Is there a way to condense multiple figures into one line for the List of Figures?  For instance, I have an appendix of measurements that are figures, which total about 600 images (multiple measurements made at multiple stations) that I don't necessarily want listed out individually, so can you force the List of Figures to read:  Figure B.1-B.30  Diagnostic Plots for station APZ....................302-310  Figure B.31-B40  Diagnostic Plots for station CRLZ...................311-320  etc.?

I have a complex document with a few thousand figures (most of which are slight variants, but a few are key). I would like to produce a list of figures (lof) which only includes individual figures selectively, bunches others, and omits some completely. Some of my captions are in floats and others use captionof from the caption package.  For example:  1.2       This is the king.........................5  1.5       This is the queen........................9  1.16-1.66 Various princesses...............12-88  Most of this is easy to do. I can omit the entries I want by sending a blank alternative argument to the caption. I can also manually send entries to the lof that includes a range of figure numbers (for excluded entries).     What is however difficult is to figure out a way to   a) punch a page range (corresponding to the figure range) into the page number part of the lof.  b) format the figure range so that it aligns with the rest of the figure numbers (I use titletoc)  MWE below with image of results so far    \documentclass[a4paper]{book} \usepackage{caption}  \begin{document} \listoffigures     \chapter{Bloo}  \begin{figure}[htb] \caption[]{This is God and does not appear in lof} \label{fig:first} \end{figure}   \clearpage \begin{figure}[htb] \caption[This is the king]{King} \label{fig:second} \end{figure}   \clearpage \begin{center} \captionof{figure}[This is the queen]{Queen} \label{fig:third} \end{center}  \clearpage \begin{center} \captionof{figure}[]{Does not appear in lof} \label{fig:fourth} \end{center}  \clearpage \begin{center} \captionof{figure}[]{Princess 1} \label{fig:fifth} \end{center}  \clearpage \begin{center} \captionof{figure}[]{Princess 2} \label{fig:sixth} \end{center}  \addcontentsline{lof}{section}{\ref{fig:fifth}--\ref{fig:sixth} Various princesses page numbers wrong want a range}  \end{document}   Edit: Since posting I realised I can do   \addtocontents{lof}{\protect \contentsline {figure}{\numberline {\ref{fig:fifth}--\ref{fig:sixth}}{\ignorespaces Various princesses}}{\pageref{fig:fifth}--\pageref{fig:sixth}}}   which yields a great output.  I will leave the question up here for the moment in case it inspires any better solutions or helps anyone else.


I am having 2 string and wanted to compare ignoring the case.  Ex:  s1.contains(s2.toLowerCase()) in this case the problem is s1 might be in upper case.  s1.toLowerCase().contains(s2) in this case the problem is s2  might be in upper case.    The only option is i need to change both the string to lowercase to find the contains.   ex: s1.toLowerCase().contains(s2.toLowerCase())   Is there is any utility or string method instead of using this approach as String is immutable.  Thanks.

Say I have two strings,  String s1 = "AbBaCca"; String s2 = "bac";   I want to perform a check returning that s2 is contained within s1. I can do this with:  return s1.contains(s2);   I am pretty sure that contains() is case sensitive, however I can't determine this for sure from reading the documentation. If it is then I suppose my best method would be something like:  return s1.toLowerCase().contains(s2.toLowerCase());   All this aside, is there another (possibly better) way to accomplish this without caring about case-sensitivity?


What is the easiest way to compare strings in Python, ignoring case?  Of course one can do (str1.lower() <= str2.lower()), etc., but this created two additional temporary strings (with the obvious alloc/g-c overheads).  I guess I'm looking for an equivalent to C's stricmp().  [Some more context requested, so I'll demonstrate with a trivial example:]  Suppose you want to sort a looong list of strings. You simply do theList.sort(). This is O(n * log(n)) string comparisons and no memory management (since all strings and list elements are some sort of smart pointers). You are happy.  Now, you want to do the same, but ignore the case (let's simplify and say all strings are ascii, so locale issues can be ignored). You can do theList.sort(key=lambda s: s.lower()), but then you cause two new  allocations per comparison, plus burden the garbage-collector with the duplicated (lowered) strings.  Each such memory-management noise is orders-of-magnitude slower than simple string comparison.  Now, with an in-place stricmp()-like function, you do: theList.sort(cmp=stricmp) and it is as fast and as memory-friendly as theList.sort(). You are happy again.  The problem is any Python-based case-insensitive comparison involves implicit string  duplications, so I was expecting to find a C-based comparisons (maybe in module string).  Could not find anything like that, hence the question here. (Hope this clarifies the question).

How can I do case insensitive string comparison in Python?  I would like to encapsulate comparison of a regular strings to a repository string using in a very simple and Pythonic way. I also would like to have ability to look up values in a dict hashed by strings using regular python strings.


I traveled to Italy two times previously 10 years ago and applied for a tourist visa last year (2017). Unfortunately, my visa was rejected and objection raised on me that      Justification of attended stay and condition is not provided   All of my attached documents are perfect except that in my previous visits I didn't enter and leave Italy directly; rather I entered once from France and second from Amsterdam. I have paper evidence that I was in Italy previously.   I like to re-apply again this year kindly guide me.

Schengen refusal formulae can be difficult to understand sometimes.  Sometimes an applicant receives a refusal with:       Justification for the purpose and conditions of the intended stay was not reliable.     often accompanied by:       Your intention to leave the territory of the Member States before the expiry of the visa applied for could not be ascertained.   What is meant by this refusal reason?  What are they trying to say?


I've been told that the sequence X1, X2,...,Xn are iid from Exp(y) with density function f(x)=(1/y)*exp(-x/y). I've been asked to find the limiting distribution of Wn = Xn:n - ylog(n) where Xn:n is the first order statistic. However, I feel totally stuck. I feel as if I need more information on the sequence of random variables in order to solve the problem. Any help is greatly appreciated.

I have two questions.   1) If $X_1,X_2,X_3,...,X_n$ constitute a random sample of size $n$ from an exponential distribution, show that $\bar X$ is a consistent estimator of the parameter $\lambda$.    This is my attempt: Mean of exponential distribution is $\lambda^{-1}$. Thus by central Limit theorem $E(\bar X)=\lambda^{-1}$. Using mean square consistency, if  $\lim_{n\to \infty} E[(\bar X -\lambda )^2]=0$ then $\bar X $ is consistent for $\lambda$. Since $$ E[(\bar X -\lambda )^2]= E[(\bar X)^2]+E(\lambda)^2-2\lambda E(\bar X) , $$  I get $$ \lim_{n\to \infty} E[(\bar X -\lambda )^2] =    \lim_{n\to \infty} {2 \over \lambda ^2 }+\lambda^2-2 . $$ Clearly this is not equal to $0$. How can I show this is consistent? I tried using Chebechev inequality as well. But even using that I couldn't.    2) Is $X_{(n)}$ a consistent estimator for $\lambda$? If $P[|X_{(n)}-\lambda|<\epsilon]$ approaches $1$ as $n$ goes to infinity for all $\epsilon > 0$ then $X_n$ is a consistent estimator for $\lambda$.    The probability density function of $X_{(n)}$ is $f_n(x) = n \lambda e^{-\lambda x}(1-e^{-\lambda x})^{n-1}$,  for $X>0$.  Thus \begin{align*} P[|X_{(n)}-\lambda|<\epsilon]  &= P[\lambda -\epsilon<X_{n}<\lambda+\epsilon] \\  &=P[0<X_{n}<\lambda+\epsilon] \\  &=\int_0^{\lambda+\epsilon} n \lambda e^{-\lambda x}(1-e^{-\lambda x})^{n-1}\\  &= (1-e^{- \lambda X_{(n)} }), \end{align*} where $X{(n)}$ takes values in $[0 , \lambda+ \epsilon]$.  Thus, can I say $\lim_{n\to \infty}[1-e^{-\lambda(\lambda+\epsilon)}]^n=1$?


I have a laptop ASUS, model G551J, with ubuntu 14.04.5 installed (64-bit architecture). After running on it a USB live of Lubuntu, 32-bit, the laptop won't boot any more. A grub-rescue prompt turns up with the following error:  error:file '/boot/grub/i386-pc/normal.mod' not found.   I ran a USB live of ubuntu 14.04.5, and executed boot-repair, but it threw an error, with this log:     There is a very similar question with a very good answer here:     But this question is more about why boot-repair failed to repair  this issue.   How can I fix this problem?

error: file '/grub/i386-pc/normal.mod' not found. grub rescue>   What can I do? I just sit and stare at it.   I found my old netbook (Dell Inspiron 1010) which I have not used for about four years. I replaced Windows XP with Ubuntu 12.10. I used my bootable USB drive. I installed and rebooted. I got the message that normal.mod is not found.   What should I do? Type exit, reboot, or quit? Should I re-install?


Rolling a 1 or 20, PHB pg 194      [...] If the d20 roll for an attack is a 1, the attack misses regardless of any modifiers or the target's AC.        Lucky Feat, PHB pg 167      [...]You can choose to spend one of your luck points after you roll the die, but before the outcome is determined.   Rolling a 1 on an attack roll (Nat 1) is often called being an auto-fail and with a good reason. Is it intended for these rolls to be instant failure/success? Because as soon as you see that 1 on the die you know: you have failed and there is a limited number of ways to change that. The question is: "Is Lucky one of them?".  I can see a DM calling "You have failed so hard that even your inexplicable luck can't get you out of this one", and it is usually fun for the players when something so unlucky happens to someone else. At least in my experience. My question is if it was meant to be like that as seeing that 1 alone can be a confirmation for failure. Are features like Lucky(dice manipulation features) worded that way to prevent these manipulations?

Several features like the Lucky feat, the divination school, and bardic inspiration can change the outcome of a roll by adding or changing the result.  The lucky feat states:      You can choose to spend one of your luck points after you roll the   die, but before the outcome is determined.   The divination school states:     You can replace any attack roll, saving throw, or ability check made   by you or a creature that you can see with one of these foretelling   rolls. You must choose to do so before the roll, and you can replace a   roll in this way only once per turn.   And the bardic inspiration states:     The creature can wait until after it rolls the d20 before deciding to   use the Bardic Inspiration die, but must decide before the DM says   whether the roll succeeds ar fails.   My issue is understanding the concept "Before the outcome is determined". Some examples:   Bob rolls a 1 on an attack roll, the outcome is automatically determined, he failed. He can't roll a luck dice, because 1 is a natural failure for an attack. Tim the ogre attacks Bob, and rolls a 20 on the dice. It's a critical and automatic succes. Bob can't spend a luck dice to change Tim's roll, because a 20 is a natural succes.   Bardic inspiration is out of the formula, because modifiers don't change the outcome of an automatic succes or failure.  In the case of the divination school Bob the Wizard can expend those dice when the GM says "the ogre attacks you", Or when Bob decides to attack and choose a foretelling dice.   My question is. Did I get everything right, or I missed something? And, What happens with the divination school feature when you roll behind the DM screen?   Thanks for your answers, and sorry for my english, It isn't my native language.


So i use a python scrips that sometimes on some ips it just hangs. I run the script on about 250 ips. With xargs from a sh script  How would i i limit the time of the py script runing. If it hang for more than 30 sec for example to leave/kill ?  I dont want to use time as it is server dependant. I was thinking more of a python function

I want to start a programm with timeout, how can I kill the process using SIGINT and SIGKILL? If the programm not terminate within 5 seconds, send SIGINT. If it’s still running after 10 seconds (in total), send SIGKILL.  I already did timeout -s SIGINT nano; timeout -s SIGKILL nano but its not working, can somebody help me?


I know there is a difference in meaning between "economic" and "economical" but what about "geographic" and "geographical" or "analytic" and "analytical"?

I just came across a course name: Geometric and Theoretical Optics. The mismatched endings bug me. Why do we have both -ical and -ic endings?   Is there any difference in meaning between, say, theoretic and theoretical? I know that acoustic and acoustical mean slightly different things, but is this difference inherent in the words, or is it just usage — we happen to use the former for sound, and the latter for ceilings?


Given a vector space $V$ (possibly infinite dimension) and a subspace $W$, is it always possible to write  $$V = W\oplus \overline{W}$$  For some subspace $\overline{W}$ of $V$. How would one show this? Clearly if there is additional structure, like $V$ has an inner product and is finite dimensional we can set  $$\overline{W} := W^\perp =  \{ v\in V \ | \ \forall w\in W, <w,v> = 0 \}$$  But can we always decompose any vector space $V$ this way given any subspace $W$? This post shows it can be done for finite dimension $W$: . Is additional structure such as an inner product required?

Given a subspace $U \subset V$ of a vector space $V$, show that there exists a subspace $U' \subset V$, such that $U+U'=V$ and $U \cap U'=\{0_V\}$.  I am aware that $U'$ is the complement of $U$ in $V$.   Would it be correct to prove this over the basis extension theorem?  For every subspace $U$ there exists a basis of $U$, let it be $B_U$. It is true that $B_U \subset V$. According to the basis extension theorem one can extend any set of linearly independant vectors in $V$ to a basis of $V$. Thus one can extend $B_U$ to a basis of $V$. Let this basis be $B_V$. It is true, since the vectors in $B_V$ are linearly independant, that $\langle B_U \rangle \cap \langle B_V \setminus B_U \rangle = \{0_V\}$. It is also obviously true that $\langle B_U \rangle + \langle B_V \setminus B_U \rangle =V $. Let $\langle B_V \setminus B_U \rangle=U'$.   Is this correct or am I missing something?


Need help identifying frames to make sure make model and possibly year

We often get questions on bicycles.stackexchange about identifying a bicycles manufacturer, model, make, and year.  Often these questions are downvoted or closed -- usually with a comment attached to them that it's not necessary to know the exact model/make/year of a bicycle if you want to fix, repair, or ride your bike. Why should owners not care about the model/make/year of their bicycle? Especially when it comes to less expensive bikes (aka BSOs) and BMX bicycles? This is intended as a canonical question that we can point closed questions to. Also see      (generally not helpful for identifying a brand/model)


I have the following code working:  SELECT of_Loans__c, Id, ( SELECT id FROM Loans__r WHERE MtgPlanner_CRM_Status__c = 'Closed')  FROM Contact   After some time tinkering around, I was able to access the information of the loan related list (on the Contact page) using the '__r' extension. The above SOQL query does as I want it:    However, I did this in a sandbox environment which may not have the same relationships between objects as I have in live.  A similar SOQL query (in live):  SELECT of_Closed_Loans__c, Id, ( SELECT id FROM Loans__r WHERE MtgPlanner_CRM__Status__c = 'Closed')  FROM Contact   renders the following error:  didn't understand relationship 'Loans__r' in FROM part of query call. If you are attempting to use a custom relationship, be sure to append the '__r' after the custom relationship name. Please reference your WSDL or the describe call for the appropriate names  Both environments have Contacts with a related list to the Loan object; I do not know what might I need to tweak on the live env. to replicate the results of the successful first sandbox env.   Any suggestions are appreciated!

In Trailhead we have the query to get the Contacts for the Account named "SFDC Computing", with an inner query.   SELECT Name, (SELECT LastName FROM Contacts) FROM Account WHERE Name = 'SFDC Computing'   It works fine for my purposes.  "Contacts" is the name of the relationship, per Trailhead. So, I went to Object Manager and examined the Account object's "Fields and Relationships". There is nothing named "Contacts"!   In general, how do I get the name of the relationship, for use in similar SOQL queries?


I am wondering if "from where" is an acceptable relative phrase when we refer to a location.  For example:  You should stay at a hotel near the main station, from where/which you can travel everywhere in this country.  In this sentence, I think "where" is better but which is not wrong, as where refers to the location of the station and which refers to the station itself.  So, from where in this means "from at the station" or "from where the station is" and from which means "from the main station".  Did I distinguish between them correctly?  Any advice is welcome.  Thanks in advance.

The following is an excerpt from a New York Times article of April 6.     “Tonight, I ordered a targeted military strike on the air base in Syria from where the chemical attack was launched,” Mr. Trump said in remarks at his Mar-a-Lago estate in Florida. “It is in this vital national security interest of the United States to prevent and deter the spread and use of deadly chemical weapons.”    Shouldn't that "from where" be either "from which" or else just "where" without "from?"


Considering RSA, $n=p\,q$ with $p,q$ odd primes and the public key $(n,e)$,  where $\gcd(e,\phi(n))=1$,  I need a hint on how to show that the number of plaintexts with $E_e(x)=x$ equals  $\gcd(e-1,p-1)\cdot gcd(e-1,q-1)$. So we are searching for the number of plaintexts that remain unchanged by the encryption function using the public key.

For every RSA-cryptosystem, there exist some messages $m$, for which it holds that $m^e \equiv m \pmod n$ As to the question, how many such messages exist, this question has already been asked and answered here:  However, I do only understand the answer up to a certain point Suppose that $n$ is only 1 prime. Then it holds that the number of unconcealable messages is $\gcd(e-1, p-1)+1$ This is because in $m^e \equiv m \pmod  p$ , either $m = 0$ or $m \not= 0$. In the latter case $m$ can be expressed as $g^t$, where $g$ is a Generator in $\mathbb{Z_p}$ $g^{t*e} \equiv g^t \pmod p$ $g^{t(e-1) \bmod p -1 } \equiv g^{0 \bmod p -1} \pmod p$ $t(e-1) \equiv 0 \pmod {p-1} $ has exactly $\gcd(e-1, p-1)$  solutions, so the total number of unconcealable messages is, together with $m=0$ , $\gcd(e-1, p-1)+1$ When we now look at real RSA, which has two prime factors in its modulus, it holds that the number of unconcealable messages is $(\gcd(e-1, p-1)+1)\cdot(\gcd(e-1, q-1)+1)$ Why is that so? I suppose it has to do with CRT, but I just cant understand why.


I'm using Ubuntu 20.04 LTS and I noticed this issue recently. I cannot open a terminal in a directory by right clicking in the directory and selecting "Open in Terminal". However, I'm able to launch the terminal from applist and cd to any directory. What can be the issue?

I am working on Ubuntu 12.04 64bit.  I want to add "Open terminal here" to Nautilus context or right-click menu but it tries to download 32bit version from Internet.


Which is correct, re capitalization of the word "mayor"?  San Francisco Mayor John Doe ...  San Francisco mayor John Doe ...

Is the word "mayor" capitalized when it follows the city name?  As in, San Francisco Mayor John Doe   or San Francisco mayor John Doe?


What is recommended to use, passing a structure as a pointer to const i.e.    int doCalculations(const MyStruct* my_struct);    or passing the struct by value, as in,    int doCalculations(MyStruct my_struct);    and why?  In C++ I recall reading somewhere that passing references to const should be used when the struct/Class has a non-trivial constructor. In C although there are no constructors, I imagine it would still take some time to make a local copy of the struct.

Are there any downsides to passing structs by value in C, rather than passing a pointer?  If the struct is large, there is obviously the performancd aspect of copying lots of data, but for a smaller struct, it should basically be the same as passing several values to a function.  It is maybe even more interesting when used as return values. C only has single return values from functions, but you often need several. So a simple solution is to put them in a struct and return that.  Are there any reasons for or against this?  Since it might not be obvious to everyone what I'm talking about here, I'll give  a simple example.  If you're programming in C, you'll sooner or later start writing functions that look like this:  void examine_data(const char *ptr, size_t len) {     ... }  char *p = ...; size_t l = ...; examine_data(p, l);   This isn't a problem. The only issue is that you have to agree with your coworker in which the order the parameters should be so you use the same convention in all functions.  But what happens when you want to return the same kind of information? You typically get something like this:  char *get_data(size_t *len); {     ...     *len = ...datalen...;     return ...data...; } size_t len; char *p = get_data(&len);   This works fine, but is much more problematic. A return value is a return value, except that in this implementation it isn't. There is no way to tell from the above that the function get_data isn't allowed to look at what len points to. And there is nothing that makes the compiler check that a value is actually returned through that pointer. So next month, when someone else modifies the code without understanding it properly (because he didn't read the documentation?) it gets broken without anyone noticing, or it starts crashing randomly.  So, the solution I propose is the simple struct  struct blob { char *ptr; size_t len; }   The examples can be rewritten like this:  void examine_data(const struct blob data) {     ... use data.tr and data.len ... }  struct blob = { .ptr = ..., .len = ... }; examine_data(blob);  struct blob get_data(void); {     ...     return (struct blob){ .ptr = ...data..., .len = ...len... }; } struct blob data = get_data();   For some reason, I think that most people would instinctively make examine_data take a pointer to a struct blob, but I don't see why. It still gets a pointer and an integer, it's just much  clearer that they go together. And in the get_data case it is impossible to mess up in the way I described before, since there is no input value for the length, and there must be a returned length.


I have a script which process some information coming from a web page. I guess that because of the encoding of the page, some special characters are encoded in hexadecimal. For example, I have the the string "%2f" that should be translated to "/".  How can I, in bash, translate those special characters in hex to ASCII? Any ideas?

I want to decode URL encoding, is there any built-in tool for doing this or could anyone provide me with a sed code that will do this?   I did search a bit through  and on the internet but I couldn't find any command line tool for decoding url encoding.  What I want to do is simply in place edit a txt file so that:   %21 becomes ! %23 becomes # %24 becomes $ %26 becomes & %27 becomes ' %28 becomes ( %29 becomes )   And so on.


I have a 23-hour layover in London. I have a valid US visa. Which UK visa do I need for sightseeing during the layover time?

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


When walking, if I apply a force of 2N on the earth, the earth applies a force of 2N back on my feet due to Newtons 3rd Law of Motion. These 2 forces are equal in magnitude but opposite in direction, so they negate each other and add up to zero. So how can we move then if the net force adds up to zero?

Given Newton's third law, why is there motion at all? Should not all forces even themselves out, so nothing moves at all? When I push a table using my finger, the table applies the same force onto my finger like my finger does on the table just with an opposing direction, nothing happens except that I feel the opposing force. But why can I push a box on a table by applying force ($F=ma$) on one side, obviously outbalancing the force the box has on my finger and at the same time outbalancing the friction the box has on the table? I obviously have the greater mass and acceleration as for example the matchbox on the table and thusly I can move it, but shouldn't the third law prevent that from even happening? Shouldn't the matchbox just accommodate to said force and applying the same force to me in opposing direction?


I've recently downloaded .ipsw file (firmware 7.0.6) and want to update my apple 4s 32 gig phone (ios 5). but when I tried to to use iTunes (holding shift key in windows 7 + press update button in iTunes -> choose .ipsw file for update) I got the error below :             What does this error mean and how can I fix it? I've downloded iTunes 11.2 (latest version)     Extra questions:  I am certainly sure there is no problem about my internet or hosts file. I turned my anti virus & firewall off and after that still got that error. Is it possible to transfer .ipsw file to my phone and run it from there? If yes, where should I copy that file and how can I run it? If no what is the solution and how can i fix that error?

I'm trying to downgrade my iPhone from the current iOS to an older one, as per .  But every time I try, I always receive this error:     The iPhone could not be restored. This device isn't eligible for the requested build.     I have tried many times with and without DFU mode. Any ideas regarding this?


I already defined the array of objects size. But whenever I try to set name for a customer an error happens . Here is my code  :      public static void main(String[] args) {      int customerNum, mainChoice;      System.out.println("Enter Total Number of Customers Using your System : ");     Scanner input = new Scanner(System.in);     customerNum = input.nextInt();     Customer[] customersArray = new Customer[customerNum];     mainMenue();     mainChoice = input.nextInt();      if (mainChoice == 1) {         String askLoop = null;          for (int i = 0; i < customerNum; i++) {             System.out.println("Enter customer name : ");             customersArray[i].setName(input.next());             System.out.println("Enter customer phone number : ");             customersArray[i].setPhoneNumber(input.next());             System.out.println("Do you want to Add another Customer (y/n)");             askLoop = input.next();             if (askLoop == "y") {                 continue;             } else {                 break;             }          }      }  class Customer{ private String name; public void setName(String name){ this.name = name;     } }   When I run it then I input the name the program stops and this error is displayed :   Exception in thread "main" java.lang.NullPointerException     at ba_1316855_p4.BA_1316855_P4.main(BA_1316855_P4.java:30)  How can I solve this ?

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?


When someone questions how light can re-accelerate after slowing down in a glass medium, the common answer is that it never really slows down, it is absorbed by the atoms and then released.  Have there been any confirmations that this is the reason why light appears to slow down, or is this speculation, the best guess we have?  I'm thinking the apparent speed reduction could be estimated by knowing the density of the glass and calculating in the absorption/emission time?

I know that if we solve the Maxwell equation, we will end up with the phase velocity of light being related to the permeability and the permittivity of the material. But this is not what I'm interested in - I want to go deeper than that. We know that the real speed of light is actually not changing, the decrease in speed is just apparent. Material is mostly empty, the light will still travel with $c$ in the spacing. The rare atoms will disturb the light in some way. So I am interested in how the atoms affect the light. Photon absorption-emission theory Some textbooks that I read explain it in a way kind of like this: In a material the photons are absorbed by atom and then re-emitted a short time later, then they travel a short distance to the next atom and get absorbed&emitted again and so on. How quickly the atoms in a material can absorb and re-emit the photon and how dense the atoms decides the apparent speed of light in that material. So the light appears slower because it has a smaller “drift speed”. Interference theory But recently I realize an alternative explanation: Atoms respond to the light by radiating electromagnetic wave. This “new light” interferes with the “old light” in some way that results in delayed light (advanced in phase), this can easily be shown by using simple phasor diagram. Consequently effectively the light covers a smaller phase each second, which gives the impression of a lower phase velocity. However the group velocity is changing in a complicated way. I think that the first explanation does not explain the change in phase velocity of light. if we consider light travelling into a slab of negative refractive index non-dispersive material, let’s say the light is directed perpendicular to the slab. The phase velocity’s direction will be flipped, but group velocity’s direction in the material will not change. Only the second explanation can explain the flipped phase velocity direction. I guess that the velocity that we get in the first explanation is actually belongs to the group velocity. It makes sense to me that the front most of the photon stream determines the first information that the light delivers. So the question is What really cause the phase velocity of light to be decreased?  "drift velocity" of photons (they aren't the same photons, they are re-emitted all the time) phase difference between absorbed and emitted light something else  And also, I still don't really understand detailed explanation of the absorption-emission process for small light's wavelength (for large lambda compare to the atoms spacing, the photons will be absorbed by the phonons). The dispersion relation that we know is continuous and also some material is non-dispersive, therefore the absorption process must occur in all frequency for a certain range. So definitely it doesn't involve the atomic transition, otherwise it will be quantized. My guess is that the relevant absorption process gets smooth out by the dipole moment. What makes the spectrum continuous? EDIT: link for dispersion relation:


Let $(X, \tau_1)$ and $(Y, \tau_2)$ be topological spaces. Is it true that if $X$ is homeomoprhic to a subset of $Y$ and $Y$ is homeomorphic to a subset of $X$ then $X$ and $Y$ are homeomorphic spaces? I'm trying to find a counter-example cause I don't believe that the statement is correct, however I'm struggling since I don't know that many homeomorphisms. An idea I had is to prove that a subset of $\mathbb{R}$ is homeomorphic to a subset of $\mathbb{R^2}$ and the other way around but $\mathbb{R}$ and $\mathbb{R^2}$ are not homeomorphic.

Let $A$ , $B$ be topological spaces such that there for some subset $D$ of $B$ there is a homeomorphism form $A$ to $D$ and for some subset $E$ of $A$ there is a homeomorphism form $B$ to $E$ ; then must there exist a homeomorphism from $A$ to $B$ ?


I am doing a course in Abstract Algebra, and my teacher gave me a question: "Find all possible group structures on a set X whose cardinality is ≤ 4."  I know basic group theory, but I am unable to understand what exactly does the question expect us to do (meaning of the question in simple language, and a possible technique or way to answer such questions, exact answer not needed.)

I should consider group tables obtained by renaming elements as essentially the same and then show that there are only two essentially different groups of order 4.  There seems to be so many different possible group tables for all the different binary operations - which is why I'm confused. I was thinking about using Cayley's table to show their commutativity but I'm really not too sure. Any help please!   Edit: After all of your help, I completely understand how to show that there are only two different groups of order four. Thank you. The only thing which I am still unclear of is how to note down the 'other tables' before stating that they are essentially the same as one of the other tables - meaning that there are just two different ones. It's pointless work but I think it's what the question requires.  Answer: After a bit of playing around - I've realised that there are four different tables, however, 3 tables are the same as each other, just with different values (the Klein 4 Group with 3 different generators). Hence there are two tables.


Maybe is a dumb question, but I was always confused about the wave-particle duality, what if particles are just an interpretation of our brains? is that possible? that everything is actually a wave, and in just scenarios those waves acts like our concept of particle?        Asking it in another way: do we need particles? as a real thing? or the universe could be just waves and nothing else?

Reading about photons I hear different explanations like "elementary particle", "probability cloud", "energy quanta" and so forth. Since probably no one has ever seen a photon (if "seen" it supposedly - and rather conveniently - ceases to exist) but many experiments seem to verify its properties (or are they maybe adjusted to fit the experiment). I thus can't help wondering if the "photon" is then just a physical/mathematical tool with inexplicable properties (like zero mass - but affected by gravity fields - and constant speed c in space) invented to explain some otherwise unexplainable phenomem and to supplement the elementary particles and their interactions. In short: Are they real or imaginary!  Does anybody know? Or maybe the answer is "blowing in the wind" because to most physicist it probably just does'nt matter as long as it works (as the alternative healers say). Sorry if I seem a little sarcastic here and there.


In my project I have seen the performance issues if we include collection fields in hashCode() and equal() methods.Is it mandatory to include or not? Below is the sample program.  Student.java  public class Student {     int no;     String name;     String adress;     Set < Parent > parent;         public int hashCode() {         final int prime = 31;         int result = 1;         result = prime * result + ((adress == null) ? 0 :         adress.hashCode());         result = prime * result + ((name == null) ? 0 : name.hashCode());         result = prime * result + no;         result = prime * result + ((parent == null) ? 0 :         parent.hashCode());         return result;     }       public boolean equals(Object obj) {     if (this == obj)         return true;     if (obj == null)         return false;     if (getClass() != obj.getClass())         return false;     Student other = (Student) obj;     if (adress == null) {         if (other.adress != null)             return false;     } else if (!adress.equals(other.adress))         return false;     if (name == null) {         if (other.name != null)             return false;     } else if (!name.equals(other.name))         return false;     if (no != other.no)         return false;     if (parent == null) {         if (other.parent != null)             return false;     } else if (!parent.equals(other.parent))         return false;     return true; }        }

What issues / pitfalls must be considered when overriding equals and hashCode?


I'm trying to do an independent project for my Math class, but I was stuck and couldn't figure out how to use optimization to find position along the sideline that gives the widest angle to shoot. As in the picture, A and C demonstrate positions that provide smaller angle to shoot, while B provides a wider angle to shoot. I tried using law of cosine, but because both sides of triangles change every times I didn't know how to apply optimization to it :(  if anyone know, please help, any suggestion would be appreciate


Is there a continuous function constructed by elementary functions, or by integral formula involved only elementary functions (like Gamma function) that grows faster than any $e^{e^{e...^x}}$ ($e$ appears $n$ times)?  I ask for the answer with a single formula. Gluing continuous function together is too trivial.  The function need not to be defined on whole $\mathbb{R}$, the domain $(a, \infty)$ is acceptable.

This started off with me goofing off on Twitter and quickly led to this question to which I didn't know the answer.  Let $T_2(x) = x^x$, $T_3(x) = x^{x{^x}}$, $T_4(x) = x^{x^{x^x}}$, and so forth.  Is there a $C^{\infty}$ elementary function $f(x)$ (it can be piecewise-defined) with $\displaystyle \lim\limits_{x \to \infty} \frac{f(x)}{T_k(x)} = \infty$ for all $k$? If so, what is a (possibly piecewise-defined) formula for such an $f$?


Is there any app which allow any windows (safari / Text edit) to remain on top, even in full screen ?  From what I search, afloat used to be a good solution but with random result.

I am looking for a stable way to keep any window 'always on top' on OSX.  , an app that does that requires SIMBL/easySIMBL, which it seems is not very stable.  Are there any better solutions? It's actually surprising that there is no native way to implement this.


I have about 30 tests in directory GameTests. There is a test like DeleteGameTest which is based on static ID (private const GAME_ID = '...') but PHPUnit runs this tests in alphabetical order. I was tried to organise them by testsuite but 30 items in this suite makes little mess. Is it possible to run this single test always last without setting it's name to starts with 'Z' letter?

Is there a way to get the tests inside of a TestCase to run in a certain order? For example, I want to separate the life cycle of an object from creation to use to destruction but I need to make sure that the object is set up first before I run the other tests.


Given that mirrored Storage Spaces provide automatic corruption detection and repair, is space efficiency the only compelling advantage of parity over a mirror?   I am thinking that the poor write performance of parity justifies the relatively cheap cost of storage overhead incurred in a mirror.

This is a  about RAID levels.    What are:   the RAID levels typically used (including the RAID-Z family)?  deployments are they commonly found in? benefits and pitfalls of each?


I want to remove this folder :  Name Name 1x05 name FormaciÃ³n  I have tried all I have seen on internet :   find -maxdepth 1 -inum INODE_NUMBER -exec rm -i {} \; rmdir: wrong deleting './Name Name 1x05 name FormaciÃ³n': don't exist file or folder   Too I tried to use mc (Middnight Commander) , Krusader and any other methods I have seen on internet.  But is not posible. Give this problem.  We can enter in folder and to rename parent but we can't rename or delete this folder.  The problem is because is a folder with spaces and wrong chars and is not posible to change it. You can enter on folder but you can't remove or rename.  So is not duplicated. There is not any solution for this case on StackSchange.   I think the only solution would be edit directly inode to make renaming and be able to remove later, but I don't know how to do on Unix system.  System is Ubuntu but I suppose would be in any other system.  Any method to delete this folder or to edit directly folder name ?  Thanks.

