in the process of learning Python. I understand the use of lambda, here's an example and link(for others).    mult3 = filter(lambda x: x % 3 == 0, [1, 2, 3, 4, 5, 6, 7, 8, 9])   Would assign [3, 6, 9] to  mult3.    Here is the code I was required to do in the book's quiz:  import tkinter  def counter(text):     """Add 1 every time the button is pressed"""      count = int(text.get())     text.set(count + 1)   window = tkinter.Tk() frame = tkinter.Frame(window) frame.pack()  var = tkinter.IntVar() var.set(0)  button = tkinter.Button(window, textvariable=var, command=lambda: counter(var)) button.pack()  tkinter.mainloop()   That is the verified solution. What I had come up with was the same except for the code in variable button. Here's my line:  button = tkinter.Button(window, textvariable=var, command=counter(var))   The absence of lambda prevents the counter from working. I don't understand why lambda is required? As I'm just calling a function I had made, I'm not requiring a new unnamed function..?  Thanks in advance for your time :)

For a person without a comp-sci background, what is a lambda in the world of Computer Science?


...the drive is 'whirring' etc, but not ejecting the cd.  I restarted and held down the mouse on the start-up chime -- that worked once; but I then put the cd back in and that method no longer works.  How do I get the cd out?  Thanks,

I tried everything on this page:  except Open Firmware (Intel macs doesn't support this).  Then I tried using the terminal but this didn't work either.  Every time I bootup my mac the drive tries to eject it but it can't. I ran the Apple Hardware Test (hold d on startup) and it sayed that all is fine. (it also tested the slot in drive).  And I put my mac upside down and booted it up (hoped that the cd could come out) but it didn't work. (same problem)  How can I get that out of my slot in drive? Mayby with a tweezer?  Any ideas?  PS: in finder there's no visible cd and in the diskutility there's nothing too


What do I say instead of Ladies and Gentlemen  if there are many men and only one woman present? Should I say:   Lady and Gentlemen  Gentlemen and Lady Madam and Gentlemen or something else?

It seems to be not quite logical to use the traditional address "ladies and gentlemen" when there are only a single lady and a single gentleman in the room, not counting for the person who is speaking.  What an address (in a similarly traditional style) would it be better to use in such case? Does it depend on the speaker's gender or any other circumstances?


For example, the sum of the sequence of perfect squares from 1^2 to 24^2 = 70^2.  What other sequences (of let's say length >= 5) of some starting n^2 and ending m^2 would sum to a perfect square?

We have the sum of squares of $n$ consecutive positive integers: $$S=(a+1)^2+(a+2)^2+ ... +(a+n)^2$$ Problem was to find the smallest $n$ such, that $S=b^2$ will be square of some positive integer. I found an example for $n=11$. Now, I'm trying to prove, that if $2<n<11$ there is't any solution. So I need some help with this: If $n,a,b \in \mathbb{N}$ and $n<11$ prove that equation  $$ n\cdot a^2 + n(n+1)\cdot a + \frac{1}{6}n(n+1)(2n+1)=b^2 $$  can't be solved. Or if I'm wrong, find counterexample.  The only idea I have is: to consider the remains $\operatorname{Mod}[b^2,n]$ and $\operatorname{Mod}[\frac{1}{6}n(n+1)(2n+1),n]$. For each $2<n<11$, but it is very long.


I have a MacBook Pro running El Capitan that I need to upgrade to Sierra 10.12 (not High Sierra) for development reasons.  I have previously upgraded my personal computer as follows: El Capitan -> Sierra -> High Sierra.  Knowing that, I should be able to see the previous version in the App Store as outlined in .  However, I don't see Sierra in my Purchased tab in the App Store:    Was Sierra 10.12 completely removed from the store (including previous purchases)?

Sometimes it's hard to search for older versions of macOS & OS X  on the App Store.  This is an attempt to provide the canonical QA for this issue, as per the Meta QA -  I expect it to be modified over time to hopefully become a complete information resource.  How can I get any older version of a Mac OS to be able to run as a VM, or to reinstall on my Mac?


I'm trying to identify a short story which I recall reading many years ago.  A series (i think) progressing into the future, similar to Harry Harrisons "One step from earth" but details the progress of a computer type device over millennia. The story I recall ends with the "computer" after many calculations works out how to reverse entropy and ends with a Biblical quote.

I am looking to identify a story that I read around 2001 (it is probably much older).  Someone showed me the story on pages printed from the internet, and it was attributed to Isaac Asimov (although I cannot state that is the true author).    The story is told in glimpses at different points of time in the future.  In each glimpse, humans are asking a more and more "intelligent" computer how to prevent the universe from collapsing into a singularity in the future, and the computer states it needs more computational power and resources to solve this problem.  At some point, man becomes one with the computer, and the computer exists in hyperspace (or subspace?).    In the final glimpse, it is the end of time and the universe is collapsing into a singularity.  At the instant the universe reaches the singularity, the computer figures out how to prevent it and says "Let there be light" and the universe begins to expand again.  Is anyone familiar with this story?


I have a flight from India to US with transit at Doha (Qatar). Connection flights are on two different partner airlines.  I want to carry my laptop with me in cabin during the flight from India to Qatar. Since USA has banned laptop inside the cabin for flights from Qatar, is it possible for me to check in the laptop bag in Qatar? Will it be delivered at same time as the luggage which I already checked in India?

Some flights prohibit laptops in the cabin.  Under such circumstances, can one gate check the laptop?  The risk of loss should be lower compared to regular checked luggage, and perhaps the traveller is not (otherwise) checking luggage at all.


If I have a function $f(x)$ and I find the derivative I will get $f'(x)$. Furthermore, if I do the integration of the derivative $f'(x)$, as a result I will get again my original function $f(x)$.  What I do not understand is a relation between integration and derivative operations. For me, the derivative is an operation where we calculate the slope of a function, and integration is an area under a curve.  But, if we take an example where $f(x) = x^3$. The derivative is $f'(x) = 3x^2$. If we do the integration of the $3x^2$ we will get our $x^3$ back again. But, $3x^2$ is some function, and if we do the integration on it, we should get its area under the $3x^2$. Is it possible to visualize that relation between derivative and integral operation, because I do not see it from the graph below?

I am trying to understand the relationship between differentiation and integration.  Differentiation has been introduced to me by this diagram:    Which displays that the derivative of a point $x$ on a continuous function $f(x)$ is the gradient of a line which is a tangent to that particular point, as shown in the diagram.  This can be written as  $$\lim_{h \to 0} \left(\frac{f\left(x+h\right)-f\left(x\right)}{h}\right)=f'\left(x\right)$$  and this gives the gradient of the point $(x, f(x))$.  Next examine this diagram:     The area under the continuous function from $f(x)$ from $a$ to $x$ is $A(x)$, shaded pink.  The area of $A(a)$ is $0$ and the area from $a$ to $b$ is $A(b)$.  Following this convention the area of $x$ to $x+h$ is  $$A\left(x+h\right)-A\left(x\right)$$  This section has with $h$ and the area is close to that of a rectangle so it can be said that   $$A\left(x+h\right)-A\left(x\right)\approx hf(x)$$  If you divide this through by $h$ you get an equation which shows that the derivative of $f(x)$ is $A'(x)$.    $$\lim_{h \to 0} \left(\frac{A\left(x+h\right)-A\left(x\right)}{h}\right)=f\left(x\right)$$  and hence   $$A'(x)=f(x)$$  This is where I have a problem, earlier it was stated that the derivative is the gradient of a line which is a tangent to a point on a continuous function.  Here however, we have an area, which encloses many points, which are not a line which is a tangent to a continuous function.  So I do not see how you can find the derivative of an area because it is not a point that you can find the gradient of a line which is a tangent to it.?  (Images taken from course texts provided by the Open University, Chapters C1 & C2 of the course MST121).


How do I unistall steam?  sudo apt-get remove steam returns Package 'steam:i386' is not installed, so not removed This response seems odd because this is a 64 bit system and I steam runs fine when I open it in a terminal.  Steam shows up in the software center when I search for it but clicking more info it says Not Found.  What is going on?

I'm seeing people say things like sudo apt-get remove steam and sudo dpkg -r steam but neither are working.   I ran dpkg-query -l *steam* and I get the following:  Desired=Unknown/Install/Remove/Purge/Hold | Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad) ||/ Name           Version      Architecture Description +++-==============-============-============-================================= un  steam          <none>       <none>       (no description available) rc  steam-launcher 1.0.0.47     all          Launcher for the Steam software d un  steam64        <none>       <none>       (no description available)   Not sure if this helps.  The steam FAQ doesn't seem to help either. I'm pretty sure I didn't do any apt-get install for Steam. I downloaded the steam_latest.deb from the website. Any ideas?   Update: I do have what I believe to be the folder in ~/.steam. What I'm wondering now is, if I remove this folder, what else do I need to remove?


I want to make the number and percentage in the last column well aligned to the right in every row. Separating them into two columns is the solution that worked for me because the number and percentage length is not fixed.   I have a very large other table (this is only a small sample) so please try to solve my problem with the way I use (multi columns to separate the number and percentage) without coming with completely new solutions as this way is used in many large tables.   The problem: in my method to achieve the right alignment I want, the space between the number and its percentage is large.   I want to reduce this space (see the red rectangle in the figure below).     The script in ACM conference template (2 columns template):  \documentclass[sigconf]{acmart} \usepackage{amsmath,amssymb,amsfonts} \usepackage{graphicx} \usepackage{xcolor} \usepackage{booktabs} \usepackage{array, makecell}  \usepackage[font={small}]{caption}  \usepackage{multicol}  \usepackage{multirow}  \usepackage{adjustbox}  \usepackage{paralist} \usepackage{mathptmx}  \usepackage[compact]{titlesec} \usepackage{sistyle}  \SIthousandsep{,}  \pagestyle{plain}  \begin{document}  \title{Title}  \begin{abstract} Abstract \end{abstract}  \maketitle \section{Sample}  \begin{table}[!tp]     \centering     \caption{Results}     \label{tab:results}      \begin{adjustbox}{max width=\columnwidth}         \begin{tabular}{llllrr}             \toprule             \thead{Col 1}& \thead{Col 2} & \thead{Col3} &\thead{Col 4} & \multicolumn{2}{r}{\thead{Col 5}} \\             \midrule             \multirow{4}{*}{\texttt{program 1}}&             \multirow{2}{*}{\texttt{dataset 1}} & \multirow{2}{*}{\num{\#\#\#\#\#\#}}              & type 1 & \num{\#\#\#\#\#}&(\#\#.\#\%)\\             \cline{4-6}             & & & type 2  & \num{\#\#\#\#} & (\#\#.\#\#\%)\\              \cline{2-6}              & \multirow{2}{*}{\texttt{dataset 2}} & \multirow{2}{*}{\num{\#\#\#\#}}                 & type 1 & \num{\#\#\#\#}&(\#.\#\%)\\             \cline{4-6}             & & & type 2  & \num{\#\#\#}& (\#\#\.\#\%) \\              \midrule             \multirow{4}{*}{\texttt{program 2}}&             \multirow{2}{*}{\texttt{dataset 1}} & \multirow{2}{*}{\num{\#\#\#}}              & type 1 & \num{\#\#\#}& (\#.\#\%)\\             \cline{4-6}             & & & type 2  & \num{\#\#\#}& (\#.\#\%)\\              \cline{2-6}              & \multirow{2}{*}{\texttt{dataset 2}} & \multirow{2}{*}{\num{\#\#\#}}                   &type 1 & \num{\#\#} & (\#.\#\%)\\             \cline{4-6}             & & & type 2  & \num{\#\#\#\#} & (\#\#\.\#\%) \\             \bottomrule         \end{tabular}     \end{adjustbox} \end{table}  \end{document}   EDIT:   Please note, I just want to reduce the spaces between columns in the last column (which is a multicolumn) (Col 5 in the provided figure).

I have 5 columns in my table. So I want to reduce distance between two columns to make it look good. In the following figure, I want to reduce distance between column 1 and 2.   I tried \setlength{\tabcolsep}{5pt} but it didn't look good. I want top row to take only two rows, not three. how do I do that?    \usepackage{tabularx,booktabs}  \usepackage{array} \newcolumntype{Z}{>{\centering\let\newline\\\arraybackslash\hspace{0pt}}X} \newcolumntype{C}{>{\centering\let\newline\\\arraybackslash\hspace{0pt}}p}  \begin{table}[t] \caption{Case studies} \centering  \begin{tabularx}{\textwidth}{C{3cm}*5{Z}}     \toprule  Nature of unreliability &  Sender SST &  Receiver SST &  Implementation SST &  Retransmission Bound \\      \midrule  Noisy (Single fixed error message) & DSST & DSST & DSST & Unbounded \\ \bottomrule \end{tabularx} \label{case-studies} \end{table}


I recently built a PC and installed Windows 10 on a 512GB SSD, I recently shrunk that partition to about 256 GB so I had room to install Ubuntu 17.10.   I have two 2TB hard drives, one of which is being used by Windows and the other is just free space. What should be my partition schemes for Ubuntu?  Should I:   Shrink the Free Space on the SSD just to put /boot and put / and swap space on the HDD Keep the Free Space on the SSD the Same and put / on the SSD, and have /home and swap on the HDD Some other combination   Thanks

I have installed Ubuntu 14.04 on 1TB HDD and have installed lots of packages and softwares. Now i've bought an 128GB SSD, I have few questions on how to partition SSD and HDD and how to move my current installation to SSD.  I'm thinking to have / and /home on SSD, and store other files on HDD, so how can i partition SSD+HDD to have:   / and /home on SSD have /home/music, /home/videos, /home/downloads, /home/pictures on HDD I have no idea about swap partition (should it be on SSD or HDD, actually its empty most of the time now), my laptop has 16 GBs of RAM   I'm planning to have fresh install of 14.04 on SSD (and i think i have to), so what is the best way to move currently installed packages to new installation ? i'm planning to use Aptik for that, is there a better solution ?  Is preload any good and gives performance boost when using SSD (i have 16 GBs of RAM)


Post for Suggestion:  scenery: I want to install ubuntu on android phone. not running ubuntu beside android. Remove android from boot and use grub to boot the phone.  Question: Is it possible?  If possible then how?

With the announcement of the Ubuntu Phone OS I'd like to know what phone (and tablet) models are supported at this time.  Note from foss & Oli: We are making this the master question for all future "Will this work on <insert random tablet/phone/device here>?!" questions


So I just read this and it didn't make any sense     It is not necessary for the rocket exhaust to push against anything   EXCEPT THE SHIP ITSELF. You see, when the combustion of fuel takes   place inside the rocket (think of a long vertical cylinder with the   'bottom' open) the exhaust gasses produced expand quickly in all   directions. The molecules slam into anything in their path exerting a   small force each. Thus some molecules push against the 'right' side   and some push against the 'left' side, and all these sideways forces   cancel each other out. Some molecules slam against the 'top' of the   cylinder, but since there is no bottom of the cylinder, there is no   force to cancel this out! Therefore the net force will be in the 'up'   direction.   By the very definition; there would be no movement still. Also engines require oxygen to burn which doesn't exist in a non existent environment. up, left, right, are not directions.

I know Newton's third law of motion might be the answer for this but still I am wondering how the rockets could thrust in the empty space and move in the opposite direction. I guess an astronaut wouldn't be able to push in the empty space with his hands or legs to move himself, but with a rocket engine it's possible. How? What might be the explanation for this in General Relativity?


The word 'nigger' comes from Latin 'nigrum' (black). It's quite a neutral description of the external characteristic of a person. There's no reason to be offended by it, just like (normally) nobody is offended by calling them 'white'.  However, nowadays it's considered an offensive word. When and how has the character of that word changed? When it has became common to use it to offense people instead of describing them?

My research has resulted in theoretical reasons for the usage of the term "nigger", and I have failed to uncover any evidence as to how this nasty little epithet evolved into the usage and connotation it had and has to this day.  When the African slave-trade was in full-swing , my belief is that a good percentage of black slaves  were captured and sold in Nigeria.  If the ship's captain could read, he would probably not be able to pronounce "Nigeria" or "Nigerian" properly nor would he care.  Since a four syllable word is difficult to pronounce anyway for the education level of seamen in the slave-trade of that era, I believe the term was shortened from nigerian to nigger which was easier for them to say.


I am working with Ubuntu 14.04 LTS on EC2. I want to change the default python interpreter from python 2.7 to 3.4.0 which is installed by default.  When I do:  /home/ubuntu$ which python /usr/bin/python   looking in /usr/bin/ I see:    So obviously it's there. How do I set this as default?

The python program command executes Python 2. Python 3 can be executed using the python3 command.  How can Python 3 be executed using the python command?


In this code, I've been trying to figure out my mistake, when I run it the program crashes. It's asking the user to enter a pet gender, if the user enters (F, f, Female or female) it sets the variable as "Female". same for Male.  I feel it's a silly mistake, but I really couldn't find it!   public void setPetGender(String PetGender) {      if (PetGender.toUpperCase().startsWith("F")) //retrun Female if it statrts with letter F, (F,f,Female,female) entered by user.     {         PetGender = "Female";         this.PetGender = PetGender;     }      else  if (PetGender.toUpperCase().startsWith("M")) {         PetGender = "Male";         this.PetGender = PetGender;      } else {         throw new IllegalArgumentException("The gender your entered is invalid, please enter Female or Male only.");     }  }

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


First off, this is a very tiny bug that doesn't really affect anything here except my perfectionism.  When a suspended user tries to accept an answer on their question, the following message comes up:     Suspended user cannot vote   I believe this should read     Suspended users cannot accept answers

While trying to accept an answer during suspension gives a tool tip     suspended users can't vote   shouldn't that be     suspended users can't accept answers


Question: Is there a Lebesgue measurable subset $A \subset R$ such that for every interval $(a,b)$ we have $$0 < \lambda(A\cap(a,b))< (b-a)$$  It looks like the answer is no, I'm trying to use the Lebesgue differentiation theorem on A in order to do so.  Also, If we assume there's a set $A$, $\forall (a,b) \subset (0,1)$, $0 < \lambda(A\cap(a,b))< (b-a)$, Does there exist an open interval $I_n \subset (0,1)$ that will hold as a contradiction?

The solution of problem 6 (page 3)  uses a measurable set $E\subset\mathbb{R}$ such that $0<\mu(E\cap I)<\mu(E)$ for all interval $I\subset\mathbb{R}$. Could someone give me an example of a set that satisfies this condition?  ($\mu$ is the Lebesgue measure)  Thanks.


I am confused about the fundamental definition of a sufficient statistic. I found two different definitions and I wounder if they are equal. with  data $X$ sufficient statistics $t$ parameter $\theta$  Definition 1, e.g. from: "A statistic $t = T(X)$ is sufficient for underlying parameter $\theta$ precisely if the conditional probability distribution of the data $X$, given the statistic $t = T(X)$, does not depend on the parameter $\theta$.", i.e. as formula: $$ p(X \mid t) = p(X \mid t, \theta) $$ Definition 2, e.g. from a : $$ p(\theta \mid t) = p(\theta \mid X) $$  The second definition should be equivalent to $p(\theta \mid t, X) = p(\theta \mid t)$: from $t=T(X)$ we can compute $t$ from $X$, so $p(\theta\mid X) = p(\theta \mid X, t)$. Is this correct? If yes then in the two definitions the $X$ and $\theta$ are exchanged.  So, my question is: Are the two definitions equivalent (in general or under some assumptions)?  Do I overlook something? P.S.: The second definition makes more sense if I look at the estimation of $\theta$ (estimator $\hat \theta$) from the data: $X \rightarrow \hat \theta$ and with the sufficient statistics $X \rightarrow t \rightarrow \hat \theta$. The arrows are not causal, e.g., the arrows do not reflect the data generating process which is probably $\theta \rightarrow X$, but not intermediated by a sufficient statistic(?). The first definition also makes sense: $t$ captures all the information about $\theta$ for $X$.

The title pretty much says it all. I wonder whether there is any difference in the way Bayesians understand sufficiency vs. the way orthodox statistics understands sufficiency, or are they equivalent?  If there is a difference, what is it?


I have the following regression equation: Fertility = - 0.2197 - 0.14986 educ - 0.1646259 rural + 0.0417699 edu_rural Where rural is a dummy variable for Rural area=1 and Urban area=0 ad educ is years of education. How do I interpret the interaction term edu_rural? Edu and Rural are both negative, so its confusing me a little.

I am confused about the interpretation of my interaction term , I have been through similar questions but I am still not sure about the interpretation that I should give to my output .  So this is my model , Y  stands for earnings management , X1 = CSR , X2=CEO duality , as you can see both of the coefficients are negative CSR reduces earnings management manipulation and Duality in my sample reduces em as well  which is in line with the literature and confirm my hypothesis , but to my surprise my interaction term is positive and significant does that mean that CSR combined with duality increase EM ? Or that CEO duality moderates the effect of CSR on EM knowing that in papers that I've read, they only use" moderate "when the interaction term and the components are all negative . Could you please help me ? I am supposed to comment my results but I don"t understand this . Thank you


I want to set my folders permissions to 555 and my files permissions to 554, so I tried the following chmod:  sudo chmod -R -v ug=rx,o=r,a+X mydir/   I thought this would set the user and group permissions to r-x and others permission to r--, but since there is an a+X only folders would receive an r-x for the others permission, but files would remain r--.  But this isn't working and it is setting all the files and folders to 555, even if I set all folders and files to 444 before to assure there isn't any x permission anywhere.  Why this chmod command doesn't work as I expected it to?

I've never really got how chmod worked up until today. I followed a tutorial that explained a big deal to me.   For example, I've read that you've got three different permission groups:   owner (u) group (g) everyone (o)   Based on these three groups, I now know that:   If the file is owned by the user, the user permissions determine the access. If the group of the file is the same as the user's group, the group permission determine the access. If the user is not the file owner, and is not in the group, then the other permission is used.   I've also learned that you've got the following permissions:   read (r) write (w) execute (x)   I created a directory to test my newly acquired knowledge:  mkdir test   Then I did some tests:  chmod u+rwx test/ # drwx------ chmod g+rx test/ # drwxr-x--- chmod u-x test/ # drw-r-x---   After fooling around for some time I think I finally got the hang of chmod and the way you set permission using this command.    But...  I still have a few questions:   What does the d at the start stand for? What's the name and use of the containing slot and what other values can it hold? How can I set and unset it? What is the value for this d? (As you only have 7=4+2+1 7=4+2+1 7=4+2+1) Why do people sometimes use 0777 instead of 777 to set their permissions?   But as I shouldn't be asking multiple questions, I'll try to ask it in one question.  In UNIX based system such as all Linux distributions, concerning the permissions, what does the first part (d) stand for and what's the use for this part of the permissions?


I just started using blender yesterday to model a character. I got through most of the head but now, every time I want to move vertices/edges or extrude, I cannot do it properly. If I try, it moves at a pre-set length that I can't seem to get away from. Please help!  You can see the file here ()

My cursor is moving by every selection by large increments!  Normally when I use Blender, I am able to select and move objects to any coordinate. Now, all of the sudden, when I select an object or mesh the selection moves by an inch or so in each direction.  How do I reset it to normal?


I have several files in the same folder that have one element in common in the names.  How do I rename the files so that the common element in the names is deleted?

I got a bunch of files with the filename messed up. All the file names have the same beginning which appear to be windows file directories. The problem is there are 700+ files and I really don't want go through and manually rename all of them. These are examples of the file names (Note: None of these have file directories):  G:some\really\long\file\path\then\the\name1.jpg G:some\really\long\file\path\then\the\name2.png G:some\really\long\file\path\then\the\filename.txt G:some\really\long\file\path\then\the\file_name.mov ...   The important take away is that each file has G:some\really\long\file\path\then\the\ before the file name that I would like.   So I would want the above files to look like:  name1.jpg name2.png filename.txt file_name.mov   I've tried the rename command and was not successful. I am still new with Linux and really am not sure on how to go about it or really what to google. Any help would be appreciated.


A rather simple question: if an Ancient Dragon uses it's Shapechange ability to transform into a medium-sized humanoid, and then has that Shapechange disabled/dispelled inside a narrow tunnel / small underground room, will they get crushed to death by their own size? I have plans on True Poly-ing my spellcaster PC into a Dragon, and i'm worried that a random dispel would instakill me when i go dungeon-delving in the Abyss or somewhere.

So in a 5e campaign I'm running, the party Druid has recently been doing some scouting of the local monster caves in spider form to avoid notice. I've also described how the goblins and kobolds who live in these caves use a variety of tunnels too small for Medium sized creatures in order to get around. Since the party doesn't have any halflings or gnomes, I didn't really think the party would ever get into those tunnels. But obviously if a goblin can fit, so can a spider, so there is the possibility that the Druid might try to scout them out.  But what if something goes wrong? What if the Spiderdruid were to get lost and run out of time in Wild Shape, or encounter a hungry lizard and drop to 0 Spiderhealth?  Is there anything in the rules to suggest what should happen when somebody tries to revert to their normal size in a space where they normally wouldn't fit?  With a space sized for a Small creature such as in my game, I might just rule that he's stuck unless he makes difficult Dexterity checks or waits to get his Wild Shape back. However, what if it was an even smaller space, such as a burrow or a pipe or a deep crack in the rock? Someplace where his human body literally won't fit?  If there aren't any rules for this, I'm open to suggestions on how it can best be handled.


what is actually better to use with LuaLaTex: Babel or Polyglossia?  I read everywhere that we should prefer Polyglossia over Babel when using  LuaLaTex because LuaLaTex did not completely support Babel. But these statements i read are some years old and many things have changed. So the support for Babel is maybe better?  Therefore i want to know what package i should prefer and why? thanks!

Which are the key questions one has to ask to decide between Polyglossia and Babel for a LuaLaTeX project in 2019?  There has been a similar, more general , but the packages have changed a lot in the meantime. Hence I open a new, more specific question.  Can we reduce it to a check list like  Use package A, if you need   utf-8 characters right to left support   Use package B, if you need   package foo, because A breaks foo


Is there a closed form for a finite sum $s_n=1+x+x^2+x^4+x^8+\ldots+x^{2^n}$? I apologize if this has been already discussed. Is there some literature on this I can take a look at?

The following appears as the second-to-last problem of Stewart's Complex Analysis:     Describe the Riemann surface of the function $y=\sqrt{z+z^2+z^4+\cdots +z^{2^n}+\cdots}$.   This problem intimidated me when I first saw it as an undergrad, as the series under the root isn't the expansion of any function I know (then or now). That renders the Riemann surface more subtle than usual, since any info about poles and zeroes must be found from this series alone. For instance, it has a zero at $z=0$ and therefore a branch point. But there should be other zeroes — indeed, infinitely many zeroes— since the number associated with any truncation of the series grows as $2^N$!. This suggests that the Riemann surface of this function must be exotic.  I'll give a sketch of an argument below, taking the pedestrian approach of hunting poles and zeroes of the function. However, I'd be glad to see an elegant and advanced perspective of the problem, particularly if it uses some ideas which I wouldn't have encountered as an undergraduate. The more food for thought, the better!  EDIT: As noted by O.L.'s answer below, the series above is the canonical example of a lacunary function with the unit circle as natural boundary. What that leaves open is the nature of the resulting Riemann surface, which would seem to hinge upon the quantity of the function's zeros within the unit circle. David Speyer has given an argument in his answer that this number is at least 10. Is there a more definitive result on the zeroes of this lacuuary function?


After reading  about undefined behavior and sequence points, I wrote a small program: #include <stdio.h>  int main(void) {   int i = 5;   i = (i, ++i, 1) + 1;   printf("%d\n", i);   return 0; }  The output is 2. Oh God, I didn't see the decrement coming! What is happening here? Also, while compiling the above code, I got a warning saying:  px.c:5:8: warning: left-hand operand of comma expression has no effect   [-Wunused-value]   i = (i, ++i, 1) + 1;                         ^   Why? But probably it will be automatically answered by the answer of my first question.


My friend has a wireless router in his car that supports streaming music. I would like to stream music to this router from my google play (or other internet source), but as soon as I connect to his router, I lose internet access (since his router doesn't have any kind of outside line). It seems that even though the router clearly doesn't have internet access, android is shutting down my 4G connection. Is there any way to change this behavior, or is it expected to change in Android L? It is a little disappointing that this doesn't work as it seems the iPhone has supported this for quite some time.  For reference I am on android KitKat 4.4.3

When I turn WiFi on, my 3G connection shuts down, which is fine in most cases. However, I need to connect to a LAN at work that is not connected to the internet and I'd prefer not to lose my data connection when I connect to the work intranet. How can I keep both connections active? Ideally, I could limit this desired behavior to this one SSID because I want it to continue to operate with the default behavior for all other WiFi connections.  If that can't be done, prefer a solution that is easy to toggle on and off. I'm using a Samsung Galaxy Nexus (Verizon Wireless) on CyanogenMod 9.


I have been working for some time on a document that uses the calibri font for the main text. However, recently I updated my packages through MiKTeX and now, using LuaLaTeX as my main compiler, the document no longer renders. I am sure it is some setting within Windows or TexStudio but I have been unable to figure it out. If I type this simple document:  \documentclass[11pt,a4paper]{report} \usepackage{fontspec} \setmainfont{Calibri}  \begin{document} here is some text \end{document}   Then I get the error exited with errors file and a blank pdf. The error log being    I have tried multiple things, from installing packages that supposedly resolve these errors to trying XeLaTeX as a different compiler. But so far none of the solutions have worked. And all that I get, when using it on my main document, is images and a huge log file. The only way to resolve, so far, the error is to remove the fontspec package.

I just updated my MiKTeX packages (and also did FNDB refreshes, updmap and everything and also already tried a complete fresh install), but now I suddenly get loads of errors telling me that my fonts are not found, for example:  fontspec error: "font-not-found" The font "Philosopher-Regular" cannot be found.   At first I thought that some packages are missing because of the November Package Refactoring (). But for some of my fonts this can't be the reason, because I load some font files like this, which also triggers this error:  \newfontfamily\PhilosopherRegular[Path=../]{Philosopher-Regular.ttf}   And these files are in my git repository (and it compiled just fine before the update on the exact same code).  What ways do I have to attack this error?


I am having a problem with Blender since I started using it: when I have a solid object (for example a cube) I cannot zoom in inside the surface; when I zoom in after the zoom reaches the surface it continues zooming in into the surface, but it never penetrates it. The only way to see inside the geometry is placing the camera inside and select the camera view. This problem happens equally in object and edit mode.   Please note that my problem is not that the zoom cannot get any further, but rather that I cannot penetrate to enter the inside of a closed solid (like a cube). This is something very common, particularly in architectural design, where you often start with a cube and the scene happens inside the cube.  Of course this problem is in no way a deal breaker for I can always place the camera in the right position and view through it, but that is rather limiting for I cannot get any other angle of the interior of my geometry than the camera angle; and besides it would be handy to be able to zoom in into the geometry before I set any camera; even to navigate to the adequate view and then set camera to view. I know this is possible for I see all the time in tutorials as a thing so basic that no explanation is required.  Can anybody help?  Thanks!  Sept

I often find that I can zoom in to a point, but then cannot zoom any more, even when there is a lot of room to zoom to the meshes on the scene.   This is particularly annoying in the following scenario:  I often land up left clicking on the scene and the 3D cursor shifts there. I use Shift+C to shift the 3D cursor back to the origin. However, this also centers the view on the cursor and shifts the view to show all objects, and sometimes this zooms things way out – at this point, if I try to zoom in, I can zoom in to a point (using the pinch/zoom on trackpad), but then it stops zooming in.   How do I zoom in after that? Is there anything else I am doing wrong in this case?


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


So say there are two point masses, m1 and m2. There is no gravity affecting them besides the gravity between themselves. How long does it take them to collide with a given distance? The acceleration will change at the rate of x^2, so the objects will experience constant jounce, the second derivative of acceleration.  There are a couple problems i am having with solving this equation. The first is how to find the acceleration toward the other obejct of each individual mass. If i had the initial acceleration, I could make that a function of acceleration vs time, and making a differential equation solve for distance vs time. With that, all I would have to do is find out how far the objects have to travel to reach each other, which leads into my second problem.  How can i find where the objects will collide? It makes sense that they will meet at their inital barycenter, but I am not completely sure.

My friend and I have been wracking our heads with this one for the past 3 hours... We have 2 point masses, $m$ and $M$ in a perfect world separated by radius r.  Starting from rest, they both begin to accelerate towards each other. So we have the gravitational force between them as:  $$F_g ~=~ G\frac{Mm}{r^2}$$  How do we find out at what time they will collide?  What we're having trouble with is this function being a function of $r$, but I have suspected it as actually a function of $t$ due to the units of $G$ being $N(m/kg)^2$.  I've tried taking a number of integrals, which haven't really yielded anything useful.  Any guidance?  No, this is not an actual homework problem, we're just 2 math/physics/computer people who are very bored at work :)


I am having a terrible time finding information on this and I am hoping someone here can help or point me in the right direction.  I am working on a project of setting up an IIS webfarm that is multi-site - that is, example.com will be hosted from location A and location B in high availability or load balancing.    I currently have an IIS farm in test that is working fine, but it is in the same geographical location and thus a single public IP address to access it from the outside.  I am stumped as to how I can have two public IP addresses, one for each geographical site, and make the environment highly available.    If I haven't explained my environment thoroughly, please let me know.  This is my first foray into this sort of thing and just trying to do my best.  Thank you,

We have a SaaS application that we need to be highly available. We already have an expensive, well-maintained Hyper-V failover cluster, but today the datacenter where we host that cluster had a five-hour power outage that knocked us completely offline. So now we're wondering if a better approach might be to use servers at two separate datacenters. Assuming we get all the back-end file replication and data replication working between these two sites, we're wondering how to handle the front-end routing -- no wonder how we approach the problem, we always wind up with the load balancer being a single point of failure.  So the question is ... how can we set up load-balancing between two hosting sites such that the load balancer isn't the single point of failure? Is there a way to use two separate load balancers, one at each site? Should we be considering round-robin DNS?


I'm about to give up on installing .NET 3.5. I've tried almost everything now, but nothing seems to work.   Installing .NET 3.5 from my Windows USB installation via CMD doesn't work, it simply freezes after Image Version: 10.0.10240.16384 (Command used: dism.exe /online /enable-feature /featurename:NetFX3 /All /Source:D:\sources\sxs /LimitAccess). I have also tried copying the sources folder to my C drive and run the command, without succes. It should be noted that Dism.exe /online /Cleanup-Image /StartComponentCleanup freezes at the exact same moment. Microsoft's installer doesn't work either. If I click the 'Install this feature' button it is stuck at the first phase (Where it's searching for the correct files if I remember correctly) It cannot be enabled via the control panel, because it doesn't show up there. (This might be a related issue) I cannot search for new updates, for some reason it just keeps searching without finding something or stopping. Nevermind, it found updates after ~2 hours.   I do not get any errors in all the ways that I've tried mentioned above.

When I try to install .net 3.5 I get the follwing message:     The following feature couldn't be installed:      .NET Framework 3.5   (includes .NET 2.0 and 3.0)      Error code: 0x800F081F   I tried with a standalone package and through Windows Features.  Update: Internet connection is fine.


I have a Macbook Pro and all my friends have 40+ games but most of them are for Windows. So is there anyway that I can download them but on my Mac and be able to play them?

I recently downloaded 'Blood Bowl' on Steam to my Mac, not realizing that it was not Mac-compatible. Is there any software or any way that will allow me to play it, as obviously I've already paid for it? Cheers.


So I'm playing Skyrim, and I have a family in Whiterun. (Wife, and 2 children) I have a lot of items there. And I just bought a house in Windhelm. I tried to see if they would move. But there's no option.

I'm playing Skyrim with Hearthfire and I'm wondering how do I move my family(Wife and Daughter) to my new Manor near Morthal?


My question is exactly similar to the one posted here .  The answer posted here is not complete and I'm looking for a solution. I'm using the below code to save a node.  function api_add_getabstract($node_values, $api_endpoint) {   //initialise node object   $ex_node = new stdClass();   $ex_node->type = 'getabstract';   $ex_node->language = 'en';   node_object_prepare($ex_node);   dpm($node_values,'node values');    //add field values   $ex_node->title = $node_values['bookinfo']['title'];   $ex_node->body['en'][0]['value'] = $node_values['recommendation'];   $ex_node->body['en'][0]['format'] = 'full_html';   $ex_node->field_authors['en'][0]['value'] = $node_values['bookinfo']['authors'];   $ex_node->field_sub_title['en'][0]['value'] = $node_values['bookinfo']['subtitle'];   $ex_node->field_publisher['en'][0]['value'] = $node_values['bookinfo']['publisher'];   $ex_node->field_ex_cover_image['en'][0]['value'] = $node_values['bookinfo']['bookcoverOriginal'];   $ex_node->field_ex_deep_link['en'][0]['value'] = $node_values['publicURL'];   $ex_node->field_api_info['en'][0]['value'] = $api_endpoint;   node_save($ex_node); }   I tried by changing the value 'en' to 'und' and LANGUAGE_NONE, but none seem to save the node completely. Using 'en' at least creates the node with only Title field, but for the other 2 values, node is not even getting created.

i'm trying to create a multilingual node using a php script.  I'm doing this:   $node = new stdClass();  $node->title = "Test ".mktime();  $node->type = "job";  $node->language = 'de'; // Or e.g. 'en' if locale is enabled  $node->uid = $user->uid;   $node->status = 1; //(1 or 0): published or not  $node->promote = 0; //(1 or 0): promoted to front page  $node->comment = 1; //2 = comments on, 1 = comments off  $node->path = array('alias' => 'das-ist-ein-test-'.mktime());  $node->body[$node->language][0]['value']   = "Body Body Body";  $node->body[$node->language] = text_summary("Body Body Body");  $node->body[$node->language]  = 'filtered_html';  node_save($node);   As long as i set $node->language to 'und' everything is working fine. But as soon as I set the language to 'de' or 'en' (both languages are activated in my Drupal installation) the body text doesn't get saved.  So my question is: can anybody provide me with a working example of how to store a multlingual node (de,en) into Drupal using program code.  Thank you


I had to go a long way round to get Steam, as I was getting Error 403 Forbidden.  I worked around that, but when Steam starts up, I get told it wants to add additional files.  When I click on the application, I get a message suggesting that I install these files.  When run I get the following dialogue in the console:  >Steam needs to install these additional packages:  >   libgl1-mesa-dri:i386, libgl1-mesa-glx:i386, libc6:i386 >[sudo] password for robert:  >.............................................................................>.............................................................................>.............................................................................>.............W: The repository 'cdrom://Ubuntu-MATE 16.04.1 LTS _Xenial >Xerus_ - Release powerpc (20160719) xenial Release' does not have a Release >file. >E: Failed to fetch cdrom://Ubuntu-MATE 16.04.1 LTS _Xenial Xerus_ - Release >powerpc (20160719)/dists/xenial/main/binary-powerpc/Packages  Please use >apt-cdrom to allow APT to recognise this CD-ROM. 'apt-get update' cannot be >used to add new CD-ROMs >E: Failed to fetch http://gb.ports.ubuntu.com/ubuntu-ports/dists/xenial>/main/binary-i386/Packages  404  Not Found [IP: 2001:67c:1360:8001::22 80] >E: Failed to fetch http://gb.ports.ubuntu.com/ubuntu-ports/dists/xenial->updates/main/binary-i386/Packages  404  Not Found [IP: >2001:67c:1360:8001::22 80]   XXXXXXX  E: Some index files failed to download. They have been ignored, or old ones used instead.  Reading package lists... Done Building dependency tree        Reading state information... Done Package libc6:i386 is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source However the following packages replace it:   libdb1-compat initscripts tzdata  Package libgl1-mesa-glx:i386 is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source  E: Unable to locate package libgl1-mesa-dri:i386 E: Package 'libgl1-mesa-glx:i386' has no installation candidate E: Package 'libc6:i386' has no installation candidate Press return to cont   Please can anyone advise?  I'm running a G5 PowerMac, running ubintu-MATE 16.04.   Any ideas how to make this work?

When updating I got this error message:  W:Failed to fetch cdrom://Ubuntu 11.10 _Oneiric Ocelot_ - Release amd64 (20111012)/dists/oneiric/main/binary-i386/Packages  Please use apt-cdrom to make this CD-ROM recognized by APT. apt-get update cannot be used to add new CD-ROMs W:Failed to fetch http://ppa.launchpad.net/synce/ubuntu/dists/your_ubuntu_version/main/source/Sources  404  Not Found   What to do?


Let matrix $M$ be \begin{align*} M= \begin{pmatrix} A_1 & 0 & 0 & \cdots & 0 \\ 0 & A_2 & 0 & \cdots & 0 \\ \vdots \\ 0 & 0  & 0 & \cdots & A_n \end{pmatrix} \end{align*} where $A_1, A_2, ..., A_n$ are rectangular matrices (could be of different types). What is the formula of calculating determinant of such matrix?


I'm cleaning up shapefiles (mainly for US areas) in QGIS 3.6 to import into other CAD environments such as Rhino. One problem encountered is that the units are in degrees, resulting in imports being several orders of magnitude wrong. How do I change the unit to meters?   I searched and understand it's something to with the CRS (switching to UTM instead of WGS), but as there seems to be many options/zones, I'm not really sure which is the correct one.

I am running QGIS 1.7.0 on windows, and I donwloaded a shapefile of .  This file appears to be in the WGS 84 coordinate system, and when I open it in QGIS the unit of measure is degrees.  I tried re-projecting the file into the NAD 83 coordinate system, and saving it as a new shapefile, but when I open the new file it still displays a ruler in degrees.  If I try to make a buffer, it interprets buffer distance as degrees.  Assuming I'm starting with a shapefile from TIGER, what's the best way to convert my unit of measure from degrees to meters?    For posterity, it seems like the following workflow make sense when dealing with US census TIGER shapefiles:           Open it in QGIS     Click the Settings menu and select project properties     Select a projected coordinate system, like NAD83 / UTM zone 19N     Click the box Enable 'on the fly' CRS transformation     Click ok     Click the 'zoom full' button (one of the magnifying glasses)


When watching videos on Youtube some of them display thumbnail previews when the mouse if hovered along them time line? The picture below shows the thumbnail of the video at 3:31.    Some Windows video players have them as seen in the answers for this question - , ie   Are there any Linux video players with this feature?

When you watch a video in YouTube, you can seek it with the thumbnail preview. Many Windows' and MacOS' video players have this feature, but what about Linux's? I've already read , but the information in it seems out-of-date.  is still alive but the project is neglected (see ), and actually the player doesn't work on the latest Ubuntu or Linux Mint.  Is there any video player which has the feature and works on the latest linux distributions? Or must I use Windows' one with VirtualBox? If only VLC would implement this feature, but it seems that won't happen as far as I read .  YouTube's seek preview:


I have a problem with some code, I need to save an Dynamic object in a binary file. I tried to do as static objects but doesn't work I tried this I have a problem with some code, I need to save an Dynamic object in a binary file. I tried to do as static objects but doesn't work I tried this   CGame* obj_juego;//objects is already created //Save ofstream ofile("Jetpack_Joyride.bin", ios::binary); if (ofile.is_open())     {         char* data = reinterpret_cast<char*>(obj_juego);         ofile.write(data, sizeof(CGame));         ofile.close();     } ///Load CGame* aux2 = nullptr;     ifstream ifile("Jetpack_Joyride.bin", ios::binary);     if (ifile.is_open())     {         ifile.read((char*)aux2, sizeof(CGame));         ifile.close();     }     class CGame { private:     CLista_doble_F<CLevel>* arreglo_niveles;     CLevel* obj_nivel;     CBarry* player;     Array_bg* background;     int cantidad_niveles;     int dificultad;     int dron_intervalo;     bool vidas;     int general_speed;     int cont_speed;     int checkpoint;     int checkpoint_level;     bool is_empty;  public:     CGame()     {         arreglo_niveles = new CLista_doble_F<CLevel>();         player = new CBarry(100,520);         cantidad_niveles = 0;         background->set_activado(true);         dificultad = 1;     }//some other code

Is it possible to serialize and deserialize a class in C++?  I've been using Java for 3 years now, and serialization / deserialization is fairly trivial in that language. Does C++ have similar features? Are there native libraries that handle serialization?  An example would be helpful.


Is it safe to eat the skin of a baked or boiled potato, or are there any health or sanitary reasons not to eat it?  Contrarily, are there any reasons to eat it, e.g. does the skin contain vitamins or minerals which you would cut off by peeling?  EDIT: There is a related question  that asks specifically for red potatoes. This question covers yellow potatoes as well.

I recently made some potato wedges in the oven. I shared this recipe with my relative, who admonished me for not properly peeling the red potatoes before baking them.  She claims that there are disease and viruses that lie on the skin, so peeling it will get rid of it.  I bake it, so I assume that even the high heat in the oven would kill bacteria and germs. And besides that, I make sure to wash potatoes thoroughly before cooking them.  Am I in the wrong here? Should I have properly peeled the potato wedges before baking them? Personally I feel they add more flavor, and from all the pictures on the recipes online, it seems they also do not peel it.


I am doing something very basic: trying to simulate a rigid body (a sphere) falling onto a large cloth. Right now in my simulation, the object falls, the cloth deforms, and then the object just comes to rest on the cloth. It would look more realistic if the sphere were to bounce a little bit (and maybe roll around) before coming completely to rest. I have tried changing the physics properties of the cloth and the rigid body, with no success. I know rigid bodies can bounce off of each other: is there any way to get them to bounce off of a cloth before coming to a stop?

For example, rigid bodies and fluid. I know it's kind of possible by setting the rigid bodies as fluid obstacles, but it's not "true" interaction in that the fluid does not affect the rigid bodies...  By "true" interaction I mean where two (or more) physics systems affect each other simultaneously. For example, with rigid body and cloth, the rigid body affects the cloth but the cloth doesn't affect the rigid body (at least the way I'm doing it), so the rigid body just eventually stretches the cloth to an extreme and falls through...  Are there any ways to achieve this? (for any interaction, not just rigid bodies and fluid)  Or, if not, does anyone know whether there are any plans to implement this sort of feature?  Thanks


We can assume that A is $n{\times}n$ matrix. Prove that  $$\det(A^{-1})=\frac{1}{\det(A)}$$  We know that $AA^{-1}=I$.   If someone could provide some insight on how to prove this that would be much appreciated  Thanks,  Tuki

I was hoping that someone could point me in the right direction on how I could start answering the following question:     Based on the fact that $\det(AB)=\det(A)\det(B)$ for all square $n \times n$ matrices $A,B$, explain in every detail why:   $$\det(A^{-1}) = 1/\det(A).$$


I am running Windows 7 and I want the get Windows 10 app thing.  I have tried the Reservewin10.cmd, with an error message that says access denied even if I elevated to admin.  I have also tried the Win10fix_full file, and I used all 3 methods and waited and it still doesn't work. My computer cant check for updates so I downloaded B3035583 and KB2952664 standalone and installed them.  Then I reran both scripts. The reservewin10 shows the following     and the win10fix_full file still thinks it fixed it but it actually didn't do anything.  I have the 2 prerequisite updates installed, but as @David mentioned below, it may rely on some OTHER updates for it to work.  Error code given by windows update when I try to check for updates is 80072F76

I want to get Windows 10, but I do not see this icon in the notification area (tray):    How do I get the icon to get Windows 10?


I am learning about magnetic induction and transformers.    I have coil1 which uses AC to create an oscillating magnetic field. I have coil2 which has a voltage applied to it based on the magnetic field from coil1.   I just heard that if you have more coils in coil2 (the coil dependent on the oscillating magnetic field) you get a bigger voltage and this seems counter intuitive because:   voltage is based on pressure and that pressure is coming from coil1 so how can it be bigger? wouldn't more electrons present in coil2 cause more resistance and thus make the voltage smaller?   How is it that with more coils you get a bigger voltage?

A current I flows through a solenoid (with n turns). Self inductance is $L$. If the magnetic flux is $\phi$, I am taught that $-n\phi=LI$  I dont understand the part with $n$, why do we have multiply by $n$? $\phi$ itself represents the whole magnetic flux there, if $\phi$ implied the flux only occurred by one coil, then it would be correct.   Moreover, flux change by a coil ($n$ turns) in $dt$ time is $d\phi$, so the induced electromagnetic force is   $$dE=n \cdot \frac{d\phi}{dt}$$   Why do we multiply by $n$ here? If $\phi$ means the whole flux, then why multiply?


First time using Bibtex. I was reading the tutorial of sharelatex on bibtex, here:   I copied the bib file they provide into a file:  @article{einstein,   author =       "Albert Einstein",   title =        "{Zur Elektrodynamik bewegter K{\"o}rper}. ({German})                  [{On} the electrodynamics of moving bodies]",   journal =      "Annalen der Physik",   volume =       "322",   number =       "10",   pages =        "891--921",   year =         "1905",   DOI =          "http://dx.doi.org/10.1002/andp.19053221004" }  @book{latexcompanion,     author    = "Michel Goossens and Frank Mittelbach and Alexander Samarin",     title     = "The \LaTeX\ Companion",     year      = "1993",     publisher = "Addison-Wesley",     address   = "Reading, Massachusetts" }  @misc{knuthwebsite,     author    = "Donald Knuth",     title     = "Knuth: Computers and Typesetting",     url       = "http://www-cs-faculty.stanford.edu/\~{}uno/abcde.html" }   Then I copied the tex file:  \documentclass[a4paper,10pt]{article} \usepackage[english]{babel} \usepackage[utf8]{inputenc}  %Includes "References" in the table of contents \usepackage[nottoc]{tocbibind}  %Title, date an author of the document \title{Bibliography management: BibTeX} \author{Share\LaTeX}  %Begining of the document \begin{document}  \maketitle  \tableofcontents  \medskip  \section{First Section} This document is an example of BibTeX using in bibliography management. Three items are cited: \textit{The \LaTeX\ Companion} book \cite{latexcompanion}, the Einstein journal paper \cite{einstein}, and the Donald Knuth's website \cite{knuthwebsite}. The \LaTeX\ related items are \cite{latexcompanion,knuthwebsite}.   \medskip  %Sets the bibliography style to UNSRT and imports the  %bibliography file "samples.bib". \bibliographystyle{unsrt} \bibliography{sample}  \end{document}   Saved both files in the same folder, opened the .tex file and clicked on compile. Citations don't appear, I get a [?] instead. I get the warning "Citation 'latexcompanion' on page 1 undefined."  This works on their browser viewer but not on texmaker. What am I doing wrong?

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}


Well, I have to do a mesh in millimeters, and amplify the view to begin, and set a vertex in the center (Y=0 X=0), and as you can see, set the top view, and create a square of 10cm but the mesh does not fit the grid. See the first image please.     But when I fit the selected vertex to the grid, result in this:    On the job will be a mess if I leave that 10.1367cm, because y need exact precision, and I set Scene >>> Units >>> Meters and Unit Scale to 0.1 and 0.01 and 1... nothing!  The scale to 1, 0.1, 0.01... nothing!!!  And what I need is a grid with exact measurement in millimeters.

I always struggle when trying to create a floor plan or furniture. How do I model using exact measurements.


I've stumbled upon a equation in the form $$A\sin{\theta} + B\cos{\theta} = C$$ What would be the steps necessary to solving it? Thank you.

Could someone help me with the steps for solving the below equation $$a \sin\theta + b \cos\theta = c$$ I know that the solution is $$\theta = \tan^{-1} \frac{c}{^+_-\sqrt{a^2 + b^2 - c^2}} - \tan^{-1} \frac{a}{b} $$ I just can't figure out the right steps to arrive at this solution.


Electricity flows from a point of higher level of potential toward a point of lower potential. Liquids flow from a point of higher level toward a point of lower level. I want to know, in the same manner, how do we explain the flow of photons in a beam of light from its source of origin, say, from a candle or from the sun?

I know there have been similar questions but I'm still unclear what the overall consensus is. (1) I assumed and have read that photons travel in straight lines unless deflected by gravity but there are conflicting theories. (2) I have heard that single photons takes every possible path but that makes no sense. Why would a single photon traveling from here to the moon go to every other place in the universe along the way.  (3) I can understand a single photon traveling as a particle or packet of energy but I have a hard time understanding a single photon traveling as a wave. I have never understood any attempts to answer this.  (4) Does a single photon have a frequency and what causes the frequency? If not then how does it have energy? I have many questions about single photons and their frequency.


I asked this question earlier , but was not clear which resulted in the question being closed, and was later told in the comments that I should ask the question again.  A requirement of my PHP/MySQL application is to allow all users to create their own multiple "views" of the data.  These views are not traditional SQL views, but performed by the application.  For instance, the user could create a view and provide the following criteria:   Name of the view. Desired records per page. Which columns to display by using a dropdown menu. Any filters for the results.  A first dropdown menu is used to select the column, a second dropdown menu is used to select the operator (equals, not equal, greater than, etc), and then either a third dropdown menu is used to select the value to be matched or the user directly enters the value to be matched. Whether the records should be grouped on a given column.   Based on the user's selection, various tables might need to be joined to the query to support the select, where, and group by clauses, and the application is used to eliminate duplicate table joins should they exist.  After the user has finished configuring their views, there is a dropdown menu which allows them to select their desired view, and the appropriate results are displayed.  I have implemented this functionality by storing the user's selections in several tables, and also storing the resultant query (actually, I store individual sections of the query in various columns so I may count the total results in an initial query and return the correct number of results in a second query) in a SQL table.  Note that I am storing the user's selections only so that I can allow them to edit their view requirements, and not to create the resultant query on the fly (more on this later).  I recognize that I have to be very careful as doing this can be prone to SQL injunction.  For instance, I can't just escape the user's input using PDO and store it in the database, and then later retrieve the data and use it in a query since when it is retrieved, it is no longer escaped.  To combat this risk, I limit user input to integers wherever possible, and typecast them where possible.  Where user inputs are percents and dollars, I multiply by 100, typecast the resultant as an integer, and then divide by 100 before storing it.  A couple of the filters require text as the value in the WHERE clause, and as stated earlier, escaping the data is not enought, and instead I am using $user_input= preg_replace('/[^a-z0-9,]/i', '', $_POST['user_input']); to make safe.  Is this an accepted method to implement this functionality?  Is there an easier way to ensure the user input is safe?  My earlier post  indicated that this type of practice should never be attempted, however, I don't know how else to do it.  Are there any other steps I should take to prevent injection?  Or maybe I should not create a query and store it in a table when the user saves his view configuration, but create the query on the fly using the user's saved values each time the user selects a given view.  This would have a negative performance impact and add complicity but I suppose I can do it.  Would you recommend using this strategy?  Thank you

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


I am supposed to write a program that takes in the amount of each type of donut the user wants (regular or fancy), calculate the price, and then calculate how much money the user should receive back depending on what they paid with.  I have completed the first part of the problem and can successfully calculate the price of the donuts the user wants. I am now trying tell the user how much change they will get, but when I wrote the first if statement to return that the exact payment has been made if the customer pays exactly what is owed it does not print the result to the screen. I want to figure this part out before moving on to the next part.  #include <iostream> using namespace std;  int main() {     const double TAX = .075;     const double REGPRICE = 0.75;     const double REGDOZENPRICE = 7.99;     const double FANCYPRICE = 0.85;     const double FANCYDOZENPRICE = 8.49;      int regular = 0, fancy = 0;     double price = 0, payment = 0, change = 0;     double costOfFancy = 0, costOfRegular = 0;      cout << "Number of regular donuts ordered: " << endl;     cin >> regular;       // calculate cost of regular donuts if donut amount is between 0 and 12      if (regular < 12 && regular > 0) {         costOfRegular = regular * REGPRICE;     }      // calculate cost of regular donuts if donut amount is greater than 12     else if (regular >= 12) {         int regDozen = regular / 12;         int regInd = regular % 12;          costOfRegular = (regDozen * REGDOZENPRICE) + (regInd * REGPRICE);     }      // set regular donut cost to 0 if 0 regular donuts are ordered     else {         costOfRegular = 0;     }       cout << "Number of fancy donuts ordered: " << endl;     cin >> fancy;      // calculate cost of fancy donuts if donut amount is between 0 and 12     if (fancy < 12 && fancy > 0) {         costOfFancy = fancy * FANCYPRICE;     }     // calculate cost of fancy donuts if donut amount is greater than 12     else if (fancy >= 12) {         int fancyDozen = fancy / 12;         int fancyInd = fancy % 12;          costOfFancy = (fancyDozen * FANCYDOZENPRICE) + (fancyInd * FANCYPRICE);     }     // set fancy donut cost to 0 if 0 fancy donuts are ordered     else {         costOfFancy = 0;     }      // add cost of fancy donuts and regular donuts together and add tax to calculate final cost     double totalCost = (costOfFancy + costOfRegular) + ((costOfFancy + costOfRegular) * TAX);     cout << "Customer owes " << totalCost << endl;      cout << "Customer pays " << endl;     cin >> payment;      if (payment == totalCost) {         cout << "Exact payment received - no change owed" << endl;     }          return 0; }   For example if the user orders 1 regular donut and 1 fancy donut the amount due is 1.72, and if the user inputs 1.72 as their payment nothing returns.

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


There are abundant information on how to shrink a growing Transaction log, from frequent log backups, to changing the RECOVERY from FULL to SIMPLE and truncate. A daily background job takes care of this process and it's working fine. By now, most people know how and why Transaction Log works. There is a complete explanation .          I have a misbehaving application that, somehow, create a growing transaction log by not releasing, not sure if it's not committing or not closing or what, at the end of the (whatever) action.      It doesn't look like there is data loss or inconsistencies and not any unusual situation on the DB.      Upon restarting SQLSERVER show the database in 'recovery mode' for a while and then back to normal.      Doing DBCC LOGINFO, shows over 100 entries, all of them with 'Status=2' so I understand, they are in use. Interesting but on some entries, the 'filesize' is even larger that the Database itself!        The subject database on SELECT name,log_reuse_wait_desc,recovery_model_desc FROM sys.databases show log_reuse_wait_desc as 'NOTHING' and recovery_model_desc as 'FULL'       My question is: Is there any method, documented or not, to 'read' the log file and find what table, application, data or whatever info is on the VLF to help finding the culprit application?

This one seems to be a common question in most forums and all over the web, it is asked here in many formats that typically sound like this:  In SQL Server -  What are some reasons the transaction log grows so large? Why is my log file so big? What are some ways to prevent this problem from occurring? What do I do when I get myself on track with the underlying cause and want to put my transaction log file to a healthy size?


I just saw this CW answer:    Under the CW, it shows Shog9. However, Tim Stone is really the poster! Why is it showing Shog?

I just noticed a  that I edited in the past shows me as the posting user. Per  and  comments below, this is because I am responsible for the largest percentage of the edits.  Why do community wiki posts show the last editing user user responsible for the largest percentage of the edits as the OP instead of the actual original poster?


They did create/created the first representative government.  Which one is better? Different non-native people think differently.

I did commented on your post.       Is this a correct sentence? As you know that we often make emphatic sentences by using "did"but when we make them we use 1st form but here 2nd form is used.  I am just confused.


I received an unofficial offer for a post-doctoral researcher position a few days ago from a well-known and respected professor in the field, and the institution is very well-ranked. At the same time, I already have an official offer from a different place, but not comparable in value. So, I need to know how certain the unofficial offer is to justify declining the official one.   Actually, after I received the first offer officially, I contacted the other places to which I had applied, and asked them to decide on my application, and set a deadline for them by when I had to decide about my already-issued offer. I received the second offer right before the deadline as an email in clear and strong words ('I am pleased to offer you ...') similar to what you see in an official offer letter. I quickly accepted the offer.   I think that since he knew I would have to decide about the other offer, he tried to be clear in the email, encouraging me to decline the other one. However, I'm not sure whether it would be wise to do so. More specifically, does such an email work as a legally binding document (e.g., capable to be held up at a court)? I'd say the difference between the values of the positions actually justifies 1%  risk. What do you suggest?

I'm in/from the US. I'm finishing my PhD this semester. I've been offered a research postdoc, via email, by the dept. chair at one of my top choices, but outside the US (would rather not give too many details). I replied to say I'm accepting the position. Everyone seems very happy: me, the chair, the professor I intend to work with. But I have nothing in writing.  In the meantime I have an offer for a teaching job at another place much closer, which I would definitely take if I were not getting the above postdoc. I don't feel comfortable turning this down until the other setup is official.  I emailed the postdoc place asking for an official letter. They said they would send it out by mail, but ignored my request for a scanned emailed copy, and I need to give a yes or no answer to the second place before their alleged letter would arrive. I emailed them again about the scanned copy and no response though it has only been a couple days.  How confident should I be that this postdoc is really happening? How common is it for informal agreements like that to be backed out of? Are scanned emailed letters less customary outside the US? It would be terrible of I turned down the teaching job and then the postdoc fell through.  Also, what should I say to the other place if I am still unsure about the postdoc by the deadline for my yes/no?  Update: I got the requested scan of the official letter today. I ran it by my adviser and he says this seals the deal and I can cancel any other interviews. Whew!!!


What does "off" mean as in "He chose a three-star hotel off fashionable Orchard Road."  As a foreigner, I was not sure. It seems to me that hotels are always "off the road", it's always "on the side of some road."  Does "off the road" mean it's near the road (off the road but on the side) or far away from the road?

The forum is located on Musavi St. off Taleghani Ave.  I am wondering what the bold part could mean here.


Given the function $$f(x)= e^{\sin{x}}$$ I have to write it without using the exponential or sine function.   I came to this point $$f(x) = \sum_{k=0}^{\infty} \frac{\sin^k{x}}{k!}$$  How can I get rid of that $\sin^k(x)$?   Thanks in advance!

Hello I have some problems concerning Taylor series.  Given the function $$f(x)=e^{\sin{x}} $$  I concluded that the Taylor series expansion would be   $$f(x) = \sum^\infty_{n=0}\frac{1}{n!}f^{(n)}(x)(x-x_0)^n$$ But Wolfram wrote a much simpler form   $$f(x)=\sum^\infty_{n=0}\frac{\sin^k{x}}{k!}$$  My question is: how come? Secondly, could somebody explain to me how  to get the second sum's radius of convergence?   Thank you very much for your time!


Windows first saves crash dumps to the pagefile. Windows only moves the data into a separate file (either a Memory.dmp file or a minidump file) after reboot.  Why must crash dumps go into the pagefile first?

I've got a secondary harddrive (a separate physical device, not a logical partition) specifically dedicated for the Virtual Memory paging file.  The drive is 3.5x larger than my RAM, so it's plenty large.  When I configure Windows 7's virtual memory to put the paging file on this second harddrive and not the same drive as the operating system, I'm warned,     If you disable the paging file or set the initial size to less than 800 megabytes and a system error occurs, Windows might not record details that could help identify the problem. Do you want to continue?   So in other words, if I get a Blue Screen of Death, I won't be able to investigate why, just because I put my paging file at a more efficient location.  The best explanation I can find from searching the web is that Windows just doesn't want to make error dumps on a drive separate from the operating system location.  Can anybody give me a less nonsense explanation for this?  I don't want to have to tell Windows, "Sure, go ahead and continue managing a paging file on the primary drive," just so I can get a debug dump, as that totally defeats the purpose of a physically separated paging file.  Is there a workaround to having my paging file on a separate drive and still get error dumps?


The statement that baffles me:     During most of the collisions, part of the kinetic energy evolve as heat, nevertheless momentum is still conserved.   Ok, the statement may be true. But what confuses me is that: Is there no relation between the momentum and kinetic energy? Are they not linked with each other?  Both concerns with velocity. If one decreases, generally it would effect the other. I know something is wrong in my understanding. But I am unable to visualize the above statement. Please help me explaining this.

In inelastic collisions, kinetic energy changes, so the velocities of the objects also change.  So how is momentum conserved in inelastic collisions?


I have an aircraft. On it are weapons. Weapons have masses and centers of masses. The larger aircraft system has a center of mass.  I wish to calculate the cumulative rotational inertia of only the set of weapons around the center of mass of the aircraft. In general, since these objects have a volume and a mass distribution, rotational inertia for each should be calculated as  $I = \int_x \int_y \int_z \rho(x,y,z) ||\vec{r}||^2 dzdydx$  where $||\vec{r}||$ is the distance to a point in space from the axis of rotation. But I can be reasonably sure that the center of mass of the aircraft does not fall inside the volume of any weapon, so essentially I have a system of satellites rotating around some external point.  Can this be reduced to simply modeling the satellites as point masses located at their centers of mass? Clearly $I=mr^2$ is not true if rotating around a point located within the volume of an object. Does it hold for objects farther away with arbitrary density distribution?

I was doing the question :     A uniform 8.40-kg spherical shell, 50.0 cm in diameter has four small   2.00-kg masses attached to its outer surface and equally spaced around it. This combination is spinning about an axis running through the   center of the sphere and two of the small masses (see ). What friction torque is needed to reduce its angular speed   from 75.0 rpm to 50.0 rpm in 30.0 s?   I understand how to get $\alpha$, and how to get $\tau$ from $I$ and $\alpha$. What I do not understand is their computation of the moment of inertia. The question did not provide any information regarding the shapes of the masses, but the solution (which writes $I=\frac{2}{3}MR^2+2mR^2$) seems to assume that the masses are point particles. Thus, the two masses along the rotational axis have a moment of inertia of 0 ($r=0$), and each of the other two masses has a moment of inertia of $I=mr^2 =mR^2$, where $R$ is the radius of the sphere and $r$ is the distance from the axis.  But why are the masses considered to be point particles? I wanted to use the parallel-axis theorem to determine the moment of inertia about the rotational axis; not knowing the shape of the masses made this impossible, since I couldn’t find the moment of inertia about the CM. If I knew $I_{CM}$, then couldn’t I use $I_{axis}=I_{CM}+mR^2$ for the two masses not on the rotational axis and $I_{CM}$ for the two that are? That would make $I_{total}=\frac{2}{3}MR^2+4I_{CM,\:mass}+2mR^2$ Would that not be a better way of solving this problem?


I am new to Java so spare me. Below you can see my code. What it should do is read the 3th column from text file and if this column is S**ei or P***ei it returns the first word in that line. However my question is "How can I make * match any character from a to z"?. I heard of regular expressions but haven't really worked with them yet. Any help would be much appreciated. Thanks.  package test;  import java.io.BufferedReader; import java.io.File; import java.io.FileReader; import java.io.IOException;  public class moja {     public static void main(String[] args) {         try {             File file = new File("SloveneLexicon.txt");             FileReader fileReader = new FileReader(file);             BufferedReader bufferedReader = new BufferedReader(fileReader);             StringBuffer stringBuffer = new StringBuffer();             String vrstica;             while ((vrstica = bufferedReader.readLine()) != null) {                  String s = vrstica;                 String[] dobi_besedo_v_vrstici = s.split("\\s+");                 String prva_beseda = dobi_besedo_v_vrstici[0];                 String tretja_beseda = dobi_besedo_v_vrstici[2];                 if (tretja_beseda =="S**ei"){                     System.out.println(prva_beseda);                     if (tretja_beseda =="P***ei")                         System.out.println(prva_beseda);                 }              }             bufferedReader.close();          } catch (IOException e) {             e.printStackTrace();         }     } }

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


Here's Theorem 4.3-2 (i.e. the Hahn Banach theorem for normed spaces):     Let $f$ be a bounded linear functional defined on a subspace $Z$ of a normed space $X$. Then there exists a bounbed linear functional $\tilde{f}$ on $X$ such that $$\tilde{f}(x) = f(x) \ \mbox{ for all } \ x\in Z,$$ and $$\Vert \tilde{f} \Vert_X = \Vert f \Vert_Z, $$ where $$\Vert f \Vert_Z \colon= \sup \left\{ \ \frac{ \vert f(x) \vert }{\Vert x \Vert} \ \colon \ x \in Z, \ x \neq 0 \ \right\} \ \mbox{ if } \ Z \neq \{\ 0 \ \}; \ \mbox{ otherwise } \ \Vert f \Vert_Z \colon= 0.$$ And, $$\Vert \tilde{f} \Vert_X \colon= \sup \left\{ \ \frac{ \vert \tilde{f}(x) \vert }{\Vert x \Vert} \ \colon \ x \in X, \ x \neq 0 \ \right\}.$$    I think I'm clear about the proof of this beautiful result. It uses the Hahn Banach Theorem for Complex Vector Spaces, which uses the Hahn Banach Theorem for Real Vector spaces, and the latter uses the Zorn's lemma.   Now if $X$ is a separable normed space, then is there a proof of the above result that doesn't involve the use of the Zorn's lemma?

I was reading about the Hahn-Banach Theorem, its many versions and their proofs. It's known that in the proofs we need Zorn's Lemma. But in the book that I'm reading, the author said if $X$ is a separable space then it's possible to prove the Hahn-Banach Theorem without the Zorn's Lemma.  How can we show there is a suitable extension of a linear functional without Zorn's lemma?


I've started building some homemade computer kits recently (like the Maximite and the Micromite Companion boards), and they have barrel jacks that accept a DC power supply that are easy to find, but come in a lots of varieties in terms of output voltage and output current.  One computer I built recently recommended a 7.5 V power supply (though anything from 5V to 9V was deemed acceptable) and an output current of 1 Amp (or at the very least 500 mA).  I have a ton of old DC power supplies that can plug into these systems, but none of them match exactly the designer's recommendations, and I'm not sure what's "safe" to use and what could potential damage the system or make it unreliable.  My main questions that I'm hoping to get help with here:  1. If a DC power supply is rated 7.5 V, what difference does it make how much current it can deliver? I understand each component in the system draws some current from the power supply, and that's why the current is clearly labelled on the plug, but then what difference does it make if 1 amps comes from a 5 volt supply or a 12 V supply?   Is there any danger in plugging in a 12 V power supply that is rated at 2.5 amps into a system that is expecting a 7.5 V supply with 1 amps?   Clearly I'm a newb on this subject, so if my questions don't make sense let me know and I'll try to clarify.  Please note: I'm not asking for a recommended power supply for a specific project. What I'm really after is just some basic understanding in how voltage and current relate in a DC circuit. I've looked extensively online and of course there's a ton of information on this, but I'm still left confused on the topic and was just looking for some help here on this site.

Power supplies are available in a wide range of voltage and current ratings.  If I have a device that has specific voltage and current ratings, how do those relate to the power ratings I need to specify?  What if I don't know the device's specs, but am replacing a previous power supply with particular ratings?  Is it OK to go lower voltage, or should it always be higher?  What about current?  I don't want a 10 A supply to damage my 1 A device.


I've received a bunch of emails with large attachments and images.  I want to keep the emails (including their headers) for my records, but I don't want the attachments and images using up my allotment of storage on Google's servers.  I also want to keep my backups small, and they add unneeded bulk to my backup files. In Gmail, how can one delete attachments/images from emails without deleting the email itself? To keep this QA generic enough to help everyone, answers addressing sent and/or received emails are fine.

My Gmail account is starting to get full, so I have been using the new search term larger:1M to find attachments that are larger than 1 Megabyte.  I'd like to just delete the attachment without losing the email itself?


I thought I needed to update stuff because of my computer randomly logging me out, So I saw that there was 1,418 updates so I installed them then after that I restarted the computer and I logged in and all that I saw was only my background picture of my desktop... Nothing else just the picture.

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


I don't understand why I've got this error: line 1: #!/bin/bash: No such file or directory  while running any piece of bash script like this: #!/bin/bash echo "pouet"  I've tried running it on a Fedora 19 and everything went well. I'm on Debian 7, I've tried parsing the first line to search for \n\r but everything was clean (every script I've made so far seems to behave the same way). My $PATH looks like this: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin. I've tried it with a normal user or root, same result. But the rest of the script seems to behave normally (echo is interpreted). And yes, /bin/bash exists and is executable. Edit: $ LC_ALL=C sed -n l < tesT.sh \357\273\277#!/bin/bash$ echo "pouet"$

I've created a bash script but when I try to execute it, I get   #!/bin/bash no such file or directory   I need to run the command: bash script.sh for it to work.  How can I fix this?


This came up because I was not able to activate the time synchronization function from the VCD. Most of what I've seen that discussed the benefits of installing VMWare tools looks like it applies to Windows machines, and perhaps also graphical Linux machines. I wonder if it will be worth it to install on this particular Red Hat Oracle Server, which also is mission critical to the point that my client is very apprehensive about making changes and restarting it. However, perhaps it does them a disservice by not having them installed. Thanks.

We have a deployment with what I would call an Enterprise Cloud Provider. It's VMWare Infrastructure 3.5.x and includes VMotion / VMWare HA instances, etc.  At Provider 1 VMWare Tools was installed:   vmware-guestd is running and; at least two kernel modules are loaded, vmmemctl & vmhgfs   Provider 1 does nightly VM Snapshots.  We are beginning a new deployment at Provider 2 (also an Enterprise Cloud Provider). They did not install VMWare Tools. Provider 2 does not do nightly VM Snapshots but rather file-system backups (using an agent).  From my reading it seems like at the very least VMWare Tools should be installed for the Memory Balloon Driver (vmmemctl) and from reading sources like  it suggests that certain VirtualCenter management operations also depend upon VMWare Tools being installed in the Linux guest.  Note that all of our instances are headless (default runlevel is 3) and RHEL.  It is hard to find authoritative information on this question and the aforementioned source is somewhat dated.  Can someone shed some light on this? What are the factors/criteria that would lead to an answer in the affirmative or negative?  TIA  Cheers


In the Stack Exchange app I see no way to delete previous posts, I must login on webpage to do this am I missing something?

Currently, the only way to vote to delete (and undelete, since you can't see deleted posts) in the Android app is to open the post in a browser, and then vote to delete from there.  Can we get delete vote functionality within the app, as well as the ability to delete our own posts?  Worth to mention: users , so it's possible in the API.  Related:


I just started canning hot peppers last year. This year I am canning salsa. I boil the jars, lids, and rings just before I seal the jar. I make 3 pints at at time. I combine all my ingredients and add 1 cup of 5 percent vinegar with 3 tablespoons of lemon juice, and bring to a hard boil for about 10 minutes. Then I turn it down to a mild boil and hot pack into the jars that I took out of boiling water.  I fill the jar, place lid on top and hand tighten the ring. Is this good?

Wondering if I have to boil my homemade jars of salsa to seal them if they sealed on their own. (Yes I sterilized them before hand) The salsa went in hot and once the lid was on, about 5 minutes later there was the telltale pop!   IF this is safe, how long does something like homemade salsa and homemade sauces keep for in sealed jars?  Thanks! ~Andrea


Hello, I am new to programming and would love to get some help. I am try to make a simple program in eclipse to work out few basic equations. I have made 2 packages,  "Equations", and "Workspace".  This is the class "quadraticEquation" in equations package.  package Equations; import java.util.*;  public class quadraticEquation {      //ax^2 + bx + c = 0      double a,b,c;     Scanner input= new Scanner(System.in);      void calculateQuadEq() {         System.out.println("Enter a");         a = input.nextDouble();          System.out.println("Enter b");         b = input.nextDouble();         System.out.println("Enter c");         c = input.nextDouble();          double z = Math.pow(b, 2) - (4*a*c);         if(z<0) {             System.out.println("This equation has no real roots");         } else if(z==0) {             double m = -b/(2*a);             System.out.println("There are 2 equal roots to this equation, " + m + " and " + m);         } else if(z>0) {             double m = (-b + (Math.pow(b, 2) - 4*a*c))/2*a;             double n = (-b - (Math.pow(b, 2) - 4 *a*c))/2*a;              System.out.println("There are 2 real roots to this equation, " + m + " and " + n);         }     } }   I am successfully able to run the variable calculateQuadEq in the same package (have tried) but when it comes to a different package, I am not able to. I tired importing the class file like this.    What can I do to achieve this?

In Java, are there clear rules on when to use each of access modifiers, namely the default (package private), public, protected and private, while making class and interface and dealing with inheritance?


To provide a little bit of context to the above question, it's not so hard to show that the statement is implied by the axiom of choice (first replace $A$ with an ordinal, then build a bijection by transfinite induction).  Also, if you replace the statement by the stronger statement "for every two infinite sets $A$ and $B$ there is a bijection $A\coprod B\cong A$ or a bijection $A\coprod B\cong B$" then the statement indeed implies the axiom of choice: given an infinite set $A$, use Hartog's lemma to find a well ordered set $B$ such that $B$ doesn't inject into $A$, then by the above statement we have that $A$ injects into $B$ and $A$ acquires a well-ordering.  But what is less clear (to me) is that the statement implies the axiom of choice.  Does it?  As an aside, I see the site is awash with people asking the question "is ... equivalent to the axiom of choice" and have tried to check that this question isn't a duplicate.  Apologies if it is.

Two simple questions: (Of course ${\frak m}$ denotes a cardinal in the weak sense in the claims below.)   Can we prove in ZF that $\aleph_0\le{\frak m\Rightarrow m+m=m}$? If not, what is the relationship of this statement for all cardinals ${\frak m}$ to AC?   The weaker principle $\aleph_0\le{\frak m\Rightarrow m}+1={\frak m}$ can be derived in ZF, and it is a well-known result of Tarski that $\forall{\frak m}\ge\aleph_0,{\frak m\times m=m}$ implies the axiom of choice, but I am not sure about the intermediate result with ${\frak m+m=m}$.  Edit: A related question: is it consistent with ZF that there exists a cardinal ${\frak m}\ge\aleph_0$ such that ${\frak m=n+p}$ with ${\frak n<m}$ and ${\frak p<m}$? It's hard to say whether ${\frak m+m=m}$ precludes this scenario.


I'm new to python and I have a python2.x script that asks a user to enter a choice between answers A, B or C in bash. How can I make the script to quit immediately when only escape key is pressed at that time while waiting for user input?   For now, I have this function. However, after escape key I have to press enter too.  def choice(prompt):     """     Choose A, B or C     ESC exits script     """     while True:         char = raw_input(prompt)         if char.encode() == '\x1B': # ESC is pressed             sys.exit("Quitting ...")         elif char.lower() not in ('a', 'b', 'c'):             print("Wrong input. Please try again.")             continue         else:             break     return char  user_choice = choice("\nChoose between A - C: ") print("You chose %s.") % user_choice.upper()   The code is in UTF-8 and escape key in bash terminal gives me ^[. As I understand msvcrt doesn't work in Linux. Can this be done, so the script works in Windows and Linux?

Is there a way of reading one single character from the user input? For instance, they press one key at the terminal and it is returned (sort of like getch()). I know there's a function in Windows for it, but I'd like something that is cross-platform.


I'm new to Ubuntu 13.04. I want a 'refresh' option, like in Windows when you right click on desktop. Can anyone help me to get that option in Ubuntu?

I have many users at the place I work, expressing the notion of switching to Ubuntu.  Most of them, for whatever weird reason wanting to know if its possible to have refresh added when you right click on the desktop.   Is that possible?


I am trying to write lines one at a time to the console and to an output file. I am not able to figure out how to pad the string so that the left part of the string is aligned left and the right part is aligned right similarly between different WriteLines's and StreamWrite's.   I've tried using the \t which works nicely if the left part of the string is similar in length to other strings, but fails if the strings are too different in length.   { sw.WriteLine($"{now} {typeOfTransaction} \t ${transacAmnt:0.00} ${currentbalance:0.00}"); }   Expected Output: 6/10/2019 4:15:44 PM Added Money         $10.00 $10.00 6/10/2019 4:15:53 PM Cloud Popcorn A4    $10.00 $6.35 6/10/2019 4:15:55 PM Cash Out            $6.35 $0.00  Actual Output: 6/10/2019 4:15:44 PM Added Money         $10.00 $10.00 6/10/2019 4:15:53 PM Cloud Popcorn A4    $10.00 $6.35 6/10/2019 4:15:55 PM Cash Out    $6.35 $0.00

Does the .NET String.Format method allow placement of a string at a fixed position within a fixed length string.   "           String Goes Here" "     String Goes Here      " "String Goes Here           "   How is this done using .NET?  Edit - I have tried Format/PadLeft/PadRight to death.  They do not work.  I don't know why. I ended up writing my own function to do this.  Edit - I made a mistake and used a colon instead of a comma in the format specifier.  Should be "{0,20}".  Thanks for all of the excellent and correct answers.


I am running Ubuntu 16.04 off a USB stick. I have tried to install Chrome via the Software Center and it says installing and then goes back to "install" a second later.  I have also tried via Terminal and have failed. I am fairly new to Ubuntu, but not Linux as a whole.

How do you install Google Chrome on Ubuntu?


When I run VirtualBox If I don't use VirtualBox for some time and then I come back to using it the virtual machine runs very slowly, obliviously all subsequent operation go enough fast.  How I can avoid the memory manager to put the VirtualBox's process in the swap when the application is not used ? I want that application to respond quickly even after long time of inactivity.  NOTE: That question is not the same of:  Preventing a heavy process from sinking in the swap file Prevent an arbitrary process to use swap Prevent process from swapping (Windows)  because I don't have access to the source code of that application.

Is there a way (application) to control RAM / swap usage policy at application level.  I have some applications that I use all the time and I want them to stay in RAM all the time and there are also application that I use quite seldom and they might be thrown to swap at demand. I know that default configured windows should give me best performance but I want to check whether I can get more :).  I use windows 7.


For a given positive integer $n$, how do I simplify $$\sum_{k=1}^n \gcd(k,n)?$$  By simplification I mean is there any formula which makes it easier to compute it (rather than just compute each term and sum up)?

I want to find this  $$ \sum_{k=1}^n \gcd(k,n)$$  but I don't know how to solve. Does anybody can help me to finding this problem.  Thanks.


When looking at suggested edits that involve changes to LaTeX code, I can't see the rendered output, only the code.  E.g. I was looking at the suggested edits for .  It would be much easier to approve or reject if I could see the LaTeX code worked out as it would be when the question is displayed, but this doesn't seem to be available.

In a suggested edit I just reviewed, about a third of the MathJax renders properly, but the rest doesn't. Note that the delimiters on puzzling are \$, so that doesn't escape it.    Related:  Don't render MathJax when viewing source:   Render MathJax when viewing rendered output: