Suppose $X_1, X_2,$ and $X_3$ are independent and $N(0, 1)$-distributed. Compute the moment generating function of $Y = X_1X_2 + X_1X_3 + X_2X_3$.   I know that any $X_iX_j$ with $i \not =j $ is a joint normal with variables $(x_i,x_j)$ I also know the formula of the moment generating function of a normal distribution.  Furthermore, I know that if $Y_1,…, Y_n$ are independent $N(0,1)$, that is, $Y = (Y_1,…,Y_n )´$ are $N(0,I)$ by definition, the moment generating  function of Y is given by $$e^{\frac{1}{2}\mathbf t' \mathbf t}$$   I thought about using the pdf's and the definition of a moment generating function but it proved to be a really tedious process jacked of multiple integrations.  Does anyone know how to easily solve this problem with some relatively simple lines? (Especially using the multivariate normal properties and matrices)


The 16.04 Startup Disk Creator no longer has the option to disable saving documents and settings in reserved extra space.  Note the option visible on the right and missing on the left.   From:   Does a Ubuntu 16.04 USB Startup Disk save documents and settings by default?  If so, how do I disable?  If not, how do I enable?

The Startup Disk Creator no longer shows the option to create a persistent drive. How do I get back this setting in the application?


By profession I’m a programmer. I don’t know a lot about how cryptographic algorithms are implemented, or even where I’d start, and I don’t know about cryptanalysis, but as I work in Blockchain technology, I know how to consume cryptographic algorithms. One might say I have a passing interest.  One thing that has piqued my curiosity, as it probably does many novices in cryptography is the Vernam, or One Time Pad cipher; supposedly 100% mathematically impossible to crack and incredibly simple to implement.  The problem seems to be around the keys used. Specifically:   Keys shouldn’t be reused Key sequences shouldn’t be repeated Keys need to be shared somehow    Other encryption algorithms solve (or don’t suffer from) these problems, but, if we can find a suitable, secure way to generate and share unique keys, does the Vernam cipher become useful?  Is there anything else that needs consideration in this respect?

The symmetric cryptosystem one-time pad (OTP) seems to be very beautiful since it is perfectly secret according to Shannon. Many books, however, point out the main drawback: one must create a secret key the same length as the plaintext. For this reason, the concept of perfect secrecy has these days been abandoned, and we prefer other cryptosystems.   Now, for example, suppose I want to encode my text message with the ASCII scheme, and moreover suppose that this plaintext is 10 gigabytes long, therefore (using an OTP) the key must be the same length, 10 gigabytes. I think, however, this is a ''sustainable price'' because I'm sure that the ciphertext can't be attacked.  Practically, I don't understand why having such long keys with an OTP is a big disadvantage if we reach "the dream"-- namely, perfect secrecy. Nowadays the storage of information is very easy, so what is the real problem? I can, for example, share the "long key" in person.


I want to change the colors that appear in the dropdown here:     If I open the Colors window and select another color, nothing changes. The steps outlined for older versions of Keynote don't work.  Thanks!

In Keynote 6, each Theme comes with a color scheme. I cannot figure out where this color scheme is defined, nor how to change it.  How to change the color scheme?    Or this one from a different template:


Let $X_1, X_2, \cdots,X_n$ be independent and identically distributed random variables having an exponential distribution with mean $\frac{1}{\lambda}$.  Let $S_n=X_1+X_2+\cdots+X_n$ and $N = \text{inf}\left\{n \geq \ 1:S_n > 1\right\}$. Then $\operatorname{Var}(N)$ equals   1 $\lambda$ $\lambda^2$ $\infty$   I don't understand the question and only thing I could deduce from the question is that $S_n$ has variance $\frac{n}{\lambda^2}$. Can somebody please explain what the question demands.

Suppose $X_1, X_2, X_3, \ldots, X_n$ be independent and identically distributed random variables having an exponential distribution with mean $\frac{1}{\lambda}$.  If $S_n = X_1 + X_2 + \ldots + X_n$ and $N = \inf\{n \geq 1: S_n > 1\}$, then what would be the value of $\mathrm{Var}(N)$ ?


Let $S_n= X_1+\ldots X_n$ where $X_i$ are independent, with mean $0$ and finite variance (possibly not the same). Let $F_n$ be the natural filtration generated by the $X_i$.  a) Prove that for $c>0$ $(S_n+c)^2$ is a submartingale.  b) Using (a) and Doob's inequality show that for $x>0$  $$ \mathbb{P}\Bigl( \max_{1\leq m\leq n}S_m \geq x \Bigr) \leq \frac{\operatorname{var}(S_n)}{\operatorname{var}(S_n) +x^2}. $$  I have proved (a) (even though I don't see why $c>0$ is needed) butI don't know how to prove (b), especially because I don't see where $var(S_n)$ at the denominator comes from. This looks like Kolmogorov inequality but we don't have the absolute value for $S_n$ so we have a sharper bound.

Define $\overline{X}_{n}:=\max\limits_{1\leq m \leq n} X_{m}$ and let $(X_{n})_{n}$ be a martingale where $X_{0}:=0$ and $EX_{n}^{2}< \infty$  Show that $P(\overline{X}_{n}\geq \lambda) \leq E(X_{n}^{2})/(EX_{n}^{2}+ \lambda^{2})$  As a hint: Consider $(X_{n}+c)^{2}$ and optimize over $c$.  It is clear that $((X_{n}+c)^{2})_{n}$ is a submartingale and when I optimize over $c$, I get:   $X_{n}^{2}+2X_{n}c +c^{2}\Rightarrow 0=2X_{n}+2c=0\Rightarrow -X_{n}=c$  It is also clear I need to use Doob's inequality but I am not sure how to go about this, and how the above optimization helps me.


What options do I have to process a folder of shots that include faces taken at various proportions and positions (e.g., some of full body, some of head and shoulders) and resize and crop them all so that the head to chin ratio is 2/3rd the height of the total photo?  Essentially, I want to turn all the photos into 2 inch wide x 3 inch tall headshots with the heads equally positioned and proportioned (i.e., the top of the head to the chin is 2 inches tall).  I've been doing it manually in several steps, but if there is some or all of the process I can automate I would appreciate suggestions.

I've got 12,000 photos from an event where there's only one person in each photo. I need to crop these photos to apply rule of thirds. The idea of doing all of these individually is daunting and I can't just take 10% off the top of them all since every photo is a little different.  Is there a way for me to automatically crop all of these photos based on the position of the person?


MWE:  \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{csquotes} \MakeAutoQuote{‘}{’} \MakeAutoQuote*{“}{”} \begin{document}   Hylo \end{document}   This code works fine with pdfLaTeX from TL 2017, but causes compilation errors with TL 2018.  ! Package csquotes Error: Invalid argument.  See the csquotes package documentation for explanation. Type  H <return>  for immediate help.  ...                                                l.15 \MakeAutoQuote{‘}{’}  ? h Only single characters with category code 12 or 13 may be allocated as active quotes. Numbers, punctuation marks, and characters which are part of LaTeX's syntax or reserved for a specific purpose are invalid.   How can I fix my csquotes configuration so that my chosen active quote mark characters continue to work? All my documents use these, so simply switching to a character the package now deems acceptable is not a practical option.  csquotes revision history does not list any changes for version 5.2c which would affect the user interface or package behaviour - there is no entry for this update in the list of such changes. So I would assume that what worked with 5.2b should work with 5.2c. Hence, I wonder if something outside the package has changed rather than the bump from b to c itself altering the behaviour.

After the last update of TeXLive 2018 (pretest) I get an error with csquotes' macro MakeAutoQuote:  \setcounter{errorcontextlines}{100} \listfiles \documentclass[fontsize=11pt,paper=a4,pagesize,ngerman]{scrartcl} \usepackage[utf8]{inputenc} \usepackage{babel} \usepackage[T1]{fontenc} \usepackage{csquotes} \MakeAutoQuote{»}{«}  \begin{document} ABC \end{document}   The error:  ! Package csquotes Error: Invalid argument.   My versions:  inputenc.sty    2018/04/06 v1.3b Input encoding file babel.sty    2018/02/14 3.18 The Babel package csquotes.sty    2018/02/11 v5.2c context-sensitive quotations (JAW)   I use pdfLaTeX. What is wrong here?


This question could sound something stange, but normally you can get values by the key, e.g:  >>> mydict = {'a':1,'b':2,'c':3} >>> mydict['a'] 1 >>> mydict['b'] 2 >>> mydict['c'] 3   But I need to do:  >>> mydict[1] 'a' >>> mydict[2] 'b' >>> mydict[3] 'c' # In this case, my dictionary have to work like >>> mydict = {1:'a',2:'b',3:'c'}   In my program my dictionary could be open by the two ways, I mean:  >>> mydict = {'a':1,'b':2,'c':3} # Sometimes I need the value of a letter: >>> mydict['a'] 1 # And somethimes, I need the letter of a value. >>> mydict.REVERSAL[1] a   I can do something like: (I don't know if this work, I don't test it)  >>> mydict = {'a':1,'b':2,'c':3} >>> mydict['a'] 1 # etc... >>> def reversal(z): ...     tmp = {} ...     for x,y in z.items(): ...         tmp[y] = x ...     return tmp >>> mydict = reversal(mydict) >>> mydict[1] a # etc >>> mydict = reversal(mydict) >>> mydict['c'] 3 # etc, etc, etc...   Is there an easy way to do that?  FIRST: I know about chr() and ord(), my code isn't about letters... this is only and example.  SECOND: In my dictionary there won't be two same values, so there won't be any problems with duplicate keys...

Given a dictionary like so:  my_map = {'a': 1, 'b': 2}   How can one invert this map to get:  inv_map = {1: 'a', 2: 'b'}


Thanks for the help.  I forgot my admin account password and want to log in through standard because its the only one I can access.  any suggestions?

I have forgotten the Administrator password of my Windows XP installation and locked out. Is there a way to reset it? I do have physical access to the PC.


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


I run below python code, a and b will point to the same object as I know.  >>> a=10 >>> b=10 >>> a is b True   but when I change the 10 to a bigger number such as 100000, the result is weird.  >>> a=100000 >>> b=100000 >>> a is b False   It seems that python create two 100000 in memory.  Then I try below code:  >>> lst=[10,10] >>> lst[0] is lst[1] True  >>> lst=[100000 ,100000 ] >>> lst[0] is lst[1] True   In list the numbers (10 or 100000) are both in same object.  That's what I confused.  Why when the number is bigger, Python create two object? and why in List, it still use one copy?

