I have the mean & SD of several different time points, I want to combine them into one mean and SD. Is it possible? Example;  At 1 hour; mean=5, SD=1, n=42  At 2 hours; mean=6, SD=3, n=42 and so on.  Any equation to do that?  Note: at some time points, I have different group numbers (n), due to missing one or two patients. I really appreciate your help, thanks!

I'm calculating the covariance of a distribution in parallel and I need to combine the distributed results into on singular Gaussian. How do I combine the two?  Linearly interpolating between the two almost works, if they are similarly distributed and sized.   provides a forumla at the bottom for combination but it doesn't seem right; two identically distributed distributions should have the same covariance, but the formula at the bottom of the page doubles the covariance.  Is there a way to combine two matrices?


I'm trying to login to my Gmail account but I keep getting an error message number code 93.   How can I fix this and access my account?

Since August 1st I've been getting this error when trying to login to my gmail account:     Temporary Error (500)      We’re sorry, but your Gmail account is temporarily unavailable. We apologize for the inconvenience and suggest trying again in a few minutes.      If the issue persists, please visit the Gmail Help Center »      Try Again Sign Out      Hide Detailed Technical Info   Numeric Code: 93   I've emailed Gmail support several times with no response after their autoresponder, and I've posted to the .  Absolutely no response.  It's been more than 10 days now, and I'm starting to get desperate!  Can anyone give me any ideas for how I might get this issue resolved.  If any Googlers happen to read this – you'll receive much good karma if you notify one of the engineers of my plight! :-)


$X \sim N(\mu, \Sigma)$. How can I find conditional distribution of $X$ given $AX$, where $A$ is a non-random matrix? I know that $AX \sim N(A\mu, A\Sigma A^T)$ but don't know what to do next.  P.S - I am preparing for an exam and solving problems from textbook, so should i add hashtag self-study?

Given a Gaussian random vector $X \in \mathbf{R}^p \sim \mathcal{N}(\boldsymbol\mu, \boldsymbol\Sigma)$, a matrix $\mathbf{K} \in \mathbf{R}^{q \times p}$, and a vector $y \in \mathbf{R}^q$, I'd like to find the distribution of $\tilde X = (X \mid \boldsymbol{K} X = y)$ while assuming that $\operatorname{rank}(\boldsymbol\Sigma) = p$ and $\operatorname{rank}(\boldsymbol{K}) \le q < p$. Ideally without having to (psuedo-)invert any singular matrices.


I'm trying to make a video from an image and I want to add a zoom effect on the center. The input image is 640x360.  The command I'm using is:     ffmpeg -framerate 25 -loop 1 -i 46686405.jpg -vf   "zoompan=z='min(zoom+0.0015,1.4)':x=320:y=180:d=150" -t 6 -c:v mpeg2video   -b:v 700k -s 640x360 -y 46686405.mpeg   My goal is to have a video mpeg of 6 seconds with size 640x360 and 25fps. The zoom effect should start from the center and the maximum zoom I want is 40% of the image.   Actually I'm able to generate a video, but it's jerky. I noticed that if zoom starts from top left (x=y=0), it was fluid. In both cases I receive errors like that  [swscaler @ 0x28794a0] deprecated pixel format used, make sure you did set range correctly   Where am I wrong? Thank you for any help.  This is my complete console output:  ffmpeg version 2.3.git Copyright (c) 2000-2014 the FFmpeg developers   built on Aug  7 2014 18:14:20 with gcc 4.6 (Ubuntu/Linaro 4.6.3-1ubuntu5)   configuration: --prefix=/home/stuzzo/ffmpeg_build --extra-cflags=-I/home/stuzzo/ffmpeg_build/include --extra-ldflags=-L/home/stuzzo/ffmpeg_build/lib --bindir=/home/stuzzo/bin --extra-libs=-ldl --enable-gpl --enable-libass --enable-libfdk-aac --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libxvid --enable-libx264 --enable-nonfree   libavutil      52. 98.100 / 52. 98.100   libavcodec     55. 72.102 / 55. 72.102   libavformat    55. 51.101 / 55. 51.101   libavdevice    55. 13.102 / 55. 13.102   libavfilter     4. 11.102 /  4. 11.102   libswscale      2.  6.100 /  2.  6.100   libswresample   0. 19.100 /  0. 19.100   libpostproc    52.  3.100 / 52.  3.100 Input #0, image2, from '/home/stuzzo/Videos/test/46686405-1400593167_temp.jpg':   Duration: 00:00:00.04, start: 0.000000, bitrate: N/A     Stream #0:0: Video: mjpeg, yuvj420p(pc, bt470bg), 640x360 [SAR 96:96 DAR 16:9], 25 fps, 25 tbr, 25 tbn, 25 tbc [swscaler @ 0x22699e0] deprecated pixel format used, make sure you did set range correctly [mpeg @ 0x22789e0] VBV buffer size not set, using default size of 130KB If you want the mpeg file to be compliant to some specification Like DVD, VCD or others, make sure you set the correct buffer size Output #0, mpeg, to '/home/stuzzo/Videos/test/46686405-1400593167_temp_temp.mpeg':   Metadata:     encoder         : Lavf55.51.101     Stream #0:0: Video: mpeg2video, yuv420p, 640x360 [SAR 1:1 DAR 16:9], q=2-31, 700 kb/s, 25 fps, 90k tbn, 25 tbc     Metadata:       encoder         : Lavc55.72.102 mpeg2video Stream mapping:   Stream #0:0 -> #0:0 (mjpeg (native) -> mpeg2video (native)) Press [q] to stop, [?] for help [swscaler @ 0x28794a0] deprecated pixel format used, make sure you did set range correctly     Last message repeated 1 times [swscaler @ 0x28794a0] Warning: data is not aligned! This can lead to a speedloss [swscaler @ 0x28794a0] deprecated pixel format used, make sure you did set range correctly     Last message repeated 11 times [swscaler @ 0x288aaa0] deprecated pixel format used, make sure you did set range correctly     Last message repeated 85 times [output stream 0:0 @ 0x22611e0] 100 buffers queued in output stream 0:0, something may be wrong. [swscaler @ 0x288aaa0] deprecated pixel format used, make sure you did set range correctly     Last message repeated 49 times [swscaler @ 0x28826a0] deprecated pixel format used, make sure you did set range correctly     Last message repeated 1 times frame=  150 fps=0.0 q=14.0 Lsize=     708kB time=00:00:05.96 bitrate= 973.1kbits/s     video:701kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.941622%

I want to create 5 second mp4 video from 1 image.  When I use below code the video is smooth. Default direction is zoom in to top left.  ffmpeg -loop 1 -i prop1.jpeg -vf "zoompan=z='min(zoom+0.0015,1.5)':d=125" -c:v libx264  -t 5 -s "800x450" fade.mp4   So, to zoom in to top right I figure it out to use the code below  ffmpeg -loop 1 -i prop1.jpeg -vf "zoompan=z='min(zoom+0.0015,1.5)':x='if(gte(zoom,1.5),x,x+1)':y='y':d=125" -c:v libx264  -t 5 -s "800x450" fade.mp4   It is zooming in to the right direction but the video become jittery.  Also got some error when converting :  [swscaler @ 0x429bda0] deprecated pixel format used, make sure you did set range correctly [swscaler @ 0x429bac0] deprecated pixel format used, make sure you did set range correctly [swscaler @ 0x429bac0] Warning: data is not aligned! This can lead to a speedloss [swscaler @ 0x429bac0] deprecated pixel format used, make sure you did set range correctly Last message repeated 97 times [output stream 0:0 @ 0x37af200] 100 buffers queued in output stream 0:0, something may be wrong. [swscaler @ 0x429bac0] deprecated pixel format used, make sure you did set range correctly Last message repeated 24 times [swscaler @ 0x42b7040] deprecated pixel format used, make sure you did set range correctly Last message repeated 1 times   What is wrong with the code?


just recieved new android phone which should be 1GB ROM AND 8GB RAM. ANTUTU tells me the following   memory               840.2/1008.3 MB RAM                  175.7/967.5 MB Internal SD card    5558.3/5564.6 MB  I'm new to Android and smartphones and am not sure exactly what these figures tell me nad if they are correct or acceptable for an 1GB/8GB phone ? Can anyone help me with this ?  Thanks .John.

I have an HTC Wildfire (the original, not the S version). It is supposed to have 512MB of memory. When I check my free space in the app manager I noticed I have around 185MB. Why is this?  I am using CyanogenMod which is around 80MB, if this wasn't accounted for there is still a lot of space missing. Why is my phone reporting so little?


A short story of a science fiction collection set on a ship or freighter in space from the captain's point of view. He once refers to his second in command or pilot as "Little One".  The male and female clones (possibly 10 or more) of a single person come aboard. Even though genetically brothers and sisters (or twins), they have sex together and the captain wonders if he can approach one of the women.

I'm looking for a story I read in the 90s - I'd guess it's 20-30 pages long.  Two men are posted as scientific observers on an isolated planet for many years.  Despite their differences, they learn to get along and survive the solitude.  One day, a team of 12 identical clones arrives.  There are 6 males and 6 females who were cloned from a brilliant male biologist (by adding X chromosomes, etc.).  They are super close to each other; each one specializes in a different field of science, they all sleep together, and they don't really communicate well with outsiders.  The point of the story is the contrast between the original pair's way of dealing with differences and the clone's identical, in-built similarity which makes those skills unnecessary.  A disaster on the planet results in the death of some of the clones & explores the psychological aftermath of the breakup of their unit.


I have:    var datahere; var url = "/example.txt"     example.txt has the text "Hello World"  How do I get datahere to equal this string outside of any request?  I'm happy to include PHP into the equations if necessary.

I need to do an  request in JavaScript. What's the best way to do that?  I need to do this in a Mac OS X dashcode widget.


How to find infinite sum How to find infinite sum $$1+\dfrac13+\dfrac{1\cdot3}{3\cdot6}+\dfrac{1\cdot3\cdot5}{3\cdot6\cdot9}+\dfrac{1\cdot3\cdot5\cdot7}{3\cdot6\cdot9\cdot12}+\dots? $$   I can see that 3 cancels out after 1/3, but what next? I can't go further.


Why did the developers make Dexterity add to damage on DEX-based attacks? Are there statements by the writers/developers describing why DEX bonus is on damage done as well as to hit rolls? Have they said anything about how to justify your DEX applying as a damage bonus?  Is it like a vital strike?

