I just updated MiKTeX packages in my workstation, and TexWorks gives the following error when I try to make pdf:     pdflatex.exe - Entry Point Not Found   The procedure entry point ?WideCharToUTF8@Utils@Core@MiKTeX@@SA?AV?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@PB_W@Z could not be located in the dynamic link library MiKTeX209-core.dll.   How can I fix that?  PS: OS - Windows 7 Pro 64-bit, MiKTeX 2.9 32-bit.

Every once in a while after updating MiKTeX, the installation gets into an inconsistent state. This might be a problem with the packages (an example is described in ), but sometimes packages are split or renamed. The cases I remember are when  and when miktex-etex-base-2,9 was renamed to miktex-etex-base-2.9 (if I recall correctly; I am sure it was either that or something very similar). In each case the MiKTeX Update process suggested to remove the "old" packages but it didn't give the user any hints about him having to manually add the respective replacement packages back in the package manager to get one's MiKTeX installation back into a usable state.  What are best practices for keeping MiKTeX up to date? Note that I'm not asking about installing new packages or fonts in general; there are other questions covering this area.   In which order should one execute the Update process and the Synchronization of the repository? , it is recommended to check the MiKTeX homepage before updating. What else should one do? When and in which order (and why) should one execute the "Refresh FNDB" and "Update Formats" processes within the MiKTeX Options menu? What else can happen? Other advice?


Microsoft support are trying to send me a 1GB file. The problem is, their homespun file transfer service (filetransfer.support.microsoft.com) appears to be configured in a way which prevents downloads from being resumed. I don't know what they've done on their side, but here are some example symptoms:   In IE's download manager, if I press "pause" then resume, IE says "resuming..." for a moment, then "restarting..." and starts again from 0 bytes In Firefox, any pause or interuption is reported as "Failed". If I do the "Firefox resume download trick" (copy the .part file, download again, pause, paste the old .part file over the newly created one, resume), it just instantly reports "Failed" In the Firefox extension / download manager DownThemAll, any attempt to resume after a pause or interupption is reported as a "406 error". It is also unable to partion the download into multiple parrallel downloads (normally, it can split it into four seperate streams)   Microsoft want me to download this file, but right now it seems impossible - I'm in a country where sustaining a connection with 0 milisecond blips simply doesn't happen.  Is there any way I might be able to restore a download from such a server?

When am downloading any link that's cannot be resumed, if my Internet connection gets disconnected then download link stops working.  What can I do to resume the download from the link?


It would be great to create polls on Stack Exchange. For example:  What is your favorite programming language?  C C++ Java PHP ...   I think many people would use this.

Stuff like polls, recommendations based on subjective constraints, puzzles, webcomics etc. do not belong on the serious main SE sites, where professionals should be considered at work and having just a few spare minutes ("code's compiling") to answer questions, so they should not be distracted by such things. However, I'd also like to have a home for these things still using the SE engine. For the reason I mentioned before, this needs to be a separate place though. Let's call it four.[sitename-here].com.


When i open the terminal and type      su XXXXX    where terminal open in the name of XXXXX , it ask for password and switched. Am i not already there in the first place when i opened the terminal? So What is the differences between terminal open in the first place and terminal open after I switch to same as open in first? I do not seems to find any differences here. When i type exit it exits and bring me where i am before. Am i always in same place or different? If i am on same place why switching account happen ?

I already read it from manual but I can't see difference..  su - change user ID or become superuser  sudo -s [command]   The -s (shell) option runs the shell specified by the SHELL environment variable if it is set or the shell as specified in passwd(5).  If a                    command is specified, it is passed to the shell for execution.  Otherwise, an interactive shell is executed.  sudo -i disappear description in manual


I have a dataset that I have created in Python with a category called change_label that has values "buy, hold, sell" (or alternatively I could use -1,0,1).   I am wondering, what is the best way to fit this data so that machine learning algorithms can be applied to it to make predictions?   My options are label encoding, label binzarization, or one-hot encoding. Basically, I thought that simply using sci-kit learn's LabelBinarizer() would be enough. However, I want to be sure. Any advice?

I have been building models with categorical data for a while now and when in this situation I basically default to using scikit-learn's LabelEncoder function to transform this data prior to building a model.  I understand the difference between OHE, LabelEncoder and DictVectorizor in terms of what they are doing to the data, but what is not clear to me is when you might choose to employ one technique over another.    Are there certain algorithms or situations in which one has advantages/disadvantages with respect to the others?


This is just a question that popped up in my head while going through basic real analysis. The ordinary Mean Value Theorem (MVT) is given as follows.     Let $f:[a,b] \to \mathbb{R}$ be a function satisfying the following conditions: $(i)$ $f$ is continuous on $[a,b]$ and $(ii)$ $f$ is differentiable on $(a,b)$. Then $\exists c \in (a,b),$ such that $$f(b)-f(a)=f'(c) \cdot (b-a)$$   Of course, we can restrict $f$ to any interval $[x,y] \subset [a,b]$ and apply the theorem on $f|_{[c,d]}$ to state that $\exists z \in (x,y)$ such that $f(y)-f(x)=f'(z) \cdot (y-x)$  Can I formulate a converse proposition as follows?     Let $f:[a,b] \to \mathbb{R}$ be a function satisfying the following conditions: $(i)$ $f$ is continuous on $[a,b]$ and $(ii)$ $f$ is differentiable on $(a,b)$. Then $\forall c \in (a,b), \exists x,y \in [a,b]$ such that $$f(y)-f(x)=f'(c) \cdot (y-x)$$   Does it hold?  If yes, how do I prove it? (How does one find out the points $x$ and $y$, which need not be unique, that work for a given point $c?)$ Does it hold under weaker assumptions on the function?  If no, can you provide me a counter example? Can I impose stronger conditions to make it work?  Any help would be much appreciated. Thank you.  EDIT : As pointed out by @Henrik, the proposition does not hold with it's current assumptions. On the other hand, @MANMAID claims that it does hold with the additional assumption that $f$ has no point of inflection. It seems very interesting. I require a formal proof, though.

I am wondering if the following converse (or modification) of the mean value theorem holds. Suppose $f(\cdot)$ is continuously differentiable on $[a,b]$. Then for all $c \in (a,b)$ there exists $x$ and $y$ such that $$ f'(c)=\frac{f(y)-f(x)}{y-x} $$


I managed to add the abbreviation list by this way:   \DeclareAcronym{can}{ short = CAN , long = Control Area Network, class = abbrev } \printacronyms[include-classes=abbrev,name=Abbreviations] \ac{cip}   The result is like this:    CAN Control Area Network  Control Area Network(CAN)   What I want is only the first line with the abbreviation list, not the second line. Is there any way I can get rid of this? Because if I delete \ac{cip}, the whole list is empty... Thanks a lot for help

I have one problem related to Abbreviation list:   First I define the abbreviations: such as   \DeclareAcronym{cip}{ short = CIP , long = Common Industry Protocol, class = abbrev }  \DeclareAcronym{gprs}{ short = GPRS , long = General Packet Radio Services, class = abbrev }   Then   \ac{cip} \ac{gprs}  \printacronyms[include-classes=abbrev,name=Abbreviations]   The result is like this:  Common Industry Protocol(CIP),General Packet Radio Services(GPRS)  Then Abbreviation list..  My question is how can the system does not show the Bold part, only showing the abbreviation list.  Because when I delete  \ac{cip} \ac{gprs} The list is empty, so nothing shows up...Can anyone help me with this


I've been reading the Wikipedia article on CSP () and one of the first formulas there has double vertical bars in it.  $$ {{w}}={\arg \max }_{{\mathbf  {w}}}{\frac  {\left\|{\mathbf  {wX}}_{1}\right\|^{2}}{\left\|{\mathbf  {wX}}_{2}\right\|^{2}}}$$ The text right before the formula says both the enumerator and denominator are variances of two multivariate signals. What do double vertical bars here mean? I know that double bars should mean the norm of a vector. In this case we have matrices (X1 and X2), so how can that be the norm of a matrix? Please help.

Shilov's Linear Algebra writes a matrix with two bars on each side rather than square brackets. I didn't find any mention of it with a quick Google search, and I can't see any other examples this double bar notation.  Does it mean something other than a matrix? Is it an older notation? Or is it something else?  Thank you


Is there any idiom or expression for someone who gets something without any effort? like a guy got a job without doing anything.. I want a idiom by which i can mock him.

I'd be greatly appreciative of a cleverly devised idiom/phrase that depicts the following concept:     Results without work/effort.   ...and/or...     My Work/Effort; Your Result.   Any idioms/phrases you can recount or conceive would be of use.    Contextual Edit:  The idiom/phrase should be in the context of service offering/hiring or task delegation, not free-loading as most answers thus far have understandably assumed. E.g.     [You hire me for] My Work/Effort; [My work/effort produces] Your   Result.


My father is cooking a soup, we don't have a cheesecloth and he wants to clear the soup.

I have a big pot full of chicken necks and backs on the stove which I need to separate into (a) stock and (b) everything else.  I'm wondering the best way to go about doing this. I've previously laid cheesecloth into a fine-mesh strainer and poured it through that, but the cheesecloth always seems to kind of clog up, making straining 4 litres of stock a very lengthy process. I also tried a coffee filter laid inside a strainer and got more-or-less the same results.   Alternatively, I ditched the cheesecloth and just used the fine-mesh strainer by itself, but, unsurprisingly, this method leaves some bits I'd rather not have.   I'm wondering: is there a better way? Or should I stick with the cheesecloth and work on being more patient?


I have a student visa to study in Spain with a "valid from" date of Jan 8.  I am travelling to Spain from US on Dec 21.  I know I need to leave Spain and go to non-Schengen country (Morocco or UK) and then re-enter Spain at some point to activate student visa.  Do I have to leave Spain before Jan 7 or just within 90 days?

If I have a Type C visa from the Norwegian embassy valid for February 9-28, and my Type D national visa from the German embassy valid from March 1 - August 31, 2017, do I need to leave/fly out of the Schengen area on the 28th and fly back on the 1st day of March?


I have Sample file s1.txt like this:    Sample.log.54   Sample.log.56   Sample.log.57   Sample.log.58   Sample.log.59   Sample.log.110   Sample.log.113   Sample.log.114   Sample.log.115   Sample.log.116   Sample.log.117   Sample.log.118   Sample.log.119   Sample.log.120   Sample.log.121   Sample.log.122   Sample.log.112   Sample.log.123   Sample.log.124   Sample.log.140   In the folder i have many other files. but i need to grep particular string from the files that are listed in s1.txt. I should not read all the files which are present in the folder.

I am trying to run grep against a list of a few hundred files:  $ head -n 3 <(cat files.txt) admin.php ajax/accept.php ajax/add_note.php   However, even though I am grepping for a string that I know is found in the files, the following does not search the files:  $ grep -i 'foo' <(cat files.txt)  $ grep -i 'foo' admin.php The foo was found   I am familiar with the -f flag which will read the patterns from a file. But how to read the input files?  I had considered the horrible workaround of copying the files to a temporary directory as cp seems to support the <(cat files.txt) format, and from there grepping the files. Shirley there is a better way.


long story short: I got a big prize from my scholarship, which consists in a lot of money for books, and I mean a lot: almost USD$ 3000. Thus, I am going to buy lots of books, of course!  So I'm asking for book recommendations. My field is theoretical high energy physics (I work on extended SUSY and string theory, mostly), so my focus is in those topics, but not only that.  The books I'm targeting are:   General physics   Landau's vol 1, 2, 3, 5 and 9 Griffiths QM and Electrodynamics Weinberg QM "Lectures on Quantum Mechanics", Dirac  QFT   Zee's QFT in a nutshell Weinberg vol 1,2,3 Srednicki QFT Shifman Advanced topics in QFT Mussardo "Statistical Field Theory" Coleman's "Aspect of Symmetry"  String   the two volumes of Green, Schwarz, Witten Polchinski vol 1 and 2 Nastase AdS/CFT book Peter West "Introduction to Strings and Branes" Becker^2 and Schwarz "String Theory and M-theory" "Quantum Fields and Strings: A Course for Mathematicians" "A First Course in String Theory", Zwiebach  Group Theory   Ramon's "Group Theory: A Physicist's Survey " "Representation Theory", Fulton  Susy   "Modern Supersymmetry Dynamics and Duality", Terning "N=2 Supersymmetric Dynamics for Pedestrians", Tachikawa "Supersymmetry and Supergravity", Wess and Bagger "Supergravity", Freedman  GR   "General Relativity", Wald  Mathematical Physics   "The Geometry of Physics", Frankel  Others   Exactly Solved Models in Statistical Mechanics, by Baxter    Reading previous questions related to this one, I found Naber's "Topology, Geometry and Gauge Fields" and Bredon "Topology and Geometry", which seem to be good books. Witten suggested to read "some" complex analysis as part as your academic training, and I found Lang's "Complex Analysis" and the series of four volumes by Stein and Shakarchi, but I have zero experience in those topics (as far as a formal course), so I don't know if those are good choices or not. Finally, one of my academic rivals computed using harmonic superspace something I computed using the standard Minkowski superspace, and it seems interesting. He suggested to me Galperin et al "Harmonic Superspace" as a good place to learn it, what do you think about that book?  Do you have any suggestion and/or recommendation? I feel like another Stastitical Mechanics book is missing (Landau's is too hard, and next semester I may have to teach some Statistical Mechanics, as part of my future teaching duties.) Any other book that might be a good reference in the future?, some more mathematical physics (topology, geometry, group theory, etc.)?, maybe some condensed matter book for string people like me?

Every once in a while, we get a question asking for a book or other educational reference on a particular topic at a particular level. This is a meta-question that collects all those links together. If you're looking for book recommendations, this is probably the place to start.  All the questions linked below, as well as others which deal with more specialized books, can be found under the tag  (formerly ).  If you have a question to add, please edit it in. However, make sure of a few things first:   The question should be tagged  It should be of the form "What are good books to learn/study [subject] at [level]?" It shouldn't duplicate a topic and level that's already on the list   Related Meta:


Let $Y$ be a Hausdorff topological space and $X$ an arbitrary topological space. Let $c_1,c_2 : X \to Y$ be continuous functions. Show that the set $P = \{x \in  X \mid c_1(x) = c_2(x)\}$ is closed in $X$.  How do I go about solving this without product topology? Thanks in advance.

I'd like to know if the following proof is valid.  The only thing I'm not sure about (though I can't see why it's invalid if it is) is if we can always use the Hausdorfness of $Y$ to separate an open set from $f(C)=g(C)$.  "Let $X$ be a space, $Y$ a $T_2$-space, and $f,g:X \to Y$ continuous functions.  Prove that $C:=\{x \in \,|\,f(x)=g(x)\}$ is a closed subset of $X$."  Let $x \in X$ be such that $f(x) \ne g(x)$.  Since $Y$ is $T_2$, there are open sets $U_\alpha \ni f(x)$ and $V_\alpha \ni g(x)$ such that $U_\alpha \cap O_\alpha=V_\alpha \cap O_\alpha=\varnothing$ for all $\alpha \in A$ where $A$ is the set indexing the points of $f(C)=g(C)$, and $O_\alpha$ is an open set containing $x_\alpha \in f(C)=g(C)$.  Let $U:=\displaystyle\bigcap_{\alpha \in A} U_\alpha$ and $V:=\displaystyle\bigcap_{\alpha \in A} V_\alpha$.  Then $U \cap f(C)=V \cap f(C)=\varnothing$.  Therefore, since $f,g$ are continuous, $f^{-1}(U)$ and $g^{-1}(V)$ are open sets in $X$ disjoint from $C$.  Since $X\setminus A$ is the union of such open sets, it is open itself and therefore $C$ is closed.  Thanks.


I am an Indian citizen currently living in Ireland with Irish residence Stamp 1. I am planning to travel to Dubai from Ireland through the UK (Heathrow airport) with connecting flights.   Do I need any UK transit visa?

Is there a website or some other way to find out if I need a transit visa for a short stop in the UK on my way somewhere else? Ideally this should give me the answer for all nationalities, and take into account any other visas I may have.


