how to call var total to down I have tried to talk to do this but always failed. I want to call var total to be operated below but every time I call I can't can you help me?   <input class="largerCheckbox1" type="checkbox" data-exval="<?php echo $user->tertagih; ?>" <?php echo "name='id_history[]' value='1'"; ?> >    <script type="text/javascript">         $(document).ready(function(){             $("#boxes input[type='checkbox']").click(function(){                 var total= 1;                 $("#boxes input[type='checkbox']:checked").each(function calc(){                   //Update total                   **total** += parseInt($(this).data("exval"),10);                 });                  $("#test_<?=$id?>").text(total);                                        });          });   $(document).ready(function(){               $("#hhb").click(function(){                   var three = 3;                    var bilangan1 = **total**;                   var bilangan2 = three;                   var pengurangan = bilangan1 - bilangan2;                   document.getElementById("pengurangan").innerHTML = pengurangan;               });             });  </script>

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


When tethering hotspot is on, and I connect with my laptop via USB (in order to tether), I get asked each time to trust the computer which is annoying.  Latest iOS 13.2 17B84 ;  Mac OS Catalina 10.15.1 (19B88) .

(I am on macOS 10.14.6 and iOS 12.4)   I am certain that I have trusted my Mac before. Without the latter trust, I can also access the phone in iTunes.   I have tried reset "Location and Privacy" on my phone. Then   When connecting the iPhone with iTunes running, it asks for the trust and I trust it.  Reboot my Mac and the phone asks for another trust.   Is there some known malware mimics system behavior and steal data from an iPhone?  (I do have installed some pir*ted software recently. That's my fault.)


Is $f_{n}\left(x\right)=nx^{n}\left(1-x\right)$ uniformly convergent on $x\in\left[0,\:1\right]$  We can see $f_{n}\left(x\right)\rightarrow f\left(x\right)=0$ point-wise, but $f_{n}\left(x\right)\geq f_{n+1}\left(x\right)$ does not seem hold ?

I want to decide whether or not $f_n(x)=nx^n(1-x)$ is uniformly convergent or not. I have shown that $\lim_{n\to\infty} f_n(x)=0$ for $x \in [0,1]$.  Now $f_n(0)=f_n(1)=0$. And in $(0,1)$, we have $f'_n(x)=n^2x^{n-1}-n(n+1)x^n$. Putting this to zero gives $x=\frac{n}{n+1}$. Also $f_n(\frac{n}{n+1})=(\frac{n}{n+1})^{n+1}$. But that tends to $\frac{1}{e}$ as $n$ tends to $\infty$ which is not $0$ so we don't have uniform convergence, right?  Nonetheless we have $\lim_{n\to\infty} \int_0^1 f_n(x)dx=\lim_{n\to\infty} (\frac{n}{n+2}-\frac{n}{n+1})=0=\int_0^1 \lim_{n\to\infty} f_n(x)dx$.  Is all this right? I have some doubts, I mostly doubt my intuition in analysis... Thank you!


I am learning statistical network analysis and came across this symbol (highlighted in the screenshot below) that I do not know what it means.

I'm reading a  by Andrew Granville on analytic number theory.  On page 22 of the paper, there appears a strange looking symbol, undefined.  I've circled it in red in the screenshot below.    Since it's not defined in the paper, I'm assuming it must be standard notation.   From the context, I'm assuming it means something like "as compared to", or "with reference to", but that's just a guess.  Can anyone identify the symbol, even better explain what it means and/or provide a reference?  Is there a name to speak the symbol?  Thanks in advance.


How does a Stack Overflow moderator know about sock puppet accounts?   How do they trap the user?

How many users have created more than one profile on SO to vote themselves on their other original profile? There are some benefits when you have more reputation and sometimes you don't want a single -1 vote on your question or answer. In this case you may have an extra account to convert that -1 vote into 0 vote and  upvote for each of your questions and answers to gain reputation. I think it is not a good thing to do as a good developer.  Is there any way to recognize this situation? I think there should be some stats in each user's profile about how many votes are posted by each user on him/her or something like that.  So how many users have more than one profile? How to handle this situation? I have not created one yet but............ I don't think so :)


I'm writing a short story and was wondering which sentence is grammatically correct.      We lived in a cul de sac.   Or     We lived on a cul de sac.

In the United States, we say that someone lives on a street, whereas I've noticed that British people say in. For instance:     Bubba lives on Washington Street.   Colin lives in Cavendish Avenue.   I believe we both would use at when a number is given. For instance:     Bubba lives at 16 Washington Street.   Colin lives at 7 Cavendish Avenue.   I don't think it matters if it's a road, avenue, street, circle, or lane — as far as I know, in America, we always live on a street. Does it vary in British English, or is it always in? If it varies, what are the rules?


I would like to take a better picture of that fjord where water is crystal-clear.    The idea would be to include immersed stuffs in the foreground (whether ice or stones, algae...) and mountains in the background.  My main concern is about water transparency. I was not able to avoid reflections. Is it all about angle of incidence on the surface when taking a picture, but also ambient and polarized light? What would you recommend?  I use a Canon EOS 450D camera with a 18-55 mm lens and tripod.  All tips are welcome!

I received a circular polarizing filter as a gift, but I have a hard time determining when I should be using it.   I've done river shots with some success, but other than that, it doesn't seem to do much beyond reducing the amount of light.   What am I missing?


From , I have known how to write multiple columns enumeration.  But is it possible to automatically determine column numbers according to the maximal widths of all items, rather than manually specify the column number?

Consider the following minimal example:  \documentclass{article}  \setlength{\parindent}{0mm}  \usepackage{paralist} \usepackage{tabto}  \begin{document}  \NumTabs{3} \begin{inparaenum} \item text \tab\item text \tab\item text \tab\item text \tab\item text \tab\item text    \end{inparaenum}  \end{document}   Which results in:    It does exactly what I want, but I was wondering whether it was possible to create an environment, say tabbedEnum so that we can eliminate the use of the \tab, in particular, that the first case doesn't need a tab but all others do. Something of the form:   \begin{tabbedEnum}[3] \item text \item text \item text \item text \item text \item text \end{tabbedEnum}


Can you please post the specific code for using \diamondplus and \diamonddot from MnSymbol without loading this package?   The answer to the question  gives a general procedure. To implement this procedure for a specific symbol different from the symbol used there requires understanding of  document. For those who do not understand fntguide, help asked here is essential. Also, more specific examples can help others gain better understanding of the general method.

Is there a general way to change the font of a particular symbol without switching packages?  For example, suppose I'm using Computer Modern for my entire document, but I want the "subset" operator to look as it does in mathabx.  How can I redefine it to appear in this way?


Is it still possible to remotely uninstall an android application from a web browser via the Google Play Store?  According to the question that this is a supposed duplicate of, this was possible in 2012, but it seems to no longer be there.

I have tried through the Google Play store and it does not seem possible from there, but does anyone know if it is possible to remove an application remotely?   In other words, if I do not have direct access to my phone, can I make use of some website, app or service to uninstall an app without being able to interact with the phone directly.


1)Everyone, except Jess and Susie, was present at the company meeting yesterday.  2)Everyone, except Jess and Susie, were present at the company meeting yesterday.  Which is correct?

Which is correct?     Everyone were convinced that he would go to the game.   Everyone was convinced that he would go to the game.   I think it's "was", because "everyone" is singular, but I just wanted to check.


I tried root and ratio tests but it didn't work. Also, i can't use integral tests (and other "uncommon" ones) in this homework.   (Prove that the series is convergent) $$\sum_{n=1}^{\infty}\left(\frac{n}{n+1}\right)^{n^2} = \frac{1}{2} + \left(\frac{2}{3}\right)^4 + \left(\frac{3}{4}\right)^9 + ...$$

Determine whether the series $\sum_{n=1}^{\infty}(\frac{n}{n+1})^{n^2}$ is convergent or divergent.  I've tried applying all the basic tests to no avail. I need to find out what the "trick" for this particular series is.


Recently while browsing for a camera, I noticed that some cameras have this "DoF Preview" and some have none.  Now, can someone explain to me here the importance of this feature in a DSLR?

I'm fairly new to DSLRs and I've been exploring the functions on my new Canon 60D.  There's a button to the side of the lens described as the "depth-of-field preview button".  Based on the limited description in the manual, I thought this would give me a preview of how the photo would look in terms of what's in and out of focus when I'm using Live View.    When I press it though, despite jerking as if it's processing something, I see no difference in the LCD screen.  I've played with the aperture with no discernible effect.  Am I missing something?  What should I be seeing?


Given that eclipses occur, why aren't they more regular?  If the sun and the moon are in the same plane, shouldn't the moon transect the line from the earth to the sun every month?  I guess order of magnitude, if the moon at 10^-2 radians was in a random place every day, then an eclipse once / 18 months is about right.  This is a genuine question, not a troll, this question has bothered me for years.