Finesse weapons allow you to use Dex for attack and damage rolls. This allows most of classes, including even some first-line fighters, to dump Str for Dex - you do not lose in attack rolls, only a little bit in damage rolls (there are no finesse two-handed weapons, but a rapier with d8 dmg is still pretty good), you gain a lot in AC, and as a bonus you have excellent ranged attacks. You cannot really grapple etc., but you easily avoid such attacks.  Having low Str incurs some limitations like lower carrying capacity, but this seems to be more than offset by having good Dex skill checks. All in all, having a power-focused fighter against a fighter with this kind of optimization, my bets would be strongly on the second one. Am I missing something?  (Of course, the DM can have something to say on that, and it may also look like poor role-playing; but let's put aside those for now.)


I'm running Ubuntu 16.04 LTS. I used sudo apt-get autoremove  Reading package lists... Done Building dependency tree        Reading state information... Done The following packages will be REMOVED:   apt-clone archdetect-deb canonical-poke dmeventd dmraid   gir1.2-timezonemap-1.0 kde-config-screenlocker kinit kio kpackagelauncherqml   kpackagetool5 kpartx kpartx-boot kwayland-data kwayland-integration kwin   kwin-common kwin-data kwin-x11 libbonobo2-0 libbonobo2-common libdb5.3++   libdebian-installer4 libdevmapper-event1.02.1 libdmraid1.0.0.rc16 libfam0   libgnome-2-0 libgnome2-common libgnomevfs2-0 libgnomevfs2-common   libkdecorations2-5v5 libkdecorations2private5v5 libkf5activities5   libkf5archive5 libkf5attica5 libkf5auth-data libkf5auth5   libkf5bookmarks-data libkf5bookmarks5 libkf5calendarevents5   libkf5codecs-data libkf5codecs5 libkf5completion-data libkf5completion5   libkf5config-bin libkf5config-data libkf5configcore5 libkf5configgui5   libkf5configwidgets-data libkf5configwidgets5 libkf5coreaddons-data   libkf5coreaddons5 libkf5crash5 libkf5dbusaddons-bin libkf5dbusaddons-data   libkf5dbusaddons5 libkf5declarative-data libkf5declarative5   libkf5globalaccel-bin libkf5globalaccel-data libkf5globalaccel5   libkf5globalaccelprivate5 libkf5gpgmepp5 libkf5guiaddons5 libkf5i18n-data   libkf5i18n5 libkf5iconthemes-bin libkf5iconthemes-data libkf5iconthemes5   libkf5idletime5 libkf5itemviews-data libkf5itemviews5 libkf5jobwidgets-data   libkf5jobwidgets5 libkf5kcmutils-data libkf5kcmutils5   libkf5kdelibs4support-data libkf5kdelibs4support5 libkf5kdelibs4support5-bin   libkf5kiocore5 libkf5kiofilewidgets5 libkf5kiontlm5 libkf5kiowidgets5   libkf5newstuff-data libkf5newstuff5 libkf5notifications-data   libkf5notifications5 libkf5package-data libkf5package5 libkf5parts-data   libkf5parts-plugins libkf5parts5 libkf5plasma5 libkf5plasmaquick5   libkf5quickaddons5 libkf5service-bin libkf5service-data libkf5service5   libkf5solid5 libkf5solid5-data libkf5sonnet5-data libkf5sonnetcore5   libkf5sonnetui5 libkf5textwidgets-data libkf5textwidgets5 libkf5wallet-bin   libkf5wallet-data libkf5wallet5 libkf5waylandclient5 libkf5waylandserver5   libkf5widgetsaddons-data libkf5widgetsaddons5 libkf5windowsystem-data   libkf5windowsystem5 libkf5xmlgui-bin libkf5xmlgui-data libkf5xmlgui5   libkscreenlocker5 libkwalletbackend5-5 libkwin4-effect-builtins1   libkwineffects7 libkwinglutils7 libkwinxrenderutils7 liblvm2app2.2   liblvm2cmd2.02 liborbit-2-0 libparted-fs-resize0 libphonon4qt5-4   libpolkit-qt5-1-1 libqt4-designer libqt4-help libqt4-opengl   libqt4-scripttools libqt4-test libqt5script5 libqtassistantclient4   libqtwebkit4 libreadline5 libvoikko1 libxcb-composite0 libxcb-cursor0   libxcb-damage0 linux-headers-4.4.0-23 linux-headers-4.4.0-23-generic   linux-headers-4.4.0-40 linux-headers-4.4.0-40-generic   linux-image-4.4.0-23-generic linux-image-4.4.0-40-generic   linux-image-extra-4.4.0-23-generic linux-image-extra-4.4.0-40-generic   linux-signed-image-4.4.0-23-generic linux-signed-image-4.4.0-40-generic   linux-tools-4.4.0-23 linux-tools-4.4.0-23-generic lvm2 plasma-framework   python3-icu python3-pam python3-pyqt4 python3-sip   qml-module-org-kde-kquickcontrols qml-module-org-kde-kquickcontrolsaddons   rdate sonnet-plugins 0 upgraded, 0 newly installed, 164 to remove and 0 not upgraded. After this operation, 803 MB disk space will be freed. Do you want to continue? [Y/n] y   Did it remove some stuff that was not to be removed?

I was compiling a tool called Rejoystick so I installed a few packages and dependencies. But now I don't need it any more so I removed those packages. Running apt-get shows that I have some packages that are automatically installed and are no longer needed.   But I have a bad experience with apt-get autoremove. It broke my desktop environment when I uninstalled wine some time ago. Luckily, I had a clonezilla partition backup then, but this time, I don't have a backup. So I'm cautious. Running apt-get shows these packages are orphaned     gir1.2-gtk-2.0 libasound2-dev libavahi-client-dev libavahi-common-dev   libcaca-dev libcairo-script-interpreter2 libdbus-1-dev libdrm-dev   libexpat1-dev libfontconfig1-dev libfreetype6-dev libgl1-mesa-dev   libglu1-mesa-dev libharfbuzz-dev libharfbuzz-gobject0 libice-dev   libpcre3-dev libpcrecpp0 libpixman-1-dev libpng12-dev libpthread-stubs0-dev   libslang2-dev libsm-dev libx11-dev libx11-doc libx11-xcb-dev libxau-dev   libxcb-dri2-0-dev libxcb-dri3-dev libxcb-glx0-dev libxcb-present-dev   libxcb-randr0-dev libxcb-render0-dev libxcb-shape0-dev libxcb-shm0-dev   libxcb-sync-dev libxcb-xfixes0-dev libxcb1-dev libxcomposite-dev   libxcursor-dev libxdamage-dev libxdmcp-dev libxext-dev libxfixes-dev   libxft-dev libxi-dev libxinerama-dev libxrandr-dev libxrender-dev   libxshmfence-dev libxxf86vm-dev mesa-common-dev x11proto-composite-dev   x11proto-core-dev x11proto-damage-dev x11proto-dri2-dev x11proto-fixes-dev   x11proto-gl-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev   x11proto-record-dev x11proto-render-dev x11proto-xext-dev   x11proto-xf86vidmode-dev x11proto-xinerama-dev xorg-sgml-doctools xtrans-dev   zlib1g-dev   I'm not sure if I should run apt-get autoremove. I was searching details related to each of these packages so that I can understand which ones are needed but they all seem important e.g.     gir1.2-gtk-2.0    I have Cinnamon, GNOME and Unity installed, I think apt-get autoremove will break something. Any help will be appreciated.   Thanks for reading.


I have OS X v10.9. I downloaded v10.8 installer from the AppStore in order to install it on an external drive. However, when launching the installer it says that it can't be installed on this computer and give no option other than quit.  What's the easiest way to do install 10.8 on an external drive when I already have 10.9 installed?  I'm aware that there are some answers about downgrading from 10.9, but I wonder if there is any easier way than the hard process described in other places for downgrading.  Edit: THIS IS A MID-2011 MBP so it did not come with Macericks pre-installed.

I am using 10.9 and would like to install 10.7 on an external volume. I have the “Install Mac OS X Lion” application, but when I run it, I get the message     This version of Mac OS X is too new to run “Install Mac OS X” from Mac OS X 10.7.   Well, I do not want to downgrade, I just want to have a way to boot into 10.7. Is there any way around this?


I am a little confused as to what constitutes a fair question on SO.  I posted a question, that some thought to be subjective and was downvoted, followed by 3 votes to close.    I responded with a comment asking people to flag a question as off topic and move it to Programmers SE if they thought it was too subjective.  Instead, the post was closed as "subjective and argumentative."    Honestly, I participate pretty heavily in Programmers SE and I do not feel this question would have been closed as a bad-subjective.  That's why I made the recommendation in the first place.  But, since they went ahead and closed my question anyways, I asked for the question to be deleted.  They refused deleting the question because it had been upvoted.  I had actually asked to delete the question because I felt my question was answered.  I also did not want others downvoting my question, especially seeing the question was closed.    This whole ordeal makes me feel as if moderation is still too literal on SO.  Too many users do not understand what Programmers is for or the definition of good-subjective questions (as can be seen in the comments).    I feel that more people with the ability to close questions, and just in general need to be more aware of the SE faq's.  Second, moderators should also be aware of not just what the FAQ states, but also how they are interpreted and "play out" for real on Programmers.  This will prevent a lot of unecessary downvoting and closing of real questions.  Update  Now people are downvoting my post on SO. Thanks.

I frequently come across a really useful answer on StackOverflow which has been closed because it doesn't match the Q&A format.  Examples include  ,  ,   ,  and there are others.  Where should this information be exchanged if it's not on stackoverflow?  It seems the moderators are often somewhat overzealous...  ---edit  When I say best, I mean they are informative and useful for someone who's looking for an answer to them.  Even if they do become a bit of a discussion, I value other people's opinions on the relative merits of the different JPA frameworks.  I come here looking to choose one and the answer helps me.  So what if it's not a definitive answer?  ---edit  I don't care how popular a question is, nor how interesting it is.  Users are interested in stuff that's useful to them.  Plenty of those were useful (as judged by the upvotes on the answers: 'This answer is useful'), but closed because they didn't have a definitive answer, as far as I can tell.  ---edit  Seems I'm not the first person to think this: there are various similar questions to mine like this one:   In it the user lists lots of other useful questions which have been closed:                    So isn't there a place on stackoverflow for these questions?  A discussion section, maybe?


how can I use a variable in match() if I want to use regex? This works fine for me:  if (message.match('!' + cmd)) {   this.client.say(to, myJson[cmd]); }   but if I try something like this it will not check the variable.      if (message.match(/!cmd/i)) {       this.client.say(to, myJson[cmd]);     }   I already searched for a solution but could only find something for replace.  Edit: it's not a duplicate of  as it explains it for replace not match.

I would like to create a String.replaceAll() method in JavaScript and I'm thinking that using a regex would be most terse way to do it.  However, I can't figure out how to pass a variable in to a regex.  I can do this already which will replace all the instances of "B" with "A".  "ABABAB".replace(/B/g, "A");   But I want to do something like this:  String.prototype.replaceAll = function(replaceThis, withThis) {     this.replace(/replaceThis/g, withThis); };   But obviously this will only replace the text "replaceThis"...so how do I pass this variable in to my regex string?


I'm studying for an exam and I can't seem to understand data structures & algorithm complexity i.e. I know that a linked-list has insert, get , delete method implementation, but what I cannot understand about it is 0(n) or 0(1). I know that n means list size and 1 means linear but I don't understand the 0 or O. If you can explain what complexity is and how it works I'd be grateful. So if you could please help me. Thank you.

I'd prefer as little formal definition as possible and simple mathematics.


I'm trying to prove the sum of reciprocals from 1 to (p-1) is divisible by p^2.  Someone showed me how to prove it. But there's a step which I don't grasp. (Or maybe I misunderstood.)  He changed the form of the sum from 1+1/2+...+1/(p-1) to p{1/(p-1)+1/2(p-2)+...+1/{(p-1)/2×(p+1)/2} and first considering only the sum of 1/(p-k)k where k is from 1 to (p-1)/2.  He said in the numerator of the sum of 1/(p-k)k , will appear every term of (p-k)k from 1 to (p-1)/2.   But I cannot show how to gurantee it.  Could you give me any hints or advice?

Write $\frac 11 + \frac12 + ...\frac1{(p-1)} =$ $\frac ab$.Such that $(a,b)=1$. Show that $p^2 \mid a$ $\text{if}$ $p\geq 5$.  I was trying to apply something with prime modulus, but I am unsure how exactly to go about it.


Is $\mathbb{Z}[\sqrt{-1}]/(7)$ isomorphic to $\mathbb{Z}[\sqrt{-2}]/(7)$?  Here $(7)$ is the ideal generated by $7$.  If so, please tell me the explicit isomorphism. And how you  come up with the construction?

I was having some trouble finding an explicit isomorphism between $\mathbb{Z}[i]/(7)$ and $\mathbb{Z}[\sqrt{-2}]/(7)$.  $\textbf{What I have noticed is}:$   7 is a prime element in $\mathbb{Z}[i]$ so $(7)$ is a maximal ideal in $\mathbb{Z}[i]$ and $\mathbb{Z}[i]/(7)$ is  a field.  7 is also a prime element in $\mathbb{Z}[\sqrt{-2}]$   $\textbf{What I have been trying to do is this}$   Find a surjective homomorphism between $\mathbb{Z}[i]/(7) \rightarrow \mathbb{Z}[\sqrt{-2}]/(7)$. Since $\mathbb{Z}[i]/(7)$ was a field, the kernel of this homomorphism will be either the whole ring or just $0$. In the latter case it would be a isomorphism.    I am having trouble finding this surjective homomorphism:  I have noticed that $\bar{{i}}^{2}=-1$ so the image of $\bar{{i}}$ must be sent to something whose square is $-1$. Any help would be appreciated. I may be missing some obvious insight.


I think Goldbach's conjecture is quite well-know at this point, but there is no problem restating it: any even integer greater than $2$ can be written as the sum of two prime numbers.  But what about distinct prime numbers? For every even integer $n$ that does not equal $2p$, for $p$ a prime, Goldbach's conjecture obviously implies that $n$ can be written as the sum of two distinct prime numbers, but the question in the title remains: what if $n=2p$? (Ignore $p=3$, which clearly fails...)  I tested all prime numbers up to 10.000.000 and found no exceptions.

The strong Goldbach conjecture postulates that every even number can be expressed as the sum of two primes.  An even number that is just twice a prime is considered a valid exemplar.  For low values of n, I cannot find any example of a number that is not the sum of two distinct primes.  Among the integers that have been looked at, are there any instances of an integer 2p that can only be expressed as p + p?


I want to find the condition of a group $G$ such that for all $a\big||G|$, there exists $H\leq G, |H|=a$. For instance, If $G=C_n$, then for all $a|n$, $C_a\leq C_n$, so $C_n$ satisfies the condition.

It is known that the converse of  isn't true in general. More precisely it is known that the following proposition:  If $G$ is a finite group of order $n$ and $m\mid n$ then there exists a subgroup $H$ of $G$ such that $\operatorname{order}(H)=m$.  isn't true for all finite groups $G$. My questions are:   For which groups $G$ does the converse of Lagrange's Theorem (as stated above) hold? More precisely, if $G$ is a group for which the converse of Lagrange's Theorem as I mentioned above holds then what properties must $G$ satisfy?  If there is no complete classification of such $G$s then can someone give me references to works by other mathematicians where they try to give at least a partial classification of these $G$s?    Please note that I am not interested in knowing a complete classification of the groups for which a partial converse holds ( does the job in some sense). I want to know a complete classification of the groups for which the converse of Lagrange's Theorem as I mentioned above holds.


How can we differentiate when to use “to” or “for” for example: To me/for me, it’s important to know if we can make reservation at this hour.

I cannot easily figure out which one is more appropriate to use:     It's important to me.        It's important for me.   Are they the same? If not, what's the difference?


I'm running Mac OS X 10.4.11 on a 2007 MacBook. I want to upgrade to Mavericks, but I can't do so without using the Mac App Store to download the upgrade. Tiger doesn't have the Mac App Store. How can I get around this?

If I buy a regular retail Snow Leopard disc (i.e. the £25 version), can I use it to upgrade a Mac from Tiger (10.4)?   on the Apple Store’s Q&A site suggests it’ll work, but Apple seem to imply that you need the (significantly more expensive) Mac Box Set (“”).


I have been playing pokemon go for about a week now and the game worked perfectly all this time. But recently when I logged in, the game fails to detect any of the nearby gyms or pokestops. There are'nt any nearby pokemon shown in the box below as well.There are like 2 pokestops and 3 gyms in my area but the game is not detecting any of them for a couple of days now.

Pokemon GO isn't working at all for me right now. I'm in one of the following circumstances and can't do anything:   My game is displaying a "Try Again" message I'm stuck on the Loading Screen When I sign in I get a message that the servers are experiencing problems. I see the map but nothing is loaded, and my team color is wrong The "loading" Pokeball just ends up spinning and I can't catch or interact with things When I try to catch a Pokemon, the Pokeball just sits on my screen doing nothing Gym opponents will drop to 1 HP and won't take any more damage or attack When I open a pokestop, the pokestop image and the name of the pokestop does not load.   What's causing this? Is there a way to fix it?


I am building a new PC. I am planning on having both a SSD and HDD.  I want to install the latest Ubuntu release to, and have the PC boot from and run the OS from, the SSD.   I also want any files, such as pictures, music, docs, etc to automatically be written to and saved on the HDD.  This will keep the SSD/OS relatively "clean" and allow for the fastest possible boot.  The forums here have a lot of posts about Dual booting Windows 7 and Ubuntu, moving a system over to SSD, cloning from HDD to SSD, etc. I cannot seem to find a post on this exact subject. If there is one, can somebody direct me to it.   Note that I am a noob when it comes to Linux. I have studied and understand how to do such an install and disk(s) setups on Windows 7 and Windows 8.

I would like to see a full how-to guide on how to install Ubuntu.


I am a beginner to use linux os.  What is the basic packges needed to install to compile a C,C++ code in terminal box ? and, please give the command to install it .  :(

Is there a need to install a C/C++ compiler in Ubuntu 14.04 LTS? Where to write the program? How to compile the same?


Once a user has editing privileges, how many edits can a user make per day on posts generally per site?  This  does not give information about the total limit per day

5 edits on own posts per day, more for high-rep users (scales with reputation)    does not say anything about the exact number a high-rep user can have. Can someone tell me how many edits can a high-rep user have(not just on his own posts)?


I have multiple objects in my scene and I have multiple light sources in it. How can I make that a certain light source affects just one selected object so it doesn't affect other objects in the scene? My render engine is Cycles.

Is (or will be) there any sort of light linking in Cycles, or a method to get a light to affect only certain objects that doesn't involve compositing two or more different render layers? Sort of what 3Dstudio does with the Include/Exclude methods.


Let $f$ and $g$ be continous functions and $f(x)\neq 0$ forall $x$. Prove that $f^2(x)=g^2(x)$ forall $x$ then $f(x)=g(x)$ forall $x$ or $f(x)=-g(x)$ forall $x$.  It 'is so apparent, so I don't know what must I do, and with similar problems, do we have the general solution? Thank you!

Let $f,g:[a,b]\subset \mathbb{R} \to \mathbb{R} $ be continuous functions with $f^2(x)=g^2(x)\neq 0$ for all $x\in[a,b]$. Show $f=g$ or $f=-g$ on $[a,b]$.


People seem to think it's risky to do this.  But I'm trying to work with Android Studio which is enormous.  It's made my AppData folder literally 30 Gb with all the images of virtual machines and different versions of the libraries in the SDK.  I installed Android Studio itself on another drive, but it's still putting all its junk in AppData. My C drive is now full, and the only way I can imagine solving this problem without breaking Android Studio is if I can move AppData itself behind a symlink.  I saw instructions here :   But it suggests if I click on properties on the folder I'll find a move option. There's nothing like this on the properties pop up.  So. Is it possible? If so, how?  Is it dangerous / a bad idea? If so, what can I do about Android Studio which seems determined to use AppData rather than the directory where I put it.

I have 3 Drives, Boot(C:), Data(D:) and Restore(E:) My C: , which has 116 GB is full, and most of it is in my Appdata\Local (50GB) My D: has 377GB Free Space and I wanted to Know if it is safe to move the AppDta folder to it.  I did this with the Appdata\roaming yesterday and it did not work but after a restart it was back to normal and this time I searched for it on google and made a User\username\AppData folder in my D: drive and went to the properties of Local and manually moved it to the new folder like the search told me and after opening the Local\ElevatedDiagnostics Folder which had admin rights it was possible for me and it is copying everything right now   Will this work? and if not, will it be easy to return back to the previous state like with the roaming folder?


I want to add charts on my web map in a way that when i click on the point the chart appears in the pop up field.      Do i have to add it as an image in the attribute?  Can i do that when the pictures are in my hard drive and not in a html form?

Does anyone know if it is possible to add hyperlinks to image fields etc. in the pop-up windows of Qgis2web?  I've had a look in the layers javascript file, but the image source path isn't rendered using html, so I can't simply append <a href" to it.  The image is coming in via the usual method of having a field that contains the path of the image file.  I'd like to achieve linking of the image, like in the example below. Alternatively, I could just populate the 'more info' field with the URL, but if I did that I'd like to avoid just doing it by having a field that contains the entire URL, as some may be quite long (these will only be internal links).


Why can't I see or buy the Karin Kuruma on southernsanandreasuperautos.com? I have the 100k one. I have already done the Fleeca Job but I can't find it or buy it again.  I am playing on the PS3.

Why can't I find the Karin Kuruma car in the southernsanandreasuperautos.com website? Do I have to do a specific heist/setup/mission or be at a certain level? I'm level 25 in GTA Online.


n-th harmonic number is:  $H_n=\sum_{k=1}^n\frac1k$  is there some $n\neq1$ for which $H_n$ is a natural number?  Or can it be proven that there is no such number?

If $n>1$ is an integer, then $\sum \limits_{k=1}^n \frac1k$ is not an integer.  If you know , then you know there must be a prime $p$ between $n/2$ and $n$, so $\frac 1p$ appears in the sum, but $\frac{1}{2p}$ does not. Aside from $\frac 1p$, every other term $\frac 1k$ has $k$ divisible only by primes smaller than $p$. We can combine all those terms to get $\sum_{k=1}^n\frac 1k = \frac 1p + \frac ab$, where $b$ is not divisible by $p$. If this were an integer, then (multiplying by $b$) $\frac bp +a$ would also be an integer, which it isn't since $b$ isn't divisible by $p$.  Does anybody know an elementary proof of this which doesn't rely on Bertrand's Postulate? For a while, I was convinced I'd seen one, but now I'm starting to suspect whatever argument I saw was wrong.


Which one of the following is correct?   Each employee wanting their workday adjusted or time off to vote must request it from their supervisor.  or Each employee wanting his/her workday adjusted or time off to vote must request it from his/her supervisor.     Thanks  GeorgeV

I know that one can use "they" / "them" / "their" in place of "he" / "him" / "his" or "she" / "her" / "hers" when the subject's / direct object's gender is not known; for instance, just looking at the default user's about me section on Stack Exchange sites:     Apparently, this user prefers to keep an air of mystery about them   My question is what happens when someone wants to reference the subject using a pronoun instead.  Should the verb be conjugated accordingly to the pronoun? E.g.:     Apparently, they prefer to keep an air of mystery about them   Or should the conjugation be retained? E.g.:     Apparently, they prefers to keep an air of mystery about them   The former looks unclear because it wouldn't allow the reader / listener to understand if the writer / speaker is talking about a single person or about a group of people, however the latter sounds very weird, at least just to the non-native speaker which I am.


Using Ubuntu 16.04, I have a problem with python3  $ python --version Python 2.7.12  $ sudo apt-get install python3 Reading package lists... Done Building dependency tree        Reading state information... Done python3 is already the newest version (3.5.1-3). The following packages were automatically installed and are no longer  required:   linux-headers-4.8.0-53 linux-headers-4.8.0-53-generic   linux-image-4.8.0-53-generic linux-image-extra-4.8.0-53-generic Use 'sudo apt autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 4 not upgraded.  $ python3 bash: /usr/lib/command-not-found: /usr/bin/python3: bad interpreter: No such file or directory

The python program command executes Python 2. Python 3 can be executed using the python3 command.  How can Python 3 be executed using the python command?


I need to split a string that I receive like that : my_string = "\data\details\350.23.43.txt"  when I use my_string.replace ("\\", "/") it returns : /data/detailsè.23.43.txt It's considering the \350 in my string as a special character 'è'

I have a string that contains both double-quotes and backslashes that I want to set to a variable in Python. However, whenever I try to set it, the quotes or slashes are either removed or escaped. Here's an example:  >>> foo = 'baz "\"' >>> foo 'baz ""'   So instead of baz "\" like I want I'm getting baz "". If I then try to escape the backslash, it doesn't help either:  >>> foo = 'baz "\\"' >>> foo 'baz "\\"'   Which now matches what I put in but wasn't what I originally wanted. How do you get around this problem?


Show that:  $\mathbf{A_4}\oplus\mathbf{Z_3}$ has no subgroup of order $18$  $|\mathbf{A_4}\oplus\mathbf{Z_3}|=36$ so subgroup $\mathbf{H}$ has index $2$  and must be normal.   Thus the quotient group $\frac{\mathbf{A_4}\oplus\mathbf{Z_3}}{H}$ exsists and has only two elements.  Now if $\alpha\in\mathbf{A_4}\oplus\mathbf{Z_3}$ then ${\alpha}^2\mathbf{H}={(\alpha\mathbf{H})}^2=\mathbf{H}$  Thus ${\alpha}^2\in \mathbf{H}$  How can I now show there more than $18$ elements for which ${\alpha}^2$ doesnot belong to H   I know there are six elements of order $2$ in  $\mathbf{A_4}\oplus\mathbf{Z_3}$.  THANKS.

Here my solution: Suppose there exists and $H \leq A_4 \oplus Z_3$ such that order of H is 18. Now, notice index of H in $A_4 \oplus Z_3$ is 2. therefore, H is normal, and therefore, the $A_4 \oplus Z_3 / H$ exists. Now, for every $\alpha$ in $A_4 \oplus Z_3$, $\alpha^2H = (\alpha H)^2 = H$ since the quotient group has order 2. But notice, $A_4$ has only 3 elements of order 2, therefore, $A_4 \oplus Z_3$ have only 3 elements of order 2, which implies H has 3 elements of order 2 and the rest must have order 1, and this is an absurd.  Is this a correct solution? Do you guys have any other solution?   thanks,


I want to search in the  column "Position" for duplicates and want remove the entire row.  this my data frame dfZ1      structure(list(Position = c("01.0401  Z", "02.0714A  Z", "02.0715D  Z",  "02.0715E  Z", "10.1805T  Z", "10.1805V  Z", "10.1808I  Z", "35.9008A  Z",  "98.0408A  Z", "01.0401 Z", "02.0715D Z", "02.0714A Z", "99.0408A Z",  "35.9008A Z"), Stichwort = c("Grundlegende Charakt. gem. DVO",  "Bestandspläne Kanal LP und LS", "Aufp. für koord. Aufnahme und Einb. in GIS",  "Bestandspläne Stauraumkanal", "GF-UP-Kanalrohr, PN1, DN 1800, SN 10, gew. lief.u.verl.",  "GF-UP Abschlusskappe, PN1, DN1800, SN10  lief.u.verl.", "Aufz.angef.GF-UP Schacht.DN 1000 auf DN 1800",  "Abflussregler 10-30 l/s", "Schrämmhammer mit Schlauch", "DVO reg",  "GIS", "LS", "Neu", "Regler"), Einheit = c("Stk", "m", "PA",  "PA", "m", "Stk", "Stk", "Stk", "h", "stk", "m²", "VE", "VE",  "Stk")), row.names = c(NA, 14L), class = "data.frame")    I already tried (and a lot of other things):  dfZ1[!duplicated(dfZ1[c("Position")]),]   but i didn't work.   Any ideas?  THX

What is the best way to remove duplicate rows from a fairly large SQL Server table (i.e. 300,000+ rows)?  The rows, of course, will not be perfect duplicates because of the existence of the RowID identity field.  MyTable  RowID int not null identity(1,1) primary key, Col1 varchar(20) not null, Col2 varchar(2048) not null, Col3 tinyint not null


In the Renderman Shading Language, the whole purpose of a shader is to determine the final pixel color for each fragment. You have complete control over what the shader does and what the final color is. If you have a scene with a mountain covered in snow, with trees in the foreground and a lake, if you want the whole image to be completely red--like (255, 0, 0) red in every single pixel--you can do that by setting the final color at the end of each shader. It can completely disregard the lights, image textures and geometry.  Is this possible in Cycles or OSL? I realize that the REYES algorithm is a very different beast than OSL closures in a unidirectional path tracer. But, can I override the physically-based-ness of Cycles in a shader?

I'm trying to make a material node setup to set final render colors, regardless of lighting conditions. Is such a setup possible?


I have the following trigger and I would need some help in creating the test class.   trigger listingLocationUpdate on pba__Listing__c (before insert, before update) {      //Mantiene actualizado el picklist Location en base al lookup Location     List<pba__Listing__c> listings = Trigger.new;     Map<Id, pba__Listing__c> oldListings = null;     if (!Trigger.isInsert) {         oldListings = Trigger.oldMap;     }      for (pba__Listing__c listing : listings) {          if (!Trigger.isInsert) {             pba__Listing__c oldListing = oldListings.get(listing.Id);             if (oldListing.Location__c == listing.Location__c) {                 continue;             }         }         if (listing.Location__c == null) {             listing.fm_Location__c = null;             continue;         }          pba__Location__c l = [Select Name from pba__Location__c where Id =:listing.Location__c];         if (l != null) {             listing.fm_Location__c = l.Name;         }      }   }

How do I write a unit-test / test class for a trigger?  What are my options?   Inline with the trigger?  New Class?


I want to answer letter $(b)$ in this question: Let $R$ be an integral domain and let $R[[x]]$ be the corresponding ring of formal power series. $(a)$ Show that $R[[x]]$ is an integral domain. $(b)$Show that $R[[x]]^*$ consists of the series $\sum_{n \geq 0}a_{n}x^n (a_{n} \in R)$ such that $a_{0} \in R^*.$ My question is: I found a solution here  in case of $R$ a ring, I am wondering how will my solution differ as my $R$ is an integral domain?

Is there any way to calculate the multiplicative group of the units of power series ring $k[[x]]$, where $k$ is a field ?


The icons look squished and cropped wrong. I've repro'd this on several sites.

On both the full site and mobile theme, when viewed from Android and Chrome,  the site icons are misaligned as seen below on the drop down site list. Can't replicate on my mac.    But new reports are saying this is affecting multiple systems, mobile and desktop:   Both the Site Drop Down and the HNQ use the same image and css, so it's all connected.


I'm trying to send a file to a php script through ajax, however I see that it's not being passed properly as I tried to echo that file and got a null response. How can I solve this?   HTML JS code  <script type="text/javascript"> $(function(){     $("#first").submit(function(event){         event.preventDefault();          $(this).find(".error").remove();         file = $(this).find("input[name=file_save]").val();         form = $(this);         url = $(this).attr("action");         $.post(url,{file_save:file}, function(data){                 console.log(data);         },"json");         return false;     }); });  </script>   Php script (addImages.php)  <?php $username = $_POST['files']; $tableau["error"] = $username; echo json_encode($tableau); ?>

I would like to upload a file asynchronously with jQuery.     $(document).ready(function () {     $("#uploadbutton").click(function () {         var filename = $("#file").val();          $.ajax({             type: "POST",             url: "addFile.do",             enctype: 'multipart/form-data',             data: {                 file: filename             },             success: function () {                 alert("Data Uploaded: ");             }         });     }); });  File <input type="file" id="file" name="file" size="10"/> <input id="uploadbutton" type="button" value="Upload"/>     Instead of the file being uploaded, I am only getting the filename. What can I do to fix this problem?


If I buy or build a computer with no OS, how do I get Ubuntu?  I am looking at building a PC with a tight budget and don't want to blow US$100 on Windows 10.

I need to upgrade my existing Ubuntu system, and I also want to install Ubuntu on a new laptop.  I would like to have an installation CD or DVD to do both of these.  Where exactly I can order or request an Ubuntu installation CD/DVD/USB?


class Cell {     Point ob ;     int distance;     public Cell(Point x, int i) {        try {             ob = x;// works fine             distance = i;         } catch (Exception e) {           System.out.println(e.getStackTrace());         }     }  }  class Cell {     Point ob ;     int distance;     public Cell(Point x, int i) {         try {             ob.x = x.x; // throws null pointer exception             ob.y = x.y;             distance = i;         } catch (Exception e) {             System.out.println(e.getStackTrace());         }             }  }   Error: I am getting a null pointer exception in the second code. However when I try to just assign the passed object in constructor, it works fine.

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


Let $f$ be a irreducible polynomial in $\mathbb{F}_p[x]$ of degree $n$.  Why are there $p^n$ elements in the quotient field $\mathbb{F}_p [x]/ (f)$  I am having some difficulty convincing myself this is true.  Any help or insight is deeply appreciated

Can someone please give me a hint how to prove that the quotient ring $\mathbb{F}_p[x]/{\langle f\rangle}$, where $f$ is a irreducible polynomial of degree $k$ and $p$ is a prime (and $\langle f\rangle$ the ideal generated by $f$), has cardinality $p^k$ and how to determine the dimension of $\mathbb{F}_p[x]/{\langle f\rangle}$ as a vector space ?


Today we learned about Euclidean domains in class but I don't understand why we need one of the conditions stated in the definition. We called an integral domain $R$ a Euclidean domain if there exists a function $f$ from $R$ to strictly positive integers such that:    1) For $a,b$ non zero in $R$, $f(ab)\ge f(a)$.    2) If $a,b\in R$, $b\neq 0$, then we can write $a=bq+r$ with $q,r\in R$ such that either $r=0$ or $f(r)<f(b)$.    So from what I understand the whole point of a Euclidean domain is to be able to define a Euclidean algorithm, but I don't see why (1) is needed. Furthermore later in the class we proved a Euclidean domain is a principal ideal domain and in the proof we didn't use the property (1), so my question is:      Why do we need (1) in the definition?   Thanks in advance.

Can anyone make me understand in simple language why the second condition for being an Euclidean domain is superfluous ?  Why $v(a)  \leq v(ab)$ is not needed?  How we can deduce from the first one?


If repeatedly picking a random element from a set, what is the expected number of times I'd have to pick before seeing all the elements of the set?  Edit: when picking an element, it is simply counted and not removed from the set, so it can be picked again.

What is the average number of times it would it take to roll a fair 6-sided die and get all numbers on the die?  The order in which the numbers appear does not matter.  I had this questions explained to me by a professor (not math professor), but it was not clear in the explanation.  We were given the answer $(1-(\frac56)^n)^6 = .5$ or $n = 12.152$  Can someone please explain this to me, possibly with a link to a general topic?


How do I have to include my own *.sty files in TeXstudio (with default setting, e.g. with PdfLaTeX)?  According to the log file TeXstudio uses TeX Live 2019 .  The *.sty files are organised in folders with separate subfolders e.g.  /beamer/base/themes/color/   /beamer/base/themes/font/   /beamer/base/themes/theme/  (the main *sty file ist located here, it include than e.g. corresponding color)   /briefe/ ……  and so on   kpsewhich –show-path ls-R shows the following path:  /usr/local/share/texmf /usr/share/texmf /usr/share/texlive/texmf-dist /var/lib/texmf   I have already tried to copy the *.sty folder into the first three paths as root and afterwards I executed sudo texhash.  Additionally I have created the subfolder /home/ich/texmf/tex/latex and tried to copy the sty-folder there, too, and executed texhash.  whereis texlive shows /usr/share/texlive.  kpsewhich texmf.cnf shows /etc/texmf/web2c/texmf.cnf. A comment inside it explains that /etc/texmf/texmf.d should be modified or own *.cnf should be used and then update-texmf should be invoked.  kpsewhich -var-value=TEXMFHOME shows ~/texmf.  kpsewhich -var-value=TEXMFLOCAL shows /usr/local/share/texmf.  I am using TeXstudio V 2.12.16 (Flatpak) on Linux Mint 19.3 Cinnamon.

I know how to define a package or a class, but how do I make it available (to myself) at all times?  Say I have the package file commonstuff.sty (or myprettyclass.cls), that I want to be able to include in any .tex file I create on my computer. Where do I put it? Do I need to run some installer on it, or is it enough to keep it in a certain folder?  Note: I know I can just place it in the same folder as the .tex file, but that's not what I'm after here. I'm looking for a way to "install" the package centrally on my computer.


Electron is the source of electric field and changing electric field produce magnetic force, what about particle that can do vice versa? My concern is how come universe favors particles that carry electric charge but not magnetic charge? What prevailing theory can explain this discrepancies?

One thing I've heard stated many times is that "most" or "many" physicists believe that, despite the fact that they have not been observed, there are such things as magnetic monopoles.  However, I've never really heard a good argument for why this should be the case. The explanations I've heard tend to limit themselves to saying that "it would create a beautiful symmetry within Maxwell's equations" or similar. But I don't see how the fact that "it would be beautiful" is any kind of reason for why they should exist! That doesn't sound like good science to me.  So obviously there must be at least another reason apart from this to believe in the existence of natural magnetic monopoles. (I'm aware that recent research has shown that metamaterials (or something similar) can emulate magnetic monopole behaviour, but that's surely not the same thing.) Can anyone provide me with some insight?


Can I use my existing Windows partitions to install Ubuntu? I don't want to loose files and I also don't want to change the partitions. Thanks in advance.

I would like to see a full how-to guide on how to install Ubuntu.


On my Windows 7 computer, I created some custom user environment variables (right-click computer > properties > "Advanced system settings" > "Environment Variables..." > "New..." for "User variables for ...") but when I echo them in command prompt it seems to not recognize one. For example, this is what I had:  UTILS_HOME  C:\myUtils UTILS_WILDFLY  %UTILS_HOME%\wildflyUtils   I added both to the PATH variable in my user variables like this:  PATH  %UTILS_HOME%;%UTILS_WILDFLY%   When I echo the PATH I get this:  C:\mytils;%UTILS_WILDFLY%   I expect that it would expand UTILS_WILDFLY but doesn't. Now if I change the name of UTILS_WILDFLY to JBOSS_8, when I echo the path it'll get expanded. I've tried several names for testing and do not understand why some expand and why some do not. When they do not expand I'm not able to access my scripts in that folder on the command line.  Is there some rule that I don't know about for naming environment variables or is this the way it works and I have to do trial and error until I find one that does work?  There are no typos when trying different names. I created the name for the variable and cut and paste it in the PATH variable to rule that out.

My colleague and I have identical Dell workstations with Windows XP Professional x64 edition installed.  My Path environment variable starts with:  %JAVA_HOME%\bin;...   My colleague's Path variable includes the same directory, specified using the same environment variable, but it is not the first item in his Path.  If I access system properties -> environment variables and change the value of my JAVA_HOME variable, the version of java found from the command-line changes as I expect. This is starting a brand new console window, to be sure to pick up the changes.  But on my colleague's machine, it does not.  He continues to find his previous version of Java until he brings up his Path variable and saves it (even if he makes no changes to it).  (Again, this is when starting a brand new console window.)  I have been observing this inconsistency on Windows for about 6 months now and very curious about it.  We have way too many versions of Windows in our office, so rarely have I had a chance to see this happening on two machines running the exact same OS version, until now.  What is causing this?  Why does his machine not re-evaluate Path, using the new JAVA_HOME, when mine does?  (Is it because it's not the first thing in the Path?  If so, how could that be, and why?  I'd do more tests to check, but I think he's now fed up with it and would like to get back to work.)


$D_4$ here indicates the dihedral group of order 8. Does there exist any trivial example of topological spaces such that it has $D_4$ as it's fundamental group.

I am studying elementary Algebraic Topology recently. I have seen that a topological space is identified with a group. We are telling the group as Fundamental Group. So every topological space $X$ and for any $x \epsilon X$ there is a fundamental group $\pi_1 (X,x)$. I have a question about the converse. If we consider any arbitrary group $G$, then does there exist a topological space $X$ and an element $x\epsilon X$ such that $\pi_1 (X,x)=G$?


Suppose I have the set of polynomials $P$ in one real variable.   $p(t) = t^3 + 2t^2 + 3t + 5, p ∈ P$.  And I have an equivalence relation $\sim$ on P defined as $a \sim b$ if $a = b + pq$ for some $q \in P$.  How can I show that each equivalence class has a unique representative of a degree less than $3$?

Is there a nice way to perform calculations within a quotient ring? for instance, an exercise I had was to show $\mathbb{Z}[X]/(X^2+1) \cong \mathbb{Z}[i]$, but this got me thinking; If I didn't know this, how could I calculate in $\mathbb{Z}[X]/(X^2+1)$ easily?  (and of course any other general quotient ring)?


If I am comparing the effect of age, sex, location (numerical) on various numerical parameters, but one of these responses are not normally distributed, can I still do a factorial ANOVA? I can't do a Kruskal Wallis test as I am comparing so many variables. EDIT: Anderson-Darling normality test gave a p-value of <0.005

This issue seems to rear its ugly head all the time, and I'm trying to decapitate it for my own understanding of statistics (and sanity!).   The assumptions of general linear models (t-test, ANOVA, regression etc.) include the "assumption of normality", but I have found this is rarely described clearly.   I often come across statistics textbooks / manuals / etc. simply stating that the "assumption of normality" applies to each group (i.e., categorical X variables), and we should we examining departures from normality for each group.   Questions:     does the assumption refer to the values of Y or the residuals of Y?  for a particular group, is it possible to have a strongly non-normal distribution of Y values (e.g., skewed) BUT an approximately (or at least more normal) distribution of residuals of Y?   Other sources describe that the assumption pertains to the residuals of the model (in cases where there are groups, e.g. t-tests / ANOVA), and we should be examining departures of normality of these residuals (i.e., only one Q-Q plot/test to run).  does normality of residuals for the model imply normality of residuals for the groups? In other words, should we just examine the model residuals (contrary to instructions in many texts)?  To put this in a context, consider this hypothetical example:   I want to compare tree height (Y) between two populations (X).   In one population the distribution of Y is strongly right-skewed (i.e., most trees short, very few tall), while the other is virtually normal  Height is higher overall in the normally distributed population (suggesting there may be a 'real' difference). Transformation of the data does not substantially improve the distribution of the first    population.  Firstly, is it valid to compare the groups given the radically different height distributions? How do I approach the "assumption of normality" here? Recall height in one population is not normally distributed. Do I examine residuals for both populations separately OR residuals for the model (t-test)?     Please refer to questions by number in replies, experience has shown me people get lost or sidetracked easily (especially me!). Keep in mind I am not a statistician; though I have a reasonably conceptual (i.e., not technical!) understanding of statistics.  P.S., I have searched the archives and read the following threads which have not cemented my understanding:


I would like to pass event types such as TNotifyEvent or TKeyPressEvent.  How do I declare method param to accept these types ?  procedure RegisterEventType(AEventType: ???)   so that these compile:  RegisterEventType(TNotifyEvent) RegisterEventType(TKeyPressEvent)   Point being that TKeyPressEvent and TNotifyEvent are obviously different:  TNotifyEvent = procedure(Sender: TObject) of object; TKeyPressEvent = procedure(Sender: TObject; var Key: Char) of object;   So it's not an instance of event that I want to pass, it's the type.  To give some context this is the implementation:  procedure RegisterEventType(AEventType: ???; AFactory: TRedirectFactory) var   vTypeInfo: PTypeInfo; begin   vTypeInfo := TypeInfo(AEventType);   Assert(vTypeInfo.Kind = tkMethod);   vTypeInfo.Name <------ contains string 'TNotifyEvent'    SetLength(fFactories, Length(fFactories)+1);   fFactories[High(fFactories)].EventType := vTypeInfo.Name;   fFactories[High(fFactories)].Factory := AFactory; end;   context: TRedirectFactory creates an instance of IEventRedirect which implements TNotifyEvent and is used for redirecting event handlers on forms. There is one implementation for every supported event type (TNotifyEvent, TKeyPressEvent...). This allows centralised logging and measuring of forms that have lots of code in event handlers.  So the intent is to not pass a string 'TNotifyEvent' but actual type TNotifyEvent.

I fear this is probably a bit of a dummy question, but it has me pretty stumped.  I'm looking for the simplest way possible to pass a method of an object into a procedure, so that the procedure can call the object's method (e.g. after a timeout, or maybe in a different thread).  So basically I want to:   Capture a reference to an object's method. Pass that reference to a procedure. Using that reference, call the object's method from the procedure.   I figure I could achieve the same effect using interfaces, but I thought there was another way, since this "procedure of object" type declaration exists.  The following doesn't work, but might it help explain where I'm confused...?  interface    TCallbackMethod = procedure of object;    TCallbackObject = class     procedure CallbackMethodImpl;     procedure SetupCallback;   end;  implementation  procedure CallbackTheCallback(const callbackMethod: TCallbackMethod); begin   callbackMethod(); end;  procedure TCallbackObject.CallbackMethodImpl; begin   // Do whatever. end;  procedure TCallbackObject.SetupCallback; begin   // following line doesn't compile - it fails with "E2036 Variable required"   CallbackTheCallback(@self.CallbackMethodImpl); end;   (Once the question is answered I'll remove the above code unless it aids the explanation somehow.)


I believe the person (idiot) who remodeled the home I recently purchased let the grout and other construction material he used to rehab the bathroom go down the drain.  I believe it has dried in the pipe and there is only a very small opening for water to drain through.  The house is a slab, so I can't get to the pipe under the tub.  Is there anything I can use to dissolve the grout so that the water will drain faster.  He obviously didn't know what he was doing as the tile is already bulging behind the faucet.

The contractor I hired to tile my basement bathroom dumped a bunch if grout sand down the drain. it is clogged solid now that the plumbers came back to do their water test.  we have been trying to get it out by chipping when it was soft yesterday and then dumped muriatic acid down and left it overnight. Nothing seems to have happened and I'm afraid we don't know how deep the clog goes.  The trap is completely inaccessible.  Please does anyone have any ideas?


On the post "" an edit was made to include the text  "..."  (unlike voting, which is only available for users with 15 reputation or more).  Which made me a bit confused, as I remembered the tooltip for voting when you don't have 15 reputation yet to say something along the lines of "the vote is recorded, but not displayed". Due to me remembering that I went into the MSO chatroom, asking if this edit could be deleted. Since to my knowledge this was inaccurate information. Some kind users in there pointed out that the information is in fact correct, and that the votes are in fact not used for anything besides site metrics, as explained in  . Not even when the user does reach the threshold. Now the exact message when a < 15 rep users tries to vote is: (emphasis mine)  Thanks for the feedback! Votes cast by those with less than 15 reputation are recorded, but do not change the publicly displayed post score.   to me this message (clearly) indicates that the vote is in fact cast (".. are recorded .."), but just not being displayed publicly. (".. do not change the publicly displayed ..") Now my questions is, is it just me, and am I reading the meaning behind it incorrectly (Not a native English speaker), or is the text actually a bit vague? Besides the 2 Meta questions linked earlier I was not able to find anything in the help pages/faq about what happens to a users vote that has < 15 reputation (like the vote also not being converted once the user reaches 15 rep), maybe a page containing this information could be added, and linked in the message? Alternatively, maybe change the text to be the same text someone gets when they are not logged in at all "You need 15 reputation to upvote posts.". As this seems to capture what's actually happening way better.   (In spirits of the , an attempt at haiku)  Edit I saw done Left in state of confusion To meta I turned

Currently, when a user with less than the required reputation needed to cast a vote on a post attempts to do so, they are shown this message:     Thanks for the feedback! Votes cast by users with less than [x] reputation are recorded, but do not change the publicly displayed score.   While it is technically correct in that their attempted vote is recorded as feedback, it's rather confusing. It implies that the vote is still recorded as...a vote, not as feedback. This can mislead users into thinking that  (also see its duplicates here as well as ), or that such "votes"  (i.e. still a normal vote with the sole exception that it doesn't change the score).  Can we please change this message so that it no longer implies that an actual vote is recorded?  Examples:     Thanks for the feedback! You need at least [x] reputation to [up/down]vote this post.   or:     Thanks for the feedback! You need at least [x] reputation to cast a vote, but your feedback has been recorded.   In my opinion, the "Thanks for the feedback!" text implies to me that the feedback has been submitted and recorded; there's no need to point that out explicitly.


I am a user on Stack Overflow, and I think every page that shows questions, display all tags and the questions. Are the tags saved in a tags table or are they included together with the questions table?

What tools and technologies are used to build the Stack Exchange Network?  See also:


I am participating in a conference in Spain, I have an invitation letter from the university. Is my visa application for tourism or for Business ?  I appreciate if you can provide me with more advises since it is my firs Schengen visa application.

I am planning to travel to Portugal to attend an academic conference and in that regard needed a short-stay Schengen visa. The visa application has a field "Purpose of Travel" with the following options:   - Business - Sports - Cultural - Other - Study - Visiting family or friends - Medical reasons - Official visit - Transit - Airport transit - Tourism   I am attending the conference to present the research I am conducting as a part of my PhD. So "Study" is the closest in my opinion. But I don't want the Embassy to misconstrue that it is for studying at a university in Portugal. In that case, would "Business" be the right option to choose?


Sharepoint sites doesn't open in Safari 8.0.2 . It asks authentication continous.  How can I solve this problem?   Someone adviced to me this :"Change your Form Based Authentication (FBA) to Claims authentication in SharePoint."  It is a complex process. When I do this, does be formed any problem in  exist users profile.  Is there any way for fix?

I upgrated my software and Safari 8.0 installed with the update. My sharepoint site can open in Safari 8.0. But I upgrated Safari 8.0 to Safari 8.0.2. But my sharepoint site can't open.  I searched this issue on the net. The problem stems from the windows authentication.   Should I need to make an amendment to the SharePoint side? Have you any information the issue?


Our TAP Air Portugal flight From San Francisco to Barcelona, scheduled for Apr 28, 2020, was canceled by the airline. We called TAP Air Portugal and asked for a full refund to our credit card, which was the original form of payment. The airline representative confirmed that a refund to a credit card would be issued. However, a few days later we received "TAP Vouchers" from the airline, which expire in March 2021, and which were not what we asked for. We called the airline again and asked for a refund to a credit card once more, but we got a reply "Vouchers are how we handle flight cancellations due to COVID-19 policy". Any attempts to get more information led to the same phrase repeated again. We filed a complaint on  but still didn't get any reply from the airline.  We believe we have a right to get a refund according to , Article 8, which is confirmed by .  Do you know what we can do next to get our money back to the credit card?

My international conference in Europe this May has been canceled due to the COVID-19. I have a ticket, purchased from TAP air Portugal, from Toronto, Canada to Lisbon. Because it is a non-refundable fare, they don't want to give a refund.  They won't allow me to reschedule later than May 31 of this year. This won't be useful for me.  What options do I have? I'd prefer to get a full refund.  (I am a US citizen if it matters)  Note: They offered to refund just the taxes, which is about 10% of the value. That's not horrible, but I'd rather have the whole thing returned.


@Override                 protected void onHandleIntent(Intent intent) {                     if (intent != null) {                         final String action = intent.getAction();                         if (ACTION_UPDATE_SERVER.equals(action)) {                             final Server server = (Server)intent.getSerializableExtra(SERVER);                             handleActionUpdateServer(server);         [...]     }     } }   server is a model class I made where I override toString().  In the line   final Server server = (Server)intent.getSerializableExtra(SERVER);   I get this error   [package].[app] Java.lang.NullPointerException exception: cannot evaluate server.toString()   it seems like it is unable to retrieve the serialized extra because of this error.  but if I remove my implementation of toString() then there's no error. Problem is I need to override toString for a listView to use when displaying objects of the server class in the list. (there's no problems with the toString() method when being run to populate the list.  my implementation of toString looks like this:   @Override         public String toString() {             StringBuilder strb = new StringBuilder(serverTitle);             strb.append(" | Monitored: ");             strb.append(isMonitored);             strb.append(" | Online: ");             strb.append(isOnline);             return strb.toString();         }   why is it unable to evaluate server.toString when I override it myself and why is it even trying to?  don't mark this as duplicate of nullPointerException questions as this doesn't help me at all. The app doesn't crash after this error, it keeps running and to me the error seems to have to do with my implementation of toString()

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


I have custom made files that were created by my app. I want to be able to double-click on these files and make them open through my app. How can I achieve this?!

I would like to associate the last installed version of my Mac OS X application with a certain type of file. A little experimentation shows that the info.plist file seems to be read and interpreted by the operating system when launching the application, not when dragging the application bundle to the disk.  does not say much on that topic.  Is there any way, using a simple .dmg image as installation medium, to make sure the system associates that particular file type with my newly installed app without having to launch it first?  I should clarify that I want this to be done automatically during the installation (I don't want my users to have to do it themselves).


I'm trying to do a number checker in imessage. We all know that there is no such api, so I'm trying to use the tools at hand. The main took with past issues on this site on this topic.  I made a loop that inserts a number into a string, and by the color of the number (blue - registered, red - missing), using the standard utility Digital Colors Meter determines the color of the number. Then, depending on the color, it either adds a variable with a number from the initial txt file to the new one, or starts the script from the beginning. At least it should be.  But something is going wrong in loop. It checks the color, inserts numbers, everything is fine, but apparently the wrong condition, apparently the wrong data types. It inserts different numbers into the scatter. Some will insert, some will not, regardless of the initial condition. What could be the reason? Where is the error?      tell application "Digital Color Meter" to activate     tell application "System Events"         tell process "Digital Color Meter"             click menu item 1 of menu 1 of menu bar item 4 of menu bar 1         end tell         do shell script "/usr/bin/python -c \"import objc;bndl = objc.loadBundle('CoreGraphics', globals(), '/System/Library/Frameworks/ApplicationServices.framework');objc.loadBundleFunctions(bndl, globals(), [('CGWarpMouseCursorPosition', 'v{CGPoint=dd}')]);CGWarpMouseCursorPosition((" & 1002 & "," & 222 & "));\""         set rgbColors to words of (the clipboard)     end tell     if rgbColors is equal to {"77", "39", "38"} then         exit repeat     else         do shell script "echo " & quoted form of n & " >> /Users/oneone/Desktop/base2.txt"     end if   Only the color check condition for Digital Color Meter is presented here.  Through the do shell, the color is read at the mouse position and the variable is added to the new file.

I'm trying to do a number checker in imessage.  We all know that there is no such api, so I'm trying to use the tools at hand. The main took with past issues on this site on this topic.   I made a loop that inserts a number into a string, and by the color of the number (blue - registered, red - missing), using the standard utility Digital Colors Meter determines the color of the number. Then, depending on the color, it either adds a variable with a number from the initial txt file to the new one, or starts the script from the beginning.  At least it should be.   But something is going wrong. It checks the color, inserts numbers, everything is fine, but apparently the wrong condition, apparently the wrong data types. It inserts different numbers into the scatter. Some will insert, some will not, regardless of the initial condition.  What could be the reason? Where is the error?  And is it possible to make it so that after a certain number of verified numbers, he himself deleted open dialogs with these numbers?  repeat with n in client     activate application "Messages"     repeat         tell application "System Events" to tell process "Messages"             key code 45 using command down             keystroke n             delay 1             key code 36             tell application "Digital Color Meter" to activate             tell application "System Events"                 tell process "Digital Color Meter"                     click menu item 1 of menu 1 of menu bar item 4 of menu bar 1                 end tell                 do shell script "/usr/bin/python -c \"import objc;bndl = objc.loadBundle('CoreGraphics', globals(), '/System/Library/Frameworks/ApplicationServices.framework');objc.loadBundleFunctions(bndl, globals(), [('CGWarpMouseCursorPosition', 'v{CGPoint=dd}')]);CGWarpMouseCursorPosition((" & 1002 & "," & 222 & "));\""                 set rgbColors to words of (the clipboard)             end tell             if rgbColors is equal to {"77", "39", "38"} then                 exit repeat             else                 do shell script "echo " & quoted form of n & " >> /Users/oneone/Desktop/base2.txt"             end if         end tell     end repeat end repeat


I am using Lyx and need to modify my document's preamble. Where should I add   \documentclass[openany]{scrbook} \usepackage{classicthesis}  \begin{document}  \chapter{A}   in order to remove blank pages from the document?  I would like to know the file name and the specific place in the file.

I'm using LyX and a custom class from  which is based on the  class.  I'm at another school and my advisor wants me to include titles of the readers on the signature page as well as a date line for each signator.  I've looked through some documentation on the thesis class and poked around in the .cls file in use but didn't come across anything obvious to change.  Perhaps this section would help though?  \newcommand*{\th@degreeyear}{\number\the\year} \newcommand*{\th@signature}[1]{ \begin{center}     \normalsize     \vspace*{16mm}  % works well?     \vrule width 80mm height 0.2mm\\     #1 \end{center} } \newcommand*{\th@dateline}{ \vspace*{9mm} \begin{flushright}     Date~{\vrule width 35mm height 0.2mm} \end{flushright}   How do I include this?


I have a blank map, I've set the data frame to the same projected coordinate system as the data I'm going to add. I have added one shapefile and it looks good. When I wave the cursor over the map the decimal degrees displayed in the lower right corner of the data frame are correct.    I then attempted to add a Excel table that has lots of points with the decimal degrees for each point. I added the table, and used the Display XY Data option to display the points. The resulting points do not overlap the first shapefile, even though the two are actually just about identical. I've checked the projected and geographic coordinate systems and they're the same.   When I zoom in on the layer with the points I find that in the lower right hand corner of the data frame it registers everything as being at -85.489, 0 decimal degrees, which is clearly wrong. The measure tool shows that the points are mere millimeters apart, which they're not.  Based on similar question on this site I tried using the project tool on my points and projecting it into the format it already was in (i.e. the same projected and geographic systems as the shapefile) that didn't work, it just wound up warped.  What has gone wrong with displaying my data?

I put 4 different layers into my ArcMap document, but only one of them will show up on the map! I should be seeing the other 3 layers as well. When I do a Zoom to layer, I can see one layer, but I cannot figure out how to make the other 3 show up at once on top of each other.  Before I opened ArcMap, I used ArcCatalog where I right-clicked 3/4 of the shapefiles and  clicked Properties → Coordinate system → Import and then clicked on my Trees layer, which has the coordinate system I want the other 3 to have. But when I opened ArcMap the 4 layers did not overlap, nor could I move them above or below each other.


/^([A-Za-z0-9]){1,8}$/    This is a normal way to write a regex in JavaScript but I want to construct the regex dynamically with a variable in between ().   Variable = [A-Za-z0-9]

I would like to create a String.replaceAll() method in JavaScript and I'm thinking that using a regex would be most terse way to do it.  However, I can't figure out how to pass a variable in to a regex.  I can do this already which will replace all the instances of "B" with "A".  "ABABAB".replace(/B/g, "A");   But I want to do something like this:  String.prototype.replaceAll = function(replaceThis, withThis) {     this.replace(/replaceThis/g, withThis); };   But obviously this will only replace the text "replaceThis"...so how do I pass this variable in to my regex string?


I have an Ubuntu 17.04 instance that randomly locks up. Nothing responds so I have to turn off the PC using the power button.   I've realised that the issue starts when I try to reboot my computer... Sometimes the wifi stops working for like 15 seconds and then asks me for the wifi password.

All operating systems freeze sometimes, and Ubuntu is no exception. What should I do to regain control when...   just one program stops responding? nothing at all responds to mouse clicks or key presses? the mouse stops moving entirely? I have an    In what order should I try various solutions before deciding to pull the power plug?  What should I do when starting up Ubuntu fails?  Is there a diagnostic procedure I can follow?


I have this charger:  It supports QC3.0 and has: Output USB-A DC 3.6-6.5V/9V/12V/14.5V/16V3A/19V/20V3.5A QC3.0 USB-C DC 5V/9V/12V/15V/18V/20V3A  i connected a 2pin 12v computer fan to one of its USB-A port and the multi-meter suggested that the charger is outputting 30v obviously, a 2 pin fan does not support any kind of charging protocol, why did it still getting a > 5v voltage? How does the charger decide its output voltage for old device like old iphones(5V 1A), or when D+/D- pins are not connected(like my fan)? I plan to drive a WS2812B RGB LEDs Strip (60 leds, DC 5V, 18W) with the charger, how can i control its output voltage? Update: i think its defaulting at 20V output on USB-A, while everyone is suggesting that the default output should 5V when there is not any negotiation not connected to any device  connected to a fan  connected to arduino

I've heard about laptops such as the new Chromebooks that are charged via a wall charger that connects to a USB-C port. I'm quite happy that this will supposedly standardize laptop chargers but I'm a little unclear about how this works.   Existing USB ports provide a 5 volt source, but the laptop chargers provide up to 20 volts. is there some kind of higher voltage line or are the USB-C powered laptops running on a lower voltage?  All this information I've seen gives a fairly vague idea of providing more power, providing up to 100 watts rather than 10 watts. Even so, my laptop is not the most powerful machine and the charger still outputs fairly near 100 watts, I can imagine more chargers for power laptops providing much more than 100 watts. Could a general purpose USB-C charger really power all these machines?


Is it considered embarassing if adding a dedication to the family on the second page and giving credit in the acknowledgement section in the end for the support during hardships in an undergraduate thesis? What's too much and of disadvantage? Or is an undergraduate thesis quite forgiving and the question of 'too much' isn't an issue here?

I am compiling my thesis, and have noticed that the LaTeX template that I am using provides space for a dedication.  Whilst I do have an individual whom I want to credit with being a source of inspiration for my research and career motivation, I'm curious as to if honours theses normally include a dedication, and if I would be better to wait until I write my doctorate.


Is it frowned upon to add slight humor and sarcasm to academic presentations? For example, I flip to a background slide and say "This is a typical slide used by researchers in (field) just to show off how difficult their work is." before going through the content of the slide. Is there a difference in doing that in different settings, like a department seminar vs an international conference?

I am preparing slides for a short (10min) talk at the group meeting. The talk is about a fairly serious piece of (pure) mathematics, and it so happens that there is a very relevant one-panel webcomic. A thought appeared to me, and got some support from my fellow PhD students, that it would be cool to include this comic, perhaps at the final thank-you-for-your-attention slide.  I am probably not going to do it, so I'm asking mostly out of curiousity: Would this be a bad idea to go ahead and include a comic on the final slide?   Note: The comic is genuinely funny (based on a sample of 6 non-randomly selected students). It is not - as far as I can tell - offensive in any way. It could come across as somewhat silly.


from time to time recently I notice the cmd window opening and then immediately closing. I need to find out what is using it.  windows 7. updated.

I'm wondering if there's any log which stores information about a particular program such as when the program has started and closed manually on Windows such as MS Word, or Chrome. Any ideas?


I haven't played minecraft in a couple months, a couple days ago my friends wanted to play so I joined their private server and I've been having this problem.  Its not just on their server, it does the same thing on all servers. I will be playing with normal frame rates and good game play until everything goes unresponsive, mobs stop moving, blocks don't drop when they break. And then I lag out of the server.  I have tried with and without Optifine, and with different resource packs. I'm playing on version 1.8.3 but it still does it in others. The error I get when I lag out is:  Internal Exception: java.io.IOException: An existing connection was forcibly closed by the remote host.

Upon entering any given minecraft server, after a minute or two I am forced out of the server, and I'm given the following error:  java.io.IOException: An existing connection was forcibly closed by the remote host.  What does this mean, and how can I prevent it from happening again?


I'm relatively new to Java and I am trying to make a login page for my desktop application. I have a thread called "listen" that should be called when the application first opens, its job is to check weather the username and password fields are not blank.   public class Login extends JFrame implements Runnable {     private JPanel contentPane;     private JTextField txtUsername;     private JPasswordField pwdPassword;     private JLabel lblUsername;     private JButton btnLogin;     private JLabel lblPassword;     private JCheckBox cboxRemember;     private Thread run, listen;     private boolean running = true;  public Login() {     createWindow();     run = new Thread(this, "Running");     running = true;     run.start();     }  private void createWindow() {      //application layout and actionListener for login button }  public void run() {     listen();  }  public void listen() {     listen = new Thread("Listen") {         public void run() {             while (running) {                 if (txtUsername.getText().equals("") || pwdPassword.getText().equals("")) btnLogin.setEnabled(false);                 else btnLogin.setEnabled(true);             }         }     };     listen.start(); }  public static void main(String[] args) {     EventQueue.invokeLater(new Runnable() {         public void run() {             try {                 Login frame = new Login();                 frame.setVisible(true);             } catch (Exception e) {                 e.printStackTrace();             }         }     });   } }   Whenever i try to execute my code the 'listen' thread throws a NullPointerException on this line if (txtUsername.getText().equals("") || pwdPassword.getText().equals("")) btnLogin.setEnabled(false); I'm not sure what am I doing wrong, any help will be appreciated, thanks.

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


I am very new to Python.Is there any method through which i can find out which type of value is stored in a particular variable?  In below code how to find out type of stored value in a variable?  counter = 100           miles   = 1000.0        name    = "John"      name    =10   print counter print miles print name

How do I see the type of a variable whether it is unsigned 32 bit, signed 16 bit, etc.?  How do I view it?


I'm sorry if this is a general question but what block of code should I use to make javascript or html respond to a key press or key event? Any way to do it is ok but I just want to make my website more interactive. Thank You!  And don't go around saying that this is a copy of some other question. It is not. I don't know why anyone would think that, too because the "original" question is asking "how do I know if a key is pressed". I am asking how do I make my website respond to a key press. And to the comment below, I have been searching this stuff up but isn't that what this website is for? I don't have a P.H.D in computer science and I'm just asking questions so I can understand these computer languages a little better but every time I ask a question everyone gets really mad at me because somehow a question about javascript is a lot like a fancy jquery command. But back on topic I am just looking for ways that my website can react to a key press. Once again, Thank You!

With jQuery, how do I find out which key was pressed when I bind to the keypress event?  $('#searchbox input').bind('keypress', function(e) {});   I want to trigger a submit when ENTER is pressed.  [Update]  Even though I found the (or better: one) answer myself, there seems to be some room for variation ;)  Is there a difference between keyCode and which - especially if I'm just looking for ENTER, which will never be a unicode key?  Do some browsers provide one property and others provide the other one?


I read in one website that the former is a short version of the later, but I found no other source saying so. Also, I know the meaning of the former, but I’m not sure what “from your lips” mean. Is it really just a shorter version? If not, then what does it mean?

I used this phrase in a conversation with my wife yesterday and was surprised to learn that she had never heard of it.  This led me to wonder where it came from.


How can I prove the following.  Suppose that A is  a square matrix and suppose that there is another matrix B such that $A=B^TB$.    a)Show that A is positive semi definite    b)Show that if B has full column rank then A is positive definite.

$A$ and $B$ are $n\times n$ matrices, A = $B^{T}B$. Prove that if $\operatorname{rank}(B)=n$, then  $A$ is positive definite, and if $\operatorname{rank}(B)<n$, $A$ is positive semi-definite.    My current understanding is that if $\operatorname{rank}(B)=n$, then $\operatorname{rank}(B^{T}B)=n$ then $\operatorname{rank}(A)=n$, making $A$ positive definite.   Similarly, if $\operatorname{rank}(B)\le n$, then $\operatorname{rank}(B^{T}B)\le n$ then $\operatorname{rank}(A)\le n$, making $A$ positive semi-definite.  This doesn't feel like a complete proof. Is there anything I am missing?


Periodically, Ubuntu prompts me to download the latest version of Firefox.  But some programs, like Python, are never upgraded unless you update Ubuntu itself.  For instance, Ubuntu 14.04 uses Python 2.7.6, despite the fact that 2.7.7 came out years ago.  Is there any particular logic as to which things get constantly updated versus which get frozen?

Why are packages in the official Ubuntu repositories older than the latest (upstream) versions from Debian Sid, PPAs, the authors, etc.?


My old laptop died because of battery issues earlier in the year, and I've managed to get the HDD out before trashing it.  I've bought a new laptop and a USB/SATA plug, and I can access and see the old file tree of my old C: drive (now H:)  I'm trying to recover my personal files from C:\Users\$Username. Unfortunately, I do not have the autorisations, and if I remember my old password I can't remember the name of the laptop (domain controller).  Do you have any way/program which can gain me access rights ?  Thanks you in advance.

I have a hard drive which I need to recover specific files from but all the folders in the K:\ drive are denying me access even though I took owner ship of the full drive I.E      C:\Windows\System32>takeown /F K:\   This granted me access to the drive and see the folders but I can not access any of the folders after that.   Is there a way in which I can use Takeown to apply ownership to every directory on the drive>


First of all, let's get one thing straight, while im sure it's not the ONLY solution to sql injections, PREPARED STATEMENTS ARE BETTER and MORE SECURE... that's granted.   So let's not debate it anymore, as I just needed to explore the escaping options and target the user inputs rather than the statement..   (a bit of back story)  I have a huge application w/ lots of basic SQL statements which i need to make "safer" in a short period of time. Converting all statements to PDO is a monster of a task which requires resources not available to this situation.   But good thing is that there's a hook in the application where ALL incoming $_GET/$_POST passes through a function before making available as plain variable in the scripts... ( eg.globalize($_POST) )  So i'm looking to target that function instead and focus on "cleaning" user input ...   I pretty much got a good grasp of SQL injection techniques, and basically much of its concept, such as: 1) Whenever there is user input involved in a statement, that's when the attacker has an opportunity 2) The main mission is to break your statement's quoting by simple single or double quotes as string, or character codes, in the attacker's input..  3) Escaping is good at preventing SQL injections except for that situation when the DATABASE character encoding is able to ready multibyte representations of those nasty illegal strings and the script based escaping misses it.  Based on the above premise, what if:  1) All my SQL Statements follow a standard where user input is quoted using single quotes ALWAYS, therefore there is no guess work for me anymore on what type of quote i need to escape (single quotes)  2) all user inputs (POST / GET) go through a function (eg. globalize() ) that basically addslashes() and globalizes each variable   3) This is an intranet application and the scripts can be made aware of the database encoding support.  QUESTION: What are the threats currently available in the above situation and how can we handle them?  ...i personally was looking into simply adding routines to the globalize() function similar to mysql_real_escape_string()  .. or go as far as "tweaking" the SQL statements to use mysql_real_escape_string() as that is a lot easier/faster to do than programming statements on each sql query..   PS Of course this script may never be as secure as prepared statements, but i just need to make it hard enough for most attackers (not looking to 100% bullet proof it as it is not that worth it)

If user input is inserted without modification into an SQL query, then the application becomes vulnerable to , like in the following example:  $unsafe_variable = $_POST['user_input'];   mysql_query("INSERT INTO `table` (`column`) VALUES ('$unsafe_variable')");   That's because the user can input something like value'); DROP TABLE table;--, and the query becomes:  INSERT INTO `table` (`column`) VALUES('value'); DROP TABLE table;--')   What can be done to prevent this from happening?


I need to replace a string in a file A, with empty string. And I need to do it using Batch script.   Input: A.txt A.txt contains "xyz", which I need to replace with empty string in same file A.txt.  I need to replace only "xyz" from the file A.txt, not the entire file. The file A.txt contains contains several other strings.  Please let me know if possible.

I am writing a batch file script using Windows command-line environment and want to change each occurrence of some text in a file (ex. "FOO") with another (ex. "BAR"). What is the simplest way to do that? Any built in functions?


I know this has been asked several times and I promise I have read over 100 articles before resorting to posting. Here is my issue:   I have created my own object (WorkoutData). It is made up of several string variables, and integer and a linked list of strings:  public class WorkoutData implements Serializable {     private static final long serialVersionUID = 878893767880469289L;     String workoutLocation;     String bodyPart;     String exercise;     int numOfSets;     LinkedList<LinkedList<String>> datesSetsAndReps; }  In case any duplicates ever get into my datafile I am reading the objects into a LinkedHashSet. My thinking is that this will automatically eliminate any duplicates.   Of course this isn't working, because each object has its own ID and therefore will not be "equal" to another object. To try to get around this I have overridden the equals and hashCode inside my WorkoutData class.  For some reason it is still not working. Here is how I am loading my linkedHashSet:  for (int iterator = 0; iterator < numberOfWorkouts; iterator++)     tempWorkoutDataSet.add((WorkoutData) in.readObject());   Here are my overridden methods in the WorkoutData class:  @Override public boolean equals(Object other) {     if (other == null)     {         return false;     }      if (this.getClass() != other.getClass())     {         return false;     }      if (!this.workoutLocation.equals(((WorkoutData)other).workoutLocation))     {         return false;     }      if (!this.bodyPart.equals(((WorkoutData)other).bodyPart))     {         return false;     }      if (!this.exercise.equals(((WorkoutData)other).exercise))     {         return false;     }      return true; }  public int hashCode() {     return this.workoutLocation.length(); }   The hashset contains duplicates no matter what I try. I think the equals method is correct, but I freely admit I have no idea what the hashCode method is meant to accomplish.    This question is NOT a duplicate of "How do I compare strings in Java?". That question only talks about the == vs .equals issue. My issue has more to do with overriding hashCode.  I think that is where my problem lies. Couple that with the fact that I am still unclear exactly what the hashCode override is meant to accomplish.

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


I am confused regarding the derivation of  the fact that, $${n \choose k} =\frac{n!}{k!(n-k)!}$$  I understand that the number of sequences of $n$ objects arranged $k$ ways is   $$\frac{n!}{(n-k)!}$$  and I also understand why there could be $n!$ different permutations of the same $n$ letters, but my question is:   In the formula, why does one divide by $k$! to get rid of such combinations? How does that remove them?

Regarding the formula for binomial coefficients:  $$\binom{n}{k}=\frac{n(n-1)(n-2)\cdots(n-k+1)}{k!}$$  the professor described the formula as first choosing the $k$ objects from a group of $n$, where order matters, and then dividing by $k!$ to adjust for overcounting.  I understand the reasoning behind the numerator but don't understand why dividing by $k!$ is what's needed to adjust for overcounting. Can someone please help me understand how one arrives at $k!$? Thanks.


I have been recently going through the hyper threading technology of Pentium 4. The number of pipeline stages is high in P4 and is said that it will increase the speed of clock rate. How is that possible?

The Megahertz Myth became a promotional tactic due to differences between the PC's INTEL 8086 processor and Apple's Rockwell 6502 processor.  The 8086 ran at 4.77MHz while the 6502 ran at 1MHz.  However, instructions on the 6502 needed fewer cycles; so many fewer, in fact, that it ran faster than the 8086.  Why do some instructions need fewer cycles?  And why can't the instructions of the 6502, needing fewer cycles, be combined with a fast cycling processor of the 8086?  Wikipedia's article for instructions per cycle (IPC) says     Factors governing IPC   A given level of instructions per second can be achieved with a high IPC and a low clock speed...or from a low IPC and high clock speed.   Why can't you have both high instructions per cycle and high clock speed?  Maybe this has to do with what a clock cycle is?  Wikipedia mentions synchronization of circuits?  Not sure what that means.  Or maybe this has to do with how a pipeline works?  I'm not sure why instructions in a short pipeline are different from instructions in a long pipeline.  Any insight would be great!  Just trying to understand the architecture behind the myth.  Thanks!  References: