Wikipedia:Reference desk/Computing

From Wikipedia, the free encyclopedia


The Wikipedia Reference Desk covering the topic of computing.

Welcome to the computing reference desk.
Want a faster answer?

Main page: Help searching Wikipedia

How can I get my question answered?

  • Provide a short header that gives the general topic of the question.
  • Type '~~~~' (that is, four tilde characters) at the end – this signs and dates your contribution so we know who wrote what and when.
  • Post your question to only one desk.
  • Don't post personal contact information – it will be removed. All answers will be provided here.
  • Specific questions, that are likely to produce reliable sources, will tend to get clearer answers,
  • Note:
    • We don't answer (and may remove) questions that require medical diagnosis or legal advice.
    • We don't answer requests for opinions, predictions or debate.
    • We don't do your homework for you, though we’ll help you past the stuck point.
    • We are not a substitute for actually doing any original research required, or as a free source of ideas.



How do I answer a question?

Main page: Wikipedia:Reference desk/Guidelines

  • The best answers address the question directly, and back up facts with wikilinks and links to sources. Do not edit others' comments and do not give any medical or legal advice.
 
Choose a topic:
 
See also:
Help desk
Village pump
Help manual


June 20

Adding an accent

So I just tried to add an accented E (É) to an article, but appear to have lost the ability to do so without copy/pasting an existing character. As far as I can remember to create for example E acute, you would hold CTRL and E (caps optional), but it seems when I did this just now I didn't get a response. Instead the cursor disappears as if it were retrieving a pull down menu, but nothing was showing. Do I need to change a setting to get it to work again? I previously had no problems with this function, but admit I haven't used it for a while. Can anyone help? Thanks in advance, This is Paul (talk) 16:36, 20 June 2017 (UTC)

Wrong place for your post. Go to Help Desk. They are very fast over there. All the answers by the staff. --AboutFace 22 (talk) 16:59, 20 June 2017 (UTC)
I should have made it clear I'm asking this question in a wider context, as currently it doesn't work on any browser or word processor. It was editing Wikipedia that brought it to my attention, but it's not a Wikipedia specific problem, so here is probably the right place. This is Paul (talk) 17:06, 20 June 2017 (UTC)
You are correct that in many Windows applications, you could type É by holding down Ctrl, pressing , and then pressing Shift-E. I just tested it and it didn't work. I assume it is part of the move to unicode. You have to memorize the unicode numbers for every letter now. Hopefully there is some setting to revert this change for users who want to continue to do it. 209.149.113.5 (talk) 17:33, 20 June 2017 (UTC)
I think you can use the 'Special characters' menu in the toolbar. Ruslik_Zero 17:56, 20 June 2017 (UTC)
Ah yes, I just found it under "Latin". Great stuff. Thanks, Ruslik, and also thanks to the anonymous user as I thought it was something I'd done to change things, or a problem with my computer. Now if anyone can tell me how to do it in Word/Open Office/Libre Office I'll be back on track. This is Paul (talk) 18:25, 20 June 2017 (UTC)
I believe they each have "insert special character" in the menus. (But I don't need to know this because I'm on MacOS, which has smarter keyboards.) —Tamfang (talk) 19:46, 20 June 2017 (UTC)
If I wanted to write an e-acute, I would hold down control, hit the apostrophe key, release control and hit the e key. This works in my word processor (word 2003) but not my browser (IE very old). Perhaps you've misremembered the key sequence? Ctrl-e is always likely to be a keyboard shortcut (like ctrl-p normally provdes print). Phil Holmes (talk) 07:45, 21 June 2017 (UTC)

(EC) I find it unlikely could ever just push ctrl + e (or other suitable letters) to get an accented character by default in Windows as this strongly risks conflicting with program shortcuts. If you had this option, I strongly suspect you did something to allow this. Windows is fairly flexible so it would be relatively easy to add support for it.