Since we see the  at least once in a month when the Moon gets in between of the Sun and the Earth during the evening ( and as far as I know if this happens during the day, you'll get to see a . Why don't we get to see this often or in the day?   Does it mean that in some part of world there's a solar eclipse when we are seeing a new moon? I'm looking for a diagram or interactive way to understand this if possible as I'm not a native English speaker, but I'll try my best to do so.


In the universe we see that hydrogen (bound up energy) is found in a highly concentrated ordered state in some places and it's highly dispersed in most other places. There is a natural progression that makes all of the elements heavier than hydrogen so is there a return cycle to make hydrogen again? If not, how did hydrogen (bound up energy) get into a highly concentrated ordered state as we see it today? (You could appeal to another universe and it still will not answer the question of how energy got ordered or made for that matter.)

The Big Bang theory assumes that our universe started from a very/infinitely dense and extremely/infinitely hot state. But on the other side, it is often claimed that our universe must have been started in a state with very low or even zero entropy.   Now the third law of thermodynamic states that if the entropy of a system approaches a minimum, it's temperature approaches absolut zero.  So how can it be that the beginning universe had a high temperature and a low entropy at the same time? Wouldn't such a state be in contradiction to the third law of thermodynamics?


Let: $$ (-1)^0=1 $$ I need to prove that: $$ \sum_{k=0}^n(-1)^k \binom{n}{k} = 0 $$  Thanks!

Let $n$ be a positive integer. Prove that   \begin{align} \sum_{k=0}^n \left(-1\right)^k \binom{n}{k} = 0 . \end{align}   I tried to solve it using induction, but that got me nowhere. I think the easiest way to prove it is to think of a finite set of $n$ elements, but I can't find the solution.


Just wondering if there is any difference between:    echo "running the npm patch" >&2;   and   echo "running the npm patch" &>2;   I have actually never really understand that syntax.

I'm reading an example bash shell script: #!/bin/bash  # This script makes a backup of my home directory.  cd /home  # This creates the archive tar cf /var/tmp/home_franky.tar franky > /dev/null 2>&1  # First remove the old bzip2 file.  Redirect errors because this generates some if the archive # does not exist.  Then create a new compressed file. rm /var/tmp/home_franky.tar.bz2 2> /dev/null bzip2 /var/tmp/home_franky.tar  # Copy the file to another host - we have ssh keys for making this work without intervention. scp /var/tmp/home_franky.tar.bz2 bordeaux:/opt/backup/franky > /dev/null 2>&1  # Create a timestamp in a logfile. date >> /home/franky/log/home_backup.log echo backup succeeded >> /home/franky/log/home_backup.log  I'm trying to understand the use of /dev/null 2>&1 here. At first, I thought this script uses /dev/null in order to gracefully ignore errors, without causing the script to crash (kind of like try catch exception handling in programming languages). Because I don't see how using tar to compress a directory into a tar file could possibly cause any type of errors.


After familiarizing myself with the ordinal numbers and their arithmetic, I’ve been (perhaps sloppily) using function notation to refer to certain combinations of arithmetic operations on ordinals. For example, letting $$f(x)=x^2+\omega x$$ Gives values like $$f(\omega + 1) = \omega^2 + \omega$$ However, I recently realized that it might be mathematically incorrect to define a function on all ordinals. Because if asked to state the domain and codomain of this function, I would have to say “the set of all ordinals”... which isn’t a set, it’s a class. And as far as I know, functions can’t be defined on classes, only sets. Question: Is it wrong to define functions that accept any ordinal as an argument? (By “wrong”, I mean - does it lead to contradiction or paradox?)

In ZFC there seem to be two ways to define a function, as an ordered triple of domain, codomain and the set of ordered pairs that make its graph, or a relation over the two sets.   Whichever we use doesn't matter, but this seems to present a certain problem. Both are defined over sets, but no-one seems to have any problem defining functions on the ordinals like Hartog's function giving the minimum ordinal that doesn't have an injective function on to the given ordinal. I know we want to be able to obviously, but how are we supposed to justify this, because the definitions of functions don't seem to include classes. Or is there a nicer definition I've missed?


All other ISPs (Google, AOL, Hotmail) are fantastic, hitting 98-100% in the inbox. Yahoo is very random, and lately our deliverability has dropped drastically. All IPs are senders certified by Return Path and supposedly that automatically whitelists our IPs and allows us to send as many emails as we want (from what my boss says).  Do I bother with applying to Yahoo's bulk sender form?   I run every email campaign through:   SpamAssassin (Excellent Scores) Test Accounts (for test deliverability) Old school HTML format    I'm running out of ideas and I'm starting to be in the hot seat and I am very fearful for my job position.   If you can offer any wise words i will be very grateful. Thank you in advance.

This is a  about how to handle email sent from your server being misclassified as spam.  For additional information you may find these similar questions helpful:                    Sometimes I want to send newsletters to my customers. The problem is, that some of the emails get caught as spam messages. Mostly by Outlook at the client (even in my own Outlook 2007).  Now I want to know what should be done to create "good" emails. I know about reverse lookup etc., but (for example), what about a unsubscribe link with an unique ID?  Does that increase a spam rating?


I have a project that I can run correctly from within Eclipse, but running the standalone jar gives me the java.lang.NoSuchMethodError for a class at runtime.   I unpacked the jar file and can see the class file in one library file in jar and I do see the method defined in the class. The exception is not about class not found, but just can't find the method in the class.   Could not find any helpful information on the internet for how to solve it.

I'm getting a NoSuchMethodError error when running my Java program.  What's wrong and how do I fix it?


I was wondering how you would calculate the S-box in AES. I found that you have to calculate the inverse of the polynomials in $GF(2^8)$. I found out that to calculate the inverse, you have to use the Extended Euclidean Algorithm. What I can't figure out is how do you apply this to a polynomial?

I know how to do multiplication over ${\rm GF}(2^8)$:  uint8_t  gmul(uint8_t  a, uint8_t  b) {     uint8_t p=0;     uint8_t carry;     int i;     for(i=0;i<8;i++)     {         if(b & 1)             p ^=a;         carry = a & 0x80;         a = a<<1;         if(carry)             a^=0x1b;         b = b>>1;     }     return p; }   So, I tried to create a ${\rm GF}(2^8)$ multiplication table using this code. I've given below the values in the 3rd row of the table, but I don't think they're correct:      0  1  2  3  4  5  6  7   8  9  A  B  C  D  E  F 0 1 2   0  2  4  6  8  A  C  E  10 12 14 16 18 1A 1C 1E  3 . . E F   I don't know what went wrong. I built the table by multiplying the values in the first row with those in the first column.  E.g. in the third row, I multiplied 2 × 0, 2 × 1, …, 2 × E, 2 × F.  How can I create a multiplication table for arithmetic in ${\rm GF}(2^8)$?    Also, how can I find the multiplicative inverse of a number in ${\rm GF}(2^8)$?  For example, how can I determine that the inverse of 95 is 8A?  I tried to do this using the multiplication table above, but when I took 9th row and the 5th column in the multiplication table I got 2D, not 8A.


"With cats and dogs the most popular companion animals around the world, it’s no surprise that they are often compared to one another in the great cats vs dogs debate." Please help me understand this part"With cats and dogs the most popular companion animals around the world" I know how the nominative absolute works with with, however, the predicate here is a noun. Is it grammtically correct?

Which is correct, and why?     some days we went on adventures — him maneuvering our scooter, me resting my chin …   or     some days we went on adventures — he maneuvering our scooter, I resting my chin …


I am using some Table! which is  wrapper list, and when i will hit some button and if the values in those fields are blank i need to show a validation message on page with help of json. i am new in salesforce. please provide me solution

I have three rows on a Visualforce page. The requirement is that when any value of this field is blank it will show the error message on the page. I have to do this with the help of JSON and by using the following javascript function but I'm stuck. I am new on salesforce and JSON  <script type="text/javascript">    var text = '{"val":['{"TValueFields"}' ] }';     obj = JSON.parse(text);              function findBlank() {             debugger;                        for (i=0; i< obj.length; i++)               {                         var js = JSON.stringify(obj);              if(document.getElementById(js).value == " ")               {                          alert("TValueFields must be select");               }                     i++        } </script>


What's the best way to add geotags to photos if I have a GPX file with my location track?  I don't have lightroom and I'm on a Mac.

I want to add GPS location to RAW photos (from my EOS7D) using location data from my iPhone 5. Aperture doesn't save the data I added unless I export the RAW files as JPEGs.  I've searched the site using "  edit EXIF" to no avail.


When trying to deploy an auto responder rule to a new scratch org, we're getting:     [email] is an invalid From email address.: Email Address   Is there a scratch org config to set an organization wide email? Surprisingly I haven't found any resources about this specific question.

We are a team with three orgs. Development, UAT and Production.  We are trying to move away from changesets and manual copying and use various deploy mechanisms or scratch orgs but we cannot deploy org wide email addresses since it is not supported in the metadata api.   The problem is that since addresses cannot be deployed, workflows referencing them cannot either. And if we dont deploy all workflows some tests will fail and the environment will be wrong.  I would appreciate any help with this issue, thanks


Well, after my successful installation of ubuntu 16.04 it hasn't been that great.  I ran terminal and did updates, etc. After that I decided to download the software center and after running it, I tried to download an app. An error popped up restricting me to download anything, or update the system the error said:   Software can't be installed or removed because the authentication service is not available. (org.freedesktop.PolicyKit.Error.Failed: ('system-bus-name', {'name':  ':1.78'}): org.debian.apt.change-repository   please help!

I have 12.10 ubuntu and when I try to remove / install programs I get notification :      Software can't be installed or removed because the authentication service is not available.    (org.freedesktop.PolicyKit.Error.Failed: ('system-bus-name', {'name':  ':1.104'}): org.debian.apt.install-or-remove-packages   When I log in as root user (instead of user account that I regulary use) i have no problems.


contains ten links to other posts on the Stack Exchange network. On Meta Stack Exchange, bare links like these are replaced by the question titles. However, on that particular post, it stopped working after the fifth link:    When you edit the post, you see in the preview that all links are rendered, even though it takes a while:     seems to imply that it's by design, since that post links to more than 5 different Stack Exchange sites. In that case, the markdown preview should exhibit the same behaviour.

This is probably easier to show than tell...   On the recent question , I see the following:    As you can see, the first five links render properly, but after that, they stop converting.  Unfortunately, this isn't obvious to the person writing the post, which I discovered when I went to edit the post to fix the "broken" links. In the edit window, it renders all of the links just fine:    I understand that this behavior is expected based on balpha's answer :        Links to questions on the same site are unlimited.   Links to other sites are limited to             a) 5 linked-to sites and     b) N questions per target site, where N is 200 on meta sites and 10 on non-metas (this is about the site that the post containing the link is posted on, not the site that is being linked to)         So if this rule is still going to stay in effect, please fix the edit view to also not automatically convert more than five linked-to sites to help people writing posts know that they need to manually title the links to the other questions.  That said, I'd prefer that (at least on MSE) this limitation be removed or raised. Even in the answer, balpha says:     The restrictions are currently as follows, but note that they do look a bit contrived, resulting from the fact that they have grown over time (from single site to cross-site, from "there are no subsites" to "facebook.SO", etc.), so it's not unlikely that we'll revisit them.   So, if it's not hurting performance, can we please increase the limit or remove it?


There are many sites where I can search for a particular flight with various date ranges and compare the prices.  But, say, I want to go from Warsaw to New York, or London, or anywhere else (the location is just an example). But I have 100% flexibility when I'll go. How can I check in which part of the year the flight prices on the given route tend to be the most attractive?  I'm aware the prices are very volatile, but if there's a general trend that the flights to London are cheapest in May, and to New York in October, it would greatly help me to start planning.

