Jump to content

Wikipedia:Reference desk/Computing: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
→‎VPN in other countries: referred to article
TheGrimme (talk | contribs)
→‎VPN in other countries: Provided response
Line 283: Line 283:


:Both. To add to complications, if you use the VPN in country B to perform illegal activity in Country C, you are also subject to the laws of country C. -- [[User:Kainaw|<font color='#ff0000'>k</font><font color='#cc0033'>a</font><font color='#990066'>i</font><font color='#660099'>n</font><font color='#3300cc'>a</font><font color='#0000ff'>w</font>]][[User talk:Kainaw|&trade;]] 16:23, 5 January 2012 (UTC)
:Both. To add to complications, if you use the VPN in country B to perform illegal activity in Country C, you are also subject to the laws of country C. -- [[User:Kainaw|<font color='#ff0000'>k</font><font color='#cc0033'>a</font><font color='#990066'>i</font><font color='#660099'>n</font><font color='#3300cc'>a</font><font color='#0000ff'>w</font>]][[User talk:Kainaw|&trade;]] 16:23, 5 January 2012 (UTC)
:I'm sorry that this won't help you, but [[Wikipedia:Legal_disclaimer|Wikipedia does not give legal advice]]. [[User:TheGrimme|TheGrimme]] ([[User talk:TheGrimme|talk]]) 16:27, 5 January 2012 (UTC)


::(e/c):This is a complex issue, and of course we cannot give you legal advice. I suggest you read [[Legal aspects of computing#Jurisdiction]].--[[User:Shantavira|Shantavira]]|[[User talk:Shantavira|<sup>feed me</sup>]] 16:25, 5 January 2012 (UTC)
::(e/c):This is a complex issue, and of course we cannot give you legal advice. I suggest you read [[Legal aspects of computing#Jurisdiction]].--[[User:Shantavira|Shantavira]]|[[User talk:Shantavira|<sup>feed me</sup>]] 16:25, 5 January 2012 (UTC)

Revision as of 16:27, 5 January 2012

Welcome to the computing section
of the Wikipedia reference desk.
Select a section:
Want a faster answer?

Main page: Help searching Wikipedia

   

How can I get my question answered?

  • Select the section of the desk that best fits the general topic of your question (see the navigation column to the right).
  • Post your question to only one section, providing a short header that gives the topic of your question.
  • Type '~~~~' (that is, four tilde characters) at the end – this signs and dates your contribution so we know who wrote what and when.
  • Don't post personal contact information – it will be removed. Any answers will be provided here.
  • Please be as specific as possible, and include all relevant context – the usefulness of answers may depend on the context.
  • 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 don't conduct original research or provide a free source of ideas, but we'll help you find information you need.



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.
See also:


December 31

"find" in firefox browsers

When I try to "find" a string, the scroll-bar ends up so positioned that the string I'm searching for is on the lowest line in the window. If a human did that, I'd consider it rude at best. Is there a way to make it appear on the middle line? Michael Hardy (talk) 00:11, 31 December 2011 (UTC)[reply]

I don't like that either. If you do a "Previous" find, it puts the line at the top, which is a bit better. StuRat (talk) 00:17, 31 December 2011 (UTC)[reply]

First result for a search of 'firefox addon find middle': https://addons.mozilla.org/en-US/firefox/addon/find-to-center/ ¦ Reisio (talk) 01:20, 31 December 2011 (UTC)[reply]

Is this fast enough to run Battlefield 3?

I am purchasing a new Dell XPS 15 laptop with the following customized specs:

  • 2.2 Ghz i7 2670-QM
  • 8 Gb, 1333 Mhz RAM
  • nVidia GeForce GT 540M 2 gb
  • Windows 7, 64-bit

This should be fast enough to run BF3 right? What kind of fps can I expect? Acceptable (talk) 01:17, 31 December 2011 (UTC)[reply]

Yes, & significantly more FPS than the human eye is physically able to distinguish. ¦ Reisio (talk) 01:19, 31 December 2011 (UTC)[reply]
Well, that's better then me, welp. Thank god I'm getting a new video card in a couple of days. ResMar 02:33, 31 December 2011 (UTC)[reply]
I'm not so sure. I think you're skirting the minimum system requirements (PROCESSOR: 2 GHZ DUAL CORE (CORE 2 DUO 2.4 GHZ OR ATHLON X2 2.7 GHZ)...WITH ATI RADEON 3870 OR HIGHER PERFORMANCE))... Your 520M benchmarks just below the 8800 GT and above the ATI 3870... so I don't think you'll be at the highest end of the curve. That's a beast machine for a laptop, but BF3 has some high requirements. Shadowjams (talk) 22:14, 31 December 2011 (UTC)[reply]
I don't know much about mobile GPUs but the OP said they had a 540M not a 520M. A quick search suggests this probably has double the number of shaders of the 520M and probably double the memory bandwidth so the performance difference is likely to be quite big, likely over double. If you really meant the 520M then I would I guess it's significantly faster then the 8800GT although must still be below the recommended (but the recommended sound a bit insane) Nil Einne (talk) 11:09, 1 January 2012 (UTC)[reply]

Helping MS SQL 2000 trying to understand how to do this

Hi,

I've got two huge tables Sales and Events containing something like things clients bought (this is not really what happens but this example matches the real situation). Events looks like:

eventid, clientid, datetime

Sales contains:

eventid, productid, price

So a Sale is one of the events that can happen to a client. To get all sales for client 12345 we're using a query like this:

select * from sales where eventid in (select eventid from event where clientid=12345)

Obviously a JOIN would be a much better solution, but translating our internal query language to SQL is much easier this way, and MS SQL seems to understand that it's actually supposed to JOIN when I look at the Estimated Execution Plan. This query is done in 30 milliseconds.

Now I want to know: at what prices did client 12345 buy product 678. What SQL seems to think is that it's much faster to find all Sales for product 678 and after that do the difficult join to find out which records apply for client 12345. Unfortunately, this a very slow (3 seconds+) strategy as nearly every client bought 678, but a normal client only bought a couple of items. It would be much faster to find the 20 or so sales for client 12345 and then filter for the product.

Is there anyway I can help SQL understand this? I've been looking into "hints", but I can't find a hint like "filter on this first". All possible indexes are there, and all statistics have been updated.

Txs! Joepnl (talk) 02:38, 31 December 2011 (UTC)[reply]

Just to be clear, the slow SELECT is like this, right ?
 select price from sales 
  where productid = 678
    and eventid in 
(select eventid from event 
  where clientid = 12345)
If so, you might try reversing the order:
 select price from sales 
  where eventid in 
(select eventid from event 
  where clientid = 12345)
    and productid = 678
If that doesn't help, then an actual JOIN may be the only cure, or perhaps you could do the query without the productid WHERE clause, and put the results into a temporary table, then apply that clause to the that table. StuRat (talk) 02:47, 31 December 2011 (UTC)[reply]
Here are a few additional suggestions. I assume that there are already indexes defined for eventid and productid and that the query optimizer is selecting the productid index.
  • Try creating an single index on the sales table for both productId and eventId. (create index ix_sales_eventid_productid ON sales(eventid, productid)). You might already have separate indexes for each column, but the SQL optimizer can only select one and may be choosing the productid index. Having an index with both columns may yield the most efficient access.
  • If you can't alter the database schema, you can force selection of an existing index using the with-index hint like "...from sales with(index(ix_sales_eventid))...".
  • If you would prefer to avoid using index hints, you can make the productid look up less index-friendly by altering the expression to something like productid+0 = 678 or abs(productid) = 678. That will force the query optimizer to ignore the productid index and favor the eventid index.
Hope this helps. -- Tom N (tcncv) talk/contrib 18:42, 31 December 2011 (UTC)[reply]

Flash drive

I got my first flash drive ... and promptly screwed up. The second time I copied some files to it, I yanked it out without selecting eject. All of the files and folders are gone (no permanent loss). My question is, have I damaged the drive, or can I go ahead and transfer the files again? Clarityfiend (talk) 02:00, 31 December 2011 (UTC)[reply]

You probably didn't damage it. Give it a try. StuRat (talk) 02:55, 31 December 2011 (UTC)[reply]
I'd have thought that if there is nothing recoverable on it, and it may possibly be corrupt, reformatting it might be a good idea? What do others think? AndyTheGrump (talk) 03:10, 31 December 2011 (UTC)[reply]
(e/c) Agree (with both), but I'd be a little wary. That 'eject' function is a bit of a gimmick in my experience, at least on Windows computers - it's like a safety mechanism to check that the drive isn't actually in use, but provided you have nothing open in an application, copying, saving, etc, then just yanking it out like that shouldn't do anything; it certainly shouldn't wipe everything on the drive. I'd test it out with some unimportant files for a while to make sure the drive itself isn't faulty. Also, I don't mean to sound presumptuous, but are sure you ever really had the files/folders on there in the first place? It's just that I've been using these things for many years and have seen them yanked out on hundreds of occasions without that happening. --jjron (talk) 03:14, 31 December 2011 (UTC)[reply]
Yes, I'm sure. It happened the second time I transferred files over. The stuff from the first time was there. Clarityfiend (talk) 04:15, 31 December 2011 (UTC)[reply]
Uh oh. I formatted it (it went extremely fast). Then, when I tried to add a new folder, it said "Could not find this item. This is no longer located in <%NULL:Optext>. Verify the item's location and try again. Lexar" Clarityfiend (talk) 04:21, 31 December 2011 (UTC)[reply]
Try formatting again, but make sure you untick "Quick format" in the format dialogue box to get a full format. After that I'd personally restart the computer, and try another flash drive in it if you have access to one, just to make sure it's not just the computer. Then try this drive on a different computer (again checking if it's the drive or the computer). Then take the damn thing back to the shop and swap it over, as I personally suspect the drive is faulty (and FWIW I wouldn't get Lexar, I tend to either buy Sandisk or (previously) Kingston, but I don't mean to sound like a consumer advice service or something so I won't actually recommend any particular brand). --jjron (talk) 05:05, 31 December 2011 (UTC)[reply]
Hmmm ... I rebooted, stuck it in a different slot, and got my stuff back. Clarityfiend (talk) 05:21, 31 December 2011 (UTC)[reply]
"Eject" is there because modern operating systems (for the last 20 years or so) cache disk writes. If you yank a drive out without stopping it then any unwritten cached data has nowhere to go. Actually, Windows disabled disk caching on USB devices by default some time ago because of people's tendency to yank them out without stopping them, so that probably isn't your problem. But in the future you could make your USB devices faster by enabling disk writeswrite caching (it's in the device properties), as long as you remember to eject them. -- BenRG (talk) 06:13, 31 December 2011 (UTC)[reply]
Enabling disk writes ? You must mean delayed writes. I don't care for that option. My goal is to make things quick and simple for me, not the computer, and having to pick eject makes it worse. StuRat (talk) 16:33, 31 December 2011 (UTC)[reply]
Well, the point is to make things faster overall (and maybe also extend the life of the flash drive a bit, if it is one, by reducing the number of redundant writes). -- BenRG (talk) 08:14, 1 January 2012 (UTC)[reply]
As far as faster overall, I'm a bit skeptical, once the time to "eject" is included, and perhaps some allowance for time wasted when you forget to eject properly. StuRat (talk) 00:24, 2 January 2012 (UTC)[reply]
I don't need that much speed, but thanks all. Clarityfiend (talk) 08:11, 31 December 2011 (UTC)[reply]
Please note that there are fake USB flash drives that claim to have a multiple of their actual capacity, writing more data than what they can really store will cause failures, garbage data, etc. You might want to check if the drive is genuine. Look for a tool called h2testw from Heise/c't (a renowned German computer magazine). The tool is available in German and English, so no need to learn German first. ;-) -- 188.105.112.97 (talk) 15:25, 2 January 2012 (UTC)[reply]

Running on the battery

I bought an Asus laptop last July which came with Win7. A couple of months ago I installed Ubuntu to dual boot. I've discovered that if, while in Windows, I unplug the power supply and use battery power it says there is 98%. However, in Ubuntu when I unplug it I get a warning that there is insufficient power in the battery and the computer will hibernate. If I plug the power back in I can see that the battery has 98% power left before it shuts down. Any suggestions? CambridgeBayWeather (talk) 08:08, 31 December 2011 (UTC)[reply]

looks like a bug. try ubuntuforums.org for the specialists in this. good luck! Staticd (talk) 13:53, 31 December 2011 (UTC)[reply]
Thanks. CambridgeBayWeather (talk) 16:11, 31 December 2011 (UTC)[reply]

Ad-ID

Friends- In your reporting re. Ad-ID your refer to the idea that Ad-ID is a descendant of the "International Standardized Commercial Identifier" or something close to that.

Since I (a) created ISCI in 1969,

       (b) proposed it to the AAAAs in early 1970, 
       (c) prepared its first publication for the AAAA's announcement of ISCI's "birth" in Spring 1970, 
       (d) supervised its use by the industry from ISCI's debut, 01JL1970, 
       (e) was its sole "operator" through 31JA1974 when I retired after 23 years with 
                Leo Burnett Advertising (VP-Broadcast Business) and 
       (f) continued to single-handedly operate ISCI until the end of 1992 when I sold the 
                majority (96%) of ISCI coding to the AAAA's and the National Association of Advertisers -   

perhaps you will allow me to correct your name (above) to "Industry Standard Commercial Identification".

Although I see that the AAAA's and Ad/ID (which was built upon the ISCI system) announced several years ago that ISCI was being retired, they were possibly in breach of contract unless they made it clear that they were only retiring the 96% of the ISCI codes which they owned. I did not see the announcement. I'm now 97 years of age and at that time was caring for both my bride of 69 years and my 100+ year-old-sister. I hope you will correct the name.

FYI: Incidentally, I will shortly provide Wikipedia with the details regarding "Dole Dating" - a copyrighted dating system I created in 1998 and have urged many to adopt with no fear of copyright infringement. It is the briefest possible foolproof method of expressing dates.

Alors,

David W. Dole — Preceding unsigned comment added by 206.72.27.52 (talk) 09:11, 31 December 2011 (UTC)[reply]

Hi David - This is the Wikipedia Reference Desk, a section of Wikipedia where people can come to ask questions, and random strangers on the Internet answer them. You can go and actually edit the Ad-ID and International Standardized Commercial Identifier articles yourself, but note that personal recollections are not a great idea to add to Wikipedia articles; they will probably be challenged as "Original Research" and removed. Wikipedia articles' statements are pretty much supposed to have references to published "Reliable Sources", top to bottom. Leave me a note on my talk page if you need help. Comet Tuttle (talk) 19:51, 1 January 2012 (UTC)[reply]

mymax wireless router not turning on.

I was going to use my computer today and saw that the wireless network was not working. Tried to see what was the problem and saw that my mymax wireless router power led is off. Tried to plug it on and off again without sucess. What can be the problem?201.78.191.84 (talk) 12:35, 31 December 2011 (UTC)[reply]

Start with the obvious: try plugging something else into the same power socket. Does that work? If not you need to fix the power supply. If so, you need to fix or replace the router.--Shantavira|feed me 13:32, 31 December 2011 (UTC)[reply]

C won't compile

NOTE: Sorry about the formatting of the code if someone can fix this please do so.

#include <stdio.h>
#include <math.h>

int isPrime(int x);

int main(void)
{
  ...
}

int isPrime(int x)
{
  int i;
  for (i=2; i <= sqrt((double)x); i++)
    if (x % i != 0)
      return 0;
  return 1;
}

So I've written this program to check whether a number is prime but it won't compile and it has someting to do with the sqrt(). I get a message saying "...: undefined reference to 'sqrt'" "collect2: ld returned 1 exit status" --178.208.197.58 (talk) 18:39, 31 December 2011 (UTC)[reply]

You're not linking with the math library. On unix/linux with gcc, you'd say gcc foo.c -o foo -lm
The same (with slightly different compiler options) will be true for other platforms and compilers like Windows, but I don't have the specifics to hand. -- Finlay McWalterTalk 18:45, 31 December 2011 (UTC)[reply]
Another option is to rewrite it without the square root function. In some languages a square root can be rewritten as X**(0.5) or X^(0.5). However, in this case, you might be better not to use a square root at all, since it's CPU intensive. Instead of "i <= sqrt((double)x)", how about "i*i <= x" ? Those statements should be identical for positive numbers (other than different overflow/underflow issues), but the second is far quicker.StuRat (talk) 18:56, 31 December 2011 (UTC)[reply]
StuRat's idea is excellent for yet another reason: it avoids comparing an integer to a floating point number. When comparing integers, "<=" is guaranteed to do what you expect it to do, which is not necessarily the case when one or both of the, whataretheycalled?, comparands is floating point. For instance, if x=25, then sqrt((double) 25) may be represented by a number slightly smaller than 5, in which case the loop would stop at i=4, and the program would give a wrong answer. Not sure whether this is an issue in practice with these particular numbers, but it's good to be aware of the pitfalls of floating-point arithmetic. --Wrongfilter (talk) 02:42, 1 January 2012 (UTC)[reply]
In terms of optimization, StuRat's idea does have the disadvantage of requiring the computation of i*i for every iteration, whereas sqrt(x) could be computed only once. Are any C compilers smart enough to know that sqrt() always yields the same result for a given argument (that it is deterministic solely based on its argument) and thus optimize the code, or would the code always have to be rewritten to take this advantage? Also, one way to avoid the floating-point arithmetic problem is to use an integer square root function. -- ToE 04:30, 1 January 2012 (UTC)[reply]
If the goal is efficiency then many compilers will realize that sqrt((double)x) is constant during the loop and only compute it once, while i*i would have to be computed each time. If you want to be certain of this speedup then introduce a new integer variable n=sqrt((double)x) before the loop, and say i <= n in the loop. Most floating point computations will probably follow the IEEE 754 standard where I think sqrt(i*i) == i for non-negative integers is certain if i*i can be precisely represented, but you can also make certain with n=sqrt((double)x+0.5).
An efficient program could of course make other speedups, for example not testing even factors above 2. For large numbers there are far more efficient algorithms than trial division, but fast primality testing algorithms can be complicated. PrimeHunter (talk) 04:32, 1 January 2012 (UTC)[reply]
A compiler computing sqrt((double)x) before the loop is an example of loop-invariant code motion. PrimeHunter (talk) 04:42, 1 January 2012 (UTC)[reply]
C does not have a "to the power of" operator. It has a "to the power of" function, pow(), but using it won't help at all in this case, as it also requires the math library, and suffers from the same problem with comparing integers to floating-point numbers as User:Wrongfilter mentioned. Using i*i <= x is the best way to go, in my opinion. JIP | Talk 08:37, 1 January 2012 (UTC)[reply]
Although really we've (hopefully) fixed the OP's problem, we've gone off on an optimisation tip. In that vein, I've benchmarked the two optimisations proposed (for the same naive prime-test algorithm). The code is here. The results aren't quite what I'd expected, and I'd appreciate it if others, with different platforms, would test it to see what effect that has. There are three versions:
first.c - based on OP's code
second.c - use i*i rather than a sqrt
third.c - one sqrt, to save a multiply per iteration
I'm testing 12764787846358441471, which I found online; I've had to resort to working in 64 bits, as 32 bit primes are tested so quickly (even on my old machine) that it's hard to benchmark properly. Performance is:
first: 197 seconds
second: 150 seconds
third: 134 seconds
This shows us some interesting things:
  • The sqrt isn't removed by loop invariance (which was enabled) - otherwise first and third would take the same time. This must be because the compiler doesn't know that sqrt is a pure function, presumably because the library doesn't mark it with the GCC pure function attribute. I'd be interested to know if the same code, compiled on other platforms, does get this optimisation from the compiler.
  • I'm surprised the saving of second over first isn't much greater. I don't know if that's because sqrt is rather efficient, but I suspect that the results are being impared because I'm having to use uint64_t on a 32 bit machine (with all the concomitant heavy lifting that entails). I'd be interested to know if the ratios hold when compiled and run on a real 64 bit platform.
-- Finlay McWalterTalk 14:19, 1 January 2012 (UTC)[reply]
Incidentally that was gcc 4.5.2, gnu libc 2.13, on 32 bit Intel Linux. -- Finlay McWalterTalk 14:36, 1 January 2012 (UTC)[reply]
My results are:
first: 28 seconds
second: 26 seconds
third: 26 seconds
That's gcc 4.1.2, x86_64-redhat-linux, gnu libc 2.5 if I'm not mistaken (newer computer, older system, apparently). --Wrongfilter (talk) 14:44, 1 January 2012 (UTC)[reply]
If the goal is benchmarking the SQRT function versus alternatives, I suggest removing all code not needed for the test, to maximize the relative effect of the SQRT. StuRat (talk) 00:19, 2 January 2012 (UTC)[reply]
I vaguely recall from having met this situation before that optimizing the sqrt call is slightly harder for the compiler than it seems at first glance. The error reporting behavior depends on mode flags that can be changed at runtime, and the compiler doesn't know what flags will be in effect with the code runs. It can't move the sqrt out of the loop unless it knows there will never be an error (i.e. negative argument), or that the error handling will never have any side effects that matter to the next iteration of the loop. 68.60.252.82 (talk) 04:28, 2 January 2012 (UTC)[reply]
Our modulo operation article states that where constant is a power of two, compilers will typically rewrite expression % constant as expression & (constant-1), but that otherwise many compilers will compute the integer quotient x / i in the process of computing x % i. Are any optimizing compilers smart enough to recognize when both x % i and x / i are used within a loop and compute the latter only once, thus doing the division for free? If so, would that encourage writing a trial division primality test as follows?
        int isPrime(int x)
        {
          int i = 1;
          if(x == 2 || x ==3)
            return 1;
          if (x % 2 == 0)
            return 0;
          do {
            i += 2;
            if (x % i == 0)
              return 0;
          } while (x / i > i);
          return 1;
        }
-- ToE 04:23, 2 January 2012 (UTC)[reply]
This depends completely on the assembly used. I would expect that, when in assembly, this would use a conditional jump for the do loop. Then, you put i in a register. Add 2 to it. Move the result to the i register. Put x in a register. Perform x/i, getting x/i and x%i in two registers. Do a conditional return. Perform x/i, getting x/i and x%i again. Do a conditional jump. Because the second x/i doesn't change a variable, it would be rather easy for an optimizer to move the second x/i before the conditional return. Then, the optimizer would easily see two x/i's in a row. Of course, having an optimizer realize that it can move the x/i before the conditional return is the big trick. I am certain that the gnu compiler will recognize that it is possible because it does shuffle things that don't change variable values rather easily. -- kainaw 20:25, 2 January 2012 (UTC)[reply]
Note that x % 2 is defined to return -1 when x is a negative odd integer. This means that it will usually generate less efficient code than x & 1, since the compiler has to check for that case. On the other hand, x % 2 == 0 is the same as (x & 1) == 0.
I did some tests with Microsoft C++ version 16.00.40219.01 for x86 with the /Ox flag. For x %= 2 it produces more or less the following:
            x &= 0x80000001;
            if (x < 0)
                x = ((x - 1) | 0xFFFFFFFE) + 1;
For x %= 3 it produces:
            unsigned long long y = x * 0x55555556ULL;
            x -= ((y >> 63) + (y >> 32)) * 3;
(Multiplication is a lot faster than division.) It doesn't convert x % 2 == 0 to (x & 1) == 0. However, gcc 3.4.4 and 4.5.3 for Cygwin with -O2 do make that optimization. All three compilers do just one division per iteration in ToE's code, meaning that it is probably the most efficient implementation of trial division. Funny that I never thought of it before. -- BenRG (talk) 21:21, 2 January 2012 (UTC)[reply]


January 1

fuses that can be attached to a printed resistive heating device so as to maintain a temperature range ie: 100 degrees F

Looking to improve temperature control over a printed resistive heating device. Have been testing using a themistor type system, but am looking for added protection. — Preceding unsigned comment added by 99.155.19.96 (talk) 09:51, 1 January 2012 (UTC)[reply]

this looks as complex as the question ;-) fredgandt 10:18, 1 January 2012 (UTC)[reply]

malfunctioning header and footer in HTML file

Resolved

I’m maintaining a web site in which each file invokes header.htm and footer.htm, which of course provide the header and footer information for the pages on the site. My skill in HTML is not great; mostly I use Front Page and only go into the code to make small changes. I’ve never attempted to change the header/ footer files.

Yesterday, the content files I changed appeared on the web with no header/footer. Investigating, I found the header/footer files missing on my computer but still present at the web site. I don’t know how they came to missing; I’m the only one who uses this computer. I transferred header/footer back to my computer, re-saved the content files and transferred them back to the web. But the header/footer are still missing. What can be going on? --Halcatalyst (talk) 17:23, 1 January 2012 (UTC)[reply]

What language is the scripting in? E.g. how are you invoking the header/footer pages. (Pure HTML cannot invoke other pages, so there must be something else going on here.) --Mr.98 (talk) 17:53, 1 January 2012 (UTC)[reply]
  • The language is Javascript.
  • I forgot to add that there are differences in the code between the successful and unsuccessful “compilations.” I give that for the header.
Good: ...!--webbot bot="Include" U-Include="header.htm" TAG="BODY" startspan --> / <div align="center">...
Bad:...<!--webbot bot="Include" U-Include="header.htm" TAG="BODY" startspan --> / <strong>[header.htm]</strong><!--webbot bot="Include" i-checksum="4229" endspan --> / <div align="center">...

--Halcatalyst (talk) 18:10, 1 January 2012 (UTC)[reply]

Mmm, that's not Javascript. It appears to be some kind of FrontPage markup language. Perhaps there is someone who knows FrontPage who can help... --Mr.98 (talk) 21:45, 1 January 2012 (UTC)[reply]
The problem is that the files went missing on your computer, not your server? Do you use Filezilla? An inadvertent double click somewhere could have deleted the files from you computer. Or am I getting the wrong end of the stick? fredgandt 22:09, 1 January 2012 (UTC)[reply]
  • I'm using FrontPage and Filezilla as well, and yes, the files were missing on my computer, not on the server, from where I recovered them. Not sure if the temporary loss of those files is related to the current problem.
  • I wonder: how does FrontPage "include" files? In the code of the "content" files I can see header-related material, but it's not the same as in header.htm. The code above is from the content file, not header.htm. --Halcatalyst (talk) 01:12, 2 January 2012 (UTC)[reply]
FrontPage must run some sort of processing to manually make the include work, unless there is something server side that does it. I suspect that somewhere in this issue lies the problem — you're manually uploading files that need to be rendered or managed by FrontPage first. --Mr.98 (talk) 14:35, 2 January 2012 (UTC)[reply]
I managed to make one page work by replacing (with a few tweaks) the header and footer code with that of a page that worked. It was obvious that the code was corrupted; by comparison, there were huge gaps. To check whether FrontPage was then altering the code, I brought up the file in FP, inserted some text, saved, and FTP'd the file to the server. It worked fine.
Another editor I've had trouble with is KomPozer. It would intermittently foul up image paths (also in the header, but images that were used in menu items, so quite annoying. I figured out how to fix these -- KomPozer was sometimes changing the relative path to the absolute path on my computer.. Once I understood the situation, I could fix the problem easily, but it was, as I said, annoying. So I stopped using KomPozer and went back to FrontPage, which I had been using for a long time. I might try Kompozer again, with the known bug, and see if the current problem reappears.
Meanwhile, back to the remaining problem files, to see if the straightforward but tedious method will work for all. --Halcatalyst (talk)

The corrupted files on the site are now repaired and all is well. Thank you for your comments. --Halcatalyst (talk) 22:12, 2 January 2012 (UTC)[reply]

Laptop Purchase

Resolved

Hi, Not sure if this belongs here, but I am looking at buying a new 14" laptop in Canada for around $400. I'm planning to use it in class (high school), and around the house for web browsing, video watching, and hopefully some gaming too. I've pretty much narrowed it down to two options, an HP with 4GB of RAM and an AMD Quad-Core A6-3400M processor. [1] The other option is not available online but is an Acer with 6GB of RAM and an Intel Core i3-370m processor. It seems to me to be a tradeoff between the extra RAM on the Acer and the better processor and integrated video on the HP. I am computer literate (I've published applications on the Android Market, etc.), but I am not sure which one to go for. Any suggestions? Thanks, 99.240.226.174 (talk) 17:54, 1 January 2012 (UTC)[reply]

If you are planning any serious gaming, I would recommend that you focus on the graphics capabilities. Memory is easily upgradable, but most other laptop components are not. 24.254.222.77 (talk) 18:53, 1 January 2012 (UTC)[reply]
That's true. HP's product spec page says that it's upgradable to 8GB by yanking out the old 4GB DIMM and inserting a new 8GB one, so eventually you can get more RAM if that is needed. I would not say this is a "serious gaming" laptop, though, because video RAM appears to be shared with main RAM. Comet Tuttle (talk) 19:45, 1 January 2012 (UTC)[reply]
If you're going to be moving it around a lot, which it sounds like you are, you should check the respective weights of the laptops (the HP is 2.12kg). If one is significantly heavier, you may regret having to lug it around for the next few years. There's always a tradeoff to be had - between portability, performance, and price. -- Finlay McWalterTalk 19:53, 1 January 2012 (UTC)[reply]

You saying they're the same price? What's the graphics device on the Acer? ¦ Reisio (talk) 23:19, 1 January 2012 (UTC)[reply]

OP here. Thanks for the help: I decided to go with the HP, on the principle that RAM is more easily upgraded than a processor. For the record, the Acer had only an Intel Graphics 3000. Thanks, 72.136.170.188 (talk) 03:31, 2 January 2012 (UTC)[reply]

Keyboard layout defaults to English/US on Fedora 14 Linux

Now that I've upgraded to Fedora 14 Linux, I have found that my keyboard layout defaults to English/US instead of Finnish. I specifically configured the original Fedora 12 system to use the Finnish layout, and I didn't change that when upgrading to Fedora 14. But still, when I boot up the computer, and try to enter the letter ä, the computer prints an apostrophe ('). (The "ä" key on the Finnish layout is two keys right of the "l" key.) When I go to keyboard preferences and select the "layout" tab, there are two options listed: "Finnish" first and "English/US" second. After I delete the "English/US" option, the keyboard starts working with the Finnish layout as normal. But when I reboot the computer, the problem comes back. How can I make this setting permanent? JIP | Talk 19:45, 1 January 2012 (UTC)[reply]

You'd really get more Fedora help on IRC: http://webchat.freenode.net/?nick=JIP&channels=#fedora ¦ Reisio (talk) 20:10, 3 January 2012 (UTC)[reply]


January 2

Research design for IT PhDs

I'm interested in the sorts of research design used in IT for PhD students. You have to contribute something new, but say your research involves coding something - how do you evaluate it to show it is new? Do you show that no one has ever been able to write such a program before that does such and such? Or do you show that it does the same thing as another program, but using less disk space, or else what? I'm enrolled in a PhD in IT, but having trouble refining the topic, as I know how to program alright, but I haven't had much formal training in the discipline as it works in academia. Thanks in advance, IBE (talk) 10:47, 2 January 2012 (UTC)[reply]

In general the way you show something is new, in academia, is to show that you are aware of the state of the art and its deficiencies and limits, and that your work is just beyond those. It's not unlike how it works on patents — "My product, product X, is meant to do A, B, and C. Products Y and Z can do limited versions of A and maybe C, but are deficient both because they don't combine these elements together, but also totally omit B, which is obviously a good idea." As for the exact form, or the exact state of the art you should be showing mastery of, that's what advisors and peers are supposed to be helping you with. Your advisor should be helping you figure out what is the level of originality you need to achieve for them to be happy (and thus sign off on the work) — whether you have to re-invent the wheel, or whether you just need to optimize it a little bit. --Mr.98 (talk) 14:24, 2 January 2012 (UTC)[reply]
If computer science counts as IT, the answer is that coding (as traditionally understood) isn't really a core part of the research process. It's an excellent idea to write code, as a sanity check and as a way to evaluate the practicality of one's ideas, but the products that people produce are generally more mathematical constructs than code (though it's possible to be both). You evaluate these constructs by the features they support, their simplicity, and sometimes even by their performance (as measured in big-O notation). Paul (Stansifer) 17:16, 2 January 2012 (UTC)[reply]
It would also be a good idea to look at some previously defended dissertations at the same field and, if some are being defended nearby, to observe a defence or two. --Martynas Patasius (talk) 19:52, 2 January 2012 (UTC)[reply]
Code is not new. It never ever is new. It is like claiming a sentence is new. It just a collection of words other people have been using for many generations before you. What is (or may be) new is the algorithm that the code implements, just as a poem made with words may be new. So, the thesis is on the algorithm, not the code. The following is how I developed my PhD thesis, which was an algorithm, which I also implemented with code in two programming languages:
First, I had my idea. That was useless. Everyone has ideas. I had to check with experts (professors and researchers) to figure out what fields of research I was touching on. There were a lot of them. I had to read a lot of books and research papers and then I was interviewed by my PhD committee to ensure that I was competent in all of the fields my algorithm was based on.
Next, I had to write a survey paper. This was designed to do three things. It had to show that I had a complete understanding of all the algorithms and theories I was planning to use. It had to explain to anyone else who was going to read the paper how those algorithms and theories related to my goal. Finally, it had to explain exactly why I believe that my algorithm is worth working on. I had another interview with my PhD committee to prove that I knew my stuff and my algorithm was novel and new. That was a very hard interview because everyone on the committee has the goal of finding any fault of any kind in my plan. It is hard to defend against a large group that are all against you.
Finally, I had to write my thesis. My survey paper became the background (much shortened). Then, I explained the algorithm in detail. Then, I explained how it was implemented. Then, I explained how it would be tested - and more importantly, why those tests are the best and most valid tests. Just to be complete, I showed the results of the test - which must be good or the thesis wouldn't be published. So, that is a very short section. In the end, I explained different ways in which this algorithm would be beneficial to other areas of research. The last step is publishing that paper and defending it against attacks from the PhD committee.
Hopefully that helps. What you really need to do is discuss this with your committee. They know what they want and they could care less what my committee wanted. -- kainaw 20:18, 2 January 2012 (UTC)[reply]

Thanks - these replies help a great deal. I know to ask my supervisors, but they are on holidays, and I also can't sit there chatting about how the discipline works in general in academia - and I always get good replies here. In fact, I come to Wikipedia when I'm at my wits' end, and it at least restores my sanity, so thankyou. Note that the stuff about my personal situation wasn't the exact question, just background to help focus the answers - the questions were as listed, and about the general situation, so you've given a lot of help. Any more info is much appreciated. IBE (talk) 08:45, 3 January 2012 (UTC)[reply]

rsync not working as expected

Hi, I was trying to consolidate several backup generations using rsync's hardlink ("--link-dest=") feature, to save some space.

What I have:

/oldbackupdir
/oldbackupdir/backup0
/oldbackupdir/backup1

What I am trying to create:

/newbackupdir
/newbackupdir/backup0
/newbackupdir/backup1

With the difference that files that are identical between backup0 and backup1 will be hard-linked.

Step 1:

rsync -aPv /oldbackupdir/backup0/ /newbackupdir/backup0/

Step 2, try #1:

rsync -aPv --link-dest=/newbackupdir/backup0/ /oldbackupdir/backup1/ /newbackupdir/backup1/

And this is where everything breaks: I'm not getting any hardlinks, even though I know some files are identical (same md5sum).

Step 2, try #2:

rm -rf /newbackupdir/backup1/ # Clean everything up for a new attempt
rsync -aPv --link-dest=../backup0/ /oldbackupdir/backup1/ /newbackupdir/backup1/

I read somewhere that one should use relative path names for link-dest, but it doesn't help, either.

Step 2, try #3+4: Repeat the above two steps with rsync -aPvc --link-dest=, as the file creation/modification times might be different between the backups, but the md5sums are the same for identical files between backup generations, and -c should switch from time/date-dependent to md5sum-dependent detection.

Same result though, no hardlinks. :-(


Step 2, try #5:

rm -rf /newbackupdir/backup1/ # Clean everything up for a new attempt
rsync -aPv --link-dest=../backup0/ /oldbackupdir/backup0/ /newbackupdir/backup1/

Intentionally copying the wrong (backup0 instead of backup1) source to the backup1 directory does create hardlinks.


What the heck am I doing wrong? -- 188.105.112.97 (talk) 15:48, 2 January 2012 (UTC)[reply]

Green and blue look fine on my laptop.

The red, however, isn't red enough, and counter-intuitively for me resulting in a slightly purplish look where it should be white or gray, especially gray. Store's run out of the model, but I can still return it Great price though, and a rare matte. What should I do? 66.108.223.179 (talk) 20:39, 2 January 2012 (UTC)[reply]

Use a color management system to calibrate individual gains for red, blue, and green channels. If your laptop runs Windows, use the Windows Color System tool, already installed on your system. Additional technical documentation is available from Microsoft's WCS page. If you are running a different type of system, let us know and we can help you find another solution. Nimur (talk) 21:15, 2 January 2012 (UTC)[reply]
If everything looks purplish, that likely means you don't have enough green (or have too much blue and red). So, try adjusting those levels accordingly. Under Windows, Start + Control Panel + Display may have some settings for color adjustments, depending on the graphics card, driver, and OS level. There may also be an icon with a picture of the monitor, down by the volume control, etc., which might allow for color adjustments. StuRat (talk) 21:45, 2 January 2012 (UTC)[reply]
If no adjustments produce the right "red" color, it may be a hardware issue relating to your graphics card or monitor. It's often a tell-tale sign that something's not working right if either the red, green, or blue suddenly short out. I've had cables where the red was totally defunct and only blues and greens were coming through. --Mr.98 (talk) 01:30, 3 January 2012 (UTC)[reply]
If the problem is with your laptop screen and a particular primary color isn't coming through, I would assume the problem is with a short in the internal video card or a lose connection. If you do some Googling for your notebook model with the keyword "Disassembly" you should be able to find a guide for accessing the video cable. Try wiggling it around while grounded with the computer on to see if the color comes back.
If the problem is with an external monitor, do a similar wiggling thing for your VGA/HDMI cable. TheGrimme (talk) 16:07, 3 January 2012 (UTC)[reply]

January 3

Wikipedia-related blog aggregators

For the last few years, I've enjoyed keeping up with Wikipedia-related blogs at Open Wiki Blog Planet. I view it daily in my browser. However, for the last six months or so, the site has very irregularly updated - perhaps about once a month. I don't think this is a caching issue on my end. Does anyone know what the problem is with the site, or suggest any change I can try on my end? What alternative compendiums of WP blogs are there? I am already aware of Planet Wikimedia.-gadfium 00:38, 3 January 2012 (UTC)[reply]

Pop up blocker for specific site?

I have an Imac and I use the latest version of Firefox with pop-up blocker on but it only works sometimes. Some pop-ups continue to... pop up and especially ones from one site. Is there a way to target popups if you know a part of the URL? Alternatively, is there a Firefox add-on or other program that will be more effective? In the scheme of things, it's a minor annoyance, but enough of one that I'm asking.--108.46.103.88 (talk) 01:03, 3 January 2012 (UTC)[reply]

I'd say AdBlock Plus is what you're looking for. -- 88.67.154.4 (talk) 09:41, 3 January 2012 (UTC)[reply]
AdMuncher (not free) is pretty good, too. I use both at the same time. KägeTorä - (影虎) (TALK) 17:56, 3 January 2012 (UTC)[reply]

What's wrong with the external link check?

Hi, I just added a single line referencing one of our articles to Wikipedia:Reference_desk/Computing#Pop_up_blocker_for_specific_site.3F and upon saving, I'm getting a captcha because I'm introducing external links?! Huh?! -- 88.67.154.4 (talk) 09:45, 3 January 2012 (UTC)[reply]

Well, anti spam I would imagine. To make sure you're not a robot posting spam or advertising material from an external source? Mrlittleirish 10:23, 3 January 2012 (UTC)[reply]
Please, kindly explain what part of my edit was an external link? -- 88.67.154.4 (talk) 10:24, 3 January 2012 (UTC)[reply]
Good point, I read the question and not the link sorry! Note sure then... Mrlittleirish 10:34, 3 January 2012 (UTC)[reply]
Someone else inserted the external link, but you received the warning. This is a known bug. Von Restorff (talk) 10:38, 3 January 2012 (UTC)[reply]
But there's no external link at all?! -- 88.67.154.4 (talk) 13:04, 3 January 2012 (UTC)[reply]
And if you create yourself an account to edit from you shouldn't be bothered by these sort of annoyances. It's easy and free. --jjron (talk) 12:03, 3 January 2012 (UTC)[reply]
Our name is Legion, for we are IP. Resistance is futile. You will be anonymized. -- 88.67.154.4 (talk) 13:04, 3 January 2012 (UTC)[reply]
Actually you are not a part of Anonymous. Usernames, when chosen correctly, can be more anonymous than IP's. Von Restorff (talk) 13:14, 3 January 2012 (UTC)[reply]
So are...-- 78.43.93.174 (talk) 17:21, 3 January 2012 (UTC)[reply]
...sufficiently random IPs. --89.204.155.106 (talk) 17:22, 3 January 2012 (UTC)[reply]
Don't you think? ;-) -- 91.47.17.11 (talk) 17:31, 3 January 2012 (UTC)[reply]
When you provide three IPs that trace to destinations near one another, it actually makes it easier to triangulate your location. A username has no geolocation unless one is given. Even then, the one given can be completely false. -- kainaw 21:08, 3 January 2012 (UTC)[reply]
Kainaw is right. We know your approximate age, we know your sex, and we can geolocate you to a specific area. Your IP's are not "random" enough to hide your identity; the more info you give me the easier it is to find you. If the IPs would geolocate to places all over the world it would be even easier; certain countries do not respect the rights of their citizens and it would be quite easy to trace you even without computer skills by using social engineering and a bit of bribery. If you want to be anonymous on the internet there is 1 good trick: avoid using it. Von Restorff (talk) 01:30, 4 January 2012 (UTC)[reply]
Um, no. First of all, I didn't want to run afoul of WP:POINT, so I stopped after four IPs. One of them belongs to a pool of IPs used nationwide for mobile devices (UMTS), geolocation info for that one can't be more specific than "Germany". This is basically a huge NAT array (used due the IP v4 shortage, and most users not needing a public IP on their mobile device).
Also, some of the IPs don't "belong" to me, either (though I have permission from their owners to use them) and are not even in the same city, and I could have picked a US or UK IP as well to confuse you, or used Tor. While tracking me may seem easy to you, think about this: Without me admitting the use of all these IPs above, you would have had no proof of them being the same user, only a suspicion, e.g. see the mention of "fist" in Morse code (especially if I had used them to edit elsewhere, not in this thread). Plus, they're all dynamic IPs.
With a username, once it has been de-anonymized, your complete edit history becomes known, in a way that it can be proven, not just guessed/assumed. Which is not something you want w/r/t previous/future employers, law enforcement (esp. in the kind of countries you mentioned above), or even your neighbo(u)rs... -- 88.67.154.4 (talk) 09:33, 4 January 2012 (UTC) PS: Von Restorff, you're younger than me, but let's keep WP:OUTING in mind and stop here. ;-)[reply]
Um, no. For law enforcement it is quite easy to geolocate mobile devices. It is possible to change usernames (almost) as quickly as IP's; so there is not much difference in that aspect. Making an account also takes less than a minute. But IP's are geolocatable and some usernames are not. The MediaWiki software's TorBlock extension automatically blocks all editing through Tor. Von Restorff (talk) 09:41, 4 January 2012 (UTC) p.s. In which month was I born? [reply]
Well essentially, you are just trolling now. If you wanted to hide, like someone said before, don't use the internet. There is always a way to track IP's. It's not that hard for me or you to really. If you want to carry on changing IP's or using someone else's IP, then you carry on. It's no skin off anybodies nose here. Mrlittleirish 10:03, 4 January 2012 (UTC)[reply]
@Mr X.: if you want to we can continue this discussion on my talkpage, that is probably a better place.
@Mr little irish: I know your intentions are good but relax mate, he is not trolling, he just believes some misconceptions about anonymity on the internet. Von Restorff (talk) 10:08, 4 January 2012 (UTC)[reply]
I'm not trolling, we're just drifting off-topic from my original question (hence the <small>). As per Von Restorff's suggestion, we're moving it to his talk page. -- 88.67.154.4 (talk) 14:59, 4 January 2012 (UTC)[reply]

MySQL5 password brute force

I have Extreme GPU Bruteforcer and with 3000 PasswordsInThread and 512 streamprocessors and both min and max length 8 chars I get about 300.00M p/s. How can I improve this without spending money?

Is there better software out there (sorry, I do not own a Macintosh, but I am willing to install a Linux distro)?

This is just for fun, it is my own site and I know the password. Von Restorff (talk) 10:28, 3 January 2012 (UTC)[reply]

Firefox Stopping & Starting

My firefox (v9) has developed an annoying habit (since around v4). It works fine for about 8 seconds, then seems to freeze for 3 seconds. The content of the page doesn't seem to matter, as while I type this, it is freezing on and off (resulting in half a sentence suddenly appearing). I can be scrolling up or down the reference desks, and it will freeze, then suddenly jump to wherever it was I would have been. It's very annoying and for this reason I prefer to use Opera, however, firefox does have some features I like to use once in a while. I believe it might have something to do with constantly checking for updates to addons. Is it possible to get firefox to just check for these addons once a day? I mean, if there was no update 5 seconds ago, I doubt there'd be one now. It only happens with Firefox and nothing else. KägeTorä - (影虎) (TALK) 17:01, 3 January 2012 (UTC)[reply]

Start Firefox in safe mode. If the problem disappears it is likely that it is caused by an add-on/plugin. Von Restorff (talk) 18:43, 3 January 2012 (UTC)[reply]
... and if it is a plugin, try disabling them one at a time until you find the culprit. You can disable Firefox updates completely by unchecking the boxes in Tools > Options --> Advanced --> Updates. Dbfirs 20:42, 3 January 2012 (UTC)[reply]
Do not disable FF updates, browsers need to be up to date. Von Restorff (talk) 04:29, 4 January 2012 (UTC)[reply]
I have my FF updates disabled (for reasons of poor internet access), but I do update manually. Perhaps I should have written "you can disable Firefox addon updates by unchecking the addon box". Dbfirs 08:31, 4 January 2012 (UTC)[reply]
My guess is that updates are not the problem. Von Restorff (talk) 09:23, 4 January 2012 (UTC)[reply]
Yes, you're probably right. Firefox doesn't check for updates that often, even if it has dozens of addons. What else in Firefox could be causing the problem? I suppose it could be one particular addon, possibly downloaded from an unapproved site. Perhaps it would be worthwhile trying Help --> Restart with add-ons disabled. (Sorry, I've just noticed that you suggested exactly that above) Dbfirs 08:18, 5 January 2012 (UTC)[reply]

Mercury (element)

Your article on mercury states the following: A heavy, silvery d-block element, mercury is the only metal that is liquid at standard conditions for temperature and pressure; the only other element that is liquid under these conditions is bromine, and metals such as caesium, francium, gallium, and rubidium melt just above room temperature. With a freezing point of −38.83 °C and boiling point of 356.73 °C, mercury has one of the narrowest ranges of its liquid state of any metal.[1][2][3]

My question is, If mercury is a liquid at room temperature; How can the freezing point be -38.83 degees Celcius? — Preceding unsigned comment added by 174.111.46.103 (talk) 17:19, 3 January 2012 (UTC)[reply]

Elements are in the liquid state when their temperature is between the freezing and boiling point. Maybe you're unfamiliar with the celsius scale? Room temperature is usually around 25°C, which is between the freezing- and boiling- points of pure mercury. Mercury will freeze into a solid metal if you make the temperature very much colder - around −38 °C, which is much colder than your household refrigerator or freezer (but not as cold as, say, some parts of Antarctica in winter; or some biology-lab freezer equipment; and certainly not as cold as a vacuum freezer apparatus in a low temperature physics lab). Nimur (talk) 17:24, 3 January 2012 (UTC)[reply]
(EC) In the same way that water is a liquid at room temperature, and its freezing point is 0°C. Its freezing point and its state at room temperature are unrelated. In any case, this is a question for the science desk, not the computer desk. Feel free to re-post it over there to get some more detailed answers. KägeTorä - (影虎) (TALK) 17:25, 3 January 2012 (UTC)[reply]

MySQL fuzzy select field name

I have 30 fields named diag1, diag2, diag3, diag4... I want to get a list of rows in which any of those fields have the value '410'. I know this will not work: select * from er where 'diag%'='410'. Is there a way to fuzzy-select all the fields at once? -- kainaw 18:22, 3 January 2012 (UTC)[reply]

I don't think there's a way to use wildcards in your field names (with the exception of the * column wildcard). I think you will have to just make a very large query of it ("where diag1='410' OR diag2='410' OR ..."), which is pretty easy to generate, no? --Mr.98 (talk) 19:39, 3 January 2012 (UTC)[reply]
I can't think of a way to do it with a single query. Possibly in a program/script of some type, using a "SHOW COLUMNS FROM " statement to start with. --LarryMac | Talk 20:20, 3 January 2012 (UTC)[reply]
I have considered using a show columns subquery, but I don't think it is possible to use the results of that subquery as a field name, only as a value. -- kainaw 20:24, 3 January 2012 (UTC)[reply]
This may not be an option for you, but it would be nice to adjust the schema to better fit the data. If you have a large number of things that you want to treat uniformly, it's probably best to represent them as rows rather than columns: create a new 'Diag' table that contains two columns, a key into the original table, and a value representing whatever the diag columns contained, and fill it with 30 (or however many) rows per row in the original table. Then, the number of diags wouldn't be built into the schema, and you can simply query that table to find something with the value '410' and join on whatever other information you need. Paul (Stansifer) 21:13, 3 January 2012 (UTC)[reply]
Trust me... If I were the one who created this database (which is read only), I wouldn't have had a table structure like this. I also wouldn't have used "ADYEAR" and "ADMONTH" to be the year and month values, but "ADDAY" to be the day of the week (completing omitting the day of the month). -- kainaw 21:16, 3 January 2012 (UTC)[reply]
Well, for MySQL 5.0 and higher, this should get you the list of the column names:
select * 
  from INFORMATION_SCHEMA.COLUMNS 
 where TABLE_NAME = 'Foo' 
   and COLUMNS like 'diag%'
However, I'm not sure how, or if, you can then use this list of column names to do what you want. StuRat (talk) 17:07, 4 January 2012 (UTC)[reply]

Latin characters in Unicode

What fonts support Latin Extended-C and Latin Extended-D and is there anywhere I can download them? --Theurgist (talk) 22:30, 3 January 2012 (UTC)[reply]

C & D. Quivira is a font that is free to use for any purpose, including commercial usage, and it has a nice name. Try evermono if you like this. Code2000 is the most complete Unicode font available. Von Restorff (talk) 01:11, 4 January 2012 (UTC)[reply]
Thanks! I can now see all Latin characters in Unicode. --Theurgist (talk) 09:40, 5 January 2012 (UTC)[reply]

User Limit on Software Installation

Hello. How do software developers keep track of the number of PCs on which a program with a specific serial key is installed, especially if your PC crashes and you have to re-install the program? If a license on your PC is 1-user and your PC crashes, how does the software company know that you are not installing the program on a second PC? Thanks in advance. --Mayfare (talk) 23:01, 3 January 2012 (UTC)[reply]

Digital rights management outlines several of the techniques. Many of these technical solutions have holes; many of them inconvenience users; but some of them work very well. You might read floating license and software metering as well. Nimur (talk) 23:04, 3 January 2012 (UTC)[reply]

January 4

Can't access external hard drive

On a Windows 7 system, an external drive started acting strangely. I started a disc scan. At first it was counting through files rapidly, then it started going very slowly. I decided to stop the scan and reformat the external HD (a Seagate). Now properties shows all of the HD used and when I try to format, it says "you do not have sufficient rights to perform this operation". I have only one user account and it has administrator rights. How can I reformat the external HD? Bubba73 You talkin' to me? 03:21, 4 January 2012 (UTC)[reply]

Try using it with another computer. Starting in safe mode and temporarily disabling User Account Control may help. Use CHKDSK and/or SeaTools for Windows. Von Restorff (talk) 03:48, 4 January 2012 (UTC)[reply]
I think something has gone wrong with the drive. Now it isn't even showing up under "Computer". Yesterday my daughter said that it was making a noise, I said that it was just spinning up. If I unplug it and plug it back in, I get the normal USB sounds, but it doesn't show up. If I reboot it doesn't show up, the light on it keeps flashing, and there are some sounds like it is trying to connect a USB device but can't (two sounds at the same pitch). Bubba73 You talkin' to me? 04:25, 4 January 2012 (UTC)[reply]
Your daughter was probably right. Well, I hope you still have your files! Luckily external drives are cheap nowadays. If I understand it correctly the drive is empty and you did not lose any files, is that correct? If so, its probably best to buy a new harddrive instead of trying to get this thing to work. Western Digital, Seagate, and Maxtor are all decent brands if you want to buy one. Von Restorff (talk) 04:36, 4 January 2012 (UTC)[reply]
It had a lot of files on it, but I use it for a backup. I have my primary computer which has an external HD and this external HD is on my secondary computer. I have a batch file that copies my important files from the primary HD to: the primary external HD, the secondary computer HD, and the secondary external HD. A day or two ago, I noticed that the batch file was taking a lot longer than it should. Today the batch file would get only part of the way through, when there was an error 23 scanning the destination directory. Then it got worse. So, that combined with my daughter noticing a different noise, and the fact that now the computer doesn't even see it (except for the USB beeps), it must have died. And I think it was less than a year old. Bubba73 You talkin' to me? 05:30, 4 January 2012 (UTC)[reply]
Rest In Partitions dear Seagate drive. I use Dropbox, that has a couple of advantages over the system you described, but I only need to backup 20-30 gigs. Von Restorff (talk) 06:19, 4 January 2012 (UTC)[reply]
Resolved
I ran Seagate Sea Tools, and it says that it is defective. It read the serial number and it is in warranty (until April 2015). It took me to the area to submit a RMA. Bubba73You talkin' to me? 06:25, 4 January 2012 (UTC)[reply]
Good work! My personal experience is that Seagate support is OK but a bit slow; I hope they'll help you quickly! Von Restorff (talk) 06:29, 4 January 2012 (UTC)[reply]
Sea Tools says that it has been on for 11,799 hours. So I got it about 16 months ago. Bubba73 You talkin' to me? 07:10, 4 January 2012 (UTC)[reply]

Clicking scroll wheel to go to full-screen mode?

Resolved

I just installed Batman: Arkham City on my computer, and some of the moves in the game require one to push in the scroll wheel on the mouse (not scroll with it, but push it in as if pushing a button). Whenever I do this, however, the screen flashes back for a second. Sometimes I get the desired result as well, as if the push had been successful, and other times I don't. When I do it several times in succession, the game will go from full-screen to windowed mode, as if I had pressed alt-enter. I'm using a Logitech wireless mouse with left and right buttons plus a clickable scroll wheel (nothing fancy). Any idea what's going on here? Help is greatly appreciated--thanks! Meelar (talk) 04:16, 4 January 2012 (UTC)[reply]

Try the button R. If that does not work the easiest fix is probably to remap the controls in the options-controls screen in the main menu. Use a different button. Von Restorff (talk) 04:26, 4 January 2012 (UTC)[reply]
Remapping worked. Thanks! Meelar (talk) 06:11, 4 January 2012 (UTC)[reply]
Whoohoo! You are very welcome of course. Von Restorff (talk) 06:18, 4 January 2012 (UTC) p.s. Buying a cheap gamepad is always a good idea.[reply]

How to select proper PSU for my PC with new GPU card upgrade

Hi guys, I have Intel pentiumD3Ghz CPU, 2GB RAM,1HDD,1DVD,965Mobo,300Watts local PSU. The APC UPS of mine can provide load upto 390W. The software tool of UPS tells me the power consumption of my PC(PC alone plugged in, all other devices are removed from UPS while doing this test) is 113W at Idle and 170W at 100% CPU (+/- 5watts). I think this reading is somewhat equivalent to kill-a-watt meter reading.

Watts consumed by PC = 100% CPU(Using App) + 100% HDD(fileCopy) + 100% DVD(read/write test) = 175W MAX

I plan to buy HD 6870/GTX560ti which may eat 150W/175W (Max).

So as per my calculation(Max),

Watts Consumed by GPU(max) = 175W (for GTX 560ti) / 150W (for HD 6870) ( As per Spec)

So total power(max) = (CPU+RAM+mobo+DVD+HDD) + GPU

                   = 175W + 175W = 345W for GTX 560ti 
                   = 175W + 150W = 320W for HD6870.

I dont use cooling fan\chasis fan. And these cards are not Overclocked versions. Hence I dont have idea of buying any cooling systems. Also the DVD drive isn't going to run all the time.

So as per my calculation, the required SMPS rating (PSU) I should go for either of two cards is 400Watts. This should be sufficient Am I correct?.

This is again for my configuration only.

But in recommended spec in websites and reviews say 500W min is required. Why is that?. Even in some GPU reviews, I had seen like using kill-a-watt meter, total PC consumed power with GTX560ti as GPU is 365W Maximum. Then why still Nvidia\Radeon suggest to buy 500W with 2x75W on PCIe cable as min PSU spec?....

All I know is that these cards do expect above 35A in +12V rail. So is it because PSUs with 500W and above should only be capable of delivering that much current in +12v line?.

Or is this a market strategy?. Now can anybody suggest me what rating I should choose here?..Your help can help me choose right one.

Thanks Balan (talk) 08:20, 4 January 2012 (UTC)[reply]

You generally want some headroom but from my experience most manufacturers strongly overestimate how much power you will need as you've concluded yourself. This reduces the risk of problems. This is partially because of 12V rail problems but with modern ATX 2.0x PSUs this isn't really an issue. The far bigger problem is likely all those of cheap, crappy PSUs which suffer from false advertising and can't reliably deliver what they advertise. Even in those parts of the developed world where there are strong consumer protections laws regarding false advertising and product quality, from my experience computers PSUs is one are which still tends to fall thru the cracks. Remember from GPU manufacturer POV, the number of customers they are going to lose is small. The fact that people are getting seriously oversized PSUs and particularly before the 80Plus standard became withspread were likely wasting power by doing so, isn't their concern. Product failures and product problems because people are using some crappy PSU which claims 500W but can't even reliably deliver 350W is not something thay want. Generally those who know what they are doing ignore the manufacturers recommendations for video card PSUs anyway knowing them to be often seriously inflated, and knowing not to touch crappy PSUs with a barge pole due to the risk it will take out the whole computer (which incidentally violates the ATX standard). Nil Einne (talk)

Two sets of earbuds in one iPhone 3GS

'sup?

I've been wondering if there's a possibility of plugging two sets of earbuds in one port on an iPhone. If yes, which devices would you recommend?

Cheers, 93.143.9.167 (talk) 08:49, 4 January 2012 (UTC)[reply]

Is this what you need? Von Restorff (talk) 08:52, 4 January 2012 (UTC)[reply]
"Normal" TRS connector on the left, iPhone TRRS connector in the middle
If it's just for listening to music, you can get a simple splitter for about £1 – [2]. However you'll lose the functionality of the iPhone headphones' microphone, as the iPhone jack is a TRRS connector (middle in photo) whereas the splitter will only be a TRS (left in photo). The audio will still sound the same (like when you plug in "normal" headphones to an iPhone) but you won't be able to use the mic. matt (talk) 15:51, 4 January 2012 (UTC)[reply]
Ah, yeah, I should've mentioned that, with that link I gave you still have the microphone functionality, but it is more expensive. Von Restorff (talk) 16:00, 4 January 2012 (UTC)[reply]

Is face detection involves matching faces

Hi, i had a doubt on topic Face detection. Whether it involves matching the faces? Is it possible to find out a person from a group of people? If a input photo is given, whether it possible to find correct person? — Preceding unsigned comment added by 117.211.60.17 (talk) 09:59, 4 January 2012 (UTC)[reply]

I am not completely sure what you mean but I think the answer is that face detection and facial recognition are not the same thing but they can be combined. Von Restorff (talk) 10:25, 4 January 2012 (UTC)[reply]
I think you are asking if there are any shortcuts other than directly comparing the face with every face in your database. I believe there are, such as measuring various dimensions and ratios on the face, and using those to pare down the database to only a few which match those parameters. A side-by-side comparison can then be done with those. StuRat (talk) 16:44, 4 January 2012 (UTC)[reply]

C# cannot convert from char[] to string

I'm working in a windows application using forms, I only have a label on it which I'm using for output.

        public Form1()
        {
            InitializeComponent();
            char[] x ={ 'i', 'u' };
            label1.Text = x.ToString();           // Both these assignments gave the same result
            label1.Text = Convert.ToString(x);
        }

I keep getting system.char[] on the label instead of the desired iu. Any ideas? Bastard Soap (talk) 14:28, 4 January 2012 (UTC)[reply]

Possibly you could just assign the array to the label attribute?
      label1.Text = x;
Just guessing, not being a C# programmer... --CiaPan (talk) 14:41, 4 January 2012 (UTC)[reply]
(ec) Or use an explicitly created temporary string object, like the author ofthis question at bytes.com. --CiaPan (talk) 14:44, 4 January 2012 (UTC)[reply]
label1.Text = new string(x);     -- Finlay McWalterTalk 14:42, 4 January 2012 (UTC)[reply]

In C# and Java, and some other languages, String objects are immutable, so they are not directly interchangeable with character arrays. You need to use a String construction function for such purposes. This is detailed in the remarks section of the official C# String reference. Nimur (talk) 16:18, 4 January 2012 (UTC)[reply]

Delete facebook

My name is Roxanne Sellers and I am with Gulf Islands National Seashore and we are asking to please delete this facebook site it is not an offical site. Any questions please call <redacted> or email me at <redacted>

Thank you — Preceding unsigned comment added by 165.83.133.248 (talk) 17:24, 4 January 2012 (UTC)[reply]

You seem to be in the wrong place, Wikipedia is not affiliated with Facebook and we have no control over their content--Jac16888 Talk 17:36, 4 January 2012 (UTC)[reply]
I read this as a request to remove the Wikipedia article Gulf Islands National Seashore. -- kainaw 17:50, 4 January 2012 (UTC)[reply]
Facebook community pages may incorporate content from Wikipedia— such use complies with Wikipedia policies on reuse of content. We at Wikipedia have no control over how the content is included nor can we help to remove it. Facebook does have a topic on Community pages and profile connections on their Help Center. PrimeHunter (talk) 18:13, 4 January 2012 (UTC)[reply]
A piece of advise for Ms. Sellers. I'd suggest embracing the page instead of asking for it to be deleted. You can most likely post whatever you want on it, thereby somewhat controlling the direction you want it to go (assuming here it would be to promote tourism and education), so why not post links to websites of local hotels, restaurants, schools, marinas, fishing clubs, etc ...and share those posts on the other community pages in your area? Long story short: In this day and age, people are going to create websites and social media pages about the people, places and things they are interested in. There is not much you can do about it...so it's best to just work with it instead of against it. Plus using Facebook is a free form of advertising , and I guarantee that more people are looking at their Facebook feed on a daily basis than the "official website" of Gulf Islands National Seashore. Quinn WINDY 20:21, 4 January 2012 (UTC)[reply]
And here's a good article discussing the difference between Facebook community/business pages. I realize that the GINS is not exactly a business, but still might be informative. Quinn WINDY 20:30, 4 January 2012 (UTC)[reply]
Just to clarify - Ms Sellers might be encouraged to "post whatever you want ... promote tourism ... [advertising] ..." on any Facebook page (subject to FB's terms and conditions of course), but not on Wikipedia. Mitch Ames (talk) 09:38, 5 January 2012 (UTC)[reply]

Multithreaded Apartment in Visual Basic Application

I am writing an application with Visual Basic 2010 Express. The application has a COM reference to a DLL, and everything works fine as a single threaded application. However, I want to break the application into two threads, one for the GUI and one which actually does the work. Both threads need to make calls to the COM reference. When I set up a multithreaded application, I receive this error message: "Unable to cast COM object of type 'Sync Framework Managed Class' to interface type 'Sync Framework COM Interop Class'. This operation failed because the QueryInterface call on the COM component for the interface with IID '{73EA794F-1251-4466-A19C-DAEAF5BDBD04}' failed due to the following error: No such interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE))." which according to here (third heading) means I need to use a multithreaded apartment model. Can anyone point me in the right direction on how to do that? I've read Microsoft's pages on that (starting here) but I can't figure out how to make it happen. anonymous6494 22:11, 4 January 2012 (UTC)[reply]

January 5

Computers that degrade with age

We've all had them: computers that run ok and then within a year or two they start getting slower or overheating. Why? Common answers to this question that I've heard over the years:

  • "too much stuff" clearly not true since most times the hard drive with the operating system is less than 50% full and usually defrags once a week.
  • "too much in the registry" seems more plausible, in my case I have >300 installed programs even with constantly uninstalling things I don't need. But.. most people have a lot fewer than this, and as if just 300 entries would make a difference on modern hardware. Even if the OS did a linear search through the registry it wouldn't add much.. correct me if I'm wrong.
  • "Dust", means the fans have to do more work to keep it cool. Sound logic but too many times I've checked and they've been cleanish.

Formatting and defragging makes a difference, sure, but you never quite get as fast as when the computer was new. Why? Does the processor or the RAM slow down over time? Does the hardware literally just degrade over time?

Discuss — Preceding unsigned comment added by Benjamint444 (talkcontribs)

Yes, hardware does degrade over time, but this is not the reason performance of most Windows desktops degrade with age. The reason is that the Windows operating system and the humans controlling it do not clean up after themselves properly. Scandisk, defrag and reinstall; the computer will perform as quickly as when you just bought it. Von Restorff (talk) 06:38, 5 January 2012 (UTC)[reply]
Is it really just updates? I can kind of see how a few hundred mb of extra code could become really inefficient. Does Windows just have a terrible way of implementing the updates or something? Benjamint 06:44, 5 January 2012 (UTC)[reply]
Yes, Windows Update is terrible, but this problem does not have much to do with updates. It has to do with the fact that the Windows operating system and the humans controlling it do not clean up after themselves properly. E.g.: uninstalling an application does not remove it 100%, defragmentation occurs, the register gets polluted, logfiles accumulate et cetera. Lets say Mr. X moves out his parents basement when he is 18 and rents his own house. At first he works very efficiently, but because he does not like cleaning his house gradually becomes messier and messier. Stuff is hard to find, hidden under piles of trash. This affects his work efficiency. By cleaning his house (reinstalling Windows) he can improve his performance temporarily; but because of his messy habits it will inevitably become a mess again. Some operating systems are much better in cleaning up after themselves, and their performance degrades much slower. Von Restorff (talk) 06:47, 5 January 2012 (UTC) p.s. Overheating is usually caused by dust accumulating in places that are hard to reach. p.p.s. Almost no one defrags once a week, unfortunately. p.p.p.s. Your register contains a lot more than 300 entries![reply]
I do! I run disk clean-up after closing my browser (every time), defrag at least once a week, and run chkdsk at least once a month. I also have most styling and smoothing nonsense disabled. My OS (XP/SP3) GUI looks 20 years out of date (really clunky), but this old and fairly crappy PC runs as fast as it possibly can. I've also enabled file indexing. This speeds up disk searches, but without chkdsking, I think would get messy due to the shoddy implementation of the files system. "Tag it and chuck it in". Or, NTFS as it is properly called. fredgandt 07:16, 5 January 2012 (UTC)[reply]
Geeks all over the planet are starting to build fansites dedicated to you now! Von Restorff (talk) 07:45, 5 January 2012 (UTC)[reply]
Indexing will speed up searches, but it may slow down the PC when you change indexed files (like documents). Depending on how often you search, relative to how often you update files, indexing may not be an efficient way of speeding up your system. Mitch Ames (talk) 09:32, 5 January 2012 (UTC)[reply]
Interesting observation. In fact I found it did slow things down at first, but has sped things up since being enabled longer. I think it improved after the first chkdsk after enabling. My biggest issue is very small hard drive (and old) of only 40gb and hardly any ram of 512mb. Reworking my bios helped too. The computer is second hand, and had the primary boot device set as its (wait for it) floppy drive! Yes folks, a floppy drive. So everything it did, it checked the floppy first. It wasn't fun. I need to upgrade so badly  fredgandt 09:50, 5 January 2012 (UTC)[reply]

Question from the archive with some discussion about computers slowing down over time 82.45.62.107 (talk) 11:39, 5 January 2012 (UTC)[reply]

Does Video card affect video playback performance?

Will a better graphic card improve video playback performance when watching movies on VLC media player? Or is movie playback sort of like an HDMI cable where it either works or it doesn't. In other words, if the video playback is choppy/laggy, could a poor graphic card be responsible? Acceptable (talk) 07:33, 5 January 2012 (UTC)[reply]

Yes, that is possible (especially with HD), although it is rare. I am running a program called Extreme GPU Bruteforcer at this moment, which means my videocard has a lot of work to do. If I watch a HD video in VLC while running the bruteforcer I can see it lagging. If you have an old computer make it lag and try to find the bottleneck: is the CPU usage 100%? Is there free RAM left? Et cetera. Von Restorff (talk) 07:37, 5 January 2012 (UTC)[reply]
Essentially, I have a NVIDIA GT 540M with Optimus technology. Optimus automatically switches between the dsicrete NVIDIA card and the onboard integrated Intel GPU. Most of the time, video playback is pretty good, but there are occasional blips here and there when I play 1080p video. If this is the level of performance I can expect from my discrete card, then I'm fine with it. But if it's a problem with Optimus not switching to my discrete card, then I would like to find a way to switch to the discrete card when watching video. Acceptable (talk) 07:48, 5 January 2012 (UTC)[reply]
Open the "NVIDIA Control Panel" from your start menu. On the lefthand side, under "Select a task...", open the "3D Settings" tree, and select "Manage 3D Settings". Now on the righthand panel, click the "Program Settings" tab. Under "1. Select a program...", click "Add", navigate to your VLC directory and select "vlc.exe". Under "2. Select the preferred graphics...", choose "High-performance NVIDIA processor", then (VERY IMPORTANT) click "Apply" in the bottom right. Von Restorff (talk) 07:58, 5 January 2012 (UTC)[reply]

What's the best way to restore a computer to it's factory state?

I would like to pass off a used laptop of mine with Windows 7 to a younger sibling. Before doing so, I would like to erase all of my personal files and restore it to the original factory state that it came in when I first got the computer. I know erased data can be recovered with software, but since it's a sibling, I'm not worried about loss of personal information or something. What is the best way for me to do this? The computer is a Dell Studio 15, I think I may have the restore CD that came with the laptop. But if I do not, what are the steps that I should take to formatting my computer, but still ensuring that Windows 7 works afterwards? Thanks. Acceptable (talk) 07:51, 5 January 2012 (UTC)[reply]

http://pastebin.com/FEnN9EXt For files that are not acceptable to see for younger siblings you may want to use a file shredder. Does your computer has a recovery partition? Try to find the CD first, if that does not work reboot the computer and bash F8, maybe it gives you the option to press a button to go back to factory settings. If not check your startmenu, maybe there is an option to restore factory settings there. If all else fails read this. Von Restorff (talk) 08:01, 5 January 2012 (UTC)[reply]
I'm pretty sure that unless your younger sibling is a computer wizz of epic skill (and is thus able to read the hard drive without the files being filed), simply reinstalling the OS will clean as it installs. The result will be a computer with nothing but an OS. Then fresh install all the drivers etc and ancillary programs (photoshop or whatever). fredgandt 09:40, 5 January 2012 (UTC)[reply]
I think you did not read the pastebin link. Acceptable is asking for the best way, not the worst way! Von Restorff (talk) 10:11, 5 January 2012 (UTC)[reply]

Free MS-DOS games?

Is there any games for an MS-DOS machine with CGA-graphics that are free as in PD/GPL etc..? needed for WP illustration. Electron9 (talk) 15:17, 5 January 2012 (UTC)[reply]

Check through this list perhaps: List_of_open-source_video_games IRWolfie- (talk) 15:21, 5 January 2012 (UTC)[reply]

VPN in other countries

If I live in country A, and I use a VPN hosted in country B, am I subject to Internet laws in country B or country A? Aacehm (talk) 15:53, 5 January 2012 (UTC)[reply]

Both. To add to complications, if you use the VPN in country B to perform illegal activity in Country C, you are also subject to the laws of country C. -- kainaw 16:23, 5 January 2012 (UTC)[reply]
I'm sorry that this won't help you, but Wikipedia does not give legal advice. TheGrimme (talk) 16:27, 5 January 2012 (UTC)[reply]
(e/c):This is a complex issue, and of course we cannot give you legal advice. I suggest you read Legal aspects of computing#Jurisdiction.--Shantavira|feed me 16:25, 5 January 2012 (UTC)[reply]

Website prices

Say I want to create a website that will allow for video and picture uploading and sharing as well as discussion forums. Suppose I expect to have around 2000 members, and that the largest use of memory would be the video uploading with, lets say, 500 people uploading 500Mb each over the course of the first 2 years. Roughly how much would such a site as this cost to set up and run over those two years?

79.66.96.194 (talk) 16:00, 5 January 2012 (UTC)[reply]