Let $f(x)$ be a real valued function defined on $(-1,1)$ such that   $e^{-x}f(x)=2+\int_0^x{\sqrt{t^{4}+1}}\;\mathrm{d}t$ for all $x$ belonging to   $(-1,1)$ and $g(x)$ be its inverse function.   How to find the value of $g'(2)$ (the derivative of $g(x)$ at $x=2$)?  I tried writing $f(g(x))=x$ and then took derivative on both sides of original equation. But it's not working. I think I'm missing something important.  And please don't use hyper-geometric functions.

Let f be the real-valued function defined on the interval $(-1,1)$ such that $e^{-x}f(x)=2+ \int_0^x\sqrt{t^4+1}dt$ for all $x\in(-1,1)$ and let $f^{-1}$ be the inverse function of $f$. Then find the value of $(f^{-1})'(2)$.  This is my step  1-$f(x)=y$  2-$f^{-1}(y)=x$   3-$f^{-1}(x)=y$  4-$f^{-1}(x)'=\frac{dy}{dx}$  5-  $y=f(x)=2e^{x}+e^{x} \int_0^x\sqrt{t^4+1}dt$  6-  $y'=2e^{x}+e^{x} \int_0^x\sqrt(t^4+1)dt+e^x\sqrt{x^4+1}$  I am lost after this step, please help me as I have jolted down the step.


Setup:   java 1.8 JUnit 4.8.1   Java is not really my thing. But still I'm playing around with JUnit. I wish to write a test case of which he outcome is an exception.  I followed some examples I found with no luck  import biblioteca.exception.InvalidAuthorException; import biblioteca.util.Validator; import org.junit.Rule; import org.junit.Test; import org.junit.rules.ExpectedException;  import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue;  /**  *  Test  */ public class MyTest  {     @Rule     public ExpectedException exception = ExpectedException.none();      @Test     public void testValidator()     {         assertTrue(Validator.isAlphaNumeric("A1"));         assertFalse(Validator.isAlphaNumeric("><"));         assertTrue(Validator.validateLength("vasile", 2, 64));         assertFalse(Validator.validateLength("vasile", 24, 64));         assertTrue(Validator.containsAtLeastOneLetter("1234a"));         assertFalse(Validator.containsAtLeastOneLetter("1234"));     }     @Test     public void testException() {         Validator.validateAuthor("123");         exception.expect(InvalidAuthorException.class);     } }   This approach throws an error    This approach does not result in the desired outcome (I want the test to pass as I'm expecting the error)  What am I missing?

How can I use JUnit4 idiomatically to test that some code throws an exception?  While I can certainly do something like this:  @Test public void testFooThrowsIndexOutOfBoundsException() {   boolean thrown = false;    try {     foo.doStuff();   } catch (IndexOutOfBoundsException e) {     thrown = true;   }    assertTrue(thrown); }   I recall that there is an annotation or an Assert.xyz or something that is far less kludgy and far more in-the-spirit of JUnit for these sorts of situations.


I recently read this article () about data tables. The article contains a bunch of uses for data tables. To communicate the ideas, the author is using some animated gifs if the data tables.  My question is, does anyone know what tool was used to create those animated designs?

I'm sure you've seen Dribbblers upload animated mockups of their designs.   Here's an example:     I can create mockups on Photoshop and even apply simple Tween Animations to them but I can never get my GIFs to look like the example here.   What are Dribbblers using to create these animations?   Notice that the animations also include touch points and perfect motion. I would like to convert my Photoshop mockups to do the same.  How can I create an animated example of my mockups, similar to the ones created by Dribbblers?


I have a large (maybe 22^56 or so items this time) generator in python 2.7. I'd like to know how many items are in the generator so that I can estimate time to complete the task. Unfortunately when I tried len() of a list comprehension, it killed the whole python instance...  >>> len([i for i in giant_word_list_generator]) Killed: 9 [user@host:~/Documents/work/bin|16:59:28] $    How can I estimate the number of items in the generator for progress estimation? I would be okay with estimating to the nearest .25 order of magnitude (e.g. 250,000,000 or 50,000)

Python provides a nice method for getting length of an eager iterable, len(x) that is. But I couldn't find anything similar for lazy iterables represented by generator comprehensions and functions. Of course, it is not hard to write something like:  def iterlen(x):   n = 0   try:     while True:       next(x)       n += 1   except StopIteration: pass   return n   But I can't get rid of a feeling that I'm reimplementing a bicycle.  (While I was typing the function, a thought struck my mind: maybe there really is no such function, because it "destroys" its argument. Not an issue for my case, though).  P.S.: concerning the first answers - yes, something like len(list(x)) would work too, but that drastically increases the usage of memory.  P.P.S.: re-checked... Disregard the P.S., seems I made a mistake while trying that, it works fine. Sorry for the trouble.


I updated the iPad and the music app updated to different layout. Can I return to previous update? It is for my mother and she can't see. She could play music and now with the upgrade she can't use it. Just need to know if it is possible to go back to previous upgrade or even a few upgrades previous.

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


Express, as a recurrence relation, the number of ternary strings of length n that contain either 2 consecutive 0's or 2 consecutive 2's. Don't forget to include the base case. Can someone help me start this question? Can we say the base case would be length n = 2   i.e (00 , 22) n = 3  i.e (000, 001, 002, 100, 200, 022, 122, 222,220, 221)

Note: Problem from "Kenneth Rosen's DM and it's applications" and solution from "Students solution guide for use with ... applications"  Let P(n) be the number of strings not containg two containing two consecutive zeros or two consecutive ones.  I got the answer  P(n)=P(n-1)+2P(n-2)+2P(n-3)+...+2P(0) +2  but then the book says the sequence also satisfies the recurrence relation  P(n)=2P(n-1)+P(n-2). I am not able to understand this part.


If I recall correctly, the story describes life on the American frontier, but the characters soon realise there's a world outside and that they're essentially living in an exhibition. The characters then escape and I am 99% sure that the area they escape to the "real world" and discover the truth is either: Indianapolis or Minneapolis - it definitely ends in -polis. I read this in about 2000, but no idea when it was published! This is a book. People say it sounds similar to Westworld and it is very similar, but they are humans not robots. I may be entirely wrong but I believe that the characters discover that they are in this exhibition because they discover some "limits" to their world maybe like the glass panel or something. I also think there is some requirement for the girl to go somewhere outside of the exhibition maybe for medical reasons but honestly I am not sure that this is true or if I'm making things up.

So, I remember being read a book in elementary school (so it was at least written by 97-98). It was about a girl in the 1700-1800's who found out she was actually part of an exhibit in a history museum - The entire younger generation thought they were actually in the time period, while all the adults were in on it. Could someone help me identify this story?


The question:  $$\sum_{n=0}^\infty\frac{2^n+4^n}{6^n}=\;?$$  I can't figure out how to approach this question as I can't find a constant value for $r$.

I am being asked to find the sum of the following convergent series :  $$\sum_{n=0}^∞ \frac{2^n}{6^n} + \frac{3^n}{6^n}$$  Attempting to generalize from partial sums yields nothing of interest:  $s_1 = \frac{5}{6}$  $s_2 = \frac{5}{6} + \frac{13}{36} = \frac{43}{36}$  $s_3 = \frac{43}{36} + \frac{35}{216} = \frac{293}{216}$  $s_4 = \frac{293}{216} + \frac{97}{1296} = \frac{1855}{1296} $  I do not see a pattern here...  How must I proceed to find the sum of this series?


After installing latest nvidia drivers from xorg edgers ppa, the boot screen ( where it shows ubuntu logo) displays background process as text.  Is there any way to restore the default boot screen using nvidia driver.  (Note: It changes back to default logo and resolution once I change back to nouveau driver)

When you boot from live CD, or doing the first boot after installing Ubuntu, splash screen looks awesome. But as soon as you enable nvidia-current driver, installed with apt-get, splash screen goes all crazy.  With crazy I mean that resolution is very low, font(I assume) is very weird and it all looks like it's been broken.  This happened with 10.04 and now again with 10.10.  How do I fix splash screen after enabling nvidia drivers?


In The Walking Dead, the outbreak starts in an unknown year, but we know that Carl had to have been at least ten and the show has been going on for six years now and then by the time it's season six Carl is a teen.  So my question is how long has everything been happening for?

Many have questioned the ability of the Still-Alives to have survived the zombie apocalypse, considering the stupid decisions they make, like the well debacle (2x04 - "Cherokee Rose"). But it's possible that they actually haven't been alive for very long.  How many days have passed from the start of the show to the events of episode 2x05 - "Chupacabra"?


Just to make this clear, this is not my usual avatar on GTA online. I was playing a recent game and went into a quick mission, but when I entered the game with 3 other random players, I looked like this:  This is not my avatar and somehow a snowman has been added over, in addition a camp fire, which is constantly burning me until I die (the only reason I am not currently is because I am in my garage.) I am not sure but my account may have been hacked. Any help on how I can stop constantly burning and revert my character to my original avatar (without burning)?

I was playing Grand Theft Auto Online on Xbox 360, and a player teleported to me.  I shot them, but they placed a campfire on me.  Now, I am constantly being burnt to death. How do I get out?


I want to put a paragraph after an image but latex always put the paragraph before the image. how can I do it? Thank you.

Is there any package or a method to force LaTeX to keep floating environments like table and figure closer to where they are declared?


I uninstalled ubuntu 32 bit to get ubuntu 64 bit but when I did that when I turn on  my pc when I try to go to windows and get a black screen that just blinks and I do not have a windows disk

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


I'm trying to remember the name of this short story. As far as I remember the guy wants someone killed so he hires a hitman to kill the person, but the hitman says he will get a discount if he chooses some more people to kill. The guy then finds some more people but the hitman says again that if he finds more X people the discount will be higher. This keeps repeating until the hitman offers to kill all of mankind for free (I think) and the guy chooses that. I remember that it ends with the guy hearing sounds and screams of people getting killed everywhere.

I think I read this in the 90's.  As I recall, a guy found out his wife was cheating on him. While flipping through the phone book, he finds an "Exterminator". He calls the number and is offered a two (or three) for one special. Asks for time to come up with another name. Each time he calls back with a list of names, he's offered a better deal for more names. At one point, asks how many people have to die for him to become King of England. Finally gets down to asking how much for everybody on the planet and the answer is "free".


