The standard authoryear style in biblatex puts parentheses around the year in the bibliography and no parentheses around in text citation years:        Smith 2011 shows ... (citation)   Smith, Joe (2011) ... (bibliography)      Is there a (simple) way to turn these into:        Smith (2011) shows ... (citation)   Smith, Joe. 2011. ... (bibliography)

I have a question that has been answered a few times, but does not work for me (and also not for another commenter in a previously asked question).   I want to remove the parenthesis around the yead in the bibliography with biblatex style authoryear, and ideally also add a comma and space before it. I have looked at the following questions:        I use biber 2.10 and TexLive 2017/W32Tex.  This MWE should work according to the question v2 above, but does not work for me, i.e. the output is still Author, Anne (2001a). Alpha. The output I need is Author, Anne, 2001a. Alpha.  \documentclass{article}  \usepackage[style=authoryear,dashed=false]{biblatex} \usepackage{xpatch,filecontents}  \begin{filecontents}{\jobname.bib} @misc{A01,author={Author, Anne},year={2001},title={Alpha}} @misc{A02,author={Author, Anne},year={2001},title={Beta}} \end{filecontents} \addbibresource{\jobname.bib}  \xpatchbibmacro{date+extrayear}{%   \printtext[parens]% }{%   \setunit*{\addperiod\space}%   \printtext% }{}{}   \begin{document} \nocite{*} \printbibliography \end{document}