As 209 hinted at, on some programs like Office it's possible to add accents by typing ctrl + some other character like grave mark ` then letting go and pushing a suitable letter. I just tested it on Word 2016 on Windows 10 Creator's Update and it still works. This is for Office 2007 [1] but I suspect its still current. Note as I said and the article indicates, you need to push ctrl + some other character like ^ including the shift if needed to get that character and then let go and quickly push the relevant letter (with shift if needed). I'm not sure if this was ever a general Windows feature, if it was I couldn't find much discussion of it which seems a bit weird, although there is a lot of discussion about alt codes so this is a difficult area to search. It's possible that it was supported on some other Windows programs besides Office but isn't any more and there is a Firefox addon which I think adds similar behaviour to Firefox [2]. Personally I have doubts this was ever a universal feature. Although less common, I imagine there may be cases where ctrl + possible accent symbol (or ctrl + shift plus possibly accent sumbol, e.g. 6/^) will conflict with shortcut keys on some programs.

There are of course plenty of other options to enter accented characters on Windows. If you regularly do it, you may want to consider another keyboard layout. US International [3] would allow you to entered accented characters by simply pushing the accent like character and then the relevant letter although this obviously slows things down when you want to use the actual character. (E.g. Quotation marks or tilde!) You can switch between keyboard layouts with a chosen keyboard shortcut key if that helps.

For some more options see [4]. (Someone there claims the Finnish layout used to have the ctrl plus accent functionality but it no longer works although I wonder if they are remembering wrong or confused. It's specifically claimed here as being Word only functionality compared to US English International and I'm fairly sure that page isn't only thinking of Windows 10 although this doesn't prove it wasn't functionality in some other keyboard layout.) Note one of the options there is to create your own keyboard layout [5] which I think still works on Windows 10 [6]. However I'm not sure if it's possible to introduce Word like functionality. You could however probably do it aith something like AutoHotKey. (Which someone else used to introduce OS X like functionality.)

Nil Einne (talk) 11:04, 21 June 2017 (UTC)

  • Assuming the typing language is French, the BÉPO keyboard layout allows accentuated capitals (the official website [fr] contains installation instructions). TigraanClick here to contact me 11:41, 21 June 2017 (UTC)
Thanks guys, this is exactly the kind of stuff I was looking for. I bought my current computer from a place that builds their own machines, so from what's been said above it sounds like it may have been set up that way, and perhaps cancelled out by a Windows update. I'll give the above suggestions a go anyway. Cheers, This is Paul (talk) 16:50, 21 June 2017 (UTC)
If you have a UK keyboard, try AltGr+e. 78.0.193.196 (talk) 23:35, 21 June 2017 (UTC)

June 21

Very low level programming

How many man-hours would it take to make 4 minutes of techno music with an abacus? A Turing tape? (1 read, write, erase or square move per second) You can't actually hear it since the system's so slow and speakerless but just because the it's not a PC doesn't mean it's not Turing-complete. How many abacuses do you need? Turing tape squares? About how many words would it take to describe the initial state and "how to do it" in plain English (though if it has enough loops doing the instructions might make learning them seem like a millisecond?). Sagittarian Milky Way (talk) 19:07, 21 June 2017 (UTC)

An abacus is not a programmable computer, so that part of the question doesn't make sense.
The rest of your question isn't likely to have an easy reference answer. You'd be asking us to do a lot of research, math, and estimation on your behalf.
Perhaps you could attempt the estimation yourself and ask us for any constants you can't find through your own research. ApLundell (talk) 21:39, 21 June 2017 (UTC)
A CD is 44,100 16-bit samples/sec*2 (~172 KB/s) so an uncompressed song is about 10 megabytes/minute. A decimal abacus with 10-14 rows of beads has a storage capacity of at least 4 bytes and can hold one 16-bit audio sample (stereo) or 2 samples (mono) so storing a song would take millions of abacuses. If a common abacus weighs only 100 grams(?) that'd be 2,000 tonnes of abacuses (stereo) or 1,000 tonnes (mono). Laid end to end the abacuses could span some continents if each was 1 foot wide. If 1 square foot they'd cover a large fraction of a square mile. This could be reduced greatly if compressed to mp3 or something. I don't know what the smallest program that can make electronic music is but surely one can be stored in only kilobytes or several megabytes. I don't know how many PC cycles it'd take but perhaps drawing the sound waves by hand would simple enough that a human could do it (calculating the value of each sample of i.e. saw-shaped waves of middle C, low F, high A or whatever the notes you need are, adding together like 7+ of them into chords, figuring out when to change the notes, calculating the new chords, and inputting the samples into roughly 10 million abacuses (mono). 1 second to write each abacus digit would be almost 5 years stopping only to sleep/eat/excrete. If you want the song to have tremolo, vibrato, portamento, glissando, volume changes, or stereo bouncing from one ear to the other that'd be a ton of more work. Perhaps it'd take over 100 man-years even without those effects but I can't estimate better than that. I've heard that some techno is made of 21 seperate notes(!) which would have to be added by abacus. Sagittarian Milky Way (talk) 01:44, 23 June 2017 (UTC)
Low-level programming generally means writing software without the aid of a compiler to isolate the writer from the execution semantics of a computer architecture.
Techno is a genre of electronic dance music characterised by a 120 to 150 beats per minute tempo created with music technologies such as drum machines, synthesizers and digital audio workstations, and expresses what Adorno saw as the alienating effect of mechanisation on the modern consciousness. Quora.com has some answers to What-is-the-best-equipment-software-for-a-beginner-to-create-electronic-music?
An Abacus is an ancient bead frame calculator capable of simple manual calculations such as addition but it is not capable of performing a program algorithm involving conditional branching or of synthesizing the sinusoidal tone waveforms of Electronic music.
Turing Tape is the name of a Seattle-area experimental musical project. You may be confusing this with the Turing completeness criterion in Theoretical computer science. Blooteuth (talk) 23:28, 21 June 2017 (UTC)
I assumed that "Turing Tape" was a reference to the infinite tape drive on Turing's hypothetical machine.
It's a common misunderstanding that if a physical Turing Machine could be built to Turing's original specification (perhaps with finite tape) it would somehow be the "most primitive" computer possible. That's not really the case. It's more of a universal machine for thought experiments, not some primitive base case upon which all other designs are built. ApLundell (talk) 15:51, 22 June 2017 (UTC)
I think a talented musician might be able to use the abacus as a sort of inconvenient cabasa - an abacasacabasa? - and with a little imagination, you could probably perform at least a portion of a musical composition that some might call "rhythmic." Nimur (talk) 23:29, 21 June 2017 (UTC)
It also depends on what you define as "techno" (do you count 8-bit music?). But I don't see the point of making music for a speakerless system unless you intend to make it write the notes down on the Turing tape. If it has no output, how do you decide if it's "made" anything? 78.0.193.196 (talk) 23:33, 21 June 2017 (UTC)
The question is very unclear, but one could imagine a computer program for generating music being written down on paper and "executed" by a human being. It's a common exercise in elementary programming classes to give the student a program and ask her to determine what it does by executing it manually. An abacus could be used to assist with any arithmetic operations required by the program. (Multiple abacuses would not serve any purpose, except perhaps to save the trouble of copying the result of an arithmetic operation onto paper.) Perhaps that's what the OP was asking. I would estimate that it takes a human 1 to 10 seconds to execute an assembly language instruction, so the answer would require determining how many instructions a music generating program takes, and multiplying by that number. Human are of course vastly slower than computers in executing computer code -- a typical modern computer takes less than a nanosecond to execute an instruction, several billion times faster than the human. CodeTalker (talk) 00:17, 22 June 2017 (UTC)
On the same lines as the abacasacabasa might I suggest Mechanical Turing Machine in Wood which definitely does make a noise though one would probably need a number of them to produce music like The Floppotron: The Final Countdown. ;-) Dmcq (talk) 11:31, 22 June 2017 (UTC)
Usually, ll programming is assembler. A programming language very close to assembler is C. But, todays C on the PC it is full of included ressources, inflating each small program, sometimes with an overhead. For a real time application on the lowest level, the cycles of each CPU instruction can be counted. In RISC, it is usually all the same number of clock cycles per instruction. Interrupts trigger by a preset countdown to compensate an variable number of instructions in program flow. This occurs, in generating a variable frequency generator to the duration of a tone. Understanding it in this way, there's no big difference, in swapping a bit for pulse output or reading a sample from previous stored a wave sound. Splitting the tone data from the program code is the basic of a simple digital synthesizer, which is playing the sound data. More complex is MIDI and synthesizing different sounds per instrument and octave, also fading volume in and out. The basic loops for such program code are simple, but the human errors take the time. --Hans Haase (有问题吗) 08:48, 25 June 2017 (UTC)