I use LaTeX2e Standard Macros for SIAM Journals for my thesis and try to insert the bibliography. If I see this correct, at the end of your document you have to add    \bibliographystyle{siamplain}   \bibliography{reference}   where in the example reference.bib file you find the articles/books etc. listed as    @Misc{AMSMSC2010,   title =    {{Mathematics Subject Classification}},   author =   {{American Mathematical Society}},   year =     {2010},   url =      {http://www.ams.org/mathscinet/msc/msc2010.html},   urldate =  {2015/03/29},   }   with no further code. But it just doesn't work. I can't use my own bib-file mybib.bib nor the default one. In the pdf there will simply appear a [?] when I use    \cite{AMSMSC2010}   Are there packages which can cause problems?

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}


So this is the problem. Ive been tring to put the red dot on the 3d model, but i cannot seems to understand how texturing works, I already have a texture for my plane, but i want to put a png on that texture.

I'm designing this animal-type creature, and want to add a transparent .png image to its face with the face features (object has a subsurf). On the left is the image with the features, on the right is the part of the object where I want it to be.    I tried to import the image as a plane, but matching the shape of the plane with the face didn't work, and the lines of the face left shadows on the head, and could be seen as a different object from some angles (although it's the closest I've gotten yet). It looked like this:    So , I tried selecting the faces of the head that the features should go over, and create a new material for it. Unfortunately, since the .png is transparent, the result produced was this:    (where it's impossible to tell the transparency from a black background default color, and where I wouldn't know where to start to adjust size and position).  I also tried UV mapping, but then the whole object became black with the features repeated all over.   Is it something I have to go into Nodes for? I'm kind of stuck here. Creating a new material and applying it is simple, but applying a material that is an image is a bit more complex it seems... Ideally, I would reproduce the same technique for the adhesive bandage on its arm (seen on the right of image 1).


I compared the output from the two approaches using rfsrc() and gbm() in R respectively. The important factors given in the output from the two approaches are totally different. Since the importance of factors in gradient boost depends on the order of the trees, are they somewhat arbitrary? How do we interpret the important influencers from gbm()?

I am using both random forest and xgboost to examine the feature importance. but i noticed that they give different weights for features as shown in both figures below, for example HFmean-Wav had the most important in RF while it has been given less weight in XGBoost and i can understand why?


A question is about variable scope. Why next next function2 modifies list l  def function1():     myvar = 1     l = []     def function2():                                                                      l.append(3)     function2()     print l   But it gives error "local variable 'myvar' referenced before assignment", if I add next line myvar = 4,    def function1():     myvar = 1     l = []     def function2():         myvar += 4                                                                        l.append(3)     function2()     print l   How to modify myvar that is local to function1 within function2 without making myvar belong to the module scope (module global variable)? References to documentation are appreciated!

What exactly are the Python scoping rules?  If I have some code:  code1 class Foo:    code2    def spam.....       code3       for code4..:        code5        x()   Where is x found?  Some possible choices include the list below:   In the enclosing source file In the class namespace In the function definition In the for loop index variable Inside the for loop   Also there is the context during execution, when the function spam is passed somewhere else. And maybe  pass a bit differently?  There must be a simple reference or algorithm somewhere.  It's a confusing world for intermediate Python programmers.


I've downloaded lots of music from the Apple Music trial, what happens if after say 4 months I stop paying? Does all my music get deleted or do I get to keep it.

I am now using the 3-month free trial of Apple Music. Yesterday, I downloaded a few albums into my iPhone. If I do not join the subscription after the free trial period, will the songs still be in my iPhone?


I'm not interested at converting it, but extracting the thumbnail JPEG.

When you're shooting in RAW-only mode (not RAW+JPG), most (all?) cameras also generate a JPEG preview using the current style settings. This is what you see momentarily when you first import the image into Lightroom, and also what you see on the camera's LCD. (Try switching the picture style to B&W and you'll see this very clearly: B&W on the camera's LCD and briefly in Lightroom before it's overwritten with a colour image.)  My question is, is there any way to save that preview from the camera as a separate JPEG file?  If so, how?  (I know that shooting RAW+JPG in the first place is the best way to achieve this, but I was thinking particularly of the problem posed in .)


Given a triangle with vertices $A,B,C$, Show $\sin(A)+\sin(B)+\sin(C) \leq \frac{3 \sqrt{3}}{2}$.  Here is a proof using Jensen inequality: $\sin(x)$ is concave from $0$ to $\pi$.  hence $\frac{\sin(A)+\sin(B)+\sin(C)}{3} \leq \sin(\frac{A+B+C}{3})=\frac{\sqrt 3}{2}$ and hence we get the desired inequality by multiplying the previous inequality by $3$.

What is the maximum value of $\sin A+\sin B+\sin C$ in a triangle $ABC$. My book says its $3\sqrt3/2$ but I have no idea how to prove it.   I can see that if $A=B=C=\frac\pi3$ then I get $\sin A+\sin B+\sin C=\frac{3\sqrt3}2$. And also  maximum is attained for $a=b=c$. But this does not give me any idea for the proof.  Can anyone help?


Sounds trivial, I know. But you are working on the text of your comment. In a small space. So the natural reaction is to get  a new line by hitting the return key. Wham, your half completed comment is posted AND you have only 5 minutes to get it right. Up goes the heart rate. Would it not be more friendly to have only the Add Comment button do the posting?

I don't think I'm going any more crazy than normal, but I'm surprised I can't see any other meta mention so far. This started happening recently on at least SO and ubuntu.SE, and occurs in at least IE and Firefox. So I'm guessing it's a deliberate feature not [bug]. But I'm not keen.  It's not standard in any browser for a <textarea> to submit when Enter is pressed; the behaviour to me seems spooky and undesirable. I've already accidentally-commented more than once and had to delete the comment and drag the text back into editing.  (I realise you can't actually have a newline in a comment, but I've often used newlines to separate thoughts I'm editing together into a comment, or maybe bits to overflow into a subsequent comment. I don't really want to have to break out the text editor to get this ability.)  May I have my Enter key back please Sir?


I am starting a new class of theory of computation (you know, where we talk about the turing machine, etc etc) and I am having some difficulties to understand that $|\mathbb N| = |\mathbb Z|$ (they are the same infinite). Before I started this class my intuition always said that $|\mathbb N| < |\mathbb Z|$. Can some one here with your own words explain to me why are $\mathbb N$ and $\mathbb Z$ the same infinite?  Thanks!

In our 6th grade math class we got introduced to the concept of integers. With all the talk about positive and negative, it got me wondering. Is the amount of elements in $\mathbb{Z^+}$ less than the amount of elements in $\mathbb{Z}$?  Here is how I thought of it. If we have $\mathbb{Z^+}$ and add one element to the "back" of it ($\mathbb{Z}^{\geq-1}$) there are certainly more elements in that new set, so there must be more elements in $\mathbb{Z}$ than in $\mathbb{Z}^+$ but on the other side if we try to express the amount of elements in them "numerically" (In a loose sense of the word) they both have $\infty$ elements.    So what is the right answer? Is there even one?  (Please note I am a bit of a layman when it comes to mathematics)  Edit: About the possible duplicate, I am not looking for a bijection between the two sets, I am looking for if they even have the same number of elements and why a bijection shows that they do/don't


I've started tinkering with Blender a few days ago and finally produced my own rendered image.  The only problem is that the final render is way too noisy to use.  It took around 1-2 hours to complete and I even tried to use a , but it didn't seem to do too well.   Are there any suggestions that could help with the final result? I can attach the blend file as well if that helps.

I know that this question is a bit old or maybe overdone, but I'm running the latest edition of Blender and when I use the Cycles engine I get really fuzzy results and I can't find a simple, non-compromising solution to the quality.  I don't know exactly what I'm doing wrong here, but I'm sure others share my frustration.  Leaving everything in default settings, I started a new project and switched to the Cycles render.  I duplicated the cube and set colors for two Diffuse BSDF shaders, then went ahead and made walls and a floor all sharing the same diffuse shader.  I made two windows to emit blue light.  The screenshot has gaps between the walls because of the setup:  I'm aware that it's considered very incomplete and many have come to terms with some amount of noise, but is this normal?  Furthermore, with default settings or not, I can't change the amount of noise produced.  Supposedly, using "progressively refine" in the rendering tab should make it refine itself indefinitely, however Cycles only counts to 10 refines and then stops, creating a render which is a pixel-perfect match of the ordinary rendering method when it's completed.  I understand that there are tricks that can be used to reduce noise, but at the cost of extra processing time and usually small quality conflicts, like blurring.  My question essentially boils down to is this Cycles' current limit?


We're trying to rig 6 bundles of 10 motors at a time, so 60 motors in total on the same power supply.  Each one normally is directly powered with 1.5v aa battery. We read the current as 200ma per motor.  PS. I am dyslexic, and have severe learning disabilities. Forgive any grammar and punctuation issues.

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.


kindly help to install ooVoo in Ubuntu 12.04 64 bit.

The only reason I ever boot into Windows (7) is to use the popular video chat software ooVoo (). It's useless under Wine and there seems to be no way to run it in Ubuntu except for some proprietary tools. Does anyone have any information on some alternatives to running it with Wine?


I'm studying SQL Server. I have read that a database can have several data files and one log file, but recently I was heard that a database can have more than one log file.   Is this true?

So I've gotten into an argument with several people regarding the number of transaction log files a give databases should have.  I've seen several post saying you should only have 1 transaction log file for each database, nothing in any Microsoft whitepapers though. However in many cases I've seen that increasing the number of transaction log files for a given database will actually improve the write performance to the database.  I should note that all these databases are in Full recovery model and are using a large SAN frame for the I/O sub system.  If as many of the posts say that the transaction writes all happen serially to the one file until the end of the file is reached then the writes move on to the subsequent log file, why would increasing the number of log files end up have a very noticeable improvement on the Write speed to the Disk?  In the most recent case we saw IO jump from 700 Kb/s to more than 60 Mb/s by increasing the number of log files from 1 to 8.  Any input would be appreciated.


I have an ordered list with dynamically loaded li elements. Each of these li contains a div. By clicking on this div, the li containing it should be deleted. I have given these divs a height and width of 24px.  The li look like this:
Some text

   These are appended to the ol like this:  $('#id_of_ol').append('
Some text

');   Here is the jquery code that I have tried:  $('#child').on('click', function () {     alert("clicked"); });   Of course, this alert is just there to check whether it's working, I will replace that with remove() later.  However, this doesn't work. On clicking, nothing whatsoever happens. What's the problem here?

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


(Full disclosure: this question relates to programming logic in a JavaScript problem I am working on, hence its "simplicity".)  A ball is dropped from a given height and bounces one dimensionally (up and down). With each bounce, the ball climbs 2/3 the height of its previous bounce.  How can I calculate the number of times the ball will bounce higher than a specific height? We can assume this target height is lower than the height at which the ball was originally dropped.  My current solution checks the height of each bounce against the target height, incrementally adding 1 to the solution each time. This is inefficient, however, particularly in such cases where there is a substantial difference between the original height and the target height. For example: if the ball is dropped from 100,000 feet, bouncing up to 2/3 its previous height each time, how many times will it bounce higher than 1 foot?

I need help in calculating the math behind the below question.     A child plays with a ball on the nth floor of a big building the height of which is known . He lets out the ball. The ball rebounds for example to two-thirds of its height.      His mother looks out of a window that is 1.5 meters from the ground.    How many times will the mother see the ball either falling or bouncing in front of the window     Note    You will admit that the ball can only be seen if the height of the rebouncing ball is stricty greater than the window parameter.   Example: h = 3, bounce = 0.66, window = 1.5, result is 3  What i have learnt is      I know that the ball falls from 27 feet and bounces back up 2/3 of that height, so I multiplied 27 times (2/3) and got 18 feet for the height of the first bounce.       Then, since it went up 18 feet, it fell from 18 feet   for the second bounce and bounced back up 2/3 of 18 feet. A table showing the four bounces:    Bounce 1:  (2/3) * 27 feet =   18 feet Bounce 2:  (2/3) * 18 feet =   12 feet Bounce 3:  (2/3) * 12 feet =    8 feet   I dono from this , how to reach solution ?


There should be slots next to global but I cant find them.

Usually my layers tab appears in the area of the red circle, but I did something that changed it. I would like to know how to get it back. Thanks!


So I know when listing variables in object class, you can return every line to list the variables vertically for better organization:  class Thing(object):   def __init__(x,                y,                z):   Is it possible to do the same thing with conditionals in an if statement, like so?  if condition1 and    condition2 and    condition3:   Obviously that's probably not the right syntax for it since it doesn't work, but it's a good example of what I'm trying to do in order to organize my code so I don't have scroll to right when something has long names for conditional satements.

Sometimes I break long conditions in ifs onto several lines. The most obvious way to do this is:    if (cond1 == 'val1' and cond2 == 'val2' and       cond3 == 'val3' and cond4 == 'val4'):       do_something   Isn't very very appealing visually, because the action blends with the conditions. However, it is the natural way using correct Python indentation of 4 spaces.  For the moment I'm using:    if (    cond1 == 'val1' and cond2 == 'val2' and           cond3 == 'val3' and cond4 == 'val4'):       do_something   But this isn't very pretty. :-)  Can you recommend an alternative way?


I will soon make a math exame where one can't use L'Hôpital's rule, integrals concept neither the formal limit definition. The most I can use is the derivative definition and the algebraic ways to solve limits.  My thought was:  Let $\displaystyle \lim_{x \to \infty} \frac{\log(x)}{x}=y$, so $\displaystyle \lim_{x \to \infty}\log(x^{\frac{1}{x}})=y$.  Then,  $$\displaystyle \lim_{x \to \infty}e^{\log(x^{\frac{1}{x}})}=e^y \Leftrightarrow$$   $$\displaystyle \lim_{x \to \infty}x^{\frac{1}{x}}=e^y $$  I ended with an indetermination.  How can I proof the $\displaystyle \lim_{x \to \infty}\frac{\log(x)}{x}=0$ with the restritions and as formal it can get? Thanks.

Find $\space\ \begin{align*} \lim_ {x \to+\infty} \left [ \frac{\log_{2}(x-1)}{x}\right]   \end{align*}$.   After some minutes around this limit I did it this way:  $\log_{2}(x-1)=y \Leftrightarrow 2^y=x-1$  So,$\space x=2^y+1$.  When $x \to +\infty$,$\space y \to +\infty$ also. By substitution:  $\begin{align*} \lim_ {y \to+\infty} \left [ \frac{\log_{2}(2^y+1-1)}{2^y+1}\right]=\lim_ {y \to+\infty} \left [ \frac{\log_{2}(2^y)}{2^y+1}\right]=\end{align*}$  $\begin{align*}\lim_ {y \to+\infty} \left [ \frac{y}{2^y+1}\right]=\lim_ {y \to+\infty} \left [ \frac{1}{\frac{2^y+1}{y}}  \right]=\lim_ {y \to+\infty} \left [ \frac{1}{\frac{2^y}{y}+\frac{1}{y}}\right]= \frac{1}{+\infty+0}=0  \end{align*}$  Is this correct?Are there any other easy way to find this limit?Thanks


I am trying to convert a mov I have created by recording my screen with Quicktime (I am running Mac OS El Capitan) but the result is far from perfect. I am using ffmpeg (installed using homebrew) but the end result is disappointing. Any ideas? Thank you.

I'm converting a video to GIF file with ffmpeg:  ffmpeg -i input.flv -ss 00:00:00.000 -pix_fmt rgb24 -r 10 -s 320x240 -t 00:00:10.000 output.gif   It works great, but output gif file has a very low quality.  Any ideas how can I improve quality of converted gif?


I have a good Travel history ( Visited UAE Twice , Italy , Spain , USA Twice , also Visit UK Last year on a Family Visit Visa Which was Sponsored by my Brother ) Now this time I apply for UK General Visitor Visa with my Family ( Wife & 2 Kids ) , to Visit UK for Tourism for 10 Days, But Unfortunately Refused because I have Transactions of almost 6-8 Lac in my Bank Account in month of June & I didn't explain the Origin of Funds, Now I want to tell you guys that this amount is a Commission which I get from my Company every 6 months, I got around 8 Lac in February as well ( Which is Deposited in my Bank Account as well ) for last 6 months of 2015 & Now in June I got again almost 8 Lac for first 6 months of 2016, Now my Question is How Can I prove that this is my Commission, ( Note, When I apply my UK Visa, I clearly Mention That I also got commission from my Company except Salary but I did not mention amount & dates ), Now Please Guide me that Should I Reapply immediately by explaining all this situation ? How Can I Prove that this amount is my commission for last 6 months ? Please Help me , I will really Appreciate your kind response. If Possible Please give me a Sample  that How to Write a Letter to Visa Officer When Reapplying after Refusal to explain the above Mention Situation. & Please also tell me that id it fine if my employer explain on Company's Latter head that they give me Commission of last six months in June., I will be grateful for your kind Response.

I have applied recently for a general visitor visa to the UK to spend 10 days during Christmas with my British unmarried partner and it has been turned down.   The Entry Clearance Officer stated on his refusal notice the following:     I note that you have never previously travelled to the UK or any country with similar immigration requirements and you therefore do not have a history of travel and compliance to consider.      You have submitted an employment letter to confirm your occupation in KSA but I am required to also assess your personal, domestic and economic circumstances in determining whether you are genuine visitor travelling to the UK for the period and purpose you state.      You claim an income of SAR ........ per month which equal ........ GBP and from the evidence submitted this appears to be your sole source of income.   I note that this monthly income is reflected on your bank statements. However, the bank statement you have presented show a recent large deposit that are in excess of your stated income and inconsistent with the account history. You haven't provided evidence toward the origin of this recent deposit and in the absence of reasonable evidence I am not satisfied that these bank statements accurately reflect your personal circumstances.      In view of the above, I am not satisfied you have demonstrated that your circumstances are as you claim and therefore I am not satisfied that you're travelling to the UK for the period and purpose you stated. 41(i)and(ii).   Its true that I have deposited that sum of money right before I apply and it was a commission I received from work earlier this month.   So, could you please give me your advice on the above as I am planning to apply again soon. and how to avoid my application being refused again?


Here is the Data in my MySQL DB   And the corresponding PHP code to retrieve it  $query = "SELECT * FROM `states` ORDER BY `NAME`"; $result = mysqli_query($connection, $query);  $json_response = array();  while ($row = mysqli_fetch_array($result, MYSQL_ASSOC)) {     $field_info = mysqli_fetch_fields($result);     foreach ($field_info as $value) {         $row_array[$value->name] = $row[$value->name];     }     array_push($json_response, $row_array); } echo json_encode($json_response, JSON_UNESCAPED_UNICODE);   JSON output is printing ???? instead of actual text  Help !  Here is JSON Output

I'm setting up a new server and want to support UTF-8 fully in my web application. I have tried this in the past on existing servers and always seem to end up having to fall back to ISO-8859-1.  Where exactly do I need to set the encoding/charsets? I'm aware that I need to configure Apache, MySQL, and PHP to do this — is there some standard checklist I can follow, or perhaps troubleshoot where the mismatches occur?  This is for a new Linux server, running MySQL 5, PHP, 5 and Apache 2.


$[a,b)$ and $(a,b)$ are not homeomorphic  Hint given to me is: removing one point from $(a,b)$ leaves a disconnected set whereas removing a point from $[a,b)$ still gives a connected set.  I don't understand how being able to remove points and preserving connectedness while doing that is related to homeomorphism  Is there a simple way to show this?

As the topic, how can I prove it?     Prove that (a,b) and [a,b) in R are not homeomorphic metric space.   I'm pretty weak on this section (homeomorphism) and I don't have any clue to figure it out.  Please help me, thank you.


My home is 1970s construction with aluminum wiring. I have recently upgraded several fixtures in my bathroom and basement. These fixtures have all been internally wired with stranded aluminum wiring. The directions for these fixtures make no mention of special care needed for joining aluminum to copper. About half of the fixtures have shipped with some sort of crimp connector to join to the house wiring, the remainder have shipped with bog standard wire nuts. These fixtures are all LED lights. I expect them to be fairly low draw.  I am well aware of the risks of AL wiring when adding fixtures and outlets. CO/ALR receptacles triple the cost of simple work in my home. I am well aware of the risks and needs of joining aluminum wiring to fixtures made for copper.  Do I need to take any special precautions when wiring aluminum to aluminum for these new fixtures?   Do AL to AL connections pose any risks distinct from AL to CU connections?

I just purchased and installed a new Panasonic FV-10NLF1 inline exhaust fan.  My house has copper wiring, but the wires on the fan appear to be aluminum (they are silver in color).  I didn't think anything was made with aluminum wire anymore.    What special considerations do I need to take when connecting the copper house wiring to the fan wires?


Question:  ${Let S = \{x_1, x_2, x_3, ..., x_n\}}$  Show that  ${\backsim\Bigl(\forall x {\in} S,P(x)  \vee  Q(x)\Bigr) \Leftrightarrow  \exists x {\in} S, \Bigl( \backsim P(x)  \wedge  \backsim Q(x)\Bigr)}$    This is what I have done so far ...  ${\backsim\Bigl(\forall x {\in} S,P(x)  \vee  Q(x)\Bigr) \Leftrightarrow  \exists x {\in} S, \Bigl( \backsim P(x)  \wedge  \backsim Q(x)\Bigr)}$  ${\exists x {\in} S,  \backsim P(x)  \wedge  \backsim Q(x)\Leftrightarrow  \exists x {\in} S, \Bigl( \backsim P(x)  \wedge  \backsim Q(x)\Bigr)}$  And then I have no I idea how to continue from here.  Any hint will be appreciated.

Can someone help me? I can't even understand what the question is asking for.     Let $S = \{x_1,x_2,x_3,\ldots,x_n\}$. Show that ${\sim}[\forall x\in S,P(x)\lor Q(x)]\iff \exists x\in S,[{\sim}P(x)\land {\sim}Q(x)]$


My sister and I are trying to start a LAN server. It worked fine yesterday, but today it is not working anymore. Each time she tries to log in it says:  java.net.connectException:Connection refused: no further information.  Does anyone know what to do?

I am getting the following error when I try to connect to a Minecraft server:  This is all servers, not just one. The error says:  io.netty.channel.AbstractChannel$AnnotatedConnectException: Connection refused: no further information: Version 1.12  I've tried:  Restarting Minecraft Restarting Computer Uninstalling and Reinstalling Mincraft Uninstalling and Reinstalling Java Altering Firewall Restarting Internet I've messed with my port, made a second windows account, reset netsh winsock Checked hosts Made a new WINDOWS account  The overlay in the bottom right is Geforce's Overlay for game capturing. I don't have any mods installed. A Mojang support ticket wouldn't help. Im desperate.


After upgrading to 18.04 the login prompt on my laptop acts really strange: It wait's for the input of the user name and after pressing ENTER it behaves as if the ENTER key is stuck and gives no chance to enter the password. Here is a picture:  The exact step that happen are as following: 1. It shows the normal login prompt  Ubuntu 18.04.1 LTS computername tty1 computername login: _  2. It wait's for the input of the username and until you entered the username it behaves normally. 3. As soon as you press ENTER to confirm the username it immediately goes on to  Password: Password: Login incorrect.  Without waiting for any user input. So there is no chance to login to this PC anymore?!

I upgraded from 16.04 to 18.04. When I press Ctrl+Alt+F3 I get the terminal which prompts for the username. When I type my username and press Enter, it doesn't wait for my password (its as if I pressed Enter without entering anything). Even if I enter something, the text shown in plaintext and then it keeps on saying my password is wrong. After few times, the screen is cleared and it prompts for my username again and the same loop goes on.


"she RETURNED 2 days ago and she HAS KNOWN me for 2 yrs"  Why in the 2nd sentences we have used "HAS" and not in 1st sentence?

Non-native speakers often get confused about what the various tenses  and aspects mean in English. With input from some of the folk here I've put together a diagram that I hope will provide some clarity on the matter.  I offer it as the first answer to this question. Consider it a living document. Input is welcome, and good suggestions will be  incorporated into the diagram.    Nota bene: What this is not is a discussion of whether there are  more than two tenses in English. , to which this question is not intended to supply arguments one way or the other.  Here, the aim is to provide an overview of what constructions English-speaking people use for conveying information about actions referring to past, present, and future, and to provide it first and foremost to precisely the people who are likely to use "tense" as a catch-all term in their search, rather than to linguists who know better.  Breaking News There is now an excellent ELU blog article titled  . It is highly recommended reading.


I have a scenario where i want to calculate the sum of below data set   V1|V2|V3   "1.1"|"1.2"|"A" "1.1"|"1.2"|"B" "1.1"|"1.2"|"C"   sum of V1 V2 ?  how to that   output :  3.3 3.6

I have a scenario where i want to calculate sum of column   SAL|CAL|TAG|VAL 12.11"|"1.1"|"2.1"|"1.1 13.11"|"1.1"|"2.2"|"2.2 14.11"|"1.1"|"2.4"|"2.4   My below code not giving output giving output as 0.00  I need output for this column CAL VAL  awk -F'|' '{T+=$2} END { printf "%.2f\n", T }' demo.txt   output :  6.7 5.7


Given $a, b \in Z^+$, where $\gcd(a, b) = 1$, we can define an arithmetic sequence $c_i = a + i \cdot b$. The sequence is thus $\{a, a+b, a+2b, \cdots\}$. Do all such sequences contain a prime? Do they contain an infinite number of primes? Example: $a=2, b=3$. Then, $c_1 = a+b = 5$, which is prime. Meanwhile, $a=4, b=2$ does not have primes, but $\gcd(a, b) = 2 \neq 1$, so this isn't a counterexample.

Q: Is every element of $\mathbb Z/p\mathbb Z$ represented by a prime number? More generally, let $m, n \in \mathbb Z$ be coprime. Is there a prime number congruent to $m$ modulo $n$?   the affirmative answer is given by .     A: Yes, in fact there are infinitely many such primes.   I don't want to prove Dirichlet's theorem. Is it obvious that there always exists at least one such prime?


Structure table Comments:  id (int 11) NewsIdn (varchar 10) CommentsIdn (varchar 10) // ForCommentsIdn (varchar 10) //have CommentsIdn comments(answers) reply to which users  Text (varchar 100) DateCreate (datetime)   I would like output comments and comments(answers) for comments, ie. structure output data on page:  -- comment 1 -----answer on comment 1 --------answer on answer on comment 1 (№1) --------answer on answer on comment 1 (№2) --------answer on answer on comment 1 (№3) ----------answer on answer №3 on answer on comment 1 ------------- ---------------N                        ***                        ***                        *** -- comment 2 -----answer on comment 2 --------answer on answer on comment 2 (№1) --------answer on answer on comment 2 (№2) --------answer on answer on comment 2 (№3) ----------answer on answer №3 on answer on comment 2 ------------- ---------------N                         ***                        ***                        *** -- comment N -----answer on comment N --------answer on answer on comment N (№1) --------answer on answer on comment N (№2) --------answer on answer on comment N (№3) ----------answer on answer №3 on answer on comment N  AND IE.   I get first comment:  SELECT * FROM COMMENTS WHERE NewsIdn='1122121' // value NewsIdn as example   But How output comments on comments in cycle ?  Tell me please how make it?

Assume you have a flat table that stores an ordered tree hierarchy:  Id   Name         ParentId   Order  1   'Node 1'            0      10  2   'Node 1.1'          1      10  3   'Node 2'            0      20  4   'Node 1.1.1'        2      10  5   'Node 2.1'          3      10  6   'Node 1.2'          1      20   Here's a diagram, where we have [id] Name.  Root node 0 is fictional.                          [0] ROOT                           /    \                [1] Node 1          [3] Node 2               /       \                   \     [2] Node 1.1     [6] Node 1.2      [5] Node 2.1           /            [4] Node 1.1.1   What minimalistic approach would you use to output that to HTML (or text, for that matter) as a correctly ordered, correctly indented tree?   Assume further you only have basic data structures (arrays and hashmaps), no fancy objects with parent/children references, no ORM, no framework, just your two hands. The table is represented as a result set, which can be accessed randomly.   Pseudo code or plain English is okay, this is purely a conceptional question.  Bonus question: Is there a fundamentally better way to store a tree structure like this in a RDBMS?    EDITS AND ADDITIONS  To answer one commenter's ('s) question: A root node is not necessary, because it is never going to be displayed anyway. ParentId = 0 is the convention to express "these are top level". The Order column defines how nodes with the same parent are going to be sorted.  The "result set" I spoke of can be pictured as an array of hashmaps (to stay in that terminology). For my example was meant to be already there. Some answers go the extra mile and construct it first, but thats okay.  The tree can be arbitrarily deep. Each node can have N children. I did not exactly have a "millions of entries" tree in mind, though.  Don't mistake my choice of node naming ('Node 1.1.1') for something to rely on. The nodes could equally well be called 'Frank' or 'Bob', no naming structure is implied, this was merely to make it readable.  I have posted my own solution so you guys can pull it to pieces.


Is there a way I could enable live playback from microphone? It could use at karaoke or as a guitar amplifier.

I have a USB microphone that I can chat on Skype, record sound etc. But how can I make it so that when my mic is on and I speak, Ι hear it in speakers live without having to record my voice first and then play it back? What apps do I need or where can I enable this option?  I'm running Ubuntu 10.10


Let $A$ and $B$ be two nilpotent $n\times n$ matrices that commute (so $AB=BA$), how do I show that $AB$ is nilpotent as well?  I have frankly no idea how to start this proof, so excuse me for not showing what I have done so far.

A square matrix $A$ is called nilpotent is $A^k=0$ for some positive integer $k$.  Let $A$ and $B$ be square matrices of the same size such that $AB = BA$ and $A$ is nilpotent. Show that $AB$ is nilpotent.   Following that is $AB$ not equal to $BA$ in part (b), must $AB$ be nilpotent?  I don't get how to prove this. Since $A$ can represent any matrix. I have no idea how to show it.


I really enjoy spending time attempting to help others on Stack Overflow. However, I have seen the same list of questions in my Unanswered > My Tags view for several months. I have reviewed those questions and I can't provide any input. It would be nice to be able to "dismiss" those and allow others to filter into view.

The /unanswered/tagged?tab=mytags page gives a list of questions from my favorite tags that are currently considered "unanswered" - they have no up voted or accepted answers. I think it's good to put them in front of me easily, but even though they have one or more tags that I'm interested in, I may not have the knowledge, ability, or interest to write an answer to them. However, they will remain on this page until someone writes an answer.  I would like to be able to dismiss questions from views, like this one, that show me interesting questions. I may choose to share them on my social media to get them views and answers, but I don't want to continually see them. Instead, I want to be able to use views like unanswered/tagged?tab=mytags as a queue of things that could use my attention.


When commenting on a comment below a question, I can use the @, and the first letter of the person I want reply to, and get a little pop-up with their display name in it. If I use that, the person will get notified of my comment.  You can't just type @ and then the display name of the person, because things like spaces, and who knows what else, should be left out. So the pop-up is quite essential.  I like this feature, and it works great, except in the following situation:  If someone marks a question as a duplicate you cannot reply to them in this way, because their display name will not appear in the little pop-up when you type @ and their first letter.  So that is the feature I would like to see added.   It's a small thing, but I don't understand why I can reply to another comment, but not to someone who marks a question as a duplicate. That person clearly has an opinion about the question.   I do see that I could vote to reopen the question. I doubt that's used very often.

@username auto-completion for comments was , and is already active on MSO.  However, it only seems to auto-complete the usernames of people who have commented on the post. According to , the list of users who can be explicitly notified also includes:   Anyone who edited the post Anyone who started a bounty on the question The ♦ moderator or  who cast a binding close vote on the question   Why not auto-complete those, as well?


Given $Z=X+Y$ where X and Y are two random variables, under what conditions does $H(Z)=H(X)+H(Y)$?  Notice $Z$ is a function of $(X,Y)$, therefore $H(Z)\leq H(X,Y)$, and $H(X,Y)\leq H(X)+H(Y)-I(X;Y)$. Therefore when $Z$ and $(X,Y)$ is a one-to-one function and $X$ is independent of $Y$.  My question is, how to find an example that satisfy this problem ? I have a simple example that let $X=0$ so that $Z=Y$, which satisfy the conditions.  However, can anyone gives a more non-trivial example ? Thanks.

Having $X$ and $Y$ discrete random variables above finite set. Z is defined as $Z=X+Y$ when does the following happen:  $$H(Z)=H(X)+H(Y)$$


was set free by Jaime. He could have just held the Riverlands.  Yet he chose to go back in his cage and betray his own men to ensure that his child could live.  That's kind of idiotic isn't it?  His son, whom he never saw, is  Walder Frey's grandson. He shouldn't fear that they will murder his son. Yet he takes a much greater risk and forgoes his freedom just so Jaime doesn't murder his son.  If I were him, I'd just enjoy my freedom and father more sons on other women than Roslin Frey.

Spoilers for Game of Thrones S06E08     Edmure Tully accepted to kill his uncle (he knew this would happen) and to give Riverrun back to the Freys/Lannisters.    I understood that he was afraid Jaime would kill his son & wife, but why did he care about them this much? I'm not a heartless fellow, but given this context:     He said he never met this child and never saw his wife again after the wedding night;   He was a prisoner of the Freys since the Red Wedding, so he was probably very mad with them;   The existence of said son could easily be a lie;   His marriage was arranged, it was purely political, he did not love his wife. In fact, as I remember, he just met her right before the wedding (on the same day, or just a few days prior);   Why would he choose the      lives of his son and wife over his uncle's and his family sovereignty?


I have managed to get my fields to calculate properly but now I am trying to add some validation to them which is proving difficult. What I aim to do is make sure that the fields have to contain numbers only and have to be filled in.  function audience_details() if(fields.length === 0) {      var aud1, aud2, total;      var aud1 = parseInt(document.getElementById("audience_1_field").value);      var aud2 = parseInt(document.getElementById("audience_2_field").value);      var reach = parseInt(document.getElementById("reach_field").value);      var total = (aud1 + aud2 - reach ) / aud1 * 100 ;      total_field.value =  parseFloat(total).toFixed(2) + '%';      estimate.value =  parseFloat(total).toFixed(2) + '%'; } else {      //alert fields must be complete / contain numbers only! }   any help would be lovely here is the form

What's the cleanest, most effective way to validate decimal numbers in JavaScript?  Bonus points for:   Clarity. Solution should be clean and simple. Cross-platform.   Test cases:  01. IsNumeric('-1')      => true 02. IsNumeric('-1.5')    => true 03. IsNumeric('0')       => true 04. IsNumeric('0.42')    => true 05. IsNumeric('.42')     => true 06. IsNumeric('99,999')  => false 07. IsNumeric('0x89f')   => false 08. IsNumeric('#abcdef') => false 09. IsNumeric('1.2.3')   => false 10. IsNumeric('')        => false 11. IsNumeric('blah')    => false


I have this javascript code:  <script> var burl = location.search; </script>   It fetches variables after ? from my page url  which is = hash=37393 and it creates a button with this javascript code:   <script>       document.write('<input type="button" name="hash" value="' + burl + '" id="buttonjs" style="font-weight: normal; font-family:Verdana,sans-serif; font-sizes:15px;line-height:1.5; padding: 10px; margin: 10px; text-align: center; background: green; border: 1px solid #c0c0c0; color: white; font-weight: bold; border: 3px; width: 100%; box-shadow: 3px 3px 3px black; border-radius: 16px;"/>');       </script>   Is there any way i can make the code fetch only the hash variable from page url which is 37393 ?

I have some jQuery/JavaScript code that I want to run only when there is a hash (#) anchor link in a URL. How can you check for this character using JavaScript? I need a simple catch-all test that would detect URLs like these:   example.com/page.html#anchor example.com/page.html#anotheranchor   Basically something along the lines of:  if (thereIsAHashInTheUrl) {             do this; } else {     do this; }   If anyone could point me in the right direction, that would be much appreciated.


I am trying to make objects fall onto a plane and actually pile up like normal objects would.  Instead of that, the objects fall, bounce around a few times, and end up merging with each other until they're all totally flat on the plane:    I've tried many different settings in Physics for both the plane and the cube, I've even tried to play with Molecular add-on but I couldn't find what settings relate to "Particle Self-Collision" in Blender and/or Molecular.  End goal:  Being able to create a pile of objects that looks realistic (as if objects were dumped on the ground from a container) as such (bills only, not the coins):    Note: There are some similar threads around but the website "blenderartists" seems to be down as I write this.

I want to create a scene that has a lot of irregularly shaped objects piled up on the ground.  I don't want the objects to intersect with eachother.  I started off by creating a particle system that uses an object group containing these objects.  No matter what settings I 'messed with' I could not get the individual objects to behave the way I want them to - They would interact with the ground like perfect spheres, and they would pass through the other particle objects.  Is there a way to make particles have rigid body physics so they behave with each other and with the ground like real objects?  Or failing that - is there a way to copy rigid body attributes to many objects? (i.e. plan be - don't use a particle system, but rather make lots and lots of copies of the objects and just let them fall)  Edit:  I ended up applying the settings 26 times (there are 26 unique objects) and then copying those 26 objects several times. To produce this    but this was before there were any replies to this question. Thanks to WChargin's answer I will be able to copy the attibutes in one action next time I do something like this :)


Within a method, I have the following code:  s = s + (items[i] + ":" + numItems[i]+" @ "+prices[i]+" cents each.\n");   Which outputs:  Candy:      5 @ 50 cents each. Soda:     3 @ 10 cents each.   and so on . . .   Within this line, how do I get the 5, 3, etc . . to line up with each other so that it is:  Candy:      5 @ 50 cents each. Soda:       3 @ 10 cents each.   This is part of a toString() method, so I can't do it with a System.out.printf

Is there some easy way to pad Strings in Java?  Seems like something that should be in some StringUtil-like API, but I can't find anything that does this.


As there are different kinds of shells, What is the difference between bash and shell scripts and is there any compatible script on can write that runs on al unix shells

What are the fundamental differences between the mainstream *NIX shells and what scenarios might prompt you to use one over the other?  I understand that some of it probably comes down to user preference but I've only ever used Bash and I'm interested to hear where another shell might be useful. Also, is there an impact on user-written shell scripts when running under one shell or another or is it simply a matter of changing the shell at the top of the file?  My instinct says it's not that easy.


Let X1, · · · , Xn be independent N(0, 1) and Let $u_4 = E[X^{4}_1]$ Im having problems in how to calculate the expected value. I know that $\sum X^{2}_1$ of a normal(0,1) becomes a chi squared with E(X) = 1. How can i calculate $u_4$?

Given a random variable $X\sim\mathcal N(0,\sigma^2)$, how can we prove that $E[X^4]=3\sigma^4$? I am having trouble even starting with the proof.


Let $f: \mathbb{R} \to \mathbb{C}$ be a trigonometric polynomial with degree $N > 0$ and $g \in L^1(\mathbb{T})$. I'd like to show that $$\lim_{n \to \infty}\frac{1}{2\pi}\int_{-\pi}^{\pi}f(t)g(nt)\ dt = \hat{f}(0)\hat{g}(0).$$ I have learned that, $$f(x) = \sum_{m = -N}^N\hat{f}(m)e^{imx}$$ and if $g_n(t):= g(nt)$, then \begin{equation}\hat{g}_n(m) = \begin{cases} \hat{g}(m/n),\ \ \ \text{if $n$ divides $m$}\\ 0, \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \text{otherwise}. \end{cases}\end{equation} So, we have then \begin{align*} \frac{1}{2\pi}\int_{-\pi}^{\pi}f(t)g(nt)\ dt = \frac{1}{2\pi}\sum_{m = -N}^N\hat{f}(m)\int_{-\pi}^{\pi}g(nt)e^{imt}\ dt. \end{align*} I thought I should be able to use $\hat{g}_n(m)$ but I don't have $e^{-imt}$. Is there a trick that I haven't use? Putting $e^{-imt}e^{imt}$ inside the integral doesn't seem to help as well.

Let $f,g\in PC(2\pi)$ continuous. Show that $$\lim_{n\to \infty}\int_{-\pi}^{\pi}f(x)g(nx)\,dx=\frac{1}{2\pi}\int_{-\pi}^{\pi}f(x)\,dx\int_{-\pi}^{\pi}g(x)\,dx$$ Where if $f\in PC(2\pi)$ then $\int_{-\pi}^{\pi}f(x)\,dx=\int_c^{c+2\pi}f(x)\,dx \quad\forall c\in\mathbb{R}.$ I've been struggling with this proof. Any suggestions would be great!


How to access the member of OneClass which is in default package into OtherClass of another package   Project Hierarchy | |--->default |      |------> OneClass |                   |-------> public int a=1; |                              |--->another                            |----->OtherClass                                         Now want to access variable a of class OneClass to OtherClass of package another.

I'm working now together with others in a grails project. I have to write some Java-classes. But I need access to an searchable object created with groovy. It seems, that this object has to be placed in the default-package.   My question is: Is there a way to access this object in the default-package from a Java-class in a named package?


I have created a survey using Google Forms many of which are multiple choice with an "other" option at the end and a small box for users to enter their own response.  In the results spreadsheet it only counts the number of users who have selected the other option but does not record the actual text they have entered.  Is this a bug or am I doing something wrong?

I have a Google Form with a checkbox question and I can see from the responses summary that two respondents have ticked 'Other'.   But, I can't see what they have typed, even in the responses spreadsheet.  Where can I see what they have entered?


I am trying to solve the following problem. Let $f$ be an analytic function defined on $\mathbb{D}=\{z:|z| <1 \}$ such that range of $f$ is contained in $\mathbb{C}$ \ $(-\infty,0]$.Then there exist an analytic function $g$ such that $Re g(z) \ge 0$ and $g$ is a square root of $f$ on $\mathbb{D}$ and there exist an analytic function $g$ such that $Re g(z) \le0$ and $g$ is a square root of $f$ on $\mathbb{D}$.  Clearly fuction $Log(f(z))$ and function $f(z)^{1/n} $are well defined according to given co-domain of $f$ . But these functions are not required function according to me. Then how to find required function $g$. Since $f$ is non zero so $f^{'}/f$ is also analytic and there is a function $g$ such that $g=Log(f(z))$. Now i am stuck please some one help.

I came across the following problem that says:  Let $f$ be an analytic function defined on $\mathbb{D}=\{z\in\mathbb{C}:|z|<1\}$ such that the range of $f$ is contained in the set $\mathbb{C}\setminus (-\infty,0]$. Then  $f$ is necessarily a constant function. there exists an analytic function $g$ on $\mathbb{D}$ such that $g(x)$ is a square root of $f(z)$ for each $z\in\mathbb{D}$. there exists an analytic function $g$ on $\mathbb{D}$ such that $\operatorname{Re}g(z)\geq 0$ and $g(z)$ is a square root of $f(z)$ for each $z\in\mathbb{D}$. there exists an analytic function $g$ on $\mathbb{D}$ such that $\operatorname{Re}g(z)\leq 0$ and $g(z)$ is a square root of $f(z)$ for each $z\in\mathbb{D}$.   I have to determine which options are correct. Can someone help in the right direction? Thanks in advance for your time.


I'm getting this error  New software can't be installed, because there is a problem  with the software currently installed. Do you want to  repair this problem now?   And other than this error message popup has only two button. "cancel and "Repair"  And when I click repair, same pop up comes back.  My Ubuntu version is 14.04 LTS  jitendra@jitendra-Dell-System-XPS-L502X:~$ sudo apt-get install -f Reading package lists... Done Building dependency tree        Reading state information... Done Correcting dependencies... Done The following packages were automatically installed and are no longer required:   cli-common libmono-corlib4.5-cil libmono-i18n-west4.0-cil   libmono-i18n4.0-cil libmono-security4.0-cil   libmono-system-configuration4.0-cil libmono-system-security4.0-cil   libmono-system-xml4.0-cil libmono-system4.0-cil libthunarx-2-0   libtumbler-1-0 mono-4.0-gac mono-gac mono-runtime mono-runtime-common   mono-runtime-sgen thunar-data tumbler tumbler-common xfdesktop4-data Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 230 not upgraded. 1 not fully installed or removed. Need to get 0 B/110 kB of archives. After this operation, 0 B of additional disk space will be used. dpkg: error processing package libmono-security4.0-cil (--configure):  package libmono-security4.0-cil is not ready for configuration  cannot configure (current status `half-installed') E: Sub-process /usr/bin/dpkg returned an error code (1)     jitendra@jitendra-Dell-System-XPS-L502X:~$ sudo apt-get -f install Reading package lists... Done Building dependency tree        Reading state information... Done Correcting dependencies... Done The following packages were automatically installed and are no longer required:   cli-common libmono-corlib4.5-cil libmono-i18n-west4.0-cil   libmono-i18n4.0-cil libmono-security4.0-cil   libmono-system-configuration4.0-cil libmono-system-security4.0-cil   libmono-system-xml4.0-cil libmono-system4.0-cil libthunarx-2-0   libtumbler-1-0 mono-4.0-gac mono-gac mono-runtime mono-runtime-common   mono-runtime-sgen thunar-data tumbler tumbler-common xfdesktop4-data Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 230 not upgraded. 1 not fully installed or removed. Need to get 110 kB of archives. After this operation, 0 B of additional disk space will be used. Get:1 http://ubuntu.uhost.hk/ trusty/main libmono-security4.0-cil all 3.2.8+dfsg-4ubuntu1 [110 kB] Fetched 110 kB in 1s (86.9 kB/s)                 dpkg: error processing package libmono-security4.0-cil (--configure):  package libmono-security4.0-cil is not ready for configuration  cannot configure (current status `half-installed') E: Sub-process /usr/bin/dpkg returned an error code (1)

I keep getting this warning whenever I try to run sudo apt-get update.  W: Duplicate sources.list entry http://archive.ubuntu.com/ubuntu/ precise-updates/main i386 Packages (/var/lib/apt/lists/archive.ubuntu.com_ubuntu_dists_precise-updates_main_binary-i386_Packages) W: You may want to run apt-get update to correct these problems   Below is the output from /etc/apt/sources.list file:  deb http://archive.ubuntu.com/ubuntu precise main restricted deb-src http://archive.ubuntu.com/ubuntu precise main restricted  deb http://archive.ubuntu.com/ubuntu precise-updates main restricted deb-src http://archive.ubuntu.com/ubuntu precise-updates main restricted  deb http://archive.ubuntu.com/ubuntu precise universe deb-src http://archive.ubuntu.com/ubuntu precise universe deb http://archive.ubuntu.com/ubuntu precise-updates universe deb-src http://archive.ubuntu.com/ubuntu precise-updates universe  deb http://archive.ubuntu.com/ubuntu precise multiverse deb-src http://archive.ubuntu.com/ubuntu precise multiverse deb http://archive.ubuntu.com/ubuntu precise-updates multiverse deb-src http://archive.ubuntu.com/ubuntu precise-updates multiverse  deb http://archive.ubuntu.com/ubuntu precise-security main restricted deb-src http://archive.ubuntu.com/ubuntu precise-security main restricted deb http://archive.ubuntu.com/ubuntu precise-security universe deb-src http://archive.ubuntu.com/ubuntu precise-security universe deb http://archive.ubuntu.com/ubuntu precise-security multiverse deb-src http://archive.ubuntu.com/ubuntu precise-security multiverse   How do I fix it?


I have an older Toshiba laptop (about 6 years old) formatted for SUSE 11.2 and Windows XP for dual boot.  I want to reformat the hard drive and to install Ubuntu 12.04.3 LTS as the sole operating system.  I have an open USB port.  I can also use a USB flash drive to load the Ubuntu installation files to either current hard disk partition.  I can also use a portable hard disk as the source for installation files.  Finally, I could make a DVD which I think the laptop could read.  (It will certainly read CDs, but I'm not totally sure about DVDs.)  What should I do?

I would like to see a full how-to guide on how to install Ubuntu.


Consider a triangular face of three vertices A(0,2,-1), B(1,0,1) and the origin O, and the normal vectors at the vertices are nA=(0,1,0), nB=(1,0,0) and nO=(0,0,1), respectively. The incident light is white and directional in direction of L=(1,2,2) and the intensity is 1, the background ambient light intensity is 0.1, and the diffuse reflection coefficients for (red, green, blue) are (0.6,0.7,0.8). No specular light contribution needs to be considered.  Find the (red, green, blue) intensity values at the centre of the face using Gouraud shading.  I do not know how to answer this question and have looked at my lecture slides, youtube videos, computer graphics textbook by Foley and Van Damm and obviously used google. Any help would be much appreciated.   Edit: I want to find the intensity values using Gouraud shading, not flat shading. From my understanding, the intensity at a point is interpolated along polygon edges and scan lines? But with the information I am given in the question, I don't have a clue how to answer this question. This video helped a bit:  but it doesn't set me up for answering this question.

Consider a triangular face of three vertices A(0,2,1), B(3,0,1) and the origin, and the normal vectors at the vertices are nA=(0,0,1), nB=(1,1,0) and nO=(-1,-1,1), respectively. The incident light is white and directional in the direction of L=(0,3,4) and the intensity is 1, the background ambient light intensity is 0.1, and the diffuse reflection coefficients for (red, green, blue) are (0.6,0.7,0.8). No specular light contribution need be considered.   How do I find the (red, green, blue) intensity values at the centre of the face using flat shading?  Flat Shading:  I = Ia x Ka + Fatt x Il x (Kd x (N x L))  Final intensity = ambient reflection x ambient reflection coefficient + (attenuation x incident light intensity x (diffusive reflection coefficient x (surface normal x Light intensity))  My lecturer told me that because ambient reflection coefficient and attenuation are not given, I can forget about it. Also specular light contribution need not be considered.  The surface normal is:   A = (0, 2, 1) B = (3, 0, 1) O = (0, 0, 0)  U = A - O = (0, 2, 1) V = B - O = (3, 0, 1)  Surface normal = U x V (cross-product) = (2, 3, -6)  I = 0.1 + (1, 1, 1) x ((0.6, 0.7, 0.8) x ((2, 3, -6) x (0, 3, 4)))  I = 0.1 + (1, 1, 1) x ((0.6, 0.7, 0.8) x (0, 9, -2.4))  I = 0.1 + (1, 1, 1) x (0, 6.3, -1.92)  I = (0.1, 6.4, -1.82) = RGB intensity values  Is this correct?


I would like a figure (including a Tikz picture) to appear inside a theorem-like environment (the point is that I need a caption for the figure).  Even using the option [H] with the float package the figure does not behave so.  Is there an easy way of accomplishing this?  Thanks

The LaTeX Wikibook :     Please understand: you do not have to use floating tables. It only   looks more professional. If you want to place your tables where they   lie in your source code, do not use table at all! This is a very   common misunderstanding among newcomers.   LaTeX works with an intricate , but I often prefer immediate placement with the H placement specifier (enabled by the float package).  My understanding is that captions and table/figure numbering require the table/figure environments. Is this really so, or are there ways around that? What other reasons are there for using table/figure if we know that we don't want a particular object to float?


Let A be an n × n matrix whose entries are 0,1,−1 and each row and column has exactly one 1 and one −1. Decide if it is possible, by successively switching the place of rows or columns, to reach to the matrix −A.  i don't which method i can chose to use, please give a hint or answer.

Place $8$ pairwise non-attacking white rooks and black rooks on a $8\times8$ chess board. If one can swap rows and columns, is it possible for the black rooks to take the initial position of the white rooks and vice versa?  My attempt:  Let the rows be $a_1,a_2,...,a_8$ and columns $b_1,b_2,...,b_8$. If there are white rooks at ($a_i$,$b_j$) and ($a_j$,$b_a$) as well as black rooks at ($a_i$,$b_i$) and ($a_j$,$b_j$), then we can reduce it to a $2\times2$ and a $6\times6$.   I don't know what to do next. Any help appreciated.


On Starbound, when ever you beam down to a planet, it drops you in the same spot each time. Is there a way to edit where it drops you (no mods preferably)?   I am exploring planets to find a good place to live, and it would be nice to be able to pick a place to build, instead of having to build relativly close to the spawn/teleport of the planet.

Is it possible to change the location you beam to on a planet? I've been to a couple of planets that have no usable resources near the spawn point and everything is a good distance East or West. It would be nice to be able to always beam down to there instead.


Im trying to make a python program, and i just can't find any information on Google on how to just execute a non-python file from python (with an if statement).  For Example:  if abc == "abc":     "Execute ThisFile.sh"   EDIT: this was marked as dupe, but I am not trying to run a single command, I want to execute the entire file.

How do you call an external command (as if I'd typed it at the Unix shell or Windows command prompt) from within a Python script?


First off there is the standard armour:  Notice the flat shoulder pads, next we have     Notice the larger shoulder pad.   Also through the movie I noticed the same larger shoulder pad coloured in both Black at one point and Red at one point.   We also have Phasmas crazy chrome armour.   What is the ranking order for these armour types? Who commands who?

In The Force Awakens, some of the stormtroopers have a colored pauldron on their right shoulder. Some of them were white. Other ones were black. And yet other ones were red.  What do the pauldron colors signify?   I guess that they indicate rank. But which ranks for which colors? Or do they indicate special job functions that have nothing to do with rank?


The RDI for calcium is 1000-1300 mg. I wonder if it was established simply by observing what normal healthy people consume daily, or has it actually been shown that consuming only, say, 500 mg is bad for you?

We are told to follow the RDI for a variety of nutrients. This is repeated over and over by teachers, guides, nutritionists, medical doctors and so on. However, when asked, no one can provide me with the actual source of how they came to this conclusion about RDI.   Who calculated this and using what scientific method exactly? Looks like a shot in the dark to me.   Where can I look at a study that proves that a human eating less than RDI will become deficient (showing clinical symptoms of deficiency of a certain vitamin or mineral)?


At wikipedia and here at math.stackexchange.com it is often said that a vector space is a set with some properties and then one goes on to refer to the set as the vector space. I am guessing that this is "just" an abuse of terminology and notation, right? Shouldn't the tuple $(X, S, +, *)$ be the vector space, where $X$ is a set, which elements we can add up using $+$ (and receive an element of $X$), and which we can multiply with elements of the set $S$ (and receive an element of $X$) using $*$? Often it is said that $X$ is the vector space, but that is strictly speaking wrong isn't it? I am asking, so that I may understand the mathematical concepts better. Bonus question: $X$ would be the underlying set of the vector space $(X, S, +, *)$, I guess. Could I say that, if $X=\mathbb R^n$, $X$ is the Euclidean spaced set or do I have to go route of writing in my publications that "$X$ is the underlying set of an Euclidean space"? Background: I submitted a paper and, even though it was ultimately accepted, one of the reviewers said that my math is not precise enough. I think (s)he might be right... especially with this topic.

I am kind of confused on the terminology of "space". From  I am getting that  In mathematics, a space is a set (sometimes called a universe) with some added structure.  And from topological and metric spaces, I know that we a space is a a tuple of a set and a structure, e.g. $(X, \tau)$, $(X, d)$, where $\tau$ and $d$ are a topology and a metric respectively. On the other hand, in machine learning the term "features space" is used a lot for sets like $\mathbb R^n$, e.g.  and although it often refers to the set underlaying set itself, not the tuple of set plus the added structure. In fact, I have done the same in a previous publication (which the peer-reviewers accepted), but I would like to be both correct and precise in what I research, write, and submit. Is it just that machine learning researchers are imprecise in their terminology? Is it just an ? I think, what some people are doing, might be they consider a space to be a set, which is somewhat structured, instead considering the set with the structure (so, the tuple), to be the space.  I am not sure how to think about this. How do I deal with this in my writing? Especially since, what happens a lot is that I need subsets and element out of the underlying sets of all kinds of spaces.  Of course it would greatly help if there was a general name for a set that is the underlying set of a space, , but it seems that there is no dedicated name for such a set. Let's say there was a features space $(X, \cdot)$, (where I am not even sure, what structure we would add). Then it would be great to have a name for the set, let's call it an asdf. So we could say the feature asdf.  Afterthoughts: What makes it worse for me is that it seems ( and ) I am not even using the word "structure", right, since it is about operations, so we are talking about an "algebraic structure", while "geometric space" is... something else...? So apparently a "vector space" is actually not a "geometric space", but an "algebraic structure". I can understand that point, but the language gets even more confusing.


Let $f :\mathbb R\to\mathbb R$ be an infinitely differentiable  function. Assume that for every $x \in \mathbb R$, there exists an  $n_x\in \mathbb N$, such that $\,f^{(n_x)}(x)=0$. Prove that  $f$ is polynomial.

Let $f\colon\mathbb{R}\to\mathbb{R}$ be an infinitely differentiable function, and suppose that for each $x\in\mathbb{R},$ $\exists\  n=n(x)\in\mathbb{N}$ such that $f^{(n)}(x)=0$. For each fixed $n\in\mathbb{N}$, consider the sets $F_n=\{x\in\mathbb{R} : f^{(n)}(x)=0\}$ and let $I=[a,b]$ a finite closed interval.  Show that $$I=\bigcup_{n=0}^\infty(I\cap F_n).$$ Show that there is a non empty open set $A\subset I$ where $f$ is a polynomial.   My attempt:  If $x\in I$ then by hypotesis there is $n$ such that $f^{(n)}(x)=0$ then $x\in F_n$ so then $\bigcup F_n\supset I$ then $$I=I\cap\bigcup_{n=0}^\infty F_n=\bigcup_{n=0}^\infty(I\cap F_n).$$  Let $$B_k=\bigcap_{n=k}^\infty F_n.$$ I want to show that $I\cap B_k$ has non-empty interior for some $k\in\mathbb{N}$. Then there is $A\subset B_k$ and by Taylor's Theorem $f$ will be a polynomial. But I didn't know how to prove this. I tried using the following bigger set: $$B=I\cap\bigcup_{k=0}^\infty B_k=I\cap\bigcup_{k=0}^\infty \bigcap_{n=k}^\infty F_n.$$ I think that it suffices to show that $B^o\neq\emptyset$ maybe using the Baire's Theorem proving that $B$ is a not meagre set.   More general Problem  Let $f$ be an infinitely differentiable function on $[0,1]$ and suppose that for each $x \in [0,1]$ there is an integer $n \in \mathbb{N}$ such that $f^{(n)}(x)=0$. Then does $f$ coincide on $[0,1]$ with some polynomial? If yes then how. I thought of using Weierstrass approximation theorem, but couldn't succeed. Answer: The proof is by contradiction. Assume $f$ is not a polynomial. Consider the following closed sets: $$ S_n = \{x: f^{(n)}(x) = 0\} $$ and $$ X = \{x: \forall (a,b)\ni x: f\restriction_{(a,b)}\text{ is not a polynomial} \}. $$ It is clear that $X$ is a non-empty closed set without isolated points. Applying Baire category theorem to the covering $\{X\cap S_n\}$ of $X$ we get that there exists an interval $(a,b)$ such that $(a,b)\cap X$ is non-empty and $$ (a,b)\cap X\subset S_n $$ for some $n$. Since every $x\in (a,b)\cap X$ is an accumulation point we also have that $x\in S_m$ for all $m\ge n$ and $x\in (a,b)\cap X$. Now consider any maximal interval $(c,e)\subset ((a,b)-X)$. Recall that $f$ is a polynomial of some degree $d$ on $(c,e)$. Therefore $f^{(d)}=\mathrm{const}\neq 0$ on $[c,e]$. Hence $d< n$. (Since either $c$ or $e$ is in $X$.) So we get that $f^{(n)}=0$ on $(a,b)$ which is in contradiction with $(a,b)\cap X$ being non-empty.


I have the following table:      \documentclass{article} \usepackage{booktabs} \begin{document}     \begin{table} \centering \begin{tabular}{ lcccccccc }  \toprule \multicolumn{5}{c}{\textbf{Training time per fold}}  \\  \toprule \textbf{Average per fold}     & 1462.20 & 1482.31 & 1487.15 & 1496.49    \\[2pt] \hline \textbf{Stddev per fold}      & 35.13   & 28.09   &  30.10  &  31.30   \\[2pt] \hline \textbf{Average per sequence} & 365.55  & 370.58  &  371.79 &  374.12   \\[2pt]  \midrule \multicolumn{5}{c}{\textbf{Time for classification per fold}} \\  \midrule \textbf{Average per fold}     & 1092.39 & 1101.13  & 1102.03 & 1080.47 \\[2pt] \hline \textbf{Stddev per fold}      &  53.17  & 43.73    & 46.43   & 45.66   \\[2pt] \hline \textbf{Average per sequence} & 273.10  & 275.28   & 275.51  & 270.12  \\[2pt]  \bottomrule \end{tabular} \end{table} \end{document}   I would like to align all numbers with respect to their decimal position, that means all dots should be aligned.

Let me begin by stating that I did google the answers (and I'll reference to them soon). Yet each of the resources I found discussed one particular method, I'm interested in a comparison of the approaches.  So far, I've found three ways to deal with this problem:   split the number into two columns (integer and fractional parts), as documented  or . The LaTeX code is simple, but the approach is a pain when it comes to copying and pasting tables from external sources. use  manually use Mike Zhang's automatic  (). I have yet to test it.   What do most people use? dcolumn? Are there other options?


I'm trying to remove the css when somewhere on the page has been clicked. I know how to implement the css changes but can't figure out how to or where to place the listener for a mouse click.  Any suggestions would be great.  $(document).ready(function() {     var friends = false; $('#friends').click(function() {     friends = true;     $('#cont').css({'left':'502px'});          $('#members').css({'left':'251px','display':'inline','opacity':'1'});     alert(friends); });  if($(document).click() && friends){     alert('here'); }; });

I have some HTML menus, which I show completely when a user clicks on the head of these menus. I would like to hide these elements when the user clicks outside the menus' area.  Is something like this possible with jQuery?  $("#menuscontainer").clickOutsideThisElement(function() {     // Hide the menus });


In the circular motion of a particle, it has two acceleration components, first, the tangential one which is responsible for increment (positive or negative) in speed and is $$ \frac{d \omega}{dt} \times r$$ and the other is centripetal acceleration and is responsible for the change in direction and is $$\omega \times \frac{dr}{dt}$$. Now imagine that you are rotating a stone with a string tied to it and then you slowly start to increase the centripetal acceleration which means that you start pulling the string with your other hand then according to the equation of circular motion kinematics, the magnitude of the velocity shouldn't be affected but now according to a new law that I studied which is the conservation of angular momentum, the object must increase its magnitude of velocity in order to conserve angular momentum and I don't get that, aren't the laws contradicting themselves and how does increase the central force even results in an increment of speed ?

A mass is attached to a rope, and put into a circular motion. If I pull the string from the center, the tangential speed of the mass will increase (by conservation of angular momentum).   I am applying a force only in the radial direction, so how can the tangential velocity increase if there is no tangential force?


The page number cant be removed, without removing both header and footer. But i want to keep header and footer and only remove page number  \documentclass[letterpaper, 10 pt, conference]{ieeeconf}    \IEEEoverridecommandlockouts                               \overrideIEEEmargins \usepackage{fancyhdr} \begin{document} \maketitle   \fancypagestyle{firstpage}{% Page style for first page    \renewcommand{\headrulewidth}{0pt} \renewcommand{\footrulewidth}{0pt}     \fancyhead[C]{2020 IEEE International Conference on Convergence to Digital World – Quo Vadis (ICCDW 2020)}% Header   \fancyfoot[L]{978-1-7281-4635-5/20/\$31.00 ©2020 IEEE}% Footer }  \thispagestyle{firstpage} \end{document}

I would like to remove page numbering on a specific page. However, the header and footer should remain intact. If I try:  \thispagestyle{empty}   The header and footer disappear. What is the recommended way of removing just the page number?


$|x-z| \leq |x-y|+|y-z|$  We know that both LHS and RHS are non negatives. So, I thought of proving this by comparing the squares of both sides but can't advance beyond that step. Any help would be appreciated.

Let $a,b,c$ real numbers. Prove the inequality $|a-b| \leq |a-c| + |c-b|$. Prove that equality holds if and only if $a \leq c \leq b$ or $b \leq c \leq a$.   I've tried starting with just $a \leq c$ and using field properties to reconstruct the inequality, however I haven't been able to make it work. I also tried making the negatives positive and stripping the inequalities and making something happen but again I don't know if that's a proper rule and it didn't seem to get me anywhere.


The Sorgenfrey topology on $\mathbb{R}$ is the topology whose basic open sets are of the form $[a,b)$ where $a < b \in \mathbb{R}$.   Does it have a countable base? (I suspect not.) Certainly it is separable and first countable.  The reals with the usual topology is second countable because open intervals with rational endpoints form a countable base. However this approach does not work for the Sorgenfrey topology, since open sets of the form $[i,b)$ where $i$ is irrational, cannot be written as the union of basic open sets $[p,q)$ with rational endpoints.

I am trying to prove that $\mathbb{R}$ with the lower limit topology is not second-countable.  To do this, I'm trying to form an uncountable union $A$ of disjoint, half-open intervals of the form $[a, b)$, $a < b$. Is this possible? I think this would imply the $A$ is open but no countable union of basis elements could coincide with $A$ therefore making the real numbers with the lower limit topology not second-countable.  I think there must exist something like $A$ described above but I am having trouble visualizing it and coming up with a formula to represent it.  Maybe there is some other way to show it is not second-countable.


I am trying to downgrade my iPhone from 14.1 to 13.3 in order to jailbreak it using checkm8, since checkm8 supports up to iOS 13.3. I have currently downloded 13.3 IPSW, but since it is not signed, I am not able to install it to my iPhone using iTunes. For that reason I though that I might be able to downgrade it by bypassing iTunes using alternative methods such as tools like tinyumbrella. But unfortunately, because of bad programming behind the tool, tinyumbrella doesn't even start. So what I wonder is that what alternative apps can I use for manually downgrading the firmware, and is it even really possible to downgrade an iPhone to an unsigned IPSW version. All help will be appreciated.

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


I have $\pi:4y−3z−4=0 \quad A=(2,4,4) \quad B=(2,−2,−4)$. I have to calculate the equation of the plane σ throw A and B and parallel (not orthogonal)  to π. What is the solution? Thanks in advice! And if I have three points, what's the solution?

I have $\pi:4y-3z-4=0 \quad A=(2,4,4) \quad B=(2,-2,-4)$. I have to calculate the equation of the plane $\sigma$ throw $A$ and $B$ and orthogonal to $\pi$. What is the solution? Thanks in advice!


I had to reformat my drive because my computer does not support 12.04 or higher. Now when I go to the update manager it is not recognising a Internet connection. I have an Internet connection and it works fine this is confusing. My computer is a satellite A10 Toshiba laptop with a 75g drive and a 32 bit processor. All I want is for this computer is for it to upgrade to 11.10 so I can run it on my tv via vga adapter. 10.10 does not support this feature without going batty on me. Any answers would be greatly appreciated.

Recently I have installed an older version of Ubuntu on my old machine. Whenever I try to install any software, I get an error saying it couldn't be found:  $ sudo apt-get install vlc Reading package lists... Done                Building dependency tree        Reading state information... Done     E: Couldn't find package vlc


I stumbled upon something strange that I never really seen before:  javascript:a=a+10;   The line above seems to be correct and evaluates happily (at least in Firefox) just like if the javascript: part never existed.  While I do understand the purpose of the old javascript:void(...) style <a href=".."/> used during the dark ages of , I just can't figure out any useful usage of this prefix in plain JavaScript code.  Does it have some special meaning?

AFAIK, you never need to specify the protocol in an onclick:  onclick="javascript:myFunction()" Bad  onclick="myFunction()" Good  Today I noticed in  on Google Anallytics that they are using it:  <a href="http://www.example.com" onClick="javascript: pageTracker._trackPageview('/outgoing/example.com');">   Is this example just plain wrong, or is there ever a reason to specify javascript: in anything other than a href?


I want to prove the following theorem      Suppose that $f$ is an entire function with $Re[f(z)]\neq 0$  $\forall z\in \mathbb{C}$. Then $f$ is constant.    What I know is . This can be easily shown by $g(z) = e^{f(z)}$ and apply Liouville's theorem.   In this case $g(z) = e^{f(z)}$ and hence $|g(z)| = e^{\operatorname{Re}[f(z)]}$.  It seems $\operatorname{Re}[f(z)]\neq 0$ $\forall z \in \mathbb{C}$ does not imply boundeness.   How to show the above theorem is correct?

Let $f : \mathbb{C} \to \{z\in\mathbb{C}:\Im(z)\neq0\} $ entire . Show that $f$ is constant.  I took $g(z)=\frac{1}{f(z)}$ and I think that g is bounded, therefore it is constant (due to Louville's theorem) but how do I prove it? Is $|g(z)|=\frac{1}{|f(z)|}=\frac{1}{u^2+v^2}\le M$ valid?


I receive the following string from one website via mechanize:  'We\x92ve'   I know that \x92 stands for ’ character. I'm trying to convert that string to Unicode:  >> unicode('We\x92ve','utf-8') UnicodeDecodeError: 'utf8' codec can't decode byte 0x92 in position 2: unexpected code byte   What am I doing wrong?  Edit: The reason I tried 'utf-8' was this:  >> response = browser.response() >> response.info()['content-type'] 'text/html; charset=utf-8'   Now I see I can't always trust content-type header.

I received some text that is encoded, but I don't know what charset was used. Is there a way to determine the encoding of a text file using Python?  deals with C#.


So I found this multi-tool thing in my drawer, recently, which has:   A magnifying glass, allowed on-board, I think. A compass, also OK. and a thermometer, not OK.   However, the thermometer is covered in plastic very tightly and the liquid is red (mercury isn't red, is it?), so would that be OK on a plane? I don't need it, I am just curious if it is allowed and if there is anything I can do...

Why do airlines prohibit carrying conventional mercury thermometers onboard? What potential this small device has to prohibit it?  PS: I prefer conventional thermometers in my personal first aid kit over electric ones because they do not need batteries and they are accurate.


I am currently learning LaTeX from 'The Not So Short Introduction To LaTeX' and in that book many examples are displayed side by side:      $a^2$  'Left side of page' ---------------------------------                        'right side of page'                                                                a^2  I would like to do the same in the paper I am writing, but can not seem to find the command to this?

When documenting a style file, it would be nice to be able to easily put side by side different examples of code, side-by-side with the output they produce.  What recommendations to people have to do this efficiently, and æsthetically?


In indirect speech if the reporting verb is in past tense, then the verb in subordinate clause will also be in past tense.  Ex- He said that he was going to see movie.  What tense will be used in subordinate clause if the reporting verb is in past continuous tense ?  Ex -1) He was saying that he was/is going to cinema.

I know the past tense carries the past tense in every dependent clause, but referring specifically to places or to things that are eternal, like the Earth, seems a bit weird and therefore we sometimes (I believe incorrectly) say     He didn't know that New Jersey was actually on the East Coast.   Because it still is. Or     He thought the Earth was round.   So is it square now?  Logically speaking, would you consider the use of past tense here a bit confusing in a day-to-day speech in these examples? Would you instinctively opt for using the present tense?


I use Thunderbird with gmail via imap and do so with multiple accounts.  On the gmail side I have filters that will automatically assign labels to incoming mail and archive it moving it out of the inbox.    On the Thunderbird side it will see the new mail appear in the corresponding folder and the all mail folder -- that's fine but my problem is that they're both marked as unread.  Since I have many accounts I use the unread mail view in Thunderbird's folder panel and what I see is both folders highlighted as unread.  When I read the message in one folder the other only get marked as read I click on it and Thunderbird does another imap transaction.    Is there a configuration that will recognize the same mail in two different folders automatically?

I'm using a gmail account in Thunderbird. When I send a message, a new mail notification appears (sound and system try icon), an unread message appears in the gmail All Mail folder, and the account name turns blue.  I have to click on "Sent Mail" or "All Mail" to get rid of the notification. Unsubscribing from "All Mail" is not effective (it still turns the account name blue).  This seems to be popping up elsewhere (), but nobody has posted a helpful answer.  How do I keep Thunderbird from thinking that a sent message is new unread mail in the All Mail folder?


If I want to test the accuracy of a predicted coefficient based on my data set $N$, then I create a bootstrap sample by sampling from by data set with replacement $N$ times, and then refit my model and calculate the estimate once again.   Why do we sample WITH replacement?

The bootstrap method has seen a great diffusion in the last years, I also use it a lot, especially because the reasoning behind is quite intuitive.  But that's one thing I don't understand. Why Efron chose to perform resample with replace instead of simply subsampling by randomly including or excluding single observations?  I think that random subsampling has one very good quality, that is represent ideally the real life situation in which the observations we have in our study are a subset of an hypothetical population. I don't see the advantage of having multiplied observations during resampling. In a real context no observation is similar to another, especially for complex multivariate situations.


I have an application which takes an argument as the path of some assembly(exe/dll). I need to recursively load all referenced assemblies. I tried to use assembly.GetReferencedAssemblies() method, but it gives only assembly names, not physical paths(Assembly.LoadFrom(path)) (by using assembly name assembly.Load() method doesn't find assembly to load).   How can I proceed this using C# ?

Is there a way to get the path for the assembly in which the current code resides?  I do not want the path of the calling assembly, just the one containing the code.   Basically my unit test needs to read some xml test files which are located relative to the  dll.  I want the path to always resolve correctly regardless of whether the testing dll is run from TestDriven.NET, the MbUnit GUI or something else.  Edit: People seem to be misunderstanding what I'm asking.  My test library is located in say      C:\projects\myapplication\daotests\bin\Debug\daotests.dll   and I would like to get this path:     C:\projects\myapplication\daotests\bin\Debug\   The three suggestions so far fail me when I run from the MbUnit Gui:   Environment.CurrentDirectory gives c:\Program Files\MbUnit System.Reflection.Assembly.GetAssembly(typeof(DaoTests)).Location gives C:\Documents and Settings\george\Local Settings\Temp\ ....\DaoTests.dll System.Reflection.Assembly.GetExecutingAssembly().Location gives the same as the previous.


According to the second law of Newton f=ma only objects with mass can experience a force. But light can be bent by gravity and is not supposed to have a mass. How come?

Light is clearly affected by gravity, just think about a black hole, but light supposedly has no mass and gravity only affects objects with mass.  On the other hand, if light does have mass then doesn't mass become infinitely larger the closer to the speed of light an object travels. So this would result in light have an infinite mass which is impossible.  Any explanations?