How can I correctly align page numbers > 100 in the table of content? I use the cleanthesis template.   \documentclass[draft=on]{scrbook} \usepackage{blindtext} \usepackage[ngerman]{babel} \usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} \usepackage[svgnames]{xcolor} \usepackage{cleanthesis}   \begin{document} \tableofcontents  \section{Section 1} \blindtext[100] \section{Section 2} \blindtext[500] \section{Section 3} \end{document}

This is a follow up question of .  The formatting problem has nothing to do with cleanthesis.sty.  The problem is that if I use the charter font, page numbers greater than 99 are not formatted correctly in the table of content.  \documentclass[draft=on]{scrbook} \usepackage{blindtext} \usepackage{charter}  \listfiles  \begin{document} \tableofcontents \section{Section 1} \blindtext[100] \section{Section 2} \blindtext[500] \section{Section 3} \end{document}


public enum CardinalDirection {     NORTH (90),     EAST (0),     SOUTH (270),     WEST (180);      private float angle;      CardinalDirection(float angle) {         this.angle = angle;     }      public float angle() {         return angle;     }      public CardinalDirection opposite() {         switch (this) {         case EAST: return WEST;         case NORTH: return SOUTH;         case SOUTH: return NORTH;         case WEST: return EAST;         default: return null;         }     } }   Hello, I've created this enum quite a while ago. The enum is being used within forked code, meaning, another project has this exact code in it every time when exported.  However recently, after exporting the entire project, the method "angle()" is throwing a NoSuchMethodError: ...angle()F  First of all, what does the F at the end of the method mean? Second of all, how is it possible that code which is 100% up to date with certainty throws this error?  Caused by: java.lang.NoSuchMethodError: org.thearaxgroup.surf.enums.CardinalDirection.angle()F         at org.thearaxgroup.act.object.ActionBoxDisplayManager.newArmorStand(ActionBoxDisplayManager.java:65) ~[?:?]         at org.thearaxgroup.act.object.ActionBoxDisplayManager.getArmorStand(ActionBoxDisplayManager.java:80) ~[?:?]         at org.thearaxgroup.act.object.ActionBoxDisplayManager.reloadArmorStand(ActionBoxDisplayManager.java:30) ~[?:?]         at org.thearaxgroup.act.command.CommandActBox.onCommand(CommandActBox.java:171) ~[?:?]         at org.bukkit.command.PluginCommand.execute(PluginCommand.java:44) ~[spigot-1.9.jar:git-Spigot-bc01c3a-55b0def]         ... 15 more   EDIT: I did find out what caused the issue ... more or less. Another .jar (plugin) also uses the code in the affected project. However, it only depends on it, it doesn't redefine it in any way. I checked for a lot of possible causes and I can't find any reason.  It seems like the jar's sole existence is causing the error.

I'm getting a NoSuchMethodError error when running my Java program.  What's wrong and how do I fix it?


I have a text file with a lot of blank lines that I want to remove like:  aaa  bbb   ccc   I would like to get:  aaa bbb ccc   At the moment I am trying:  LANG=C sed -E '/^\n|^\r|^\r\n|^\n\r/d' file   I should say I am using OSX. I have tried quite a few things and can't figure out what I'm doing wrong.  I have already tried searching for \r character

I have a .csv file (on a mac) that has a bunch of empty lines, e.g.:  "1", "2", "lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum   lorem ipsum ","2","3","4" "1", "2", "lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum   lorem ipsum ","2","3","4"   Which I want to convert to:  "1", "2", "lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum ","2","3","4" "1", "2", "lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum lorem ipsum  lorem ipsum ","2","3","4"   I know there must be a one liner but I don't know awk or sed. Any tips greatly appreciated!


I have GDBs in folders in a certain location in a shared dropbox. When I move the folders to another location, some of the feature classes have been converted to GDB tables.   I have never seen this before, and now all of a sudden it is happening to me all the time.   Has anyone else seen this and know what is causing it?

I've been able to accumulate a large free dropbox account and use it to Sync my GIS databases across several different PC's. I've just started doing this and havent had any problems thus far. But I am getting some red flags of warning that are scaring me.  There seems to be several duplicate files in the GeoDatabases. Usually something like:   a00000017.gdbtable (GIS-HP duplicate Copy)  I can manually delete these files with no problem, but I have no idea why they are popping up.  Also, instead of removing file locks, Dropbox keeps saying it is renaming them. So when I release one lock and gain another, it renames the file instead of deleting it and creating a new one. Although it still does delete the lock file when I have fully disconnected from the GeoDatabase.  Like I said, I haven't had any issues so far, but I am worried about long term data corruption while using Dropbox.   Has anyone used Dropbox and found problems using it to sync GIS data?


How do I subtract dates in JavaScript? I have a string of a date and i would like to subtract from it another date. I would like to do that in a function:  function substractDate(date1, date2){ }   How can i that in proper JavaScript?

I'm creating an application which lets you define events with a time frame.  I want to automatically fill in the end date when the user selects or changes the start date.  I can't quite figure out, however, how to get the difference between the two times, and then how to create a new end Date using that difference.


I am from Nigeria. I got my UK tourist visa in February, but am unable to travel yet due to restrictions from Nigeria to UK. My visa will expire in August.  What will happen if the restriction is still in place and my visa expires before I can use it?

In the beginning of 2020, I applied for and was granted a UK visitor visa for 6 months. Its starting date was April 1st and it will expire in September. Theoretically, I will be able to enter as I am a resident of the EU (not a citizen), but it is unlikely I will travel this summer.  Do you know if it is possible to cancel visa due to COVID-19 and get a refund (at least partial) for the fees I paid?


If black holes can swallow any object, and can radiate energy, then how could black holes join each other and can form bigger black holes?

If time stops at the event horizon, can we ever detect two black holes merging? In other words, if you are a short distance away, would you encounter a spherically symmetric gravitational field, or a dipole field?


How would I attempt to brute force a RSA encrypted message with a 64bit computer if it the memory can't put up with calculations bigger than 64bit? Without going that far to attempting to crack it, how does my computer encrypt a message with a public key that's bigger than 64bit (e.g 2048)?

Whilst I understand how the RSA algorithm works, I don't understand how the CPU operates when it needs to use the mod function with a huge number $n$, for example.  $n = 8192$ bits; $c = m^e \mod n$;  In essence my question is how does the CPU deal with this huge modulus?


I'm trying to build a maven project in Azure DevOps used the VS2017 windows hosted agent but it fails cause it could find the selenium webdriver  here's my code when I run it on local   System.setProperty("webdrive.firefox.drive", "C:\\Users\\hkefi-ext\\Desktop\\Webdriver\\Chrome\\geckodriver.exe");  WebDriver driver = new FirefoxDriver();  driver.get("Website URL");   I tried to upload the exe in the Project repo in azure and call it but it fails  I found this "The paths to the folders containing these drivers can be obtained from the environment variables named IEWebDriver (Internet Explorer), ChromeWebDriver (Google Chrome), and GeckoWebDriver (Firefox)." in microsoft document but I couldn't find a way to the path of these webdrivers

How can I get the System Variable value which is present in   MyComputer -> Properties -> Advanced -> Environment Variables -> System Variables   in Java?  Edit  I have used System.getenv() method.  It is printing value if I give   System.out.println(System.getenv("JAVA_HOME"));   and it is showing null value if I try the same for system variable created by me   System.out.println(System.getenv("DBE"));


Let $(V, \mathbb{C})$ be a complex - valued vector space. Let $A$ be any linear operator acting on this vector space. Suppose that $B = \{|v\rangle_{k}\}_{k=1}^{n}$ is a basis set for $(V, \mathbb{C})$. Then, the linear operator $A$ may be written as $A = \sum_{k=1}^{n}A_{kj}|v_{k}\rangle \langle v_{j}|$ - in terms of it's outer product.  I would appreciate hints in the direction of assisting me in writing $A = B + iC$ where $B,C$ are Hermitian and $i$ is an imaginary number.

How can we prove that any complex matrix can be expressed in term of hermitian and anti-hermitian matrices of the following form $A = H_1 + iH_2$ Where, $H_1$ is hermitian and $H_2$ is an anti-hermitian matrix


I have a user on my system who appears to be sending large quantities of mail and I'm having difficulty identifying who he is. I don't know his IP address or username by which he authenticated.  One such entry from the syslog is:  root@s2:~# zgrep '2EA87A0CDF' /var/log/syslog.2.gz | more   Jul 28 21:04:32 s2 postfix/pickup[10654]: 2EA87A0CDF: uid=33 from=<callcenter@bdo.com>   Jul 28 21:04:32 s2 postfix/cleanup[11263]: 2EA87A0CDF: message-id=<56a1b0b372c938dfc989c5630be75ac1@www.ourCustomersDomain.com>   Jul 28 21:04:32 s2 postfix/qmgr[2545]: 2EA87A0CDF: from=<callcenter@bdo.com>, size=4808, nrcpt=1 (queue active)   Jul 28 21:04:36 s2 postfix/smtp[11361]: 2EA87A0CDF: to=<mangmkkepweng@yahoo.com>, relay=mta5.am0.yahoodns.net[98.137.159.27]:25, delay=4.4, delays=0.01/0.01/1.2/3.2, dsn=2.0.0, status=sent (250 ok dirdel)   Jul 28 21:04:36 s2 postfix/qmgr[2545]: 2EA87A0CDF: removed   Please note the following:   I've replaced our customer's domain name with ourCustomersDomain.com. bdo.com domain is an external domain not handled by us and appears to be being used as the from address given by our user. Because I know the customer's domain what I'm looking for is the actual username being used to gain access.   I can see the UID, which is '33' but it doesn't mean anything to me. How can a match this to the username used?

