Wikipedia:Reference desk/Archives/Computing/2009 October 16

From Wikipedia, the free encyclopedia
Computing desk
< October 15 << Sep | October | Nov >> October 17 >
Welcome to the Wikipedia Computing Reference Desk Archives
The page you are currently viewing is an archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages.


October 16[edit]

Cheapest pocket 'computer'[edit]

What would be the cheapest pocket-sized or less self-contained computing device? Some constraints: it must 1) have some kind of alpha-numeric keyboard - a touch-screen keyboard might do. 2) have a display that can at least show text and numbers. 3) have some high level programming language 4) be able to save data or programs 5) be able to trabsfer data and programs to and from a computer. Thanks. (As paper LCDs are now possible, I hope that one day soon it will soon be possible to buy a pocket computer for a few pounds or dollars.) 78.151.92.101 (talk) 00:25, 16 October 2009 (UTC)[reply]

Off the shelf - a used PDA would probably fit the bill. A high-end graphing calculator. An Android-based cellphone maybe. SteveBaker (talk) 01:35, 16 October 2009 (UTC)[reply]
Personally, I'm still waiting for my OpenPandora. Graphing calculators like the TI-92 sell used for under $40 on ebay. They've got a weird form factor, though. You might go for an older PalmOS machine. They don't come native with built-in programming tools, but you can get C compilers and stuff. APL (talk) 23:54, 16 October 2009 (UTC)[reply]

wget and cURL - can the links they follow be specified?[edit]

I would like to use one of the these to download a series of pages connected by "next page" links only, and not to follow any other of the links on the pages. Is there any way of getting them to do this please? 78.151.92.101 (talk) 00:34, 16 October 2009 (UTC)[reply]

Looking to build a budget gaming computer, are these parts OK?[edit]

I'm OK with software, but I know nothing at all about hardware, so when I decided to build a computer I was forced to turn to the Internet. Off a suggested parts list for a budget gaming computer, I got most of the following parts, although a few were no longer available so I had to try to find an alternative. Again, I freely admit that I know very little about the finer points of hardware (although I'm trying to pick up a few things!), so any advice would be greatly appreciated.

Case: COOLER MASTER Centurion 534 RC-534-KKRK-GP Black Aluminum & Mesh bezel / SECC Chassis ATX Mid Tower Computer Case 460W Power Supply - Retail

Motherboard: Foxconn A7DA-S AM2+/AM2 AMD 790GX HDMI ATX AMD Motherboard - Retail

Processor: AMD Athlon X2 7850 Black Edition Kuma 2.8GHz 2 x 512KB L2 Cache 2MB L3 Cache Socket AM2+ 95W Dual-Core Processor - Retail

Memory: Patriot Extreme Performance 4GB (2 x 2GB) 240-Pin DDR2 SDRAM DDR2 800 (PC2 6400) Dual Channel Kit Desktop Memory Model PDC24G6400ELK - Retail

Video card: EVGA 01G-P3-N959-TR GeForce 9500 GT 1GB 128-bit GDDR2 PCI Express 2.0 x16 HDCP Ready SLI Supported Video Card - Retail

Hard drive: Western Digital Caviar Black WD5001AALS 500GB 7200 RPM 32MB Cache SATA 3.0Gb/s 3.5" Internal Hard Drive -Bare Drive

Optical drive: SAMSUNG SH-S223Q LIGHTSCRIBE DVD±RW DVD-MULTI 22x S-ATA

If I've missed anything vital (I already have speakers, a mouse, keyboard, etc.), please mention it as well, as this is the first computer I've ever seriously considered building. Any advice or explanation about the building process would also be appreciated. Also, I'm planning on getting Windows 7 when it comes out- what version of it will I need to get? Oh, and the budget I was trying to stay within was about $700, although I could stretch farther if absolutely necessary. Thanks for the help! 24.247.163.175 (talk) 01:20, 16 October 2009 (UTC)[reply]

Parts look OK, except that you should get a minimum of a 9600GT for a 'gaming' computer. This will need a slightly better power supply - about 600W should be OK. Memory is fine (4G) and I can't comment on the AMD components as I prefer Intel... but they should be fine (dual core). Sandman30s (talk) 09:19, 16 October 2009 (UTC)[reply]
A good 460W power supply would give more then enough headroom for that computer, even with the 9600GT. [1] [2] [3] Nil Einne (talk) 11:49, 16 October 2009 (UTC)[reply]
(this is the OP, just on a different computer now!) So if I were to switch out that card for this one, it should be good? 204.38.47.171 (talk) 17:50, 16 October 2009 (UTC)[reply]
Perfectly fine. Also, make sure you motherboard supports PCI Express v2.0 (not version 1) so that you can get full benefit out of that card. I have a similar setup and all modern games right perfectly well on 1280x1024 resolution. Of course a 9800GT is better but that could blow your budget! Sandman30s (talk) 19:27, 18 October 2009 (UTC)[reply]

TI Basic vs. Python[edit]

I'm translating a TI-89 Basic program into Python, and I'm wondering... is there a Python equivalent of TI-Basic's "cycle" command? --Lucas Brown 42 03:38, 16 October 2009 (UTC) —Preceding unsigned comment added by Lucas Brown 42 (talkcontribs)

"continue" Rckrone (talk) 04:49, 16 October 2009 (UTC)[reply]

Consequences of opening a port[edit]