Is there a service (don't mind paying a bit) that will tell me historically which month has the lowest airfare between two travel destinations? The thing is, that I need to fly to India from Canada (return trip) to see my family every year but I am flexible with time of visit.   So it will be helpful if I could get an idea when the airfare for this route is historically low.


For an offline application in javascript, a portrait face editor, I would like to let a script crawl through a directory containing +300 images. Keep in mind that I run my html and javascript locally, is there any way for me to fix getting all the sources of the images into my javascript. The user also should be able to add images to the directory to be crawled. I cannot use php because not every user can execute php.  I got one solution which requires input from the user and is restricted to certain browsers:   Is there a simpler way to do this?

Is there local file manipulation that's been done with JavaScript? I'm looking for a solution that can be accomplished with no install footprint like requiring .  Specifically, I'd like to read the contents from a file and write those contents to another file. At this point I'm not worried about gaining permissions and am just assuming I already have full permissions to these files.


I want to replace it with a version that has better quality. I do not care about the  view count, comments or ratings.

I need to make a small correction in a video I uploaded to YouTube. Googling shows that this is not possible. However, I remember seeing it done before. I posted a comment on a video saying that a certain part of the video was missing. I got a reply back that it was fixed, and when I went to see the video again, it was changed. How was this done?


I'm trying to understand file descriptors in the context of shell redirection.  Why can't I have cat read from FD 3, which is being written to by ls's STDOUT?  { err=$(exec 2>&1 >&3; ls -ld /x /bin); exec 0<&3; out=$(cat); } 3>&1;   When try this, cat still wants to read from my keyboard.  If this can't be done, why not?    Differentiation: This question is about reading / writing to the same file descriptor, using the problem presented by  as an example.

func() {     echo 'hello'     echo 'This is an error' >&2 }  a=$(func) b=???   I'd like to redirect the stderr to b variable without creating a temporary file.   echo $b  # output should be: "This is an error"   The solution that works but with a temporary file:  touch temp.txt exec 3< temp.txt a=$(func 2> temp.txt); cat <&3 rm temp.txt   So the question is, how do I redirect the stderr of the  function func to the variable b without the need of a temporary file?


I'm trying to run a command from my java application. I get input from the user and run this line of code: Runtime.getRuntime().exec($userInput);. I've tried lots of simple commands, including "echo," "start chrome," and "rem." It seems that the only command that works is "cmd.exe," and I have no idea what that even does.  Commands such as "echo" generate this error:  java.io.IOException: Cannot run program "echo": CreateProcess error=2, The system cannot find the file specified             at java.lang.ProcessBuilder.start(Unknown Source)             at java.lang.Runtime.exec(Unknown Source)             at java.lang.Runtime.exec(Unknown Source)             at java.lang.Runtime.exec(Unknown Source)             at me.Draconwolver.Main.runCmd(Main.java:119)             at me.Draconwolver.Main.main(Main.java:34) Caused by: java.io.IOException: CreateProcess error=2, The system cannot find the file specified             at java.lang.ProcessImpl.create(Native Method)             at java.lang.ProcessImpl.<init>(Unknown Source)             at java.lang.ProcessImpl.start(Unknown Source)             ... 6 more   Feel free to ask me for more details.

In my Java application, I want to run a batch file that calls "scons -Q implicit-deps-changed build\file_load_type export\file_load_type"  It seems that I can't even get my batch file to execute. I'm out of ideas.   This is what I have in Java:  Runtime.    getRuntime().    exec("build.bat", null, new File("."));   Previously, I had a Python Sconscript file that I wanted to run but since that didn't work I decided I would call the script via a batch file but that method has not been successful as of yet.


Pentagon $ABCDE$ is inscribed in a circle. For any edge of $ABCDE$, we can draw the line perpendicular to that edge that contains the centroid of the remaining three vertices. Show that these 5 lines are concurrent.  I'm supposed to use vectors for this problem since I just finished a unit on vectors. I have no idea where to start. Can I get some starter tips?

Pentagon $ABCDE$ is inscribed in a circle. For any edge of $ABCDE$, we can draw the line perpendicular to that edge that contains the centroid of the remaining three vertices. Show that these 5 lines are concurrent.  We just finished a unit on vectors in my Pre-Calculus class but I have no idea on how to do this final problem. Any help would be greatly appreciated!


I've installed it and my pc hangs a lot and screen fluctuate lot of times.. I'm not able to login to my Windows account (I've not uninstalled it) but if I start or restart the system Ubuntu is booted.. I'm not even able to open browser and look up for solutions

I installed Windows 7, which ate Ubuntu's boot file. When starting up the computer, it now goes straight to Windows, without giving me the option of booting Ubuntu.   How can I get Ubuntu back?


The summation in question:  $$\sum_{i=1}^{10} {\frac{i}{i^4+i^2+1}}$$  I have been able to factorize $i^4+i^2+1$ as $(i^2+i+1)(i^2-i+1)$ but I doubt this will help.  What is the solution?

If $$S=\frac{1}{1+1^2+1^4}+\frac{2}{1+2^2+2^4}+\cdots+\frac{n}{1+n^2+n^4}\,$$ find the value of $14S$.  The question can be simplified to:  Find $S=\sum\limits_{k=1}^n\,t_k$ if $t_n=\dfrac{n}{1+n^2+n^4}$.  As $1+n^2+n^4$ forms a GP, $$t_n=\frac{n(n^2-1)}{n^6-1}\,.$$ But I can't figure out how to solve further. It would be great if someone could help.


Is there some way in C++11 or higher to achieve a similar behavior to:  int some_int; std::string x=variable_name<some_int>::value; //Theoretical code  std::cout << x;   Result should be:      some_int   If not, is there a compiler specific way to do it? I am targeting MSVS.

As mentioned in many of my previous questions, I'm working through K&R, and am currently into the preprocessor. One of the more interesting things — something I never knew before from any of my prior attempts to learn C — is the ## preprocessor operator. According to K&R:     The preprocessor operator ##   provides a way to concatenate actual   arguments during macro expansion. If a   parameter in the replacement text is   adjacent to a ##, the parameter is   replaced by the actual argument, the   ## and surrounding white space are   removed, and the result is re-scanned.   For example, the macro paste   concatenates its two arguments:      #define  paste(front, back)  front ## back      so paste(name, 1) creates the token   name1.   How and why would someone use this in the real world? What are practical examples of its use, and are there gotchas to consider?


I want to upgrade Ubuntu 14.04.3 LTS to Ubuntu 16.04 LTS.   First I run  sudo apt update sudo apt dist-upgrade   Then I checked Ubuntu running version:  cat /etc/lsb-release  DISTRIB_ID=Ubuntu DISTRIB_RELEASE=14.04 DISTRIB_CODENAME=trusty DISTRIB_DESCRIPTION="Ubuntu 14.04.3 LTS"   and then I started Ubuntu 16.04 installation with  sudo do-release-upgrade -d   which threw the following error:  The required dependency 'apt (>= 1.0.1ubuntu2.13)' is not installed.    I know that first I need to upgrade Ubuntu 14.04.3 LTS to Ubuntu 14.04.4 LTS and then to Ubuntu 16.04 LTS. But unable to upgrade Ubuntu 14.04.3 LTS to Ubuntu 14.04.4 LTS. I would highly appreciate if someone help me in this regard. Thanks  I tried:  sudo apt-get update sudo apt-get upgrade sudo apt-get -f install sudo apt-get -y install apt sudo do-release-upgrade   But still getting the same error. Any help will be highly appreciated. Thanks

(This question was not resolved. Due to time constraints Computer was restored to factory settings.)  I was attempting to upgrade from 14.04 to 16.04, but apt threw this error:  The required dependency 'apt (>= 1.0.1ubuntu2.13)' is not installed.   What does this mean, and how can I fix it?  When I type in the command apt-cache policy apt  Shageenth@shageenth-Inspiron-3451:~$ apt-cache policy apt apt: Installed: 1.0.1ubuntu2.11 Candidate: 1.0.1ubuntu2.11 Version table: *** 1.0.1ubuntu2.11 0 100 /var/lib/dpkg/status 1.0.1ubuntu2 0 500 http://us.archive.ubuntu.com/ubuntu/ trusty/main amd64  Packages   The error happens when I run the command:   sudo do-release-upgrade -d   and it produces the following:  Checking for a new Ubuntu release Get:1 Upgrade tool signature [198 B] Get:2 Upgrade tool [1,265 kB] Fetched 1,265 kB in 0s (0 B/s) authenticate 'xenial.tar.gz' against 'xenial.tar.gz.gpg' extracting 'xenial.tar.gz'  Reading cache  Checking package manager Reading package lists... Done Building dependency tree Reading state information... Done Building data structures... Done  Required depends is not installed  The required dependency 'apt (>= 1.0.1ubuntu2.13)' is not installed.


When clicking on flag multiple times, it shows a new animation for each time we clicked on the flagging link.   This mostly happens with a slow internet connection when we click multiple time to open it when it was already loading.  Know it wasn't a big issue and don't know whether it was reported earlier, but I can't find it on my search. So just reporting it.

When posting comment to  my connection hicked up  so pressing ENTER three times produced the following:   Shouldn't the progress image be loaded in the same placeholder?  It also produced three "Comment could not be submitted" messages (due to timeout probably) which is fine.   Decline reason can be found .  Edit: as of May 21, 2013 it appears that when editing existing comment, there are no more loading indicators at all. They are still present when posting new comment though.


I have a panel data set where one of the variables is employment status is where 1= employed and 0 = not employed. The other variables are for those who have employ=1, such as place of employment, sector, number of hours worked etc.   I would like to run a fixed-effects model where I have the variables above as independent variables. However, those who have employ=0 have missing values for the workplace, sector , number of hours etc.    Under crossectional data, I would have made a subset of employed individuals and just analysed that but I don't know how to deal with this issue in panel data.

Consider a statistical problem where you have a response variable that you want to describe conditional on an explanatory variable and a nested variable, where the nested variable only arises as a meaningful variable for particular values of the explanatory variable.  In cases where the explanatory variable does not admit a meaningful nested variable, the latter is usually coded either as NA in the data set, or if it is coded with a value, that value is merely a placeholder that does not have any meaningful interpretation.  This situation tends to arise whenever you have an explanatory variable indicating the existence of a thing, and one or more nested variables describing the characteristics of that thing.  Some examples of this kind of situation in statistical problems are the following:   The explanatory variable is an indicator of whether a survey participant is married, and the nested variable is some characteristic of the spouse (e.g., education, age, etc.); The explanatory variable is an indicator of the presence of an item in a space, and the nested variable is a measure of some characteristic of the item (e.g., size, distance, etc.); The explanatory variable is an indicator of the occurrence of an event and the nested variable is a description of some characteristic of the event (e.g., duration, magnitude, etc.).   In these kinds of situations, we often want to build a regression-type model (in the broad sense that includes GLMs, GLMMs, etc.) describing the relationship between the response variable and the other variables.  It is not obvious how to deal with the nested variable in this type of model.  Question: How do we deal with the nested variable in this type of model?    Note: This question is designed to give a generalised answer to a recurring question on  regarding nested variables in regression (see e.g., , ,  and ).  This question is designed to give a generalised context-independent example of this problem.


I'd like to review the reasoning of this question for the case $p=q$. It says     If $|G|=pq$ where $p$ and $q$ are primes that are not necessarily distinct. Prove that $G$ is abelian or $Z(G)=1$.   This question is already answered  for the case $p \ne q$. The reasoning is:  $Z(G)$ is a subgroup of $G$ and then $|Z(G)|$ is $1,p,q$ or $pq$. If $|Z(G)| = p$ then $G/Z(G)$ has order $q$ and therefore is cyclic, which means $G$ is abelian and that is a contradiction because in that case we would have $Z(G)=G$.  We conclude $G$ is abelian or $Z(G)=1$.  Now, if $p=q$  what part of the previous reasoning fails? I mean, we still could say "since $|G| = pp$ then $|Z(G)|$ is $1,p$ or $pp$. If $|Z(G)|=p$ then $G/Z(G)$ has prime order and hence is cyclic" and conclude again $G$ is abelian or $Z(G)=1$. However if $G$ has order $p^2$ ($p$ prime) then $Z(G) \ne 1$, according to a further result.   So as much as possible, without involving the class equation I'd like to know what is wrong with that proof for the case $p=q$ (actually this problem is in Dummit&Foote and it is supposed to be solved without class equation).

Question :   If $|G|=pq$ where $p$ and $q$ are primes that are not necessarily distinct.   Prove that the order of $Z (G) =1$ or $pq$.   Showing the order is $pq$ is trivial.   I unsure how to start with showing the order is $1$. Hints are appreciated.  Thanks in advance.


Point 1: When there is 1 car passing the road, the average speed is 50km/h.  Point 2: When there are 5 cars passing the road, the average speed is 45km/h.  Point 3: When there are 12 cars passing the road, the average speed is 38km/h.  How do I write all 3 systems of linear equations this in matrix form? Any help is appreciated.  50 = α + β  45 = α + 5β  38 = α + 12β

Point $1$: When there is $1$ car passing the road, the average speed is $50$ km/h.  Point $2$: When there are $5$ cars passing the road, the average speed is $45$ km/h.  Point $3$: When there are $12$ cars passing the road, the average speed is $38$ km/h.  A traffic engineering company decides to model the average speed (shown by $u$) as a linear function of the number of cars (shown by $n$). So we want to have  $u(n)=\alpha+\beta n$ .   Using Point $1$ , Point $2$ and Point $3$ information: write a system of linear equations to calculate $\alpha$ and $\beta$ using all three points; i.e. we will have three equations with two unknowns.


I bought a bag of peeled garlic cloves as a convenience(I know, shame on me) I stored the unused cloves in the fridge and the began to show purple areas on the cloves. I don't think this is anything harmful but my partner didn't like it and insisted I throw away what was left. Is this just another natural color change for garlic such as the blue/green or green colorations that can occur. Anyone have a definitive answer? I'm not trying to one-up her, just trying to be safe.

I commonly use a technique when caramelizing onions, in which I add the sliced onions to a pan with salt, oil, and water. The water softens the onions and helps cook them evenly such that by the time it all boils away, they caramelize quickly and evenly.  I decided to use this technique on garlic the other day, when making a garlic and oil sauce for pasta, and was surprised to find that the garlic turned a fairly vivid shade of purple!  What happened? Was it some reaction the garlic had to the boiling? Or could it have been a reaction with the cast iron pan I was using?


When I compile the Python code below, I get      IndentationError: unindent does not match any outer indentation level     import sys  def Factorial(n): # Return factorial     result = 1     for i in range (1,n):         result = result * i     print "factorial is ",result     return result   Why?


I have created final strings for certain commands but when I try to check if the command given by the user matches, it does not work.  These are examples of my final strings:  public static final String END = "quit"; public static final String SHOW = "print";   But if I were to use it e.g. like this:  String command = scanner.nextLine(); if (command == SHOW) {    System.out.println("Print this line."); }    It sees that they do not match even if they do. I tried printing the finalized variables:   System.out.println(END);   and it prints its value, but for some reason when I compare them to identical strings provided by the user, it does not recognize them.  I have tried to search similar examples and read about finalizing variables, but I think I am missing something important. I know that the problem is with the final variables and not elsewhere, because the program works if I compare these same strings with equal. E.g:  String command = scanner.nextLine(); if (command.equals("print") {    System.out.println("Print this line."); }   I am assuming that there is something very simple that I am doing wrong, but I could not find any answer anywhere that I would understand. I am still a beginner and all the other examples regarding similar questions include some features that I don't understand, so they don't help me to see what I am doing wrong.

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


The 't' in 'listener' is not pronounced, and these kinds of words always make me misspell them. Instead of memorizing each of them, can you give me some advice/insight/cause?  How common are these kinds of words in English?

The audio clips  do not vocalise any sound resembling a 't', and the IPA contains no 't':     BrE /ˈkrɪsn/ ;   NAmE /ˈkrɪsn/   The 't' in 'christen' and 'hasten' (mooted by  in a deleted question), was it ever pronounced?     What formal linguistic concepts or terms describe this phenomenon? I read this () and this ().


The format I want is "Nov 8 12:00". It is the format you get by using the ls -l command. It is month, day of the month, hour and minute. I tried stat -c %Y filename which gives time of last data modification, seconds since Epoch and I tried date -d @resultFromStat. It gives me unnecessary extra output like below.     Fri Feb 13 16:31:30 PST 2009   I am trying to use bash in perl.

I want to get the modification time of a file in a specific format. How can I do that ? I know about  stat -c %x find.txt   but I need this format:  yyyymmddhh24miss   I'm using ksh on Linux 2.6.18-406.el5 x86_64 if it matters.


Under Settings -> Cellular Data there is a nice break out of how much data each app has used.  I expected this to allow me to identify which specific apps were using the most cellular data so I avoid overage fees.  My carrier tells me how much data I have used, but only gives a general category of where my data is going, which is useless for this purpose.  However, I have only had the phone a couple of weeks, and it is claiming I have already used 17.4GB of data.  However, per my carrier, I have actually used only 150MB.  It is obviously counting WiFi in the cellular figures.  But why?  Am I looking at the wrong spot?  Is there a bug in iOS?  Something I am doing wrong?  Something I need to enable? Could it be counting previous months on a different phone and need a reset somehow? Shouldn't it reset every month?

In the Settings app, under Cellular > Cellular Data Usage, I see a “Current Period” value of 6.8 GB. However, I’ve checked this number several times over the years, at all different points in my cellular billing cycle, and it always hovers around 6 GB. Is this really the amount of data that I’ve transferred using my data plan since my last bill? If not, what does the number mean?


I'm using a Lenovo IdeaTab S6000. As I was watching videos, suddenly my tablet turned off. The buttons did not work and I was unable to restore it or turned it on. On the display, there were exposed these Chinese characters as they were changing with the abbreviations WIFI, GPS and MMC.    What is this screen? Is this a virus? How to fix this?

Context  I just Skyped with my mother (far away) because her Android tablet (Lenovo IdeaTab S6000, running on Android 4.2) showed a strange menu with Chinese characters, almost like a bootloader. My short troubleshoot history looks like this:   When pressing the volume-keys, the displayed content changed, at one point the text contained "GPS", so I assumed it would be some kind of "hidden troubleshoot menu" for showing system information. A restart was possible after pressing and holding the standby-button, after restarting everything seemed untouched. Just to make sure, we changed her passwords. She did not visit any suspicious websites, nor did she install any apps recently.   With my little knowledge, so far I do not feel able to rule out an attack or a trojan app, from what I can see she could have activated the strange menu by accident. Via internet research I only found one individual with the same problem, but no solution at all.  Question(s)  What can I do to determine the cause? Should I contact the provider/manufacturer? Is it safe to assume that her data & accounts are not compromised?  I know it is little information, so please bare with me, I just want to prevent damage.  Thanks for any advice.  TL;DR  Lenovo IdeaTab showed strange chinese/asian-symbols-menu, gone after reboot, do what now?


How can I find the datatype of a variable in pyhton as auto datatypes are mentioned in python?

How do I see the type of a variable whether it is unsigned 32 bit, signed 16 bit, etc.?  How do I view it?


Each and every time that I run update, the last 4 lines read as follows:  Reading package lists... Error! E: Encountered a section with no Package: header E: Problem with MergeList /var/lib/apt/lists/extras.ubuntu.com_ubuntu_dists_trusty_main_i18n_Translation-en%5fCA E: The package lists or status file could not be parsed or opened.   What can or must I do to resolve this problem?

The computer gave me this output in a window:  E: Encountered a section with no Package: header E: Problem with MergeList /var/lib/apt/lists/archive.ubuntu.com_ubuntu_dists_natty_main_binary-i386_Packages E: The package lists or status file could not be parsed or opened.   How can I fix this?


Im using a script to delete old file in a directory, but the script kept showing  /usr/bin : Argument list too long   It turned out the number of files were 40000 and more, So I want to know what is the maximum limit of files that can be listed. Is there anyway to find it? Is it system specific?

Consider that there are countless number of files under /src/  cp /src/* /dst/   How many files cp will successfully process?


I have applied for a UK visa and the refusal letter states the reason as below.     I have refused your application for a visit visa because I am not   satisfied that you meet the requirements of paragraph V4.2 of Appendix   V: Immigration Rules for Visitors because:      You state that you wish to travel to the UK for one week as part of an   incentive trip with your company. I acknowledge that you have   submitted a letter of employment from your Employer dated 28 Feb 2016   that states that they are responsible for all the expenses of the   visit. The onus however is on you to qualify for entry clearance based   on your own circumstances and your own intentions. Whilst I am   satisfied that your employer is willing and able to cover the expenses   associated with your visit that is only one aspect of the visitor   rules and this does not satisfy me of your own intention to leave the   United Kingdom on completion of your visit.      You state that you have 1,500 GBP available for this trip. In support   of this you have submitted a bank statement in your name covering a   period from 27 July 2015 to 18 February 2016 which shows a final   balance of 4.916 OMR (8.95 GBP). I am therefore not satisfied that you   have sufficient funds to cover any additional costs whilst in the UK   without working or accessing public funds. Your application for a   visit is therefore refused under paragraph V4.2 (e).      Given the above I am not satisfied that you have accurately presented   your circumstances and therefore your intentions in applying to enter   the United Kingdom. This undermines the credibility of your   application to the extent that I am not satisfied that you are   genuinely seeking entry as a visitor or intend to leave the UK at the   end of your visit. Your application is therefore refused under   paragrah V 4.2 (a) and (c) of the Immigration Rules.      Future Applications      Any future UK visa applications you make will be considered on their   individual merits, however you are likely to be refused unless the   circumstances of your application change.      In relation to this decision there is no right of appeal or right to   administrative review.   Please find below my doubts and help me for re-applying the Visa.  1) How do I prove my intention to leave the UK on completion of visit. 2) If I Deposit the money 1,500 GBP and take a new statement will that be sufficient. 3) I had actually got a credit of 3,600 GBP via Salary & Bonus on 24Th Feb 2016. As of today I have a balance in my A/C of 400 GBP. Now If I deposit some amount equivalent to 1,500 will be that be enough. Or what as of what date should I take the statement. 4) And for the 3rd Paragraph how to prove the Credibility.

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?


I recently noticed something displaying on my html source. Here are they.  <!-- This site is optimized with the Yoast WordPress SEO plugin v2.1.1 - https://yoast.com/wordpress/plugins/seo/ --> <meta name="robots" content="noindex,follow"/> <script type='application/ld+json'>{"@context":"http:\/\/schema.org","@type":"WebSite","url":"https:\/\/kl.ncc.my\/","name":"NCC KL \/ Selangor"}</script> <!-- / Yoast WordPress SEO plugin. -->          <script type="text/javascript">             window._wpemojiSettings = {"baseUrl":"https:\/\/s.w.org\/images\/core\/emoji\/72x72\/","ext":".png","source":{"concatemoji":"https:\/\/kl.ncc.my\/wp-includes\/js\/wp-emoji-release.min.js?ver=4.2.1"}};             !function(a,b,c){function d(a){var c=b.createElement("canvas"),d=c.getContext&&c.getContext("2d");return d&&d.fillText?(d.textBaseline="top",d.font="600 32px Arial","flag"===a?(d.fillText(String.fromCharCode(55356,56812,55356,56807),0,0),c.toDataURL().length>3e3):(d.fillText(String.fromCharCode(55357,56835),0,0),0!==d.getImageData(16,16,1,1).data[0])):!1}function e(a){var c=b.createElement("script");c.src=a,c.type="text/javascript",b.getElementsByTagName("head")[0].appendChild(c)}var f;c.supports={simple:d("simple"),flag:d("flag")},c.supports.simple&&c.supports.flag||(f=c.source||{},f.concatemoji?e(f.concatemoji):f.wpemoji&&f.twemoji&&(e(f.twemoji),e(f.wpemoji)))}(window,document,window._wpemojiSettings);         </script>         <style type="text/css"> img.wp-smiley, img.emoji {     display: inline !important;     border: none !important;     box-shadow: none !important;     height: 1em !important;     width: 1em !important;     margin: 0 .07em !important;     vertical-align: -0.1em !important;     background: none !important;     padding: 0 !important; } </style>   I have checked all my plugins, i find no where to delete them. Does someone here facing same issue? I just want the robot meta tag to display. Just to delete the rest of coding above. Any solutions?

So WP 4.2 introduced emojis (smileys) that basically adds JS and other junk all over your pages. Something some people may find shocking. How does one completely erase all instances of this?


I have found this example of a closure on codeproject but it does not explain how it works.        function getMultiplier(multiplyBy){        function multiply(num){           return multiplyBy * num;        }          return multiply;     }       var multiplyByTwo = getMultiplier(2);     var multiplyByTen = getMultiplier(10);     var twoIntoFive = multiplyByTwo(5);      var tenIntoSix = multiplyByTen(6);        console.log(twoIntoFive); // 10     console.log(tenIntoSix); // 60     Now i am going to assume, with my C brain what is happening. Please correct me or give your explanation.   functions in javascript can also be objects, so the inner function multiply(num) is a method of getMultiplier, looking from outside. var multiplyByTwo is assigned the return value of function getMultiplier when invoked with argument 2. when you call getMultiplier(2), javascript interpreter creates an object in memory based on the definition of getMultiplier(). that object has a method multiply and it's address is assigned to variable multiplyByTwo. var twoIntoFive = multiplyByTwo(5); calls the getMultiplier(2) object's method multiply(num) with argument 5. that returns simple numeric 10 into variable twoIntoFive multiplyByTwo = 0; will make the garbage collector of javascript delete object getMultiplier(2) from memory.

How would you explain JavaScript closures to someone with a knowledge of the concepts they consist of (for example functions, variables and the like), but does not understand closures themselves?  I have seen  given on Wikipedia, but unfortunately it did not help.


I'm having trouble opening Minecraft.jar because there is no java runtime in open with listed. Even though I have installed it. This seems to be the solution  But I don't understand how I'm supposed to make the file hes talking about. I right clicked in  /usr/share/applications/ but it didn't give me an option to make a file.   Thanks for any help.

I'm wondering something. Whenever i right click on minecraft and click open with another application, i try to find Java JDK. I have installed it for minecraft itself, but i just cant find where java is on the list of other applications. Any help?


I don't like the 12.04 panel. Is there a simple way to make it look like 10.04 which was perfect in its design?  I installed gnome-panel and followed the instructions but nothing happened.

I'm used to GNOME Classic and personally don't want to change to anything else, but it seems there is no more GNOME Classic in the Oneiric release. After apt-get installed gnome-session and all, though there comes back the GNOME Classic option in the session listbox, however, after logged in, it seems not the expected one.  There is no System menu in the top bar, and I couldn't customize panels at all. I want to change the appearance(theme), but I can't find Appearance menu at all. And much more differences to my previous experience of GNOME classic shell.    There are multiple valid answers for this question spanning over several versions of Ubuntu. For your convenience an index of each below:    and up      &


I know the theory behind bending inward while taking a turn. It is done to make a component of friction act as centripetal force and prevent from us from getting thrown out due to centrifugal force.  The main question begins here: When we have entered the turn and also tilted the vehicle,if we want to change our direction a little bit,we need to apply pressure on the opposite side on the handle i.e turn handle left for going right and vice versa. And same applies to steering of a car. What is the concept behind this? Please, if possible, include the laws of physics acting here in the answer. This question is not a duplicate of  post because there everyone has discussed about centripetal and centrifugal forces and not about the position of handle and steering during this process. Whereas I have clearly mentioned that know the concept of tilting and the forces acting the vehicle.

Everyone knows the story about countersteering. For those who don't, I will explain it below and after the explanation I will ask my question.  You can watch this short video as a beginning:   .  This an excellent graphic demonstrating what is happening:    The key is that moving your butt moves the CG ($y$ and $x$ are the location in the image.) Basically what has to happen is for the moments created from the weight ($mg$) and the centrifugal force $\left(\frac{mv^2}{r}\right)$ to cancel out. (A moment is a force times a distance, in this case the distance to the contact patch in the direction parallel to the force - $mg\times y$ for weight, $\frac{mv^2}{r}\times x$ for centrifugal force.). You can express $x$ and $y$ with sine and cosine times the distance from the contact point to CG. Then the bike goes around the corner and sparks fly from your titanium knee sliders. You can speed up and lean over (or drop your butt) until the centrifugal force equals the maximum force that the tires/road combination can handle. This is of course assuming that you're not doing anything else like braking or accelerating which takes away from the grip available for cornering. If you want the equations to play with: $\frac{mv^2}{r}\times y = mg \times x , m = mass$, cancels out! It doesn't matter how fat your ass is for computing the speed/turn radius, just where it is and the ratio of ass fat to bike fat (it does matter for maximum speed though) -> $v =$ velocity -> $r =$ radius of turn -> $y =$ vertical distance of cg from center of rotation (contact patch) -> $g = $ acceleration due to gravity (constant $9.81$ $m/s^2$) -> $x = $ horizontal distance of CG from center of rotation The two forces are trying to rotate the bike in opposite directions which is why the are on opposite sides of the equation. so: $v = \sqrt{\frac{rgx}{2y}}$ OR $r = \frac{2yv^2}{gx}$ You can see that as $y$ drops or $x$ gets bigger (lean over more or hang off more for both, basically) either $r$ has to go down (tighter turn) or $v$ has to go up!  Now comes my question. In ALL explanations (including my own) the centripetal force in the picture (free body diagram) is pointing outwards. But this doesn't make sense, because the centripetal force should point inwards. Then you get the problem that BOTH torques try to turn you to the inside. In practice we can obviously see that this doesn't happen. So you would say that in this case the centripetal force (better: centripetal torque) is pointing outwards. How is this possible? I have always learned that the centripetal force should point to the centre of the circle. Please help !!!


Is there a pure sql solution to search in all tables for a specific field with a given value or name. In pseudocode the query im looking for would be  SELECT * FROM * WHERE field = "value"   or  SELECT tablename, field FROM *   I already know how I could use the mysql  to search for all tables with the column, but I'm unsure if (and how) I could combine this inside a query (or stored procedure).

I want to search in all fields from all tables of a MySQL database a given string, possibly using syntax as:  SELECT * FROM * WHERE * LIKE '%stuff%'   Is it possible to do something like this?


Show that for $k \in \mathbb{Z}$:  Is $\zeta_n$ a primitive $n$-th root of unity, then $\zeta_n^k$ is primitive if and only if $(k,n) = 1$.  I only need the backwards direction:  $\zeta_n^k$ is primitive $\Rightarrow$ $(k,n) = 1$

Show that the primitive n-th roots of unity have the form $e^{2ki\pi/n}$ for $k,n$ coprime for $0\leq k\leq n$.  Since all primitive n-th roots of unity are n-th roots of unity by definition they all have that form, the question is, how to show $k$ and $n$ are coprime.


Like should i say reduce the aircon or increase the aircon or any other easier way to say this?   Use case: i get into a Uber car and its chilling cold. I want the driver to increase the temperature to make it comfortable.   The confusion for me is reducing the speed of aircon increases the temperature and vice versa.

As the title says, I've heard two possible meanings for turning down the air conditioning: It could mean set the target temperature lower (i.e. colder) or make it work less (i.e. warmer).  Turning down the heat makes it colder, but both meanings are in agreement there.


I saved couple of important files from my windows computer to USB Ubuntu while Ubuntu was running. But on restarting the USB Ubuntu I am unable to locate those files. is it normal that it  is erased? or is there any way i have get it back? I created a .New folder within documents and placed the files in that folder. but once i shut down Ubuntu and opened again those files are nowhere.. please help

I am crawling some data using Apache Nutch and storing it on my USB Drive. The OS itself is Ubuntu Live Boot OS. But for every restart or shutdown I am losing my data. I also tried suspending my Ubuntu user still data was not visible when I reinserted my live USB.  Is there any way I can keep the data intact and does not loose and application settings installations when I do restart Ubuntu.  Used USB installer provided by pendrivelinux.com at


I am interested in using Roman numerals for the table numbers in a report I am creating, however have run into an issue as I am using the report document class.  MWE:  \documentclass{report} \renewcommand{\thetable}{\Roman{table}}  \begin{document}  \listoftables \newpage  \chapter{Chapter 1} \begin{table}[htb]     \centering     \caption{This table is captioned with roman numerals, and is table number 1 in chapter 1} %This is Table 1.1     \label{tbl:ch1t1} \end{table}  \chapter{Chapter 2} \begin{table}[htb]     \centering     \caption{This table is captioned with roman numerals, and is table number 1 in chapter 2} %so this is Table 2.1     \label{tbl:ch2t1} \end{table} \end{document}   Previously, my table numbering convention (by the default that LaTeX uses) was that Tables 1,2,3... in chapter 1 would have table numbers 1.1, 1.2, 1.3,...  Tables in chapter 2 would have table numbers 2.1, 2.2, 2.3,...  However, with the \renewcommand{\thetable}{\Roman{table}} line, it gives the tables in sections 1 and 2 the same table number - I (because it resets the counter in between chapters). How can I generate a continuous set of table numbers so that the second table in the MWE has a table number of II?

Some document elements (e.g., figures in the book class) are numbered per chapter (figure 1.1, 1.2, 2.1, ...). How can I achieve continuous numbering (figure 1, 2, 3, ...)?  And vice versa: Some document elements (e.g., figures in the article class) are numbered continuously. How can I achieve per-section numbering?  \documentclass{book}% for "vice versa" variant, replace `book` with `article`  \begin{document}  \chapter{foo}% for "vice versa" variant, replace `\chapter` with `\section`  \begin{figure} \centering \rule{1cm}{1cm}% placeholder for graphic \caption{A figure} \end{figure}  \end{document}   Bonus question: Is it possible to adjust the numbering of the sectioning headings themselves? Can I, e.g., switch from per-chapter to continuous numbering of sections in the book class?


I'm looking for a series of books about a war between humans and demons who traveled to floating chunks of shattered worlds via boats made of dragon skin and bones?  I remember a couple of wizards, a guy that uses a cloak as a weapon, and a scorpion demonlord fighting other demonlords for dominance.

Pretty sure this book was fantasy, rather than sci-fi. Probably late 70s early 80s. I remember:  The world is made up of separate chunks, islands floating in space, each following a specific path that is charted and regular (there are timetables written about the movement and paths of each island). A thief cases a house to steal an artifact, a crystal crescent. The crescent is resting on a cushion on a mantel, in a room where the floor is specially made so that if you step in the wrong place, the floor shrieks like a riven vampire. The thief returns at night, navigates the floor, discovers that the crescent is protected by a glow (spell), figures out that the spell doesn't affect the silk cushion the crescent is sitting on, so makes a loop out of a piece of silk from his own clothes, and leaves (something) behind on the cushion, to give the spell something to protect.  To leave the building, he goes to a pantry/closet with a window, and has to dislocate his shoulder to fit. I want to say that he can shapeshift into a bear, but I can't remember how that fits in anywhere. Further on, he meets a sorceress, who wears a ring made out of crystal on a particular finger to show her rank.  And that's what I remember. I want to say the author is female, but I can't remember the name of the author or the book, and the copy I read was missing its front cover so I have no idea of the cover art. Please help!


I have set the default terminal emulator to terminator using update-alternatives and I can open terminator now with ctrl-alt-t, but when I use the right click menu on the desktop or in a folder it will open gnome-terminal.   Is there another setting to change to fix this?   I've edited compiz to try the 3d cube effect and from then had to reset compiz to default settings to revert which reset my terminal default. To get ctrl-alt-t working after this I also had to do gsettings set org.gnome.desktop.default-applications.terminal exec 'terminator'. I found this suggestion in  , but this did not make it so the right click option open terminator.  I am using Ubuntu 15.10

The nautilus-open-terminal package adds a menu/right-click option to open a terminal in the current directory.  I want to change this from opening gnome-terminal to opening terminator. , however these instructions do not appear to be valid any more, and I can't find any place in the system settings where the default emulator can be changed.  I also tried:  $ sudo update-alternatives --config x-terminal-emulator   choosing  * 0            /usr/bin/terminator               50        auto mode   But this does not appear to have any effect. Any idea how I can get this to work?


Homework problem:     Add the following constructor to your Line class:   public Line(int x1, int y1, int x2, int y2)    Constructs the new line that contains the two given points.   My code:  Main Class:  public static void main(String[] args) {         Scanner scan = new Scanner(System.in);         System.out.println("Enter x1: ");         int x01 = scan.nextInt();         System.out.println("Enter y1: ");         int y01 = scan.nextInt();         System.out.println("Enter x2: ");         int x02 = scan.nextInt();         System.out.println("Enter y2: ");         int y02 = scan.nextInt();          Line object2 = new Line(x01, y01, x02, y02);          System.out.println(object2);   Point Class:   private int x;     private int y;     private static int count = 0;      public Point(int x, int y){         this.x = x;         this.y = y;         count++;     }      public Point(double x, int y){         this.x = (int)x;         this.y = y;         count++;     }      public Point(){         this(0,0);      }      public String toString(){         return "(" + x + ", " + y + ")";     }      public int getX(){         return x;     }      public void setX(int newX){         x = newX;     }      public int getY(){         return y;     }      public void setY(int newY){         y = newY;     }   Line Class:  class Line {     Point p1;    Point p2;       public Line(Point p1, Point p2) {      this.p1=p1;      this.p2=p2;   }         public Line(int x1, int y1, int x2, int y2) {      Point p1 = new Point(x1, y1);     Point p2 = new Point(x2, y2);      }      public Point getP1() {         return p1;     }     public Point getP2() {         return p2;     }     public String toString() {         return "Line points [ (" +p1.getX() + ", "  + p1.getY() + ") , ("+p2.getX() + ", " + p2.getY() + ")]";  }   However, I am still receiving a Null Pointer Exception :  Exception in thread "main" java.lang.NullPointerException     at assignement05.Line.toString(Line.java:30)     at java.lang.String.valueOf(String.java:2994)     at java.io.PrintStream.println(PrintStream.java:821) at assignement05.Assignement05.main(Assignement05.java:29) C:\Users\18567\AppData\Local\NetBeans\Cache\8.2\executor-snippets\run.xml:53: Java returned: 1 BUILD FAILED (total time: 4 seconds)   Instead I should receive   Line Points [ ( x1, y1 ) , (x2, y2) ]   as my output. What is the issue here?

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


let $\varepsilon >0$. show that $\forall \alpha,\beta \in \mathbb{R}$  $\alpha\beta \leq \frac{1}{2\varepsilon}\alpha^2+\frac{\varepsilon}{2}\beta^2.$  Its looks like holder inequality with $p=2$ and $q=2$.   some hints would be appreciated.

let a,b be real  numbers and $\varepsilon>0$. prove the above inequality. I dont know how to even start. please, I need your help.


Zoom in slowing down then stopping not close enough to object. I want to be able to zoom in closer and a lot of the time Blender won't let me. Also I click Alt+M with vertices selected tell it to merge at center and nothing happens.

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


/** Helper function to return the index-th node in the linked list. */ SinglyListNode* getNode(int index) {     SinglyListNode *cur = head;     for (int i = 0; i < index && cur; ++i) {         cur = cur->next;     }     return cur; } /** Helper function to return the last node in the linked list. */ SinglyListNode* getTail() {     SinglyListNode *cur = head;     while (cur && cur->next) {         cur = cur->next;     }     return cur; } /** Get the value of the index-th node in the linked list. If the index is invalid, return -1. */ int get(int index) {     SinglyListNode *cur = getNode(index);     return cur == NULL ? -1 : cur->val; }     This “ return cur == NULL ? -1 : cur->val; ”  I confused this syntax, can someone separate this sentence?

I've always wondered how to write the "A ? B : C" syntax in a C++ compatible language.  I think it works something like: (Pseudo code)  If A > B    C = A Else    C = B   Will any veteran C++ programmer please help me out?


W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/quantal/restricted/binary-i386/Packages  404  Not Found [IP: 91.189.88.149 80]  E: Some index files failed to download. They have been ignored, or old ones used instead.

PPA seems to be constantly offline. Whenever I use sudo apt-get update, this error is shown:  W: Failed to fetch http://ppa.launchpad.net/ 404  Not Found   How do I fix these errors?


IT is on my case. They say I am using too much hard drive space, and need to use less.  I start looking for the culprits which are huge and are the cause.  Problem is I have multiple nested directories, and am having a hard time finding them.  How can I do find the big files in a given directory and its sub-directories?  Ideally, I would be able to sort them from large to small.  Thanks

How can I visualize which folders and files are taking up all of the space on my hard drive?  I'm getting some conflicting reports on the size of hard drive contents. Namely what is and isn't there and what folders are actually using the space.   I need to know which of the files or folders the culprits behind all this hidden bloat. Also there should be a print option to get it on paper.


What does the black rectangle at the end of the line mean? It is overflow?     This writes overflow  \documentclass[12pt,a4paper]{report} \setlength\textwidth{145mm} \setlength\textheight{247mm} \setlength\oddsidemargin{15mm} \setlength\evensidemargin{15mm} \setlength\topmargin{0mm} \setlength\headsep{0mm} \setlength\headheight{0mm} \let\openright=\clearpage  \begin{document}  \begin{description}  \item [Epocha (ekvinokcium)] $T$ udává okamžik v čase. Je několik druhů epoch - referenční epocha (v případě světelných křivek udává, kdy je fáze 0), epocha maximální radiální rychlosti, epocha periastra, epocha primárního minima, apod. Udává se v různých časových jednotkách:   \begin{itemize} \item Juliánská data se hodí na analýzu dlouhých časových pozorování. Označují střední sluneční dny, které začínají v poledne světového času SČ, což je lokální čas na poledníku procházejícím observatoří v Greenwichi. Počátek těchto časových jednotek JD0 připadá na střední poledne v Greenwichi 1. ledna 4713 př. n. l.    \end{itemize}  \end{description}  \end{document}

Is it possible to make LaTeX mark overfull boxes in the output, for example by drawing red rectangles in the PDF where the boxes overflow? The purpose -- to more easily "see" where the problems are in the output.


When I try to add a loop cut by pressing CtrlR only a dot shows on my object instead of whole loop cut line. What am I doing wrong to cause this problem?

Alright so I've seen some postings about loop cuts and done some research. I am very new to blender and modeling overall. I am trying to loop cut this concrete barrier. Now I'm following a tutorial and kind of did my own thing in some areas. I cleaned it up following some instructions in another answer here on stack exchange.  I can't for the life of me figure out why I can loop cut around the whole bottom:   ...but not the whole middle:   I see this marked as answered by another question. That question refers to ngons and inside faces. Now once again I'm totally new to this. I looked on the inside. I don't believe I have inside faces or any ngons by the terms I've read online in my research.  Here is a wireframe picture and the inside view:     Maybe I'm missing something the answers on other posts are saying. If so and you know what it is I'd be very appreciative of what it is.


The true or false question states: "True of False: Every 3-dimensional subspace of $ \Bbb R^{2 \times 2}$ contains at least one invertible matrix."  Here the $ \Bbb R^{2 \times 2}$ represents the space of all two by two matrices. It seems like this is true, but I am not sure how to prove or disprove the statement. (If such is true, then it's easy to see that every 3-dimensional subspace of $ \Bbb R^{2 \times 2}$ contains infinitely many invertible matrices)

I am sure the answer to this is (kind of) well known. I've searched the web and the site for a proof and found nothing, and if this is a duplicate, I'm sorry.  The following question was given in a contest I took part. I had an approach but it didn't solve the problem.     Consider $V$ a linear subspace of the real vector space $\mathcal{M}_n(\Bbb{R})$ ($n\times n$ real entries matrices) such that $V$ contains only singular matrices (i.e matrices with determinant equal to $0$). What is the maximal dimension of $V$?   A quick guess would be $n^2-n$ since if we consider $W$ the set of $n\times n$ real matrices with last line equal to $0$ then this space has dimension $n^2-n$ and it is a linear space of singular matrices.  Now the only thing there is to prove is that if $V$ is a subspace of $\mathcal{M}_n(\Bbb{R})$ of dimension $k > n^2-n$ then $V$ contains a non-singular matrix. The official proof was unsatisfactory for me, because it was a combinatorial one, and seemed to have few things in common with linear algebra. I was hoping for a pure linear algebra proof.  My approach was to search for a permutation matrix in $V$, but I used some 'false theorem' in between, which I am ashamed to post here.


On a , the question came up how to merge the answers of one question into another.   A quick (search ) didn't reveal anything, so I'm asking this here.

Questions can be merged into other questions.   What is a merged question? When should questions be merged? Who can merge questions? How do I request it? What happens to merged posts? Anything else I should know about merged questions?


I have a geometry(Point,4326) column on my table:  CREATE TABLE foo ( geom geometry(Point,4326) );   I want to insert into it. Currently' I am running  INSERT INTO foo (geom) VALUES (   ST_GeomFromText('POINT(latitude longitude)', 4326)) );   To save a geometry value. I think ST_GeomFromText('POINT(latitude longitude)', 4326) is wrong method, I tried

When defining a Point in PostGIS, when do you decide to use which of the following?   ST_SetSRID(ST_MakePoint(lon,lat),4326) ST_SetSRID(ST_Point(long,lat),4326) ST_SetSRID(ST_GeomFromText('POINT(lon lat)',4326) ST_GeomFromEWKT('SRID=4326;POINT(lon lat)')   If its essentially a difference in performance, which will be the fastest?


How can I get the speed of my internet connection from the terminal? Is there any script or commandline application(s) available?  I'm using CentOS 6.5 .

I want to get the current Bandwidth of an interface say "eth0" from the terminal. It better be as simple as possible. Say          up 10 dn 30. Instead of giving out a lot of text like "vnstat" does.    Edit: I need this for a command line program for auto-monitoring, not to view it manually.


Is there a definition of $ 1 + \frac{1}{2+\frac{1}{3+\frac{1}{4+\frac{1}{\ddots}}}}$? I am somewhat familiar with continued fractions; that is, I am aware that their convergence depends on whether our input is rational or not. This is not a homework problem, I am just curious about this topic which has gotten little attention in my current studies. If this expression is defined, what is it and does it converge?

Does this continued fraction converge?  $$\cfrac { 1 }{ 1+\cfrac { 1 }{ 2+\cfrac { 1 }{ 3+\cfrac { 1 }{ 4+\ddots  }  }  }  } $$  ($[0;1,2,3,4, \dots]$)  I tried approximating a few values but I couldn't make out whether it converges or diverges. Can anyone provide a proof whether this converges or diverges. If it converges, please add what it converges to.


I'm a little confused by this whole blending in with zombies business.  This much I do know:   Michone and Andrea are able to camouflage themselves for an entire winter with Michones two walkers.   Rick is able to "hide" during his fight with Shane at the prisoner drop-off site by rolling a walker on top of him.  I believe Darryl does something similar at the congested highway to save himself and T-Dawg.     The questions:  Is the camouflage literally based on a sense of smell?  Some sort of post death sixth sense?  I can't name the specific episode, but in Season one Rick and Glenn cover themselves with zombie guts to escape, and when it starts to rain, washing off some of the guts, the surrounding zombies immediately begin to take notice.  Why?  If two chained zombies can mask two adults within about a five foot radius, shouldn't that mass of zombies have been more then enough to provide cover?  By the same reasoning, as soon as the first couple zombies got close to you, shouldn't the rest of the zombies lose interest?  Is "disarming" or killing a zombie the only way to make it functional as camouflage?

Zombies are always after human beings. How do Zombies differentiate between a zombie and a human being? Why don't zombies eat each other?


I am writing an essay on a certain type of representation theory and I would be very grateful if someone can tell me how I can make these diagrams in LaTeX. Any and all help is much appreciated!


Hi I have a quick question. I know this may be a common question. If N3L states that there's an equal and opposite force, why do things still move?  I have read up a lot and this is my understanding. If a finger exerts a force on a box, then box will move/accelerate. At the same time, box exerts an equal force on the finger. The motion of box(assuming no friction) is affected only by force from the finger. (I think the term is System = box). Thus, the reaction force from box only affects the motion of finger and has no relevance to the motion of the box.  However, I came to this question. If the reaction force from the box on the finger is equal to the force from the finger to the box, then there must be some other kind of force on the finger that is opposite to the reaction force and greater, since the finger is accelerating/moving. What is that force?

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


What's this type of illustration called?

What is the name for these type of images? I love these kind of graphics and it's so flat which totally matches my current product development.      Do we have a name for it? A name will make it easier to search for examples and how to's.


How much RAM would Ubuntu 14.04 need?  (Usage: A bit of pictureprocessing, maybe an IP-Camera Stream, ordinary officework, simplecv, some Torrentdownloading).  Is 4GB or 8GB better suited for me?

I'm thinking about installing Ubuntu Desktop, but I don't know what flavor is the best for my system. What are the minimum and recommended hardware requirements? What kind of CPU? How much memory? Should I have Hardware Acceleration? What flavor should I use?  This is an attempt of a canonical answer. My answers have the "official  requirements", the recommended are a mix of official sources and opinion based (along with the answer it's told the source). You can comment or edit if you feel that the information is obsolete or incomplete. It is a good rule of thumb that any system capable of running Windows Vista, 7, 8, x86 (Intel) OS X will almost always be a lot faster with any Ubuntu flavor even if they are lower-spec than described below.


In addition to what the employee would pay in income tax on taxable wages an employer also pays their own payroll taxes on all taxable wages like:   FICA FUTA SDI SUI ETT   Are these taxes due from the employer on 401K matches?  What about on non-taxable fringe benefits?

When my employer makes a contribution to an employee 401k account, are any taxes payed by the employee (e.g. FICA)?  And does the employer match amount show anywhere on the employee's W-2 or 1040?


I have a class IBase with only pure virtual functions.  I have another class Derived which inherits IBase.  I have a function in another class that takes a QVector of IBase as a parameter.  When I create a QVector of Derived objects, I can't pass them into this function.  However, I can have a function that takes a IBase object as an argument and pass in a Derived object instance.  Why is this behavior occurring?

Consider these classes.  class Base {    ... };  class Derived : public Base {    ... };   this function  void BaseFoo( std::vector<Base*>vec ) {     ... }   And finally my vector  std::vector<Derived*>derived;   I want to pass derived to function BaseFoo, but the compiler doesn't let me. How do I solve this, without copying the whole vector to a std::vector<Base*>?


I'm expecting isCorrect() method to return "true", because it should have all the conditions to reach that answer, but it only return "false" (many times at that according to the console). There are errors but I have no idea what they are. Please tell me what's going so wrong with this code.   public class BooleanMethodTest {         static int num1 = 1;     static int num2 = 2;     static int num3 = 3;      public static void main(String[] args) {             // it should print "true" but I get "false" instead         System.out.println(isCorrect("s1"));     }      public static boolean isCorrect(String s) {         boolean answer = false;         // step 1         if (s.equals("s1")) {             if (num1 == 1) {                 isCorrect("s2");             } else {                 System.out.println("else1");             }         }         // step 2         else if (s.equals("s2")) {             if (num2 == 2) {                 isCorrect("s3");             } else {                 System.out.println("else2");             }         }         // step 3         else if (s.equals("s3") ) {             if (num3 == 3) {                 answer = true;                 return true;             } else {                 System.out.println("else3");             }         }         System.out.println(answer);         return answer;     } }     Note on the duplicate  After exchanging all String comparisons with String#equals the problem still persists. So the linked duplicate does not solve the issue. However, the real issue was found, see the comment section.

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


Consider we have an array declared as  : reg arr [n-1:0]   This array has n elements each of 1 bit and if I need to put a zero for example in all of its elements , do I need to do a for loop from 0 till n-1 or is there is a shorthand syntax for it in Verilog ?

Suppose I declare an unpacked array of size say 8 bits wide. reg b[7:0];  If I want to assign b[7] = 1,b[6] = 1, b[5] = 1, ......b[0] = 1, then apart from assigning value to each bit is there a way to assign any combination of bits say 8'bA8, to b? For instance if I execute this code(below) in verilog: module tb();     reg [7:0]a;     reg b[7:0];     initial begin         $monitor("a = %b,b = ",a);         a = 8'hA8;         b = 8'hA8; // Line 7     end endmodule  I get this error: C:\iverilog\bin>iverilog -o a test.v test.v:7: error: Cannot assign to array b. Did you forget a word index? 1 error(s) during elaboration.  I am using Icarus Verilog on a command prompt on Windows 10 operating system.


Ok I recently installed ubuntu 14.04 on all of my computers and want to put windows 7 back on my desk top, I boot from the cd everything looks to start normal, after clicking install windows 7 it comes up with a error saying "No device drivers were found. Make sure that the installation media contains the correct drivers, and then click OK." Even though I have no problems using the CD/DVD drive in ubuntu why is it coming up with this error during my windows 7 install?

I have Ubuntu on my laptop. Now I want install Windows 7 in a dual-boot. How can I do this? I can't lose my Ubuntu files, and I'm afraid that I might break . Go  for UEFI only!


I just newly broke this glass on my lens tonight. Wondering if I need to buy a new lens or if I can repair this. It is a Canon EF 85mm f/1.8 USM. This is my favorite lens to use for portraits!

Can I send in for repair a lens that has a shattered front element?     UPDATE: The front element was not shattered, it was the UV filter. Factory diagnosis: Lens assembly had been impacted; cleaned and checked.  Helpful notes by Crowley, David Richerby (x2), Michael Clark (x2), and   mattdm (on element price vs UV filter).      Canon cleaned and checked my lens back to like new quality for $179 labor, no parts, not including shipping.      Jim Garrison answered my question, but Crazy Dino has the best info all around for a lens element shatter.   Original Question:  I recently opened my camera bag to find a shattered front element on a Canon EF 16-35mm f/2.8 L II USM lens.   There are a lot of micro glass shards on the second element.  Does anyone have experience with this sort of thing?  Some of the following are questions I have:   Can I get it repaired? What will the cost be roughly? Will the lens ever work the same and have a good image quality? Should I ship it as is, or attempt cleaning it with air? Where is the best place to cry a little?   Thanks, any good info on this would be appreciated.  I will never rest a lens on another lens, I nearly lost a 24-70mm L that shattered a UV filter also.   Good reason to have a UV always, never thought it could happen to me.  Update: Looking at it more it looks like maybe just the front ring came undone and the UV filter broke?  I can't remember what it looked like exactly before.  I threw away the glass shards (polished sand) in the Nevada desert.      UPDATE: Primary reason for thinking more than just the UV was broken,   UV filter split into two rings, depositing the locking collar into the   lens barrel.


The random walk I am referring to is a symmetric, unbiased, 1D random walk.  In an answer given in the link below, the probabilities are given for S1, but I am trying to find out what it is for S2, and the more general case (Sn).

We have a random walk which starts in state $0$. At each step, a coin is tossed with probability of heads: $P(H)=p$. If we get a heads, we go to the next higher integer state and on tails, we go to the next lower integer state (so state $n$ would go to $n+1$ on heads and $n-1$ on tails).   Now, I want to know the probability that we will reach state $k$ for the first time after exactly $n$ tosses of the coin. Turning out to be surprisingly hard for me.    Here is my attempt:  I define $a_n^{k}$ as the probability described above and $c_n^k$ as the probability that the random walk will be in state $k$ at toss $n$ (regardless of if it was there in a previous toss).  It's clear that we need $\left(\frac{n-k}{2}\right)$ tails and $\left(\frac{n+k}{2}\right)$ heads. So if $n-k$ is not even, the sequences for those $n$'s become $0$.   To get $a_n^k$, we need to identify all sequences where the cumulative number of heads stays less than $k$ + the cumulative number of tails for all tosses leading upto $n$. This is not so easy to solve.  On the other hand, I got an expression for $c_n^k$ and hoped I could use it to get $a_n^k$. I reasoned that the probability the walk reaches $k$ for the first time on toss $n$ is the probability it is in state $k$ on toss $n$ subtracted by the probabilities that it was in state $k$ in any previous toss. So,  $$a_n^k = c_n^k - \sum_{i=1}^{n-1} c_i^k$$  But this can't be right since this expression will become negative for many values of $n$.


I'm going to run small, heavily modded server and I can't find this anywhere. How many threads can an MC server use efficiently?  I'm choosing between 5GHz 2/4t and 4Ghz 6/12t.  Edit:  I'm asking about production data of an up to date server and if it can utilize more than 4 heavy threads. The question everybody flaging as duplicate is quite old (10 versions back) and it only tells me: How can I force JVM Garbage Collector to use more threads.  Im concerned about world loading, tick handeling, dimension handeling, entities managment and so on. Not about GC.

I am working on setting up a Minecraft server on a machine I have at home. This particular machine has two quad-core CPUs running at 2.0Ghz so I would like to take advantage of the number of cores and run a server with 4 or 6 of the cores. My server of choice is CraftBukkit, the latest version of which is craftbukkit-1.4.7-R1.0 and launched with a start-up script of:  "C:\Program Files\Java\jre7\bin\java.exe" -Xms1G -Xmx8G -jar craftbukkit-1.4.7-R1.0.jar"   The  says:     Minecraft servers, as of 1.1.0, can use multiple cores, so now they will not sit idle.   but does not really expand on this.  My questions, then:   Is it possible to set the number of cores the server uses? How do I do it - via start-up options, or other methods? Is it really worth it and would it make that much of a difference with a lot of players?


I have some code like  #!/bin/bash DIR='/project/stnb' HOST_CONFIG="${DIR}/config/host.$(hostname -s).php" CT_NUMBER="$(grep -Pow --max-count=1  ct'[0-9]*'  ${HOST_CONFIG})"  #number of container  BASH_PROFILE_PS_STING="PS1='\[\e[0;32m\]\u\[\e[0;32m\]@\[\e[0;36m\]${CT_NUMBER}\[\e[0;33m\]\w\[\e[0;36m\]\$(__git_ps1 \"(%s)\") \[\e[0m\]\$ '"   so I want to rewrite 1st row at "bash_profile", and try "sed"  sed -i "1с${BASH_PROFILE_PS_STING}" ~/.bash_profile   but after replacing I see only   PS1='[e[0;32m][e[0;32m]@[e[0;36m]ct88[e[0;33m]w[e[0;36m]$(__git_ps1 "(%s)") [e[0m]$ '   After googling I was try following options:  1) Use an alternate regex delimiter  sed -i "1s!.*!${BASH_PROFILE_PS_STING}!" ~/.bash_profile   2) or  sed -i "1c~${BASH_PROFILE_PS_STING}" ~/.bash_profile     what's wrong?  Is it really necessary to preliminary replace \ in variable before and replace change after operation back?

In my bash script I have an external (received from user) string, which I should use in sed pattern.  REPLACE="<funny characters here>" sed "s/KEYWORD/$REPLACE/g"   How can I escape the $REPLACE string so it would be safely accepted by sed as a literal replacement?  NOTE: The KEYWORD is a dumb substring with no matches etc. It is not supplied by user.


From Orwell's essay:  "But apart from these, there are two well-known types of pest by whom every second-hand bookshop is haunted. "  Why is the singular used here? Why not the plural?

When speaking precisely or technically, one would say that "Homo erectus and homo sapiens are two species of hominid" rather than "Homo erectus and homo sapiens are two species of hominids." The hominid here should be singular because we are speaking about instances of a single class ("class" being used here in its broader sense, not in the sense of taxonomic grouping).  Now let's consider more common parallel constructions replacing the word species with other words.      Tide and Wisk are two brands of detergent.       Tide and Wisk are two brands of detergents.      Cats and dogs are two types of pet you can buy at Pets-R-Us.       Cats and dogs are two types of pets you can buy at Pets-R-Us.   I feel that using the singular noun to specify the class is more grammatically correct, but sounds stilted in conversation. Almost everyone I hear making these constructions uses the plural form. What are your thoughts about singular vs. plural here?  Edit  Here's a more extreme example that may help clarify the issue. Consider the following sentence:     It was my first attempt at calming an angry crowd, and I just        stood there while people were hurling all kinds of insults at me.   Here I think the singular insult sounds strange, if not downright wrong.  Further Edit  I just noticed in A Treasury for Word Lovers (Morton S. Freeman, 1983) a section entitled "Types of Errors." This is a book about (American) English usage by an English professor and editor, which purports to be a "practical guide for serious writers and readers." I wish I could say this discovery satisfies the question, but in fact I now feel somewhat farther from the truth, if there is any single "truth" in this matter. But at least I don't have to worry about being wrong when using the plural form of the class in these constructions.


I am using external usb keyboard. I want to disable laptop's internal keyboard using software.  I know that i can just remove the internal keyboards wire and disconnect it physically, but i wanted to disable it using software so that later I can enable it by just executing a command in terminal easily. I am talking about disabling the keyboard and NOT the keyboard layout.  I am having Hp-Compaq Presario A965 TU Laptop Intel Centrino Core 2 Duo(Freq. 2 GHz). I am using 64 bit Ubuntu Lucid Lynx.

A week ago, I spilt the contents of my cup onto my laptop keyboard. Half of the keys no longer work, except one! The letter Q which is very active regularly.  This is very disturbing as I work.  Is there a way to disable the internal keyboard of a laptop?  Is it possible with xmodmap?