I was checking my munin tables and saw a huge list of deferred mails in postfix and looking into /var/log/mail.log gave me an idea: I am sending mails to unknown mail addresses:  Dec 23 08:21:32 h2065299 postfix/pickup[10816]: 63F5811A0384: uid=33 from=<www-data> Dec 23 08:21:32 h2065299 postfix/cleanup[20915]: 63F5811A0384: message-id=<301b8e057416d03df3ac7c11f1aa5bda@www.my-server.com> Dec 23 08:21:32 h2065299 postfix/qmgr[7878]: 63F5811A0384: from=<www-data@my-server.com>, size=2254, nrcpt=1 (queue active) Dec 23 08:21:32 h2065299 postfix/smtp[20917]: 63F5811A0384: to=<underlyingbzvn+zprtra@gmail.com>, relay=gmail-smtp-in.l.google.com[173.194.69.26]:25, $ Dec 23 08:21:32 h2065299 postfix/qmgr[7878]: 63F5811A0384: removed   this is not really different to a forced "good" email   Dec 23 09:41:51 h2065299 postfix/pickup[28905]: EE51611A0393: uid=33 from=<www-data> Dec 23 09:41:51 h2065299 postfix/cleanup[30516]: EE51611A0393: message-id=<2736115f98e8293f5e8b657b22e66b4d@www.my-server.com> Dec 23 09:41:52 h2065299 postfix/qmgr[28906]: EE51611A0393: from=<www-data@my-server.com>, size=977, nrcpt=1 (queue active) Dec 23 09:42:22 h2065299 postfix/smtp[30518]: connect to gmail-smtp-in.l.google.com[2a00:1450:4008:c01::1b]:25: Connection timed out Dec 23 09:42:22 h2065299 postfix/smtp[30518]: EE51611A0393: to=<my-name@gmail.com>, relay=gmail-smtp-in.l.google.com[173.194.69.27]:25, delay=$ Dec 23 09:42:22 h2065299 postfix/qmgr[28906]: EE51611A0393: removed   We are running three wordpresses and some scipt folder on the server. The WPs are up-to-data and I think we have correct file permissions on them.  What can cause www-data to send mails to unknown users?!


Google is no longer supporting 32 bit version of Chrome browser, at least that's what the message i get every time i open the browser is saying. I need to use chrome, and i need to get latest upgrades too. So, i guess i need to install 64 bit Ubuntu but i am not sure if it will work on my Laptop. This is the specification, can someone tell me if 64 bit run smoothly on my Laptop:  Ram - 2gb Processor - Intel® Pentium(R) CPU B950 @ 2.10GHz × 2  Graphics - ntel® Sandybridge Mobile x86/MMX/SSE2

I'm downloading both versions of Ubuntu 12.04 at this moment. I'd like to install AMD64 on my portable, even though it's an Intel machine. Is there a website (or another way) where I can check compatibility?  Acer Aspire 5745G-724G50Mnks, Intel i7 with 4Gb RAM


I want the following piece of code to replace few strings in a file and save the changes. It is doing the right job but just adding the changed lines to the previous file without replacing it. I just want the file to be overwritten. What's wrong in my code?  import os import sys  fileToSearch  = 'sample.csv'  replace_values = {     'text1'     :   'text1_new',     'text2'     :   'text2_new',     'text3'     :   'text3_new' } with open(fileToSearch, 'r+') as tempFile:     for line in tempFile:         for key, val  in replace_values.items():             if key in line:                  tempFile.write(line.replace(key, key.replace(key, val)))

I want to loop over the contents of a text file and do a search and replace on some lines and write the result back to the file. I could first load the whole file in memory and then write it back, but that probably is not the best way to do it.  What is the best way to do this, within the following code?  f = open(file) for line in f:     if line.contains('foo'):         newline = line.replace('foo', 'bar')         # how to write this newline back to the file


when light beam is incidented at some angle on the surface of a medium some part of the light is reflected and some refracted. I want to know about refraction. As the photons interact with the atom and get reemitted in all the directions, how the photons know to a particular angle they should refract?

is the bending of a wave when it enters a medium where its speed is different. The refraction of light when it passes from a fast medium to a slow medium bends the light ray toward the normal to the boundary between the two media. My question is what is the fundamental reason for this refraction?is it something related to the atomic force?


Is there something like a "standard dress code" for a Ph.D thesis discussion? And, if there is - how important is it? Obviously, one should not (I think) dress too casually, but I do not know what is deemed appropriate.  I don't know how much this varies around the world; if it helps, I am from Europe.

Is it better to wear formal clothes for a PhD or MSc thesis defense or can we wear something as simple as a T-shirt?


I asked  whether UK citizen can enter after 15-day stopover in Bermuda and the answer seemed to be "yes." I have some critical new information that I believe justified a follow-up question. I just spoke with the US government (US Citizens Crisis Assistance from travel.state.gov) and someone there told me this is not possible, that only US citizens and lawful permanent residents are allowed to enter the US, even after having been out for 14 days. But  seems pretty clear:  foreign nationals who have been in any of the following countries during the past 14 days may not enter the United States  It does not say anything about foreign nationals who have not been in those countries during the past 14 days. Surely it would be easier for them to just say "no foreign nationals, at all"? Why enumerate the 14 day rule if the reality is different? I have received contradictory information and was wondering if anyone here could help clear it up. Maybe there is confusion on their end between the "no new visas" and the "no foreigners who've been in Europe/China/Iran/Brazil in past 14 days" rules? The UK citizen in question is not attempting to permanently immigrate for any reason–and already has an ESTA from September 2019 (valid for 2yrs). Edit I think this question is just different enough due to how interesting it is that I was told seemingly contradictory information to many official online US government sources. The old question was already edited and full of comments. I apologize to anyone whose time I may have wasted. Second edit I re-worded the question to stress that my question is about the contradiction between advice received from the US State Department Crisis Hotline (+1(202) 501-4444) and official advice. Please, stop trying to close this question as there is still lively truth-seeking going on. Final edit I called Customs and Border Protection and they said the 14-day rule is the law. They also said they have no idea why the state department said what they did.

The  says:  foreign nationals who have been in any of the following countries during the past 14 days may not enter the United States.  and then goes on to list Schengen, UK, Brazil, China, Brazil, Iran. However, the  is opening back up to both US and UK tourists starting 1 July, including Puerto Rico. Could I not just go to the Caribbean for 14 days, chill on the beach, and then enter the US? I had a big US road trip planned this summer and don't want to give up on it!


If I throw 5 dice, then the sum of numbers should be integers from 5 to 30.  How can I get the probability that the sum is n? (n = 5,6,...,30)  I used the formula: no of ways to get 8: 5_H_2 = 6_C_2 = 15  But this holds only for small n (n = 5, 6, ...), This is not true for n = 30, 29, 28...

I want to calculate the probability distribution for the total of a combination of dice.   I remember that the probability of is the number of combinations that total that number over the total number of combinations (assuming the dice have a uniform distribution).   What are the formulas for   The number of combinations total The number of combinations that total a certain number


I'm using PCA from sckit-learn and I'm getting some results which I'm trying to interpret, so I ran into question - should I subtract the mean (or perform standardization) before using PCA, or is this somehow embedded into sklearn implementation?  Moreover, which of the two should I perform, if so, and why is this step needed?    Edit: I've read that I should perform scaling if features have different scale. But one things still puts me in doubt - why scale when PCA considers the directions of greatest variance? Aren't I going to break this when standardizing the data before PCA?

What are the main differences between performing principal component analysis (PCA) on the correlation matrix and on the covariance matrix? Do they give the same results?


Adding a space to a filename breaks the code. This works:        This doesn't, the function returns undefined:        I tried playing with JSON.stringify, no luck. What am I missing? EDIT: Not a duplicate, the question is about spaces. pointing to the possible duplication actually provides an answer, but one can't know that without asking first.

How do you safely encode a URL using JavaScript such that it can be put into a GET string?  var myUrl = "http://example.com/index.html?param=1&anotherParam=2"; var myOtherUrl = "http://example.com/index.html?url=" + myUrl;   I assume that you need to encode the myUrl variable on that second line?


I accidently ran sudo rm *  I thought I was in an unimportant subfolder.  The result is that I deleted some very important files. Is there any way to get my data back?

Are there any tools, methods, incantations to recover recently deleted files on Ubuntu?  If it makes any difference, I want to recover a  2.x database file. But would be better to have a method/tool that works on any kind of file.


My mother is flying with United Airlines, and she is about 400 pounds, but looks maybe 350 or so. She will be taking flights:  Airbus A320: seat 7C Canadair Regional jet 700: seat 18B Bombardier Q400: seat 7b Boeing 737-900: seat 8D  I haven't flown for awhile and I just want to make sure my mother isn't embarrassed if she was to go to the airport, and they told her she needed to buy a second seat, because in reality I wouldn't want anyone to go through that because well its embarrassing. So I guess my big question is: Do you think she would fit fine, maybe not comfortable but fine, or do you think she might have some issues?

As I said in another question, I'm bringing my parents to visit me here in Sweden next year.  My mother is around 280-300 pounds and 5'6" (130-135kg, 1.67m). I am concerned that she might be asked at the airport to buy a second seat. If it's likely I would rather just buy the second seat in advance, because I don't want her to be embarassed/humiliated by some random employee. As well, I won't be there, they will be travelling alone and aren't used to dealing with airports and they won't know what their rights are.  In terms of how it will affect other passengers, it's not important, she will get a window seat and my dad will sit in the middle seat, so I don't see it affecting anybody.   She insists it's fine, "the last time I flew I fit easily!" but that was 20 years ago when she was half the size.   They will be flying BA or SAS, definitely not Ryanair.  So - where is the cutoff? Is a 300 pound 5'6" woman going to be too big to fit in a single airline seat? Or am I worrying about nothing?


After death, the Elves would spawn in the Halls of Mandos and remain there until the end of days, Man will leave Arda, never to return, and Dwarves will return to the Earth from which they were made. What of the Ents?