I am getting on my back end a json this way   "pessoa": {         "nome": "asas",         "tipoPessoa": "F",         "dataNascimento": "15/06/1983",         "foto": ""     },     "cns": "ewe",     "pessoasFisicas": {         "sexo": {             "idSexo": "1"         },         "estadoCivil": {             "idEstadoCivil": "2"         },          "dataObito": "11/12/2017"     },     "pessoasEnderecos": {         "cep": "966",         "pais": {             "idPais": "5"         },         "municipio": {             "idMunicipio": "1"         }      },     "pessoasContatos": {         "tipoContato": {             "idTipoContato": "1"         }     },     "pessoasCaracteristicas": {         "cbors": {             "idCbor": "1"         }      }   and I got two problems in my method to save it on the database. I have a null pointer exception in   Entidades entidades = new Entidades(); entidades.setIdEntidade(json.get("pessoa").get("entidade").get("idEntidade") == null ? 0l: json.get("pessoa").get("entidade").get("idEntidade").asLong());   but sure that method will be null because  the business rule to entidade is not mandatory requirement but I need to know how I do not get a nullPontException in this case   look my method to save the data   @RequestMapping(method = RequestMethod.POST, value = "/pacientes")     public HttpStatus cadastrarPacientes(@RequestBody ObjectNode json) throws ParseException  {           SimpleDateFormat formato = new SimpleDateFormat("dd/MM/yyyy");              Entidades entidades = new Entidades();             entidades.setIdEntidade(json.get("pessoa").get("entidade").get("idEntidade")== null ? 0l: json.get("pessoa").get("entidade").get("idEntidade").asLong());              Pessoas pessoas = new Pessoas();             pessoas.setNome(json.get("pessoa").get("nome").textValue());             pessoas.setNomeSocial(json.get("pessoa").get("nomeSocial")== null ? null : json.get("pessoa").get("nomeSocial").textValue());             pessoas.setFoto(json.get("pessoa").get("foto").textValue()  == null ? null : json.get("pessoa").get("foto").textValue());             pessoas.setNomePai(json.get("pessoa").get("nomePai") == null ? null : json.get("pessoa").get("nomePai").textValue());             pessoas.setNomeMae(json.get("pessoa").get("nomeMae") == null ? null : json.get("pessoa").get("nomeMae").textValue());             pessoas.setDataNascimento(formato.parse(json.get("pessoa").get("dataNascimento").textValue()));             pessoas.setEntidade(new Entidades());             pessoas.setEntidade(entidades);             pessoas.setTipoPessoa(json.get("pessoa").get("tipoPessoa")== null ? null : json.get("pessoa").get("tipoPessoa").textValue());              Paises pais = new Paises();             pais.setIdPais(Long.parseLong(json.get("pessoasEnderecos").get("pais").get("idPais").textValue()));     PessoasFisicas pFisicas = new PessoasFisicas();     pFisicas.setDataCadastroPisPasep(formato.parse(json.get("pessoasFisicas").get("dataCadastroPisPasep")== null ? "" : json.get("pessoasFisicas").get("dataCadastroPisPasep").textValue()));             Ufs uf = new Ufs();             uf.setIdUf(json.get("pessoasEnderecos").get("uf").get("idUf")== null ? 0L : json.get("pessoasEnderecos").get("uf").get("idUf").asLong());       pacientesService.cadastrarPacientes(pFisicas, pCarac,pessoasEnderecos, pac );        return HttpStatus.CREATED;     }   i have a similar error in other case.. whe i pass a empty date i got a null too.. `     pFisicas.setDataCadastroPisPasep(formato.parse(json.get("pessoasFisicas").get("dataCadastroPisPasep") == null ? "" : json.get("pessoasFisicas").get("dataCadastroPisPasep").textValue()));   so i asking..how can I handle this error, remembering that by my business rule it is possible to have the date null and entidade   im using api Spring boot

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


I want to know what's the Windows default font name used in bars. I can't find the window to change window color and appearance in the Windows 8, and it'd show the current font name in the bar (I believe).  The font is used in this bar:

What font is used for the interface in Windows Phone 8 and Windows 8? Is this font free to use?


I'm creating a simple spellchecking program.  It basically loads in a dictionary and misspelled words.  I have a function aimed at removing repeats, and another function that generates all vowel combinations of a word to be checked. I'm having an issue with my vowel function.  I keep getting CurrentModifcationException, but I feel like it should be able to modify the array its adding words to as the array is statically defined at the top. Basically this function takes in an ArrayList and recursively adds additional words to the ArrayList which are vowel combinations of the word inputted. An example is if 'who' was inputted, it would add 'wha, whi, whe, whu' to the array list. The Code DEFINED AT TOP OF CONTAINER CLASS private static List<String> vowelList = new ArrayList<>(); private static ArrayList<String> checkList = new ArrayList<>();  private static void feedWordsForVowelCheck() {          for(String temp : checkList) {             System.out.println("Checking vowels for: " + temp);           //  createVowelCombosStatic(temp, 0);             createVowelCombos(temp, 0 , checkList);         }         // System.out.println("Does this finish?");     }    private static void createVowelCombos(String word, int start, ArrayList<String> checkList) {         StringBuilder sbAddWord = new StringBuilder(word);         String[] splitWord = word.split("");                   if (start==splitWord.length) {             checkList.add(word);             return;         }                  if (splitWord[start].matches(".*[aeiou]")) {             for (int j = 0; j < 5; j++) {                 sbAddWord.setCharAt(start, vowelList.get(j).charAt(0));                 createVowelCombos(sbAddWord.toString(),start+1, checkList);                 //System.out.println(sbAddWord.toString());             }         }         else             createVowelCombos(sbAddWord.toString(),start+1, checkList);     }

We all know you can't do the following because of ConcurrentModificationException:  for (Object i : l) {     if (condition(i)) {         l.remove(i);     } }   But this apparently works sometimes, but not always. Here's some specific code:  public static void main(String[] args) {     Collection<Integer> l = new ArrayList<>();      for (int i = 0; i < 10; ++i) {         l.add(4);         l.add(5);         l.add(6);     }      for (int i : l) {         if (i == 5) {             l.remove(i);         }     }      System.out.println(l); }   This, of course, results in:  Exception in thread "main" java.util.ConcurrentModificationException   Even though multiple threads aren't doing it. Anyway.  What's the best solution to this problem? How can I remove an item from the collection in a loop without throwing this exception?  I'm also using an arbitrary Collection here, not necessarily an ArrayList, so you can't rely on get.


How can I convert a String object to a Date object?  I think I need to do something like this:  Date d=(some conversion ) "String "   Any help would be greatly appreciated.

I am parsing XML file. In this file there is one tag containing date string "2008-11-10T05:51:33Z" and I want convert this string in to java.util.Date object.  How can this be done?


When you twist your glass and the ice cube stays still, what causes that?  (Example: you put an ice cube in your glass, and then spin the glass to see the other side of the ice cube, but it won't spin with the glass, instead it stays still.)

When you have a drink with an ice cube and twirl the glass, the liquid itself seems to twirl but the ice cube stays roughly in the same place. Why is this?


In the help docs it just says     Community wiki posts have been donated to the community in hopes that   others will edit them to keep them up to date, to add useful   information, and generally improve their quality.   When editing to improve a tag wiki what is the recommended scope?  What information should be included to create what would be considered a high quality, complete tag wiki?  I've edited several tag wiki's and while browsing through them have found a variety of styles..   A full length wiki with information on the subjects background, origin, history, etc.. (e.g. encyclopedic.. Wikipedia style)  Only information that people may find useful in answering questions.. common questions and their answers & reference information. Only information that would educate on how to intelligently discuss the subject or present  question regarding the subject.   I enjoy writing about a subject.  It helps me learn.  So I am tempted to go on and on and expand on every aspect of a subject if I start writing.  But too much information could be bloat and make it difficult to be useful if people are only referencing them for answers rather than a broader education of the subject.

The tag  has no tag wiki, and SO invites me to help create one.  I've got the reputation.  I think Database-design really needs a tag wiki.  I'd like to help.  But I don't feel quite up to creating a tag wiki on my own for three reasons.  First, I'm not too sure what a good tag wiki looks like, and I don't know the tools that create tag wikis.  Second, the subject of database-design can get quite controversial.  There are experienced professionals that I respect that hold very different and mutually contradictory views on what constitutes good database design.  Third, most of today's database design neophytes are interested in building a database to be embedded in a single application, and to be managed without a DBA.  Most of the classic works on database design were based on the idea of strategic data management spanning multiple departments, multiple applications, one or more DBAs, and several kinds of stakeholders.  The goals of good design are completely different in these two cases.  So I'd like two kinds of help:  First, how do a get skills at building a good wiki?  Second, is there any way several of us could collaborate on a Database-design wiki before launching it on an unsuspecting public?    Edit based on first response.  The most valuable thing I've learned from the response is that the tag wiki should outline the issues more than the answers.  Accordingly, I've come up with a document that reflects my first attempt at describing the issues concerning database design.    I'm not entirely happy with it, but it's not a disaster, IMO.  It's too long, and it's not as clearly bulleted as the C# tag wiki.  Some of that difference may be appropriate. It does clarify most of the issues connected to good database design.  I've left a lot for the closely related data-modeling tag wiki, that doesn't exist yet either.  I'm tempted to go ahead and create the wiki, and post my effort.  After that the community process can correct for my blind spots.  But maybe I should post it here first,  and let the meta discussion give some feedback and correction first.  Opinions?    I've decided to go ahead and post my first effort at a tag wiki for Database-Design.  It will probably be heavily maintained both by me and by others.  But it's a start.  There probably needs to be a parallel effort on a tag wiki for data modeling  (sp?).


In QM, each measurement result cannot be predicted, in other words, that is random. This being random has a great implication: if there is no rule to specify the results, so there is cause. This lack of cause is not something acceptable logically. In other words, the non-deterministic (that is stochastic) NATURE of, let's say, electrons, means that there is not enough causes to determine the results of the observations (so electron decides where to go for itself). So, how can one resolve this contradiction between the orthodox viewpoimt of QM and the causality conjecture?

Causality is generally accepted to be a fundamental physical principle. But quantum mechanics is acausal (e.g. there is no 'why' as to the result of a measurement of the position of a particle in an infinite 1D square potential well). In which case what is a distinction between causality and determinism, that has a meaningful non-acausal definition of causality.  It seems to me that "causality = determinism + quantum mechanics". It seems that it doesn't provide any new concepts, it's just a flawed attempt to reconcile determinism with the arbitrary probabilistic nature of QM, which are ultimately unreconcilable. Does anyone agree with this idea? If not, I would like someone to try and convince me that I'm wrong.  I am fully aware that a lot of threads barking up this tree, and I have tried reading many of them, but none seem to crystallize my problem very well.


Is there is any website where I can draw a polygon/triangle online. A website with an option to use coordinates to plot points and other tools to draw polygons.

What software do you use to accurately draw geometry diagrams?


The second law of thermodynamics says that heat cannot spontaneously flow from a colder to a hotter reservoir but only with the expenditure of mechanical energy. This is taken as a postulate or law in thermodynamics. Is there a deeper reason (probably from statistical mechanics) for why this is so?

How do you prove the  from statistical mechanics? To prove entropy will only increase with time? How to prove? Please guide.


Is there any way to run a program that uses a dos executable file on a desktop? I have one program that is a must for my work and I cannot find anything comparable in Ubuntu aps.

Is there a version of MS-DOS that I can add to Ubuntu? I have old MS-DOS games.


I am required to call an input method and a calculations method from main. Input will prompt the user to input 3 variables. Without using arrays, loops, or globalized variables, how can I return the 3 variables back to main to be passed as parameters to the calculations method?

Is there a preferred way to return multiple values from a C++ function?  For example, imagine a function that divides two integers and returns both the quotient and the remainder.  One way I commonly see is to use reference parameters:  void divide(int dividend, int divisor, int& quotient, int& remainder);   A variation is to return one value and pass the other through a reference parameter:  int divide(int dividend, int divisor, int& remainder);   Another way would be to declare a struct to contain all of the results and return that:  struct divide_result {     int quotient;     int remainder; };  divide_result divide(int dividend, int divisor);   Is one of these ways generally preferred, or are there other suggestions?  Edit: In the real-world code, there may be more than two results.  They may also be of different types.


I know that the standard use is that an abbreviation at the end of a sentence that would normally end with a period has just a single period.  I also know that a sentence that ends with a statement in parenthesis has a period on the outside of the parenthesis.  However, what happens if I have both?  Do I put one period inside the parenthesis and one outside, just one period outside, or just one inside?  For instance:  I need to go to the grocery store and pick up ingredients (flour, sugar, milk, etc.).  I need to go to the grocery store and pick up ingredients (flour, sugar, milk, etc).  I need to go to the grocery store and pick up ingredients (flour, sugar, milk, etc.)

In Hungarian, when there's a dot both inside and outside parentheses at the end of a sentence, we write it as follows:     Sok állatom van (kutya, macska stb.).   (Meaning: I've got many animals [dogs, cats, etc.])  I'm not sure though how do we write it in English.   I've got many animals (dogs, cats, etc.). I've got many animals. (dogs, cats, etc.) I've got many animals (dogs, cats, etc.) I've got many animals (dogs, cats, etc).


need help with the following question:  Let $S \subseteq P(\mathbb N)$ be defined inductively so that:   $\mathbb N \in S$  for all$ ~ a \in \mathbb N \Longrightarrow \mathbb N\setminus\{a\}\in S$ for all $A,B \in S \Longrightarrow A\cap B \in S$   Prove that if $A\subseteq \mathbb N~ $ and $~ \mathbb N $ \ $A$ is finite then $A \in S$  thanks!

$A \subseteq \mathcal{R}(N)$ and given that (by inductive definition):   $N ∈ S$. If $a \in R$, then $R \setminus \{a\} \in A$.    I need to prove that for each $A \in S$, $N\setminus A$ is finite. How can I prove this formally?


I am using Ubuntu 14.04 x64 w/ Unity. I like how the Task Manager shows up in Windows with Shift+Ctrl+Escape. So I tried creating a similar keyboard shortcut in Ubuntu with the command gnome-terminal -e htop.  Nothing happens when invoking that shortcut. However, if I assign a different combination, say Ctrl+Alt+H, it works fine.  What am I doing wrong? Is Shift+Ctrl+Escape reserved or something? It used to work perfectly in 13.10 and before.

For some reason my custom shortcut for the System Monitor that I created according to this instruction does not work.   When I press it, it just does nothing. Any ideas?  My shortcut is ctrl+shift+esc.  Here is a screenshot:


I am searching for a client-side template engine for plain HTML pages. I am not talking about single DIV's in the page, I'm talking about the full page.  Say I have a simple webapp, with a menu, and 100 menu entries. So, there are in fact 100 different pages (100 different webapps!), and I want different urls for them:  http://mysite/myapp/page1.html ... http://mysite/myapp/page100.html   Now, the 100 pages share a common layout (a menu bar, a header, a footer, and the whole HTML head), and I don't want to cut-and-paste them 100 times, it's absolutely wrong. I want to keep template tiles in different files, and to merge them with some client-side JS framework.  I have looked to AngularJS and to Handlebar.js, but I cannot see a simple way to do this. You always have to write tons of code.  Old technologies (FRAME's and IFRAME's) are deprecated, IMHO.  So, my question is, what are the possible solutions?  I think this is a common task, however I cannot find a clear answer.  Please notice this is a very simple task if performed server-side (with PHP, JSP, or whatever).

Is there a decent way with static HTML/XHTML to create common header/footer files to be displayed on each page of a site? I know you can obviously do this with PHP or server side directives, but is there any way of doing this with absolutely no dependencies on the server stitching everything together for you?  Edit: All very good answers and was what I expected.  HTML is static, period.  No real way to change that without something running server side or client side.  I've found that Server Side Includes seem to be my best option as they are very simple and don't require scripting.


In our org, we are trying to block some triggers when an account is being updated through data loader.  Our strategy was to get the logginHistoryId with getCurrentSession method from the SessionManagement class. With this logginHistoryId query for that particular logginHistory and display the field Application.  Id loginHistoryId = Auth.SessionManagement.getCurrentSession().get('LoginHistoryId');         LoginHistory loginHistory = [select Id, Application from LoginHistory where Id =: loginHistoryId];         System.debug('Login Application: ' + loginHistory.Application);         if (!loginHistory.Application.contains('Bulk')) {             // Execute Trigger         }   If there is a mention of Bulk we would block would not execute the trigger.  This seems to work when a user logs in through the UI, but when we try it with the data loader we get this error.  System.UnexpectedException: Current session unavailable.   Is there an other way to found out if the user logged in through Data Loader?  In essence what I am trying to do is get the current session of the running user with  Id loginHistoryId = Auth.SessionManagement.getCurrentSession().get('LoginHistoryId');   with this map retrieve the LoginHistoryId and query the Application  LoginHistory logInApplication = [SELECT Id, Application FROM LoginHistory WHERE Id =: LoginHistoryId].Application   This works fine. But unfortunately when logged on through Data Loader I get the error  System.UnexpectedException: Current session unavailable.

i have scenario like write a trigger avoid insertion of records  from  data loader,only manual insertion trigger will fire?on any object     while Entering records from data loader trigger should not fire?


I have been writing a PHP script for a "Contact Us" form that I am using on a website to allow users to comment about the site. It has several fields, including a name field and a textarea for comments. After the user submits the form, the comment is entered into database, which is then queried for the five most recent comments and displays them on the site. However, users cannot currently enter apostrophes (') in either the name field or the comments area and have them display properly.   This is the sequence of events:  "User Submit -> Prepare SQL -> Insert Record -> Query Database -> Return recent Comments"   Currently, this is what I have for PHP:  //Function that will trim the input, and run it through a small security check function test_input($input) {     $input = trim($input);     $input = stripslashes($input);     $input = htmlspecialchars($input);     return $input; }  $name = test_input($_POST["txtName"]); $comments = test_input($_POST["txtComments"]);  //Prepared statement to insert a new Contact record $stmt = $conn -> prepare("INSERT INTO tableName (name, comments) VALUES (?, ?)");  //Create the parameters of the prepared statement $stmt -> bind_param("ss", $param_name, $param_comments);  //Set the parameters of the statement, running them through a security check $param_name = mysqli_real_escape_string($conn, $name); $param_comments = mysqli_real_escape_string($conn, $comments);  //Execute the prepared statement $stmt -> execute()   As you can see, I am running the variables through both the htmlspecialchars() function and the mysqli_real_escape_string() function. However, I still get a strange output when I run the function.    Input  Name with Apostro'phe I'm happy with the "/" and "\" of the present.   How It Looks In...  ...database  Name with Apostro\'phe I\'m happy with the &quot;/&quot; and the &quot;&quot; of the present.    I understand that the &quot; is from the htmlspecialchars function, and think that the \' is from the mysqli_real_escape_string() function.   ..website comment section (populated from database)  Name with Apostro\'phe I\'m happy with the "/" and the "" of the present.    Same here with the \'. How do I get it so that when it redisplays in the HTML after being queried from the database that the apostrophes display normally?   However, this is not what I want. When it displays in the comments section (after being queried from the database), I want it to display as it was input by the user. I don't really care how it looks in the database, as long as it displays properly when it is returned to HTML by the query to populate the list.    What should I do so that users can input apostrophes in their name/comments, and have it display as such after being returned from the database; but at the same time, not run the risk of SQL injection? I have looked at several related questions, but have not found anything that answers my question.     I have already tried the methods in this post without success      I don't need anything like this, only apostrophes   Let me know if I need to clarify anything!

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


QUESTION  What is a citation of a book whose scope includes the uniform distribution [1] that is generalized to an $n$-ball [2]?  Among other things, I'd like to read a book that include such information as the distribution's parameters, its support, its probability density function, and its moment generating function.  Answers to this question may be useful to other users as well (cf., [3]).  Bibliography  [1]   [2]   [3]

CONTEXT  In my research, I am utilizing an $n$-ball distributions along with two related distributions. I'd like to make certain I have a firm handle on the way to describe my three distributions. I have been looking for reference books on the subject [1], I've got some guidance, but have not been able to find what I'm looking for yet.   In this post, I attempt to deal with the simplest case that i am concerned with. I'm modelling my approach to this based on the format I find on wikipedia (e.g. [2])  QUESTIONS   What is the characteristic function of the uniform distribution on a ball in $\mathbb{R}^𝑛$? [edit: solution offered by @whuber in the below solution.]  What is the entropy of the uniform distribution on a ball in $\mathbb{R}^𝑛$? [edit: solution offered by @whuber in the below comment.]  MY UNDERSTANDING  The $n$-ball distribution here is a generalization of the uniform distribution.   Parameters  By $n\in \mathbb{N}$ I denote  the dimension of the ball.  By $R\in \mathbb{R}, R>0$ I denote the radius of the $n$-ball.  By $\gamma$ I denote a parametrization of the $n$-ball given as $\gamma: (0,R) \times  \left[0, \pi\right) \times \cdots \times  \left[0, \pi\right)  \times \left[0, 2\pi\right) \rightarrow \mathbb{R}^n$, which is defined by: $$\gamma\begin{pmatrix}r\\\\ \phi_1 \\\\ \vdots \\\\ \phi_{n-1}\end{pmatrix} \rightarrow   \begin{bmatrix}    r \cos{(\phi_{1})} \prod\limits_{i=1}^{1-1} \sin{(\phi_{i })} \\\\   r \cos{(\phi_{2})} \prod\limits_{i=1}^{2-1} \sin{(\phi_{i })} \\\\   \vdots \\\\   r   \cos{(\phi_{n-1 })} \prod\limits_{i=1}^{n-1-1}   \sin{(\phi_{i })} \\\\   r   \prod\limits_{i=1}^{n-1}   \sin{(\phi_{i })} \end{bmatrix}. $$  Support $$i = {1, 2, \ldots, n}$$ $$x_i = (-R,R)$$ $$0\leq \sum_{i=1}^{n}x_i^2 < R^2$$  Probability Density Function  With respect to the indicator for the $n$-ball, $\mathcal{I}(\left\|\textbf{x}\right\|_2 <R)$, the probability density is $$\frac{\Gamma\left(\frac{n}{2} + 1\right)}{\pi^\frac{n}{2} R^n}\,\mathcal{I}(\left\|\textbf{x}\right\|_2 <R)$$  Mean  $$E(X_i) = 0$$  Variance  $$\textrm{Var}(X_i) = \dfrac{1}{n+2} R^2$$  $$\textrm{Cov}(X_i,X_j) = 0\quad\quad i \neq j$$  Entropy  $$\log\left(\frac{\Gamma\left(\frac{n}{2} + 1\right)}{\pi^\frac{n}{2} R^n}\right)$$  Characteristic function  $$\phi_n(t) = e^{-i\frac{|t|}{R}} \,_1F_1\left(\frac{n+1}{2};n+1; i\frac{2|t|}{R}\right).$$  BIBLIOGRAPHY  [1]   [2]


In my program I am making the game Tetris! How could I rotate my char array piece? I know how to get the key syncs and everything. I could make each piece already rotated in the char, but is their an easier way? Here is my char array I'd use.  char block[4][5] = {        "     ",       " x   ",       " xxx ",        "     ", };

What are the best algorithms (and explanations) for representing and rotating the pieces of a tetris game?  I always find the piece rotation and representation schemes confusing.  Most tetris games seem to use a naive "remake the array of blocks" at each rotation:    However, some use pre-built encoded numbers and bit shifting to represent each piece:    Is there a method to do this using mathematics (not sure that would work on a cell based board)?


Synchronize this lazy initialization is showing  in sonar I want to solve this problem by static class holder idiom singleton pattern so how will make in static class holder idiom singleton pattern   public final class ContainerFactory {  private static final int SPLIT_PANE  = 1; private static final int TABBED_PANE = 2;  private static TopLevelContainer Container = null;    public static TopLevelContainer getTopLevelContainer() {     if(Container == null)     {         int containerType = Integer.parseInt(System.getProperty("NUEVO_CONTAINER", "1"));          switch(containerType)         {             case SPLIT_PANE:                 Container = new SplitPaneContainer();                                     break;             case TABBED_PANE:                 Container = new TabbedPaneContainer();                                     break;         }     }         return Container; }   }

What is an efficient way to implement a singleton pattern in Java?


Let's assume we have some arbitrary triangle manifold meshes which are transparent.  How real guys effectively render it?  Is it possible todo it without sorting faces back to front (e.g. via bsp) and then render it with blending?

I've seen somewhere rendering technique that allows order-less rendering of partially transparent sprites/objects.  Though I can't remember what the technique is called, so I'm having trouble Googling it.


When I right-click -> "Open with" -> ...  I see an option for atom 1.19.3 and 1.19.1.  However Spotlight locates only one Atom.app (which is found in Applications).  Opening with 1.19.1 succeeds. However it turns out my version of Atom is actually 1.19.3.  Opening with 1.19.3 however fails to do anything.  I notice from the same screenshot there is a similar duplication going on with VSCode.  What is the problem with my system?  And how to repair it?

For whatever reason, the "Open With" context menu in Finder is always listing every app four times (exactly).     I've read about (and tried) rebuilding the Launch Services database to restore the context menu to its initial state, but nothing seems to work. I've also used Onyx.app to clear user and system caches, but I'm still left with four repetitions of each app under the "Open With" service. I have restarted the system a few times just to be sure it was not some temporary corruption of the list.  I'm running OS X 10.6.6 on a 2011 17" MacBook Pro with a fresh install of OS X (i.e. I didn't use Migration Assistant.app or a Time Machine backup). I did, however, sync all my preferences and other files using MobileMe like I always do, so I imagine it's feasible that a preference file somewhere is causing problems? I didn't notice whether this was happening before or after my MobileMe sync.  How can I fix this so one app shows?


I was a bit confused, when we use  List<String> lst = new LinkedList<>();        when we use  LinkedList<String> lklst = new LinkedList<>();   At the beginning, I thought they are the same, but today, I realized they are not the same. For example, if I call lst.getFirst() It will tell me there is a error. However, if i do lklst.getFirst(), it works fine. My question is when do we use lklst then? why they are different? Also, does it apply same rule for Map. THanks!

I have seen this mentioned a few times and I am not clear on what it means. When and why would you do this?   I know what interfaces do, but the fact I am not clear on this makes me think I am missing out on using them correctly.   Is it just so if you were to do:  IInterface classRef = new ObjectWhatever()   You could use any class that implements IInterface? When would you need to do that? The only thing I can think of is if you have a method and you are unsure of what object will be passed except for it implementing IInterface. I cannot think how often you would need to do that.   Also, how could you write a method that takes in an object that implements an interface? Is that possible?


strong text****strong textfirefox keeps asking me to install a flash player so I can play video but every time I try it says there is no plugin for this I need a flash player if I want to view video so how do I fix this using ubuntu 14.04 LTS

Even though I have the latest Adobe Flash player 11.2 for Linux in Firefox -   - a particular online flash game still requests that I update to the latest flash player.  I've tried this online game on my laptop (Windows 8 with Flash Player 11.8) and it has no problems.  Is there a way to trick Ubuntu or this game into thinking Flash Player 11.8 is "installed"?


I was reading Harry Potter and the Deathly Hallows, and in chapter 5 (“Fallen Warrior”) I came across the following sentence:     The suddenness and completeness of death was with them like a presence.    I am wondering, since there are two properties of death described  here, shouldn't were be used instead?

I was surfing the internet the other day when I found this phrase: Instead your precious time and attention is wasted. To my ears, it sounds wrong. But I'm not a native English speaker, so I consulted with a number of them, and some of them said that it was "is" because the adjective modifies only the noun "time" and not "attention". Others said it "is" because that's just how it is. But I still believe it should be "are". Any help is appreciated.


Currently, my Rails app is working on a server with 1GB RAM. I feel it's so slow so that I'm planning to shift to better Server.  There are 3 choices such as 2GB, 4GB, and 6GB. or 2GB with SSD. Is there any big changes if I just move all the files of Rails app to there, and prepare exactly the same deployment?  Is 1GB RAM is too low for Rails? Anyone has any idea about this?

This is a  about  Related:      I have a question regarding capacity planning. Can the Server Fault community please help with the following:   What kind of server do I need to handle some number of users? How many users can a server with some specifications handle? Will some server configuration be fast enough for my use case? I'm building a social networking site: what kind of hardware do I need? How much bandwidth do I need for some project? How much bandwidth will some number of users use in some application?


I am new to Apex trying to do some practice assignments and have gotten stuck on this junction object query.  Task: Edit the current getUser() method to do the following:   Return a custom object (that you define in the class) with the current getUser method's query data, and the list of teams the person belongs to (by querying the team assignments). Parent Object 1: User (Standard Object) Parent Object 2: Team (Custom Object) Junction Object: Team Assignments (Custom Object)     **Original Class & getUser Method** global class CTI {     global class CTIException extends Exception {}      global static User getUser() {          return [SELECT Id, Name, ProfileId, Profile.Name, UserRoleId, UserRole.Name, Username                  FROM User WHERE Id = :UserInfo.getUserId() ];     } }   I have tried adding subqueries into my main query, but the verbiage tripping me up is the custom object defined in the class to be returned.


I'm writing a script where the user needs to input a week number and a procedure will be ran based on that. However, I ran into a small issue, I know I can get week numbers via something like this:  >>> a=datetime.datetime.now() >>> a datetime.datetime(2015, 1, 22, 15, 51, 57, 820058) >>> a.isocalendar()[1] 4   But I can't find how to do it backwards. Also, the date I require has to be Sunday of that week at 6:00am. Once I have that datetime element I can just do   begin_date = datetime.datetime.strptime(a, "%Y-%m-%d %H:%M:%S")   To get the format I want. I'm still missing the step to get the date. Any thoughts?

The Python  method returns a tuple (ISO_year, ISO_week_number, ISO_weekday) for the given datetime object.  Is there a corresponding inverse function?  If not, is there an easy way to compute a date given a year, week number and day of the week?


Given $ \sum x_n  < \infty$ , I need to show that this implies $\sum \frac{\sqrt {x_n}}{n} < \infty $ if $x_n \geq 0$  I thought of using Abel's test to test the convergence but that test couldn't be applied here as $ \sum x_n  < \infty \nRightarrow  \sum \sqrt{x_n}  < \infty$  . I am completely stuck at this point. Any hint how to approach?

Consider a convergent sequence $\sum\limits_{n=1}^\infty{a_n}$, with $a_n\ge 0$. Show that the series  $$\sum\limits_{n=1}^{\infty} \frac {\sqrt{{a_n}}}{n}$$ also converges.  Hint: $pq\le \frac 12(p^2+q^2)$


How can I compute the volume of a cone whose side length is $R$ and the vertex of the cone forms an angle $2\theta$?

How can i compute the volume of a cone whose length of its side is $R$ and the vertex of the cone forms an angle $2θ$ .  The top cone is a cap of a sphere of radius $R$.    I tried to solve first in 2 dimension and then use solid of revolution:    Some help please to find the volume of this cone.


I had a program which requires one to search values from -100.00 to +100.00 with incrementation of 0.01 inside a for loop. But the if conditions arent working properly even if code is correct...  As an example I tried printing a small section i.e if(i==1.5){cout<<"yes...";} it was not working even though the code was attaining the value i=1.5, i verified that by printing each of the values too.  #include<iostream> #include<stdio.h>  using namespace std;    int main() {     double i;      for(i=-1.00; i<1.00; i=i+0.01)     {          if(i>-0.04 && i<0.04)          {              cout<<i;              if(i==0.01)                 cout<<"->yes ";              else                 cout<<"->no ";          }     }         return 0; }   Output:  -0.04->no -0.03->no -0.02->no -0.02->no -0.01->no 7.5287e-016->no 0.01->no 0.02->no 0.03->no  Process returned 0 (0x0) execution time : 1.391   (notice that 0.01 is being attained but still it prints 'no') (also notice that 0.04 is being printed even if it wasn't instructed to do so)

Consider the following code:   0.1 + 0.2 == 0.3  ->  false   0.1 + 0.2         ->  0.30000000000000004   Why do these inaccuracies happen?


When I'm reading Matsumura's Commutative Algebra, I find the following statement on the 7th page.  When $M$ is of finite presentation, i.e. when there is an exact sequence of the form $A^m\to A^n\to M\to 0$, we have also  $S^{-1}(Hom_A(M,N))=Hom_{S^{-1}A}(S^{-1}M,S^{-1}N)$.  I think it for hours, but still don't understand why we need the assumption that $M$ need to be of finite presentation. What will happen if we only assume $M$ is finitely generated? (I think it's enough when $M$ is f.g.)

Question. Let $R$ be a ring, $\mathfrak{p}$ a prime, $M$ a finitely-generated $R$-module, and $N$ any $R$-module. Is the natural map $$\textrm{Hom}_R(M, N)_\mathfrak{p} \to \textrm{Hom}_{R_\mathfrak{p}}(M_\mathfrak{p}, N_\mathfrak{p})$$ an isomorphism (of $R_\mathfrak{p}$-modules)?  I can prove this in the case when $M$ is finitely presented: indeed, let $S$ be any flat $R$-algebra, and let $$R^m \to R^n \to M \to 0$$ be a right-exact sequence; tensoring with $S$ gives another right-exact sequence $$S^m \to S^n \to M \mathbin{\otimes_R} S \to 0$$ and applying hom functors, we get left-exact sequences $$0 \to \textrm{Hom}_R(M, N) \to N^n \to N^m$$ $$0 \to \textrm{Hom}_S(M \mathbin{\otimes_R} S, N \mathbin{\otimes_R} S) \to (N \mathbin{\otimes_R} S)^n \to (N \mathbin{\otimes_R} S)^m$$ and $S$ is flat, so tensoring the first sequence yields $$0 \to \textrm{Hom}_R(M, N) \mathbin{\otimes_R} S \to (N \mathbin{\otimes_R} S)^n \to (N \mathbin{\otimes_R} S)^m$$ but extending the sequences by $0$ to the left, and putting in vertical maps between the last two, we conclude that $\textrm{Hom}_R(M, N) \mathbin{\otimes_R} S \cong \textrm{Hom}_S(M \mathbin{\otimes_R} S, N \mathbin{\otimes_R} S)$ by the five lemma (modulo checking commutativity of diagrams). This is essentially the proof Eisenbud gives [Commutative Algebra, Prop. 2.10].  The trouble with extending it to a proof for finitely-generated modules is that we have to replace $R^m$ with a potentially arbitrary submodule $K$ of $R^n$, and that may not be free or even finitely-generated without some additional assumptions on $R$. I can't see an abstract nonsense proof of the claim, but I admit I haven't tried a bare-hands proof. However, is the claim even true?


I worked in the UK for the last couple of years on a Tier 2 visa but moved to another country recently. I tried to re-enter the country during the curtailment period unaware that the visa was not valid (although a part of the curtailment letter said I had leave to enter until the curtailment period).I was denied entry and removed from the UK. Can I apply for a long term visa directly or do I need to apply for a 6-month visa first (since this is recommended to see your international travel history)?   Thanks in advance!

If one is refused entry to UK for bringing more tobacco than is allowed, does he have a right to reapply for a visa? Would he be granted another visa? There is no cancelled stamp on the visa used to travel there and the person returned to India on his own ticket.


I recently discovered that MemberwiseCloning a class doesn't seem to clone it's subclasses (classes defined within it). They still seem to be treated as pointers. Is there some way I can clone a whole class with all subclasses?

I want to do something like:  MyObject myObj = GetMyObj(); // Create and fill a new object MyObject newObj = myObj.Clone();   And then make changes to the new object that are not reflected in the original object.  I don't often need this functionality, so when it's been necessary, I've resorted to creating a new object and then copying each property individually, but it always leaves me with the feeling that there is a better or more elegant way of handling the situation.  How can I clone or deep copy an object so that the cloned object can be modified without any changes being reflected in the original object?


I've read an answer about traveling via a third country in case dual citizenship might not to be OK, and I don't know whether it is technically possible. I'm a citizen of Germany and Saudi Arabia, and I want to travel via UAE. Once I arrive in Saudi Arabia, I'll try to enter with KSA pass but a Saudi official may see from passport that I live in Germany, and in that point is there a risk that he may ask me for German residence permit or stamps or a visa? How can I possibly tackle this situation?

I am a citizen of two different countries, and have two passports.  How should I use my passports when traveling?


I am iterating over a list of objects, and creating a new input component for each iteration.  When I use the cancel button, I would like what I typed in the input to revert back to a default value.  While everything looks ok in my JS file, the UI is not refreshing the input, and instead keeps displaying whatever I typed.  Is it possible for my cancel button to revert the values in the lightning-inputs?  html:  <template>     <template for:each={inputs} for:item="inp">         <lightning-input key={inp.key} type="text" value={inp.value}></lightning-input>     </template>     <lightning-button label="Cancel" onclick={cancel} ></lightning-button> </template>   js:  import { LightningElement, track } from 'lwc'; export default class Iteration extends LightningElement {     @track inputs = [];     connectedCallback(){         var input1 = {};         input1['key'] = 'fname';         input1['value'] = 'firstName';         this.inputs.push(input1);     }      cancel(){                 var input1 = {};         input1.key = 'fname';         input1.value = 'firstName';          //trying to recreate the input list from scratch         this.inputs = [];         this.inputs = [...this.inputs,input1];          //everything looks ok in the javascript output, but the ui doesn't revert the value in the input field         console.log('inputs: ' + JSON.stringify(this.inputs));     } }   starting value:    after typing in something and then hitting cancel:

I have a simple component that creates a record using lightning-record-edit-form. After the record is created, I want to clear the values of the lightning-input-field components. I have tried a few different ways, and none seem to work. The same code applied to a lightning-input does work.   example template  <template>     <lightning-card title="bug sample">         <lightning-record-edit-form id="form" object-api-name="Account" onsubmit={handleSubmit} onsuccess={handleSuccess}>             <lightning-messages></lightning-messages>             <lightning-input-field value={name} field-name="Name"></lightning-input-field>             <lightning-input value={name}></lightning-input>             <lightning-button type="submit" label="Save" class="slds-m-top_medium">             </lightning-button>         </lightning-record-edit-form>     </lightning-card> </template>   example .js  import {     LightningElement,     track } from 'lwc';  export default class ToDoApp extends LightningElement {     @track name;      handleSubmit(event) {         event.preventDefault();         const fields = event.detail.fields;         this.template.querySelector('lightning-record-edit-form').submit(fields);     }      handleSuccess() {         // attempt 1         this.name = '';         // attempt 2         this.template.querySelectorAll('lightning-input-field').forEach(each => {             each.value = '';         });     } }   on success, the lightning-input clears, but the lightning-input-field remains unchanged.   Any ideas?


I have a matrix on which I am performing a zero inflated regression model but it return an error indicating collinearity between some of the variables zinf1 = zeroinfl(count ~ origin + variable + gene, data = count_FGT_free, dist = "negbin") Warning message: In value[[3L]](cond) :   Lapack routine dgesv: system is exactly singular: U[590,590] = 0FALSE  What is the best way to identify which variables are the cause of this?

I have a correlation matrix of security returns whose determinant is zero. (This is a bit surprising since the sample correlation matrix and the corresponding covariance matrix should theoretically be positive definite.)  My hypothesis is that at least one security is linearly dependent on other securities. Is there a function in R that sequentially tests each column a matrix for linear dependence?  For example, one approach would be to build up a correlation matrix one security at a time and calculate the determinant at each step. When the determinant = 0 then stop as you have identified the security who is a linear combination of other securities.  Any other techniques to identify linear dependence in such a matrix are appreciated.


I have an inductor coupled via coupling capacitance $C_c$ to a transmission line (waveguide, feedline?) with impedance $Z_L$. Given that the inductor has some internal losses and a capacitance, I imagine that for all intents and purposes it can be modeled as an RLC circuit. This gives a simple circuit shown below:    Here I have to admit that putting the resistance in series might actually make sense instead, I'm a bit stuck on that mentally; the losses originate from losses in the superconducting that makes up the inductor. However, what I am interested in here is an analytic expression for the external quality factor $Q_E$ of the circuit in terms of $C_c$, $C$, $L$, $Z_L$, and perhaps $R$ but I imagine that only goes into the internal quality factor regardless of how we put it in.  Now, from the definition of the quality factor, we can write that  $$Q_E = \omega \frac{E}{P}$$  where $\omega$ is the frequency, $E$ is the energy stored in the RLC circuit, and P is the power lost in the transmission line, essentially due to the coupling. But I have to admit, at this point I'm already starting to get stuck in relating it to the circuit parameters; my circuit analysis is definitely somewhat rusty beyond $E = 1/2 CV^2$, $E =  1/2 LI^2$ and $P = V^2/R$.   does look at a circuit along these lines, but this is not an identical system. They transform their circuit using Norton equivalences (I have to admit I can't follow this step all that well, not familiar with the equivalence in this context). If one were to take their figure 5c and make some adjustments, perhaps that helps?    Taking the above with $R* = R_L$, $C* = 0$, and replacing $C \rightarrow \frac{C_c C}{C_c + C}$, would that not be identical? In that case the external quality factor is given in the paper to be  \begin{equation} Q_E = \frac{Z_L}{2} \frac{C_c C}{C_c + C}\omega_0 \end{equation} where $\omega_0$ is then the resonant frequency of the circuit taking into account the coupling capacitance. I am not 100% sure this is correct; could someone help me out there?

I know that for parallel RLC circuits, the $Q$ factor is given by:   $$ Q = R \sqrt {\frac{C}{L}} $$  But now suppose it is connected in series to a resistor $R_2$ and capacitor $C_2$. Would the $Q$ factor be changed?


Is it possible to run function in process A from process B? I want to implement wpf application that will run only as one instance, and if another instance is launched - pass process start arguments from new process to a "main" process.

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.


Here is a screenshot of Windows Explorer looked deep into using process explorer.  I am not sure of the why a connection is required to Explorer? My OneDrive has been disabled and nothing's happening in the Explorer too. Can anyone let me know more about why msft is connected here?

This seems a bit odd. Using netstat -a -b -n I've found the following:  TCP 192.168.1.X:1150   157.56.124.76:443 ESTABLISHED [Explorer.EXE]   It turns out that the ip 157.56.124.76 which resolves to db3wns2011017.wns.windows.com is a static ip from .  Moreover, using tcpView from  I can see that it's a TCP connection over https.  I tried closing the connection and after a second it was back on. Initially a kb of data was sent and nothing after that..  What is this all about and why is it Established?  I have windows 8.1 enterprise. I don't have OneDrive or any other microsoft cloud stuff installed. This is persistent, and is there after booting.  update  After finding out that this is related to Windows Push Notifications, I followed the steps  to disable such notifications, but the connection remains.


Intro:  I am working on a batch system. I read that the batch gets fragmented into chunks, each chunk is a subset of an entire query; the chunks will be executed sequentially.  Question:  If one of the chunks fails, is there any way I can rollback all changes done in the chunks?

I am using an APEX batch to process and insert large amounts of data. Essentially I would like it to process every row to catch any errors with the data and then rollback the entire batch if a single error is found. Is there any simple way to do this?  I have tried using a Save Point, but because they are not serialisable, it doesn't work across the entire batch.   Just to clarify, by error I mean an error that I have defined, error with validation, etc. Not an Exception thrown by the system.


Notation   # categories $= c$. # trials $= t$. Side $i$ = $si$. Random vector $= S = \left[S_1\;S_2\;\ldots\;S_c\right]^T$. # occurrences of $si$ vector $= s = \left[s1\;s2\;\ldots\;sc\right]^T$. Probability of occurrence of $si$ vector $= p = \left[p_{s1}\;p_{s2}\;\ldots\;p_{sc}\right]^T$. $p_{s1} + p_{s2} + \cdots + p_{sc} = 1$. $s1 + s2 + \cdots + sc = t$. Pmf of $S = P\left[S = s\right]$.   Games   g1: An ideal 2 sided die is simulated using a standard die by assigning faces w/ dots 1 through 3 & 4 through 6 to $s1$ & $s2$, respectively. The 2 sided die is tossed 7 times & the # times $s1$ & $s2$ occur are recorded. g2: Same concept as in g1, accept faces w/ dots 1 through 3 have micro holes etched into them s.t. $p_{s2} = 18/30$. g3: Same concept as in g1, accept w/ the standard die, i.e., $p_{s1} = p_{s2} = \cdots = p_{s6} = 5/30$. g4: Same concept as in g2, accept w/ the standard die, i.e., $p_{s4} = p_{s5} = p_{s6} = 6/30$. g5: Same concept as in g2, accept the micro holes are filled w/ $0.07$ kg of a material, which evaporates @ $0.01$ kg/s upon being sprayed w/ an activator, s.t. $p_{s2} = 15/30$ for the 1st toss. Immediately after being sprayed, the outcomes of the tosses are measured every second. g6: Same concept as in g5, accept w/ the standard die, i.e., $p_{s4} = p_{s5} = p_{s6} = 5/30$ for the 1st toss.   Questions   q1: Find pmf & evaluate when $s = \left[2\;5\right]^T$. q2: q1. q3: Find pmf & evaluate when $s = \left[0\;2\;1\;1\;0\;3\right]^T$. q4: q3. q5: q1. q6: q3.   Answers   a1: $S$ ~ Binomial distribution.   $P\left[S = s\right] = t!\prod_{k = 1}^c \frac{p_{sk}^{sk}}{sk!} = 7!\prod_{k = 1}^2 \frac{(15/30)^{sk}}{sk!} = \frac{7!(15/30)^2(15/30)^5}{2!5!}$ $\Longrightarrow P\left[S = s\right] = 21/128$.  a2: $S$ ~ Binomial distribution.   $P\left[S = s\right] = t!\prod_{k = 1}^c \frac{p_{sk}^{sk}}{sk!} = 7!\prod_{k = 1}^2 \frac{p_{sk}^{sk}}{sk!} = \frac{7!(12/30)^2(18/30)^5}{2!5!}$ $\Longrightarrow P\left[S = s\right] = 20412/78125$.  a3: $S$ ~ Multinomial distribution.   $P\left[S = s\right] = t!\prod_{k = 1}^c \frac{p_{sk}^{sk}}{sk!} = 7!\prod_{k = 1}^6 \frac{(5/30)^{sk}}{sk!} = \frac{7!(5/30)^2(5/30)(5/30)(5/30)^3}{0!2!1!1!0!3!}$ $\Longrightarrow P\left[S = s\right] = 35/23328$.  a4: $S$ ~ Multinomial distribution.   $P\left[S = s\right] = t!\prod_{k = 1}^c \frac{p_{sk}^{sk}}{sk!} = 7!\prod_{k = 1}^6 \frac{p_{sk}^{sk}}{sk!} =  \frac{7!(4/30)^2(4/30)(6/30)(6/30)^3}{0!2!1!1!0!3!}$ $\Longrightarrow P\left[S = s\right] = 224/140625$.  a5: $S$ ~ Poisson's binomial distribution.   $P\left[\left[S_1\;S_2\right]^T = \left[s1\;s2\right]^T\right] = P\left[S_1 = s1, S_2 = s2\right] = P\left[S_1 = s1\right] = P\left[S_2 = s2\right]$. $p_{s1}$ & $p_{s2}$ are vectors now: $p_{s1} = \left[p_{s1_1}\;p_{s1_2}\;\ldots\;p_{s1_t}\right]^T, p_{s2} = \left[p_{s2_1}\;p_{s2_2}\;\ldots\;p_{s2_t}\right]^T$. $P\left[S = s\right] = \frac{1}{t + 1}\sum_{i = 0}^t \left\{\exp\left(\frac{-j2\pi i s}{t + 1}\right) \prod_{k = 1}^t \left\{p_{s2_k}\left(\exp\left(\frac{j2\pi i}{t + 1}\right) - 1\right) + 1\right\}\right\}$ $= \frac{1}{8}\sum_{i = 0}^7 \left\{\exp\left(\frac{-j5\pi i}{4}\right) \prod_{k = 1}^7 \left\{\left(\frac{0.5k + 14.5}{30}\right)\left(\exp\left(\frac{j\pi i}{4}\right) - 1\right) + 1\right\}\right\}$ $\Longrightarrow P\left[S_2 = 5\right] = 53529/250000$.  a6: $S$ ~ Poisson's multinomial distribution.   I understand this enough to write a q about it, but not enough to solve it.  was the only 1 on SE that was relatable but the answer was incorrect. PLEASE help me find the exact solution; not an approximation.

If in a binomial distribution, the Bernoulli trials are independent and have different success probabilities, then it is called . Such a question has been previously answered  and .  How can I do a similar analysis in the case of a multinomial distribution? For instance, if a $k$-sided die is thrown $n$ times and the probabilities of each side showing up changes every time instead of being fixed (as in the case of regular multinomial distribution), how can I calculate the probability mass function of such a distribution? We assume that we have access to $\{\mathbb{p_i}\}_1^n$ where $\mathbb{p_i}$ is a vector of length $k$ denoted the probability of each of the $k$ sides showing up in the $i^{th}$ trial.  Note: I have asked this question on stats.stackexchange as well, but I feel it is more pertinent here.


I want to install Ubuntu on my Windows 10 machine. Last time I installed Ubuntu my PC was dead. Both Bootloaders were corrupted. What do I have to choose in the „Select Bootloader“ field? What do I have to do, if Ubuntu does not realize Windows. I saw some videos about dual boot, sometimes it shows: „Install with Windows“. Can I install Ubuntu on the same drive with Windows 10? I have two drives, do you recommend one for Win and one for Linux or is there no problem with two OSs on one drive?

I'm absolutely new to Linux. I would like to know how to install Ubuntu alongside the pre-installed Windows 8+ OS.  Should I do it with Wubi, or through the Live USB/DVD?  What steps do I need to take to correctly install Ubuntu?


Let $G$ be a finite group, and let $H$ be a subgroup of $G$ such that the index $(G\colon H)$ of $H$ in $G$ is the smallest prime that divides the order of $G$. Can we say anything about whether or not $H$ is normal in $G$?   The answer is of course yes if $G$ is abelian.

Generalizing the case $p=2$ we would like to know if the statement below is true.  Let $p$ the smallest prime dividing the order of $G$. If $H$ is a subgroup of $G$ with index $p$ then $H$ is normal.


I take the definition of the Fourier transform of $f \in L^2 (\mathbb{R}^3)$ to be   $$ \widehat{f} (k) = \int\limits_{\mathbb{R}^3} e^{-2 \pi i k \cdot x} f(x) dx $$  Question: Can we say anything useful about $\widehat{|f|}$ in terms of $\widehat{f}$?

It is possible to find the following Fourier transform? $ \widehat{\vert f\vert}(\xi)$, provided $ f $ has Fourier transform. I have not found any information about this statement.


I've cloned my repository via git clone, and now I want to checkout a folder.  Source folder: /opt/XYZ/foldertochecout  and it should be checked out to  /var/www/foldertochecout    Is that possible and how?

I have my Git repository which, at the root, has two sub directories:  /finisht /static   When this was in , /finisht was checked out in one place, while /static was checked out elsewhere, like so:  svn co svn+ssh://admin@domain.com/home/admin/repos/finisht/static static   Is there a way to do this with Git?


What is the quotient space $S^{2}\times S^{2}\times S^{2}/\sim$ topologically amd geometrically, where $S^{2}\subset\mathbb{R}^{3}$ is the unit sphere of $\mathbb{R}^{3}$ and the equivalence relation is defined as $$\left(p_{1},p_{2},p_{3}\right)\sim\left(p'_{1},p'_{2},p'_{3}\right)$$ iff there exists $T\in SO(3)$ (special linear group) such that $$T\left(p_{1},p_{2},p_{3}\right)=\left(p'_{1},p'_{2},p'_{3}\right)?$$ Thanks.

What is the quotient space $S^{2}\times S^{2}\times S^{2}/\sim$ topologically, geometrically, and algebraically, where $S^{2}\subset\mathbb{R}^{3}$ is the unit sphere of $\mathbb{R}^{3}$ and the equivalence relation is defined as $$\left(p_{1},p_{2},p_{3}\right)\sim\left(p'_{1},p'_{2},p'_{3}\right)$$ iff there exists $T\in O(3)$ such that $$T\left(p_{1},p_{2},p_{3}\right)=\left(p'_{1},p'_{2},p'_{3}\right)?$$ Thanks.


I'm now reading the source code of LaTeX.  In the definition of verbatim environment (\@verbatim, exactly), there is something like  \everypar \expandafter{\the\everypar \unpenalty}   What does this \expandafter do?  I only know that \expandafter can delay expansion like  \expandafter\def\csname test-cmd\endcsname   But what will happen if the token after \expandafter is a }?

Several times, the  package uses \newtoks which (according to  website) means that a token register is allocated. An example code snippet is  \@ifdefinable\FR@everyfloat{\newtoks\FR@everyfloat} \FR@everyfloat={\let\@footnotetext\@mpfootnotetext   \def\@mpfn{mpfootnote}\def\thempfn{\thempfootnote}\c@mpfootnote\z@   \floatobjectset\floatfont}   Suppose I want to add something (e.g., \setlength{\footnotesep}{0.2\baselineskip}) to the definition of \FR@everyfloat. One way I successfully applied in  answer is to overwrite the original definition, i.e., write  \FR@everyfloat={\let\@footnotetext\@mpfootnotetext   \def\@mpfn{mpfootnote}\def\thempfn{\thempfootnote}\c@mpfootnote\z@   \floatobjectset\floatfont   \setlength{\footnotesep}{0.2\baselineskip}}   However, I'd like to avoid duplicating the whole token list content; instead, I want to append material to the list the same way one would use \g@addto@macro (or \appto from the  package). However, my naïve approach to write  \g@addto@macro{\FR@everyfloat}{\setlength{\footnotesep}{0.2\baselineskip}}   doesn't work -- obviously, token lists must be treated different from macros.  So: How does one append material to a token list?


Using 2.82a.  I made some accidental area subdivisions and I wanted to join them.  But now, right-clicking on the area line, I just see "Swap Areas".  What's wrong?

I can't find a way to close a view panel, in particular the horizontal at the bottom, is pretty useless to me at this moment.


I have noticed a very odd behaviour in Unity 5.2.1. When I drag and drop a Sprite into the Scene, it's cut in half like this:    I tried with PNG and PSD formats but it didn't help. Although when I flipped an image horizontaly in PS and then imported it, it worked. Is this a Unity bug?  Edit: It happens only when I set Max Size to 512 or more, but still - why?

While making a game in unity, we found a graphical glitch that only happens on one of our mobile devices (a htc) where the screen will be oddly sliced by a triangle as shown in this image;    I've searched online but found no problem. We're using unity 2D, it only does it on the HTC but we have no idea why.  The background is a 3D quad with a texture wrapped around it (so we can make it move with the character when the character is running, without having one large background).  Any help would be greatly appreciated.  Thanks


Let $k$ be a field. I want to show that $k[x,y]\ncong k[u,v,w]/(uw-v^2)$ as $k$-algebras, but can't find a way to do it.    The dimension of the $k$-vector space generated by the degree 1 monomials are different on both sides, but then it's possible that an isomorphism doesn't preserve the graded parts, right?  Any help will be appreciated.

I am trying to show that $k[x,y,z]/(xz-y^2)\not\cong k[x,y]$.    The latter is a UFD, so I am trying to show the former is not. Clearly $x$ is not prime, since $x\mid xz$ which implies $x\mid y^2$, but $x\mid y$.      So if I can show that $x$ is irreducible then $k[x,y,z]/(xz-y^2)$ is a not a UFD, because irreducible implies prime in UFDs.    Attempt: Assume $x$ is reduced into $ab$ in $k[x,y,z]/(xz-y^2)$, then we know there exists $c\in k[x,y,z]$ such that $x=ab+c(xz-y^2)$ in $k[x,y,z]$, or more usefully as $x-ab=(xz-y^2)c$. Someone suggested that I write $a,b$ such they are degree at most 1 in $y$, that is, replace every $y^n$ using $xz$. This means the LHS is degree at most 2 in $y$ and the RHS is degree at least two in $y$ in  $x-ab=(xz-y^2)c$. I am not sure where to go from here just by knowing that $c$ has no $y$ terms though. Ultimately I want to show that this forces $x=ab$ in $k[x,y,z]$ which, since $x$ is irreducible there, shows that either $a,b$ is a unit, which means $x$ is irreducible in $k[x,y,z]/(xz-y^2)$.


Is time affected by the gravitational force?  If so, what might be the effect on time at the centre or near centre of earth ?

I would like to know what happens with time dilation (relative to surface) at earth's center .  There is a way to calculate it?  Is time going faster at center of earth?   I've made other questions about this matter and the answers refers to:  $\Delta\Phi$ (difference in Newtonian gravitational potential between the locations) as directly related, but I think those equation can't be applied to this because were derived for the vecinity of a mass but not inside it.  Any clues? Thanks


$n \in \mathbb{N}$  Prove that if  $3\mid n^2 $ then $3\mid n $   I want to prove this in a accepted formal way, I thought about the fact that every integer can be written as multiplication of prime numbers. and if we raise this integer to the power two we will get multiples of each prime. $3\mid n^2 $, it means that this $"3"$ must have been in $"n"$ before raising it to the power. I am going to the right direction? and if yes, can someone hint how can I write it formally?

$n\in \Bbb N$ Prove that if $n^2$ is divided by 3, then also n can also be divided by 3.  I started solving this by induction, but I'm not sure that I'm going in the right direction, any suggestions?


I am looking to drive with a friend to Toronto this coming weekend for a basketball game.  My U.S. passport is expired but I have a valid Drivers License and Birth Certificate.   Will I be able to get into Canada with what I have, and will I be able to get back into the U.S.?

My US passport took too long to be shipped to me, and it will arrive after I need to leave. Will I be able to cross the border from the United States to Canada with a birth certificate (copy) and a passport locator number?


I'm reading Kim and there are many lines like "Canst thou?".   Seems this is a conjugation of verbs on the 2nd person pronoun.   Nowadays seems English only has conjugation on the 3rd person pronoun. Was there conjugation on other person pronouns? and when did such conjugation go away?

What happened to them, and how were they once used? Straining my mind to sound archaic, I came up with the following:     Dost thou thinkest thou can escape thy sins?   and     Bringeth me mine armor and favorite sword.   I’d like to use these suffixes intelligently, so my questions are: how are ‑est and ‑eth properly appellated in conjugations, and  when and why did they disappear?


What is the name of the rhetorical device where someone mentions a subject by stating that he or she will not mention it, as in "not to mention the fact that you have not paid me."

"I don't mean to change the subject, but..." but you are changing the   subject.      "I don't mean to interrupt, but..." but you are interrupting.   Is there a name for these type of "polite" phrases?


I started using Ubuntu on windows 10 and I've noticed that the default path /home/<user_created_during_installation> is located in   C:\Users\User\AppData\Local\Packages\CanonicalGroupLimited.Ubuntu18.04onWindows_79rhkp1fndgsc\LocalState\rootfs\home\<user>   My question is, can I change that path (and if so, how?) or do I have to work on that path while I use Ubuntu on Windows?  Thanks in advance

I am a super newbie for Ubuntu and basically need Ubuntu for a Python package.  I would like to run a Python file in say e:/username/folder1/folder2/python.py. I tried every method online and the only reply is bash: cd./e: No such file or directory. I am not sure whether it is because of the bash windows or virtualenv.  When I use bash on Ubuntu on Windows, ls, it says VIRTUALENV_DIR. cd, it says /home/username. The cd .. etc changes the directory a little, but not another drive, nor the folder I would like it to find.


If I haven't got /etc/init.d/postgresql file in what package could I find it?

Simple enough question: is there some shell command (or GUI method) I can use that, given the path to a file on my system, tells me what package put it there? Assuming the file did in fact come from a package, that is.  Bonus question: what if it's a file that isn't installed on my system? Is there, say, a website that will let me look up a file and see what packages, if any, provide it?


A fresh install of Drupal results in a WSOD including a very helpful error message which says "The website encountered an unexpected error. Please try again later."  I normally install Drupal with the drupal-project template from github and at first, I thought this was a problem with my local DDEV environment. I then tried with MAMP Pro to find exactly the same.   Finally I tried on simplytest.me to realise that it isn't me.  A look at my local error logs reports the following;  "NOTICE: PHP message: Uncaught PHP Exception Twig\Error\SyntaxError:  An exception has been thrown during the compilation of a template  ("Attribute "name" does not exist for Node  Twig\Node\CheckToStringNode) in  core/themes/bartik/templates/block--system-menu-block.html.twig"." at  /var/www/html/public_html/vendor/twig/twig/src/Environment.php line  797"   I found that is was possible to access the site via the admin path, and changing the theme to Stark allowed me to view the site.   I then attempted to view recent system messages at admin/reports/dblog - only to once again to get the "Please try again later" message.

Up until Saturday I had a functioning Drupal 8.6.x instance. The I did  composer update   and Drupal 8.6.10 was installed. Since then I get the following in my error logs:     Declaration of Drupal\Core\Template\TwigTransTokenParser::parse(Twig_Token $token) must be compatible with Twig\TokenParser\TokenParserInterface::parse(Twig\Token $token)   and Drush fails with     Robo\Robo::configureContainer() must be an instance of Robo\Config\Config, instance of Drush\Config\DrushConfig given   I use PHP 7.2 on Ubuntu 18.04.  I did a clean reinstall of Drupal 8.6.10 and the same things occur. I've tried to replace 8.6.10 with 8.6.9 and even 8.6.0 but I still get these errors. If it were Java, I would suspect that the interface and the class had been compiled with different versions of the compiler. But I don't know PHP well enough to know where to start. These errors seem to me to be in core: all my code is under modules/xxx.  Any hints?  Steve


I have this code     \arg(z-z_1)=&\theta\\     \arg((x-x_1)+i(y-y_1))=&\theta\\     \frac{y-y_1}{x-x_1}=&\tan\theta \\     (\theta \mbox{ is a fixed angle so } \tan\theta \mbox{ is a constant.)}\\     y-y_1=&\tan\theta(x-x_1)\\ \mbox{( This is the equation of a straight line with gradient }\tan\theta      \mbox{ passing through the point )}(x_1,y_1).) \end{aligned}\)  And what I get is this  I would like that my text is aligned to the left without interfering my alignment

I have a document I am trying to copy to learn TeX. Here is what I have encountered: How can I have the "or" in the equation. This is what I have right now:  \[ f = ma; \]  But $a$ is the change in velocity,  \[ f = m \frac{dv}{dt};\] \[ f = m  \frac{d^2y}{dt^2};\]   Edit: Trying out Stefan's answer


I try to assign bit wise operators into variables. How can i do it?  Eg      String bitOp="";          String rFunction=JOptionPane.showInputDialog(null,"Enter Your round function","Round function",JOptionPane.INFORMATION_MESSAGE);           if(rFunction.toUpperCase()=="AND")              bitOp="&";          if(rFunction.toUpperCase()=="OR")              bitOp="|";          if(rFunction.toUpperCase()=="XOR")              bitOp="^";      int res= x +bitOp+ y; // if the operator is "AND" , this should be x & y.                           //Here NumberFormatException error shows.     System.out.print(res);   But it doesn't work. Anyone please!!!

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?


Does there exist a polynomial over the rational Field $\mathbb Q$ whose Galois group is a non abelian group of order 12? If we consider the cyclotomic polynomial containing the primitive 13th roots of unity, its Galois group turns out to be the cyclic group of order 12. But the question wants me to find a polynomial for which we get a non abelian group of order 12 as its Galois group, if it exists. Is it possible? Please give one example. Thank you for the help.

Can anyone give me an example of a finite Galois extension whose Galois group  is $A_4$?


Three vessels having different shapes but having the same base area and same weight when empty , are filled with mercury to the same level. Neglecting the atmosphere ,       Statement-- On a weighing machine, vessel A would weight the most followed by C and B in that order as A would contain the maximum amount of mercury.  A supposed contradiction The pressure applied by the fluid at the base of the vessel is the same and hence drawing a free body diagram of the bottom surface , the three vessels must weigh the same. **  I am doubtful about which analogy would be correct and why?

For both containers it is true that:  $p_{bottom}=p_{atm}+\rho gh$ and $F_{bottom}=a*p_{bottom} \iff F_{bottom}=a*p_{atm} + a\rho gh$  I do not know how a scale functions, but I guess that the only force it can count is the force by the liquid on the bottom of each container (the only surface that is in touch with the scale is the bottom of the container). Thus, if we measured the mass of these two masses of water (lets assume that the mass of the containers is negligible) it would appear to be the same in each case. Am I right?


Let $Q$ be an open connected and bounded subset of $\mathbb{R}^2$. Is it true that for any two points $x,y\in \partial Q$, there is a path $\gamma \subset \overline{Q}$ which connects $x$ and $y$? I know that $\overline{Q}$ is connected and $Q$ is path-connected, but I still wasn't able to answer my question.

If $U$ is a connected open set in $\mathbb R^n$, is $\bar U$ path-connected? (that is, for any two points $x_1,x_2$ in the closure of $U$, can we find a continuous path connecting them?)


So, I watched Infinity War, and felt like Thanos didn't think things through enough. His plan was to wipe out half of the life in the universe, but would that life not regenerate relatively quickly over the scale of things? Did he plan on snapping his fingers every X amount of years? How could he possibly think this wouldn't turn the entire universe against him? Perhaps it will, and that will be the sequel, but considering he is supposed to be really smart, it seems like a weird solution to the problem. Is Thanos really that short sighted?

So we know from Infinity War that Thanos was collecting all the Infinity Stones to basically solve the problems brought about by overpopulation on many planets.  But does it make any sense? He could've just easily increased the resources or changed the area or taken appropriate measure to handle that situation. As far as I know, collecting all the Infinity Stones gives the user limitless power and control over the universe in the MCU.  Is Thanos just a mass murderer or is there something I'm missing?


What is the difference between:  ./script.sh "$VARIABLE"   and  ./script.sh ${VARIABLE}   Is there any?

I can write  VAR=$VAR1 VAR=${VAR1} VAR="$VAR1" VAR="${VAR1}"   the end result to me all seems about the same. Why should I write one or the other? are any of these not portable/POSIX?


Ever since I was born, I'd lived with an American family. They were missionaries from  Atlanta and they lived with me and my family for over 14 years. So I literally grew up with their kids and they taught me English and my brother and I would teach them Portuguese (I'm Brazilian btw). They went back to Atlanta in 2010 and I sign up for an English school just to get a certificate or a diploma or something to prove that I speak English.    Later on, I got a scholarship to study  high school  in Canada for  6 months, only to find out that everybody, literally everybody, I talked to would presume I was American. Some people would even argue with me.   So anyways, ever since I came back, I've been working as an English teacher, I mostly teach kids and advanced students. But what intrigues me is that I hear a lot of people saying they are fluent or advanced English speakers (some of them are even English teachers) and their accents is just terrible. They sure know a lot of words, grammar and can speak and talk naturally, but they all have accents.  And so one time I wrote on my resume "native speaker" and all of my friends made fun of me. They still do actually. I just don't know if "fluent"  is enough of word to describe my English.

I think this particular phrase creates a lot of concern in English learners. From general conversation to posts here, we see native speaker a common usage when talking about a person who speaks English by birth. So according to this definition, inhabitants of all the countries considered as  should be considered as native speakers. But herein lies my confusion. Would we conclude a random inhabitant of these countries to be a native speaker (as there is a chance of them to be a English speaking person)?    Also, I think Native speaker can also be one whose mother tongue is not English but uses English a lot in day-to-day life. For example, I don't speak English by birth, but as , I have to use English daily for at least 5 hours a day in my normal life. So can I consider myself as native because I use it frequently?  UPDATE 1 - From Googling, I could not find any dictionary sites explaining this phrase. The results only include different forum answers. So I thought of asking the question here and perhaps wise users here can help me out with the actual meaning.  UPDATE 2 - Later I thought it is worth adding that Anglo Indian families (and some purely Indian families too) who are born and raised here in India, speak English from birth and their first language is English and English is their primary means of communication although I cannot admit they fully abide by or understand all English cultural values like a British or an American. So what can I call them? Are they native?


I have a WinForms application with Status strip which shows label on the right. But, when I launch the application and click on some other window to take focus away from it before it has opened, this is what I see in status strip    instead of    I get the correct thing if I wait for the application to open up completely without it losing focus.  Has anybody seen something like this before? Please feel free to ask for any additional information for properties set for form and status strip.  Thanks in advance!

I am trying to right align a control in a . How can I do that?  I don't see a property to set on ToolStripItem controls that specifies their physical alignment on the parent StatusStrip.


This is a curiosity question. Considering same mass black holes. As nothing can come out of either black hole, would the annihilation result into a black hole of energy? Assuming the two black holes do not repel one another - i.e. assuming antimatter does not have opposite gravity.   Could the big bang have been one such collision between black holes of unequal masses where black hole of normal matter was heavier?

Let's say we have one black hole that formed through the collapse of hydrogen gas and another that formed through the collapse of anti-hydrogen gas. What happens when they collide? Do they (1) coalesce into a single black hole or do they (2) "annihilate" into radiation?  One would expect (1) to be the case if the No Hair Theorem were to hold. So I guess what I'm really asking for is a modern understanding of this theorem and its applicability given what we know today.


I recently answered a "humour +offtopic" CW question about annoying habits of colleagues with what I thought was a most amusing (and meant to be light-hearted) reply containing the word --redacted--. It got edited so the "profanity" was removed.  Was I inappropriate? Last time I checked, SO wasn't a my little pony appreciation society. It's hardly like I used the word [EXPLETIVE DELETED], is it?

Can I use salty, -laden language on Stack Exchange sites, like ?       For more information, see  in the .


I know modal over a modal  is not good UX. But I have a modal window and I am going to place a file upload(browse) component to upload a image for user. I am not really sure, will that break any UX by opening up the second dialog (window) to browse a file? Any suggestions, should I do or do not? Appreciate your comments. NOTE: This is not the modal over another modal, it is modal over a system file upload popup.

Using bootstrap modals, I keep running into the issue of having an info modal with content inside of it, but there's a need to have a "confirm your decision" modal/popup on top of the initial modal.   E.g. I have a page with a list of users. You can click on a user to open a modal with user info inside of it. Then there will be maybe a "remove user" button in the modal that requires a "confirm remove user" modal.  Is it ever a good idea to have a modal on top of another modal or am I using modals wrong? Should I use actual pages instead?