June 22

Forced crop

Why some social networks, including Facebook, apply a forced crop of the uploaded avatars? If the size is an issue, wouldn't it be better to just autoresize them pixel-wise? Brandmeistertalk 08:02, 22 June 2017 (UTC)

Why do you think resizing is better than cropping? There's sites on the web which will resize for you if you like, just type something like 'resize photo' into Google and you find some. Dmcq (talk) 11:20, 22 June 2017 (UTC)
In these cases I think resizing is better, as it preserves all desired areas, while in cropping you're forced to choose what to include. If I want a crop, I can do it myself. Brandmeistertalk 13:23, 22 June 2017 (UTC)
One reason might be that cropping will consistently work on all graphics formats and sizes, while resizing can sometimes create artifacts (at least in my experience). Cropping might also require less storage space than resizing, if they only store the cropped image. OldTimeNESter (talk) 14:04, 22 June 2017 (UTC)
As well as details being lost if it resized then one would also have to choose between bars at the sides or top and bottom because of the different aspect ration. One really needs to allow both cropping and resizing to satisfy most people. One advantage of resizing would be that it could produce a number of versions with the resolution determined by the target device, that takes a bit more support but it isn't too hard to do efficiently with modern browsers.. Dmcq (talk) 14:15, 22 June 2017 (UTC)
Thanks. Brandmeistertalk 16:27, 22 June 2017 (UTC)
Do they? When you upload a Facebook avatar you don't have to upload it at some specific size.
I suppose you're complaining that Facebook forces your avatar to be square, instead of taking some rectangular image and just stretching it into the square box. Stretching like that would look really cheazy. People can always tell. And besides, it'll make people look fatter or thinner than they really are, making their face look different. ApLundell (talk) 14:34, 22 June 2017 (UTC)
I mean you are forced to select a limited area on your avatar with subsequent automatic crop by the website. By resizing I specifically mean autofitting of an entire image. Brandmeistertalk 16:27, 22 June 2017 (UTC)
But you aren't? I tried 1 minute ago and I can both crop (it needs to be square so cropping is semi automatic depending on the size) and resize (using the slider at the bottom). I have to select a square size thumbnail but I don't even have to keep the profile photo square, there is a skip crop button. (What this means is for both the crop and resize it shows in the thumbnail, but clicking on the profile picture will take you to the original photo. If you don't select it the profile picture will be the same as the thumbnail albeit possibly high resolution including I think upscaling to achieve a minimum res.) I'm using the desktop website so I can't say what the mobile app or website may do but it's definitely not required on Facebook as you implied. Nil Einne (talk) 16:57, 22 June 2017 (UTC)
BTW, by "avatar", I'm assuming you mean profile picture. If you mean something else, I don't know what since Facebook doesn't have anything else which seems like an avatar. It's possible the pictures shown in other areas (like chat) taken from the profile picture may be more cropped, I never paid much attention. Nil Einne (talk) 16:57, 22 June 2017 (UTC)
I had a quick look and AFAICS, both the chat and the thumbnail shown in place like next to your name on posts is not further cropped so yeah I'm fairly unsure what you're referring to. Nil Einne (talk) 16:59, 22 June 2017 (UTC)
It does seem the default option is to crop meaning the resize is not at the far left. Especially I think if it's a photo you are in and Facebook recognises you. Weirdly sometimes the resize bar shows at the far left but isn't, once you drag it it fixes itself. But yeah at least on the desktop site I seem to have no problem no cropping other than needed to be square and as said even that it only for the part shown in must circumstances the actual photo stays the same. The fact that the default is to crop does I presume mean if you don't get the option to resize you're SOL but it's definitely not forced in all circumstances. Nil Einne (talk) 17:06, 22 June 2017 (UTC)
Final test, the Android app seems to let you crop and resize using a typical mobile interface (pinching to zoom etc). The mobile site on Chrome Android does not seem to let you adjust in any way, you can't even select precisely where the square will be. You can use the desktop site on Chrome Android of course, which lets you adjust resizing (meaning turn off any both direction cropping) but you can't adjust the square (i.e. on direction cropping) due to the inability to drag or at least I couldn't work out how. If you have a browser which lets you do so, I guess it will work. I guess you must be using the mobile site (although weirdly not for wikipedia). Unfortunately mobile sites are often a lot more limited than the apps despite the promises of HTML5, probably not helped by the dominance of Android and iOS. Facebook is one of the better ones (e.g. notifications) but still I suspect they didn't think it was that important since many people probably just accept the default crop-resize option. Nil Einne (talk) 17:32, 22 June 2017 (UTC)
One final comment, since Facebook is known to roll out different features to different users depending on a lot of different things like geographical location and browser, I can't guarantee that you have the same option available. Still most complaints about this seem to have died out perhaps 2 years ago at least that I found. (It maybe started about 4 years ago when the scale to fit option disappeared?) And I'm not certain the mobile site actually resizes or crops other than to the square by default as I see it suggested as a solution. It sounds like the app has had the option to adjust zooming and cropping for a while when the desktop may have still been limited. Nil Einne (talk) 17:42, 22 June 2017 (UTC)
Actually reading a bit more I'm not sure how many of the complaints are about cropping in both directions or about forced one way cropping. I.E. the thing which a lot of people seem to be unhappy about is that for a while it sounds like using the desktop site the profile picture was cropped to a square no matter what. (Meaning you wouldn't get a non square image when clicking on it.) Nil Einne (talk) 17:48, 22 June 2017 (UTC)
It lets me resize just fine. The final image needs to be square, and it won't squish or stretch a rectangular image into a square. But If I start with a square image, it resizes to let me use the whole thing. (This is the web page I'm speaking of. I don't have the official app installed on my phone, so I can't test that.) ApLundell (talk) 19:20, 22 June 2017 (UTC)