In the book The Two Towers Treebeard tells Merry and Pippin the sad story of the Entwives, who were lost (literally lost - they didn't die); he says the Ents believe that they "may meet [the Entwives] again in a time to come" and find a new home together where they can all live in peace.  However, he also says:      "But it is foreboded that that will only be when we both have lost all that we now have"   This loss will take the form of Sauron "withering" the woods of the Ents, just as Sauron once destroyed the gardens of the Entwives.  Then Treebeard sings an Elvish song about the Ents and Entwives, which ends with the lines     Together we [Ents and Entwives] will take the road that leads into the West,   And far away will find a land where both our hearts may rest.   Granted, fading into the West and traveling to a far away land there is a constant theme among the Elves, and this is an Elvish song, not an Entish one, but Treebeard says the Ents love it as well, which suggests that it reflects not only Elvish thought, but also Entish thought.    All of this is very familiar, and echoes the persistent thread woven throughout Tolkien's work - Arda and Middle-earth are changing;  the ancient world of mythology is transforming into the world of history in which we live today;  the old order is passing away;  the time of the Elves is over, and the time of Men is beginning;  magic will fade and science will supplant it; this final war against Sauron will be the last time that evil is gathered into a single, personified entity, and henceforth, the one ultimate evil will be replaced by many lesser, more insidious, subtler evils; and so on and so forth.  My question is this:  When Treebeard and the Elvish song speak of the Ents and Entwives finding a new, permanent home in the West, are they referring to Aman?  Will the Ents and Entwives eventually go to the Undying Lands?  The only other option seems to be that Tolkien thought the Ents would either die out or linger in Arda forever;  in the latter scenario, the Ents would presumably still be around today, though I would imagine that they all became what Treebeard referred to as "treeish", more or less immobile, and largely silent.  So if the Ents don't go to the Undying Lands, did they die out, go somewhere else, or did they, in Tolkien's imagination, linger on to modern times, hoever treeish they may have become?  Edit:   has this to say about the fate of the Ents;  the first citation (marked 6) is to Robert Foster's Complete Guide to Middle-earth, and the second (marked 14) is to Return of the King, specifically the chapter "Many Partings":     The Ents remained in Fangorn where they probably dwindled in the following Ages,[6] but Galadriel wished to Treebeard that they would meet again in Tasarinan, when Beleriand is lifted again from the waves, in Spring.[14]


After reaching 2k rep , I'm not receiving  +2 rep per edit. Why?

On Stack Exchange, users may gain a certain level of reputation.  What does reputation do? How can a user gain or lose reputation?   See also   in the Help Center  - Maximum amount of votes a user can use in a day and reputation requirements to vote.  - How to get an exact overview of the actions that got you your reputation.  - A full list of all privileges granted at each reputation level on all sites.


I noticed that if you apply this code:  var curry = function(x) {     return function(y) {         return x + y;     }; };  console.log(curry(3)(2));   You could apply the sum of 3+2, this is what is called "Curry", but I don't find it very useful, I would like to know, if there are many others good examples and cases to use it

I don’t think I’ve grokked currying yet. I understand what it does, and how to do it. I just can’t think of a situation I would use it.  Where are you using currying in JavaScript (or where are the main libraries using it)? DOM manipulation or general application development examples welcome.   mentions animation. Functions like slideUp, fadeIn take an element as an arguments and are normally a curried function returning the high order function with the default “animation function” built-in. Why is that better than just applying the higher-up function with some defaults?  Are there any drawbacks to using it?  As requested here are some good resources on JavaScript currying:    Crockford, Douglas (2008) JavaScript: The Good Parts  (Takes a detour into ML so skip the whole section from “A crash course in ML” and start again at “How to write curried JavaScript”)    (Mr. Resig on the money as per usual)    I’ll add more as they crop up in the comments.    So, according to the answers, currying and partial application in general are convenience techniques.  If you are frequently “refining” a high-level function by calling it with same configuration, you can curry (or use Resig’s partial) the higher-level function to create simple, concise helper methods.


Using the following code how can I access a from inside log2?     (function() {      function log() {        var a = "string";      }      log()       function log2() {        console.log(log.a);      }       console.log(log);      log2();    })()

I've heard from a variety of places that global variables are inherently nasty and evil, but when doing some non-object oriented Javascript, I can't see how to avoid them. Say I have a function which generates a number using a complex algorithm using random numbers and stuff, but I need to keep using that particular number in some other function which is a callback or something and so can't be part of the same function.   If the originally generated number is a local variable, it won't be accessible from, there. If the functions were object methods, I could make the number a property but they're not and it seems somewhat overcomplicated to change the whole program structure to do this. Is a global variable really so bad?


I currently have this:    With the following code and preamble:  \documentclass{article} \usepackage{amsmath}  \begin{document}  $\backslash c_{t}$ \begin{equation} {C_{t}: \pi D_{1}U(c_{t},L_{t})+\pi(-1)p_{t}=0 \iff D_{1}U(c_{t},L_{t})-p_{t}=0} \end{equation}  \end{document}   I want to have the "\c_t" on the same line, left-aligned.  I have tried my best to Google around but nothing seems to be right. One person suggested I put it in a table, but that seems cumbersome, especially to do this numerous times.

Inside an equation-like environment, I'd like to have some text that is aligned to the left margin of the text block, something like \intertext, but in the same line as the equation  Something like this:  \usepackage{amsmath,mathtools} \newcommand*{\midmathskip}{\hskip0.5\displaywidth\hskip-0.5\totwidth@} \newcommand*{\lefttext}[1]{\llap{\rlap{#1}\midmathskip}}  \begin{align} \lefttext{and similarly}  \hphantom{nn-nn}  \mathllap{hwnn} &= H+hw. \\ \lefttext{Thus}  nn-nn &= 1. \end{align}   of course, the \hphantom and \mathllap are just hacks to make it look right in this case, but I'm looking for something that would work in a gather environment too. flalign could help, for it alters the alignment of the equations (they are not in the center of the text block any more), and it doesn't help with gather anyway.  As a bonus, it would also be nice if it worked with aligned and alignedat.


Let us define $\mathbb{C}$ by $$\mathbb{C} = \mathbb{R}^2.$$ Real elements of $\mathbb{C}$ are tuples $(x, 0)$. But $x \neq (x, 0)$, so $\mathbb{R}$ cannot be a subset of $\mathbb{C}$.  I also read the following definition. Let $$\mathbb{C} = \{ a + bi \mid a, b \in \mathbb{R},\ i^2 = -1 \}.$$ But there is no $i \in \mathbb{R}$ such that $i^2 = -1$, so where does $i$ come from? If $i \in \mathbb{C}$ then we are using $\mathbb{C}$ in definition of $\mathbb{C}$.  NOTE: Apparently, there are similar questions on MSE but I think that lhf's answer is the best and most concise. Also, title "R is a subset of C?" is much easier to google than "Is a+0i in every way equal to just a?" I don't want readers to be redirected.

I'm having a little argument with my friend. He says that "$a + 0i$" is, in every way, absolutely equal to "$a$" (e.g.: $2 + 0i = 2$).  I say this is practically the case, so in every calculation you just assume that "$a + 0i$" is equal to the real number "$a$" and you always get the right results (this might not even be true, but I am no expert and as far as I can see this is the case). But then again, I believe that just cutting away "$+ 0i$" makes this number is not the same kind of number anymore, it's changed its structure and is not totally equivalent anymore. This is where he says I am absolutely wrong.  So, is it mathematically (strictly speaking!) perfectly fine to say that every complex number with an imaginary part of $0$ is just a real number? Or does this change the mathematical structure so much that it cannot be mathematically-valid but just something that happens to work (which is what I believe)?  I must say that I believe a complex number is one entity, whilst he believes that it is just a conglomerate of other entitites. So, as one said here, "$(a + bi) - bi = a$", I believe is barely a good argument. But then again: is it correct to view $a + bi$ as a single entity (like "$5$" or "$2$", just consisting of multiple symbols)? I'm (as a non-mathematician) not sure there either.


In the End, Rose throws off the Heart of Ocean in the Sea.There are numerous theories trying to find out the real reason.  1).The fact that it didn’t belong to her anyways.So it would be unethical to keep it.  2)She was gonna die anyways  3)She threw it to complete a "Life Circle".Gave something to where it all began.  Any other strong reasoning why she let it go?  Edit: The other question is similar, but does not cover all possible reasons.I have mentioned the answer there in above bullet points

In , the elderly Rose visits a ship searching for the  diamond, set in a necklace.  Unbeknownst to them, she actually carries it with her. In one of the final scenes, a bare footed Rose walks to the railing of the search ship, climbs up on it in similar fashion to when she and Jack were on the prow of the Titanic, and throws it into the ocean. The accepted answer in  suggests Rose threw it overboard for 'closure', but I simply cannot understand how that was closure.  After all, it is not as though Jack (when alive) had any real interest in it.  Nor did Rose. It was of interest only to her fiance Cal (who took his own life in 1929, when the stock market crashed). It could be said that the return of the 'Heart of the Ocean' to the ocean, was ..poetic in a sense, but how was it closure?  If not closure, then why did she do it? Update Interestingly, the  differs from the movie in that the people searching for the diamond are there to witness her throwing it overboard.  She even has a few words with Lovett as he is holding the object of his desire in his hand.  You look for treasure in the wrong place, Mr. Lovett.  Only life is precious, and making each day count.  Another snatch of the script that might be relevant:  The hardest part of being so poor, was being so rich.  But every time I thought of selling it, I thought of Cal.  And somehow I always got by without his help.


I don't know if this question doesn't answer itself.  Generally, when a binary operation $\circ:S\times{S}\to{S}$ is called associative, it is usually sufficient to state:  $$a\circ(b\circ{c})=(a\circ{b})\circ{c}$$  defines the operation as associative.  I don't know whether, if the above identity holds, it can be proven by induction that all parenthesizations of an expression containing are equivalent. I therefore ask the following in some ignorance:     Are there algebraic objects in which "associativity" holds only up to some finite $n$?   That is:     Are there algebraic objects in which, e.g, $a\circ(b\circ{c})=(a\circ{b})\circ{c}$  holds but $a\circ({b}(\circ{c}(\circ{d})))=(((a\circ{b})\circ{c})\circ{d}$ does not?

I've always heard this reasoning, and it makes obvious sense, but how do you actually show it for some arbitrary product? Would it be something like this?  $$(a(b(cd)))e=((ab)(cd))e=(((ab)c)d)e=abcde?$$  Do you just say that the grouping of the parentheses now corresponds to just multiplying straight through? Thanks.


Here is the code I'm using,  #include <stdio.h> int main () {     /* variable definition: */     double sidea, sideb, sidec;     /* Prompt user for side a */     printf("Enter length of side a of the triangle: \n"); // Input the base     scanf("%f", &sidea);     /* Prompt user for side b */     printf("Enter the length of side b of the triangle: \n"); // Input the base     scanf("%f", &sideb);     /* Prompt user for side c */     printf("Enter the length of side c of the triangle \n");     scanf("%f", &sidec);     // Calculate the Perimeter     double perimeter=  (sidea + sideb + sidec);     // Print the result     printf("The perimeter is : %f \n", perimeter);     return 0; }   Input data: 4.6 7.5 5.8  I can't for the life of me figure out why any values used for input result in 0.000000. Using float seems to work just fine. What am I missing. Thanks!

Why is it that scanf() needs the l in "%lf" when reading a double, when printf() can use "%f" regardless of whether its argument is a double or a float?  Example code:  double d; scanf("%lf", &d); printf("%f", d);


How to prove the following using mathematical proof by induction?  $\phi^n = \phi\times F_n + F_{n-1}$  $\phi = 1 + \sqrt 5 /2$  Fn is the Fibonacci number.  I tried solving this using induction but then again I get stuck when solving for the proof of n=k+1.   Thank you

I need to prove the following equation using mathematical induction and using the phi values if necessary.   $\phi^n = \phi F_n + \text{(another Fibonacci number)}$  In this proof, it is kind of hard for me to prove this with the part "another Fibonacci number".  Thank you in advance.  Help is much appreciated.