I am interest to prove the equation below : $$ \sum_{k=1}^m  \tan^2\left(\frac{k\pi}{2m+1}\right) =  m(2m+1)  $$ you can understand better the first member of the equation here:    (mark the whole url with your mouse because i dont know why the link isn't blue at all) sorry but i am not familiar writing equations here . i hope to understand.  so what's the problem in formula i cannot eliminate the trigonometric functions to prove this series is a polynomial . any idea how to manipulate the formula ?

Prove that $$\sum _{l=1}^{n}\sum _{k=1}^{n-1}\tan \frac {lk\pi } {2n+1}\tan \frac {l( k+1) \pi } {2n+1}=0$$     It is very easy to prove this identity for each fixed $n$ . For example let $n = 6$; writing out all terms in a $5 \times 6$ matrix, we obtain:  $\begin{matrix}  \tan \dfrac {\pi } {13}\tan \dfrac {2\pi } {13}  &  \tan \dfrac {2\pi } {13}\tan \dfrac {3\pi } {13} & \tan \dfrac {3\pi } {13}\tan \dfrac {4\pi } {13} & \tan \dfrac {4\pi } {13}\tan \dfrac {5\pi } {13} & \tan \dfrac {5\pi } {13}\tan \dfrac {6\pi } {13}  \\  \tan \dfrac {2\pi } {13}\tan \dfrac {4\pi } {13}  &  \tan \dfrac {4\pi } {13}\tan \dfrac {6\pi } {13} & \tan \dfrac {6\pi } {13}\tan \dfrac {8\pi } {13} & \tan \dfrac {8\pi } {13}\tan \dfrac {10\pi } {13} & \tan \dfrac {10\pi } {13}\tan \dfrac {12\pi } {13} \\ \tan \dfrac {3\pi } {13}\tan \dfrac {6\pi } {13} & \tan \dfrac {6\pi } {13}\tan \dfrac {9\pi } {13} & \tan \dfrac {9\pi } {13}\tan \dfrac {12\pi } {13} & \tan \dfrac {12\pi } {13}\tan \dfrac {15\pi } {13} & \tan \dfrac {15\pi } {13}\tan \dfrac {18\pi } {13} \\ \tan \dfrac {4\pi } {13}\tan \dfrac {8\pi } {13} & \tan \dfrac {8\pi } {13}\tan \dfrac {12\pi } {13} & \tan \dfrac {12\pi } {13}\tan \dfrac {16\pi } {13} & \tan \dfrac {16\pi } {13}\tan \dfrac {20\pi } {13} & \tan \dfrac {20\pi } {13}\tan \dfrac {24\pi } {13} \\ \tan \dfrac {5\pi } {13}\tan \dfrac {10\pi } {13} & \tan \dfrac {10\pi } {13}\tan \dfrac {15\pi } {13} & \tan \dfrac {15\pi } {13}\tan \dfrac {20\pi } {13} & \tan \dfrac {20\pi } {13}\tan \dfrac {25\pi } {13} & \tan \dfrac {25\pi } {13}\tan \dfrac {30\pi } {13} \\ \tan \dfrac {6\pi } {13}\tan \dfrac {12\pi } {13} & \tan \dfrac {12\pi } {13}\tan \dfrac {18\pi } {13} & \tan \dfrac {18\pi } {13}\tan \dfrac {24\pi } {13} & \tan \dfrac {24\pi } {13}\tan \dfrac {30\pi } {13} & \tan \dfrac {30\pi } {13}\tan \dfrac {36\pi } {13}  \end{matrix}$  one can notice then, that the first column vanish the fourth one :  $\tan \dfrac {\pi } {13}\tan \dfrac {2\pi } {13}=-\tan \dfrac {12\pi } {13}\tan \dfrac {15\pi } {13}$  $\tan \dfrac {2\pi } {13}\tan \dfrac {4\pi } {13}=-\tan \dfrac {24\pi } {13}\tan \dfrac {30\pi } {13}$  $\tan \dfrac {3\pi } {13}\tan \dfrac {6\pi } {13}=-\tan \dfrac {16\pi } {13}\tan \dfrac {20\pi } {13}$  $\tan \dfrac {4\pi } {13}\tan \dfrac {8\pi } {13}=-\tan \dfrac {4\pi } {13}\tan \dfrac {5\pi } {13}$  $\tan \dfrac {5\pi } {13}\tan \dfrac {10\pi } {13}=-\tan \dfrac {8\pi } {13}\tan \dfrac {10\pi } {13}$  $\tan \dfrac {6\pi } {13}\tan \dfrac {12\pi } {13}=-\tan \dfrac {20\pi } {13}\tan \dfrac {25\pi } {13}$  and the third column vanish the fifth one :  $\tan \dfrac {3\pi } {13}\tan \dfrac {4\pi } {13}=-\tan \dfrac {30\pi } {13}\tan \dfrac {36\pi } {13}$  $\tan \dfrac {6\pi } {13}\tan \dfrac {8\pi } {13}=-\tan \dfrac {5\pi } {13}\tan \dfrac {6\pi } {13}$  $\tan \dfrac {9\pi } {13}\tan \dfrac {12\pi } {13}=-\tan \dfrac {25\pi } {13}\tan \dfrac {30\pi } {13}$  $\tan \dfrac {12\pi } {13}\tan \dfrac {16\pi } {13}=-\tan \dfrac {10\pi } {13}\tan \dfrac {12\pi } {13}$  $\tan \dfrac {15\pi } {13}\tan \dfrac {20\pi } {13}=-\tan \dfrac {20\pi } {13}\tan \dfrac {24\pi } {13}$  $\tan \dfrac {18\pi } {13}\tan \dfrac {24\pi } {13}=-\tan \dfrac {15\pi } {13}\tan \dfrac {18\pi } {13}$  while the second column is self-vanishing:  $\tan \dfrac {2\pi } {13}\tan \dfrac {3\pi } {13}=-\tan \dfrac {10\pi } {13}\tan \dfrac {15\pi } {13}$  $\tan \dfrac {4\pi } {13}\tan \dfrac {6\pi } {13}=-\tan \dfrac {6\pi } {13}\tan \dfrac {9\pi } {13}$  $\tan \dfrac {8\pi } {13}\tan \dfrac {12\pi } {13}=-\tan \dfrac {12\pi } {13}\tan \dfrac {18\pi } {13}$ .  So the equality occurs. But how to generalize the proof?


I have two different computers that I use regularly. On one computer, the colors look too bright, and on the other computer, the colors look too dark. Is there a way to try to keep things looking more consistent between my different workstations? And how do I know how things will look for the "average" user?  I should mention I'm producing digital works that won't be printed out on a physical medium. It will all be viewed on a screen of some sort, either a monitor or a tablet.

I designed a mockup on my LG monitor. When I view the same design on another monitor that I own, the colors seem drastically different. I reset both of the monitors to their factory defaults, but still the issue persists. I'm wondering if some of my clients might dislike my designs because of this. What should I do?  How can I make sure that what I design is what my client sees?  Even worse still, I've realized that my laptop is showing different colors too.


I am doing some work with Gaussian mixture models and we want to find the standard deviation of samples from the model. Our current methodology is to run a Monte-Carlo sim, and just take a bunch of samples then evaluate the std of those samples. This method is time-consuming and kinda ugly.  I am curious if anyone knows of a closed-form solution?  I started making some headway on calculating the variance of a gaussian using a new mean. aka E((x-c)^2) | x ~ N(u,s). Then say Var(sample_gmm) = sum_i(pi_i^2 * E((x-c)^2) | x ~ N_i) and c = sum_i(pi_i * u_i). However, the resulting formula is Very ugly. I haven't been able to find any online discussion on this problem.

Say I have two normal distributions A and B with means $\mu_A$ and $\mu_B$ and variances $\sigma_A$ and $\sigma_B$. I want to take a weighted mixture of these two distributions using weights $p$ and $q$ where $0\le p \le 1$ and $q = 1-p$. I know that the mean of this mixture would be $\mu_{AB} = (p\times\mu_A) + (q\times\mu_B)$.  What would the variance be?    A concrete example would be if I knew the parameters for the distribution of male and female height. If I had a room of people that was 60% male, I could produce the expected mean height for the whole room, but what about the variance?


For a few weeks now, my Windows 7 installation has been showing intermittent freezes. Typically, the currently focused application window will freeze for up to 7 seconds, but I can still switch to a different application which will be working fine. Often, Firefox will freeze when loading a page, but other applications freeze as well at unpredictable times.  I created two xperf traces which capture a freeze in two different applications, as well as a trace without a freeze (following ). The only correlation I found so far is some higher-than-usual writing to the disk occurring near the moment of the freeze, but in the summary table, I see no obvious differences between the freezing and the non-freezing traces. What should I be looking for?

A machine is described as being "really slow" or "freezing". How can I troubleshoot/resolve this issue? What should be the first steps to take?


I'm currently working my way through some Machine Learning courses and books, and from what I can understand, ML uses a stock of standard functions that are used over and over again. This led me to ask, is there a way to generalise a function instead of specifying it? For example, instead of using linear or logistic or polynomial regression, create an ML algorithm to approximate the best type of function? Is such a thing possible mathematically?

I came across a simple question on comparing flexible models (i.e. splines) vs. inflexible models (e.g. linear regression) under different scenarios. The question is:  In general, do we expect the performance of a flexible statistical learning method to perform better or worse than an inflexible method when:   The number of predictors $p$ is extremely large, and the number of observations $n$ is small?   The variance of the error terms, i.e. $σ^2 = \text{Var}(e)$, is extremely high?   I think for (1), when $n$ is small, inflexible models are better (not sure). For (2), I don't know which model is (relatively) better.


Can somebody help me solve this. I need to find the equivalent resistance of these resistors. I really don't know where the trick here is. If somebody could help me I would really appreciate it


Consider the following minimal example:  % !TEX program = xelatex \documentclass{article}  \usepackage{fontawesome}  \begin{document} \faTwitter{} Some Text \faLinkedin \end{document}   On my MacTeX 2016 basic system (up to date), the icons are missing in the PDF and I get the following error message:  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ! /usr/local/texlive/2016basic/texmf-dist/tex/latex/fontawesome/fontawesome.sty:45: fontspec error: "font-not-found" !  ! The font "FontAwesome" cannot be found. !  ! See the fontspec documentation for further information. !  ! For immediate help type H <return>. !...............................................   The example does work when I change the engine to  % !TEX program = latex   or  % !TEX program = luatex   I don't have the font installed on my system because according to the documentation the package should use the font bundled with the package (which obviously works with latex and luatex, but not with xelatex).

I'm using the latest version of MacTeX 2013 on OS X 10.8.4. All of my Tex Live packages are fully up-to-date. Tex Live also lists the fontawesome package as installed. I'm trying to use the FontAwesome font with XeLatex or LuaLatex and getting font-not-found errors. The exact message is: kpathsea: Running mktexmf FontAwesome ! I can't find file `FontAwesome'.  There's a longer traceback which I am omitting for brevity. Let me know if it's needed to resolve this problem. I have already tried running the following commands, to no avail: sudo -H mktexlsr sudo -H updmap-sys  Other than the above two commands, this is a 100% new out-of-the-box installation, with no modifications whatsoever. Here's a minimal broken example: \documentclass{article} \usepackage{fontawesome}  \begin{document} \faTwitter \end{document}  How can I add this missing font? Edit (Q1 2021): Please see Justin Curry's answer regarding an update to the package name from fontawesome to fontawesome5.


For each $t ≥ 2$, show that a $t$-regular Ramsey graph has   $$r(3,t+1) ≥ 3t$$     I'm stuck on where to go with this question. I've tried using what few theorems I know, but I've gotten caught up with inequalities that are not helping with anything, such as $r(3,t+1)≤r(3,t)+r(2,t+1)=r(3,t)+t+1$.

I need to prove the following inequality: $$R( n + 2 , 3 )>3n$$ where $n>1$ and $R(s,t)$ is a Ramsey number.    The most general way to prove such inequalities is to paint a graph with $3n$ nodes then show it could not have a sub graph with $n+2$ in red or $3$ in blue, I've also used induction but no answers yet.


Is it possible to have access to the source file of each pattern you have inside Photoshop? A pattern is a squared piece of some artwork that is repeated according to the settings you choose. How could I get direct access to the 1 piece of that specific pattern so I can manipulate it or make it usable for web?  My goal is to have direct access to the pattern itself outside of Photoshop, like a .jpg file or so. I tried accessing Photoshops folder and located the pattern folder but I can´t see any customized pattern I created there, where does Photoshop store the patterns you create? I only saw .pat files there. Is there a way to access directly each pattern separated as a single file?  Please someone help!   Thanks!

I am designing a website and in the background I am using a pattern that is done by somebody else.  Now while slicing, is there anyway to find and select the exact dimensions of the pattern that the other designer has used to create that pattern instead of guessing it?


What happened to Gandalf the Grey's body when he died? It is described that he:  'strayed out of thought and time',  and then:  'I was sent back naked' .  He died in his clothes and if he was sent back 'renewed' and naked to his old body,  what happened to his clothes? Did his body also 'stray out of thought and time'? Or perhaps he was sent back in a new body; in this case why was he sent back to the (harsh) place where he died?  (If) When he came back in a new body, what happened to his old body? It seemingly is a stretch for someone to look at their own dead body(!). So what happened to his old body?

So Gandalf and the Balrog of Moria have a little fisticuffs and they both died. Presumably dead bodies lie on the mountain side somewhere.  Gandalf "strayed out of thought and time", gets a can of spinach and a new colour then he comes back sometime after his death as Gandalf 2.0.  The questions are thus:   Did Gandalf's old body get burnt to a crisp, or suffer some other death that meant there was no dead body left? OR Did his old body get renewed?   Or do we not know? If his body was left in the snow, then wouldn't it have been preserved due to freezing? This seems like an obvious oversight in the story.   I'd like to stick with the book canon, but out-of universe answers are also welcome.  Clarification: I'm not asking about his soul or whether he can die or where he went. I am specifically asking about what was left behind on the mountain.


My laptop ran out of power and when I went to plug it in and power it on, Ubuntu no longer boots. I get directed to BusyBox built in shell that looks exactly like:  BusyBox v1.27.2 (Ubuntu 1:1.27.2-2ubuntu4.1) built-in shell (ash) Enter 'help'for a list of built-in commands.  (initramfs)   When I type in exit, the following output is dumped:  mount: mounting /sys on /root/sys failed: No such file or directory mount: mounting /proc on /root/proc failed: No such file or directory /init: line 355: can't open /root/dev/console: no such file _   I've had a look at  article to see if it could help me out, which prompted me to dumpe2fs /dev/sda2 | grep superblockwhich dumped the following output:  dumpe2fs: Bad magic number in super-block while trying to open /dev/sda2 Couldn't find valid filesystem superblock   How can I boot my Ubuntu based OS again?

Installing a new system using a GPT partitioned disk dedicated to a single partition, ext4 formatted, extlinux (version 4.05) as bootloader, Ubuntu Core version 13.10 amd64 as rootfs, and Ubuntu linux-image-3.11.0-18-generic as kernel, and extlinux-update to generate bootloader configuration.  The result after reboot (still inside a KVM based virtual machine) is an (initramfs) prompt and these messages:  mount: can't read '/etc/fstab': No such file or directory mount: mounting /dev on /root/dev failed: No such file or directory mount: mounting /sys on /root/sys failed: No such file or directory mount: mounting /proc on /root/proc failed: No such file or directory The filesystem doesn't have requested /sbin/init. No init found. Try passing init= bootarg.   BusyBox is v1.20.2.  Regression:   the file system has been checked with fsck.ext4   Check for root existence  (initramfs) ls -l /dev/[hs]da* ls: /dev/[hs]da*: No such file or directory   Root boot argument  (initramfs) cat /proc/cmdline initrd=/boot/initrd.img-3.11.0-18-generic ro quiet BOOT_IMAGE=/boot/vmlinuz-3.11.0-18-generic   Check loaded modules  (initramfs) cat /proc/modules e1000 145368 0 - Live 0xffffffffa0000000   /boot folder content  $ sudo ls -l boot -rw------- 1 root root 3296162 Feb 18 22:37 System.map-3.11.0-18-generic -rw-r--r-- 1 root root 1007681 Feb 18 22:37 abi-3.11.0-18-generic -rw-r--r-- 1 root root  163258 Feb 18 22:37 config-3.11.0-18-generic drwxr-xr-x 2 root root    4096 Mar 17 20:13 extlinux -rw-r--r-- 1 root root 4995000 Mar 16 23:35 initrd.img-3.11.0-18-generic -rw------- 1 root root 5634192 Feb 18 22:37 vmlinuz-3.11.0-18-generic   How to make this system boot to the expected default bash prompt?


Short question:   What is the physics interpretation of max & inflection points in the principle of least action?    Long question:   If $$L(q_1,q_2;t)=K-V$$  then let $$S = \int^{t_1}_{t_2} L(q_1,q_2;t)dt$$  Taking $$\delta S=0$$ is what usually called the least action of principle     The path taken by the system between times $t_1$ and $t_2$ is the one for which the action is stationary (no change) to first order. -wiki   eventually it gives us Euler–Lagrange equation.  "Given there is a minimum point", that physically means assuming the system tends to be steady.  However, logically, those points can be maximum or inflection points.  I wonder what maximum points and inflection points mean physically? Will we observe things different if those points turn out to be saddle points?  I found this in wiki:     In 1842, Carl Gustav Jacobi tackled the problem of whether the variational principle always found minima as opposed to other stationary points (maxima or stationary saddle points); most of his work focused on geodesics on two-dimensional surfaces. The first clear general statements were given by Marston Morse in the 1920s and 1930s, leading to what is now known as Morse theory. For example, Morse showed that the number of conjugate points in a trajectory equalled the number of negative eigenvalues in the second variation of the Lagrangian.   Would anyone explain the work by Jacobi and Morse to me?

In  it is discussed why by Hamilton's principle the action integral must be stationary. Most examples deal with the case that the action integral is minimal: this makes sense - we all follow the path with the least resistance.  However, a stationary point can be a maximal or minimal extremum or even a point of inflexion (rising or falling). Can anybody give examples from theory or practice where the action integral takes on a maximal extremum or a point of inflexion?


Let $f : [0, +\infty) \rightarrow \mathbb{R}$ be uniformly continuous. Show that $f$ has sublinear growth  I need to show that there exists $A,B > 0$ such that |$f(x)| ≤ Ax + B$, for all $x ≥ 0$  I was thinking of using the definition of uniform continuity for $\epsilon = 1$ to show that all the values of $x \in [0, +\infty)$ are obtained in tiny steps without changing the value of $f$ much.

Let f: $\mathbb R\to\mathbb R$ be an uniformly continuous function. Show that there is a constant $C$ with $|f(x)|\leq  C\cdot (1+|x|)$.  I can´t seem to find the right idea to solve this problem. Thanks for the help in advance.


I've been studying quantum mechanics and classical mechanics for a little while now, and I still don't feel as though I fully understand the motivation for some of our choices in Heisenberg mechanics.  For example, it clearly isn't a coincidence that the classical observables (functions of coordinates and their conjugate momenta) and the quantum observables (Hermitian operators) seem to form analogous Lie algebras with the Poisson bracket and commutator respectively.  But it isn't clear to me why this is true.  Is there some deep meaning contained in this statement?  Or is it more indicative of the fact that in constructing a quantum model of the universe we took substantial inspiration from our intuition and previous study of classical mechanics?  Along these same lines, what motivates the move from classical functions on phase space to Hermitian operators?  I understand why operators corresponding to observables must be self-adjoint (the eigenvalues must be real), but I don't understand what motivates the move to operators in general.  Why would we expect that operators on a Hilbert space would give physical predictions?  Part of my confusion here may also come from the fact that it isn't entirely clear to me what exactly these operators do in all cases.  For example, I get that $\langle \psi | \hat{x} | \psi \rangle$ corresponds to the expected position of a particle in state $|\psi\rangle$, but it's much less obvious what the $\hat{x}$ operator does to a state in general.  In some cases (such as $J_\pm$ when considering angular momentum), it's clear what the operator does to a state (raises or lowers eigenstates of $J_z$), but in all these cases the operator is non-Hermitian.  Perhaps the answer to this question is simply that the model gives accurate predictions and so we use it, but I'm wondering if there's a better way to think about these things.

Imagine you're teaching a first course on quantum mechanics in which your students are well-versed in classical mechanics, but have never seen any quantum before.  How would you motivate the subject and convince your students that in fact classical mechanics cannot explain the real world and that quantum mechanics, given your knowledge of classical mechanics, is the most obvious alternative to try?  If you sit down and think about it, the idea that the state of a system, instead of being specified by the finitely many particles' position and momentum, is now described by an element of some abstract (rigged) Hilbert space and that the observables correspond to self-adjoint operators on the space of states is not at all obvious.  Why should this be the case, or at least, why might we expect this to be the case?   Then there is the issue of measurement which is even more difficult to motivate.  In the usual formulation of quantum mechanics, we assume that, given a state $|\psi \rangle$ and an observable $A$, the probability of measuring a value between $a$ and $a+da$ is given by $|\langle a|\psi \rangle |^2da$ (and furthermore, if $a$ is not an eigenvalue of $A$, then the probability of measuring a value in this interval is $0$).  How would you convince your students that this had to be the case?  I have thought about this question of motivation for a couple of years now, and so far, the only answers I've come up with are incomplete, not entirely satisfactory, and seem to be much more non-trivial than I feel they should be.  So, what do you guys think?  Can you motivate the usual formulation of quantum mechanics using only classical mechanics and minimal appeal to experimental results?  Note that, at some point, you will have to make reference to experiment.  After all, this is the reason why we needed to develop quantum mechanics.  In principle, we could just say "The Born Rule is true because its experimentally verified.", but I find this particularly unsatisfying.  I think we can do better.  Thus, I would ask that when you do invoke the results of an experiment, you do so to only justify fundamental truths, by which I mean something that can not itself just be explained in terms of more theory.  You might say that my conjecture is that the Born Rule is not a fundamental truth in this sense, but can instead be explained by more fundamental theory, which itself is justified via experiment.  Edit:  To clarify, I will try to make use of a much simpler example.  In an ideal gas, if you fix the volume, then the temperature is proportional to pressure.  So we may ask "Why?".  You could say "Well, because experiment.", or alternatively you could say "It is a trivial corollary of the ideal gas law.".  If you choose the latter, you can then ask why that is true.  Once again, you can just say "Because experiment." or you could try to prove it using more fundamental physical truths (using the kinetic theory of gases, for example).  The objective, then, is to come up with the most fundamental physical truths, prove everything else we know in terms of those, and then verify the fundamental physical truths via experiment.  And in this particular case, the objective is to do this with quantum mechanics.


Is there a requirement that says how long I have to be in Canada before I can go back to US? My situation is: I just got back to Canada not too long ago, but was notified there is a conference in a 5 days. Is possible that I can go back?

I am a British citizen visiting the USA in early August for a two week vacation with friends. After the holiday I'm returning to my home in the UK for three weeks. After that I will return to the USA and will be working for my British employer under the Visa Waiver Program for a period of 80-85 days.  I have read already that there is technically no problems with this under ESTA rules, but should I limit this working period to a shorter time frame (e.g. 70 or so days) so that it does not negatively affect the decision made by the POE officer? Ideally I would love to be over in the states for the near-full 85 day period.  Any advice or previous experiences anyone can offer?  Some clarifications: As confirmed by the immigration attorney, as I am employed by my UK employer, it will be regarded as a business trip, the important part being that I will be working officially as a consultant for my UK employer just overseas for the allotted 85 or so days


I needed to create a list of lists in Python, so I typed the following: my_list = [[1] * 4] * 3  The list looked like this: [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]]    Then I changed one of the innermost values: my_list[0][0] = 5  Now my list looks like this: [[5, 1, 1, 1], [5, 1, 1, 1], [5, 1, 1, 1]]    which is not what I wanted or expected. Can someone please explain what's going on, and how to get around it?


I have no data plan.  I need help,  really want to play please and thank you

I downloaded Pokémon GO on my Samsung Galaxy Express and I can play it at home, but when I go outside I can't play because there is no Internet.  How can I play Pokémon GO without Internet outside?


I am a US citizen, who is a Person's of Indian Origin (PIO) card holder. I am planning to buy an iPhone 6s (60 rupees) as a gift for my mother (who lives in India). I would like to bring it to her in an unopened box.  Will I have a problem at Indian Customs for bringing in an unopened, brand new iPhone, along with my old iPhone which I am using?

I am planning to travel to India (COK airport, Kerala) from United States. I want to take my laptop as well as my tablet (iPad). Am I allowed to take both in my backpack with my documents related my work. I think I am allowed to take only one computer as per the rule. Will the customs consider my iPad as a computer?  What all I can take?   One of my friends took 2 laptops (1 work and 1 personal) and had trouble at the airport.  Also I am planning to take some wristwatches (7 of them, each avg price is 45 $). I read in a website that I can take stuff up to max 35000 INR. Is that true? In that case, how will I manage my stuff?


class classD {   TestFunction(int classToSet)   {      var classAObj = new ClassA();      var classType = getClassByParam(classToSet);      classAObj.Method1<classType>(1);   } } private Type getClassByParam(int classToSet) {    var classType = default(Type);    switch(classToSet)    {       case 1 : classType = typeOf(classB);       break;       case 2 : classType = typeOf(classC);       break;    }    return classType; } class ClassA {    public int Method1<TSource>(int t)    {        some action ..         return 1;    }  } class classB { } class classC { }   i am having generic method, whose type will be decided run time.   I got something which execute generic method using reflection of ClassA in . But i don't want to use reflection of ClassA. instead i want to use object of classA.

What's the best way to call a generic method when the type parameter isn't known at compile time, but instead is obtained dynamically at runtime?  Consider the following sample code - inside the Example() method, what's the most concise way to invoke GenericMethod<T>() using the Type stored in the myType variable?  public class Sample {     public void Example(string typeName)     {         Type myType = FindType(typeName);          // What goes here to call GenericMethod<T>()?         GenericMethod<myType>(); // This doesn't work          // What changes to call StaticMethod<T>()?         Sample.StaticMethod<myType>(); // This also doesn't work     }      public void GenericMethod<T>()     {         // ...     }      public static void StaticMethod<T>()     {         //...     } }


Using the Carseats dataset in R, predicting the Sales of carseats (Unit sales (in thousands)) using price and US (sold in US, not sold in US). How would I interpret the confidence interval in words? Thanks

I know roughly and informally what a confidence interval is.  However, I can't seem to wrap my head around one rather important detail:  According to Wikipedia:     A confidence interval does not predict that the true value of the parameter has a particular probability of being in the confidence interval given the data actually obtained.     I've also seen similar points made in several places on this site.  A more correct definition, also from Wikipedia, is:     if confidence intervals are constructed across many separate data analyses of repeated (and possibly different) experiments, the proportion of such intervals that contain the true value of the parameter will approximately match the confidence level   Again, I've seen similar points made in several places on this site.  I don't get it.  If, under repeated experiments, the fraction of computed confidence intervals that contain the true parameter $\theta$ is $(1 - \alpha)$, then how can the probability that $\theta$ is in the confidence interval computed for the actual experiment be anything other than $(1 - \alpha)$?  I'm looking for the following in an answer:   Clarification of the distinction between the incorrect and correct definitions above. A formal, precise definition of a confidence interval that clearly shows why the first definition is wrong. A concrete example of a case where the first definition is spectacularly wrong, even if the underlying model is correct.


Some author's name contains special characters like "ł" in Szałowski. The latex code for "ł" is \l.  But if I write the name in bib file as Sza\l owski, the the name contained in the output pdf's reference will be "Szał owski". That is to say, there will be a space in the name.  But if I write Sza\l owski in the main text of latex file, then the name will be ok without space.   So why there will be a space? How to deal special character in bib file?  and a related question: In the main text of LaTeX file, no matter how many space after \l, the output is the same. That is to say, the output of Sza\l owski is the same as that of Sza\l    owski, both output "Szałowski". Then what should I do if I want "Szał owski" in the main text.

When using BibTeX, I am happy enough adding accents where appropriate. For example  @article{key, author="Th{\'e}venaz, Jacques", title={Permutation Representations Arising from Simplicial Complexes}, journal={Journal of Combinatorial Theory, Series A}, year={1987}, }   However, if the above is an entry in my bib file and I use the option   \bibliographystyle{alpha}   in a LaTeX file, then this creates an error, as BibTeX naturally creates the key [Th\87] for this entry. Obviously I can go back to my bbl file and change the key here, but are there more general ways of solving this problem?


My girlfriend just purchased a Pixel 4 from Verizon. Apparently, the Verizon representative rushed through the initial setup flow, and my girlfriend didn't get a chance to configure her phone the way she wanted. Is it possible to re-run the onboarding flow?

I am looking for a way to use ADB to trigger Setup Wizard at next boot. I know I can run the following command and get it to pop up. However, I can't figure out what triggers it to start at boot.  adb shell am start -a android.intent.action.MAIN -n com.google.android.setupwizard/.SetupWizardTestActivity   The phone I am currently using is stock and I would like to keep it that way.   I've read the  question:


I'm helping someone to install a  on a Ubuntu 18.04 LTS server which is currently offline from the internet. This will be later used to setup authentication to connect to a Kakfa service.  If it was online, this simple apt-get command would be enough:  sudo apt-get install krb5-user krb5-config libsasl2-modules-gssapi-mit   I though about zipping the krb5-config krb5-user libgssrpc4 libkadm5clnt-mit9 libkadm5srv-mit9 libkdb5-8 libsasl2-modules-gssapi-mit downloaded files (as seen on my server* log) and give him the instruction to where to put them. This may or .  What should I do, then?  *obs: the offline server is a similar version of my online server.

Right now I have 2 computers:   Has connection to the internet and has installed package A. Doesn't have connection to the WEB. On this PC I need to install package A.   I decided to download all needed packages using first PC and transfer them to the second PC via USB. I have searched how to get all needed packages for some deb installation and .  But when I run:  apt-get --print-uris --yes install A | grep ^\' | cut -d\' -f2 > downloads.list   on first PC I got empty file because this package is already installed there (and I don't want to uninstall it).  Also package A is very complicated and depends on package B which depends on package C and package C is not installed on the second PC.  So how can I download all needed packages? Or is there any other way of installing it?


I have just booted my clean Ubuntu 18.04 LTS VM and tried to install some application with sudo apt install.  But got error message:     E: Could not get lock /var/lib/dpkg/lock-frontend - open (11: Resource temporarily unavailable)       E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?   What process created the /var/lib/dpkg/lock-frontend file in Ubuntu? How to gently stop it and take manual control on APT?

I get this error when trying to use apt-get:  E: Could not get lock /var/lib/dpkg/lock - open (11 Resource temporarily unavailable) E: Unable to lock the administration directory (/var/lib/dpkg/) is another process using it?     How can I fix this?


I have all credentials of the computer in remote computer network consisting of several computers. I know it's local name and ip, also user and pass. And public ip of this network.

let's imagine i am at school with an android phone. I have a computer at home and that computer has a virtual machine working on it. here is the scenario, client and virtual client has ssh-client and ssh-server both and they can communicate each other in the local network.  when i want to connect to my virtual client from school by android phone through internet there must be an ip address.  the problem is virtual machine and client has the same public ip. so how do i connect one of the two machines?


I just wanted to replace Nautilus with Dolphin, installed it, but it looks like this:       How can i make dolphin look better, and make it default file manager?

I've recently came back to Ubuntu from Kubuntu, but I really like Dolphin. Is there any way how to set it up as default file manager?