Linking to github files with space in its name

If I have a file named "README.md" in my Github repo root, I can link to it within Github using the syntax:

   [my file](./README.md)

But sometimes filenames have a space in it, so when I have a file named "foo bar.txt" in the repo root, linking to it fails:

   [a filename with space in it](./foo bar.txt)

How could I make this work? (Other than the ugly workaround of replacing all spaces with underscore for all my files.) Scala Cats (talk) 20:07, 22 June 2017 (UTC)

The usual answer in Linux is to either enclose the filename with quotes, or to escape the space with \. I don't know if either of these will work with Github, however. OldTimeNESter (talk) 23:04, 23 June 2017 (UTC)

June 24

Array deconstrctors in Javascript ES6

In Javascript ES6, we can use array deconstrctors like so:

   > [key, value] = [1,2];
   [ 1, 2 ]

But using it in a lambda function doesn't seem to work:

   > const foobar = [[1,2],[3,4]];
   undefined
   > foobar.map((key, value) => console.log(key));
   [ 1, 2 ]
   [ 3, 4 ]
   [ undefined, undefined ]
   // Wrong results
   > foobar.map([key, value] => console.log(key));
   ... 
   ... 
   // Syntax error

Is there a way of getting it to work? Scala Cats (talk) 20:42, 24 June 2017 (UTC)

Security problems with weak wifi connection

At home, I have a router for my secured wireless network, and everything consistently works fine inside the apartment. Occasionally, I'll have reason to try to use it while sitting in my car outside, where I'm on the limit of its range; it tends to alternate between working-but-really-weak and not working at all. No surprise.

When I try to load a webpage and the network's too weak to work, the browser (latest IE) normally loads a "can't load this page" message, as I'd expect. However, occasionally it instead gives me a sort of security warning. Here's the most recent one:

Can’t connect securely to this page This might be because the site uses outdated or unsafe TLS security settings. If this keeps happening, try contacting the website’s owner.

This came when trying to load https://en.wikipedia.org/wiki/Donjon. Why would it claim a security problem instead of just saying that it couldn't load the page? Does a secure site require some sort of stronger connection than the absolute minimum, i.e. it's possible for the connection to be working while yet too weak to authenticate? Or perhaps the network was so weak that the router couldn't realise that the computer was properly connected to it? As I note above, this problem only arises when I'm on the edge of range, and nothing is wrong; I'm just curious. Nyttend (talk) 23:13, 24 June 2017 (UTC)

This would happen when the browser connects to the web site, but the initial security negotiation did not complete. So a failure during the TCP session. It probably timed out in the session or lost wifi connection during this phase. Another way to fail is if it tries to check the certificate and gets an error or failure connecting to the certificate authority. Graeme Bartlett (talk) 00:40, 25 June 2017 (UTC)

SD cards with secure elements

I found out about this kind of SD card (usually in a microSD form factor) a few months ago and I'd like to try one out. They seem to be like these new SIM cards that also have secure elements usable for NFC-related stuff, but I don't have a phone that uses SIM cards and I'd prefer an SD card because that way I'd have an easier time interacting with it on a general-purpose computer. Does anyone know where to find programmable ones, i.e., the kind that have not yet been programmed with an OEM's public keys and security settings? — Melab±1 23:58, 24 June 2017 (UTC)

June 25

Convert:.xls sheet → image

What's the easiest way to save a .xls file as an image? I'd like to use it a .xls file as a 1920x1080 wallpaper. I'm using Microsoft Excel 2016 on Windows 7. --Daniel Carrero (talk) 14:01, 25 June 2017 (UTC)

On Windows try a screen grab (PRINT-SCREEN) then do an Edit + Paste in MS Paint and trim off the borders. This means it won't quite be the max res of your screen. If you can set the max res above 1920×1080 for the screen grab, this could solve that issue. Once you have your image, save it in an image format and select that as the Windows background (do you know how to do that ?). StuRat (talk) 14:07, 25 June 2017 (UTC)
BTW, you wouldn't be an accountant, would you ? :-) StuRat (talk) 14:12, 25 June 2017 (UTC)
Thank you. I'm not an accountant. I'm trying to learn Japanese as my 3rd language. My .xls file is some kanji to remember. Portuguese is my 1st language, English is my 2nd. :) Daniel Carrero (talk) 10:48, 26 June 2017 (UTC)

June 26

Retrieved from "https://en.wikipedia.org/w/index.php?title=Wikipedia:Reference_desk/Computing&oldid=787601903"
This content was retrieved from Wikipedia : http://en.wikipedia.org/wiki/Wikipedia:Reference_desk/Computing
This page is based on the copyrighted Wikipedia article "Wikipedia:Reference desk/Computing"; it is used under the Creative Commons Attribution-ShareAlike 3.0 Unported License (CC-BY-SA). You may redistribute it, verbatim or modified, providing that you comply with the terms of the CC-BY-SA