Company lockdown, I am not allowed to use apt-get so I have to get our systems team to download packages for me, they ftp them to the system and then I install them with   dpkg -i <package>.deb   Pain in the **** but I can't get this changed; I've asked, pleaded and cajoled but the auditors and security boys will not allow it, no matter that I have to send a request to them every time I want to install a new package or dependency.  SO: I need to upgrade from 16.04.3LTS to 16.04.7LTS (to fix a Samba vulnerability). Any idea if this is possible using package downloads, and where I can find them? Is it just a kernel, and if so where can I get it?    Ah OK looking further into info on CVE-2017-7494 I see "Ubuntu 16.04 LTS (Xenial Xerus):    released (2:4.3.11+dfsg-0ubuntu0.16.04.7)". The installed Samba version I have is 4.3.11 so I'm not sure why I'm seeing Ubuntu 16.04.7 in there? I get confused easily...

I have a friend who has got a computer that is not connected to the Internet. Is there any way to install software offline easily?


Let's say I have a function del that I want to call as argument of a function use_del in another function my_funct, like this :  void del(void *d); void use_del(char *str, void (*del)(void *));  void  my_funct(void) {     // code     char *str = "thing"      use_del(str, (*del));      // code }   I sometime have an error message saying I should do  use_del(str, (*de)(str)); but it sounds counter intuitive to me, since I'm supposed to call a function, not pass an argument to it.  Is the big block of code the correct use of a function pointer used as an argument ? I couldn't find resources on the subject beyond genericity, and I still struggle to make tests on specific parts of a code.

I want to create a function that performs a function passed by parameter on a set of data. How do you pass a function as a parameter in C?


Help me to split these kind of string :  Example:  string to split : "{'day': 1, 'count': 100}, {'day': 2, 'count': 100}"  expected output : [ {'day': 1, 'count': 100}, {'day': 2, 'count': 100} ]  using namespace std;; #include<string> #include<regex> #include<iostream> int main() {   string s1("{asd, dsf},{fsdfsdf, sdff}");   regex e("/{([^}]*)}/");    cout << s1 << std::endl;    sregex_iterator iter(s1.begin(), s1.end(), e);   sregex_iterator end;    while(iter != end)   {     cout << (*iter)[i] << std::endl'     ++iter;   }  }   this code fails for regex mentioned in the

Unfortunately, despite having tried to learn regex at least one time a year for as many years as I can remember, I always forget as I use them so infrequently. This year my new year's resolution is to not try and learn regex again - So this year to save me from tears I'll give it to Stack Overflow. (Last Christmas remix).  I want to pass in a string in this format {getThis}, and be returned the string getThis. Could anyone be of assistance in helping to stick to my new year's resolution?    Related questions on Stack Overflow:


Is there a way in ArcGIS to find the closest VALUE in a raster to a given x,y point? There might only be NoData at a certain point, in which case I want to find the closest pixel value.  I can't seem to find a function or combination of functions to do that.

I have two layers in ArcGIS: One is a vector point and the other is a raster layer. I want to append the value of the raster data grid to the vector point. The problem is the vector point is away from any existing raster grids with value, so the command "Sample" return no value for those vector point.    So my question is: How can I find the nearest raster cell given a vector point and extract the value from the cell?   Actually there are two things I need to do:   Identify the outliner within a ranger (Usually 1-2 cells away from my existing raster) Assign a value from the nearest raster to them, if they are in a range     Edited: I have about 3000 vector points and my problem is this:   I need to append the raster value based on locations to the vector points. I used the tool "Sample" and it works well for most of the points.  However, there is a situation like this   The right point can get the value from the raster ("Sample" works) but the left point cannot due to the alignment issues.  Raster to polygon is not working because I get error message that I cannot turn them into vector because they are out of the domain. Also I have points like this  Those upper points should not get any values because they are too far away from the raster.  I thought of someways to work around:    Step 1. Do the "sample" first    Step 2. Select the null value after the "sample" operations  Step 3. construct buffer zones (within 1 decimal degree) based on the null points    Step 4. use zonal statistics??? or other tools to loop through all the raster cells in the buffer, find the nearest one, extract its value and put it in the vector point.    I am stucked at step 4. I don't know which tool in ArcSDK I can use to achieve this function.   Or else...Do you have better idea to deal with that?    I have 20 raster layers like this and I would like to make it automatically (using model builder and arcobject).


I want to ask for advice for specific computer components (Graphic card, processor, motherboard ...) to build a new PC for my purposes. Is there any Stack Exchange site where I can get help with it? Any help is appreciated!

In a perfect world, the so-important advice "do not reinvent the wheel" would be extensively followed. In practice, everyday millions of wheels are reinvented simply because someone didn't know an existing solution for a specific problem. The best way to find a library, today, is googling it, but it's not always obvious which keywords to use. The lack of a tool for finding solutions is very counterproductive for the dev world as a whole. Stack Overflow is not very receptive for recommendation threads. So what about a new SE for it?


I have more than a thousand knife kills but I have yet to understand if I should hold down the F button(R3 on ps controller) or if I should just press it once.

When you press down the right stick to counter the attack, do you just press it, repeatedly press it, or press and hold? I've been knifed a few times from the front and each time I try to counter I fail. Also, if you believe you are about to be knifed and hold down the right stick until you are knifed, will that counter an attack, or do you have to press it down just at the right time?


I just performed a do-release-upgrade to bring a server from 12.04 to 14.04. The server rebooted at the end of the upgrade. However, when I log in, I am greeted by a contradictory MotD:     Welcome to Ubuntu 14.04.5 LTS (GNU/Linux 3.13.0-117-generic x86_64)         Documentation:           New release '16.04.2 LTS' available.   Run 'do-release-upgrade' to upgrade to it.      This Ubuntu 12.04 LTS system is past its End of Life, and is no longer   receiving security updates.  To protect the integrity of this system, it’s   critical that you enable Extended Security Maintenance updates:    *    /var/lib/ubuntu-release-upgrader/release-upgrade-available only contains the 16.04.2 message (referenced in related question )  I deleted /run/motd.dynamic so that it would regenerate, but this message has more lives than The Doctor and it must be coming from somewhere else that was not cleaned up in the release upgrade process.

I just did a do-release-upgrade going from Ubuntu 16.04 to 17.04. However, now when I login via SSH I have the following message   Welcome to Ubuntu 17.04 (GNU/Linux 4.10.0-20-generic x86_64)   * Documentation:  https://help.ubuntu.com  * Management:     https://landscape.canonical.com  * Support:        https://ubuntu.com/advantage  Ubuntu 12.04 LTS end-of-life was April 28, 2017 -- Upgrade your Precise systems!  $ sudo do-release-upgrade -m server  0 packages can be updated. 0 updates are security updates.   My question is, how can I remove the   Ubuntu 12.04 LTS end-of-life was April 28, 2017 -- Upgrade your Precise systems!  $ sudo do-release-upgrade -m server   it wasn't there prior the release-upgrade  I checked and I am on Zesty  lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description:    Ubuntu 17.04 Release:    17.04 Codename:   zesty   My question is not, how can I remove this message, this I found. My question is more, is there a reason why this appears after a release-upgrade? Is this message something generic not taking into consideration the current version of Ubuntu? Or maybe my system is not updated properly?


So say I delete catID from table A and table B has the same foreign key value? It's hard to explain so I'll try and show you with the two images below: items table  Is it possible to delete the catID from the above table (items) when I delete on cascade a value from the below table (categories): Categories  table:  So say I ran delete from categories where catID = 1 - This will delete both rows from both tables? So essentially it would delete the whole iID instead of just the catID value? Is it possible to have it delete only the value from the catID column in the items table? If I'm not making any sense, please let me know? As I'm finding it kind of hard to explain!!

I would like to ask about how to handle this relationship. For better view I've tried to simplify and convert my situation into how I think StackOverflow question voting has (sorry if not :-)    I would like to add a constraint with CASCADE DELETE rule however I don't know if it's possible for this case. Another option is to create an ON DELETE trigger, so...  My question is: What would you prefer, CASCADE DELETE constraint rule (if it's possible here) or ON DELETE trigger ? Or would you create a DB model for this simple case (imagine StackOverflow's voting scheme) different way ?  Why am I asking: I've read somewhere that CASCADE DELETE constraint rules are internally nothing else than triggers and that some people here don't prefer the constraint rules at all. I know, quite vague question, but I would like to have my DB clean from a not existing relationship records.  The important thing: I'm creating the application which should be able to run on the SQL Server as well as on MySQL database engines, but both should support all, the CASCADE DELETE constraint rules as well as ON DELETE triggers, I guess.  Thanks!


I would like to know a good book in statistics, that would interest me. I have before this spent a lot of time spent studying discrete mathematics and abstract algebra and i love its beauty and elegance. However i am yet to find something of the sort in statistics. Could you give me a few pointers?  I had taken an introductory course in probability and statistics(point, interval estimation, confidence intervals and all) and aced the exams but i find it to be pretty boring, mainly formulas. The problems(numericals) in statistics are pretty easy (relative to pure math), at least given in standard books. I have a lot of experience with theoretical mathematics and find it to be very beautiful are there something like this in Statistics?  I have already taken a glance across Casella and Berger, but the same thing it isnt intellectually challenging, like real analysis or modern algebra or topology  I would like to mention i am a dual CS and Math undergrad and i have a huge interest in theoretical Computer Science in general and algorithms in particular, so that you have an idea of my interests

What is a good introduction to statistics for a mathematician who is already well-versed in probability?  I have two distinct motivations for asking, which may well lead to different suggestions:   I'd like to better understand the statistics motivation behind many problems considered by probabilists. I'd like to know how to better interpret the results of Monte Carlo simulations which I sometimes do to form mathematical conjectures.   I'm open to the possibility that the best way to go is not to look for something like "Statistics for Probabilists" and just go to a more introductory source.


I'm having a table 'Products' and if Execute this query  SELECT TOP 1000 [ProductID]       ,[ProductDesc]       ,[ManufacturingDate]       ,[ExpiryDate]       ,[Price]   FROM [TestSat].[dbo].[Products]   I got the output:    and If I use this select query:  SELECT ProductDesc,Price   FROM [Products]   WHERE Price>20.00   I got this output:    If I use CTE-Select like this:   ;WITH ProductsCTE(ProdName,Price) AS ( SELECT ProductDesc,Price   FROM [Products]   WHERE Price>20.00 )   I got this output:    The only difference I found between this simple Select Query as well as CTE Select query is the Column name (ProductDesc as ProdName).  Does it is the only difference between normal Select query as well as CTE Select query?

From  :      Unlike a derived table, a CTE can be self-referencing and can be   referenced multiple times in the same query.   I'm using CTEs quite a lot, but I've never thought deeply about the benefits of using them.  If I reference a CTE multiple times in the same query:   Is there any performance benefit? If I'm doing a self join, will SQL Server scan the target tables twice?


Let $\sum a_n z^n $ be the laurent series expansion of $f(z)=\frac{1}{2z^2-13z+15}$ in the annulus $3/2 <|z|<5$.   I am interested in finding $a_1/a_2$.  Efforts:  $f(z)=1/(2z-3)(z-10)$  So using partial fraction decomposition $$f(z)=\frac{1}{7} (\frac{1}{z-10}-\frac{1}{2z-3})$$  How should I proceed from here? Thanks in advance.

Let $\sum_{-\infty}^{\infty} a_n z^n$ be the Laurent series expansion of $f(z)=\frac{1}{2z^2-13z+15}$ in an annulus $\frac{3}{2}< \vert z \vert < 5$. What is the value of $\frac{a_1}{a_2}$?  My attempt: First note that $f$ is analytic in the given annulus. $f(z)=\frac{1}{2z^2-13z+15}=\frac{1}{(2z-3)(z-5)}$ , $\quad$ $\quad$$\quad$$\quad$$\quad$$\quad$$\quad$  $=\frac{\frac{-2}{7}}{2z-3}+\frac{\frac{1}{7}}{z-5}$  , by Partial Fraction. How to goes further to find out the required function in the power series form and find $\frac{a_1}{a_2}$? I'm Confused with which term can be taken outside of the expression. Any help?


I wanted to do something in a programming language once. The only way to do it back then was pretty verbose, so I created an open source library to make it much easier.   It's encouraged to answer your own questions here, but is it also OK to mention your own library in the answer? Of course I want to list several ways of achieving the task at hand (including the verbose method and some other open source libraries) in my answer. But still: it's kinda self promoting.  So: OK or not OK?

I'm pretty sure using the "answer your own question" feature of stackexchange is considered spam/abuse, but wanted to doublecheck. My situation:   I had a problem I couldn't find a solution I wrote a program to solve the problem   In some sense, this is the perfect "answer your own  question" scenario (maybe someone else had the same  problem), but it seems to conflict with "avoid  self-advertising" rule.   Which rule prevails? (my guess is the "avoid self-advertising" rule)


Update: The  is not a duplicate to this question for a simple reason: the suggested duplicate does not explain how StackExchange deals with conflicting edits in the queue. And the fact that the suggested duplicate references a queue that can be filled up makes me begin to doubt the accepted answer to my question. To clarify the answer to my question in light of the linked suggested duplicate: is the review queue in question filled up by total edits to all questions, or number of edits to a given question. If the latter, how many edits fills up this queue to a single question, and how are conflicting suggested edits to a given question handled? Note: this question is very much about implementation: I want to know how StackExchange internally handles suggested edits. For some reason someone edited my question to remove the implementation tag. I am re-adding it in light of the suggested duplicatee.  Perhaps this is a duplicate, but I can't find the answer. SE uses review queues to approve suggested edits. What happens when more than one edits are suggested before any are approved? Is the result a branch or does the new edit edit the previously suggested edit? And if it is a branch, does SE merge the edits when they are both approved?

When clicking "edit" I see:  Your edit will be placed in a queue until it is peer reviewed. We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.  Like:     Likewise, when I am not logged in, clicking "improve this question" or "improve this answer" shows:  You are not . Your edit will be placed in a queue until it is .  And when I click 'Save', I get:  Thanks for submitting an edit. It is only visible to you until it's been approved by trusted community members  Like:     Who can suggest an edit? Where do suggested edits go? Who can vote on a suggested edit? How do suggested edits get reviewed? Can I earn reputation? What about abuse or bad edits? Sometimes the Community user approves or rejects my edit. Why is that? When can I not suggest an edit? Is there a minimum change requirement for a suggested edit? How do I check my suggested edit history? I disagree with the reasons why my suggested edit was rejected. What can I do? How do I know whether there are edits waiting for review? Someone suggested an edit to my own post, and the reviewers took the wrong action. What can I do? Are tag wikis included in this scheme? What do the "Improve Edit" and "Reject and Edit" buttons do? Why are apparently valid links to rejected edits resulting in 404 errors?   For more information about editing, see "" in the .


This refers to   I need to install Java 11, so I run this command  sudo apt install openjdk-11-jre-headless   But it installed Java 10 according to:  tomsk@tomsk-Ntb:/opt/Build/Phoenicis/phoenicis-dist/src/scripts$ java -version openjdk version "10.0.2" 2018-07-17 OpenJDK Runtime Environment (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.4) OpenJDK 64-Bit Server VM (build 10.0.2+13-Ubuntu-1ubuntu0.18.04.4, mixed mode)   One of devs said in that issue thread that Ubuntu provide Java 11 as Java 10:     the Java 11 package in Ubuntu does not provide Java 11 but Java 10   So how can I install true Java 11 on Ubuntu 18.04 LTS?  I would like to install it using repo or ppa, not binary.

While looking to compile OpenJDK from source, the newest General Availability version () insists on OpenJDK 9 or 10.  JDK 11, however, is not due to be released until .    However, to my surprise, when I do apt search openjdk the result is:  ... openjdk-11-jdk - OpenJDK Development Kit (JDK) ... openjdk-8-jdk - OpenJDK Development Kit (JDK) ...   No OpenJDK 9 or 10!  And wait, is that OpenJDK 11?  Maybe a Beta release?  Nooo....  So I looked at apt show openjdk-11-jdk:  Package: openjdk-11-jdk Version: 10.0.1+10-3ubuntu1 ...   Why has OpenJDK 10 been packaged as openjdk-11-*??


Mostly we some times uses silent words like knife, knock, knee etc i want to know is there any law in english please also inform me why these are silent? I am a new english language learner.

Why have a letter in a word when it’s silent in pronunciation, like the b in debt?  Can anyone please clarify my uncertainty here?


I have a long text in one attribute field and want to place it as a label. Because the text is so long I want to divide it in two rows. How to do that using QGIS. I have a solution to divide text in two fields and make multi labeling, but I don't want that.

How can I apply Multiline label option in the label property?  Name field contains a lengthy name. I want to wrap it.   My QGIS version is 1.8.


I have 2 sets of SAMSUNG 2GB DDR3 RAM  1: 2 x 2GB 2Rx8 PC3-8500S-07-10-F2  2: 2 x 2GB 2Rx8 PC3-10600S-09-10-F2  There 2 main differences: (8500S vs 10600S) and (07 vs 09)  Which set is better to install in my laptop?  Thank you.

I am seeking advice on which memory to use with my motherboard and CPU. Below are my components and some relevant information extracted from their official websites.   NOTE: Although this is a very specific case, a general answer is equally good for me — and also alot more useful for everyone else!  CPU: AMD Phenom II X4 810   ASUS M4A785TD-V EVO listed as one of many  motherboards.   Motherboard: ASUS M4A785TD-V EVO   4 x DIMM, Max. 16 GB, DDR3 1800(O.C.)*/1600(O.C.)/1333/1066/800 ECC,Non-ECC,Un-buffered Memory Dual Channel memory architecture (Complete list of specs: ).   NOTE II: I wouldn't want to do any overclocking as I have no experience with that. So I think the 1333 MHz is the most appropriate. Since the higher frequencies are marked with "O.C."  Questions:   How can I be certain that a specific RAM will work well (or not work) together with my CPU and motherboard? (The Qualified Vendor List is a good starting point, but it's a bit limited and sometimes a bit outdated). Is it true that choice of memory is not independent of the processor? How?    I'm worried I'll be missing something essential when buying my next RAM chips :)


I just started learning JAVA. I am writing a very simple program  to print something on based of command line argument. but it is not working as expected.   Here is my program and output.      It should print "e" but it is printing "n".    please tell me where I am doing wrong.

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'm trying to figure out "how to" split one Google Sheets cell into multiple cells. I'm using the "|" character to identify where the string in one cell should will be split. Ideas?  I have the following in cell B1.  space|space | will always separate values in the single cell.   Chromebook 101 | GHS | 8:00 am | ID#100103  I need to split the data into FOUR parts and into FOUR different cells.   H1 = Chromebook 101 I1 = GHS J1 = 8:00 am K1 = ID#100103   The data is being added to Google Sheets via form input and I need this to update automatically. I assume an arrayformula will be needed.   If possible, I'd also like to drop the | from cells H1, I1, J1, and K1.

I have a column of strings like this:  +---------+ | a bb    | | ccc d   | | ee ffff | +---------+   (exactly one space in each string), which I'd like to split by the space into two columns:   +-----+------+ | a   | bb   | | ccc | d    | | ee  | ffff | +-----+------+   This can be done by putting B1 =split(A1," ") and dragging down the column. But I'm looking for an arrayformula version of this.   Unsuccessful attempt: the formula  =arrayformula(split(A1:A3," ")) throws #VALUE error: "Function SPLIT parameter 1 value should be non-empty."


I'm aware of precisely one word that is spelled and pronounced the same, yet has a completely opposite meaning depending on its context: sanction.  On one hand, it is official permission for something.  On the other hand, it is a penalty (so, the opposite of permission).   Yet you could sanction (give permission for) a sanction (penalty to be applied). Hm.  Are there any other homonyms that share this trait of having directly opposing meanings?

I am looking for a list of all English words that are their own antonyms. Off the top of my head, I can only think of "either", "fast", "to dust" and "to lease", but there must be dozens more. Can you provide a link to a comprehensive list, if such exists?  Also, what are such words most commonly called? I like the term "Janus word" I once heard, but is that widely understood?  Edited by popular demand to make it absolutely clear that this is not a community wiki poll.