I'm trying to remove apps I'll never use again from my purchase history.  Does anyone know how I might be able to do this? I don't want to just hide them, I want them gone. Realize same question was asked a few years ago which received a response that it's not possible.  Was hoping something has changed.  Thanks

So... Over the period of 2 years owning my beloved iPhone 3GS, I have found many useful apps that I use very frequently. However, in the process of finding these apps, I have also downloaded much, much more crappy apps.  With the introduction of the "Purchased" section on the App Store, many of the hundreds of apps I downloaded (mostly crappy) have popped up again. The apps are an eyesore and clutter up the whole space. Is there a way for me to delete them (from my account) forever, or at least hide them?


I need help jailbreaking my chromebook. I have a HP Chromebook 14. I've downloaded ubuntu the "precise" version but i want to install the latest that i can with chromebook. im not sure if i can just not jailbreak my chromebook and just download it from the site directly im completely clueless. but im trying to download an auto clicker.

Is installing Ubuntu on my Chromebook potentially dangerous to anything on my Chromebook? I got it as a gift, so I don't want to destroy anything that is important on the laptop. Also, which is better for being able to safely install Ubuntu: ChrUbuntu or Crouton? I'm using the Samsung Chromebook 3 (as described by the quick-start manual). Does that make any other differences as well?


I want to learn WPF programming. I want to know binding the gender of staff to the ComboBox:  class Staff {     public int Gender {get; set;} }  class ViewModel {     private Staff _staff     public Staff Staff {         get {return _staff;}         set {             _staff = value;             RaisePropertyChangedEvent("Staff");         }     } }  <ComboBox SelectedItem="{Binding Staff.Gender, Converter={StaticResource GenderConverter}}">     <ComboBoxItem IsSelected="True" Content="{StaticResource strGenderMale}"/>     <ComboBoxItem Content="{StaticResource strGenderFemale}"/>     <ComboBoxItem  Content="{StaticResource strGenderOther}"/> </ComboBox>   GenderConverter is my customized Converter to convert int <-> string (0: male, 1: female, 2: other)  public class IntegerToGenderConverter : IValueConverter {     public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) {         if (value is int) {             if ((int)value == MyConstants.GENDER_MALE) { //GENDER_MALE is 1                 return MyConstants.GENDER_MALE_STR; //GENDER_MALE_STR is the string: "Male"             }             if ((int)value == MyConstants.GENDER_FEMALE) {                 return MyConstants.GENDER_FEMALE_STR;             }         }         return MyConstants.GENDER_OTHER_STR;     }      public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) {         switch (value.ToString()) {             case MyConstants.GENDER_MALE_STR:                 return MyConstants.GENDER_MALE;             case MyConstants.GENDER_FEMALE_STR:                 return MyConstants.GENDER_FEMALE;             default:                 return MyConstants.GENDER_OTHER;         }     } }   When i run the application, the staff is not null (everything else (such as name, date of birth...) is bound well except Gender :(  Edit:  When I created a List Genders and bound it to the ComboBox's property ItemsSource instead of using  tags, it worked well. Why???

As an example take the following code:  public enum ExampleEnum { FooBar, BarFoo }  public class ExampleClass : INotifyPropertyChanged {     private ExampleEnum example;      public ExampleEnum ExampleProperty      { get { return example; } { /* set and notify */; } } }   I want a to databind the property ExampleProperty to a ComboBox, so that it shows the options "FooBar" and "BarFoo" and works in mode TwoWay. Optimally I want my ComboBox definition to look something like this:  <ComboBox ItemsSource="What goes here?" SelectedItem="{Binding Path=ExampleProperty}" />   Currently I have handlers for the ComboBox.SelectionChanged and ExampleClass.PropertyChanged events installed in my Window where I do the binding manually.  Is there a better or some kind of canonical way? Would you usually use Converters and how would you populate the ComboBox with the right values? I don't even want to get started with i18n right now.  Edit  So one question was answered: How do I populate the ComboBox with the right values.  Retrieve Enum values as a list of strings via an ObjectDataProvider from the static Enum.GetValues method:  <Window.Resources>     <ObjectDataProvider MethodName="GetValues"         ObjectType="{x:Type sys:Enum}"         x:Key="ExampleEnumValues">         <ObjectDataProvider.MethodParameters>             <x:Type TypeName="ExampleEnum" />         </ObjectDataProvider.MethodParameters>     </ObjectDataProvider> </Window.Resources>   This I can use as an ItemsSource for my ComboBox:  <ComboBox ItemsSource="{Binding Source={StaticResource ExampleEnumValues}}"/>


I am trying to build a one-time pad encryption software and I am thinking about simply using /dev/random to generate keys.  My question is: Is it truly random or pseudo-random? Or would it be better to use data from (for example) a website like random.org?

If I want to generate a few one-time pads, is it OK to just read required number of bytes from /dev/urandom without weakening information-theoretical security?


I have a lot of screen real estate, and am constantly "losing" my mouse.  I'd like to have a simple way of easily finding the mouse that doesn't have to be reconfigured when I undock from my 28 inch monitor and rely on my retina display.  Windows has a feature that allows for "mouse trails" so I can easily find the pointer wherever it is.  How can I get similar functionality on the Mac?  I looked under the "accessibility" tab but found nothing.

Due to a stroke, I have had some vision impairment in that I sometimes have a hard time locating my mouse pointer on the screen.  I have tried making the mouse pointer larger which helps but is still not the solution.  I am new to the Mac world and would appreciate your help.  In Windows, there is an option where pressing the CTRL key will help to identify the mouse pointer using a temporary display of several radiating concentric circles around the mouse pointer.  Is there something like this on OS X?


When I looked in the purchased section in the Mac App Store the app was not there. Am I doing something wrong or do app have to be purchased on both iOS App Store and Mac App Store?

I bought a paid app on my iMac, and a few months later tried to download it on my iPhone but it’s forcing me to pay again for it. I thought the App Store linked purchases on multiple devices?


Let $R$ be commutative ring with $1$. Let $f \in R$. Suppose $f$ is not nilpotent in $R$. We need to show $R_f \cong R[x]/(fx-1)$, with $D = \{f^n: n \ge 0\}$ and where $R_f = D^{-1}R$. I am given the following hint: [Show that the map $\phi : R[x] \to R_f$ gives a surjective ring homomorphism and the universal property in   Theorem 36 gives an inverse.]           Theorem 36: Let $R$ be a commutative ring with 1 and let $D$ be a multiplicatively closed subset of R containing 1. Then there is a commutative ring $D^{-1}R$ and a ring     homomorphism $\pi: R \to D^{-1}R$ satisfying the following universal property: for any     homomorphism $\psi : R \to S$ of commutative rings that sends 1 to 1 such that $\psi(d)$ is a     unit in $S$ for every $d \in D$, there is a unique homomorphism $\Psi: D^{-1}R \to S$ such that $\Psi \circ\pi = \psi$.      I'm not sure where to go after I define $\phi$. How does the theorem give me an inverse, and how does that show that the two rings are isomorphic? Help would highly, highly be appreciated.

In Dummit and Foote, Exercise 15.18 (p. 727 3rd edition) one is asked to prove that for a commutative ring with unity $R$, and $f$ a non-nilpotent element of $R$, that the localization $R_f$ is isomorphic to $R[x]/(xf - 1)$.  I have done this, using the strategy outlined in the problem, using the universal property of $R_f$ proved in Theorem 36. The problem I have is this:  If $R_f \cong R[x]/(xf - 1)$ and $\phi:R[x] \to R_f$ is a surjective homomorphism, it stands to reason that $\text{ker}(\phi)$ should be $(xf - 1)$. I cannot show this directly. The surjective homomorphism I have in mind is, for:  $p(x) = a_0 + a_1x + \cdots + a_mx^m$  $\phi(p) = \dfrac{a_0}{1} + \dfrac{a_1}{f} + \cdots + \dfrac{a_m}{f^m}$  It is clear to me that $\phi$ annihilates $(xf - 1)$, so that ideal is contained in the kernel. What I cannot show is the other containment, or equivalently:  If $\phi(g) = 0_{R_f}$ then $g(x) \in (xf - 1)$. The trouble I am running into is that $R$ might be a "bad" ring, containing a lot of zero-divisors, $f$ might even be a zero-divisor (being non-nilpotent is a considerably weaker property), so the usual polynomial tricks of the division algorithm or using the irreducibility of $xf - 1$ aren't much use, here.  I feel I am missing something obvious....what is it?


I have been running Ubuntu 13.04 for quite some time and though I would upgrade to 14.04 LTS as I also wanted to migrate to a larger SSD disk.  In the past it was tricky to install Ubuntu because the HP Dreamcolor display in my HP EliteBook 8740w needed the NVIDIA drivers. This was solved using an external monitor to install Ubuntu and then install the proprietary NVIDIA drivers.  When trying to install 14.04 LTS, this procedure doesn't work - all screens (VGA, Display-port and built in) remain black except for some funny coloured characters.  I though I could install the old 13.04 and then perform an upgrade. This has also proven to be tricky as "13.04 it is no longer supported" and a lot of references to packages doesn’t seem to be valid any more. I get 13.04 installed but have not managed to get the NVIDIA driver working. (It works beautifully on my existing installation (other hdd)).  Advice appreciated

I am trying to boot Ubuntu on my computer.  When I boot Ubuntu, it boots to a black screen.  How can I fix this? Table of Contents:


I am using \usepackage[style=numeric,sorting=none]{biblatex} to make my bibliography but it automatically includes fields such as ISSN, DOI, URL etc that I don't want to display as which fields are included varies so much between journal articles when I produce my .bib file by exporting from Mendeley. I could go through and delete all the fields I do not want from the .bib file but this would be extremely time consuming for the number of citations in a thesis! Is there a way (the simpler the better - I am new to LaTeX!) to customise which fields are included in the bibliography (either in LaTeX or in Mendeley)?  Thanks so much!

My .bib files are generated by Mendley desktop and usually contain URLs, ISSN and DOIs, but I don't want those to be displayed in my list of references. How can I get rid of them (short of deleting those from the entries, I just want to not display them...) I am using biblatex.


Arriving at JavaScript from a C# and Java background, I am surprised to see the below snippet of code works. The variable s as I return it from the sum function should not exist in this scope.  How does JavaScript scope work in the following example? The scope of s should be limited to inside the for loop but not after its closing curly bracket. The equivalent snippet in Java or C# will state something like s does not exist in the current context.    function sum(arr) {     for(var i = 0, s = 0; i < arr.length; s += arr[i++]) {         // scope of s is okay here     }     return s; // but, shouldn't this be a violation of scope? }  // some test code var data = [1,2,3,4]; var total = sum(data); console.log(total);

What is the scope of variables in javascript? Do they have the same scope inside as opposed to outside a function? Or does it even matter? Also, where are the variables stored if they are defined globally?


There is  paper:   In equation (36) of this, the second line ($\omega^{+ij} =\dots$), there is a term $\partial_{[i}\bar\lambda\delta_{j\,]k}$ that I didn't understand. What does this notation mean?

I know that  $A_{[a} B_{b]} = \frac{1}{2!}(A_{a}B_{b} - A_{b}B_{a})$  But how can write $E_{[a} F_{bc]}$ like the above?  Can you provide a reference where this notational matter is discussed?


Look at the following sentence.  In order to keep fit, we must eat healthy food.  Can we also say "eat healthy" and "eat healthily" to mean eat healthy food ?  In order to keep fit, we must eat healthy. In order to keep fit, we must eat healthily.  Are they both correct or is either of them wrong? Thanks for Kate Bunting's comment. I am asking this because I know "go to bed hungry" makes sense and is quite different from "go to bed hungrily" Does "eat healthy" also make sense?

Why do we say "eat healthy" instead of "eat healthily", even though the latter is the only "correct" one, according to the comments in      What came first: ads saying "eat healthy", or the grammatical acceptability of such a phrase?    Merriam-Webster does not consider "healthy" to be an adverb, unlike "quick": , and therefore this question is not a duplicate of


I'm trying to make a number guessing game that prints only to the console so far, problem is my knowledge and problem solving is in its infancy and I wanted to up the program to guess between 1 and 1,000,000 but I can't figure out how to add the commas to the integers (Or if that's even allowed) so as to make reading them when printed to the console easier to read for the player.  int max; int min; int guess; max = 1000000;  min = 1; guess = 500000;

I want to add a comma in the thousands place for a number.     String.Format()?


Is hoard of bugs to be treated as singular or plural?      ...and what we mean by that is that a hoard of bugs were squashed relentlessly in this release     ...and what we mean by that is that a hoard of bugs was squashed relentlessly in this release

Possible Duplicate:             Can anyone help me determine the correct verb in this sentence? I am not sure what to do. If it were not such a complex introductory phrase, it would be more obvious. The general consensus of my friends who are not professional writers is that the verb should be are.   To me the question is whether or not the subject is singular (i.e., “a large collective volume of paint”, perhaps in a tank) or plural (a lot of the individual gallon containers of paint).  If simplified to other options, it would be like these:   Paint is sold. Gallons of paint are sold. More paint is sold. More gallons of paint are sold. More than 1000 gallons of paint is sold. [emphasis on total volume] More than 1000 gallons of paint are sold. [emphasis on individual containers]


I want to send an email using sendmail command in bash. The email should get it's body by reading Input_file_HTML and it should send same input file as an attachment too. To do so I have tried the following.  sendmail_touser() { cat - ${Input_file_HTML} << EOF | /usr/sbin/sendmail -oi -t From: ${MAILFROM} To: ${MAILTO} Subject: $1 Content-Type: text/html; charset=us-ascii cat ${Input_file_HTML} Content-Transfer-Encoding: 7bit MIME-Version: 1.0 Content-Disposition: attachment; filename: ${Input_file_HTML} EOF }   The above command is giving an email with only the attachment of Input_file_HTML and it is not writing it in the body of email. Could you please help/guide me on same? I am using outlook as the email client. I have even removed the cat command in above command, but it also is not working.

I've created a script that runs every night on my Linux server that uses mysqldump to back up each of my MySQL databases to .sql files and packages them together as a compressed .tar file.  The next step I want to accomplish is to send that tar file through email to a remote email server for safekeeping.  I've been able to send the raw script in the body an email by piping the backup text file to mailx like so:  $ cat mysqldbbackup.sql | mailx backup@email.com   cat echoes the backup file's text which is piped into the mailx program with the recipient's email address passed as an argument.  While this accomplishes what I need, I think it could be one step better, Is there any way, using shell scripts or otherwise, to send the compressed .tar file to an outgoing email message as an attachment?  This would beat having to deal with very long email messages which contain header data and often have word-wrapping issues etc.


How would you suggest to list centuries here:   Suspended hyphen:     In the late nineteenth- and early twentieth-centuries...   Separated by commas:     In the late nineteenth-, and early twentieth-, centuries...   Spelled out in full:     In the late nineteenth and early twentieth centuries...   Or, finally, condensed:     In the late 19th and early 20th centuries...   Any help, or reference to style manuals would be hugely appreciated!

I am not that punctuation-savy, so I have one question for my research title.  Currently it is      Social crowdfunding:  individual- and project-related determinants of success.    Empirical investigation on Kickstarter   Here I have two questions.   Is it right to say individual- or just individual?  Should there be a period after "Empirical investigation on Kickstarter"?


I'm trying to understand why we have to use new operator in C++. I have wrote short program:  int N; std::cin >> N; int tab[N];  for (int i = 0; i < N; i++)  tab[i] = i + 1;  for (int i = 0; i < N; i++)  std::cout << "tab[" << i << "] = " << tab[i] << std::endl;   This program works correctly. The same behavior I have noticed in C using this algorithm (instead of malloc() function).

I've been using C++ for a short while, and I've been wondering about the new keyword. Simply, should I be using it, or not?  1) With the new keyword...  MyClass* myClass = new MyClass(); myClass->MyField = "Hello world!";   2) Without the new keyword...  MyClass myClass; myClass.MyField = "Hello world!";   From an implementation perspective, they don't seem that different (but I'm sure they are)... However, my primary language is C#, and of course the 1st method is what I'm used to.  The difficulty seems to be that method 1 is harder to use with the std C++ classes.  Which method should I use?  Update 1:  I recently used the new keyword for heap memory (or free store) for a large array which was going out of scope (i.e. being returned from a function). Where before I was using the stack, which caused half of the elements to be corrupt outside of scope, switching to heap usage ensured that the elements were in tact. Yay!  Update 2:  A friend of mine recently told me there's a simple rule for using the new keyword; every time you type new, type delete.  Foobar *foobar = new Foobar(); delete foobar; // TODO: Move this to the right place.   This helps to prevent memory leaks, as you always have to put the delete somewhere (i.e. when you cut and paste it to either a destructor or otherwise).


I copied all the contents of a hard drive to another. It wont boot of it though. I need it to. I deleted a partition and used a data recovery, The files i copied were the recovered ones. It recovered EVERY file.

I recently installed a Linux operating  system (backtrack 5 r3) I couldn't connect to the internet with it so I removed the partition manually. After that, whenever I turn on my computer it goes to a command line that says "error no File-system found" "Grub Rescue/"  I have tried f12 and booted into all the options. I also put Ubuntu 12.04 on my flash drive and tried installing it on the computer, the installation failed saying "No Available Space"  My hard-drive is 500g with about 250 left. I put the hard drive in another computer (as a secondary just to see the files. It had 2 partitions a main and one with 1 gig. I formatted it with no difference.  My Problem: I can't boot into Windows


I'm trying to identify a sci-fi movie I saw in the late 80's to early 90's, for some reason I want to say it was on Cinemax.   The highlights I can recall:   The story focused on passengers on a large starship; Opening of the film was some type of facility or star port that featured a massive dome that was opening to either allow a ship/shuttle to land or launch (not positive about this, I just recall early in the film some time of massive dome opening up and passengers all gathering there); Ship was mostly automated, only crew were a mother and a son who survived in isolated environments (immunologically compromised or somehow modified so they couldn't be around normal humans); At one point the crew-son is in a sealed suit/pod and is helping a female passenger in a space suit travel along scaffolding; The crew-son is protecting/helping the passengers against his mother.    For some reason it reminded me of The Ship Who Sang series, except that it's a movie.