Hello, tech-savvy Wikipedians! I wanted to open a port through my laptop's firewall so that the parents' computer in another city can establish a connection over the Internet to my laptop and send data back and forth. However, I am not aware of the security risks of opening a port. So my questions are 1. How does opening a port affect the security of my system? and 2. What steps can I take to let my parents' computer in while keeping the "bad guys" out? Thank you!--el Aprel (facta-facienda) 04:54, 16 October 2009 (UTC)[reply]

It depends entirely on (1) what port you're talking about, (2) what program will listen on the port, and (3) the settings for the program.--Drknkn (talk) 07:58, 16 October 2009 (UTC)[reply]
I will make a Java program that listens on the port. Does that mean I can explicitly control what computers can establish a connection with mine by using a password, for instance, or a long that holds an identification value in the program? Then, does that mean as long as my Java program isn't running, the port is essentially "closed" and won't permit a connection because there's no program listening on it? Also, I didn't know the port number mattered. I had a look at the List of TCP and UDP port numbers article and thought I could pick any of the private ports between 49152–65535. Is that a bad idea?--el Aprel (facta-facienda) 19:31, 16 October 2009 (UTC)[reply]
Oh, and I did just take a look at my netstat and will make sure to pick a private port that isn't already being used by internal processes on my system.--el Aprel (facta-facienda) 19:36, 16 October 2009 (UTC)[reply]
Specific ports are not inherently "more risky" - but if you pick a port which is commonly used to host another widespread software service, you might find statistically more random "probes" by random drive-by portscanners. Your Java program can verify the IP of who is connecting - so you can use specific-host-only connections (if you trust a specific IP, e.g. your parents' PC); the IP connecting to you can not be spoofed (unless your parents' PC is a "man in the middle" proxying somebody else's attack). You can use a Secure Socket in Java, and you can implement any of a variety of custom authorization verification handshaking protocols. It's very unlikely that an automated port scanner would guess a particular long authentication byte sequence "password" - which you could send in plain-text, or hash against the current UTC time and host IP, to make it more secure. Nimur (talk) 20:56, 16 October 2009 (UTC)[reply]
Home-brewing your own network protocol generally isn't necessary, and may open up security problems you haven't considered. I'd generally recommend running a secure-shell server like OpenSSH (on a non-standard port, so you don't have to look at so much port-knocking noise in the logs). With that you can tunnel anything you want, from windows and unix networking protocols to remote screen protocols link VNC; and if you really need to write your own protocol, it's probably easier to write a non-secured version of it, and tunnel that through SSH too. -- Finlay McWalterTalk 21:13, 16 October 2009 (UTC)[reply]
In Java, wrapping the protocol in SSL would be possible using Security, e.g. the SSLSocket (with SSL implemented by Sun, not by OpenSSH). (Or you could tunnel through an OpenSSH session). I was under the impression that el Aprel specifically wanted to write his/her own network protocol; but as Finlay rightly points out, much can be accomplished with standard tools like scp. Nimur (talk) 21:54, 16 October 2009 (UTC)[reply]
Thanks, everyone! Yes, my original intention was to construct it all by myself using Java, but I was reluctant because I didn't understand the security factors involved. Your responses really helped clear it up for me. Thank you!--el Aprel (facta-facienda) 20:00, 18 October 2009 (UTC)[reply]

3-Sat[edit]

I was wondering, are the complexity classes of algorithms used to solve the 3-Sat descion problem determined based upon the number of actual variables or the number of expressions? For example, would the input size of (a + !a + b) AND (b + !b + a) AND (a + a + a) be 2 since {a,b} has 2 elements or 3 since 3 expressions are being conjuncted? (Obvbiously, this example can be very easily reduced down to fewer expressions, etc.) 66.202.66.78 (talk) 07:37, 16 October 2009 (UTC)[reply]

Well, I would say it is 9, the number of literals you have to write to write out the expression. --Spoon! (talk) 07:41, 16 October 2009 (UTC)[reply]
So, essentially, it is the number of expressions since this is just 3 times the number of literals? In short, input size is related to the number of literals, not the number of variables used in those literals? Thanks:) 66.202.66.78 (talk) 07:45, 16 October 2009 (UTC)[reply]
It's NP complete in either case. Because worst case behaivor will occur when the number of different literals are within a polynomial factor of the size of the expression. Taemyr (talk) 08:51, 16 October 2009 (UTC)[reply]

Final Fantasy Tactics[edit]