Is there any reason to use one foreach syntax instead of another?   foreach (array_expression as $value) {     // statements }   or  foreach (array_expression as $value) :     // statements endforeach;

Are there any differences between...  if ($value) {  }   ...and...  if ($value):  endif;   ?


I currently have the  camera and it takes really great pictures and I recently changed the settings so the image quality was at super fine and they turned out better. My plan is too upgrade to  camera. The dmc-lz40 has a 20mp sensor while the wb35f has a 16mp sensor. I'm not an expert on cameras, but I do know a 20mp sensor while give you 4 more million pixels per shot than the wb35f 16mp camera, but does this mean the Panasonic dmc-lz40 takes better pictures or is their more factors that go into a camera to make the image quality greater.

Recently, I was on the Panasonic website and came across this . When looking at it I noticed it had 12.1 megapixels, which is really low compared to cheaper cameras. So why is the megapixels so low on this camera and what does lowering the megapixels do to a camera's image? One thing I do know is lowering the megapixels give the image more sharpness, but I have no idea what that means.


I'm trying to track down an example of a ring in which there exists an infinite chain of ideals under inclusion. (i.e. $I_1 \subsetneq I_2 \subsetneq I_3 \subsetneq...$)

I am looking for an integral domain in which we have an infinitely ascending chain of ideals.   Clearly, this can't be a PID. Also, I am looking for examples other than infinite dimensional fields, integral domains like $k[x_1,x_2,\dots]$.


I've just started learning blender about an hour ago, so go easy on me. I'm opening up blender like this:  I'm trying to follow a beginner tutorial, but the first thing I notice is that I can't get my monkey to look like the one on the youtube-guy's screen; with faces. Can anyone explain why? Thanks in advance.

I don't know why but now, when i go in material preview or rendered (in solid mode it works fine), my object is entirely gray, or invisible idk, because it has the same color of the background. I've been working for days on this project without having this issue, it suddenly showed up. I tried opening other old projects and suddenly they all do the same so i guess it is some blender program setting that applies for all the projects, but idk how it happened cuz i didn't change anything :/, anyone got any tips?


I am an Indian planning to take a train from Disneyland Resort (Marne-la-Vallée/Chessy) to London. Please let me know where France and UK immigration respectively will be done.

I'm a non-EU citizen, I will be travelling from London to Paris next month, so I was wondering since most countries track entry and leave dates, if I use the train to switch these countries and they don't control it, my UK visa will seem like entry YES but no leaving. Same for the Schengen, I wouldn't have an entry date but I'll be leaving,  Will it be trouble later? Are they controlling this on trains? If not is there anything I should do before?


I have COM server application which controls another application CANoe. I want to show a progress bar on Form2 of COM application. The value of progress bar should be updated in the EventHandler. The eventHandler calls a method of form2 which will update the value of progress bar. The EventHandler is in main form.   private void mCANoeProgProgressChangedInternal(string sysvarName, object Value) // in main Form {     if (mCANoeMeasurement != null && mCANoeMeasurement.Running)     {         ProgressBarForm.Prog_progress(Value);     } }   And in Form 2 -   public void Prog_progress(object value) {     progressBarProg.Value = (int)value; }   it is showing an error      "An object reference required for the non-static field, method or   property 'Form2.Prog_progress(object)'"   at - ProgressBarForm.Prog_progress(Value); in main form.    Please provide your comments.

Consider:  namespace WindowsApplication1 {     public partial class Form1 : Form     {         public Form1()         {             InitializeComponent();         }          private void button1_Click(object sender, EventArgs e)         {             //int[] val = { 0, 0};             int val;             if (textBox1.Text == "")             {                 MessageBox.Show("Input any no");             }             else             {                 val = Convert.ToInt32(textBox1.Text);                 Thread ot1 = new Thread(new ParameterizedThreadStart(SumData));                 ot1.Start(val);             }         }          private static void ReadData(object state)         {             System.Windows.Forms.Application.Run();         }          void setTextboxText(int result)         {             if (this.InvokeRequired)             {                 this.Invoke(new IntDelegate(SetTextboxTextSafe), new object[] { result });             }             else             {                 SetTextboxTextSafe(result);             }         }          void SetTextboxTextSafe(int result)         {             label1.Text = result.ToString();         }          private static void SumData(object state)         {             int result;             //int[] icount = (int[])state;             int icount = (int)state;              for (int i = icount; i > 0; i--)             {                 result += i;                 System.Threading.Thread.Sleep(1000);             }             setTextboxText(result);         }          delegate void IntDelegate(int result);          private void button2_Click(object sender, EventArgs e)         {             Application.Exit();         }     } }   Why is this error occurring?     An object reference is required for the nonstatic field, method, or property 'WindowsApplication1.Form1.setTextboxText(int)


In my current directory, I have multiple subdirectories that contain files. I'm trying to move those files from the subdirectories to my current directory. To this end, I've created this inline bash program: for i in */ ; do for j in $f* ; do mv "$i$j" $PWD ; done ; done When I run this program, however, I'm prompted by the correct use format: usage: mv [-f | -i | -n] [-v] source target        mv [-f | -i | -n] [-v] source ... directory  I'd appreciate any clarification as to why this is happening. Thanks!

Or, an introductory guide to robust filename handling and other string passing in shell scripts.  I wrote a shell script which works well most of the time. But it chokes on some inputs (e.g. on some file names).  I encountered a problem such as the following:   I have a file name containing a space hello world, and it was treated as two separate files hello and world. I have an input line with two consecutive spaces and they shrank to one in the input. Leading and trailing whitespace disappears from input lines. Sometimes, when the input contains one of the characters \[*?, they are replaced by some text which is is actually the name of files. There is an apostrophe ' (or a double quote ") in the input and things got weird after that point. There is a backslash in the input (or: I am using Cygwin and some of my file names have Windows-style \ separators).   What is going on and how do I fix it?


I can't seem to hook up everything to the same power grid and I am getting so frustrated. I set it up so many different ways now to see if I could get it to work and it just won't. I've tried hooking up all my generators to the beam emitter and then to the relay dish and the control console and that didn't work. I've tried using a power pylon with the generators and that didn't work. I'm totally over this. any suggestions? (I'm building with the Minutemen on top of an old housing structure btw)

I have a problem in building the signal interception, it always tells me to use the power from one grid, which I've done but it doesn't work at all.  Is this a bug or there is a certain way of connecting them?


I'm working on a program that determines if a number is prime or not.  This involves dividing this number by all numbers smaller than it. But because we are dealing with very large numbers. Dividing it with too many numbers isn't a good idea . So I need a way to minimize the effort done by the program.  Lets assume the number is called $n$. My approach is to divide it by all numbers less than $\frac{n}{2}$.(rounded to the nearest integer) Is there anything wrong with it? And if there is a simpler way please point me to it.

How do I determine if a number is prime?  I'm writing a program where a user inputs any integer and from that the program determines whether the number is prime, but how do I go about that?


I see in few legacy applications, POST request is used to return data to the client. Input data is provided in Form data.  Ideally to get data we should be using GET request.  What are the possible reasons to use POST instead of GET to get data ?  If its for security reasons, why we have GET in the first place ? If input data is large, probably we may have to choose POST.  Please clarify.

What's the difference when using GET or POST method? Which one is more secure? What are (dis)advantages of each of them?  ()


Many faculty positions ask applicants to demonstrate potential for securing external funding. For a fresh PhD who has only co-written some grant proposals, how can we demonstrate this potential? I really appreciate any thought.

What are the possible answers for such interview question assuming a new graduate with no funds! How much funding you will bring to the department?


I was trying to prove this and I did a very similar argument as the one in this answer:   Basically,  $\lim\limits_{x \to \infty} f'(x) \neq 0$ would imply that $f$ is not bounded, so its limit is not finite.  However, the theorem I was trying to prove makes the hypothesis that $f''(x)$ is bounded. Is this hypothesis necessary?  It's sort of strange, because using just the argument I used would mean that (considering $f$ in n times differentiable) has all its derivatives equal to $0$.

Let $f\colon\mathbb R\to\mathbb R$ be twice differentiable with $f(x)\to 0$ as $x\to\infty$ and $f''$ bounded. Show that $f'(x)\to0$ as $x\to\infty$. (This is inspired by  to a different question)


I have an GFCI outlet box wired with yellow coated wire, which I believe goes to a dedicated circuit breaker. When I turn off the breaker to the box, I still read residual voltage.  Is this induced "phantom voltage"? Is it safe?  This outlet box is underneath a jetted tub, so I want to be sure there is no voltage in the box when I turn of the circuit breaker.   The 3 tools I used to measure the voltage are:  1) Gardner Bender GDT-3190 multimeter (10 MOhm input impedance) - when pluged in to outlet hot and neutral, multimeter reads 2.1V on 200V AC setting.   2) Klein Tools NCVT-2 proximity Voltage Tester - when close to the yellow wire, tester beeps for voltage reading on 12-48V scale, but not for 48 - 1000V scale.   3) SPERRY GFI6302 outlet tester - reads open hot, so not picking up any voltage.   Thanks for the help!

I am doing some work on a ceiling light and I notice that, even though the light-switch is off, my voltage tester shows voltage present.  Answers to other questions (below) explain about phantom voltages but how exactly do I test for these and know what voltages are real and what are phantom so that I can work safely?    Phantom voltage questions


I'm fairly new both as a DM and a roleplayer. I got into it a year ago and not a long time after that i started my own campaign. We have been at it for about a year or so, 5 players and me, and it's going relatively smoothly. I make a lot of mistakes, of course, mainly forgetting things or having to improvise (to varying deggrees of success) things i should have planned for.  We play a story-focused cinematic adventure based on the Curse of Strahd module for 5e.  Last saturday we were playing one of the final dungeons. The session got long and some of the players had to leave in the middle of the climax battle. We all agreed to end the session there, so i concluded the combat with a really cool scene and a grand reveal: Two long time friendly NPCs betrayed the party, suddenly becoming the Big Bad of the adventure, foreshadowing a cool final boss. It was not intended to affect the party mechanically, they lost nothing for it and they were properly rewarded for the dungeon exploration and the combat. It was only ment to change their objectives and made them rethink past events. Everyone was really happy with that, except for the rogue, that claims i shoud have allowed him to make an insight roll to discern intentions or lies, even tough he never even tried to talk or get to know the npcs.  Over the course of the adventure i tried to avoid Npc lies, playing them outright evasive or ambiguous, throwing some hints here and there that they were more than meets the eye, but had anyone tried to actually talk to them or suspected them i would have allowed for an insight roll and revealed the deceit early. But no one did.  Four of my five players were really excited about the sudden twist ("I expected so little about that NPC that i did not see it coming"), but the rogue was unhappy. He claims his character is a master in deceit (+9 decieve +9 insight) so he shoud have been given the chance to detect the lie. He claims i shoud have him throw insight when talking to a lying character, even if he as a player has no clue about it, completely giving away the secret and breaking the surprise for everyone.  I am not concerned about the rogue's behavior, it's not the first time and i can handle it. But it got me thinking about how the mechanics and narrative mix toghether, should i have given them more clues about the betrayal? How do i handle NPC's lying to the party to build up a plot twist? The only thing that comes to mind is doing the insight rolls in secret, but i don't think that would solve the issue.

I've recently begun DMing a 5th edition D&D campaign after a long time of quiescence as Dungeon Master. I really like this new take on D&D, but still, soon a problem has resurfaced, that is: the (paranoid) use of the Insight (or, as of 3rd edition, Sense Motive) skill, and I'm struggling to keep it in check.  I'm curious to hear how you handle this aspect of social interaction. When I'm interpreting an NPC, players often ask me if they can roll for Insight, and soon everyone at the table starts rolling. I'm thinking of outright disallowing such rolls, as (in my opinion) a player should only make a check when the DM calls for it. However, PCs should get to put their skills and proficiencies to use from time to time. So, this is what I've come up with:  1) Let them roll at most once per social interaction. Actually, I should be rolling for them behind my screen, so that they can't do metagame reasoning on a 1 or a 20.  2) Simply do not allow them to roll if they don't know the person they're interacting with to some minimal extent, or in cases where it is objectively not possible to draw a conclusion (for example, asking a guard if he has seen someone they're chasing, and the guard plainly replying "no").  3) Substituting most of the active Insight checks with passive ones. This would mean that the most empathic or intuitive PCs would sometimes sense something is amiss or tension coming from the NPC, or the like.   4) Only allow Insight checks if a PC clearly starts an interaction being suspicious of an NPC, otherwise not let it happen.  But still, I'm really not satisfied. What do you say to a player who failed or succeeded at the roll? To me, Insight should not be some kind of lie detector, but it often becomes one. Have you ever had this problem, too? What do you do?