I have the following files (output of ls -l):  ?rw-------  6144 1684128777 2049835008 50331648 Jan  1  1970 image1.jpg br-xrwSrw- 25120 1987343475 1936028517 110, 110 May 30  2032 image2.jpg ?--------- 25966  774963978 1954164340      187 Apr  8  1996 image3.jpg br--r-xrwT  9776  892169583  859126070  80,  76 May 19  1999 image4.jpg c--xr-xrw- 25967 1852137846 1931502624  77,  32 Nov 15  2031 image5.jpg   A normal file in the same directory looks like:  -rw-r--r--     1 apache     apache       198849 Jan 29 21:45 image6.jpg   I already tried to remove those weird files with rm -f but I got the error:  rm: cannot remove `image1.jpg': Operation not permitted   When I try to check the flags/remove immutable flag with lsattr and chattr then I get the following errors:  lsattr: Operation not supported While reading flags on image1.jpg chattr: Operation not supported while reading flags on image1.jpg   Questions   What is going on here? These files seem corrupt? How can I remove/fix these files?


Date              12/4/2014  411,324,665 13/4/2014  422,334,567,7788          This is the result of the procedure, I have to select the invoices grouped by invoice date but how can I put the invoice numbers (of the invoices that have the same date) in a single column separated by a , ?  Please help and thank you

I'm trying to migrate a MySQL-based app over to Microsoft SQL Server 2005 (not by choice, but that's life).  In the original app, we used almost entirely ANSI-SQL compliant statements, with one significant exception -- we used MySQL's group_concat function fairly frequently.  group_concat, by the way, does this: given a table of, say, employee names and projects...  SELECT empName, projID FROM project_members;   returns:  ANDY   |  A100 ANDY   |  B391 ANDY   |  X010 TOM    |  A100 TOM    |  A510   ... and here's what you get with group_concat:  SELECT      empName, group_concat(projID SEPARATOR ' / ')  FROM      project_members  GROUP BY      empName;   returns:  ANDY   |  A100 / B391 / X010 TOM    |  A100 / A510   So what I'd like to know is: Is it possible to write, say, a user-defined function in SQL Server which emulates the functionality of group_concat?   I have almost no experience using UDFs, stored procedures, or anything like that, just straight-up SQL, so please err on the side of too much explanation :)


Let us consider the differential equation \begin{equation} y''=\frac{y'}{2\sqrt{y}}\;\; (y>0) \end{equation} 1). Prove that every non-constant solution is strictly monotone;  2). Consider the Cauchy problem \begin{equation} \begin{cases} y''=\frac{y'}{2\sqrt{y}}\\ y(0)=u\\ y'(0)=v \end{cases} \end{equation} Determine the set of points $(u,v)\in \mathbb{R}^+\times\mathbb{R}$ s.t. the maximal solution to the problem is non constant and defined on the whole real line $\mathbb{R}$. For these points $(u,v)$, determine the limits of the solution for $t\rightarrow \pm \infty$.  For the first point I supposed $y'(t_0)=0$ so that $y''(t_0)=0$ whence the constant solution $y\equiv y(t_0).$ Could it work?   For the second point, I have integrated the differential equation by using the initial conditions but I don't know how to proceed...

I'm struggling in solving this problem. We are given the differential equation $\displaystyle y''=\dfrac{y'}{2\sqrt{y}}$.   We are asked to prove:  a) Any nonconstant solution is strictly monotone.  b) Let's consider the Cauchy Problem  $$\begin{cases}y''&=&\dfrac{y'}{2\sqrt y}\\[6pt] y(0)&=&u\\[6pt] y'(0)&=&v.\end{cases}$$  Find all points $(u,v)\in\mathbb R_+\times \mathbb R$ such that the maximal solution is nonconstant and defined on the whole real line. For such points $(u,v)$ compute the limits of the solution as $t\to\pm\infty$.  Thanks in advance to anybody who will reply.  -Mario-


If $X_i$, $i=1,2$ are independent gamma$(\alpha_i,1)$ random variables, find the distribution of $\frac{X_1}{X_1+X_2}$ and $\frac{X_2}{X_1+X_2}$.  Attempt: Let $Y_1 = \frac{X_1}{X_1+X_2}$ and $Y_2=X_1+X_2$.  Then $X_1 = Y_1Y_2$ and $X_2 = Y_2-Y_1Y_2$.  The Jacobian matrix is :  $\hspace{15mm}J = \left| \begin{array}{ccc} y_2 & y_1 \\ -y_2& 1-y_1 \\  \end{array} \right| = y_2$  I'm having trouble plugging the values back in to the gamma equation. Since we want to know the distribution of $Y_1$, do we first find the joint distribution of $f_{y_1,y_2}(y_1,y_2)$ and then integrate $y_2$ out?

According to Wikipedia, the  is related to the gamma distribution by the following relation:  $$\lim_{n\to\infty}n B(k, n) = \Gamma(k, 1)$$  Can you point me to a derivation of this fact? Can it be generalized? For example, is there a similar relation that results in something other than a constant 1 for the Gamma second parameter? What if we have  $$\lim_{n\to\infty,m\to\infty,n=mb}n B(k, m) $$  That is, the two variables go to infinity while maintaining a constant ratio b.  The reason I'm asking is because I'm trying to figure out how to simplify a hieraerchical bayesian model involving the beta distribution.  (This is my first post; sorry for the math notation, the MathJaX syntax was too daunting, but I'll try to learn)


I am trying to create a DateTime from a custom string however I am getting the error:      String was not recognized as a valid DateTime.   DateTime date = DateTime.ParseExact("Thu Feb 23 23:36:01 EST 2017", "ddd MMM dd hh:mm:ss K yyyy", CultureInfo.InvariantCulture);   Any suggestions on where I am going wrong?

I'm trying to parse an international datetime string similar to:  24-okt-08 21:09:06 CEST   So far I've got something like:  CultureInfo culture = CultureInfo.CreateSpecificCulture("nl-BE"); DateTime dt = DateTime.ParseExact("24-okt-08 21:09:06 CEST",     "dd-MMM-yy HH:mm:ss ...", culture);   The problem is what should I use for the '...' in the format string? Looking at the  MSDN page doesn't seem to list a format string for parsing timezones in PST/CEST/GMT/UTC form.


Anyone else see this? Is this just me or is it Chrome? The bars on the lower reputation chart show in white when Chrome is set to 100% zoom. in IE8 it looks fine. The screenshot shows IE at the top and Chrome at the bottom.     When I zoom out, the bars get faintly green  at 90%    The more I zoom in, the more bars become green. Following three screenshots are at 110%, 125% and 150% resolution.      Can anyone else repro this? I see this on all sites I have an account with.  Running Chrome 29.0.1547.57 m on Win 7 Enterprise, SP1

As you can see, if you go to the reputation graph on your profile on Stack Overflow, the bars in the bottom overview will be white. This makes them invisible unless they are selected.  Eeek!  This does not happen on meta or any other site. Also, I cannot seem to reproduce it on others' profile. Possibly a bug only on your own profile? EDIT: I think I've existed for too long. If I change the CSS on one of the bars to stroke: none, then it becomes green. I think the outline is covering the fill because the bars are too skinny. EDIT2: Confirmed hypothesis by reproducing on Jon Skeet's graph. Proposed solution: enforce minimum bar width and add horizontal scrollbar. EDIT3: Can only repro on Chrome 29.0.1547.57 (Official Build 217859) m (the latest version). Norepro on older versions of Chrome, IE9 (winces), all versions of FF, and all versions of Safari. EDIT4: Can be fixed simply by running the JavaScript $('rect').css('stroke-width', '0') or a userstyle rect { stroke: none }. I may make a user[style|script] to fix this.


I'm trying to figure out monads in Haskell but didn't get too far yet.  I found  and several other tutorials/explanations, but none seems to be explaining the difference between the type constructor and the return function.  As I understood the   type constructor constructs a monad from a given value of the basic data type. So it's sort of a normal constructor like in Java, which builds from the given parameter a new instance. return function applies the type constructor on the given value of the basic data type and returns the constructed monad.   So what's the point of having two functions doing basically the same?  EDIT So using the example of a Maybe-monad, the   country = Just "China": (constructor) creates the monad for the value "China".  return "China": returns the monad which is corresponding to the value of China, so it's basically the monad containing the "China" value.   Generally speaking I understand a monad as a container for values.  One usage of monads is to combine simple/existing computations to more complex computations.

Having briefly looked at Haskell recently, what would be a brief, succinct, practical explanation as to what a monad essentially is?  I have found most explanations I've come across to be fairly inaccessible and lacking in practical detail.


I have several pdfs, of which my pdf-viewer can show the outline, like in this example:     While this is a great feature, there are unfortunately some pdfs, that have no such feature implemented!     Only bookmarks can be added, but for me that is not an option, because it‘s a viewer-dependent solution. For some books, it would be very helpful to  have such an outline, so i thought about adding that myself, but i couldn‘t find any program, script or different solution except for Adobe Acrobat Pro, which is much too expensive for me.   Does anyone know something that suits my problem? A Linux solution would be prefered.

How can I edit the Table of Contents of a PDF file on Linux? I tried pdfedit but I can't find where the content table list is stored.


The dimension of a topological space $X$ is defined to be the length of the maximal chain of closed irreducible subsets $\varnothing \neq X_0 \subsetneq X_1 \subsetneq ... \subsetneq X_n \subset X$.   Let $A$ be a subset of topological space $X$, how can I show that dim$A$ $\leq$ dim$X$?  I can show that given a chain of closed irreducible subsets of $A$, $A \cap X_0 \subsetneq ... \subsetneq A \cap X_n$, where $X_0,...,X_n$ are closed subsets of X, we can get a chain of closed subsets $X_0 \cap... \cap X_n \subsetneq ... \subsetneq X_{n-1} \cap X_n \subsetneq X_n$ of $X$ of the same length, but I am having trouble showing the subsets are irreducible. Any help is appreciated!

Let $X$ be topological space and $Y\subset X$. The goal is to show that $\dim Y\leq \dim X$.   Here we use this definition of dimension.  Let $Y_0\subsetneq Y_1\subsetneq \cdots \subsetneq Y_{n}$ be a chain of strictly increasing closed irreducible subsets of $X$ then $\dim X$ is the supremum over all such chains.   This is what I've got so far. I'm just stuck on one last bit. A hint would be nice.   Let $Y_0\subsetneq Y_1\subsetneq \cdots \subsetneq Y_n$ be a chain of irreducible closed subsets of $Y$. Since each $Y_i$ is irreducible, we just need to close them in $X$. There exists $F_i$ closed in $X$ such that $Y_i=F_i\cap Y$. Then if we closed each set in $X$, $\overline{F_0\cap Y}\subset\overline{F_1\cap Y}\subset \cdots \subset \overline{F_n\cap Y}$ is a chain of irreducible closed subsets of $X$. I just need to show that they are distinct. I really don't know where to proceed. A hint would be appreciated. Thanks.


I have always used adiabatic process to be fast, so that the system doesn't get enough time to exchange energy in the form of heat. But as I was reviewing adiabatic process from the Resnick, Halliday, & Krane book, the authors claim that:     we assume the process to be carried out slowly, so that the pressure   is always well defined.   Now this is completely out of sync what I already know and most web searches also agreeing with adiabatic process being fast.    Which one is right?

As per my understanding, all adiabatic processes carried out in absence of an adiabatic wall need to be fast enough so that there is no heat exchange with the surrounding. Similarly, all isothermal processes are slow so that thermal equilibrium can be established with the surroundings in order to maintain a constant temperature in the system.   But then since isothermal processes are slow, how are isothermal irreversible processes possible?   Is my notion that 'irreversible processes are fast' wrong?


Consider the subset $\mathbb{Q}[\sqrt2]:=\{x+\sqrt{2}y\mid x,y\in\mathbb{Q}\}$ of $\mathbb{R}$, together with the addition and multiplication usual/common in $\mathbb{R}$      (Does this mean that the operations $(+)$ and $(\cdot)$ are from $\mathbb{R}$ ?).   Is $\mathbb{Q}$ a field? Prove your testimony.  If you want to find a neutral element $e$ for multiplication, such that $e\circ x=x$, you will get stuck:  \begin{align} e\circ x&=x\\ (x+y\sqrt2)\cdot(z+w\sqrt2)&=z+w\sqrt2\\ e=(x+y\sqrt2)&=1\qquad\qquad \forall x\neq0 \end{align}  If you want to find an inverse element for multiplication $a^{-1}$ such that $a\circ a^{-1}=e$, you will get stuck: \begin{align} (a+\sqrt2b)\cdot a^{-1}&=1\\ a^{-1}&=\frac{1}{a+b\sqrt2} \qquad\qquad\forall a\neq0 \end{align} Is this the point where I can say, that $\mathbb{Q}[\sqrt2]$ is not a field, because you can't find a neutral and inverse element for all elements in $\mathbb{Q}$?

Show that the set $\mathbb{Q}[\sqrt{2}] = \{a + b \sqrt{2} \mid a, b \in \mathbb{Q}\}$ is a field with the usual multiplication and addition.  It is easy enough to show that it is closed under addition and multiplication ( $\forall a,b \space)$ we have $a+b \in \mathbb{Q}\sqrt{2}$ and $a * b = ab \sqrt{2} \in \mathbb{Q}\sqrt{2}$.  However, I had trouble proving the other axioms (associativity, commutativity, unique neutral element, unique inverse, and distributivity of multiplication over addition). I would really appreciate it if someone could help me with those.


If I throw a ball at the wall, when it has travelled halfway, it still has half the distance to travel. As it continues, the fraction left to travel continues i.e. one quarter to go, one eighth to go, one sixteenth to go, etc. since the denominator of the distance continues to double... I am thinking mathematicaly speaking, the ball never reaches the wall.

A brief description of the paradox taken from :     Suppose Sam wants to catch a stationary bus. Before he can get there, he must get halfway there. Before he can get halfway there, he must get a quarter of the way there. Before traveling a quarter, he must travel one-eighth; before an eighth, one-sixteenth; and so on.      This description requires one to complete an infinite number of tasks, which Zeno maintains is an impossibility. This sequence also presents a second problem in that it contains no first distance to run, for any possible (finite) first distance could be divided in half, and hence would not be first after all. Hence, the trip cannot even begin.      The paradoxical conclusion then would be that travel over any finite   distance can neither be completed nor begun, and so all motion must be   an illusion.   How can this be disproved using math, as obviously we can all move a walk from one place to another?


How to find the sum of infinite series $\sum_{n=0}^{\infty}nx^n$? I have no clue where to begin with.

I am trying to find a closed form solution for $\sum_{n\ge0} nx^n\text{, where }\lvert x \rvert<1$.  This solution makes sense to me:  $\sum_{n\ge0} x^n=(1-x)^{-1} \\ \frac{d}{d x} \sum_{n\ge0} x^n = \frac{d}{d x} (1-x)^{-1} \\ \sum_{n\ge0} nx^{n-1} = (1-x)^{-2} \\ x \sum_{n\ge0} n x^{n-1} = x(1-x)^{-2} \\ \sum_{n\ge0} nx^n=\frac x{(1-x)^2}$  However, a  I am reading used the following method:  $$\sum_{n\ge0}nx^n=\sum_{n\ge0}x\frac d{dx}x^n= x\frac d{dx}\sum\limits_{n\ge0}x^n=x\frac d{dx}\frac1{1-x}=\frac x{(1-x)^2}$$  This seems closely related to the solution I described above, but I am having difficulty understanding it.  Can someone explain the method being used here?


Let B denote the closed unit ball inside $\mathbb R^n$. Let x and y be two points inside interior of B.  Prove that there exists a homeomorphism $B \to B$ sending x to y and fixing the boundary of B.  My idea is without loss of generality assume that $x=0$ (origin). Then "push radially towards y". How can I formalise this using equations? Or maybe give an existence proof?

Let $D^n$ be the closed unit disk in $\mathbb{R}^n$. I'm looking for a homeomorphism of $D^n$ to itself which is the identity on the boundary, and takes the origin to a given point $z$ in its interior. I can visualize such a function as "shifting around the mass" within $D^n$, but I can't seem to write one down.


My understanding is that I should usually avoid using onclick in HTML, since is better to keep separate HTML structure and JS logic. However in this case, I have an application where the user can search for records and the results are displayed in divs dynamically generated from a php file using AJAX. In each div there is a button which when is clicked must perform a JS function and the function argument is the record unique id. My point is: how could i select a dynamically created button with vanilla JS, since it does not exist when JS is loaded?

I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off.  This happens on page ready and works just fine.  The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound.  I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option.


I'm relatively new to this site and love it! I want to contribute, but I can't until I get more reputation points. What is the best way to legitimately gain reputation points here on Stack Overflow?

From "6 Simple Tips to Get Stackoverflow Reputation Fast" at codexon.com:   Be the First to Answer. Even at the cost of quality. Use Downvotes and Comments Strategically Use obnoxious in-your-face formatting and lists. Be Aware of the 200 rep/day Limit Edit, But Don’t Edit Too Much Associate your other accounts   Courtesy of . Agree? Disagree? Walnuts? Cantaloupe?


I understand that composite particles with integer spin form a boson. For example a helium nucleus is a boson because it has 2 protons and 2 neutrons.  If all of the components on their own are fermions, which mean they can not occupy the same space, how can combining them allow them to now occupy the same space?  I guess my question is: Is there an "intuitive" explanation for this behavior, or is the answer just the integer spin always equals boson?

It is generally assumed that there is no limit on how many bosons are allowed to occupy the same quantum mechanical state. However, almost every boson encountered in every-day physics is not a fundamental particle (with the photon being the most prominent exception). They are instead composed of a number of fermions, which can not occupy the same state.  Is it possible for more than one of these composite bosons to be in the same state even though their constituents are not allowed to be in the same state? If the answer is "yes", how does this not contradict the more fundamental viewpoint considering fermions?


I mostly work on Mac but have a Windows problem:  I need to prevent access to specific files to all (even administrator). I'm running a local nodeJs server app, and need to prevent access to the main script. In short I need to prevent tempering with the program.  I know IIS has 'special' users for example, preventing access from any 'standard user', but not sure that prevents access from an admin.   Is there any way to prevent access to a file even to an administrator?  Special User permissions?  My guess is that an admin would always be able to change user permissions, so I'm not sure it's possible but there may be 'special' accounts that can be used?  Any hints / direction as to where to look would be appreciated.  Thanks

My surface tablet is shared with a friend. She uses a separate account, with admin rights.  Being an admin, she is able to gain access to all my files. Even my OneDrive files.   I guess I could follow  to prevent this (it basically states that you'll need to disable access for the targeted administrator), but the same scenario would be present if I were to create another administrator account.  You could say "don't make her administrator", but I don't want to mess with her personal files as well.  Somehow this feels as a security flaw... or am I mistaken?  Is there any way to protect private files from "administrator eyes" by default?


I have Tamron 90mm f/2.8 Macro Lens on my Nikon D5500. I’m trying to get my aperture to go to its lowest which is 2.8, however, I can’t get it to go lower than 3.0 or 3.5 (its lowest changes often and I’m not sure why). I’ve tried it both Aperture priority mode and Manual.  Any advice would be greatly appreciated.

I have found that my Nikon 60mm Micro AF-D changes aperture from 2.8 to 3.2 when used with a D90. I have tried both A and M mode. Is it by design? Why?  I intend to buy  and it will lock the maximum aperture at 2.0 (my guess) instead 2.8. So should I buy it or not, or would it be better to buy the newer 50mm 1.4 AF-S version?


I have been struggling with correctly aligning HTML checkboxes and labels for a while now.  I have finally managed to get 2 checkboxes on the same line with labels to the right of the checkboxes.  I have one final problem to solve. The labels and the checkbboxes to do not align perfectly-the labels are a tiny bit higher than the checkboxes-see image:    It is a minor problem, but I think it is better to solve it.  The HTML is below:          <%= oUtils.GetContentText("Collect_Config_Expense_return") %>
         <input type="checkbox" onclick="fnOnCheck(ER_Enable)" id="ER_Enable" class="fl" style="width:15px; margin-right:5px; background:transparent; border:0"/><%= oUtils.GetContentText("Collect_Config_Enable") %>         <input type="checkbox" onclick="fnOnCheck(ER_Surpress)" id="ER_Surpress" class="fl" style="width:15px; margin-right:5px; background:transparent;border:0" /><%= oUtils.GetContentText("Collect_Config_Surpress") %>
   I have tried all the usual things eg margins and padding, but they are not having an effect.  Any ideas?

This is one of the minor CSS problems that plague me constantly. How do folks around Stack Overflow vertically align checkboxes and their labels consistently cross-browser? Whenever I align them correctly in Safari (usually using vertical-align: baseline on the input), they're completely off in Firefox and IE. Fix it in Firefox, and Safari and IE are inevitably messed up. I waste time on this every time I code a form. Here's the standard code that I work with:   <form>     <div>         <label><input type="checkbox" /> Label text</label>     </div> </form>    I usually use Eric Meyer's reset, so form elements are relatively clean of overrides. Looking forward to any tips or tricks that you have to offer!


I need to prove the next numbers are irrational:  $$ \sqrt{2}+\sqrt{5} $$ $$\sqrt{3}$$ $$ \log_{2}3  $$  Of course, I tried to prove it with negative evidence...

How do you prove that $\sqrt{2} + \sqrt{5}$ is irrational?    I tried to prove it by contradiction and got this equation:  $a^2/b^2 = \sqrt{40}$.


I am looking for a word (the word, as I know it exists, but I cannot remember it) that characterizes a person who blindly follows the crowd. It is a noun, and I believe it starts with an L – monosyllabic – disparaging – might fit nicely in the phrase: the _________ of Wall Street.

Is there a word for someone who won't think through issues and instead comes to others hoping that they will think for them and solve problems for them?  A word that is more specific to a lack of critical thinking skills than "lazy"?


Subject Share Consolidation Type    Consolidation Description CONSOLIDATION OF EVERY 4 ORDINARY SHARES IN PDZ HOLDINGS BHD ("PDZ" OR THE "COMPANY") ("PDZ SHARES" OR "SHARES") HELD AT 5.00 P.M. ON 4 DECEMBER 2017 ("ENTITLEMENT DATE") INTO 1 PDZ SHARE ("CONSOLIDATED SHARE") ("SHARE CONSOLIDATION") Amount  4 : 1   What is Share Consolidation?  If a share price is $2, I buy it with $5000.     $5000/$2 = 2500units   Share consolidation will make the share units above decrease?     2500units /4 = 625units

In the picture below, Citigroup's stock split 1 to 10. My guess is this means that everyone who had 1 share now has 10 shares? This can't be right though, because the value of the stock after the split should be 1/10th of the value prior to the split. Somebody help me out here.


i have testdata.js file with json test data as below:  testdata.js file:  module.exports =    {         createHost:         {          name : "System-001",         description: "Creating System",      }   }  In another test, I am trying to create a variable called testcase1 with the above test data. Changing the property value in testcase1, changes the value in the testdata.js file json object.  it("Create a host", function(){ var testcase1 = testdata.createHost;  testcase1.name="sys-002";  console.log(testcase1.name); console.log(testdata.createHost.name); });   Response: sys-002 sys-002  My requirement is to create a copy of testdata instead of creating a reference. How can I do this?

What is the most efficient way to clone a JavaScript object? I've seen obj = eval(uneval(o)); being used, but . I've done things like obj = JSON.parse(JSON.stringify(o)); but question the efficiency.  I've also seen recursive copying functions with various flaws.  I'm surprised no canonical solution exists.


Seems like this question should have already been asked on Meta, but I could not find it.     is similar, but my question more has to do with requesting an update on a question that is not mine, rather than what to do once it is updated.  My question is how to get an update on an old question. I found  and the question itself (and the updated comment) is outdated and now useless. I would like to ask the question again however I know it will be tagged as duplicate.   How should I go about getting a completely new set of answers for a question like this?

I'm looking around for answers to my questions on several Stack Exchange sites and the good boy that I am I don't want to ask duplicate questions.  Often I find that there are other people who asked the same questions, sometimes years earlier, but still don't have an answer. I'd figure I could bump these back to top, but if I don't have enough rep for a edit (or comment), how would I do that?  Or, in that case, I should just post a 'newer' version of the same question?


Some words used to have a different meaning. For example, according to this link, here are a list of twenty words that originally had a different meaning from the connotation that we associate it with today. One example would be nice. Before nice meant silly, now nice means that a person is kind or the antonym of mean. Is there a single-word or phrase that describes the phenomenon. It kind of reminds of a paradigm shift in science, when an idea that was thought to be true is changed. For example, the heliocentric theory replaced the geocentric theory.  The link:

What is the term for words that have changed meaning over time? For example, in relation to  the term snafu  and was used to define a person, team, organisation, etc that continually makes mistakes. The first time I saw the term was in relation to a data protection leak and this now seems a pretty common usage e.g  amongst the tech community.  Is there a term to describe words that have changed meaning over time, or words that have been adopted by a particular community and had their meaning altered?


'The similarities between Odelle's and Smith’s artistic depictions of women [...]'  OR  'The similarities between Odelle and Smith’s artistic depictions of women [...]'  The point in question regards the apostrophes. One claim is that the first one on Odelle isn't necessary. It seems like this would be true only if Odelle and Smith were collaborating on their art. However, the intended meaning of the sentence is that both subjects, although similar, each have unique treatment of women in their art. The word that throws me off is depictions. Because this word is plural perhaps the first claim is true? This way Odelle and Smith could still have unique depictions but share the compound subject possession. Really scratching my head over this one...

I understand the rules for dual possessives, but I was writing and I realized that I have no idea how the following sentence should be written.  She and Kevin's house is big.  or  Her and Kevin's house is big.  Normally for a dual possessive, if there is joint possession (two people owning one thing), only the last noun takes the possessive form, but the first sentence sounds and reads awkwardly. Is it actually correct?  The pronoun seems to be the source of the confusion, as I would have no trouble choosing between the following:  Kim and Kevin's house is big. Kim's and Kevin's house is big.  The first would be correct because the house belongs to both Kim and Kevin, so only the last noun, "Kevin", takes the possessive form. Does the same rule apply when one of the nouns is a pronoun, or is there a different rule in such cases? Can someone help me out, please?  Note: I realize that there are similar discussions already:     However, these questions only discuss the proper formation of the first-person pronoun in such cases (i.e., "I" vs. "my"). I'm interested in the rules for correctly forming the third-person pronoun.


One of the sources of visitors to Stack Exchange sites is search engines like Google. When we are shown the results of a question from Stack Exchange sites on Google, we are shown along with a tag. For example, look at below image.     In the above picture, the character tag is shown along with character tag. That is the most popular tag tagged with the question.   Now, there is another example from Google as shown below.     The above question is from Hinduism Stack Exchange where it is shown along with the tag worship. Now, that is not the most popular tag in the question. I have noticed this with other questions too.  The question is how does the system select the tags which are shown with the question in the search engines?  I noticed that these tags accompany in the tabs in the browser too.     So, how does the system select the tags which are to be shown along with the question on search engines like Google?

Which tag is used in the title of a question?   It does not seem to be the most popular It does not seem to be the first in the tagging order:   This question   is prefixed with NGINX (which is actually completely fine)  And it is tagged with "php nginx fastcgi magento" in the order of popularity.  Can we choose the tag to use in the title manually?


I was thinking about this a short while ago, to expand what links onebox in SE chat.  Essentially, anything that has a valid <meta name="description" /> tag should be able to be one-boxed. The <title> could be used for the title of the box, and the meta description tag for the body. This could also (perhaps) be extended to the <meta property="title"> as well (defined by RDFa 1.1), though I suspect this is less common.  Optionally, chat could also support the  (<og:meta>) tags as well. Though these should only be used if the regular HTML <meta> tags cannot be used.

Oneboxing is a handy feature in chat for quickly previewing links, but the list of supported sites is very small, and occasionally boxes for sites such as Wikipedia can break and fetch any image/text.  Instead of having to request additional sites to be added to the onebox list (, , , , , and of course ), we could let the sites themselves handle the oneboxing with some <meta> tags, such as:  <meta name="onebox-title" content="The Onebox Title"/> <meta name="onebox-image" content="/image.png"/> <meta name="onebox-summary" content="This is the summary for a site's onebox"/>   Then when a link is placed on its own in chat, the oneboxing spider would look for these tags and, if they are found, show the appropriate data.  Support for these tags would certainly be bad (for lack of any real better term) at first, though most users of SO chat could easily add it to their personal / company's sites (should they be in such a position) and writing friendly suggestions to other sites to implement them isn't exactly a gargantuan effort.  This would also present an opportunity for currently oneboxed sites to set in stone what should be shown, such as each Wikipedia article setting the main image to be oneboxed instead of SO's spider picking one willy-nilly.  Finally, sites implementing these tags would lay the foundation for other sites and services to develop similar features to the onebox, without having to write per-site scrapers.


When should extends be used in stead of just using the class normally? Is it actually intended to override methods of the standard Java language that programers do not have access to?

Why prefer composition over inheritance?  What trade-offs are there for each approach?  When should you choose inheritance over composition?


I can't seem to find what config is missing. It use to work this way there might be something change in cygwin. I had similar setup which was always working. I have make sure that firewall on windows is turn off.   [raza@mytest]$  export DISPLAY=:0.0  [raza@mytest]$  xhost +  access control disabled, clients can connect from any host  [raza@mytest]$  export DISPLAY=localhost:0.0  [raza@mytest]$  xhost +  xhost:  unable to open display "localhost:0.0"   [raza@mytest]$   xauth list  mytest/unix:0  MIT-MAGIC-COOKIE-1  7ab7e0be4cf96102784fb9c3bb9f0d3b  mytest:0  MIT-MAGIC-COOKIE-1  7ab7e0be4cf96102784fb9c3bb9f0d3b  mytest:0  MIT-MAGIC-COOKIE-1  7ab7e0be4cf96102784fb9c3bb9f0d3b   [raza@mytest]$   telnet localhost 6000  Trying 127.0.0.1...  telnet: Unable to connect to remote host: Connection refused

I had Cygwin X 64 bit running fine on Windows 7. I upgraded to Windows 10 and things stopped working. So I wiped out the Cygwin and installed again from scratch. I installed Cygwin X 1.18.4 (x86_64). I started X server using startxwin. I could only get xterm to work when I set DISPLAY=:0. If I set DISPLAY=localhost:0 I get can't open display.   Also I can't have another computer throw a xterm back to Cygwin X. I get same error. I even tried throwing xterm to a Linux host and that gave same error. Windows firewall is turned off and I set xhost + on all hosts.   Any advice on why I can't explicitly set the DISPLAY to localhost or the local IP of my computer?  Thanks


Stack Exchange hides some comments (low votes etc.), and displays a "Show n more comments" link to reveal them.  When they are revealed it can be difficult to determine which are the new comments that have just been displayed. They should be highlighted in some fashion (probably with a darker background) to indicate they were previously hidden.

When there are several comments some of them get hidden, which I don't mind, except when comments in the middle are hidden and I don't realize it till I get to the end. Then I have to unhide the comments and try to figure out which ones I haven't read.  The comments stay in order as they should so you can follow them but when you hide random ones in the middle you can loose the context of the comments until you unhide them all.  I have a couple of ideas that could help with this.  Put the Show X more comments at the top of the comments instead of the bottom  Put some indicator that there or hidden comments between these two  Comment this is the first comment Comment this is the second comment ... Comment this is the fourth comment, comment three is hidden indicated by the dots Comment this is the fifth comment ... Comment this is comment number nine, comment 6, 7, and 8 are hidden    Where the dots equals some indicator that there are hidden comment between two comments  Finally you could highlight the newly shown comments when you hit the unhide comments link like you do when you post your question.  Update  Just wondering if this could get a second look? Seems the community really likes the idea, and Jeff is ultimately who made the decision not to do it.


I have a MCMC sampler that targets $$\mathbb{P}(U_1,U_2,...U_n \mid G(U) \leq 0)$$ where $U=(U_1,U_2,...U_n)^T$. I realize now I am more interested in estimating the conditional density $$p_k = p(u_k \mid G(U)\leq 0)$$ for all $k=1,\ldots,n$. Is there a relatively easy way to achieve this either by using the sample that I already have from $\mathbb{P}(U_1,U_2,...U_n\mid G(U) \leq 0)$ or by designing another sampler ? I gather from this  that (1) if the conditional distributions $\mathbb{P}(U_k\mid G(U) ,U_{j} \leq 0)$, $j\neq k$ are available then it is possible to derive density estimators for $p_k$. Another possibility (2) is if a functional form of the joint density $p( u_1,u_2,...u_n)$ is available and at least one $\mathbb{P}(U_k\mid G(U) ,U_{j} \leq 0)$ is straightforward to sample, then something can be done about it.  I find myself in unknown territory since neither (1) nor (2) is true in my case.   Would anyone have a suggestion to tackle this problem ? Even a MCMC sampler yielding samples from $p_k$ for all $k$ would be nice, as i could try KDE afterwards to get the corresponding density. The only annoying thing is the relatively high dimension.  Thanks

I am trying to understand the concepts of Bayesian data analysis by examples. I have managed to "do" something, and I would like some advise on where I have gone wrong.  My data is that I have 50 students who take a test and score in the range [0, 1.0], I refer to this as $y$. I would like to calculate the posterior distribution of their mean score $P(\mu|y)$ assuming that the scores are normally distributed with mean $\mu$ and standard deviation $\tau$.   Looking at other examples, I was able to do the following in Pymc:  import pymc as pm import numpy as np import matplotlib.pyplot as plt  # Generate fake data data_scores = np.random.normal(0.5, 0.1, size=50)   mu = pm.Uniform("mu", lower=0, upper=1) tau = pm.Uniform("tau", lower=0, upper=500) scores = pm.Normal("score", mu=mu, tau=tau, observed=True, value=data_scores) model = pm.Model([scores, mu, tau]) mcmc = pm.MCMC(model) mcmc.sample(40000, 10000, 1)  mu_samples = mcmc.trace('mu')[:]  plt.hist(mu_samples, bins=30) plt.show()   Which produces a nice histogram.   However, I am confused because I feel like I have calculated $P(\mu, \tau| y)$ and hence now need to marginalise of $\tau$ before considering the distribution of $\mu$.  Eventually I want to use this compare how to classes did on a test, but I am at a very basic level of understanding right now so any comments are appreciated.


This is currently a simple timer app with two activities, the first activity is the timer and the second will be used to set preferences that will be used later on.  I am not sure where the problem is in my code.  I've seen some solutions to similar errors but none of them are working. Keep in mind I am very new to coding (this is my first project) and I don't fully understand everything yet. Any help will be greatly appreciated, thanks!  Logcat error   Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.widget.Button.setOnClickListener(android.view.View$OnClickListener)' on a null object reference     at com.example.soswag49.showertimer.MainScreen.onCreate(MainScreen.java:29)     at android.app.Activity.performCreate(Activity.java:6251)     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)      at android.app.ActivityThread.-wrap11(ActivityThread.java)      at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)      at android.os.Handler.dispatchMessage(Handler.java:102)      at android.os.Looper.loop(Looper.java:148)      at android.app.ActivityThread.main(ActivityThread.java:5417)      at java.lang.reflect.Method.invoke(Native Method)      at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)  01-12 14:37:23.916 197-7464/? E/ACDB-LOADER: Error: ACDB AudProc vol returned = -19  01-12 14:37:29.535 7185-7496/? E/Finsky: [1619] com.google.android.finsky.ar.c.a(27): Unable to build selector: /storage/emulated/0/Download/marketenvs.csv: open failed: ENOENT (No such file or directory)   Main screen Java, not all of it but just the relevant stuff.  @Override     protected void onCreate(Bundle savedInstanceState) {     super.onCreate(savedInstanceState);     setContentView(R.layout.activity_main_screen);       setFlow.setOnClickListener(new View.OnClickListener() {         @Override         public void onClick(View v) {             moveToSetFlow();         }     });   *other code here   public void moveToSetFlow(){         Intent intent = new Intent(MainScreen.this, Flow.class);         startActivity(intent);     } }   Main screen XML, just the button used to switch activities    <Button         android:id="@+id/setFlow"         android:layout_width="175dp"         android:layout_height="wrap_content"         android:layout_marginTop="8dp"         android:layout_marginEnd="8dp"         android:backgroundTint="@android:color/holo_blue_dark"         android:text="@string/set_shower_flow"         android:textAlignment="center"         android:textStyle="bold"         app:layout_constraintEnd_toStartOf="@+id/historyText"         app:layout_constraintTop_toBottomOf="@+id/start" />

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?


Maybe my question seems so strange but I want to know what is the geometry meaning of Riemann stieltjes integral ??

What is the geometrical interpretation of Riemann Stieltjes Integration ?   We know that for Riemaan integration $\int_{a}^b f(x)dx$ represents the area bounded by the curve $y=f(x)$& the straight lines $x=a$ & $x=b$.  But when we integrate $f(x)$ with respect to another function $g(x)$ then which area represents that integration geometrically ?


Unable to execute below query  Update tbl SET alias_seq= (Select seq from tbl where analysed_object = 'data' order by seq LIMIT 1)   getting below error     #1093 - You can't specify target table 'tbl' for update in FROM clause

I have a table story_category in my database with corrupt entries. The next query returns the corrupt entries:  SELECT *  FROM  story_category  WHERE category_id NOT IN (     SELECT DISTINCT category.id      FROM category INNER JOIN         story_category ON category_id=category.id);   I tried to delete them executing:  DELETE FROM story_category  WHERE category_id NOT IN (     SELECT DISTINCT category.id      FROM category        INNER JOIN story_category ON category_id=category.id);   But I get the next error:      #1093 - You can't specify target table 'story_category' for update in FROM clause    How can I overcome this?


Plain "empty space" or vacuum is not empty after all. It contains small quantum fluctuations. Virtual Particles pop in and out of existence all around us. In this system, an electron and a positron appear. My first question is: How do they just appear, and after a period of time disappear? "Empty space" is measured to have about 10^-8 ergs of energy density. But according to this , Sean Carrol points out we estimated the energy of "empty space" would be 10^112 ergs density. Could you tell me how this was calculated? And how was "10^-8 ergs" measured?

In popular physics articles and even some physics classes I've been to, the vacuum of space is described as being constantly full of quantum fluctuations.  Supposedly, all sorts of particle-antiparticle pairs at all scales are constantly appearing and disappearing.  We end up with a mental image of the vacuum as a roiling, choppy sea with all sorts of things going on, rather than a calm, placid background.  However, the vacuum, being the lowest-energy state of a theory, should be an energy eigenstate—which means it is time-invariant (except for a physically-irrelevant phase factor).  So it seems the vacuum really should not be seen as a dynamic entity with all kinds of stuff happening in it, as we're led to believe.   that     A “vacuum fluctuation” is when the ground state of a system is measured in a basis that does not include the ground state; it’s merely a special case of a quantum fluctuation.   So it sounds as if the existence of vacuum fluctuations is contingent on measuring the vacuum—in particular, measuring something that doesn't commute with energy (such as, I guess, the value of a field at a point).  How much truth is there to the idea that vacuum fluctuations are constantly happening everywhere, all the time?  Is that really a useful way to think about it, or just a myth that has been propagated by popularizations of physics?


I have a distribution:  $$f_\theta(x) =\theta x^{\theta−1},0< x <1, \theta > 0 \qquad (1)$$  and I need to show that there is a function $\tau(\theta)$ for which there is an unbiased estimator whose variance attains the Cramer-Rao lower bound.   I know that the lowerbound is attained if and only if:  $$a(\theta)[W(X) - \tau(\theta)] = \frac{d}{d\theta}ln\left(f_\theta(X|\theta)\right) \qquad (2)$$  where $W(X)$ is an unbiased estimator of $\tau(\theta)$.   Starting with the MLE as an estimator of $\theta$:  $$\hat \theta = \frac{-n}{\sum_{i=1}^n log(X_i)}$$  To show that it's an unbiased estimator:  \begin{align} E\left[\frac{-n}{\sum_{i=1}^n log(X_i)}\right] &= \frac{-n}{\sum_{i=1}^n E[log(X_i)]} \\ &=  \frac{-n}{\frac{-n}{\theta}}\\ &= \theta \end{align}  To show that the estimator attains the Cramer-Rao lower bound:  \begin{align} a(\theta)\left[\frac{-n}{\sum_{i=1}^n log(X_i)} - \theta \right] = \frac{n}{\theta} + \sum_{i=1}^nlog(X_i) \end{align}  Solving for $a(\theta)$:  $$a(\theta) = \frac{-\sum_{i=1}^n log(X_i)}{\theta}$$  This indicates the variance of $W(X)$ attains the following Cramer-Rao lowerbound: \begin{align} Var(W(X)) &=\frac{\left(\frac{d}{d\theta}E\left[W(X)\right]\right)^2}{E\left[\left(\frac{d}{d\theta}ln\left(f(X|\theta)\right)\right)^2\right]} \\ &=\frac{1}{E\left[\left(\frac{d}{d\theta}ln\left(f(X|\theta)\right)\right)^2\right]} \\ &=\frac{1}{E\left[\left(\frac{n}{\theta} + \sum_{i=1}^nlog(X_i)\right)^2\right]} \end{align}  Correct me if I am wrong, but isn't this variance different from that described ?

The question states  ''let $X_{1}, \dots, X_{n}$ be random sample from $f(x \mid \theta) = \theta\cdot x^{\theta-1}$ for $0 < x< 1 ; \theta > 0$. Is there a function of $\theta, g(\theta)$ for which there exists an unbiased estimator of $\theta$ whose variance $\textbf{attains}$ the Cramèr-Rao lower bound ? if so find it!". so we have an exponential family, and we can interchange differentiation and integration, so the fisher information term, denominator of the Cramér-Rao lower bound, I calculated as $E \left(\dfrac{\partial}{\partial \theta}[\ln(\theta \cdot x^{\theta-1})] \right)^{2} = -n E \left(\dfrac{\partial^{2}}{\partial \theta^{2}}(\ln(\theta x^{\theta-1}\right) \implies \dfrac{\theta^{2}}{n}$ taking $\dfrac{1}{I(\theta)}$ Now just taking a stab the statistic I've used is $W(X)= \overline{X}$ which I calculate to be UBE since $E[X] = \dfrac{\theta}{\theta + 1}$ and thus E$[\overline{X}] = \frac{\theta}{\theta + 1}$ from my calculations (hopefully right). similarly, if I calculate the variance I get $\dfrac{\theta}{(\theta + 1)^{2}(\theta + 2)} \geq \dfrac{\theta^{2}}{n}$ satisfies the lower bound. If I examine the MLE I find: $\dfrac{n}{\theta} + \sum_{i}\ln(x_{i}) = 0 \implies \hat{\theta_{MLE}} = \dfrac{-n}{\sum \ln(x_{i})}$. the attainment theory states \begin{equation} \begin{split} \frac{n}{\theta} + \sum_{i}\ln(x_{i}) &= a(\theta)[W(\vec{x})-\tau(\theta)]\\  &= n [\frac{ \sum \ln(x_{i})}{n} - \dfrac{-1}{\theta}] \end{split} \end{equation} where if W(x) satisfies the above, then it is the best estimate for $\tau$. We need to use Rao-Blackwell theorem for W in the above equation to show that $\dfrac{1}{\hat{\theta_{MLE}}}$ is the best. Consider Y = \log(X) now applying the transformation with the Jacobian we have \begin{equation} \begin{split} f_{X}(e^{y}) = \theta e^{y(\theta-1)}\cdot e^{y} = \theta e^{y\theta} = f_{Y}(y) \end{split} \end{equation} where E[Y] = $\frac{1}{\theta}$ (Which I think is an unbiased estimator ?) Using the Rao-Blackwell theorem, let $\theta^{\star} = E[Y_{i} \mid \sum y_{i} = t]$ where since $f_{Y}(y)$ is an exponential family then $\sum y_{i}$ can be shown to be sufficient statistic. then \begin{equation} \begin{split}  E[\theta^{\star}] &= E \left[ E[Y_{i} \mid \sum y_{i} = t] \right] \\  &= E\left[ \theta^{\star} \right] \\  &= \frac{1}{\theta^{\star}} \end{split} \end{equation} which really fits into the attainment equation written above! so my guess is to let $W(\vec{x}) = \dfrac{1}{\theta_{\text{MLE}}^{\star}}$ be the best UBE (?)


I read in a book that the following expression O(2^n + n^100) will be reduced to: O(2^n) when we drop the insignificant parts. I am confused because as per my understanding if the value of n is 3 then the part n^100 seems to have a higher count of executions. What am I missing?

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


Let $V$ be a vector space and $U,W$ be its subspaces.  Prove that if the union $U\cup W$ is a subspace of $V$, then $W \subseteq U$ or $U \subseteq W$.  I'm not sure where to begin at all really.

I'm having a difficult time understanding this statement. Can someone please explain with a concrete example?


My HDD is making clicking noise. The head isn't stuck half way through the platter yet YouTube videos related to data recovery in such cases weren't helpful. Please see recording here   password is harddisk. I haven't got a spare one of this type so I can't really replace the circuit board which is what may help. The HDD is a goner but I still want to try to make it work at least to the point where the disk is detected by a computer and mounts it so I can recover the data. How should I proceed ?

Friend of mine dropped a HDD on the floor and every since the HDD won't mount when connected. It just makes this spinning noise inside for about two rounds and then it goes quiet. Obviously, he wants to salvage the data but I said to him I'll see what I can do knowing the chance of recovery is pretty slim with HDD that won't mount. Was I right about this ? Is there anything I can try I may not know about ? I tried to run gparted on it as I know gparted can detect disks that aren't mounted but connected. But no luck.


Now I have a binary tree which is  How would I go about proving binary tree with $n$ leaves has exactly $2 n - 1$ nodes ?

How would I prove that any binary tree that has n leaves has precisely $2n-1$ nodes ?  Given that a binary tree is either a single node "o" or a node with the left and right subtrees contains a binary tree        o  /       \ binary  binary tree    tree   Any help would be appreciated !


Every time I start up this windows XP laptop (lenovo t60), the svchost and wuauclt processes take up ~200,000k memory each. in addition, svchost takes ~50% of cpu power.  Is there any way to alleviate this?  this happens every time. I can end both processes but that has caused problems with wifi connection.

I'm running Windows 7. It seems that svchost is eating up a lot of memory.   The user name for the particular svchost instance is "Network Service". The description is "Host Process for Windows Services".   Sometimes it eats up 50% of the CPU usage. Other times, it's just under 5%. I can't figure out when it's 50% and when it's not. But it fluctuates often -- even when I've just booted up and no programs were started.  How do I diagnose this?


For regular expressions $r$ and $s$ prove: $$(r^*s^*)^*=(r+s)^*$$  I guess I have to prove the equality of sets $(R^*S^*)^* = \left\{ x_1^{n_1}y_1^{m_1}x_2^{n_2}y_2^{m_2}... \mid n_i,m_j \in \mathbb{N_0},x_i \in R, y_j \in S \right\}$ and $(R \cup S)^* = \left\{ x_1^{n_1}x_2^{n_2}x_3^{n_3}... \mid n_i \in  \mathbb{N_0},x_i \in R \cup S \right\}$ This seems simple enough.

Prove that for all languages $M,N \subseteq \Sigma^*$ applies:   $(M+N)^* = (M^*N^*)^*$   Hi!  I do'nt really understand why this applies: The first term uses the Kleene star on the union of M and N and therefore contains the empty word $\lambda$ and all possible string concatenations of the union. The second term contains all possible concatenations of M plus the empty word concatenated to the possible concatenations of N plus the empty word. Let $m \in M, n \in N, n \not\in M$. The word $nm$ can be expressed by the first, but not the second term $(M^*N^*)^*$. Where is my mistake?  How can I write the proof the correct way?  Thanks in advance


I know what is happening, but I do not know how to solve it because I am a novice in regular expressions.  The regular expression, takes all the expression, because it takes the initial brackets of {{username and the end of day}}, then it wraps all the code between them.  How should the regular expression be?    var str = "Welcome back {{username}}, how are you ? today is {{day}}",     regex = /{{.+}}/g,     matches = str.match(regex);       console.log(matches); // I was waiting for : [{{username}}, {{day}}]

I have this gigantic ugly string: J0000000: Transaction A0001401 started on 8/22/2008 9:49:29 AM J0000010: Project name: E:\foo.pf J0000011: Job name: MBiek Direct Mail Test J0000020: Document 1 - Completed successfully  I'm trying to extract pieces from it using regex. In this case, I want to grab everything after Project Name up to the part where it says J0000011: (the 11 is going to be a different number every time). Here's the regex I've been playing with: Project name:\s+(.*)\s+J[0-9]{7}:  The problem is that it doesn't stop until it hits the J0000020: at the end. How do I make the regex stop at the first occurrence of J[0-9]{7}?


My topic is on: Relationship between  age of teachers and academic performance of students in Mathematics.

I have a dataframe with many observations and many variables. Some of them are categorical (unordered) and the others are numerical.  I'm looking for associations between these variables. I've been able to compute correlation for numerical variables (Spearman's correlation) but :   I don't know how to measure correlation between unordered categorical variables. I don't know how to measure correlation between unordered categorical variables and numerical variables.   Does anyone know how this could be done? If so, are there R functions implementing these methods?


Since the first two list items contain a comma, do I follow suit and use a semi-colon for the last two?  "He leaves behind his wife of 61 years,_____; children ____, ____, and ____; 9 grandchildren; and 2 great grandchildren."

While writing a proposal at work today I needed to mention a list of things and within that list were multi-part items. It seems like replacing the comma with a semi-colon in this situation would make the sentence easier to understand, but is it correct usage?  With standard punctuation this could get confusing:       Some of my favorite things to do are   camping, playing football and   baseball, watching Laurel and Hardy   Movies, and traveling.   Proposed alternative. Is this acceptable usage?       Some of my favorite things to do are   camping; playing football and   baseball; watching Laurel and Hardy   Movies; and traveling.


I am writing a script that should change directory based on the input and then go back to the directory where the script was executed.  I am currently doing this:  old_dir = os.getcwd() os.chdir(<new_dir>) #do something os.chdir(old_dir) #do something   Is there a Python equivalent of cd - which would change the directory to the previous directory?  The following  expects an answer using any module while what I am looking for is something similar to cd -.

I have a function that resembles the one below. I'm not sure how to use the os module to get back to my original working directory at the conclusion of the jar's execution.   def run():      owd = os.getcwd()     #first change dir to build_dir path     os.chdir(testDir)     #run jar from test directory     os.system(cmd)     #change dir back to original working directory (owd)   note: I think my code formatting is off - not sure why. My apologies in advance


I have installed Ubuntu alongside Windows 7 (no separate partitions, I selected inside windows option).   I want to uninstall Ubuntu but last time I tried it and the Ubuntu is released but the GRUB remains. How do I remove GRUB?

I have absolutely no experience with Linux, and I desperately need to get my computer back up and running again with Windows.  How do I remove Ubuntu and reinstall Windows?    Editor's note: many of the answers are about removing Ubuntu from dual-boot but keeping Windows (which is a bit complicated), while other answers are about removing Ubuntu from single-boot (which is easy: basically just format the disk while installing Windows). The question as written is ambiguous between dual-boot or single-boot.


I'm trying to animate a basketball through the net, but I can't get collision to work. I tried flipping normals for the net, but no luck. These are my settings - I tried the net WITH and WITHOUT the rigid body physics - still nothing. Any ideas what I might be missing? EDIT: I am able to make it interact with passive rigid body that I keyframe through the net, but ACTIVE does not. I can't figure it out.

I wanted to add the torus object and attach net on the torus object in blender. I am not sure how to make a circular net and attach it to a torus object.