Wikipedia:Reference desk/Archives/Computing/2012 December 17
Computing desk | ||
---|---|---|
< December 16 | << Nov | December | Jan >> | December 18 > |
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. |
December 17
[edit]PC Memory stick as Random-Access Memory
[edit]What is an efficient way to use a 32Gb USB memory stick as RAM? The stick behaves like a hard disk but I don't want directories and files, I just want random access to bytes as fast as possible. My application is solving large sets of simultaneous equations held as matrices in RAM. Assume small programming knowledge. I might manage disk read/write at DOS interrupt level but have no idea how to address a USB interface. DreadRed (talk) 10:21, 17 December 2012 (UTC)
- With a memory-mapped file. But the USB bus is orders of magnitude slower than RAM, so it will work that much slower than RAM, regardless of how you address it. -- Finlay McWalterჷTalk 10:39, 17 December 2012 (UTC)
- You'd be better off buying lots of ram. Memory is cheap, how much is your time worth? But either way matrices can be worse than you think because of the way they access memory. There's all sorts of programming tricks people do to even get better memory access with proper ram so the cache is used better, it isn't easy as obvious tricks like aligning on page boundaries and chunking in small squares can lead to less obvious problems like cache thrashing where a cache line is overused. Dmcq (talk) 12:46, 17 December 2012 (UTC)
- Although this is only related to your question indirectly: What do your matrices look like? Are they sparse? In that case your memory requirement goes down significantly. Also using an iterative solver rather than a direct elimination method will reduce memory requirements significantly.31.54.249.205 (talk) 00:01, 19 December 2012 (UTC)
- Yes the equation matrices from FEM analysis are sparse. However the significant savings by sparse matrix methods are data dependent and therefore do not seem useful in a massive infinitely-scaleable multi-processor approach where the cost in terms of hardware engagement and running time must be predictable. DreadRed (talk) 07:45, 20 December 2012 (UTC)
- Rather than implementing these routines from scratch, have you looked into LAPACK and it's derivatives? ScaLAPACK is specifically designed for distributed-memory machines such as a computing cluster. PLASMA is optimized to scale well on multiple core systems, and MAGMA takes advantadge of multiple cores and GPUs. 209.131.76.183 (talk) 15:07, 20 December 2012 (UTC)
- Yes the equation matrices from FEM analysis are sparse. However the significant savings by sparse matrix methods are data dependent and therefore do not seem useful in a massive infinitely-scaleable multi-processor approach where the cost in terms of hardware engagement and running time must be predictable. DreadRed (talk) 07:45, 20 December 2012 (UTC)
Word frequency tables
[edit]Can anyone help me find these in the format I want ? Here's what Wiktionary has: [1]. Here's what I would like different:
1) No numbers or formatting text, just the words, in order from most common to least (one word per line in the file). This part is critical.
2) All the words in a single file, as opposed to files for the first 10000 words, next ten thousand, etc. This part is optional.
3) All non-alphabetic characters, like apostrophes, stripped off. This will make duplicates out of words like "cant" and "can't", so those should be combined into one, at the proper location in the file (the total of both frequencies). This part is optional.
4) Common proper nouns should be included, too. This part is optional.
I prefer US English, or both US English and British English, but not British English alone. So, do we have anything like that out there ? StuRat (talk) 16:45, 17 December 2012 (UTC)
- Given a source list of frequency tables (can you specify), as long as they are in some regular format it should be trivial to merge in your desired form with a bit of custom software (I'd do it in QBasic!) . -- SGBailey (talk) 17:04, 17 December 2012 (UTC)
- Possible, but not exactly trivial. It would take me several hours, and I'm already planning on rearranging the files to suit my needs, so I'd prefer if they are at the proper starting point already. StuRat (talk) 17:08, 17 December 2012 (UTC)
- Given that you already play with Python, this is not really hard. Do you want to work with the Wiktionary tables, or do you want to create your own from a text corpus? In either case, as long as your result tables fit main memory (and that should be true even for very large word lists today), it's a simple application of some string operators, sort, and print. --Stephan Schulz (talk) 23:45, 17 December 2012 (UTC)
- You may have better luck searching for concordances. I hopped over there, then to the Corpus_of_Contemporary_American_English, which led me to their concordance product here: [2], which is viewable as an html table. If you sign up, they will send you an .xls file, from which you can easily port to a single-word-per-line raw text file. Only catch is, only the first 5k words are free. Because it is a professional grade research tool, they charge for the full 100k database. SemanticMantis (talk) 20:16, 17 December 2012 (UTC)
- Depending on your application, you may or may not be worried about the methodological details that make the COCA list rather different than the wiktionary list. COCA gives you full details of why their product is better, here [3]. SemanticMantis (talk) 20:19, 17 December 2012 (UTC)
I'm amazed this isn't available for free, like lists of prime numbers are. StuRat (talk) 00:07, 18 December 2012 (UTC)
- That frequency list is from TV shows... so I guess you're looking for speech. Wikipedia would produce a different set of course. If you have a few sources with a lot of words (maybe a million?) you could run through and generate your own.
- Here's what I ran from the command line to get most of what you want (assuming you have a mac or linux, or can otherwise run perl). Copy paste the list into a text file, or all in order if you want to do more than one at a time, then run this (you can break it up of course too):
cat wordlist.txt|perl -pe 's#^\d+\s*(.+?)\s+.*#$1#;s#[^\w\n]##g'
- That won't combine duplicates (there are 4 duplicates in the first 1000), for that here's a dirty way to do it (you probably should have enough ram for this, but depending on your list size, beware):
cat wordlist.txt|perl -pe 's#^\d+\s*(.+?)\s+.*#$1#;s#[^\w\n]##g'|perl -e 'while(<>){$word{$_}=$x;$x++};foreach(sort {$word{$a} <=> $word{$b}} keys %word) {print}'
Shadowjams (talk) 03:07, 18 December 2012 (UTC)
The apostrophe in "can't" is not essentially a non-alphabetic character because it represents the character "o" that is hidden in the standard contraction of the two words "can not". English contains many such examples such as "it's" which means "it is" (or "it has" but nothing else, occasional abuses notwithstanding). DreadRed (talk) 08:37, 18 December 2012 (UTC)
- My code handled it fine. Shadowjams (talk) 14:07, 18 December 2012 (UTC)
How to disable "Accessibility features" in Windows 7 ?
[edit]I apparently held the shift button down too long, and it tried to "help" me by beeping at me and locking up the keyboard. A reboot solved it for now, but how do I prevent Windows 7 from ever doing this again ? StuRat (talk) 17:45, 17 December 2012 (UTC)
- This has been in there since at least Windows 98. To disable it in 7, open the Ease of Access Center (in the Control Panel, just use the Start Menu search). Under "Make the keyboard easier to use", you'll find the settings to disable the various keyboard accessibility features. The one you're looking for is under "Set up Filter Keys", but you'll probably want to disable the other ones as well. 209.131.76.183 (talk) 18:19, 17 December 2012 (UTC)
- Thanks. I had "Turn on filter keys" unchecked, and assumed that was sufficient. But apparently you have to pick "Set up filter keys" to disable the "feature" of it turning back on when you hold down the shift key. StuRat (talk) 18:34, 17 December 2012 (UTC)
- Those options drive me crazy when they are accidentally triggered, but I suppose that it makes a world of difference for people who don't have good enough control of their hands to use the modifier keys as designed - they can sit down at any computer and be able to turn on the feature without fighting through menus that are hard for them to use. For my personal computers I always turn it off, but I can see why it is on by default. 209.131.76.183 (talk) 19:03, 17 December 2012 (UTC)
- lol,this can be helpful for me to,Thank you.74.178.177.48 (talk) 21:01, 17 December 2012 (UTC)
![](http://upload.wikimedia.org/wikipedia/en/thumb/f/fb/Yes_check.svg/20px-Yes_check.svg.png)
Oldest Computer stuff
[edit]Hello fellow users, I'm Tailsman67,I'm a freelancer hacker and programer and I'm here to ask,"What is the oldest Computer?" and "IS the first Computer really the first?" and "What is the first program?",thank you? — Preceding unsigned comment added by 74.178.177.48 (talk) 21:06, 17 December 2012 (UTC)
- See History of computing hardware - as with a lot of inventions, which the first X is often depends on how you define exactly what X is. -- Finlay McWalterჷTalk 21:12, 17 December 2012 (UTC)
- Ada Lovelace's algorithm for calculating Bernoulli numbers on the Analytical Engine is often described as the first computer program - see Ada lovelace#First computer program. If my memory serves, I think it has a bug. -- Finlay McWalterჷTalk 21:15, 17 December 2012 (UTC)
- Weren't the first programs the punch cards you switched to make your water- or steam-powered loom weave a different pattern? I'm not sure that counts as a Turing machine-like thing, though. Sagittarian Milky Way (talk) 23:08, 17 December 2012 (UTC)
![](http://upload.wikimedia.org/wikipedia/commons/thumb/f/ff/Sundial-from-Marcianopolis.jpg/220px-Sundial-from-Marcianopolis.jpg)
- A similar example I heard of were hand-cranked organs, like this one: [4]. You could load a new program by replacing the cylinder, or edit the program by changing the pegs. StuRat (talk) 01:17, 18 December 2012 (UTC)
- I seem to remember reading that Leonardo da Vinci had made a programmable toy out of wood and springs, basically a robot. ¦ Reisio (talk) 02:55, 18 December 2012 (UTC)
- Yes, and the ancient Greeks did similar things. StuRat (talk) 21:02, 18 December 2012 (UTC)
- This image shows one early use of computers. HiLo48 (talk) 09:50, 18 December 2012 (UTC)
Returning to the OP's question seriously, several of the first serious "electronic" computers were developed during World War II, and details of them were naturally hidden behind massive security at the time. Several countries have competing claims. While we now know a lot more, we cannot be certain that all details have been released. In fact, it's almost certain that some information has been destroyed forever. HiLo48 (talk) 16:52, 18 December 2012 (UTC)
- Before the electronic ones the first mechanical one that was built that looked like a modern design was by Konrad Zuse and the first design like a modern one was Babbages. However one should really consider Zuse's initial machines as more like a modern scientific programmable calculator than a general purpose computer. Plus there were other systems in between like the Scheutzian calculation engine, based on Babbage's difference engine, Hollerith's tabulating and calculating machines which could be rigged together to do some quite complex work, and a complex number calculator which could be accessed at a distance via a teletype but however wasn't programmable. Plus all these were digital in operation, there were many analogue computers as well. Dmcq (talk)
- If you'd like to see a reproduction of a programmable cart like Hero of Alexandria built there's one here [5]. He made some much more complex things too. Dmcq (talk) 19:27, 19 December 2012 (UTC)
- Thanks,all of you,Kudos.74.178.177.48 (talk) 19:28, 21 December 2012 (UTC)
What's the cheapest that 2GB DDR2 667 SODIMMs have been?
[edit]And when was that? Sagittarian Milky Way (talk) 22:50, 17 December 2012 (UTC)
- Real cheap. Recently and now. ¦ Reisio (talk) 02:56, 18 December 2012 (UTC)
- CamelCamelCamel is a great resource for this sort of question. Here's the price history on Amazon for a particular model of 2GB DDR2 667 SODIMM: [6]. You can use the search to find charts for others. 209.131.76.183 (talk) 12:45, 18 December 2012 (UTC)