- While I'm here, I have another question. I always liked the battle system in FFT and was wondering if there was a program that would let you set up the characters, conditions, and terrains and have a multiplayer battle in a similair fashion; namely, could one get something like the FFT battle engine, but set it up so that it is two players without computer controlled characters? If this is not possible, how hard would it be to program something like this? What would be a good language to do it in? (I've often tossed around the idea of making my own, I just don't have that much experience with game programming; though I do have experience with other areas. Note: I really don't care about the quality of the graphics, just the system.) Actually, while here, I would like to ask the same question, only with regards to FF7 Chocobo racing portion from the Golden Saucer. (Again, this doesn't need to be an exact duplicate, just something related that I could customize and, possibly, mess around with the actual code) Thanks:) 66.202.66.78 (talk) 07:45, 16 October 2009 (UTC)[reply]

I searched for existing implementations; I don't know what "SuperTact" is unless it's the C64 game. I also found FFT Realm; I don't know how close it is to what you want.
As for implementing it yourself, it shouldn't be very hard if you're willing to forego (sophisticated) graphics and network play (so all players must be at the same computer). The rules are well-known. However, expect that reimplementing every character class and spell from FFT to take as long as to write that guide (at least).
If you already know any general-purpose programming languages (you said you "do have experience with other areas"), you'll probably be most effective with what you know. Otherwise, I'd suggest Java or Python, because they're well supported, widely used, have extensive standard libraries for graphics and (if you try it) networking, and are said to be easy to learn. (I'm afraid I don't know anything about Chocobo racing.) --Tardis (talk) 01:00, 18 October 2009 (UTC)[reply]

Choice of Motherboard[edit]

There is two mobo of Gigabyte in my choice

  • GIGABYTE GA-EP45-UD3R
  • GIGABYTE GA-EP45T-UD3R

Which one i should choose? —Preceding unsigned comment added by 119.30.36.51 (talk) 11:40, 16 October 2009 (UTC)[reply]

The big difference between these two motherboards is one supports DDR3 and the other DDR2. As DDR2 is still significantly cheaper then DDR3 I would recommend you stick with it. You're unlikely to see any performance difference in the vast majority of real world applications e.g. [4] [5] so the only real benefit would be being able to use the RAM in a future DDR3 computer but given the price that's not likely to be a big advantage and the advantage is the ability to upgrade the RAM in the future for a reasonable price (since DDR3 will eventually overtake DDR2 in price and then will get cheaper) but again if you get 4GB now (and given the price there's little reason not to) there's not likely to be any real reason to upgrade in the future I would expect. Nil Einne (talk) 11:58, 16 October 2009 (UTC)[reply]
DDR3 2GB modules are now at price parity with DDR2, and DDR2 prices appear to be going UP not down. DDR3 4gb modules are still much more expensive than ddr2 though. 66.127.54.181 (talk) 21:56, 16 October 2009 (UTC)[reply]
I guess this depends where you live. It's not the case here in New Zealand where DDR3 is at least 25% more. Obviously I'm only considering 2x2gb, anything else isn't worth considering unless the OP has specific needs IMHO. If DDR3 is at price parity then I would agree DDR3 is probably the better bet. Nil Einne (talk) 11:05, 17 October 2009 (UTC)[reply]
Even in cases where DDR3 are a little more expensive, it's worth something to future-proof. If it were me and the two boards were priced the same I would get the DDR3 version. ---J.S (T/C/WRE) 00:48, 18 October 2009 (UTC)[reply]
It depends on your budget but I would regard 25% (actually probably more then that from what I've seen) as significantly more expensive that you have to ask yourself what for? In this case, a big question is future proof against what? As I've mentioned, given the current price of RAM, the advantage of being able to use your RAM in a future computer is IMHO pretty much worthless (particularly since in most places you could easily sell your DDR2 RAM for a fair amount if it comes down to that). So the only real advantage which I also mentioned would be being able to upgrade RAM in the future (any decent RAM should have a lifetime warranty so having to replace broken RAM is not an issue) at a more decent price and with larger sticks (since it is unlikely we will see 4gb DDR2 sticks but I would expect 4gb DDR3 sticks to eventually take hold and become a recent price). If you are a gamer, simulatenous edit very large photos, do CAD or 3D work, edit HDTV, run a database or otherwise may really need such a large amount of RAM in the future then it may be worth considering. But in reality, the average user doesn't really need even 4gb nowadays, the only reason I recommend it is because it's the only sensible option (well unless you're looking at triple channel) given the pricing unless on a very, very tight budget (which is unlikely given the motherboards being considered). I'm usually a big fan of and there are clearly cases when future proofing clearly makes sense. For example, if in 2005 you were choosing between an AGP or PCI-express motherboard, you'd likely be rather miffed if you choose the AGP particularly if you are a gamer and in other cases like if you want a card for hte h264 etc bitstreaming. It's perhaps worth remembering we're talking about a dying platform. The socket 775 platform is being phased out. If you are considering a dual core now you may want to upgrade to a quad core in 2 years or less if you're likely to need it. Beyond that, it's likely to make less sense since even if socket 775 processors are still available, there's a good chance they'll be rather expensive for what you get particularly for the quad cores (as someone with a socket 939 processor I know this). You'll never see more then a quadcore. And, there are only going to be very few circumstances where you're likely to want 8gb with a dual core processor. So unless you're seriously considering a quad core now or in the future, another reason to ask yourself if you really need it? It's also worth considering it in an all round sense. The money may not be much, but it's still something. Where else could you spend the money? In fact if you think there's a slight possibility you may want to upgrade to 8gb you should consider some sort of cost/benefit. History with DDR and SDRAM would suggest the price for DDR2 ram is probably not going to get super expensive. RAM prices fluctate quite a lot but it's resonable to expect in 2 to 3 years time DDR2 ram will be a similar relative price then as it is now. DDR3 will have come down a lot so that it will seem expensive, however even so the amount you save now may mean the price difference you're paying isn't actually as big as it seems. You will be stuck using 4 sticks (whereas with DDR3 you can sell or do something else with your RAM and probably use 2x4gb if you want albeit this will add cost and your 2x2gb sticks DDR3 won't be worth much unlike your DDR2 sticks) and have little chance of using 16gb. Maybe even saving it and upgrading sooner may make sense. Incidentally, as someone who's used Windows x64 (first XP now Vista) for 3 years+ I can say the number of Windows x64 applications is still rather low. Many professional apps are finally coming around to this but unless you use them, there's a good chance most of your applications will be x32. This is a key point since if your apps are x32 they themselves are never going to be able to use more then 4gb so you'll only gain an advantage with multitasking of extensively memory hungry apps. I'm pretty sure quite a few aren't even large bit aware so can't even use more then 2gb. I used to think people skimped way to much on RAM. But as I've said, it seems to me we're starting to reach a level where the demands have slowed* so even 4gb is not really necessary even if IMHO the only sensible option. Even most Vista users don't really need 4gb and Windows 7 and netbooks have seemingly improved the situation. If this switch to cloud computing really happens well there will be even less need. I'm sure in 3-5 years there will be quite a few more people that need more that need more then 4gb but I also think you have to ask yourself whether it's resonable you'll be one of them and if not what you're futureproofing against? *It isn't just RAM of course, many people have argued the same thing with processors. Nil Einne (talk) 11:35, 18 October 2009 (UTC)[reply]

Visual Studio 6 & Crystal Report 2008[edit]

I have installed Visual Basic 6 and Crystal Report 2008 in my computer. But I cannot run Crystal Report from within Visual Basic as the Report Designer option is not shown in the Add-Ins Menu . What I should do to solve this problem. Please help me. —Preceding unsigned comment added by 59.161.97.110 (talk) 15:26, 16 October 2009 (UTC)[reply]

Excel question[edit]

This is such a simple question but I have a problem that's driving me BONKERS.

When I am using excel, very frequently when I click on a cell or a line, it will select 2, 3, or 4 cells/lines below it. I can't get it to stop doing this. It seems to happen at random and has nothing to do with the doc itself, the formatting, previous actions, or anything else. It will keep happening for 2-3 minutes and then suddenly it will stop and I can select 1 cell/line again. My colleagues report this issue all the time and no one has a clue why it happens or how to stop it.

I'm sure there is a MS Office savvy person who knows exactly why this happens and how to fix it. Please advise! Gohome00 (talk) 16:23, 16 October 2009 (UTC)[reply]

There must be some error that occured during installation. Has this always happened? if yes, buy and reinstall it. if not, Your computer must have some sort of bug...Accdude92 (talk) (sign) 16:26, 16 October 2009 (UTC)[reply]
"Your computer must have some sort of bug"? Please do not guess. Comet Tuttle (talk) 17:51, 16 October 2009 (UTC)[reply]
To be clear, does this happen on multiple computers when working only with a particular Excel doc, or is it any Excel doc? What version of Excel? I'm wondering if you have one particular doc in which a bunch of cells have been merged, so the behavior when clicking on one of the merged cells is not what you'd expect not knowing they had been merged. Comet Tuttle (talk) 17:51, 16 October 2009 (UTC)[reply]

It happens with any and all docs, including those created by other sources and other offices. It happens on multiple computers. Definitely has nothing to do with merges. I could create a document right now thats just a list of my friend's names, and it might happen. Or it might not. No clear pattern. It seems that many of my colleagues just deal with it and treat it like "one of those things". Excel is always trying to "help" you by doing frustrating things automatically, such as creating formulas where you don't want them. I am assuming that's what's happening here.

We use whatever the newest version of MS office is. It has happened to me before on other computers in other jobs - I've just never had to work so much with excel, so now it's driving me crazy. Gohome00 (talk) 17:59, 16 October 2009 (UTC)[reply]

Would it be possible to take a screenshot of the screen (Print Scrn key, then open Accessories>Paint, then Paste, then save as a jpeg) immediately upon its occurrence, and post it (to a photobucket or Flickr account perhaps) and post a link to it? I have used Excel for many years and I don't recognize the symptom you're describing. Comet Tuttle (talk) 20:24, 16 October 2009 (UTC)[reply]
  • Gohome00, I would bet that this has something to do with your typing or clicking habits. If you are holding down SHIFT or CTRL when you click it will select more then one cell at a time. SHIFT selects every sell between the initial cell and the finial cell in a square shape, CTRL selects the initial cell and the clicked cell. If the mouse is moving when you click it's possible to select two or more cells at a time. If you dial down the mouse sensitivity (speed) it might prevent this. I hope that helps, -----J.S (T/C/WRE) 00:53, 18 October 2009 (UTC)[reply]

Blender physical objects[edit]

I know that there is some company that you can send Blender files to, and then they will somehow "print" these, so a (plastic?) physical model is created, and then they send back the model to the customer. But I seem to have forgotten the name (and website URL) of the company. Any ideas? --81.227.64.69 (talk) 19:56, 16 October 2009 (UTC)[reply]

We have an article on 3D printing - there are a lot of companies that can do this. I think we sent .dwg files to our 3D printer when we prototyped things - there are probably hundred of companies that can contract small 3D print jobs these days. A web search for 3D Printing turns up many contract shops you can choose from to match your price and technical needs. Nimur (talk) 20:24, 16 October 2009 (UTC)[reply]
These services certainly exist - but are really expensive. For a one-off, they are the cheapest (and only) route. But if you need to do this a lot, you might also like to look at the "RepRap" project and also things like the MakerBot. These small machines can be built for relatively low cost ($750 in kit-form - about $400 if you make it yourself from scratch) and it will do exactly what you're asking. The RepRap machine can even make all of the plastic parts you need to make another RepRap machine! The business end looks like a hot-melt glue gun (although it's hotter and a little more sophisticated) and a pair of motors drives that around in two axes to 'draw' a thin layer of plastic representing a cross-section of your object. A third motor moves the plastic depositor up and down vertically so that the model can be built up layer by layer. It's slow - it could take an hour or more to make even a pretty small object - and there are rather severe restrictions on the size of objects that you can make with it - but compared to the commercial services, it would probably pay for itself after making maybe just a dozen objects.
Alternatively if your objects don't have under-cuts - and if you're at all good with tools, you could do as I did and build a three Axis milling machine for about $200. I built mine over several weekends using MDF for the major structural parts, aluminium channels and roller-blade bearings as the guide-rails and three stepper motors with long lead-screws to drive a 2hp router motor in the X, Y and Z directions. I used a couple of Arduino computers to control it using instructions written to an SD memory card - so it doesn't tie up my PC for hours at time. Mine will carve wood and some sorts of plastic pretty efficiently at sizes up to 4'x3'x9" - and with precision of about a millimeter or so. It can also cut metal - but you have to go very slowly and lubricate the cutting surface - which is a major pain. You can drive it from all sorts of 3D file formats from existing OpenSourced software. It doesn't have the versatility of the plastic deposition machines like RepRap - but it's cheap to make and can produce much larger and more robust work-pieces than those plastic deposition machines. My longer term plan is to use the CNC milling machine to make the parts for my own design of 3D printer...and to make a smaller five-axis CNC machine with a Dremel as the cutting tool. That machine would be able to make under-cuts and such like.
SteveBaker (talk) 04:25, 17 October 2009 (UTC)[reply]
Steve, that machine is amazing. Now all you have to do is program it to build a duplicate CNC machine.... Nimur (talk) 14:54, 21 October 2009 (UTC)[reply]

slow file copying speed[edit]

I have a Thinkpad T61 laptop running Ubuntu 8.04. The laptop has an internal SATA hard drive and also a plug-in bay with a second hard drive (you can put an optical drive there instead if you want). The second HD is also SATA but I'm pretty sure the plug-in bay has a SATA-PATA bridge inside. Both drives have ext3 file systems. Anyway, I tried copying a 4gb .iso file from the internal drive to the plug-in drive and after a while, the transfer slowed to around 5MB/sec, which just seems pathetic. Copying from the internal drive to an external USB drive gets around 5x that speed (though much more cpu load). It's not the speed of the PATA bus either. I unmounted and remounted the plug-in drive, then catted the copied file to /dev/null and got about 60MB/sec transfer. So why was the original copying so slow? It was slow whether I used cp, dd, or rsync. The computer has tons of ram and was not heavily loaded at the time of the tests. Any ideas? 66.127.54.181 (talk) 21:21, 16 October 2009 (UTC)[reply]

Those rates (5MB/sec and 60 MB/sec) very closely match the transfer speeds for USB 1.1 and 2.0. Probably, for whatever reason, the plug-in drive was originally only recognized as a USB 1.x compliant device; on reconnecting, the correct driver was detected and loaded, and the device functioned with full USB 2.0 speed. Nimur (talk) 21:24, 16 October 2009 (UTC)[reply]
Erm, now I'm confused - which drive was the slow one - the bay drive (which should not have been a USB device); or the external drive? Nimur (talk) 21:26, 16 October 2009 (UTC)[reply]
I think I got it - it was slow between the internal SATA drive and the bay-drive - probably because these devices share the same southbridge/peripheral controller; but the data can not go directly from disk-drive-1 to disk-drive-2 (it must go to main memory, at least - and may have to actually use the CPU). Thus the memory-northbridge-southbridge bandwidth is split in half. The case of an external USB drive does not share the PCI bus - so this bandwidth is not bottlenecked, and the full USB transfer speed is possible. There are still a few curious issues with the numbers; you could benchmark a lot more to really narrow down where the real worst-case performance happens to locate what the bottleneck is (but it may not be worthwhile, depending on how often you need high performance data transfer). Nimur (talk) 21:35, 16 October 2009 (UTC)[reply]
Whoa, something weird is going on, catting the file from the INTERNAL drive to /dev/null just took 16 minutes (4 MB/sec). I wonder if something is wrong with the internal drive. I'm trying another copy with a different large file. Just last night I backed up the drive to an external USB 2.0 drive and got 20+ MB/sec transfer. But I see no error messages in "dmesg" or syslog. Anyway, there are 3 drives: 1) internal SATA, should be directly on PCI bus and fast. 2) Plug-in bay drive, on SATA-PATA bridge that should be on the bus; 3) external USB 2.0 drive. There is also a 4th possibility, which is that I have an ExpressCard eSATA adapter (plugs into internal PCIe if I understand properly) that I can connect an external drive to, but I haven't tried that yet. Right now, something seems flat-out wrong with the internal drive, like maybe it has gotten in some weird DMA mode. I wonder how to diagnose this. 66.127.54.181 (talk) 21:53, 16 October 2009 (UTC)[reply]
It occurs to me, I have a lot of browser tabs and other windows open though quiet, and the system is not thrashing, but it's sort of possible that some javascript or something is doing steady disk i/o causing head contention on the main drive. I will reboot the computer and try repeating the copy with nothing else running. 66.127.54.181 (talk) 22:05, 16 October 2009 (UTC)[reply]

OK, I haven't rebooted, but found that copying other files from the internal SATA drive goes fairly fast, like 30MB/sec. It's only THESE PARTICULAR FILES (two .iso's that I downloaded last night) that transfer slowly, including cp or cat'ing them to /dev/null. This is weird. File system fragmentation? Bad spots on the disk? I don't see any syslog messages. 66.127.54.181 (talk) 22:52, 16 October 2009 (UTC)[reply]

Rebol v Python - which is better?[edit]

I've only programmed with basic and logo previously, and I want to learn a more up to date language that will allow me to interact with the web and with Windows or Linux. Although the Wikipedia article about Rebol is a very dry formal description (*) that does not do the language justice and makes it appear totally unsuitable for the casual user or beginner, the tutorials here http://www.musiclessonz.com/rebol_tutorial.html make the language very alluring. (* Its as if the Motorcycle article was like this: "A /motorcycle/ is an electro-mechanical device which transforms the chemical energy of hydrocarbons into kinetic energy....").

Can anyone put the case for Python and say why I should learn Python rather than Rebol? I am only going to learn to use one language. Speed of learning and quick programming (not program speed) are what is important to me. It would only be for ocassional casual use. It looks like Rebol can do things in a single line of code (see http://www.rebol.com/oneliners.html for example) that would take pages in other languages, and also that I can do web things with it that would be too complicated for me to attempt in other languages. Thanks 78.149.130.188 (talk) 21:33, 16 October 2009 (UTC)[reply]

Rebol is far less common, so you will have a harder time tracking down references, resources, and fellow humans who can help you with conceptual and technical issues. Python has an enormous user-base. Nimur (talk) 21:37, 16 October 2009 (UTC)[reply]
With great user base come great many quality libraries. From 3d game engines to symbolic math to interfaces for most databases in existence, and this is only scratching the surface. In strict contrast to rebol, python can do everything. However, many languages exist because a single one cannot fit all tasks, right tool for the right problem, and other hippie stories apply. --194.197.235.240 (talk) 23:22, 16 October 2009 (UTC)[reply]

Thanks for your replies but sorry I think that is less than convincing evidence for the superiority of Python. Python may have a big-user base prescence on the web because getting it to do some things are difficult/complicated, while with Rebol these same thing may only require one or two command words. Some of the appeal of Rebol to me is that it has some of the features of Forth, a language whose simplicity of structure appeals to me. Gosh, I think I'm falling in love. 78.147.27.136 (talk) 10:41, 17 October 2009 (UTC)[reply]

It seems you have already made your decision, but I can't resist saying python isn't difficult. Below is a python program that brings up a quit button that does what it says. It's quite readable even if you don't know python and the details can be learnt in less than a day from a pygtk tutorial.
pygtk sample
#!/usr/bin/python
import gtk

w = gtk.Window (gtk.WINDOW_TOPLEVEL)
b = gtk.Button ('QUIT')
b.connect ('pressed', gtk.main_quit)
w.connect ('delete-event', gtk.main_quit)
w.add (b)
w.show_all ()

gtk.main ()
A simple command line movie player using the gstreamer framework
gstreamer sample
#!/usr/bin/python
import sys
import gobject
import gst

loop = gobject.MainLoop ()
player = gst.element_factory_make ('playbin2', 'player')
player.set_property ('uri', sys.argv[1])

bus = player.get_bus ()
bus.add_signal_watch ()
bus.connect ('message::eos', lambda dummy, d2: loop.quit ())

player.set_state (gst.STATE_PLAYING)
loop.run ()

player.set_state (gst.STATE_NULL)
Finally a simple web browser with webkit, without an address bar because I'm feeling lazy
webkit sample
#!/usr/bin/python
import gobject
import gtk
import webkit

gobject.threads_init ()

window = gtk.Window (gtk.WINDOW_TOPLEVEL)

scrolled = gtk.ScrolledWindow (None)
scrolled.set_policy (gtk.POLICY_AUTOMATIC, gtk.POLICY_AUTOMATIC)

webview = webkit.WebView ()
frame = webview.get_main_frame ()
frame.load_uri ('http://www.google.com/')

scrolled.add (webview)
window.add (scrolled)

window.connect ('delete-event', gtk.main_quit)
window.show_all ()

gtk.main ()
These are best taken as examples of not so good programming practise, but hopefully they show python isn't "difficult". --194.197.235.240 (talk) 17:15, 17 October 2009 (UTC)[reply]

Sorry again I'm less than convinced. This is a complete Rebol program for a GUI to send an email:


view layout [e: field "Email" s: field "Subject" m: area "Body" btn "Send"[send/subject to-email e/text m/text s/text alert "ok"]]


A web site editor:


view layout[f: field btn"Edit"[editor to-url f/text]]


Taken from the 'one liners' link above. The program examples previously given by 194.197 may only require a few words in Rebol. The Python script for a button seems very elaborate: in Rebol I think it would just be two or three words. Could any Python programmer have a look at the one-liners link above, and the Cookbook external link at the Rebol article, and tell me if things with equal conciseness can be done with Python? 78.151.108.233 (talk) 10:17, 18 October 2009 (UTC)[reply]

Conciseness is not the only goal, readability is important too. People think slower than they type. As for the button example, any larger program would use a gui designer which would cut down the source lines a lot and make future layout changes easier. It looks to me that rebol has a lot of complex built-in functionality bind to short commands, but it should also be considered how much control you are given over the details. For example in sh it's trivial to make an multi-featured image manipulation program, you just type gimp<enter>. Below is a python program that creates a window with a bunch of chinese characters spinning in it and terminates when the window is closed. I don't know if rebol can do the same.
chinese chars
#!/usr/bin/python
# -*- coding: utf-8 -*-

import gobject
import gtk

def spin_cb (label):
    label.set_angle (label.get_angle () + 5)
    return True

w = gtk.Window (gtk.WINDOW_TOPLEVEL)
l = gtk.Label ('中國')
w.add (l)
gobject.timeout_add (50, spin_cb, l)
w.connect ('delete-event', gtk.main_quit)
w.show_all ()

gtk.main ()
quicksort in python (normally you would just the .sort method of course), not quite as short as rebol's but short enough
quicksort
q = lambda l: l if l == [] else q ([x for x in l[1:] if x < l[0]]) + [l[0]] + q ([x for x in l[1:] if x >= l[0]])
this one returns all primes less than n
primes
s = lambda n: [p for p in range (2, n) if all ([p % x != 0 for x in range (2, p)])]

--194.197.235.240 (talk) 14:02, 18 October 2009 (UTC)[reply]

How to install cURL?[edit]

When I download cURL for Windows XP, I get a zip file. In the zip file are curl.exe, some dills, and some text files. When I click on curl.exe a black window openms up and then immediately closes. How should I install cURL? Its irritating that the information that people would obviously need is completely omitted from the instructions, similarly with wget. Thanks. 78.149.130.188 (talk) 21:43, 16 October 2009 (UTC)[reply]

Extract all the files in the .ZIP into a folder you've made (say c:/Program Files/curl). cURL is a command-line program, so you need to open the windows command line (run->cmd.exe), cd into the folder you made for cURL, and run curl.exe with options that make it do what you want. -- Finlay McWalterTalk 21:48, 16 October 2009 (UTC)[reply]
Further, wget is also a command line program. That "black box" is the console. I don't know why Windows makes it die instantly. If it stayed open, you'd see some console output. To use either curl or wget, you need to type (ignore the mouse). If you want a click and view program that shows web pages, there are many: IE, Firefox, Opera, Chrome... -- kainaw 21:55, 16 October 2009 (UTC)[reply]

Thanks. Would it be sensible to copy the contents of the zip file into c:\ or c:\windows, so that I do not have to change directories after opening the console window? What I would like to do with either of them is to download the text from a series of pages by only following the "next page" links and not following any other link. Anyone got any idea how I could do that please? 78.149.130.188 (talk) 22:05, 16 October 2009 (UTC)[reply]

You can put those files on your Path (variable) by either adding them to a system directory (c:\windows\system32, for example); or placing them somewhere and adding that directory to your path. Or, you can put them in a folder somewhere, and manually type the full location of that program from any other current working directory; eg. "c:\programs\wget\wget.exe (arguments)" . Nimur (talk) 22:08, 16 October 2009 (UTC)[reply]
When I was using Windows I'd put command programs in a single directory (e.g. e:\utils) and put that directory in the path. Command-line programs are very useful and the great majority of them have few files that are really needed, so it's easy for a dozen or more programs to coexist in the same directory. Wget (which I happen to make great use of outside Windows) is a particularly excellent (if limited) program but do read the instructions about recursive downloading carefully before use, or else you may have one or other kind of surprise. Sorry I don't know the answer to your specific question but I imagine that these "next page" links have an easily identifiable set of filenames, and if you can't easily get wget to get these filenames and little more, then simply get the whole of the relevant section of the site and then delete the stuff that's of no interest to you. -- Hoary (talk) 02:19, 17 October 2009 (UTC)[reply]

Thanks. I've just realised I could do what I want, regarding following the "next page" link only, by combining lines 6 and 42 from the Rebol language one-line programs here http://www.rebol.com/oneliners.html 78.151.108.233 (talk) 11:14, 18 October 2009 (UTC)[reply]

Converting WAV to MIDI[edit]

I have several WAV sound files that I need to convert into MIDI format. What's a free program that will do this? Mediaconverter.org doesn't convert to or from MIDIs for some reason. --75.10.49.150 (talk) 22:11, 16 October 2009 (UTC)[reply]

A WAV file contains samples of the sound wave, several thousands per second. Consequently, any sound may be represented as a WAV data file. A MIDI file, however, is merely a sequence of instrument names, notes, and velocities, and thus only (relatively) simple music may be represented as a MIDI file. Among other things, song and general sound effects cannot be represented as a sequence of notes. In fact, you can compare WAV files to bitmap images, and MIDI files to vector images. A bitmap image contains the colour value at each pixel (millions of them per image), and a vector image file contains only a list of objects (circle, line, etc.) and their attributes (colour, line width, etc.). Thus it is easy to convert a MIDI file to a WAV file, and a vector image to a bitmap image, but it is extremely difficult to do it in the other direction. --Andreas Rejbrand (talk) 22:16, 16 October 2009 (UTC)[reply]
Then is there any way to play a WAV file in JAVA without freezing the rest of the program? The only method I could find for playing WAV files in JAVA froze the program until the sound file was done playing. --75.10.49.150 (talk) 22:19, 16 October 2009 (UTC)[reply]
Yes, you might want to consider learning about Asynchronous I/O for some background theory, and creating a separate thread for the audio I/O. Java Threads are basically built into the language, and are fairly straightforward - you will need to instantiate a thread and and provide it with a run() function that performs the audio playback. If you are using the newest Sampled Sound in javax.sound.sampled, then the default start() and stop() methods are already asynchronous (threaded), so you don't have to do this manually. Depending what your audio needs are, this may be the best audio package. Nimur (talk) 22:59, 16 October 2009 (UTC)[reply]
WAV to MIDI is essentially impossible. WAV is like the recording of an orchestra playing - MIDI is like the printed score sheets that the musicians were reading from at the time. There is software (and hardware) that can extract note information from the pitch of the music - but it's really patchy and doesn't work for anything but simplest single-instrument recordings. SteveBaker (talk) 03:53, 17 October 2009 (UTC)[reply]

There is some software that does this, although its a long time since I last considered it. I recall there was some pay-for software, not sure if there were any free versions. Update: A simple search for wav midi in Google produces several results regarding conversion. http://www.google.co.uk/search?hl=en&safe=off&newwindow=1&q=wav+midi&meta= 78.147.27.136 (talk) 10:58, 17 October 2009 (UTC)[reply]

Internet trouble[edit]

  • I have windows xp professional.
  • I am using a lynksys wireless usb adapter to access my wireless connection
  • I have at&t u verse as my isp
  • My internet is really slow, and it frequently disconnects
  • This has been happening for a while now.
  • If you need any more info, ask.Accdude92 (talk) (sign) 22:30, 16 October 2009 (UTC)[reply]
The obvious first thing to try is to connect to your router with an ethernet cable; this will tell you whether the problem is a local wireless problem, or a problem with the internet connection as a whole. Diagnosis and fixes for these two kinds of error are often very difficultedit: different. In the meantime, stop all peer-to-peer programs like Bittorrent; in my experience consumer DSL routers can inexplicably exhaust some internal resource, and become fatally horked when confronted with the torrent (sic) of traffic such programs throw at them. -- Finlay McWalterTalk 22:42, 16 October 2009 (UTC)[reply]
(e/c) Thanks for providing a useful amount of information. If the problem turns out to be with the WiFi, there are several fixes you can try. Obviously, you need to be within range for it to work. What is the signal strength as reported by Windows? A recently purchased wireless router should have the strength to cover a two- or three-storey house. Piggybacking on the neighbour's WiFi does not usually get the speed or stability that you want. Do you know the brand and model number of your router? Other quick fixes: if there are many other wireless networks in the area, then you might want to change the broadcast channel. Most routers default to channel 6 - try changing to channel 1 or 11. Some cordless phones and microwaves also emit the same frequency (~2.4 GHz). For me, changing to channel 11 solved an interference problem with a neighbour's router. It's all trial-and-error. If possible, you can move your router to a better location, away from the computer and in the centre of the range of which you wish to connect to the network. Xenon54 / talk / 22:46, 16 October 2009 (UTC)[reply]
Another thing to look at is possible over-heating of your router. I recall having a similar problem a while back. - Akamad (talk) 23:52, 16 October 2009 (UTC)[reply]
I used that AT&T service on my wife's machine for a while - it was awful. As you say - poor bandwidth, patchy connections, generally a total disaster. I carefully documented the problems - worked with them patiently for a month while they tried to fix it, making all sorts of ridiculous claims that it was my computer (I used three different one - they couldn't all be at fault) - they claimed that "Windows needs to be rebooted once a day to keep the networking reliable" (possibly reasonable advice - but I was using Linux!), etc, etc. Then I demanded (and got) all of my money back for the whole 60 days I'd been using it and the refunded the price of my network adapter too. I switched to RoadRunner - things have been working just fine since then. So I don't think you should blame XP or the wireless adapter until you've hassled the AT&T helpline a bunch of times. It's very likely to be the AT&T service. SteveBaker (talk) 03:48, 17 October 2009 (UTC)[reply]
One diagnostic thing you might try out is to see how the connection works when "wired" (you should probably be able to connect to your wireless router with an ethernet cable). Is it faster? More stable? The same? This can at least let you rule out that wireless has anything to do with it. --Mr.98 (talk) 20:13, 17 October 2009 (UTC)[reply]

Using Outlook on 2 Computers[edit]

I have Outlook 2007 installed on two computers. They are set up the exact same way (same account). However the mail only appears on the first computer I installed it on. Is there anyway i can get around this or do I need to delete it form the first machine I installed it from? 66.133.196.152 (talk) 23:04, 16 October 2009 (UTC)[reply]

I'll guess that your are accessing your email account using the POP3 protocol (it's in the account settings screen in Outlook). Very often people's POP3 clients (that's Outlook in your case) are configured to download emails and remove them from the mail server. You can configure the client to download and not remove the mail server's copy. That way Both machines can see it (I don't have outlook to hand so I don't know the precise option you'll use). A downside of this is that mail will then build up in your mail server, so you may need to be more diligent about tidying it up yourself (so you don't exceed any quota your ISP may apply). As an alternative to POP3, you may be able to use the IMAP protocol instead, which is better suited for sharing one email account between multiple machines (you can, for example, create subfolders on the mail server and then file mail as appropriate - and all the email clients see the change almost instantly). -- Finlay McWalterTalk 23:14, 16 October 2009 (UTC)[reply]
I wonder if our OP could configure his main machine to download and delete his messages, and configure his secondary machine to only download them — and keep them marked "un-downloaded" so that when he logs in on his main machine, they'll be downloaded to that machine (for the first time on that machine, and for the 2nd time total) and deleted from the POP3 server. One downside to this juggling act is that the secondary computer won't have access to any e-mails the first computer has downloaded. One alternative, OP, is to set up Windows Remote Desktop or VNC so your 2nd computer merely logs into the 1st computer and sees whatever you'd see on the screen of the first computer. Tempshill (talk) 01:31, 17 October 2009 (UTC)[reply]
The least complex way of sharing mail between two computers may be using a webmail interface like what Gmail provides. Gmail will also work with some local mail clients via IMAP but it is less intuitive to keep things synchronized that way. (Is that a new mail that I see, where did I save the sent mail, and so forth). EdJohnston (talk) 21:18, 17 October 2009 (UTC)[reply]
Make use of IMAP as suggested - or if this is for business purposes, get an microsoft exchange account and charge it as an expense. --Cameron Scott (talk) 21:21, 17 October 2009 (UTC)[reply]
I suggest choosing IMAP over Exchange, as IMAP is more widely supported. (In fact, I don't know any mail client other than Outlook with Exchange support.) --grawity 19:46, 19 October 2009 (UTC)[reply]
Evolution (software) does, kinda, but it does it by webscraping OWA rather than talking the Exchange protocol. -- Finlay McWalterTalk 19:51, 19 October 2009 (UTC)[reply]