Why does the following behave unexpectedly in Python?  >>> a = 256 >>> b = 256 >>> a is b True           # This is an expected result >>> a = 257 >>> b = 257 >>> a is b False          # What happened here? Why is this False? >>> 257 is 257 True           # Yet the literal numbers compare properly   I am using Python 2.5.2. Trying some different versions of Python, it appears that Python 2.3.3 shows the above behaviour between 99 and 100.  Based on the above, I can hypothesize that Python is internally implemented such that "small" integers are stored in a different way than larger integers and the is operator can tell the difference. Why the leaky abstraction? What is a better way of comparing two arbitrary objects to see whether they are the same when I don't know in advance whether they are numbers or not?


Is there a good way to display reviews that people have left on sites like Yelp, City Search, Google, etc on your own website without triggering duplicate content issues?   It's hard to get reviews, so I'd like to make the most out of the ones that I get.

I have a some reviews on my Facebook page and Google Plus page. Can I put those reviews on other 3rd party review page using schema?   Will it be counted as duplicate content by Google? Is it right for SEO?


On GNOME desktop environment, I have added an app to favorites and I can launch the app from that list clicking on the icon of the favorites list.   But when I launch, a similar icon of the app appears side by side. I mean, two icons of the app are showing instead of one. Where should I create a .desktop file so that when I click on the app icon, it launches with no redundant icon?

After upgrading to Ubuntu 14.04 from 12.04 I have duplicate entries in dash.    How can I get rid of them?


I imported a Collada file created on Photoshop (turning a png into 3d plane), then extruded it in Blender. The reason for that is that this is a complex object to create with curves myself so I figured it's a faster approach.  Then I try to cut through some objects with this extrusion using the boolean modifier - difference, but I never seem to get this to work properly. Either getting "Cannot execute boolean operation" or it just won't cut the objects at all.  Tried modifying the boxes with the imported object as target, and the other way around too... I tried to use the knife project by selecting a box and the imported project but I get an error on "no other selected objects for projection" error. I tried removing doubles and fixing the normals. Nothing helped so far...  Here's the Blender file -   What can I fix for that to work? This is my first Blender project btw... Please don't mark as duplicate because I already mentioned that I perofrmed the actions described in other posts and it didn't help.

I'm trying to model an , but it's not going so well when it comes to the magazine of the weapon.   Next to the magazine is a mesh. I want to cut holes in the mag with that mesh. But the magazine just goes invisible or connects with the mesh when trying to execute the Boolean Modifier. I have tested to invert the normals and some other stuff, but it isn't working.


Prove $\lim_{x\to0}  \sqrt {4 − x} = 2$ using $\varepsilon$, $\delta$-definition.   Here's what I got:   Given $\varepsilon > 0$, choose a particular $\delta$.   Then whenever $0 < |x| < \delta$,   $|\sqrt {4 − x} - 2|$ has to equal $\varepsilon$ if we want to prove this limit.   I know that $4-x > 0$. How do I prove and present this question?   Thanks.

Prove $$\lim_{x\to0}\sqrt{4-x}=2$$ using the precise definition of limits. (Epsilon-Delta)  I am not sure how to link $0<\left |x  \right |<\delta$ with $\left |\sqrt{4-x}-2\right |<\epsilon$ .  EDIT (Trying it out now)  I worked till here, then I basically got stuck.


UPDATE  Following four characters need to be escaped when '\' is the escape helper    %[]_     - LIKE     QUESTION  Though I searched a lot, I could not find out a problem exactly matching the following,  in stack overflow.  I have a database column called Log_Description. It has two records.  1) "Sample % value record"  2) "Sample free record"  I am using SQL Command  and setting parameters as shown below  commandText = commandText + “Log_Description LIKE @Log_Description”; command.Parameters.AddwithValue(“@Log_Description”, “%”+obj. LogDescription+”%”);    Suppose the user enters “%” as search param for txtLogDescription textbox, I need to show only first record. But currently it is showing both the records.    What are the possible ways to overcome this? What are the other characters that may cause such issues with the above code?   Note: I cannot prevent user from entering “%” as input  Note: I am using SQL Server as database  EDIT:   Solution I am using now is       private static string CustomFormat(string input)     {         input = input.Replace(@"\", @"\\");         input = input.Replace(@"%", @"\%");         input = input.Replace(@"[", @"\[");         input = input.Replace(@"]", @"\]");         input = input.Replace(@"_", @"\_");         return input;     }   LINQ approach (with performance hit) is below          Collection<Log> resultLogs = null;           if (!String.IsNullOrEmpty(logSearch.LogDescription))         {             resultLogs = new Collection<Log>();             var results = from o in logs where o.LogDescription.Contains(logSearch.LogDescription) select o;             if (results != null)             {                 foreach (var log in results)                 {                     resultLogs.Add((Log) log);                 }             }         }         else         {             resultLogs = logs;         }

How do I escape a string in SQL Server's stored procedure so that it is safe to use in LIKE expression.  Suppose I have an NVARCHAR variable like so:  declare @myString NVARCHAR(100);   And I want to use it in a LIKE expression:  ... WHERE ... LIKE '%' + @myString + '%';   How do I escape the string (more specifically, characters that are meaningful to LIKE pattern matching, e.g. % or ?) in T-SQL, so that it is safe to use in this manner?  For example, given:  @myString = 'aa%bb'   I want:  WHERE ... LIKE '%' + @somehowEscapedMyString + '%'   to match 'aa%bb', 'caa%bbc' but not 'aaxbb' or 'caaxbb'.


Given two matrices, $A,B\in\mathbb{R}^{m\times n}$ where $m>n$, why do the eigenvalues of $A^TB$ equal the nonzero eigenvalues of $AB^T$?  Essentially, why do the eigenvalues of the inner product between matrices equal the nonzero eigenvalues of the outer product between two matrices?

First of all, am I being crazy in thinking that if $\lambda$ is an eigenvalue of $AB$, where $A$ and $B$ are both $N \times N$ matrices (not necessarily invertible), then $\lambda$ is also an eigenvalue of $BA$?  If it's not true, then under what conditions is it true or not true?  If it is true, can anyone point me to a citation?  I couldn't find it in a quick perusal of Horn & Johnson.  I have seen a couple proofs that the characteristic polynomial of $AB$ is equal to the characteristic polynomial of $BA$, but none with any citations.  A trivial proof would be OK, but a citation is better.


I found a pile of these resistors, and I didn't know how to decode them using 4-band logic.  How do you know if it's to be read:  Brown(1), Black(0), Black(0), Black(0), Red(2) = 100Ohm  or:  Red(2), Black(0), Black(0), Black(0), Brown(1) = 200Ohm  Now before you get carried away, I hooked up a multimeter and I know that it is a 200Ohm resistor.  My question is, how would I be able to guarantee it is a 200Ohm resistor and not a 100Ohm resistor, using only the bands?  While looking for a picture to put with this post, it appears "grouping" plays a role on some 5-band resistors, but in this case there appears to be no grouping, but the red band is slightly thicker than the brown band. Is there a standard, or is this some form of tribal knowledge?

few days ago i bought few (about 500) resistors and i noticed that they have 5 color bands instead of 4. My question is how do i count them (which color is the tollerence) and how should i put them? Do they have a good or bad orientation like + or - ? I tried to use an online calculator but i dont know the first and the last band.


Every time I'm working with tables in LaTeX, I'm frustrated, because I can't find a clean way to type them. Suppose my code looks like this:  \begin{tabular}{c c c}   blablabla & blabla & bla blablabla \\   bla & blablablablabla blabla & blabla blablabla \\   blabla blabla blabla & bla & blablablabla bla \\ \end{tabular}   This looks dreadful in my code (imagine that there are even more columns and rows). I find it hard to read and quickly correct certain elements in it, if necessary. I therefore tried working with spaces and/or tabs to make it look like this:  \begin{tabular}{c c c}   blablabla              & blabla                   & bla blablabla     \\   bla                    & blablablablabla blabla   & blabla blablabla  \\   blabla blabla blabla   & bla                      & blablablabla bla  \\ \end{tabular}   However, when I now need to change something, the alignment changes too and after a while, I'm rather typing spaces than doing something useful. The code in my editor (TeXstudio) is also displayed in Verdana (because I find that easier to read), but as it isn't monospaced, it doesn't even look that nicely aligned.  How do you guys manage this? Does it bother you too that the table should be aligned nicely in your code or am I the only freak out here?

Manually hacking tables in LaTeX is one of the less funny things when preparing a document. Naturally, there are quite a few tools that promise to simplify this. In fact, I have somewhat lost track of all the tools available, and I'd like to gather your valuable experience into one big post. Some of the tools are mentioned in , but I feel there's much more around.  I'd suggest that somebody starts an overview with an alphabetic list (so that I can accept this answer and it stays on top), and that everyone replies with a "community wiki" entry, one reply per tool, and inserts the tool into the list.  Personally, I use Excel2LaTeX, but I'm unhappy with having to fire up Windows in order to generate the LaTeX code. I'm thinking of a rewrite as a standalone Python tool using the xlrd library, but I'm not too inclined to reinvent the wheel.


In our lesson we have Be going to  future plans (personal) prediction based on something we can see or hear  Present continuous  future arrangement fixed plan  Is this right? Can someone explain this to me with examples?

How to say that you have plans to go to the movies tonight (but you are not sure yet, maybe you will have a pizza)? I mean there are options:     I am going to the cinema tonight.   Way too much certainty in this. For me it means that you have already bought tickets, the least.     I am going to go to the cinema tonight.   Sounds a bit awkward.     I will go to the cinema tonight.   Sounds too formal to me.


I have  a bounty question on Stack Overflow, but I did not received any bounty and I don't know why.  From  I understand that If I have an answer with 2 upvotes (or more) on it and it is the most voted answer after the grace period ended I will receive the bounty/ half of it.     If you do not award your bounty within 7 days (plus the grace period), the highest voted answer created after the bounty started with a minimum score of 2 will be awarded half the bounty amount.   The grace period has ended and the question bounty was not given to anybody by the question asker.  My question is, my answer:   Was the first answer posted. Is the most voted question.  Has more than 2 upvotes.   This is not "I am upset that I was not given reputation question", but a general question that is relevant to all Stack Exchange sites about bounty questions.

It's possible to offer and award bounties of reputation on questions.   What is a bounty? How can I find questions that have a bounty attached? How do I start a bounty? When can I start a bounty? Why is the system requiring me to choose a bounty amount that's higher than the minimum? Can I use Markdown formatting in the bounty remarks? Can I edit the remark? How long is the bounty period? How do I award a bounty? Can I award a bounty to my own answer? Can I award a bounty to an old answer? If I offer a bounty on someone else's question, can I award the bounty to their answer? After awarding the bounty, can I remove it or move it to another answer at a later time? What happens if there's no answer after the bounty period? What happens if I feel my question is still unanswered? What is automatic awarding? Are bounty awards exempt from the 200 points/day reputation limit? How does Community Wiki mode affect bounties? How does user deletion or post dissociation affect bounties? Can I award a bounty to an answer from a deleted user or one where the author was dissociated? Can I offer a second bounty after the first one has expired? Can I raise my bounty? What happens if a bounty question is closed or deleted? Why can't I vote to close or migrate a bounty question? What happens if I delete my account while I have an active bounty? Do I keep an awarded bounty when I delete my answer? What happens if a question where I awarded a bounty later gets deleted or migrated? Can I cancel my bounty? Can I affect / divide / share part of my bounty to two (or more) users? How many outstanding bounties can a single user have?      See also:  in the Help Center


I am a Young leaner of Mathematics in the university and I found this problem a bit challenging et me.  Please can someone help me integrate   $$\int_{-\infty}^\infty e^{-x^{-2}} dx$$ Thanks.

How to prove  $$\int_{0}^{\infty} \mathrm{e}^{-x^2}\, dx = \frac{\sqrt \pi}{2}$$


I am trying to figure out how water intake during meals effects digestion. Particularly, what volumes of water would inhibit digestion versus benefit digestion. Additionally, if water benefits the digestive process, at what volume would it start to inhibit digestion.  I've read that excessive water intake could possibly inhibit digestion. Looking at the laws of chemistry and pH, it is apparent that acidity is exponential and in order to decrease stomach acidity to the point of inhibiting digestion, it would take huge volumes of water. But that does not take into account the dilution of the enzymes such as Pepsin which are also necessary for digestion. So excessive water intake may not dilute stomach acid, but it's effect on the dilution of stomach enzymes could possibly inhibit the digestion process.

Is it better to drink water during or after a meal?  Clearly, there are different opinions about this topic.   In this , it is mentioned that drinking water immediately after or during a meal should not make much difference, and in fact doing so actually aids digestion in general.  On the other side, this  says exactly the opposite:     Remember not to drink too soon before or after a meal as the water will dilute the digestive juices.  Drink water an hour after the meal to allow the body to absorb the nutrients.   Which approach is better for health?