I'm an animator who just lost his student licence for Maya and is looking to move to Blender, but I can't find a lot of options available for rigs for Blender. I only found Vincent, Rain, and Proog rig so far that are good quality. So, can anyone direct me to where I might find more rigs than 4 for Blender.

Since asking for tutorials, videos, resources, links to other content or downloads is considered off topic here, this is a specifically created Community Wiki which gathers resources for Blender and it has been approved by the .  Just write in the appropriate answer/section. If you have concerns, questions, post a  question, so we don't clutter the comments, but you can link your meta question from the comments.  Questions regarding such resources are not allowed anymore, except for very specific and on topic requests (ask on  if you're unsure about your question). Follow the instructions made in the question about how to post, what can be posted, etc.  Learning             Assets    (also see: )   Reference Images/Blueprints (also see: )    Tools    (also see: )      Other   Special Interest ()     Also see the .


I am going to start work with a company that works on a .NET framework and i am a professional java developer and i think i should switch to .NET because i cant see any bright future with java anymore. My questions: Now i have decided to move to .NET, what things i should learn as a total beginner. Should i learn C# or i should understand basics of .NET first?? as i know only that .Net is a framework and c# is one of language run on it. I am only interested in C# as it like java not in VB or any other. please tell me what i am suppose to learn and please refer to me some books. thanks