I remember seeing this sci-fi movie in video stores on VHS but don't know the name. I'm guessing its close to late 70s but more likely an 80s movie. It's in color and I remember the graphics as decent. It's been some time so I'll give what I remember.   This is a movie that takes place in space.  There is a human (or at least appears human) male who seems to float around in a pod with a glass top. It looks like the cryo units in Alien but floats around. He seems to believe an alien or creature is his mother, who tells him the humans who arrive will kill him.  The movie ends with him and a female seen flying through space (he allows her inside with him) as the only survivors of some sort of disaster.


I need to use an iterator in a model process. My problem is that I always only have one output instead of three. There are three Polygons e to run. The output always only contains the last Polygon one and I have no clue why. I did name the output xy* Value * so that cannot be the problem.   Anyone any ideas?   I'm gonna explain it a bit more detailed.  I've seen the other question with exactly the same title but I couldnt find an answer there.   I need do build a cost distance model which is based on a shp with 3 startpoints as input fpr cost distance tool and 3 shp with each containing an goal point as input for the cost path tool. I want to use an iterator so that it can run all three points with one run. The model should also be with variables so that it can be used for many regions. This is how it looks like with variables:     The names are written in German but I guess you can understand it. It works perfectly exept of the fact that it only puts out the last cost path. So the iterator works and runs each path correctly but only saves the last one.  I did name the output with %Value% (thats what I meant yesterday with Value.. I was just a bit too tired to realise that I didnt wright it correctly..).  So that cannot be the reason why it doesnt save the first two outputs.   I've also tried to run it with given inputs without variables but that didnt make it any better:     I also already tried collect value but that didnt change anything.   I really hope you guys have an idea.   Another problem is that I dont understand how I have to use an iterator with variables. Because the output name is meant to be empty. That means I cannot write %Value%.

Using Arc 10.3.1, if I manually enter the names of multiple shapefiles (all from the same folder) into the Check Geometry tool, the (single) output table lists the errors that exist in all of the shapefiles.    That is, only one output table is created, even if multiple input shapefiles have errors.  For example, if two shapefiles have errors, both will be listed in the single output table. Here's a screen print of the input:    However, if I iterate those same shapefiles (using the Feature Classes option), the output table only lists the last shapefile that went through the iteration.  Here's a screenshot of the model:     I suspect that the iterator is running Check Geometry not once, but three times, with a single input shapefile going through each iteration, overwriting the previous output.    How do I get the iterator to list all of the shapefiles with errors, either in separate output tables or aggregated in a single output table?


Consider a group , where any element has $ord(g)=2$. Could we say that $ G \cong F_{2} $? My idea was : consider all generating elements and say $g_{1} = e_{1} \dots$ am I right?

Let $G$ be a group s.t. every non-identity element has order 2. If $G$ is finite, prove $|G| = 2^n$ and $G \simeq C_2 \times C_2 \times\cdots\times C_2$  I know G is abelian since $ab = (ab)^{-1} = b^{-1} a^{-1} = ba$ for all non-trivial $a,b \in G$ so I have several questions remaining:    How do I prove $|G| = 2^n$? I'd like to say we use induction to prove this but I'm at a loss as to where I would start. Why is $G \simeq C_2 \times C_2 \times\cdots\times C_2$?   I've read several answers to question similar to this yet unfortunately most of them involve Galois Fields and vector spaces, both concepts I'm unfamiliar with. I'd greatly appreciate an intuitive proof.


I upgraded to 18.10 from 18.04 using do-release-upgrade. The upgrade was successful, but on rebooting, the system seems to freeze after the Plymouth splash screen and systemd (OK/FAIL) status output, but before the desktop. I don't get a tty login either. This happens with both the 4.18.0-10-generic and 4.15.0-10-generic kernels.  Updates:  Using another PC, I can ssh into the host and then run sudo lightdm to bring up the desktop.  Changing grub options from quiet splash to nomodeset did not fix the problem.  Renaming /etc/X11/xorg.conf to xorg.conf.bak did not fix the problem.

I am trying to boot Ubuntu on my computer.  When I boot Ubuntu, it boots to a black screen.  How can I fix this? Table of Contents:


I've recently bought a magnetic cover for my tablet (a bamboo smart cover for Asus Transformer Pad TF303CL). What puzzles me is that whenever I open the cover, the screen turns on. How does the tablet know when I open the cover?  The cover isn't connected in any way to the tablet, AFAIK. The only way that I could think of is if the tablet is using the light sensor, but then why doesn't it turn on the screen when I use my finger to cover the sensor? Or when I turn the light off and then on again?

Can someone explain how tablets like Nexus 7 detects a magnetic cover closing? I have tried putting magnets over the spots where the magnets in the cover are, but it will not lock. How does the tablet know if it is a cover?


the % character seems to have a lot of uses. So far, I have encountered it in the following places:  For writing comments  % Schrodinger wave equation $$\nabla^2\psi + \frac{8\pi^2m}{h^2}(E-V) = 0$$   (I may be incorrect here) For splitting commands over multiple lines (reference )  \newcounter{bull} \newcommand{\showbullcntr}[1]{% \setcounter{bull}{#1}% \bullcntr{bull}% }   In conjunction with minipage, to remove the leading space inserted (adapted from  question)  \noindent \begin{minipage}{0.5\linewidth}    ... \end{minipage}% \begin{minipage}{0.5\linewidth}    ... \end{minipage}  Could someone please explain, in detail, the various uses of the % character in LaTeX? In particular, why is it used after the first instance of \end{minipage}?

I see that the code in many packages and examples contains percent signs % at the end of (many) lines. What are they used for? Do they affect the parsing of those lines?


Is there a way to show the formatting of the referenced cells from another sheet in Google Sheets?  For example I have a sheet named balance with A1 having a comment and a blue background. When I reference this cell in another sheet within the same document (called rent) - ie =balance! A1 then only the value of the cell shows up - not the comment or the background color.  It would also be useful to know if this can be done with the ImportRange() function so as to have this functionality available when referencing other spreadsheet documents.

Is it possible to reference a cell in Google Sheets so that cell where it gets displayed also displays it using the same text and cell colour formatting?  =A1   Will only reference cell's value. But if that particular cell has red background and white text I'd like that to be copied as well.  I'm leaning toward existing formula solutions rather than scripts. If applicable of course.


If $I$ and $J$ are ideals in a ring $R$ with 1 which are  co-maximal, i.e $I+J = R$, show that $I^m$ and $J^n$ are co-maximal for all $m,n$ in $\mathbb{N}$  Work done:     Should I proceed using    By taking $$K=I^m+J^m \neq R$$  Let $$S=\{I,J \in R \mid I^m+J^n \neq R \}$$ be the required partially order set ordered by inclusion then  $$I+J \subseteq I^n+J \subseteq I^n+J^m \subseteq \ldots $$  Then, I think this chain doesn't have an upper bound...as $I^m+J^n \neq R$ for all $ m,n \in \mathbb N$. Am I right??  Thanks for any help!!

Let $R$ be a commutative ring and $I_1, \dots, I_n$ pairwise comaximal ideals in $R$, i.e., $I_i + I_j = R$ for $i \neq j$. Why are the ideals $I_1^{n_1}, ... , I_r^{n_r}$ (for any $n_1,...,n_r \in\mathbb N$) also comaximal?


Hey guys so I’m having trouble with testing my scheduled apex class that is sending an email. The problem that is occurring for me is that when I click test, my System.assertEquals are not true meaning the job did not execute and the email did not send. Keep in mind that it works in my sandbox when I simply schedule it through the UI, but for my test class. It is not doing the same. So my main question is, how do I execute my scheduled job in my test class? Here is the original class, and the test class. Class: global class Survey_Reminder implements Schedulable {   public Static  String Chron= '0 35 11 ? 6 3'; global void execute(SchedulableContext ctx) {         List<test_sites__c> sitelist = [SELECT Name,Last_Survey_Date__c,Id FROM test_sites__c WHERE Status__c = 'Active'  AND  Last_Survey_Date__c <= :Date.Today().addDays(-30) AND Last_Survey_Date__c <= TODAY LIMIT 10];     String sitestring= ' ';     if(sitelist != null)     {     for(test_sites__c site : sitelist)     {          sitestring += site.Name + ' ';               }     } else     {         sitestring = 'No sites to Report';     }                Messaging.SingleEmailMessage mail = new Messaging.SingleEmailMessage();             String[] toAddress = new String[] {'testemail@testemaill.com'};             mail.setToAddresses(toAddress);             mail.setSubject('Test Email');             mail.setBccSender(false);             mail.setSenderDisplayName('Survey Reminder');             mail.setPlainTextBody('Testing email  ' + sitestring);             mail.setHtmlBody('<p>Testing email   </p> '+ sitestring);             Messaging.sendEmail(new Messaging.SingleEmailMessage[] { mail });  } }  Test: @isTest private class Reminder_Test {          static testmethod void testScheduledJob()     {List<test_sites__c> sites2 =  [SELECT Name FROM test_sites__c];      Integer sitecount = sites2.size();      System.debug('site count before insert: '+ sitecount);                        List<test_sites__c> sites = new List<test_sites__c>();         Date survey =  Date.today().addDays(-30);         for(integer i = 0; i<4; i++)         {             test_sites__c site = new test_sites__c();             site.Name = ' '+ i;              site.Last_Survey_Date__c= survey;                                     sites.add(site);         }         insert sites;            sites2 =  [SELECT Name FROM test_sites__c];       sitecount = sites2.size();      System.debug('site count after insert: '+ sitecount);               Test.StartTest();         Survey_Reminder reminder = new Survey_Reminder();          String Job = System.schedule('Test Rem', Survey_Reminder.Chron, reminder);                 integer beforeinvocations = Limits.getEmailInvocations();         System.assertEquals(0,beforeinvocations,'no email sent');                  Test.stopTest();         CronTrigger ct = [Select Id,CronExpression,TimesTriggered,NextFireTime FROM CronTrigger WHERE id = :Job];                  System.assertEquals(1, ct.TimesTriggered);         System.assertEquals(1, beforeinvocations,'email sent');               }  }

This is a canonical question and answer developed by the community to help address common questions. If you've been directed here, or your question has been closed as a duplicate, please look through the resources here and use them to shape more specific questions. To browse all canonical questions and answers, including more unit test resources, navigate to the  tag.  I'm testing asynchronous code - like Batch Apex, Queueable Apex, @future methods, or Scheduled Apex - and I'm getting unexpected results. It seems like portions of my code aren't running, or I'm getting confusing errors about batch invocations. How do I effectively test this kind of code?


To execute a script, I have to:   Write the script Make it executable Double click it, which shows this window:   Click the "Run" button.    How can I execute the script directly, without showing the dialog?

When I double-click on a script in Nautilus to run it, the script just opens in my text editor with no option to run it. Using Nautilus, how do I run executable text files and/or scripts?


Say you're a 1st-level wizard and also a 1st-level druid. Could you, as a druid, prepare spells that both classes have, like Detect Magic and Ice Knife, then, since they're now "prepared" for you, write them in your spellbook so that you can cast them as a wizard, allowing you to cast with intelligence without needing to choose them on level-up or find them in a book/scroll?  Also, would it cost 10 gp per level or 50 gp?  As far as I can tell RAW seems to say yes but I just wanna make sure I'm not missing anything.

Can a multi-class Bard/Wizard write spells known from their Bard class, into their wizard spellbook?  e.g. they know the Comprehend Languages as a Bard spell, and want to write it directly into their wizard's spellbook?  And what is the cost? ... i.e. 1 hour and 10 gp because they know it, or 2 hours and 50 gp because they  have to experiment with casting it as a wizard?


I am wondering what technology is used in Stack Exchange to create the graphs like "reputation graph" in the network profile. Is it ?

Viewing reputation changes on Stack Overflow produces a nice graph which can be 'zoomed in' on to view more detailed reputation changes, for . Is this using a library or is it custom written? If it's a library, which is it?


Strange things happen at night in sleeping cars in a train. Strangers enter your cabin accidentially, smugglers hiding cigarettes, someone is sleeping in your bed when you've been away for some minutes etc.  When travelling in a sleeping car and not having an opportunity to lock valuable things away, how to protect them from being stolen when you have a tight sleep like I have sometimes? I have things in mind like Notebooks, Tablets, bigger Cameras and things that do not fit into your pocket or under your pillow.

I've heard that in some overnight trains, rooms don't lock (no door); instead its just a curtain. This means thieves can get in and out easily. Is this true? If so, how do my friends and I keep ourselves and our belongings safe? (Even if we secured it with some sort of lock and cable, if we were sleeping, I would imagine that thieves could just open everything up.)


The bottom part is not clickable.  What's up with that?

Which browsers are officially supported by Stack Exchange?  Also, what else is needed in order to use every feature of the site?


What is Automorphism group of $Z \oplus Z$? Please give some hints. I feel it is some matrix group looking as the group as a Z module.

I want to prove that:     If $F$ is a free abelian group of rank $n$, then $\text{Aut}(F)$ is isomorphic to the multiplicative group of all $n\times n$ matrices over $\mathbb Z$ with $\text{det}=\pm1$.   What I have tried:  Since $F$ is a free abelian group of rank $n$ so I can write $F=\langle x_1,x_2,...,x_n\rangle$. If $\phi\in\text{Aut}(F)$ then it should map any $x_i$ to another element $x_j$ of the basis $X=\{x_1,x_2,...,x_n\}$. My idea is to map any element of $\text{Aut}(F)$ to a suitable matrix. For example when $n=2$: $$\phi_1:=\{x_1\to x_1, x_2\to x_2\}\Longrightarrow \left( \begin{array}{cc} 1 & 0 \\ 0 & 1 \end{array} \right)\\ \phi_2:=\{x_1\to x_2, x_2\to x_1\}\Longrightarrow \left( \begin{array}{cc} 0 & 1 \\  1 & 0 \end{array} \right)$$  Am I on a right approach? Or there is another better way? Thanks.


Zoom Issues,Hello, I am a noob when it comes to blender, so I apologize up front for not being able to communicate the problem better.  I am following blender guru tutorial on how to model a donut with icing and I have the camera zoomed in for a close up of the donut but when I hit render it is in a zoomed out position, the donut is far away.  My clipping distance is .001 so I don't think it's a clipping issue.  It's as if no matter where I position or zoom camera to, the render is operating on it's own and positioning the camera and focal length farther from my object. I've tried with both EEvee and Cycles but still have the same results. I've also tried different focal lengths, 35mm 50mm and 175mm but still resulting in a zoomed out render instead of a close up shot.

I am new to blender (yes, laugh at the obligatory doughnut) and I when I set up the camera (I use NUM 0 to access the camera and move it into position with "Lock camera to view") in the viewport it shows as the first attached image, but when I render it the image is further back as shown in the second image. Is this normal behavior or am I missing something?


I have the same problem , but none of the answers works for me.  I'm using pdfTeX 3.14, Biber 2.7, BibLatex 3.7. I've reinstalled these packages, cleared Biber cache, deleted .bbl file. The same result:  LaTeX Warning: Citation 'doe13' on page 1 undefined on input line 24. LateX Warning: Empty bibliography on input line 28.   MWE (literally the same at the issue mentioned below):  \documentclass[a4paper]{article}  \usepackage[utf8]{inputenc} \usepackage{csquotes}  \RequirePackage{filecontents} \begin{filecontents}{refs.bib} @book{doe13,     address    = {City},     title      = {A nice title},     shorttitle = {Short title},     publisher  = {Publisher},     author     = {Doe, John},     year       = {2013} } \end{filecontents}  \usepackage[backend=biber]{biblatex} \addbibresource{refs.bib}  \begin{document}  Hello. \cite{doe13}.  \nocite{*}  \printbibliography  \end{document}

I've browsed the forums and found a number of posts that have addressed this issue, but none of the solutions seem to work for me. I have the following script that I just copied from the bibtex home page to get familiar with it. Instead of the citation number I get a question mark. I compile using Latex+Bibtex+Latex+Latex+PDFLatex+ViewPDF just as has been previously suggested and the problem persists.   \documentclass[11pt]{article} \usepackage{cite}  \begin{document}  \title{My Article} \author{Nobody Jr.} \date{Today} \maketitle  Blablabla said Nobody ~\cite{Nobody06}.  \bibliography{mybib} \bibliographystyle{plain} \end{document}   My bibliography (Bib.bbl)  @misc{ Nobody06, author = "Nobody Jr", title = "My Article", year = "2006" }    Looking at previous posts one thing that is concerning is that my .bbl looks empty as shown below. Further, I don't have a .blg  \begin{thebibliography}{}  \end{thebibliography}


Are there any sites similar to (in terms of function and quality) Paul's Online Math Notes, 17Calculus.com, or PatrickJMT.com, for Physics (besides Khan Academy)?  I've googled this, but the sites I've found were described as high-school level, and I'm not sure if these would be adequate/appropriate for getting help for a college physics course.  I'm aware of and a frequent user of Khan Academy, but I'm hoping to find recommendations for additional resources.    Edit: I can see how it might seem this question duplicates , but it is different. Here's why:  I'm not seeking to learn physics online—I'm a college student who just began Physics I, and I'm looking for physics resources, similar to supplemental resources like Paul's Online Math Notes or 17calculus.com you might visit if you were studying calculus.  I've googled this before asking my question, naturally, but the resources I found were either geared towards high-school students, or they were in formats, such as forums, that aren't conducive to systematic learning/studying. I also explored this site looking for similar questions that might have the answers I'm seeking, but I did not find any that were directly in line with the sort of well-organized, systematic approach that makes it easy to find and follow information pertinent to that which you're currently studying. PatrickJMT.com is another example of the sort of site I had in mind; only the publisher focuses primarily on calculus and only touches briefly on physics problems.   If more advanced users community say the high-school resources are adequate for helping a student in a college Physics I course, that'd be great!  Otherwise, I was merely hoping for some recommendations for well-organized resources designed and/or appropriate for supplementing a conventional course, similar to the abundant resources you'd find for mathematics.  If you'd reopen my question, it would benefit not only me, but also huge numbers of other people who are or will be studying physics. Thanks!

I'm thinking of following some kind of education in physics online. I have a master degree in Computer Science and have reasonable good knowledge in physics. I would like a program of 1-2 years and I'm more interested in particle physics.   Is there any good online program that offer something similar?


I'm trying to print the length of this JSON Object to the console but I keep receiving 'undefined'.  This is being JSON encoded in PHP and then returned via ajax to an anonymous function as 'msg'  {"1":{"item_id":"shirt_straight--small","quantity":5},"2":{"item_id":"shirt_straight--medium","quantity":"2"}}   Printing to console:  console.log(msg.length); //undefined console.log(msg[1].item_id); //shirt_straight--small   I'm able to print the value of msg[1].item_id but I'm not able to get the length via msg.length  Thanks for your help.

I have a JavaScript object. Is there a built-in or accepted best practice way to get the length of this object? const myObject = new Object(); myObject["firstname"] = "Gareth"; myObject["lastname"] = "Simpson"; myObject["age"] = 21;


Could you please let me know your opinion about the following?           Subject: US editors and reviewers can no longer handle submissions by authors   employed by the Government of Iran              OFAC Sanctions       US editors and reviewers can no longer handle submissions by authors   employed by the Government of Iran      Dear Dr Bruno Granier,      The Office of Foreign Assets Control (OFAC) of the US Department of    the Treasury administers and enforces economic and trade sanctions. As   a result of OFAC sanctions we have been made aware that US editors, US   Elsevier staff and US reviewers are now unable to handle scientific    manuscripts where any of the authors are employed by the Government of   Iran. This includes the research departments of the various oil and   gas  companies which are deemed to be entities of the Government of   Iran.  We realize that this OFAC regulation will cause some   inconvenience in your role as an editor but Elsevier is legally   obliged to ensure that  all reasonable efforts are made to avoid   submissions from Iranian  government agencies and companies being   handled by US editors, US  Elsevier staff and US reviewers.  Please be   aware that editors, Elsevier staff and reviewers from outside the US   may still handle these  manuscripts and that this OFAC regulation does   not pertain to  manuscripts where the authors are based at Iranian   academic and research institutes.  Manuscripts originating from a   clinical setting that are  not government run, for example, a hospital   or clinical practice are  also exempt from this regulation.      To view the official OFAC regulation, please click here.  In practice   the result of these sanctions will mean that:         Submissions where any author is based in Iran, and is not at an  academic and research institution, cannot be handled by US-based    editors, US Elsevier staff, US reviewers, or any US citizens based    outside of the US.   If an Iranian author has dual affiliations (eg.  university and  government), their submission cannot be handled by US-based editors,   US  Elsevier staff, US reviewers, or any US citizens based outside of   the  US.   Affiliations of Iranian authors should therefore be checked, and any manuscripts which fall under this OFAC regulation delegated to a   non-US editor, before handling.   When assigning reviewers, affiliations of Iranian authors should  also be checked, and any papers which fall under this OFAC regulation    should only be sent to non-US reviewers. (As an editor you should do    what is reasonable to determine the nationality of a reviewer e.g.   check their email address. This check does not extend to emailing   reviewers  directly to confirm their nationality or location). Unless   there is  specific knowledge that a non-US-based reviewer is a US   citizen, editors can send such submissions to reviewers based outside   the US.   If your journal workflow involves all submissions being handled by  US-based Elsevier staff, they will reject these manuscripts outright    before they reach you.   Should there be no suitably qualified editor or reviewer, please reject the manuscript outright.      When rejecting manuscripts which fall under this OFAC regulation    please use the new EES Decision Term "Reject - OFAC Sanctions" and the   following text:      "As a result of OFAC sanctions all editorial staff who are    US-based/US nationals are unable to handle scientific manuscripts   which  are authored by Iranian scientists, employed by the Government   of Iran.  Based on this OFAC regulation we are unfortunately unable to   handle your manuscript. We wish you success with your submission to   another  Journal."          We apologize for the inconvenience this may cause. If you do have any   questions please contact your Publisher.       Sent on behalf of Dan Lovegrove      Cretaceous Research

Elsevier has started circulating  as a consequence of the  to the editors of their journals:     Subject: US editors and reviewers can no longer handle submissions by   authors employed by the Government of Iran            Dear Dr Bruno Granier,      The Office of Foreign Assets Control (OFAC) of the US Department of   the Treasury administers and enforces economic and trade sanctions. As   a result of OFAC sanctions we have been made aware that US editors, US   Elsevier staff and US reviewers are now unable to handle scientific   manuscripts where any of the authors are employed by the Government of   Iran. This includes the research departments of the various oil and   gas companies which are deemed to be entities of the Government of   Iran. We realize that this OFAC regulation will cause some   inconvenience in your role as an editor but Elsevier is legally   obliged to ensure that all reasonable efforts are made to avoid   submissions from Iranian government agencies and companies being   handled by US editors, US Elsevier staff and US reviewers. Please be   aware that editors, Elsevier staff and reviewers from outside the US   may still handle these manuscripts and that this OFAC regulation does   not pertain to manuscripts where the authors are based at Iranian   academic and research institutes. Manuscripts originating from a   clinical setting that are not government run, for example, a hospital   or clinical practice are also exempt from this regulation.      To view the official OFAC regulation, please click here. In practice   the result of these sanctions will mean that:      • Submissions where any author is based in Iran, and is not at an   academic and research institution, cannot be handled by US-based   editors, US Elsevier staff, US reviewers, or any US citizens based   outside of the US.      • If an Iranian author has dual affiliations (eg. university and   government), their submission cannot be handled by US-based editors,   US Elsevier staff, US reviewers, or any US citizens based outside of   the US.      • Affiliations of Iranian authors should therefore be checked, and any   manuscripts which fall under this OFAC regulation delegated to a   non-US editor, before handling.      • When assigning reviewers, affiliations of Iranian authors should   also be checked, and any papers which fall under this OFAC regulation   should only be sent to non-US reviewers. (As an editor you should do   what is reasonable to determine the nationality of a reviewer e.g.   check their email address. This check does not extend to emailing   reviewers directly to confirm their nationality or location). Unless   there is specific knowledge that a non-US-based reviewer is a US   citizen, editors can send such submissions to reviewers based outside   the US.      • If your journal workflow involves all submissions being handled by   US-based Elsevier staff, they will reject these manuscripts outright   before they reach you.      • Should there be no suitably qualified editor or reviewer, please   reject the manuscript outright.      When rejecting manuscripts which fall under this OFAC regulation   please use the new EES Decision Term "Reject - OFAC Sanctions" and the   following text:      "As a result of OFAC sanctions all editorial staff who are US-based/US   nationals are unable to handle scientific manuscripts which are   authored by Iranian scientists, employed by the Government of Iran.   Based on this OFAC regulation we are unfortunately unable to handle   your manuscript. We wish you success with your submission to another   Journal."       We apologize for the inconvenience this may cause. If you do have any   questions please contact your Publisher.       Sent on behalf of Dan Lovegrove      Cretaceous Research   Has there been any public response, by US editors or reviewers, stating whether they will obey (or not) the instruction? Also, does this letter conflict with the  of the  (all Elsevier journals are members of COPE as of January 2008)?


I just learned in class that if you toss 3 coins (a quarter, a dime and a nickel), the probability of getting 2 tails only is $\frac14$ and I don't really understand why.  My first intuition is that:  0 heads => 1 tail  1 head => 2 tails  2 heads => 1 tail  3 heads => 0 tails  Therefore, it should be $\frac14$. I understand that the number of permutations is 8, thus:  HHH THT  HHT THH  HTT TTH  TTT HTH  And if you take those with 2 tails, it's $\frac38$. But where is the flaw in my first reasoning? Why do I care about which coin gets Tails when I only want to know the probability of getting 2 tails?  Thanks for your help.

If you flip a coin three times, the possible outcomes are $\left \lbrace HHH, HHT, HTH, HTT, THH, THT, TTH, TTT \right \rbrace$ What is the probability of getting two tails?


I have a question about the following matrix:  $$         \begin{bmatrix}         1 & 2 & 3 \\         1 & 2 & 3 \\         1 & 2 & 3 \\         \end{bmatrix} $$  Find the eigenvalues without calculations and define your answer. Now, I was thinking about this problem. And I thought, yeah ok if you try the vector (1,1,1), you can find 6 as one eigenvalue (and I know you have a double multiplicity 0 too). But than you are doing sort of guessing/calculation work.  I see that the columns are linearly dependant. So I know the dimension of the column space and of the null space.  Thank you in advance.  EDIT: follow up question:  Ok, so you find that the dimension of the null space is 2, so there are 2 eigenvectors when the eigenvalue is 0. Now my question is, can the dimension of the eigenspace be bigger than the amount of eigenvalues? I guess not. I know it can be smaller

This question aims to create an ""  of numerous questions that ask about determinants of specific matrices (I may have missed a few):              The general question of this type is  Let $A$ be a square matrix of rank$~1$, let $I$ the identity matrix of the same size, and $\lambda$ a scalar. What is the determinant of $A+\lambda I$?  A clearly very closely related question is  What is the characteristic polynomial of a matrix $A$ of rank$~1$?


Let $0 < r < 1$. Compute $$\frac{1}{2 \pi} \int_0^{2 \pi} \frac{1 - r^2}{1 - 2r \cos(\theta) +r^2}d\theta$$ The hint is rewrite this integral as a complex line, but I still don't know how to to it

How do you integrate $\int \frac{1}{a + \cos x} dx$?  Is it solvable by elementary methods?  I was trying to do it while incorrectly solving a homework problem but I couldn't find the answer.  Thanks!


Do you need to spell it as food or as feed? Or is that different between UK english and USA english?

When I feed my cat or my dog, the package tends to say "Dog Food" or "Cat Food."  In contrast, I give my chickens "chicken feed" or "poultry feed."  Likewise, a cow's silage is her "feed."  Why does this distinction exist?  Is there an historical or grammatical explanation, or is it merely idiom?


Based on when the last child was born in the Continuum, we know that he's at least a millennia old. How old is he?  Following the death of Quinn, a massive Q Civil War broke out, as the forces of the status quo resisted the calls for change in the Continuum, by a faction led by Q himself. Seeking to end the conflict, Q devised a plan to mate with Kathryn Janeway, the captain of Voyager, in order to create a new Q/Human hybrid – a new breed of Q that would help bring an end to the civil war. Janeway, however, flatly refused.   Q then proposed mating with his old girlfriend (instead of with Janeway) and she agreed. The new child, nicknamed Junior, became the first child born in the Continuum for millennia, and his presence brought an end to the civil war. (VOY: "The Q and the Grey")  We know from this that 'the Q' can mate and do reproduce, so Q was in fact 'born'. He jumps back and forth along the timeline from the beginning of life on earth to the far distant future so that's no real help to pin down an actual age. Is he really just a 'child' by continuum standards, à la Trelane (TOS: "The Squire of Gothos") or as old as the ages?  How old is he really?  -edit  Some try to claim that all Q suddenly came into existence at the same instant 'forever ago', therefore this question is held as redundant and without merit. The 'forever before and after' Q position is generally rationalized because the Q are immortal, exceedingly powerful and can time travel. Just because a being can have breakfast in 2375 on a starship, hangout on earth for lunch watching people trying to learn flint-knapping in 15,000 BC (after misplacing an asteroid belt), then jump forward to 15,000 AD for dinner while watching people trying to learn flint-knapping doesn't mean they have always been.  Such a position is not only tenuously founded but ignores the contrary facts and evidence that Q have been born in the past and born in 'the present'.   Per Memory Alpha: "Based on descriptions by numerous Q, including the Q later known as Quinn, as well as Amanda Rogers (the child of two Q in Human form), the Q Continuum is a highly ordered society, but is also the result of eons of evolutionary stagnation."    This alone admits that the Q are in fact the result of evolution. Because of this current state of 'evolutionary stagnation', Q even admits to Riker during his temptation (TNG 1X10 "Hide and Q"), that humans could become the Q's equal in the distant future. Also because of this 'evolutionary stagnation', Junior's conception caused quite a stir. It hadn't been done in quite some time...   All this side issue and Continuum lore being interesting an all still doesn't address the base question posed; How old is Q (John de Lancie)? Has there ever been any hint or comments relating to HIS age?  -further addition-  de Lancie himself discusses that the 'possible' creative force behind the 'Q' character was very likely the 'Trelane' character from TOS; who by the end of the episode was found to actually be a child from an ultra advanced/evolved species. Many believe that Trelane was in fact a 'Q' though he needed to use a hidden power source for much of his antics.

In the Star Trek Universe where did the Q come from? I mean before they were Q in the Q Continuum? In Star Trek Voyager you learn that the race is somewhat intolerant of individualism (in the episode of the Q Civil War) but Q also suggest they have always been Q. Is that statement true, have the Q always been the Q? or were they a race that evolved into omniscience?


I'm new to using the terminal and I found a post on here with the following code that would allow me to zip multiple directories into individual zip files but I only got it to work once.  The code is this:   for i in */; do zip ‐r "${i%/}.zip" "$i"; done   but now when ever I use it I get the following error:   zip warning: name not matched:   and when I check the folder it creates a -r.zip  file.

I have a single directory that contains dozens of directories inside of it.  I'm new to command line and I'm struggling to come up with a command that will zip each sub-directory into a unique sub-directory.zip file.  So in the end my primary directory will be filled with all of my original sub-directories, plus the corresponding .zip files that contain the zipped up content of each sub-directory.  Is something like this possible? If so, please show me how it's done.


Let $A$ be a deformation retract of $X$ and $(j)_*: \pi_1(A,x_0) \to \pi_1(X,x_0)$ be the map induced by the inclusion map $j:A \to X$ (with $x_0 \in A$). I want now proof that for every $x \in \pi_1(X,x_0)$ there exists a $y \in \pi_1(A,x_0)$ s.t. $(j)_*([y])=x$.  Okay since $A$ is a deformation retract there exists a retraction $r: X \to A$ and we have that $r \circ j =id_A$ and $j \circ r \sim id_X$. But how to continue? Can somebody help me?  (We don't know about functoriality yet and so we can't use it.)

I just ran into an expression, and I would like to know what it converges to. $$\sum^{\infty}_{n=1} \frac{n}{(n-1)!}$$  Do you know if it converges to something (like $e$) or, in alternative, how to find out what it converges to?


Are photons , quantum waves, or both?  If I subdivide an electromagnetic field into smaller , should I eventually find an electromagnetic wave of a ?   How can individual quantum waves combine to form the macroscopic observable of an electromagnetic field?

I often hear about the wave-particle duality, and how particles exhibit properties of both particles and waves. However, I wonder, is this actually a duality? At the most fundamental level, we 'know' that everything is made up out of particles, whether those are photons, electrons, or maybe even strings. That light for example, also shows wave-like properties, why does that even matter? Don't we know that everything is made up of particles? In other words, wasn't Young wrong and Newton right, instead of them both being right?


For reasons I don't understand, the page formatting goes weird when I look at various stack exchange sites.  The error is not consistent.  It comes and goes as it pleases, depending on factors I have not yet been able to identify or isolate.  Even more weird, is if I try to change the profile. I get this/these errors...   Oops! There was a problem updating your profile:   unusual error updating your profile -- please try again!  So far, this site (meta.stackoverflow.com) and the regular stackoverflow.com do not exhibit this behavior. Most of my other StackExchange sites do this; when they feel like it.  Did I do something wrong ? Is this my problem ? Is it the system ? Has anyone else observed this or similar behavior ?  This is what the page looks like

I originally thought this was a mobile-theme related issue, but it is not. The css of the page does not load.  I guess I could clear my browser's cache. Is there any other option?      Edit: I do not have the "full site" option at the very bottom :(      Edit2: this is not an issue with the mobile theme. Here's my data according to the requests from      Samble CDN file:    My IP: 186.48.230.46   Tracing route to sstatic.stackexchange.netdna-cdn.com [69.174.57.102]   over a maximum of 30 hops:      1    21 ms    15 ms    25 ms  pucor1bras1.antel.net.uy [200.40.21.7]    2    16 ms    16 ms    18 ms  ibb2cor1-7-2-93.antel.net.uy [200.40.21.81]    3    20 ms    16 ms    16 ms  ibb2agu1-1-3.antel.net.uy [200.40.16.73]    4    29 ms    56 ms    21 ms  ibr3agu1-p1.antel.net.uy [200.40.18.38]    5   167 ms   159 ms   159 ms  So5-2-0-0-grtbueba2.red.telefonica-wholesale.net.7.16.84.in-addr.arpa [84.16.7.57]    6   156 ms   159 ms   163 ms  Xe5-1-3-0-grtmiabr7.red.telefonica-wholesale.net.125.142.94.in-addr.arpa [94.142.125.122]    7   200 ms   209 ms   186 ms  Xe-0-0-2-0-grtwaseq3.red.telefonica-wholesale.net [94.142.124.109]    8   198 ms     *      196 ms  213.140.55.90    9   199 ms   197 ms   204 ms  po2-20G.ar4.DCA3.gblx.net [67.16.133.82]   10   222 ms   195 ms   194 ms  PACKETEXCHANGE-LTD.TenGigabitEthernet2-4.ar4.DCA3.gblx.net    [64.211.83.106]   11   205 ms   197 ms   197 ms  te4-7.cr1.was2.us.packetexchange.net [69.174.120.125]   12   180 ms   206 ms   188 ms  69.174.31.2   13   194 ms   192 ms   221 ms  69.174.57.102        Trace complete.      Tracert to the origin:   Tracing route to sstatic.net [64.34.119.12]   over a maximum of 30 hops:      1    29 ms    33 ms    38 ms  pucor1bras1.antel.net.uy [200.40.21.7]    2    38 ms    19 ms    16 ms  ibb2cor2-7-2-93.antel.net.uy [200.40.21.209]    3    66 ms    93 ms    73 ms  ibb2uni2-1-3.antel.net.uy [200.40.16.98]    4    46 ms    24 ms    20 ms  ibr3uni1-p2.antel.net.uy [200.40.22.166]    5   214 ms   224 ms   198 ms  so-3-1-0.mia11.ip4.tinet.net [77.67.78.189]    6   221 ms   253 ms   224 ms  xe-0-2-0.nyc20.ip4.tinet.net [89.149.183.2]    7   301 ms   291 ms   304 ms  peer1-gw.ip4.tinet.net [77.67.70.194]    8   230 ms   225 ms   223 ms  10ge.xe-0-0-0.nyc-telx-dis-2.peer1.net [216.187.115.182]    9   263 ms   204 ms   199 ms  oc48-po3-0.nyc-75bre-dis-1.peer1.net [216.187.115.134]   10   209 ms   208 ms   207 ms  gwny01.stackoverflow.com [64.34.41.58]   11   202 ms   217 ms   221 ms  stackoverflow.com [64.34.119.12]        Trace complete.   Datacenter: Miami