When I run this code, it prints 0 , 1, 2, but I have no idea why. could you explain me?  public void run() {         int[] arr =  new int [3];         for(int i=0; i<arr.length;i++){             arr[i]=i;         }         domore(arr);         for(int i=0; i<arr.length;i++){             println(arr[i]);         }     }      private void domore(int[] arr) {         // TODO Auto-generated method stub         int [] att = new int [3];         for(int i=0; i<att.length;i++){             att[i]=77;         }         arr=att;     }

I always thought Java uses pass-by-reference. However, I've seen a couple of blog posts (for example, ) that claim that it isn't (the blog post says that Java uses pass-by-value). I don't think I understand the distinction they're making. What is the explanation?


I'm trying to use a method to process a String... But I'm getting   java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String kuros.com.ipsiscontroller.stringFilter.setStringParam(java.lang.String)' on a null object reference         at kuros.com.ipsiscontroller.AddActivity.getParameters(AddActivity.java:147)   stringFilter.class  String setStringParam(String parameter){         /*String finalParam = "";         String fillString = "";              if (parameter.length() < LENGTH_PARAMETERS) {                 int missingChars = LENGTH_PARAMETERS - parameter.length();                 Log.d("STRING_TAG missingChars", String.valueOf(missingChars));                 for (int i = 0; i < missingChars; i++) {                     //fillString = fillString + "x";                     fillString += "x";                 }             }             finalParam = parameter + fillString;             Log.d("STRING_TAG", finalParam);*/          return parameter;     }   As you can see I commented most on the method just to see I get the same String back... but is not working either. This is line 147.  String test = sf.setStringParam("a");

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


I have a number of issues with the concept of editing other peoples' posts, but this is a key concern (one of two, actually).   How can I tell who edited my post and why it was edited? Do others see who has made edits? What happens if I reverse those edits? Is there an automatic way to do that or do I have to manually re-edit?

I'd like to be more aware of when other SOpedians edit my own questions and answers, which is sure to happen because my innate spelling and grammar skills are  overloaded by my vocabulary and lackadaisical proofreading habits.  That said, I would like to review edits to my posts to ensure the basic content has not changed.    What do folks think of this?  EDIT:  So, apparently there is the revisions tab, which I had not seen.  But revisions are not in the summary page, which I'd like to see.


Assume you have a list :  mylist=[[1,2,3,4],[2,3,4,5],[3,4,5,6]]   any pythonic(2.x) way to unpack the inner lists so that new list should look like ?:  mylist_n=[1,2,3,4,2,3,4,5,3,4,5,6]

Is there a simple way to flatten a list of iterables with a list comprehension, or failing that, what would you all consider to be the best way to flatten a shallow list like this, balancing performance and readability?  I tried to flatten such a list with a nested list comprehension, like this:  [image for image in menuitem for menuitem in list_of_menuitems]   But I get in trouble of the NameError variety there, because the name 'menuitem' is not defined.  After googling and looking around on Stack Overflow, I got the desired results with a reduce statement:  reduce(list.__add__, map(lambda x: list(x), list_of_menuitems))   But this method is fairly unreadable because I need that list(x) call there because x is a Django QuerySet object.  Conclusion:   Thanks to everyone who contributed to this question.  Here is a summary of what I learned.  I'm also making this a community wiki in case others want to add to or correct these observations.  My original reduce statement is redundant and is better written this way:  >>> reduce(list.__add__, (list(mi) for mi in list_of_menuitems))   This is the correct syntax for a nested list comprehension (Brilliant summary !):  >>> [image for mi in list_of_menuitems for image in mi]   But neither of these methods are as efficient as using itertools.chain:  >>> from itertools import chain >>> list(chain(*list_of_menuitems))   And as @cdleary notes, it's probably better style to avoid * operator magic by using chain.from_iterable like so:  >>> chain = itertools.chain.from_iterable([[1,2],[3],[5,89],[],[6]]) >>> print(list(chain)) >>> [1, 2, 3, 5, 89, 6]


I want to propagate my custom list programmatically.We can do it with GUI easily but I want to do it programmatically.  Found the option to make it under Variations (screenshot below)

I have defined variations with two Labels (source and target)  I have selected "Publishing Sites and List with variations and all pages" in one of the settings. The pages are created in the target site but the Lists doesn't seem to propagate. Until and unless I go to List and define it under variations from UI.  Found the option to make it under Variations (screenshot below)    How can I do this programmatically when a new List is created, it should by default be under Variations..?   Is there a configuration way?


Given $X_{nxp}$ of rank p, we know that $(X'X)^{-1}$ exists because $X'X$ also has rank $p$. But how do you prove that $X'X$ has rank $p$ (it is rank-preserving of $X$)? What properties can you use to prove this?  Clarification: $X'$ is the transpose of $X$, and the values of $X$ are real.

Prove, for real $X$, that $\text{rank}(X^TX)=\text{rank}(X)$.  Could anyone please help me with this problem? I've tried to use full-rank factorization and rank-related theorems mentioned in my book but still failed to solve this. I am learning linear algebra by myself and my book has no solutions manual so I find it really hard to get used to solve linear algebra problems.    Many thanks in advance for your help!


Sorry if it's a trivial question, but when someone uses what's up as a greeting I have no idea what they want to hear. What are the possible answers and what does this question mean exactly?


I know that booster packs are given out to users who have got all possible card drops from a certain game, as stated in the . However, with Free-to-Play games such as Team Fortress 2 and Dota 2 you have to spend money on in-game items to get cards as there are no free card drops.  As a player who haven't paid enough to get a card from either game, I have no possible card drops. However, I'm not eligible for a booster pack either. What is required to get booster packs from F2P games? There does exist both TF2 and Dota 2 booster packs, as they are being sold at the Steam Market.

So today I woke up and noticed new item in inventory which was a booster pack containing 3 cards from L4D 2. From what I see on market these booster packs are new (graph only shows up to 19 of June). No matter the game it seems to always contain 3 cards. There are two actions I can do with it: unpack or sell. There is fancy animation when you unpack the booster ;)    I'm not exactly sure why I got it, I have few guesses:   I got new badge, power player - this could give me a booster? Because of new badge I reached level 10 - maybe every couple levels there are gifts? It just dropped randomly for everyone?   Maybe together we could rule out above guesses. It's also interesting from the point of market, to estimate how many boosters are there. With some games they seem to be more valuable than 3 cards separately, but that maybe only initial confusion.


As courtesy we host our clients' website files. Each client has their own Linux account, and website files are served from /home/user/public_html.  All of the clients files have ownerships of user:user. Permissions for the accounts are 755, and this allows them to upload and manage files via SSH, and Apache can serve files, too since it has read access via the "everyone else" permissions. With this setup, users are free from worry that other users can modify their files.  The problem comes in with a Wordpress, Drupal, or other CMS where the software is responsible for self updates and file management is done through the website's interface (Wordpress' Media Library, for example.)  To do this a user or group has to have write access. Many solutions on the net advise the following ownership and permissions setup on web files and directories that need to be routinely updated / modified:  ownership: user:www-data permissions: 775 user becomes a member of the www-data group  With this setup, two undesirable things happen. The first is that, because they are of the same group, users can now access other user's accounts and, accidentally or not, modify delete or upload files, which is a bit security risk, especially if a user uploads a plugin or module with malicious code.  The second is that after uploading an image through the interface, for example, that file is now owned by www-data:www-data and the user can no longer manage these files via ssh / ftp.  Is there a way to force www-data to respect the ownership of the files so that user is always the user? What's the proper way to set up Apache in a multi user environment where Apache needs write access but I avoid these permission and security issues?

I want to stop having to use sudo everytime I work in /var/www. How can I do that? I simply want to put all of my sites into this directory and work with them without too much pain.


I'm looking to buy thinner tires for my gravel bike my bike has Weinmann U28 TL rims and right now has 700*40mm tires do I need to buy new rims to put 30mm tires in. On Weinmann's website, they say the  U28 TL doesn't come in a 700c variant so I can't find it there. The bike is a 2020 Khs grit 220 if that helps at all

We often get questions on bicycles.stackexchange about fitting wider or narrower tires to bicycles. We have a large number of these with answers suiting the specific bike or style of bicycle in question, but I have been unable to find one that provides a generic answer covering off all things that need to be considered. For most bicycles, the answer is the same regardless of the specific style and sizes of tires in question.   This is intended as a canonical question that we can point closed questions to.


I recently made the decision to pursue graduate studies and apply for an MS in computer science program during next year's application process. More specifically, the field that I want to study is machine learning. However, there is something that's been concerning me a lot for the past few days.  I'm actually taking a machine learning course this semester, and I don't believe I did too well. I think I'll end up with either a C+ or at best a B or - if the professor feels very generous - a B+. If I were to give an excuse for the result, I'm not too familiar with many of the tools we used in class (Python, Sci-kit Learn, etc.) and the professor, TA's, and fellow students all gave me the same answer of "it's your job to learn on your own" when I would ask questions (which is true to an extent). It was a disheartening semester, to say the least. But excuses aren't important, and the result is that I didn't perform well.  Now the actual question is: Would this affect my graduate studies application? My GRE scores are satisfactory (163V/169Q/5.5AW) and my TOEFL scores are also good (118/120). Upon graduation I will have around a 3.2-3.4/4.0 GPA.  I've heard stories of professors rejecting applicants because they performed poorly for relevant courses despite showing positive traits in other ways, and I guess that's been concerning me.

When applying to a PhD program in the US, how does the admissions process work? If an applicant is weak in a particular area, is it possible to offset that by being strong in a different area?  Note that this question originated from this . Please feel free to edit the question to improve it.


I have a raster with a black collar (background). I want to set those black pixels to transparent. The problem is that the values of the pixels have three bands (Red, Green and Blue) and I don't know how to define a rule in the .SLD to set those pixels which value is (0, 0, 0) to transparent.    Any idea on how to do this?   My question has been associated with another question. The answer to the other question resolves the problem for a single-band raster but in my case I have a multi-band raster, so the answer I need is different.

How to set the background color to transparent. I want use style which describe in *.sld file for all my photo with tif format. How to do that?


Im looking for help to reapply textures and maps to models from r6 siege game  in Cycles Render. I downloaded his imported models from his Devian (link below) and i imported .obj file , but i have no idea how to reapply specular,normal and detailed normal maps. Only what i've got is diffuse texture but no clue how to reapply other textures :  Here's the link to the character im trying to use:   I hope someone can help me with this , because node setting is a painful and hard thing in blender :(  (ps): if someone had time to make whole node tree for this model i would be so glad for it , cause i want to use other models too :)

I created some texture maps in MindTex to use in Blender, but I can't figure out how to properly hook them up. The maps I have:  - Diffuse  - Normal  - Height   - Specular   - Gloss   - Self Illumination  - Reflection  - Ambient Occlusion   MindTex (left) vs. Blender (right)  As you can clearly see it's a pretty big difference.  is my material node setup in Blender. In the examples I don't actually use self illumination or reflection images, but including this in the answer would be helpful.


This sentence is to say anomaly number 1 and number 2 have higher soil iodine concentration than other anomalous areas.  Should it be plural or singular? i.e. 'appear' or 'appears'?  Thanks!

Can anyone tell me if I should use inspire or inspires in this phrase?     An extraordinary leader whose vision, values, integrity and boundless curiosity inspires all who follow in his footsteps.


Is a Whole Number part of A Rational Number or a whole number??

In a college class I was asked this question on a quiz in regards to sets:     All integers are fractions. T/F.   I answered False because if an integer is written in fraction notation it is then classified as a rational number. The teacher said the answer was True and gave me the link . As a teacher of mathematics in the K-12 system I have always taught that integers were all whole numbers above and below zero, and including zero. All of the resources I have used agree to my definition. Please clarify this for me.  What is the truth, or are she and I just mincing words?


Our remote control works on infrared ray. What I had done is placing the diode towards the mouth of the camera and pressed the remote control. I saw a purple light blinked less than one second.   Some questions regarding this phenomena are:   How could a camera sense the existence of infrared ray? Why does it appear to be in purple and not other color?

I've always seen that all the old model remotes that is used in DVD players or TVs, it emits electromagnetic waves, having wavelength somewhere in the Infrared region. But when my phone's average quality camera (Moto E) is held between the emitter and my eyes, it converts the infrared into visible ones and shows a whitish purple colour. I don't know why always the purple is shown. I'll be very happy if you explain this to me.  Thank you.


$f$ is a differentiable function on real line such that $$\lim_{x \to \infty}f(x)=1$$ and $$\lim_{x \to \infty}f'(x)=\alpha$$. Then what can be said about $\alpha$  $\alpha=0$ $\alpha$ may not be $0$ but $|\alpha| \le1$ $\alpha\geq1$ $\alpha\leq-1$   I cannot think of any viable option other than 1,but i cannot prove it. Any hint or solution would be appreciated!

I've been trying to solve the following problem:  Suppose that $f$ and $f'$ are continuous functions on $\mathbb{R}$, and that $\displaystyle\lim_{x\to\infty}f(x)$ and $\displaystyle\lim_{x\to\infty}f'(x)$ exist. Show that $\displaystyle\lim_{x\to\infty}f'(x) = 0$.  I'm not entirely sure what to do. Since there's not a lot of information given, I guess there isn't very much one can do. I tried using the definition of the derivative and showing that it went to $0$ as $x$ went to $\infty$ but that didn't really work out. Now I'm thinking I should assume $\displaystyle\lim_{x\to\infty}f'(x) = L \neq 0$ and try to get a contradiction, but I'm not sure where the contradiction would come from.   Could somebody point me in the right direction (e.g. a certain theorem or property I have to use?) Thanks


Is there some special rule regarding articles  for words starting with two consonants? I was taught to use a when a word starts with consonant (or an otherwise). I just wrote "a mPOS device" but MS Word proposes to use "an". I can hear "emPOs". Is this a special rule or the Word spell checker bug? Thanks

I was reading a comic book and I noticed that the author used "an A" and "an N" in a particular phrase (screenshot below). While I understand the usage of "An A" here (A being a vowel and what not) and "N" having a pronunciation which has a sound similar to "A".  Since most of English alphabets have pronunciations which start with a syllable similar to one of the vowels or semi-vowels; is it OK to prefix the letters using "An"?  For eg. An X, or An Y.        Zenescope's Grimm Fairy Tales - Werewolves: The Hunger, page #8 (Click to enlarge)


when I output the following code (taken from dr. Liang Introduction to Java, 10th ed., chapter 03 - selections)   /* (Current time) Listing 2.7, ShowCurrentTime.java, gives a program that displays the current time in GMT. Revise the program so that it prompts the user to enter the time zone offset to GMT and displays the time in the specified time zone. */   import java.util.Scanner;  public class Ex_03_08 {     public static void main(String[] args) {         Scanner input = new Scanner(System.in);           System.out.print("Enter the time zone (GMT): ");         int gmt = input.nextInt();           long totalMilliseconds = System.currentTimeMillis();           long totalSeconds = totalMilliseconds / 1000;           long currentSecond = totalSeconds % 60;           long totalMinutes = totalSeconds / 60;           long currentMinute = totalMinutes % 60;           long totalHours = totalMinutes / 60;           long currentHour = totalHours % 24;         currentHour = currentHour + gmt;           System.out.println("The current time is " + currentHour + ":"                 + currentMinute + ":" + currentSecond);          input.close();     } }   the output is   Enter the time zone (GMT): 1 The current time is 11:2:31   How can I let display instead 11:02:31?  Thank you.

How do you left pad an int with zeros when converting to a String in java?  I'm basically looking to pad out integers up to 9999 with leading zeros (e.g. 1 = 0001).


I'm trying to keep a 3d plane facing the camera at all angles but while i have some success with this:  Vector3 gunToCam = cam.cameraPosition - getWorld.Translation; Vector3 beamRight = Vector3.Cross(torpDirection, gunToCam); beamRight.Normalize(); Vector3 beamUp = Vector3.Cross(beamRight, torpDirection); shipeffect.beamWorld = Matrix.Identity; shipeffect.beamWorld.Forward = (torpDirection) * 1f; shipeffect.beamWorld.Right = beamRight; shipeffect.beamWorld.Up = beamUp; shipeffect.beamWorld.Translation = shipeffect.beamPosition;   *Note: Logic not wrote by me i just found this rather useful  It seems to only face the camera at certain angles. For example if i place the camera behind the plane you can see it that only Roll's around the axis like this:   (imagine if you are looking from behind where you have fired from.  Any idea what to what the problem is (angles are not my specialty)  shipeffect is an object that holds this class variables: public Texture2D altBeam; public Model beam; public Matrix beamWorld; public Matrix[] gunTransforms; public Vector3 beamPosition;

I have two objects (target and player), both have Position (Vector3) and Rotation (Quaternion).  I want the target to rotate and be facing right at the player.  The target, when it shoots something should shoot right at the player.    I've seen plenty of examples of slerping to the player, but I don't want incremental rotation, well, I suppose that would be ok as long as I can make the slerp be 100%, and as long as it actually worked.  FYI - Im able to use the position and rotation to do plenty of other things and it all works great except this last piece I cant figure out.  Code samples run in the Target's class, Position = the targets position, Avatar = the player.  EDIT  Im now using Maik's c# code he has provided and it works great!


I want metrics for how much writing and reading have been done to a folder.  vmstat -d gives metrics at the whole disk level. iotop will give per process rw stats.  But how can I find out how much writing has been done to a folder or file?

I've got a few processes with a known name that all write to files in a single directory. I'd like to log the number of disk block reads and writes over a period (not just file access) to test whether a parameter change reduces the amount of I/O significantly. I'm currently using iostat -d -p, but that is limited to the whole partition.


I am trying to use rm -rf !(current) delete all folders in current path except current folder. But I am getting below error     bash: !: event not found   How do I get this functionality in bash?

I routinely use bind mounts to aid in making space available in multiple locations without having to have multiple logical volumes / physical partitions / LUNs, etc.  For example, I may have a 200G LV mounted at /space. From there, I will make subdirectories like var_opt and var_log which I can then bind mount to /var/opt and /var/log, respectively.  When doing a cleanup on the 'space' directory, is it possible to exclude directories from an rm -rf running inside /space?  Example:  # pwd /space # rm -rf * {except-for-var_opt-and-var_log}   Is there a different or better (but similarly simple) way to accomplish what I'm trying to do that I haven't thought of?


I'm trying to learn chain of responsibility pattern in Java, In below code if the successor does not exist, it gives a NullPointerException. I want to check if the successor exists like this   if(this.sucessor exists) {   this.successor.check(Home)  }   How can I do this?   public void next(HomeStatus Home){    this.successor.check(Home); }

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?


There are two parts to this question.   As a student interested in pursuing a doctoral degree; how important is it to publish an article or "something" before one applies? Will it help your chances? I plan on writing a MA thesis but whether it is publishable or not, remains to be seen. What are the main steps to go about publishing?

I've heard from people saying that while applying for PhD, you need to have past experience in researching something and should have international publications. I was like more concentrated towards practical experience and have't had any publications. If I am aspiring to do PhD and want to apply, it would be impossible if such a criteria exists!


I just wanted to know that an Uchiha can marry a Senju / Uzumaki because they are related, not closely but they are formed from indra and ashura who are brothers. And you know there is hatred between these clans. And can their child activate rinnegan and six paths power.

Ok, I'm wondering . If Uchiha and Uzumaki have a child together, there are possibility that the child inherited Sharingan right? Since Uzumaki have ties with Senju then, can the child awaken Rinnegan?


I have an SVG image that consists of thousands of nodes. How can I use Inkscape to automatically reduce the number of nodes while keeping the overall shape?  An example image is , with a small number of high-resolution paths. The whole document consists of tens of thousands of nodes.  This looks great at high resolution, but at lower resolution the overall image can be represented with far fewer nodes.  What can I do in Inkscape to say “Reduce this path to about 10% of the existing nodes, removing only those which are fine-detail deviations from the overall path” without me needing to choose any of those nodes manually? Can Inkscape discriminate based on that criterion?  If not Inkscape, is there another simple tool I can use to specify a reduction in vector resolution by reducing the number of nodes?

I was trying to incorporate a map outline in a logo using trace bitmap feature in inkscape. I was able to trace with some modifications in the setting, but the problem is it has more number of nodes. I am trying to reduce the number of nodes using simplify command, but as soon as I do this I am loosing the curves of the map & even getting variable thickness. Is there any workaround to solve this problem. Also is there any other method to include maps in a logo without tracing?  This is the image what I achieved after tracing.  The same image after using path- simplify.


At the moment in the new StackExchange top-bar, when you type a search term into stackexchange site search and press Enter, the page refreshes or something similar. I think it would be better if you actually went to the first listed site in the search.   For example, if I typed "statistic", this brings up cross validated, and if I press Enter I would like to go to cross validated.    Similarly, and perhaps this should be another suggestion, up and down cursor keys should move the selection to the list of sites, enabling you to for example, press down key twice and then enter to go to the second listed site.  It might also be better to have some specific visual indication that you have you the selection corresponds to the first hit (i.e., like the Facebook search box).  As a side point I realised after a bit that you can tab and enter, which arguably works fine, but it was not the keyboard interaction that I was expecting. So I still think supporting both modes of keyboard interaction might be good.

When searching for the desired SE site, the down arrow key (down) should work in order to choose the site one is looking for and hit enter to visit it, instead of using the mouse point to choose it. Would be pretty convenient.


I noticed that i return duplicate rows in my listview constructed from my arrayList. I would like to check if the elements exist in the arraylist and if so, ignore that set. The unique value to check would be my id, denoted by KEY_SID.  Here's my code:     public ArrayList<SaleModel> loadSalesFromSQLite() {         ArrayList<SaleModel> sales = new ArrayList<>();         hp = new HashMap();         SQLiteDatabase db = this.getReadableDatabase();         Cursor res = db.rawQuery("SELECT  * FROM " + TABLE_SALES + " ORDER BY datetime(created_at) DESC", null);         res.moveToFirst();         while (!res.isAfterLast()) {             SaleModel l_sales = new SaleModel();              l_sales.setId(res.getString(res                     .getColumnIndex(KEY_SID)));             l_sales.setCode(res.getString(res                     .getColumnIndex(KEY_CODE)));             l_sales.setAttendant_id(res.getString(res                     .getColumnIndex(KEY_ATTENDANT_ID)));             l_sales.setAttendant_name(res.getString(res                     .getColumnIndex(KEY_ATTENDANT_NAME)));             l_sales.setProduct_id(res.getString(res                     .getColumnIndex(KEY_PRODUCT_ID)));             l_sales.setPrice(res.getString(res                     .getColumnIndex(KEY_PRICE)));             l_sales.setCustomer_id(res.getString(res                     .getColumnIndex(KEY_CUSTOMER_ID)));             l_sales.setCustomer_first_name(res.getString(res                     .getColumnIndex(KEY_CUSTOMER_FIRST_NAME)));             l_sales.setCustomer_last_name(res.getString(res                     .getColumnIndex(KEY_CUSTOMER_LAST_NAME)));             l_sales.setCustomer_image(res.getString(res                     .getColumnIndex(KEY_CUSTOMER_IMAGE)));             l_sales.setUid(res.getString(res                     .getColumnIndex(KEY_UID)));             l_sales.setQuantity(res.getString(res                     .getColumnIndex(KEY_QUANTITY)));             l_sales.setP_name(res.getString(res                     .getColumnIndex(KEY_PRODUCT_NAME)));             l_sales.setP_image(res.getString(res                     .getColumnIndex(KEY_PRODUCT_IMAGE)));             l_sales.setCreated_at(res.getString(res                     .getColumnIndex(KEY_PRODUCT_CREATED)));             l_sales.setSvg(res.getString(res                     .getColumnIndex(KEY_SVG)));             l_sales.setOfflineTag(res.getString(res                     .getColumnIndex(KEY_OFFLINETAG)));              sales.add(l_sales);             res.moveToNext();         }         Log.d(TAG, "Fetching sales from Sqlite: ");         res.close();         return sales;     }     Before i return sales arrayList, i would like to check for duplicates there, remove them, the return the arrayList without duplicates. Any suggestions?

I have an ArrayList<String>, and I want to remove repeated strings from it. How can I do this?


I have a DB in pgAdmin and in one table i have an field named "description" that only can have 2 descriptions: "car" or "bike" in geoserver i set this label and work well:  <Label>  <ogc:PropertyName>description</ogc:PropertyName> </Label> <Font>  <CssParameter name="font-family">Arial</CssParameter>  <CssParameter name="font-style">Normal</CssParameter>  <CssParameter name="font-size">12</CssParameter> </Font> <Fill>  <CssParameter name="fill">#b7d5ff</CssParameter> </Fill>   but i want different colors for the 2 possibles descriptions. who is possible in geoserver?

I’ve a PostGIS table which is published as a Geoserver layer. Every feature in the table has some attributes that should style that feature (e.g color, size, opacity, external graphic url, ... etc).  I can create an SLD document and let it read its styling attributes from the table using <PropertyName>, but the problem is more complex than this, for example: some points features need to be styled as a simple circles, while some other need to be styled as external-graphic images. And from the SLD Reference, the SLD PointSymbolizer must have either <Mark> or <ExternalGraphic> element, for that reason I should create two rules one for the simple point symbolizer and the other for the external-graphic point symbolizer, and should add a filter to each rule so that it deals only with the appropriate features, something like:  <FeatureTypeStyle>     <Rule>         <ogc:Filter>             <ogc:PropertyIsEqual>                 <ogc:PropertyName>is-external-graphic</ogc:PropertyName>                 <ogc:Literal>0</ogc:Literal>             </ogc:PropertyIsEqual>         </ogc:Filter>         <PointSymbolizer>             <Graphic>                 <Mark>                     <WellKnownName>circle</WellKnownName>                     <Fill>                         <CssParameter name="fill">                             <ogc:PropertyName>fill-color</ogc:PropertyName>                         </CssParameter>                     </Fill>                 </Mark>                 <Size>6</Size>             </Graphic>         </PointSymbolizer>     </Rule>     <Rule>         <ogc:Filter>             <ogc:PropertyIsEqual>                 <ogc:PropertyName>is-external-graphic</ogc:PropertyName>                 <ogc:Literal>1</ogc:Literal>             </ogc:PropertyIsEqual>         </ogc:Filter>         <PointSymbolizer>             <Graphic>                 <ExternalGraphic>                     <OnlineResource                xlink:type="simple"                xlink:href="smileyface.png" />                     <Format>image/png</Format>                 </ExternalGraphic>                 <Size>6</Size>             </Graphic>         </PointSymbolizer>     </Rule> </FeatureTypeStyle>   My question is: Is there any better solution that is more dynamic?


They say that Neon $Ne$ is stable because it has 10 electrons and with 10 electrons it completes its octet and completing an octet decreases the potential energy of an atom to the minimum and a system loves to remain in the lowest energy as possible.  Then I read that an electron is literally a probability wave and we can only talk about the probability of an electron present at a point at a certain time instant.   How are the two terms related? How do waves decide that when a system is going to be stable? How is potential energy related to these waves?

What is the quantum mechanical explanation of the ? In other words, what makes the octet rule be true from a quantum mechanical view? How we explain  what makes some atoms don't follow the octet rule using QM?


not sure how to approach the following $\frac{\sin(a)}{\sin(b)}<\frac{a}{b}<\frac{\tan(a)}{\tan(b)}$ for $0<b<a<\pi/2$. Hints would be appreciated!

Prove the following:     $\frac{\sin(a)}{\sin(b)} < \frac{a}{b} < \frac{\tan(a)}{\tan(b)}$ where $0 < b < a < \frac{\pi}{2}$   Hello everyone, I am trying to create some sort of function or maybe see an application of the mean value theorem, but I am just not getting it. Any help would be greatly appreciated!


In Predestination, how was the lead character born for the first time?

In movie ,      a single woman (and man afterwards) repeats the same cycle starting from kidnapping of a baby, falling in love, etc.. and then again starting from beginning.   So, how was the baby born for the first time, and how does it come to know about the predestination?


I need to prove this using modular arithmetic but I'm a little stuck. Could I get some pointers? Thank you.  Let $a,b$ be integers. Then $3 | a^2 + b^2$ if and only if $3 | a$ and $3 | b$

For elements $a$ and $b$ in the ring $\Bbb{Z}$ prove that if $3\mid a^2+b^2$ then $3\mid a$ and $3\mid b$.  I tried proving it but I just don't manage to. Maybe I am missing some basic claims in the number Theory?  I would appreciate hints and, generally, your help.  I am sorry, there was another data I was given, I was fixed and resent to me.


Let $k$ be a field, $k^a$ an algebraic closure, and $\sigma$ be an automorphism of $k^a$ leaving $k$ fixed. Let $F$ be the fixed field of $\sigma$. Show that every finite extension of $F$ is cyclic.   I'm completely clueless, can anyone give some hint/solution ?

I am trying to prove the following proposition:     Let $L$ be an algebraically closed field, $g \in Aut(L)$ and $K=\{x \in L \; | \; g(x)=x\}$. Show that every finite extensions $E/K$ is a cyclic Galois extension.    So far my thoughts have led me to the following:  If $E=K$, then clearly $E/K$ is Galois and $Gal(E/K)=Aut(K/K)=i$, where $i$ is the identity automorphism, so it is trivially cyclic. Assume $[E:K]=n$ for some $n>1$. Since $E/K$ is a finite extension, it is algebraic. Note that if $\beta \in E\setminus F$ then we have the minimal polynomial $m_{\beta}(X)$ over $K[x]$. Since $K$ is fixed by $g$, we know that $g(\beta)$ is also a root of $m_{\beta}(X)$. We can also conclude that $g(\beta)\not \in K$ since $\beta \not \in K$.   Where to take any of these observations, I have yet to determine. I feel I must be missing something elementary, for I cannot see how to conclude this is a Galois extension from here.   Any tips would be greatly appreciated, especially over full solutions.


I have enum class   public enum PaymentType {      /**      * This notify type we receive when user make first subscription payment.      */     SUBSCRIPTION_NEW("subscr_signup"),      /**      * This notify type we receive when user make subscription payment for next      * month.      */     SUBSCRIPTION_PAYMENT("subscr_payment"),      /**      * This notify type we receive when user cancel subscription from his paypal      * personal account.      */     SUBSCRIPTION_CANCEL("subscr_cancel"),      /**      * In this case the user cannot change the amount or length of the      * subscription, they can however change the funding source or address      * associated with their account. Those actions will generate the      * subscr_modify IPN that we are receiving.      */     SUBSCRIPTION_MODIFY("subscr_modify"),      /**      * Means that the subscription has expired, either because the subscriber      * cancelled it or it has a fixed term (implying a fixed number of payments)      * and it has now expired with no further payments being due. It is sent at      * the end of the term, instead of any payment that would otherwise have      * been due on that date.      */     SUBSCRIPTION_EXPIRED("subscr_eot"),      /** User have no money on card, CVV error, another negative errors. */     SUBSCRIPTION_FAILED("subscr_failed");      private String type;      PaymentType(String type) {         this.type = type;     }      String getType() {         return type;     } }   When I try to create enum :  PaymentType type = PaymentType.valueOf("subscr_signup");   Java throws to me error :  IllegalArgumentException occured : No enum constant models.PaymentType.subscr_signup   How I can fix this?

Say I have an enum which is just public enum Blah {     A, B, C, D }  and I would like to find the enum value of a string, for example "A" which would be Blah.A. How would it be possible to do this? Is the  the method I need? If so, how would I use this?


On November 23, 2018 I had a flight from KRK (Krakow, Poland) to KBP (Kiev, Ukraine) via Ryanair, flight no. FR 6640. The flight was canceled due to bad weather conditions on KBP airport. Now, I'd like to submit for a flight compensation basing on EU261 and I'm looking for more information on the flight statuses that day/time at given airport, i.e. KBP.  How to find a historical and free of charge data of flight statuses per airport? I was looking for such data but ended up with paid options.    EDIT: This is not a duplicate of  The mentioned question asks about particular flight and that one is about airport. Also, sources given in the accepted answer provides paid historical data. The 3rd link is a non-existing page.

Where can I find historical data on flights, specifically Delta international flights?  I need to find out about cancellations, diversions and any other flight data pertaining on particular route at a given time.  This source has to be official and stand up to legal scrutiny.


This topic is very new to me. Is it possible to do comparison on the encrypted data(data is encrypted using Gentry's FHE)? If so, how can it be done?

I encountered a simple function that even FHE cannot solve. Here's it:  int f(a,b,c,d){    if(a+b>c+d) return a+c;       else return b+d; }   Since FHE is not order-preserving, one can't figure out whether a+b>c+d without the decryption key. That means even if practical FHE was implemented, f(a,b,c,d) cannot be computed in the Cloud independantly and securely. Not to mention linear regression, or more complex functions.  So I wonder with such an obvious limitation, why is FHE called "the holy grail of cryptography"?


What's the best Stack Exchange site to ask questions about  on?

I have a question I'd like to pose on the Stack Overflow site, but I'm sure it's been asked before - I've not seen it before, but it's so fundamentally useful to the specific thing I'm doing (that other people also do) that I can't believe I'm the first to ask it. The problem is I can't find the question for love nor money.  Is there a best practice for asking a question such as this?   (For reference my question is: how to automatically redirect all Python calls to an  virtual environment in Linux). The issue with finding the specific question may be the phrasing I use in the search (I also do a SE search via Google to no avail).


When attempting to delete own answered question, this message pops up:     Delete this answered question?      We do not recommend deleting questions with answers because doing so   deprives future readers of this knowledge.      Repeated deletion of answered questions can result in your account   being blocked from asking. Are you sure you wish to delete?   If you still decide to press delete this message can appear:     Sorry, this question has answers and can not be deleted. Flag it for   moderator attention instead.   When questions with answers can exactly be deleted? I was able to remove one of my "answered" questions yesterday, but it is apparently no longer possibly. I only delete weak questions with false, low-effort answers.

What circumstances can cause a question or answer to be deleted, and what does that actually mean?    How can a post be deleted? When can't I delete my own post? Can I still see my post even after it's deleted? Can I see a list of my deleted posts? How can I undelete one of my posts? What does deletion mean for a post? How do votes to delete work? What are the criteria for deletion? What else should I know about deleted posts? If I flag my question with a request to delete it, what will happen?       For more information, see the articles about  and  in the .


as the title says, im trying to change an image in a jframe using a timer. but it throws a NullPointerException. I am pretty new at java, and while i am in the process of researching exception handling, any direction you can give me will help my learning greatly.  here is my code:  public class PointTest extends JPanel {     JLabel drawcloseLabel = new JLabel(new ImageIcon("src/images/draw_closeup.jpg"));     JLabel monsterAttack = new JLabel("src/images/monsterAttack.jpg");     JLabel endGameLabel = new JLabel(new ImageIcon("src/images/monsterAttack.jpg"));     private static final long serialVersionUID = 1L; // i dont get this     private JFrame frame;      boolean off = false;     public JButton opendraw;     // public JButton button2;     public JButton ok;     public JButton back;     public JButton pickUpKey;     public JButton Key;     public JButton unlockDoor;     public JButton lockedDoor;      public JButton btnNewButton;     JPanel background;     JPanel door;     JPanel draw;     JPanel drawopen;     JPanel endGame;      public void room() {          frame = new JFrame("room");           frame.setSize(1280, 960);         frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);          JLayeredPane layeredPane = new JLayeredPane();         frame.getContentPane().add(layeredPane, BorderLayout.CENTER);          background = new JPanel();    endGame = new JPanel();     JLabel endGameLabel = new JLabel(new ImageIcon("src/images`/OutOfTime.jpg"));`     JLabel picLabel = new JLabel(new ImageIcon("src/images/room.jpg"));           background.add(picLabel);          endGame.add(endGameLabel);          background.setBounds(0, 0, 1280, 960);           layeredPane.add(background, JLayeredPane.DEFAULT_LAYER);       }   this is the method that, if i catch the exception, will continue the countdown to 0, but will not change the image.           public void EndTimer() {          //error         background.setVisible(false);          endGame.setVisible(true);         endGame.add(endGameLabel);         endGame.setBounds(0, 0, 1280, 960);         }  }   the countdown class for the Timer.   import java.util.Timer; import java.util.TimerTask;  public class Countdown {     static int interval;     static Timer timer;     boolean off;     PointTest pt = new PointTest();      public void Countdown1() {          int seconds = 10;         int delay = 1000;         int period = 1000;         timer = new Timer();          interval = seconds;          timer.scheduleAtFixedRate(new TimerTask() {              public void run() {                 System.out.println(setInterval());                 if (interval == 7) {                     System.out.println("works");                      pt.EndTimer();                  }              }         }, delay, period);     }      private int setInterval() {         if (interval == 1)             timer.cancel();         return --interval;      }      public int getInterval() {          return this.setInterval();     }  }    import java.io.IOException;    public class windowMain {       /**      * Launch the application.      *       */       public static void main(String[] args) throws IOException {           Countdown cd = new Countdown();         cd.Countdown1();         PointTest point = new PointTest();         point.room();         }  }   Stacktrace:  Exception in thread "Timer-0" works test java.lang.NullPointerException     at PointTest.EndTimer(PointTest.java:207)     at Countdown$1.run(Countdown.java:27)     at java.util.TimerThread.mainLoop(Unknown Source)     at java.util.TimerThread.run(Unknown Source)

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?


TL;DR: Blender seems to be prepending spurious // before filepaths when loading images from script.  Steps to reproduce: Save the following minimal script in a filename of your choice (e.g. blender_test.py)  import bpy D = bpy.data D.images.load('/Users/path/to/image.jpg')  # A JPG image in a different folder. You'll need to change this. D.images[0].use_fake_user = True bpy.ops.wm.save_as_mainfile(filepath="./fromscript.blend")   Execute using:  blender -b -P blender_test.py   Now open fromscript.blend in blender GUI, fire up the Python console and  print the path of the just-loaded image.   print(D.images[0].filepath)   I see the following in my console (part of the path has been redacted). Notice the two forward slashes in the path. When I load the image from the Python Console in the GUI, or using the dislog box, those slashes are not there. These two forward slashes are preventing my downstream commands (e.g. textured material creation) from seeing the loaded images. Why are there additional slashes when blender is executed as a script?    EDIT If I understand correctly,  is asking a different question, about linking images from a different machine using relative paths. My question asks about blender prepending slashes to an absolute path.

Functions such as os.path.exists(image.filepath) fail when Blender uses relative paths, This seems to be because Blender uses // prefix for relative paths, unlike the more conventional ./.  How can standard Python filesystem functions be used correctly on Blender paths?


Proving things in mathematics is very difficult for me. I don't quite understand what to do here:  Let $x$ be a whole number Show that $x(x-1)(x+1)$ divided by 6 is a whole number  I really appreciate any help

How can we prove that the product of $n$ consecutive integers is divisible by $n$ factorial?     Note: In this  and the comments here the OP has clarified that he seeks a proof that "does not use the properties of binomial coefficients". Please post answers in said newer thread so that this incorrectly-posed question may be closed as a duplicate.


I accepted an objective from the religious leader that required issuing an edict.  After looking at the consequences of the edict I decided I want to back out of this. Is there a way to cancel a mission?

In Tropico 4, I accepted several objectives but then discovered that once you have five unaccomplished objectives, you can't accept any more. Is it possible to dismiss an objective, once accepted?


I have bash a script like the following  #!/bin/bash  date  curl http://lab.nextt.com.br/somefile1.html -z ../public_html/somefile1.html -o ../public_html/somefile1.html --silent --show-error --location  curl http://lab.nextt.com.br/somefile2.html -z ../public_html/somefile2.html -o ../public_html/somefile2.html --silent --show-error --location  curl http://lab.nextt.com.br/somefile3.html -z ../public_html/somefile3.html -o ../public_html/somefile3.html --silent --show-error --location  curl http://lab.nextt.com.br/somefile4.html -z ../public_html/somefile4.html -o ../public_html/somefile4.html --silent --show-error --location   and I have a cronttab like this  * * * * * /home/user/cronjobs/cronjob-updatefiles >> /home/user/cronjobs/log   My intention is: whenever there is an update on a public file, download it to my server.  So good so far.  When I run the script manually on the shel, the files are downloaded and updated as expected.  And the cron is running the... The /home/user/cronjobs/log is being updated with the date (on the beggining of the script). But the curl commands are not executed via cron. The files are not updated.  Why when I run directly on the shell it works and when I run via cron it does not?

This is a  about using cron & crontab.   You have been directed here because the community is fairly sure that the answer to your question can be found below. If your question is not answered below then the answers will help you gather information that will help the community help you. This information should be edited into your original question.  The answer for 'Why is my crontab not working, and how can I troubleshoot it?' can be seen below.  This addresses the cron system with the crontab highlighted.


I need to find a candidate for the limit and then prove it is indeed one using the definition of a sequence's limit. That is, to solve inequality with a parameter $\epsilon > 0$. I suppose the limit is $0$(for intuitive reasons that $n^n$ ''grows faster'' than $n!$).  Now I need to solve the following inequality:  $\frac{n!}{n^n} < \epsilon$  Well, it is easy for $\epsilon \geq 1$ $n! < n^n \leq \epsilon n^n \ \  \forall n>1$, obviously.  If $\epsilon \in (0,1)$ we have $\epsilon n < n^n$.  By induction if $n! < \epsilon n^n$ for some $n$, then $(n+1)! < \epsilon (n+1)^(n+1) \Leftarrow !n < \epsilon n < \epsilon (n+1)^n$.   So now we need to prove that $\forall \epsilon \in (0,1)\ \ \exists n \in \mathbb{N}: n! < \epsilon n^n$  How should I approach that?

I'm trying to find out whether sequence $a_n= \frac{n!}{n^n}$ converges or not. My textbook says to compare with $\frac{1}{n}$, and my answer sheet says that $\lim_{x\to \infty} {\frac{n!}{n^n}}\leq \lim_{x\to \infty}\frac{1}{n}$. I don't get this part... Is $\frac{n!}{n^n} \leq \frac{1}{n}$? How did this relationship come about?


I have been trying to read my online training on Yahoo, but when I click the icon for training, a message box appears saying that I should install additional plugins. I have tried to install the additional plugins by selecting Tools -> Add-ons in Firefox, but nothing seems to work.   Why can't I install the Flash plugin in Firefox? And why is Firefox unable to use Adobe Flash Player?

When searching through Synaptic for flash player I always see the options to use "flashplugin-installer" or "flashplugin-nonfree" or "adobe-flashplugin".  Is there a reason to use one over the other?    I seem to be constantly running into problems with Flash player freezing crashing, mostly because of running too many flash apps at once (pandora/fantasy apps/youtube/etc). Does using one of these over the other have performance benefits?  Or am I confusing myself and it doesn't really matter as they're both the same?


When I \cref an algorithm, it shows "algorithm 1". Is it possible to ref an algorithm with its numbering and caption? Like "algorithm 1 foo", where "foo" is the caption of algorithm 1. Thanks a lot

I want to reference a section with cleveref like in the following example:  \section{Foobar} \label{sec:foobar}  See \cref{sec:foobar}.   The output of this is:     See section 1.   But what I would like is this:     See section 1 Foobar.   I understand that there is no command by default, that produces this output.  So I tried to build my own command like suggested for the hyperref package in . However, I could not find an equivalent command to hyperref's \nameref in cleveref's documentation.  Is it possible to create a new command, that produces my desired output?


What is the difference from  class Test {     A a = new A(); }   to  class Test {    static A a = new A(); }   Does the virtual machine perform differently in the initialization?

To be specific, I was trying this code:  package hello;  public class Hello {      Clock clock = new Clock();      public static void main(String args[]) {         clock.sayTime();     } }   But it gave the error      Cannot access non-static field in static method main   So I changed the declaration of clock to this:  static Clock clock = new Clock();   And it worked. What does it mean to put that keyword before the declaration? What exactly will it do and/or restrict in terms of what can be done to that object?


What is $(1372)(56) \circ(154)$ and how to work out similar compositions?

I didn't find any good explanation how to perform multiplication on permutation group written in cyclic notation. For example, if $$   a=(1\,3\,5\,2),\quad b=(2\,5\,6),\quad c=(1\,6\,3\,4), $$  then why does $ab=(1\,3\,5\,6)$ and $ac=(1\,6\,5\,2)(3\,4)$?


When I'm calculating battery life in series do I add up the mah  or is is the same as a single unit?  Ex. If I take 10x 3.2v cells @3000 mah and concert them in series, I will have 32 v @ 30,000mah or 3000mah.  How does this work for parallel circuits.  Thanks

Imagine I have a 10V battery with a capacity of 1Ahrs connected to a 100 Ohm resistor.  I'll get 0.1A (V/R) at a power of 1W (current x voltage) for a total of 10hrs. As a watt is defined as J/s my battery produces 3,600J (1x60x60) in total.  Now, imagine I get a second, identical battery and connect it in series to the first one. I will effectively have a battery of 20V with a capacity of 2Ahrs, all connected to the same 100 Ohm resistor.  I'll get 0.2A at a power of 4W (current x voltage) for a total of 10hrs. This will generate 14,400J (4x60x60).  So, from doubling my energy source I have quadrupled the energy output!  I've obviously made an error somewhere either in my calculations or conceptual understanding, and I would be most grateful to anyone who could set me right.  Thanks!


I am testing a very simple python script. What the function does is not important to my question, my question is the following code somehow gives me:  File "test.py", line 13, in traverse     if root.val > minVal and ans > root.val: UnboundLocalError: local variable 'ans' referenced before assignment   But I do have ans defined, why does it not complain about minVal but does about ans?  class Test(object):      def findSecondMinimumValue(self, root):         """         :type root: TreeNode         :rtype: int         """         minVal = root.val         ans = float("inf")          def traverse(root):             if not root:                 return              if root.val > minVal and ans > root.val:                 ans = root.val              traverse(root.left)             traverse(root.right)          traverse(root)         return ans if ans != float("inf") else -1

The following code works as expected in both Python 2.5 and 3.0:  a, b, c = (1, 2, 3)  print(a, b, c)  def test():     print(a)     print(b)     print(c)    # (A)     #c+=1       # (B) test()   However, when I uncomment line (B), I get an UnboundLocalError: 'c' not assigned at line (A). The values of a and b are printed correctly. This has me completely baffled for two reasons:   Why is there a runtime error thrown at line (A) because of a later statement on line (B)? Why are variables a and b printed as expected, while c raises an error?   The only explanation I can come up with is that a local variable c is created by the assignment c+=1, which takes precedent over the "global" variable c even before the local variable is created. Of course, it doesn't make sense for a variable to "steal" scope before it exists.  Could someone please explain this behavior?


I have Ubuntu as my main Operating System, but I run Windows in a VirtualBox because some of my programs are not supported, I have Videos, Documents etc on Ubuntu and I would like to access them on Windows without having to copy them to Windows and having two copies of the same file.  Thanks in advance

I have installed VirtualBox OSE on Ubuntu 11.04 and Windows XP pro as the virtual machine. Now I want to have a shared folder which can be accessed on both, my host Ubuntu machine, and my WinXP guest virtual machine.  How can I do that?


<img src="assets/img.jpg" id="imgElement" #imageElement  width="50%" height="50%" />  How to get resolution of an image from image and how to reduce the resolution in percentage with javascript or typescript  My Actual task is to show original image in my site on mouse hover of an element, but while showing that image, because of the higher resolutions image is crossing the browser window, so I want to reduce the percentage of image.  Guys please help me on this.

I am creating a jQuery plugin.  How do I get the real image width and height with Javascript in Safari?  The following works with Firefox 3, IE7 and Opera 9:  var pic = $("img")  // need to remove these in of case img-element has set width and height pic.removeAttr("width");  pic.removeAttr("height");  var pic_real_width = pic.width(); var pic_real_height = pic.height();   But in Webkit browsers like Safari and Google Chrome values are 0.


Consider a scenario where you have polygons representing the border of every country in Europe. You also have the Lat/Long of a user's mobile device. You now want to display which country that user is currently located in. In essence, you have multiple polygons and a single point, and you'd like to find the polygon that contains that point. Point-in-polygon algorithms are well known, but what are some strategies to reduce the search time?

I've a Google map with bunch of polygons on it.  Here is a problem I'm interested in: Given a lat,lng point, what's the best way to determine all the polygons that this point lies in?  The obvious way is to run a "point in polygon" algorithm iteratively for each polygon, but I was wondering if there an efficient algorithm to answer such queries especially if you have thousands of polygons.


I'm using Windows 7. I want to set Explorer's default location to "My Computer", whether explorer.exe is launched via the "Run" command, via command-line or via a shortcut. That's why I don't want to use a shortcut with a parameter.  I've done it in the past by tweaking the registry, but the default location was reset to Libraries after an update and I can't find the solution again.  This question isn't a duplicate of . The solution given there doesn't work on Windows 7.

My searching has only shown me how to change various shortcuts for Windows Explorer to open specific locations. While learning the command line options for explorer.exe is beneficial, I'm trying to change where Windows Explorer opens when opening it by hitting Windows + E (the shortcut)-  Super User question was particularly informative on the subject, but again - for shortcuts, not when using the global hotkey. Why do I want this? Windows + E is by far my favorite; why to open Window's explorer? But, most of the time I want to see my userdir. Also, I detest the favorites, libraries, and desktop/user directory shown (Why? because they don't represent the filesystem), it should only be computer/* <- This I've done. I want Windows + E to open to be {install_drive}/users/{user}, e.g. c:/users/payo.


I have tried playing GTA IV on PoL and Wine without luck. It works with every other game I have tried, including World of Tanks, Portal, Portal 2, Half-Life, BioShock, World of Warcraft,  Garry's mod and more. In my tests I installed the game and then applied the 1.0.7.0 patch. Now I cannot get it to boot, always crashes with the only error message being the playonlinux one.  I also tried with Wine, to no avail. Whole install works fine, then will not launch from the desktop shortcut or the /home/.wine/drive_c/program files(x86)/rockstar games/launchgtaiv.exe  It actually almost worked with update 3, but couldn't start the game or even change screen resolution. Changing wine version to the one recommended in the wine directory caused an error saying GTA IV needs a sound card to run. Changing sound driver is not an option because it says that there are none, but only with anything but wine ver. 1.3.23  My Specs:  CPU - AMD A10-6800K RAM - 4GB GPU -  9600GT (2007 version) (512MB DDR3) (Proprietary Drivers) HDD -  750GB hybrid drive

I am looking for a step by step instruction to guide me in the ways of installing, configuring and debugging many of the issues new users have when dealing with Wine in Ubuntu.  What is the recommended way of installing Wine, some of the key issues that it has and how to solve them?  If I have a specific problem with an App in Wine, how do I go about solving it? What are the recommended steps to ensure that I can fix a problem related to an app I wish to use?


I have gone through many a post here and elsewhere that treats home in such sentences as  Stay home.   Go home.  prepositions. Admittedly, this is a fairly new perspective of looking at the POS, thanks largely to Otto Jespersen. However, beyond a smattering of information about this new approach to classify the POS, nothing more is to be found anywhere on the internet. Maybe, I can't zero in on the right information. My question then is what makes home a special word that we treat it, and not other such words (say, factory, store, shop, etc.), as a preposition? Could it be that such sentences as above became idiomatic through word of mouth and forced a novel classification of home? And how does this change the definition of a preposition, which traditional grammar defines as: A word that shows in what relation a noun or a pronoun stands to other elements of a clause or a sentence.

I'm a little bit confused over the difference between the following sentences.   I went home. I went to home.  Could someone please explain the difference.


$a_n=(1+\frac{1}{n})^n$ and $n\geq 1$ I check first $n\to \infty$ then $\lim_{n\to \infty}=(1+\frac{1}{\infty})^\infty$ $=(1+0)^\infty=1^\infty$ I don't find the next step.Help me

Here is my candidate for  the most elementary proof that $\lim_{n \to \infty}(1+1/n)^n $ exists. I would be interested in seeing others.  $***$ Added after some comments: I prove here by very elementary means that the limit exists. Calling the limit "$e$" names it. $***$  It only needs Bernoulli's inequality (BI) in the form $(1+x)^n \ge 1+nx$ for $x > -1$ and $n$ a positive integer, with equality only if $x = 0$ or $n = 1$. This is easily proved by induction: It is true for $n=1$, and $(1+x)^{n+1} = (1+x)(1+x)^n \ge (1+x)(1+nx) = 1+(n+1)x+nx^2 \ge 1+(n+1)x $. (If $-1 < x < 0$, if $1+nx \ge 0$, the above proof goes through, and if $1+nx < 0$, $1+mx < 0$ for all $m \ge n$ so certainly $(1+x)^m > 1+mx$.)  This proof originally appeared in N.S Mendelsohn, An application of a famous inequality, Amer. Math. Monthly 58 (1951), 563 and uses the arithmetic-geometric mean inequality (AGMI) in the form $\big(\sum_{i=1}^n v_i/n\big)^n \ge \prod_{i=1}^n v_i$  (all $v_i$ positive) with equality if and only if all the $v_i$ are equal.  Let $a_n = (1+1/n)^n$ and $b_n = (1+1/n)^{n+1}$.  We will prove that $a_n$ is an increasing sequence  and $b_n$ is an decreasing sequence.  Since $a_n < b_n$, this implies,  for any positive integers $n$ and $m$ with $m < n$  that $a_m < a_n < b_n < b_m$.  For $a_n$, consider n values of $1+1/n$ and $1$ value of $1$.  Since their sum is $n+2$ and their product is $(1+1/n)^n$, by the AGMI,  $((n+2)/(n+1))^{n+1} > (1+1/n)^n$,  or $(1+1/(n+1))^{n+1} > (1+1/n)^n$,  or $a_{n+1} > a_n$.  For $b_n$, consider $n$ values of $1-1/n$ and $1$ value of $1$.  Since their sum is $n$ and their product is $(1-1/n)^n$, by the AGMI,  $(n/(n+1))^{n+1} > (1-1/n)^n$  or $(1+1/n)^{n+1} < (1+1/(n-1))^n$,  or $b_n > b_{n+1}$.  Since $b_n-a_n  = (1+1/n)^{n+1} - (1+1/n)^n = (1+1/n)^n(1/n) =a_n/n $ and every $a_n$ is less than any $b_n$ and $b_3 = (1+1/3)^4 = 256/81 < 4$, $b_n-a_n < 4/n$, so $b_n$ and $a_n$ converge to a common limit.  These proofs do not seem to be really elementary,  since they use the AGMI.  However, they use a special form of the AGMI,  where all but one of the values are the same,  and this will now be shown to be implied by BI,  and thus be truly elementary.   Suppose we have $n-1$ values of $u$ and $1$ value of $v$ with $u$ and $v$ positive.  The AGMI for these values is  $(((n-1)u+v)/n)^n \ge u^{n-1}v$  with equality if and only if $u = v$.  We will now show that this is implied by BI: $(((n-1)u+v)/n)^n \ge u^{n-1}v$  is the same as  $(u+(v-u)/n)^n \ge u^n(v/u)$.  Dividing by $u^n$,  this is equivalent to  $(1+(v/u-1)/n)^n \ge v/u$.  By BI,  since $(v/u-1)/n > -1/n > -1$, $(1+(v/u-1)/n)^n \ge 1+n((v/u-1)/n) = v/u$  with equality only if $n=1$ or $v/u-1 = 0$. Thus BI implies this version of the AGMI.


I was poking through the settings in unity tweak tool, adjusted a few things just to see what they did. Like window behavior on sides/corners multi desktops (forgot what they are called in ubuntu)  The very last thing I touched was the reset button and it broke it. My top bar is now gone, the launcher is gone, and the super key wont start a search. I have tried a ton of things I've read to fix it without luck, will list what I have tried.  tried reseting unity "unity-tweak-tool --reset-unity" it asks me to log out and back in which I am not sure how to do via terminal as I have no top bar to do the normal way. I logged out by using sudo service lightdm reset but I dont know if that is correct, it got me back to the login screen but upon log in everythings the same.  I tried running unity via terminal and get: unity-panel-service stop/waiting unity7 stop/waiting unity-panel-service start/running, process 3102 unity7 start/running, process 3104  those numbers change sometimes but it never works, screen flashes a bit, some windows come and go but then in the end nothing stays.  I went to restore from back in time but through terminal it says its not configured which i dont understand because I had it doing daily backups with back in time root. Which I watched it do the first one but now cannot find.  Any help is appreciated.

When I login, nothing happens.   I am presented with my desktop wallpaper.    No Dash, no Launcher, nothing.


class Game { public:     static Game& GetInstance()      {         return game_;     } private :     static Game game_;     Game(); };   Выдает ошибку error LNK2001: unresolved external symbol "private: static class Game Game::game_" (?game_@Game@@0V1@A) Не понимаю что не нравится компилятору Спасибо

Very simply put:  I have a class that consists mostly of static public members, so I can group similar functions together that still have to be called from other classes/functions.  Anyway, I have defined two static unsigned char variables in my class public scope, when I try to modify these values in the same class' constructor, I am getting an "unresolved external symbol" error at compilation.  class test  { public:     static unsigned char X;     static unsigned char Y;      ...      test(); };  test::test()  {     X = 1;     Y = 2; }   I'm new to C++ so go easy on me. Why can't I do this?


I am receiving quite a few unwanted calls (6 yesterday), although I am blocking the numbers and , I would rather simply not get them.  All of the phone numbers that are calling me end in "114", and this gave me an idea. Is there any way to block numbers that end with specific digits (or regex based)?

Is it possible to block calls starting with a specific number? For instance, I want to block calls from numbers starting with 1408 as they are all spam calls. The digits following these four, keep changing.


When I am reading a machine learning book I came across the following notation  $$||\theta||^2_2$$  What does the $||.||^2_2$ stand for? I know its magnitude but what is the 2,2 for?

I am new to optimization. I keep seeing  that have a superscript 2 and a subscript 2 on the right-hand side of a norm. For instance, here is the least squares equation  min $ ||Ax-b||^2_2$  I think I understand the superscript 2: it means to square the value of the norm. But what is the subscript 2? How should I read these equations?


In Windows File Explorer, you can highlight several files and then click the "Copy path" button from the menu.  Show below is an example.  I'd then like to process these files on the command line, preferably in a PowerShell terminal.  I've tried enclosing them in more quotes, single quotes, and backticks, to no avail. Here's an example of the files copied to the clipboard:  "C:\Users\me\100_0909.jpg" "C:\Users\me\100_0521.jpg" "C:\Users\me\100_0519.jpg"  I'd like to be able to take the files above and include them in a command like:  magick "C:\Users\me\100_0909.jpg" "C:\Users\me\100_0521.jpg" "C:\Users\me\100_0519.jpg" +append new.jpg

How do I effectively copy and paste input and output in the Windows PowerShell?


Given the letters A, A, B, B, C, D, E. How many different arrangements are possible that begins and ends with the letter "A"?   I don't understand "user99680"'s explanation for arranging the two Bs in "5C2" ways.   He said "you can select 2 places for the B′s in 5C2 ways (with $_5C_2=\frac{5!}{2!3!}=10$)."

Given the letters A, A, B, B, C, D, E   How many different arrangements are possible that begins and ends with the letter "A"?    B,B,B,G,G  Three boys and two girls shown above are lined up side by side in a single row so that boys and girls are lined up in groups respectively. How many different arrangements of the childern are possible?  There are 3 Republicans and 2 Democrats on a Senate committee. if a 3-person subcommittee is to be formed from this committee, what is the probability of selecting 2 Republicans and 1 democrat?  An urn contains 4 white marbles and 5 black marbles, all of equal size. If two marbles are drawn at random with no replacement, what is the probability that 2 marbles are different colors?  If the 5 cards A, B, C, D, E are placed in a row so that cards B and C must be next to each other, how many different arrangements are possible?


Given $f:[0,1]\to\mathbb R$ which is continuous, $f(0)=f(1)$, and $n\in\mathbb N^*$ (doesn't include $0$), show that $f\bigl(x+\frac1n\bigr)-f(x)=0$ has a solution.  This was shown to me by an acquaintance who told me that if we consider $h(x)=f\bigl(x+\frac1n\bigr)-f(x)$, then the fact that $\sum_{k=0}^{n-1}f\bigl(\frac kn+\frac1n\bigr)-f(\frac kn)=0$ somehow tells us that there are two opposite terms in that sum, and, as such, we can apply the IVT to $h(x)$. Clearly the sum is null because it is in the form $f(1) + (f(a)-f(a)\text{ same argument a})+(f(b)-f(b)\text{ same argument b})+...-f(0)$ and $f(1)=f(0)$, not because there somehow exists two different in argument terms that cancel $f(a)+f(b)=0$. In any case, we require a $h(a)$ and a $h(b)$ such that $h(a)h(b)<0$, not in terms of $f$. But, from what I have understood, this is the correction given by their professor, so maybe I am missing something? EDIT: Ignore the following nonsense... I thought of going about it by contradiction, but the use of a limit leaves me undecided as to whether this counts as a solution. The negative of the proposition is $\exists n\in\mathbb N^*\,|\,\forall x\in\mathbb R,\,f\bigl(x+\frac1n\bigr)-f(x)\neq0$, i.e $f\bigl(x+\frac1n\bigr)<f(x)$ or $>$. In both cases, if we take $n\to\infty$, we get $f(x)<f(x)$, which is impossible. Any comments? Thank you!

Let $f:[0,1]\to\mathbb{R}$ be continuous and $f(0)=f(1)$. Show that for any integer $n\geqslant 2$, there is $\xi\in(0,1)$ s.t.$f(\xi)=f\left(\xi+\frac{1}{n}\right).$  I think this requires the intermediate value theorem somewhere.