I know Java well. Which caveats and resources will help me cross to the other side (C#) as painlessly as possible.


I heard an American speaking on the BBC World at One news this lunchtime,  about the Greek debt. He was arguing that the character of a lot of Greece's debt is quite different to that of other debtor nations and that if comparable accounting methods were used they would be able to claim a debt level of less than 20% of GDP. (This is quite a radical opinion and not one accepted by the IMF, incidentally.)  He then made a statement the syntax of which made me sit up from eating my lunch. He said If they would have recognised this it would have saved them a lot of trouble. Personally I would have said If they had recognised this, it would have.... But then I thought that maybe because he was using an if clause, then it justified would.  Do others have views on this?

I watched a (Hollywood?) film the other day where a character visiting his just-hospitalised wife (who it seems will actually survive) says "If I would have lost you [I don't know what I'd do]".  I'd always thought this was an error made by non-native speakers (I myself would only expect "If I had lost you"), but there was nothing to suggest that in the movie. Is it a regionalism?  EDIT: Actually, that wasn't true about only expecting "If I had lost you". I'd have been perfectly happy with "If I'd have lost you", so long as I didn't think too hard about what was being elided. I'd usually elide "have" there to just a schwa (neutral vowel) anyway, and think no more about it.


$(1)$ $m(p,q)>0$ if $p≠q$ and $m(p,q)=0\iff p=q$:  obvious  $(2)$ $m(p,q)=m(q,p)$:   obvious  Now I thought that the triangle inequality need not hold with this definition, but I haven't been able to find a counter example in $\mathbb{R^2}$. So my question is does  $(3)$ $m(p,q)≤m(p,r)+m(r,q) $  necessarily hold with this definition? If so, how should I go about proving it, and if not is it possible to find a counterexample in $\mathbb{R^2}$? Or should I look elsewhere for counterexamples?   Thanks

Let $X$,$d$ be a metric space. Define $d'$ as the minimum of $1$ and $d$:  $$ d':\ X^2 \rightarrow \mathbb{R}:\ d'(x,y) = \min\{1,d(x,y)\} $$  The question is whether $d'$ is a metric. I've managed to prove that the first two properties of a metric hold for this function, but I can't seem to figure out how to prove the triangle inequality. Any hints?


I was wondering if it is possible to do something like what is happening in the Gif's in the link below?    I've found a tutorial for 'flat' tracking here:   but I'm specifically looking to be able to adjust the angle of the image that is superimposed to match that of the video section it is tracking.  Thanks for your time as always.

I have a video clip of a car driving by from left to right. My goal is to add a decal (mask) to the car door.  Right now I am painstakingly moving the mask via X and Y.


I found some typos (or errors) in my thesis, one formula, the label of one figure, and one citation. My thesis is done. What should I do? I know some students faked data and their degree were revoked. I did not fake data, but I am not sure how serious these typos are.   UPDATE  I cited and used 5-6 statements from an online report A and changed a little of them. They looks similar. But citation is wrong. I cited B in reference. What should I do? Is it Plagiarism?

I've just defended my PhD in mathematics and started a postdoc. While working  on an improvement of one of the results of my thesis, I realized that there are several minor mistakes and a big bug in a proof that invalids a minor result in the thesis (about 3-4 pages out of 110). Unfortunately neither I nor my advisor or referees figured it out the mistake. Though the result is minor, it is announced in the introduction and the manuscript is on-line on an ArXiv-like server, so that I could publish a new version but not cancel the one on-line.   What is the best thing to do? Upload an errata? Upload a "revised" version of the thesis?  Publish a "revised version" of the thesis on my web-page?  Can this damage my future career, making me look not "reliable" as a researcher?


When the main character's money ran out when he was in China, he did freelance assassination jobs to cover his expenses; in the near future where, "disposing of bodies" is  near impossible to be kept secretly. What would be the difference between time-travel assassinations and daylight assassinations if syndicates and freelance assassins still kill openly in the future? Like when they killed main character's wife? I don't see the purpose of sending people to the past if they still do open killings in the future.

The reason given in the movie Looper for sending targets to the past is that it is difficult to dispose bodies.  From ,     Thirty years into the future in 2074, time travel is invented, but is   immediately outlawed. However, because by that point tracking   technology has rendered it nearly impossible to dispose of bodies   secretly, crime bosses turn to time travel to send their targets to   the past to be killed using "loopers": hired guns paid in silver to   kill whoever is sent to them.   When trying to capture old Joe, they kill his wife. So how did they dispose the body of his wife? Or is it difficult to dispose bodies only in US and not in China? And they came for old Joe only because the Rainmaker wanted to close the loops?  Could someone explain? What am I missing?


I'm trying to render a cube animation in blender, but when i preview the render the shape changes, this is it before rendering:  and after rendering:  sorry for any problems, I'm new to blender stack exchange and blender in general

I'm a newb to blender so apologies if this is obvious.  I modelled a simple cup and set the modifier subdivisions to 5 after I turned on 'smooth'.  It renders fine in the CTRL+Z render preview window but when I do a final render the handle of the cup is blocky and not smooth.... Any ideas what I'm doing wrong?  Attached pics of the render with blocky handle and the object/render settings   Many thanks


Question is said in title.Suppose X is a  separable topological space and S is a dense subspace of X,to prove S is separable or give a counter-example,and we may add what conditions to make this statement true?

If $X$ is a separable topological space, and $V$ is some dense subspace of it, is $V$ necessarily separable?


Basically if I do the following:  SELECT distinct id FROM Table1   I get 20 000 rows  SELECT distinct id FROM Table1 WHERE id IN (SELECT id FROM Table2)   I get 4000 rows  So when I do the following, I expect to get 16000 rows, but I get no result.  SELECT distinct id FROM Table1 WHERE id NOT IN (select id from Table2)   -Empty result-  Why is this? Can it be that I run out of memory or something?

When I have a query that checks if a column of type uniqueidentifer does not exist in a table that has a null value then I get no results back. If the subquery does not return a null it works fine and it only happens when using not in.   I know I can just do a not null check in my subquery, but I am curious why this does not work.  Query Example:  select a.guid from tableA a where a.guid not in (select b.guid from tableB AS b)   Working Test:  select 1 where newid() not in (select newid())   Broken Test:  select 1 where newid() not in (select null)


To prove:  $$\frac{1}{\sin 10^\circ}-\frac{\sqrt 3}{\cos 10^\circ}=4$$  I tried taking lcm but could not get to anything.

$$E=\frac{1}{\sin10^\circ}-\frac{\sqrt3}{\cos10^\circ}$$  I got no idea how to find the solution to this. Can someone put me on the right track?  Thank you very much.


My data rolls over every 28 days. The data tracker on my Samsung Galaxy S6 is only rolling over on the same date each month. This is frustrating. I want to know how to change the data roll over to every 28 days instead of the same date each month.

The mobile data cycle (Settings -> Data usage) looks quite arbitrary. Since I have changed my data plan, now the new cycle should start at the first day of the month instead of the 6th.  How can I change the begin of a data cycle? I cannot seem to find some edit button, though I vaguely remember seeing it at the Data usage cycle menu.  Affected versions: Android 4.0, 4.2.2, 4.3.1.


How to manually choose which element of factor variable to throw out? Or how to automatically throw out the element with the least coefficient so that in the final model we have all the coefficients of factor variables > 0.   y <- c(1, 2, 2, 3, 1, 4) x <- c("red", "blue", "red", "blue", "red", "blue") dataset <- data.frame(y, x)  model <- lm(y ~ x, data=dataset) summary(model)   Coefficients:             Estimate Std. Error t value Pr(>|t|)    (Intercept)   3.0000     0.4714   6.364  0.00313 ** xred         -1.6667     0.6667  -2.500  0.06677 .    -- here this xred coefficient is negative   If instead xblue was chosen the coefficient would be positive. How to do it?  Throwing out the intercept from the model is not a solution because in case of multiple categorical variables problem will be solved for only one variable.   Edit. This jugglery might be good for aesthetics and storytelling. Suppose "colors" are different types of promotion and we are to interpret the model parameters to marketing stuff. Marketing people will feel much better seeing only positive coefficients for their variable. Explaining negative coefficients for stimulant variables is unnecessary challenge.

I am performing simple (first-order terms) linear regression on data having several categorical variables (i.e. factors), and it is often desired that for each factor, one of the levels should add nothing to the regressand, and the other levels should add positive values to the regressand.  When I perform a regression analyses, however, I often get a lot of negative coefficients.  Is there a non-manual way of choosing which levels of a factor should be used as regressor variables in order to maximize the number of positive coefficients in the equation?  In other words, how can I get R to do this (somewhat tedious) task for me?


I just make an application in C#, but something I don't like. I want to make the application running just one time. Now, if my application is running, when I run the application again, will start another application. I want to make that the application can be running just one time, if you want to run again the application, not create another application, but to start the running application.  Thanks.

Using C# and WPF under .NET (rather than  or console), what is the correct way to create an application that can only be run as a single instance?  I know it has something to do with some mythical thing called a mutex, rarely can I find someone that bothers to stop and explain what one of these are.  The code needs to also inform the already-running instance that the user tried to start a second one, and maybe also pass any command-line arguments if any existed.


My game has gone into 3D anaglyph red-cyan mode and I don't know how to return it to its normal screen.

Everything in Minecraft is red & blue and makes it hard to see.  It's like one of those red & blue 3D movies. How do I change it back to normal?


Who came up with the names Odious Numbers and Evil Numbers and what was the motivation behind the names?  All non-negative integers are one or the other.

There was  about evil numbers.  Some quick searching yielded .   I understand the definition of "evil" number, but not why the term was chosen.   Why are some numbers called evil in recreational mathematics?


In page-8 to 9 in Art of Electronics by Horowitz and Hill, the concept of current sources and voltage sources are discussed. Batteries are given as example of ideal voltage source but there seem to be no examples given of an 'ideal' current source, so what is an ideal current source? My question is different from  as here I ask about ideal sources, not real sources.

Please don't state the obvious that nothing is a perfect constant current source.  And please do not give examples of how to create them from components.  I looked at this  which stated the obvious - that you can not have a perfect current source.  So when I say constant current source, I am not referring to the mathematical concept used in circuits, but "natural" components that provide a close approximation to this. Key word is approximation.  A bit of research pulled up one interesting example which was a solar cell.  Is this a valid example?  A google search pulls up a similar Quora question . Which gave the example of a solar cell.  This is a more technical site and I was looking for a more engineering answer not a mathematical or laymen's answer.  Thanks.


A waiter says to two customers who ordered two bottles of mineral water.  Which should he say? I'll get you the waters vs I'll get you the water  I found this page which contains:   Here are your waters and your watering place. Drink and be whole again beyond your confusion.  What does the "waters" mean in this example?

Heard at the cafe: "We have three milks: soy, almond, and cow."  Is it ok to use the word "milks" in this context? I've heard it in other uncountable nouns, like "essential oils", or "simple sugars", or "red wines", so why can't we ask, "which milks do you have?"


Let's say that we have the points $\{1,2,3,...,k\}$. I am looking for all the ways to create a derangement of these points with the following rule: we define a derangement as a permutation $\sigma$ such that there is no fixed point i.e. $\sigma(m) \neq m$ for each $m \in \{1,...,k\}$. Now, let's define an integer $a \in \{1,...,k\}$. In the derangement, there must exist at least one point that is the total of $a$ numbers away from its fixed point. Also, the remaining points must be, at max, $a$ away from their fixed point i.e. there does not exist a number in the derangement of $\{1,...,k\}$ where a number is more than $a$ away from its fixed point. Here's my approach: I started by enumeration for different values of $a \in \{1,...,k\}$. If $a=1$, this only works for derangements of an even number of points where each couple $\{1,2\}$, $\{3,4\}$ etc is flipped the other way around, i.e. $\{1,2\} \rightarrow \{2,1\}$. We don't need to consider this case further. Now, if $a=2$, then there must exist at least one number that is $2$ numbers way from its fixed point. This could be, for example, if we had $k=4$ and $\{1,2,3,4\}$, we could have, for example, $\{3,1,4,2\}$ where $1$ is one number from its fixed point as well as $4$, meanwhile $2$ and $3$ are $a=2$ away from their fixed point. However, I am struggling to find a general combinatorial rule for this. Edit: example: Let $k=4$. Now the derangements for $a=1$ are the following: $\{2,1,4,3\}$ And similarly, for $a=2$: $\{3,1,4,2\}$, $\{3,4,1,2\}$ (I could only find these, so I could only find the total of $2$ derangements that fulfill this rule for $a=2$.) For $a=3$: $\{4,3,2,1\}$ (I could only find this, so I only found one derangement for $a=3$).


Prove that $\displaystyle\lim_{n \to \infty}\left(a^{n} + b^{n} +c^{n}\right)^{1/n} =  \max\left\{a,b,c\right\}$ for $\displaystyle a, b, c > 0$.

Let $m\in \mathbb{N}$ and $c_1,c_2,\ldots,c_m \in \mathbb{R}_+$. Show that $$\lim_{n\rightarrow \infty} \sqrt[n]{c_1^n+c_2^n+\ldots+c_m^n} = \max\{c_1,c_2,\ldots,c_m\}$$  My attempt: Since $$\lim_{n\rightarrow \infty} \sqrt[n]{c_1^n+c_2^n+\ldots+c_m^n} \leq \lim_{n\rightarrow \infty}\sqrt[n]{\max\{c_1,c_2,\ldots,c_m\}} = \lim_{n\rightarrow \infty} \sqrt[n]{n}\sqrt[n]{\max\{c_1,c_2,\ldots,c_m\}}=\lim_{n \rightarrow \infty} \max\{\sqrt[n]{c_1^n},\sqrt[n]{c_2^n},\ldots,\sqrt[n]{c_m^n}\}=\lim_{n \rightarrow \infty}\max\{c_1,c_2,\ldots,c_m\}=\max\{c_1,c_2,\ldots,c_m\}$$  it follows that $\lim_{n\rightarrow \infty} \sqrt[n]{c_1^n+c_2^n+\ldots+c_m^n}$ is bounded, but I don't think it's monotonically decreasing, at least I can't prove this. Can anybody tell me whether the approach I have chosen is a good one, whether what I have done is correct and how to finish the proof?


Following is my code sample.  SENTENCE = "Today is a wonderful day." sent= (word_tokenize(SENTENCE))  cursor = conn.cursor() cursor.execute('SELECT * FROM emotion_state WHERE key_word = %s', (sent)) results = cursor.fetchall() for i in results:     print(i)   Here I need to check whether the words in "sent" array available in the database or not. If there are some keyword available in the database that is in the "sent" array, I need to fetch all. I'm tried in followed way and it makes the error which is  raise errorclass(errorvalue) _mysql_exceptions.ProgrammingError: not all arguments converted during string formatting   How can I do this comparison easily ?

I know how to map a list to a string:  foostring = ",".join( map(str, list_of_ids) )   And I know that I can use the following to get that string into an IN clause:  cursor.execute("DELETE FROM foo.bar WHERE baz IN ('%s')" % (foostring))   What I need is to accomplish the same thing SAFELY (avoiding SQL injection) using MySQLDB. In the above example because foostring is not passed as an argument to execute, it is vulnerable. I also have to quote and escape outside of the mysql library.   (There is a , but the answers listed there either do not work for MySQLDB or are vulnerable to SQL injection.)


I use Win 10 with scaling 100%...    My monitor is LCD Lenovo. I feel that the LCD display is so big. Maybe larger than 15" I like to scale out my screen size maybe 80% or 70%  I can do this on Win 7, but I can not do it in Win 10.  I need a suggestion what program/application is needed to scale out my screen size at 80%

I would like to set my monitor's scale under 100%, but Win10 only lets me set it to 100% or higher. Why won't Windows let me do that? Is there any workaround to do that? I am aware of the fact that scaling below 100% will result in merged pixels.


help me please i’m already brining my turkey im 13 trying to cook this turkey. the brine has a small scoop of sugar, some bay leaves, peppercorns, and a few slices of lemon can i keep bring it until thanksgiving or will it affect the texture and taste and ruin my turkey. and how long should i cook it i was thinking 4 maybe 4 1/2 hours but give me some advice please

From my experience it is always best to marinate meat for a decent amount of time, so the meat can "soak" up the marinade and be more flavourful.  However, I came across this recipe here:   In the directions, it says: Add pork and marinade for a minimum of 6 hours or overnight, but no longer than 12 hours.  I was wondering, why does it say "no longer than 12 hours"? Isn't it good to let meat marinate for as long as possible?  Thanks.


While running the update at Ubuntu 14.04 LTS (Trusty Tahr). The following error is being encountered:  W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/universe/binary-amd64/Packages  Hash Sum mismatch  W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/multiverse/binary-amd64/Packages  Hash Sum mismatch  W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/main/binary-i386/Packages  Hash Sum mismatch  W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/universe/binary-i386/Packages  Hash Sum mismatch  W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/multiverse/binary-i386/Packages  Hash Sum mismatch  W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/main/i18n/Translation-en  Hash Sum mismatch  W: Failed to fetch http://us.archive.ubuntu.com/ubuntu/dists/trusty-updates/universe/i18n/Translation-en  Hash Sum mismatch  E: Some index files failed to download. They have been ignored, or old ones used instead.   command used:  sudo apt-get update

When I check for updates, I get a "Failed To Download Repository Information" error.   This is what comes up under details:   W: Failed to fetch gzip:/var/lib/apt/lists/partial/us.archive.ubuntu.com_ubuntu_dists_natty_main_source_Sources  Hash Sum mismatch,  E: Some index files failed to download. They have been ignored, or old ones used instead.


Why has the option of adding a DSL connection on the tab for Wired Connection been removed after 17.04?  I was using 16.04, and then upgraded to 17.04 and later 17.10, I still had the DSL connection, as it was saved from previous versions.  However, on a fresh install of 17.04, 17.10 or 18.04, I cannot create DSL connections anymore. In my opinion this is a important feature, as many Indian ISPs with many customers still use DSL.  For an average user who has a single device it's easier to create a DSL connection, and put the DSL modem in bridge mode, to avoid hassle of port forwarding.

In 17.04 I could create DSL Connections in the network settings. In 17.10 the option is not available anymore. How can I create a DSL connection?