Intuitively, I get how the sequence $\{\cos(j)\}, j \in \mathbb{R}$ is dense in the interval $[-1,1].$ However, I am having some issues figuring out the proof technique to solve this particular problem. I have a good feeling that if I AFSOC there exists an $x_0 \in [-1,1]$ such that $\forall j \in \mathbb{R}. \cos(j) \neq x_0,$   I will run into some contradiction towards the properties of $\cos(j).$ Should I potentially be using trigonometric identities for this problem?

Show that $\{\cos\ n:n \in \mathbb{N}\}$ is dense in $[-1,1]$ by using the fact below:      Suppose $x$ is irrational. Then there exists $p_n,q_n \in \mathbb{Z}$   such that $\bigg|x -\frac{p_n}{q_n}\bigg| < \frac{1}{q_n^2}$   I have no idea on how to apply the fact above to show the set is dense in $[-1,1]$. Can anyone help me?


I'm looking for something like \nothing, which will output no text. I need to put it between an apostrophe and closing quotes:  He said: ``I found `peace.'''   I have to do something like:  He said: ``I found `peace.'\nothing{}''

I have a paragraph as follows:  ``This is a quote. `Here is a quote within a quote.'''   But the formatting works out to be a double quote (") followed by a single quote (') instead of the other way around. How can I solve this problem?


I was reading this paper related to gaussian processes . I didn't get how they derived the posterior of the gaussian process given some observed data  I understand that y follows normal having mean u and std $\epsilon$. Both y and u have normal distribution with mean 0. Only the covariance is different in the case of y an u.Can anyone please explain how the posterior was derived. I didn't get how the $K$ part came in the mean of the posterior and the covariance of the posterior  Well  u ~ 0 K       K_uy  y ~ 0 K_uy        K+$\sigma^2$  I didn't get how the part K_uy is calculated. They have placed it to be K. I am not sure why. Clarificiations?  Also can you explain how the prediction process is derived. I know the integration makes sense. But how did they get the final expression?

I have this confusion related to the predictive distribution of gaussian process. I was reading this      I didn't get how the integration gave that result. What is P(u*|x*,u). Also how come the covariance of the posterior distribution is $\sigma^2(\sigma^2I+K)^{-1}K$


I have the following code in html:

         Name	         Parent	         Priority	         Action

         test	         null	         0	                      <button value="3" type="button" class="btn btn-danger btn-sm"></button>

         Lifestyle	         null	         1	                      <button value="2" type="button" class="btn btn-danger btn-sm"></button>

         Travel	         null	         1	                      <button value="1" type="button" class="btn btn-danger btn-sm"></button>

     And I have the following code in the footer:  $("#check tr td button").click(function () {     alert('here'); });   But the event does not seems to work. Why is my code not working? The data in table are created after a ajax call. Is it because of ajax?

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


Einstein's geometry is often explained to the layman (me) as "Mass tells spacetime how to curve, spacetime tells mass how to move". It seems to me then, that what we call gravity is explained by the movement of a body in a straight line through curved spacetime.   I understand from similar questions that it's a model, we use the apparent force of gravity because it's easier to model a force than model curved space,   The standard model of particle physics explains the other 3 fundamental forces and the particles that carry them. However it can not explain gravity as a force in the same way, and the predicted graviton hasn't been detected by any of the particle accelerators.  In light of the fact that it is explained by the curvature of space, that it isn't explained by the otherwise well tested model of particle physics, that it is completely different from the other 3 fundamental forces in magnitude, why is it still considered to be fundamental?

I have studied some of Einstein's Theory of General Relativity, and I understand that it states that gravity isn't a force but rather the effects of objects curving space-time. If this is true, then why are we instructed in middle school that it is a force?


I tried to fix this problem by reading the answers to the questions on this forum related to this topic, but I did not find any solution. Could you help me, please? The thing is that I have to break a long equation with an initial bracket...Because of that, I am not able to use neither split nor align...Here the text  \begin{equation} u_{i}^{n+1} = \frac{1}{2} \hat u_m^n e^{Ii\phi_m} \left\{ \frac{1}{2} \left(e^{I\phi_m}+e^{-I\phi_m}+2\right)  -\frac{\Gamma}{2} \left(e^{I\phi_m} + e^{-I\phi_m}\right) - \Gamma \left[ \frac{1}{2} \left(e^{I\phi_m} + e^{-I\phi_m}\right) - \frac{\Gamma}{2} \left(e^{I\phi_m} + e^{-I\phi_m} -2\right)\right] \right\}. \notag \end{equation}

I have a multi-line equation that I want to have matching sized parentheses. The advice I read online was to use \left( equation \right. \\ left. rest-of-equation \right) . However, this syntax leaves first half of the equation unaware of what is in the second half. For example, if you include a square root term after the break, the second parenthesis will be larger than the opening parenthesis. When you are using the aligned environment to split a long equation this can look somewhat offputting.    Compare the top equation to the bottom one. The parentheses match in size for the bottom equation, but the left hand parentheses for the top one is  noticeably smaller.  Top Code:   \begin{aligned}[t]   \gamma_{\text{u}} + \frac{1}{108}   \left(57\gamma_{\text{er}} \right. &+  38\gamma_{\text{se}}\\ & {}\pm  \left.\sqrt{2601 \gamma_{\text{er}}^2 + 3648  \gamma_{\text{er}}\gamma_{\text{se}} + 1444 \gamma_{\text{se}}^2}  \right)   \end{aligned}   Bottom Code:  \begin{aligned}[t] \gamma_{\text{u}} + \frac{1}{16} \left(9\gamma_{\text{er}}  +  6\gamma_{\text{se}} \pm  \sqrt{49 \gamma_{\text{er}}^2 + 76 \gamma_{\text{er}}\gamma_{\text{se}} + 36 \gamma_{\text{se}}^2} \right) \end{aligned}


The reason I'm asking this (when it's been asked before) is because I'm playing an Animated Armor, which technically HAS no senses. It's just magic in a shell. (Ghost in the shell, anyone?) So that begs the question, does something that's purely magical have the ability to see through walls? And if so, can it be stopped by that so many feet of wood, stone, iron, and lead? My question is stemmed off of the homebrew race (and the monster)

I am currently play-testing an Awakened Mystic character in D&D 5e, using the beta rules . As such, I have an ability that lets me choose between having Blindsight or Tremorsense.  BLINDSIGHT: ...[B]lindsight can perceive its surroundings without relying on sight, within a specific radius.... (Monster Manual p.8) TREMORSENSE: ...[T]remorsense can detect and pinpoint the origin of vibrations within a specific radius, provided that the [observer] and the source of the vibrations are in contact with the same ground or substance. Tremorsense can't be used to detect flying or incorporeal creatures.... (Monster Manual p.9)  I have been wondering what the difference is between these two, aside from the fact that Tremorsense requires contact with the ground and cannot detect flying or incorporeal creatures. Specifically, I want to know whether Blindsight cannot detect creatures through solid matter such as walls, floors, and ceilings, whereas Tremorsense can? Can Blindsight detect creatures on the other side of a dungeon wall, or on another floor of said dungeon? Are there monsters in 5th Edition that possess both Blindsight and Tremorsense, and if so, when and why would they use one as opposed to the other? I am aware of and appreciate  regarding Blingsight's capability to detect invisible creatures, but it doesn't exactly address my issue of whether solid matter effectively "blocks" Blindsight. I will gladly consider either rules-as-written or rules-as-interpreted answers. If there is a published game mechanic or a posted developer ruling I have overlooked, please include and cite them in your answer.


I have wondered from time to time about the phrase "attorney at law." Are there other kinds of attorneys? Attorneys at arms? If not, why do we specify?


Is there a standard connector used to connect the ground/supply pins on an RF amplifier to a power supply? For example, many RF amplifiers (also attenuators) I've seen use two pins like this:   But I have no idea if there's a standard name/mating connector for them. The reason I ask if that I've accidentally shorted an amplifier using alligator clips, and am wondering if there's an alternative option to limit the amount of exposed metal.

While working on a project recently, I noticed that Digi-key has a product category . I've never seen connectors like this before, and they don't look like any kind of contact I've seen before. What does the mating connector look like? I can't envision any mating contact that makes any sense for these.  On top of that, they look like they have to be individually machined, which can't be a cost-effective process.


I have two lists I produce using the following commands:   find . -type f -name config.php -exec ls {} \;  find . -type f -name config.php -exec grep --files-with-matches some_string {} \; | sort    How could I pipe the lists into com -23 so I can see those entries from list1 that aren't contained in list2?

From this :  $ diff <(wget -q -O - URL1) <(wget -q -O - URL2)   Seems like multiple standard inputs but---if I remember my Linux Porgramming course correctly---this can't be it. I thought that, by definition, standard input was one stream.  Perhaps this has zilch to do with stdin? Can someone explain this to me; maybe provide links to documentation.  Bonus: How would a script handle these multiple streams? If someone could provide a Python or Perl example, that would be very helpful.


How do I replace placeholders in a file with variables from another file? (Like docker-compose is doing it.)   I found many articles about single variable replacements or replacement by environment variables but not file to file.  .env file  name=John time='10:00'   Content file  Hello "${name}"! I wait for u since ${time}.   Output file:  Hello "John"! I wait for u since 10:00.   Edit: Note that I also want to keep the " in the file.  Edit2: I ended up using the solution from @steeldriver. This is what I use now in my script:  # Make copy of the template folder (containing scripts and `.env` file) cp -r templates .templates  # Replace environment variables in all files of the folder set -a for file in $(find .templates -type f) do     . ./.env && envsubst < $file > $file.tmp && mv $file.tmp $file done set +a  # create output directory mkdir -p $HOME/output/  # copy if new or modified rsync -raz .templates/. $HOME/output/  # remove temp folder rm -r .templates

Is there an easy way to substitute/evaluate environment variables in a file? Like let's say I have a file config.xml that contains:  <property>     <name>instanceId</name>     <value>$INSTANCE_ID</value> </property> <property>     <name>rootPath</name>     <value>/services/$SERVICE_NAME</value> </property>   ...etc. I want to replace $INSTANCE_ID in the file with the value of the INSTANCE_ID environment variable, $SERVICE_NAME with the value of the SERVICE_NAME env var. I won't know a priori which environment vars are needed (or rather, I don't want to have to update the script if someone adds a new environment variable to the config file). Thanks!


Let $f$ be a real-valued function for which, for every real $x,y$:  $$f(x+y) = f(x)+f(y)$$  Does this imply that $f$ is a linear function ($f(x)=a\cdot x$)?   If $f$ is differentiable, I think the answer is yes. Take the derivative of $f(x+y)$ by $x$: $f'(x+y)=f'(x)$. This is true for all $y$, hence $f'$ is a constant function. Additionally, $f(0)=f(x+0)-f(x)=0$. Hence $f(x)=ax$. (is this correct?) If $f$ is continuous, I think the answer is also yes. First, note that $f(0)=0$. Let $a=f(1)$. By addition, for every integer $x$, $f(x)=a\cdot x$. This also must be true for every rational $x$. Hence, by continuity, it must be true for all $x$. (is this correct?) What is the answer for general $f$?

Do there exist functions $f : \mathbb{R} \rightarrow \mathbb{R}$ such that $f(x+y)=f(x)+f(y),$ but which aren't linear? I bet you they exist, but I can't think of any examples.  Furthermore, what hypotheses do we need to put on $f$ before no such functions exist? I feel continuity should be enough.


Are the red ports below eSATAp that can power a 3.5'' HDD?    I saw  about 12V eSATAp and I would guess that they are. However I have a cable like this:    which claims to support 3.5'' drives on 12V, but the disk does not even start spinning. I'm trying to understand if the cable is faulty or the port is not the one I think it is (the disk works fine, by the way).

I have a Lenovo ThinkPad Edge 13" model 0217-2QG with eSATAp port.  How do i check if my port provides 12V power (enough to power a 3.5" HDD)?


Ok first, It's Not a duplicate question My Problem is different.  I recently searched my domain in google like site:mysite.com and I see a load of links to casinos that are not mine. The subdomain structure is www.mysite.com/bellagio  I never created a folder called bellagio and this subdomain(sry I don't know what we call it) is pointing directly to a casino site.  I am using wordpress on godaddy hosting and registered domain there too.  It is something like this question  but not exactly the subdomains.  I tried actually creating a folder named bellagio and then clicking the link but yet it redirects to that spam site.  When I did some research not only me but hundereds on websites were hacked this way.(try searching The Bellagio - Why To Gamble At Bellagio)  I am using free ssl certificates from startssl, is that the cause ?  any help would be greatly appreciated, atleast tell me what and how to check ?

This is a  about Server Security - Responding to Breach Events (Hacking)   See Also:                  Canonical Version I suspect that one or more of my servers is compromised by a hacker, virus, or other mechanism:   What are my first steps? When I arrive on site should I disconnect the server, preserve "evidence", are there other initial considerations? How do I go about getting services back online? How do I prevent the same thing from happening immediately again? Are there best practices or methodologies for learning from this incident? If I wanted to put a Incident Response Plan together, where would I start? Should this be part of my Disaster Recovery or Business Continuity Planning?   Original Version       2011.01.02 - I'm on my way into work at 9.30 p.m. on a Sunday because our server has been compromised somehow and was resulting in a    attack on our provider. The servers access to the Internet   has been shut down which means over 5-600 of our clients sites are now   down. Now this could be an FTP hack, or some weakness in code   somewhere. I'm not sure till I get there.      How can I track this down quickly? We're in for a whole lot of   litigation if I don't get the server back up ASAP. Any help is   appreciated. We are running Open SUSE 11.0.            2011.01.03 - Thanks to everyone for your help. Luckily I WASN'T the only person responsible for this server, just the nearest. We managed   to resolve this problem, although it may not apply to many others in a   different situation. I'll detail what we did.      We unplugged the server from the net. It was performing (attempting to   perform) a Denial Of Service attack on another server in Indonesia,   and the guilty party was also based there.      We firstly tried to identify where on the server this was coming from,   considering we have over 500 sites on the server, we expected to be   moonlighting for some time. However, with SSH access still, we ran a   command to find all files edited or created in the time the attacks   started. Luckily, the offending file was created over the winter   holidays which meant that not many other files were created on the   server at that time.      We were then able to identify the offending file which was inside the   uploaded images folder within a  website.      After a short cigarette break we concluded that, due to the files   location, it must have been uploaded via a file upload facility that   was inadequetly secured. After some googling, we found that there was   a security vulnerability that allowed files to be uploaded, within the   ZenCart admin panel, for a picture for a record company. (The section   that it never really even used), posting this form just uploaded any   file, it did not check the extension of the file, and didn't even   check to see if the user was logged in.      This meant that any files could be uploaded, including a PHP file for   the attack. We secured the vulnerability with ZenCart on the infected   site, and removed the offending files.      The job was done, and I was home for 2 a.m.            The Moral   - Always apply security patches for ZenCart, or any other CMS system for that matter. As when security updates are released, the whole   world is made aware of the vulnerability.   - Always do backups, and backup your backups.   - Employ or arrange for someone that will be there in times like these. To prevent anyone from relying on a panicy post on Server   Fault.


I accidentally switched into first person and don't know how to return to the third person again.

I've seen many trailers and other gameplay videos showcasing how you can switch from 3rd to 1st person on the fly. However, I don't recall this ever being mentioned in the tutorials (unless I missed it) and I also don't remember seeing it in the control layout in options. Now, I've tried pressing every button that makes sense (ie obviously leaving out the share button) but they all seem tied to an existing function/skill. Am I missing something?  I'm playing on the PS4 (left the tag out since this question isn't specifically about the PS4 itself).


When I add XY (lat,long) data to the map in the same PCS and GCS as the other layers, the points are added to the map but do not line up with the other layers. I am using GCS: GCS_North_American_1983, and PCS: NAD_1983_UTM_Zone_16N. When I change the XY data to WGS_1984, the points appear on the other layers. However, I am unable to run any measuring tool. I am trying to use the Near tool to measure distance between the XY data and a polygon layer. This does not work, probably because they are in different coordinate systems. I've also tried converted the XY data into a shapefile and that doesn't work either.

I put 4 different layers into my ArcMap document, but only one of them will show up on the map! I should be seeing the other 3 layers as well. When I do a Zoom to layer, I can see one layer, but I cannot figure out how to make the other 3 show up at once on top of each other.  Before I opened ArcMap, I used ArcCatalog where I right-clicked 3/4 of the shapefiles and  clicked Properties → Coordinate system → Import and then clicked on my Trees layer, which has the coordinate system I want the other 3 to have. But when I opened ArcMap the 4 layers did not overlap, nor could I move them above or below each other.


in the below code    public class MsLunch {     private long c1 = 0;     private long c2 = 0;     private Object lock1 = new Object();    // private Object lock2 = new Object(); private Dummy lock2 = new Dummy();     public void inc1() {         synchronized(lock1) {             c1++;         }     }      public void inc2() {         synchronized(lock2) {             c2++;         }     } }   i have changed the lock object used to protect the c2 count. i have used a dummy class which is no where related to MsLunch class. Is it fine or should i always put the lock on the object of the current class("this" or MsLunch object or parent class Object). Please answer as i have been  struggling a long way to understand the role of object used in synchronized block. Also is it necessary that the synchronized block member fields and variables must be held by the object used to lock ?

Whenever a question pops up on SO about Java synchronization, some people are very eager to point out that synchronized(this) should be avoided. Instead, they claim, a lock on a private reference is to be preferred.  Some of the given reasons are:    (very popular this one, also has an "accidentally" variant)     Other people, including me, argue that synchronized(this) is an idiom that is used a lot (also in Java libraries), is safe and well understood. It should not be avoided because you have a bug and you don't have a clue of what is going on in your multithreaded program. In other words: if it is applicable, then use it.  I am interested in seeing some real-world examples (no foobar stuff) where avoiding a lock on this is preferable when synchronized(this) would also do the job.  Therefore: should you always avoid synchronized(this) and replace it with a lock on a private reference?      Some further info (updated as answers are given):   we are talking about instance synchronization both implicit (synchronized methods) and explicit form of synchronized(this) are considered if you quote Bloch or other authorities on the subject, don't leave out the parts you don't like (e.g. Effective Java, item on Thread Safety: Typically it is the lock on the instance itself, but there are exceptions.) if you need granularity in your locking other than synchronized(this) provides, then synchronized(this) is not applicable so that's not the issue


public interface myInterface<T> {      public List<T> doWork();  }  public abstract class baseClass<T> implements myInterface<T>{      protected T obj;     protected List<T> list;      public baseClass<T>(){          //how do I initiate obj?          //how do I initiate list?     }    }  public class myClassA extends baseClass<T> {   public List<T> doWork() }   I have this code and I was wondering how I could initiate obj and list of type T dynamically.

Is it possible to create an instance of a generic type in Java? I'm thinking based on what I've seen that the answer is no (due to type erasure), but I'd be interested if anyone can see something I'm missing:  class SomeContainer<E> {     E createContents()     {         return what???     } }   EDIT: It turns out that  could be used to resolve my issue, but it requires a lot of reflection-based code, as some of the answers below have indicated.  I'll leave this open for a little while to see if anyone comes up with anything dramatically different than Ian Robertson's .


I am creating simple Android project which contains login Activity. The problem is I tried to reach the object in specific index and tried for loop, but it always return last object in sequence.   public Result<LoggedInUser> login (String username, String password){      try {         // TODO: handle loggedInUser authentication         GetData myData = new GetData();         usersdata = myData.getUsers();         for (User user : usersdata) {             if (user.UserName.trim() == username && user.Password.trim() == password) {                 LoggedUser = user;             } else LoggedUser = null;         }          return new Result.Success<>(LoggedUser);     } catch (Exception e) {         return new Result.Error(new IOException("Error logging in", e));     } }

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?


How ? my code and result below  \chapter*{Camera Calibration Data, \\ Cont'd}  Focal Length in x = 953.58\\ Focal Length in y = 953.58\\ Principal Point = (959.5, 539.5)\\   \begin{tabular}{|c|c|c|}   \hline Camera 1 & $\begin{array}{ccc} 0.99997 & -0.00769 & 0.00016 \\ -0.00500 & -0.66628 &-0.74569 \\ 0.00585 & 0.74567 & -0.66630 \end{array}$ & 0\\ \hline Camera 2 &   0& 0\\ \hline Camera 2 &  0 & 0\\ \hline Camera 2 &0  & 0\\ \hline Camera 2 &  0 & 0\\ \hline Camera 2 &  0 & 0\\ \hline \end{tabular}   I am trying to make it look like

I have the following table:  \begin{table}[htb] \begin{tikzpicture} \node (table) [inner sep=0pt] { \begin{tabular}{ l | l }   {\bf Symptom} & {\bf Metric} \\ \hline Class that has many accessor methods and accesses a lot of external data & ATFD is more than a few\\ Class that is large and complex & WMC is high\\ Class that has a lot of methods that only operate on a proper subset of the instance variable set & TCC is low\\ \end{tabular} }; \draw [rounded corners=.5em] (table.north west) rectangle (table.south east); \end{tikzpicture} \caption{God class symptoms} \label{tbl:god_class} \end{table}   Now I want to force the width of the table to be the same as the \textwidth, either by linewrapping of table text or by scaling. How can I achieve that?


Let G be a non-empty open subset of $ \mathbb{R}$.     Let $x_0$ $\in \space G$ and put $F=[x_0,\infty) \cap G^c.$ Here $[x_0,\infty)=\lbrace x \in \mathbb{R}:x \geq x_0  \rbrace $.  (a) Prove that $F$ is a non-empty set.  My attempt:  I found a counter example. If $G= \mathbb{R}-\lbrace 0 \rbrace $ then $G$ is clearly open. However, if $x_0 =5$ for example, then we have F=$\emptyset$.  Yet, the exercise claims that this is never true.  Please help! Thank you very much

I would be very glad if you helped me solving this problem. It's about topology. Okay let's begin :    Let $A$ be a non-empty open subset of $\mathbb R$. Let $x_0 \in A$ and $B = [x_0,\infty) ∩ A^c$ (complement of $A$)  First I should prove that $B$ is a non-empty, closed set. Then I should prove that :     $B$ is bounded below.   $\inf B > x_0$   $\inf B$ doesn't belong to $A$.   $[x_0, \inf B) \subseteq A$.    Then I should explain how to deﬁne a number $\beta$ so that $(\beta,\inf B) \subseteq  A$, where $\beta$ doesn't belong to $A$.    I really can't get up with proofs for these question. Can you please help me solving this or at least give me some hint or sketch? I would be very grateful. Thank you :)


I am trying to replicate a material with these nodes and they use a power node and it’s not on blender. i’m using 2.92

A lot of people recommend to use the maximum node for glass setup, but I can't find that node. Nothing comes up when I search for it.  Where do I find it?


im trying install ubuntu 13.04 but when installation finished cant start ubuntu please help with bios configuration and how to install ubuntu on this ativ book 9 lite.  i try disabling fast boot, disabling secure boot, etc but no result.

I'm absolutely new to Linux. I would like to know how to install Ubuntu alongside the pre-installed Windows 8+ OS.  Should I do it with Wubi, or through the Live USB/DVD?  What steps do I need to take to correctly install Ubuntu?


I have a 2TB SSD without OS on it, only data, it is on /dev/sda1. It is full but I have about 100GB that I cannot used on it. I have already extended at maximum with GParted. df|grep /dev/sda1 returns : /dev/sda1         1921802432 1824110376          0 100% /mnt/b85107de-9722-4bf5-8e9a-c810fbfb7e76   How to retrieve the unused space ? Thanks beforehand.

To my knowledge Ubuntu creates a system reserve on partitions that take up 5% of the partition capacity. On 8 TB drives system reserve takes up about 380 gigs. I double checked this in df and can calculate the missing gigs. I have four 8 TB partitions and am losing 1.5 TB of storage space. Is there a way to make ubuntu use a smaller percentage for the system reserve?


I have a previous question re loading html via ajax:  but I face small issue with attaching a click listener:

  ....

             	             Name	             Category	             Created On	             Size

                 	                 contractUHCSigned.pdf	                 Category                 	                  Create On	                 400 kb                 	                 View

       It's not triggering the handleFiledeletion method. I tried another approach: $("#noteFileDeletion").on('click', function() {         var deleteBtn = $(this);         var url = $(this).data('url');         url = url +"?csrf_token="+App.config.csrfToken;         var msg = "Are you sure you want to "+$(this).data('confirm')+"?";         bootbox.confirm(msg, function(result){             if(result){                 $.ajax({                     processData : false,                     "type" : "DELETE",                     "url" : url,                  })                     .success(function( data ) {                         window.location.href='/applicationProducts';                     });             }         });     });  but it's not triggering the event handler either. What I missing?

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


Given the following struct with a filename and a functionpointer:  static struct thread {     const char *const filename;     ssize_t (*in)(struct thread *, void *, size_t);  }   and the function  int MyClass::read_wrap(struct stThread *t, void *buf, size_t nbytes) {     return read(t->fd, buf, nbytes); }   I try to assign the function read_wrap to the function pointer member in a struct object:  int main (void) {  thread myThread; myThread.in = read_wrap;  }   But I get the error:  error: cannot convert MyClass::read_wrap’ from type ‘int (MyClass::)(stThread*, void*, size_t) {aka int (MyClass::)(stThread*, void*, unsigned int)}’ to type ‘int (*)(MyClass*, void*, size_t) {aka int (*)(stThread*, void*, unsigned int)}’   I mean, the struct is expecting a function pointer and I thought when I pass it the name of the function, that this is somehow cast into a fp?! This code is from C and compiles fine with gcc.  Thanks for the help!

I could be totally wrong here, but as I understand it, C++ doesn't really have a native "pointer to member function" type.  I know you can do tricks with Boost and mem_fun etc. But why did the designers of C++ decide not to have a 64-bit pointer containing a pointer to the function and a pointer to the object, for example?  What I mean specifically is a pointer to a member function of a particular object of unknown type.  I.E. something you can use for a callback.  This would be a type which contains two values. The first value being a pointer to the function, and the second value being a pointer to the specific instance of the object.  What I do not mean is a pointer to a general member function of a class. E.G.  int (Fred::*)(char,float)   It would have been so useful and made my life easier.  Hugo


I have a script that exports a site and restores it in another web application.  I want to check if the target site already exists.  Is there an easy way to tell if www.example.org/sites/asite/ is free, without throwing an error in Powershell?

I am an nube to Powershell, so I think I have a pretty basic question here....  How do I determine if a SPWeb exists? I want to perform some operations on a site based on a URL passed in as a parameter. However, there are instances where the site may not exist. I have tried something like  $test = Get-SPWeb($siteToGet) if ($test -eq  $null ) {     Write-Host Site $siteToGet  does not exist } else {     Write-Host Site $siteToGet  DOES exist }   where $siteToGet is not a valid site. However, I get an error message on the Get-SPWeb saying in red saying the site does not exist. The rest of the code then runs. Is this okay? I would prefer to log a message instead of display the error message from Get-SPWeb. It also causes more error messages as my script continues to run, but by checking for $null I can at least make sure I am not executing further code.  Any ideas how to check for the existence of a site using PowerShell and SharePoint 2010?  Thanks


The daily freezing and melting of water causes large rocks to break up into smaller pieces.  I have faced a sentence and can't understand what is meaning of it. As far as I know after noun + and + noun we have to use verb for plural, but the sentence says different. Please help me.  Thanks for your ideas.

I was surfing the internet the other day when I found this phrase: Instead your precious time and attention is wasted. To my ears, it sounds wrong. But I'm not a native English speaker, so I consulted with a number of them, and some of them said that it was "is" because the adjective modifies only the noun "time" and not "attention". Others said it "is" because that's just how it is. But I still believe it should be "are". Any help is appreciated.


I' am getting the following characters on my website contact us form. How can I validate the message field so that such characters are not allowed.  Ð”Ð¾Ð±Ñ€Ñ‹Ð¹ Ð´ÐµÐ½ÑŒ! ÐžÐºÐ°Ð·Ñ‹Ð²Ð°ÐµÐ¼ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒ Ð² Ð¿Ð¾Ð»ÑƒÑ‡ÐµÐ½Ð¸Ð¸ Ð³Ñ€Ð°Ð¶Ð´Ð°Ð½Ð°Ð¼ Ð¸ ÑÐ¾Ñ‚Ñ€ÑƒÐ´Ð½Ð¸ÐºÐ°Ð¼ Ñ„Ð¸Ñ€Ð¼ ÐºÐ°Ñ€Ñ‚Ð¾Ñ‡ÐµÐº Ð¼ÐµÑ‚Ñ€Ð¾ Ð² ÑÐµÑ‚ÑŒ Ð½ÐµÐ¼ÐµÑ†ÐºÐ¸Ñ…   This is the code am currently using  $message = sanitize_text_field($message); $message = str_replace("`","", $message);

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


One of our employees has had signed in with her Google account on a tablet (SM-T285, organizational one, and I didn't know that). Now she isn't here and we don't have access to her. Because she had had set a screen lock (and also many other customizations), I preferred to do a factory reset to make it totally clean. Now I am stuck in initial setup and need that Google account. How can I bypass this? I have googled a lot, no luck.  Thanks  EDIT: I have seen other posts, but none of them works for me. Connecting USB via OTG doesn't open explorer (Cable is OK). USB debugging disabled by default and no fastboot.

I won a Samsung Galaxy S6 Edge, signed into it with my Google account, played around with it, wiped it, and sold it.  Now the person can't get past setup because it's saying he must login with an account previously synced to the phone.   Is there anything I can do from my side to remove this lock?


Let say we have a group of models (car models, for example), how would you refer to it?: model group or models group? and in plural: models groups or model groups? We wanted to create a variable for a code and were discussing about the right usage, modelGroup or modelsGroup? Thank you!

Is it correct to say user accounts or users account when referring to the accounts any user has on a site like this one?  In general, in the case of a noun that is used as adjective for the noun that follows, is it better to use <plural-noun> <singular-noun> or <singular-noun> <plural-noun>?


Spells like Forbiddance or Mordekainen's Private Sanctum cannot be seen once cast. (Not just because they are invisible, but because there is nothing at all to indicate their presence excepting a few non-visible effects)   They have continuing effects, such as warding against teleportation and planar travel.  Can Dispel Magic be used to end such spells?  A few possible scenarios - in which, if any, is the Forbiddance dispelled?   A clueless PC casts Dispel Magic at a rock in the radius of a Forbiddance spell.  A PC knows there is some magic that's prevented them from teleporting into this area, but not what spell it is. They try to target a Dispel Magic at the magical effect that caused this. A PC knows there is a Forbiddance spell active in the area. They try to target the spell with a Dispel Magic.

Discussions about Dispel Magic seem to imply that as long as you can perceive a magic effect in range of the spell, you can try and dispel it.   See  and  from @Miniman:      knowing where it is means that you know where it is. This allows you to use spells like Dispel Magic to remove its invisibility.   But what if you can't perceive it?  Two scenarios come in mind:   In combat, an evil wizard casts Invisibility on himself, walks away from the fray and uses the hide action on his next turn. Since PCs know/assume/deduce he's invisible and certainly in range of the spell, can one use Dispel Magic to end the spell? PCs enter a 80'×80' room. Can one declare: "I dispel any Invisibility spell in range", thus revealing one (the closest?) invisible enemy in the room?   What's enough to enable a caster to cast Dispel Magic on a magic effect:    perceiving (seeing, hearing, smelling, etc.) it? knowing/assuming/deducing it's there? or merely suspect/predict it?


i want to cite a lecture given in a school. How is the standard way to do so in bibtex?   @unpublished{123, author = {X. YY}, institution = {NASA aerospace school, USA},  year = {2014}, title = {Air pressure sensors} }

I need to write an introduction to a topic which relies heavily on several University lecture slides and scripts. I would like to acknowledge this by using something like this:     The following exposé is based on the lectures by \citet{A, B, C} and on \citep{X, Y}.   But the question is, how do I cite them properly? In particular, what is the right BibTeX category? Is the following the only way? I would like to use something as unspecific as misc as little as possible.  @misc{LectureA,   Author = {Ridcully, Mustrum},   Institution = {Unseen University},   Howpublished = {University Lecture},   Year = {2000},   Title = {An Introduction to Crossbow Hunting} }


Is there a data structure such that I can input all the objects to it and then it will return the objects according to the number of occurrence (e.g. in descending order). All I can think of is using a hash map. The key of the hash map is the object and the value is the occurrence of the object. Every time I input an object, I increment the value of the corresponding key. However, in this way, if I want to output the objects according to the descending order of the occurrence, I need to traverse the hash map once. Is there a more efficient way to implement this in Java?

I am relatively new to Java, and often find that I need to sort a Map<Key, Value> on the values.  Since the values are not unique, I find myself converting the keySet into an array, and sorting that array through array sort with a custom comparator that sorts on the value associated with the key.  Is there an easier way?


Solve for $x$, if   $$(x+4)(x+7)(x+8)(x+11)+20=0.$$   Is there an easier way to solve this than trying to multiply all the values together? I've tried multiplying all of them together, and I get an equation of the fourth degree which I find very hard to factorise. I'm hoping there is an easier way to solve this question. Any help is appreciated.Thanks :).  The equation I get after multiplying is $$x^4+30x^3+325x^2+1500x+2484=0,$$ and its roots are  $$-6, \quad -9, \quad \frac{-15\pm\sqrt{41}}2 .$$

I can solve this equation $x(x-1)(x-2)(x-3)=1$ using the usual method but I am looking for a fast analytical method to solve this. Any hints ?


I am having trouble getting the correct result from the output. Some input give the right and some don't. For example, when I put 499 I get $29.939999999999998 but when I put 500 I get $25.0.  -Enter the number of copies to print:  499 The total cost is:  $29.939999999999998  -Enter the number of copies to print:  500 The total cost is:  $25.0  This is my code: What am I doing wrong exactly?  import java.util.Scanner;  public class Main {  public static void main(String[] args) {     Scanner in = new Scanner(System.in);     System.out.println("Enter the number of copies to print: ");     double numberOfCopies = in.nextDouble();     double cost;     double subtotal;     double totalAmount;      if(numberOfCopies >= 500) {         cost = 0.05 / numberOfCopies;         subtotal = numberOfCopies * cost;         totalAmount = subtotal * numberOfCopies;         System.out.println("The total cost is: " + " $"+ totalAmount);       } else if (numberOfCopies >= 300 && numberOfCopies <= 499) {         cost = 0.06 / numberOfCopies;         subtotal = numberOfCopies * cost;         totalAmount = subtotal * numberOfCopies;         System.out.println("The total cost is: " + " $" + totalAmount);     } else if (numberOfCopies >= 200 && numberOfCopies <= 299){         cost = 0.07 / numberOfCopies;         subtotal = numberOfCopies * cost;         totalAmount = subtotal * numberOfCopies;         System.out.println("The total cost is: " + " $" + totalAmount);     } else if (numberOfCopies >= 100 && numberOfCopies <= 199) {         cost = 0.08 / numberOfCopies;         subtotal = numberOfCopies * cost;         totalAmount = subtotal * numberOfCopies;         System.out.println("The total cost is: " + " $" + totalAmount);     } else if(numberOfCopies >= 1 && numberOfCopies <= 99) {         cost = 0.10 / numberOfCopies;         subtotal = numberOfCopies * cost;         totalAmount = subtotal * numberOfCopies;         System.out.println("The total cost is: " + " $" + totalAmount);     } else if(numberOfCopies == 0) {         System.out.println("Cannot compute cost of 0 copies");     } }   }

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


Take the sentence:     Isn't there a bunch of laws around who can stay open until what time though based on location and # of residential buildings around the bar?   Bunch is singular, and the sentence is referring to a bunch of laws.  Another example, not using bunch:     Isn't there a collection of paintings?   That uses "Isn't" not "aren't"  Can you throw the prepositional phrase, and consider what comes directly after is irrelevant in terms of plurality?

In the following sentence:     The city is populated by many people.   "many" can be replaced by something like "a great number of" (let us leave the perceived differences between the meanings of these two modifiers out of discussion):     The city is populated by a great number of people.   I understand that this replacement does not change the object "populating the city" from the original "people" to a "number", but rather shows the ability of expressions in the form "[numeral] of" to provide information about the quantity of nouns they modify.  Is this ability due to some special qualities of nouns such as "number", "quantity", "fraction", &c., or is it just one usage of the preposition "of"?


From my server (Centos 8) data.mycompany.edu  I can open a psql session using psql -h localhost -p 7432 -U myusername mydb  However, if I use psql -h data.mycompany.edu -p 7432 -U myusername mydb  I get the next message: psql: /usr/pgsql-12/lib/libpq.so.5: no version information available (required by psql) psql: /usr/pgsql-12/lib/libpq.so.5: no version information available (required by psql) psql: could not connect to server: Connection refused         Is the server running on host "data.mycompany.edu" (some IP ADDRESS) and accepting         TCP/IP connections on port 7432?  I opened this port as: sudo firewall-cmd --list-all    ...   ports: 58080/tcp 58009/tcp 80/tcp 8009/tcp 55432/tcp 7432/tcp   protocols:    ...  Any ideas?

This is a  about Connection Refused    We see a lot of questions to the effect      When I try to connect to a system I get a message      Connection refused      Why is this ?


I have tried following code in which i am trying to save my uploaded image into SD card folder with some name.It gives null pointer exception on the mentioned line. Any suggestions please.      java.lang.NullPointerException: Attempt to invoke virtual method 'android.graphics.Bitmap android.graphics.drawable.BitmapDrawable.getBitmap()' on a null object reference   Code  protected void onActivityResult(int requestCode, int resultCode, Intent data) {   super.onActivityResult(requestCode, resultCode, data);   if(requestCode==i && resultCode==RESULT_OK && data != null){     Uri selectedImage =  data.getData();     coverpic.setImageURI(selectedImage);     Bitmap  image =( (BitmapDrawable)coverpic.getDrawable()).getBitmap();//This line throws the exception     if (!direct.exists()) {     File wallpaperDirectory = new File("/images/");     wallpaperDirectory.mkdirs();      }      Bundle extras = getIntent().getExtras();      File file = new File(new File("/images/"),extras.getString("name")+i + ".jpg" );             if (file.exists()) {                 file.delete();             }      try{     FileOutputStream out=new FileOutputStream(file);     image.compress(Bitmap.CompressFormat.JPEG,100,out);     out.flush();     out.close();     } catch(Exception e)             {                 e.printStackTrace();               }         }

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?


I am trying to convert a C# DateTime variable into something that is able to be passed into a Javascript function through NewtonSoft.Json.  At the moment what I am using is:  var jsonSettings = new JsonSerializerSettings(); jsonSettings.DateFormatString = "dd/MM/yyy hh:mm:ss"; string modelFromDate = JsonConvert.SerializeObject(@Model.FromDate, jsonSettings);   However this does not seem to be working since when I use Chrome Dev Tools I get the error that      modelFromDate is not defined   in the following code:  $(".go").on("click", function () {     if (new Date(modelFromDate) < new Date(1994, 1, 1)) {         alert("invalid date");     } });   I am using ASP.NET Core MVC.

I'm taking my first crack at  with jQuery. I'm getting my data onto my page, but I'm having some trouble with the JSON data that is returned for Date data types. Basically, I'm getting a string back that looks like this:  /Date(1224043200000)/   From someone totally new to JSON - How do I format this to a short date format? Should this be handled somewhere in the jQuery code? I've tried the jQuery.UI.datepicker plugin using $.datepicker.formatDate() without any success.  FYI: Here's the solution I came up with using a combination of the answers here:  function getMismatch(id) {   $.getJSON("Main.aspx?Callback=GetMismatch",     { MismatchId: id },      function (result) {       $("#AuthMerchId").text(result.AuthorizationMerchantId);       $("#SttlMerchId").text(result.SettlementMerchantId);       $("#CreateDate").text(formatJSONDate(Date(result.AppendDts)));       $("#ExpireDate").text(formatJSONDate(Date(result.ExpiresDts)));       $("#LastUpdate").text(formatJSONDate(Date(result.LastUpdateDts)));       $("#LastUpdatedBy").text(result.LastUpdateNt);       $("#ProcessIn").text(result.ProcessIn);     }   );    return false; }  function formatJSONDate(jsonDate) {   var newDate = dateFormat(jsonDate, "mm/dd/yyyy");   return newDate; }   This solution got my object from the callback method and displayed the dates on the page properly using the date format library.


Today I wanted to propose to students a very short and stupid code as follows  # include <iostream>  int main()   {    int a[] {10, 20, 30, 40};     for(int k=0; k != 4; ++k) std::cout << ++a[k] << ' ';     std::cout << std::endl;     }   in order to show how the ++ prefix operator acts in an expression.  I inadvertently mistyped the code, ending up with the following line, in place of the one shown above:  for(int k=0; k != 4; ++k) std::cout << ++k[a] << ' ';   shortly: swapping k and a in the operand of ++.  Well... not only this is compiled, but it gives also the correct results. How this could be understood? Is the index of the loop interpreted as an iterator over the array a? Or what else?

As Joel points out in , in  (aka: K & R), there is mention of this property of arrays in C: a[5] == 5[a]  Joel says that it's because of pointer arithmetic but I still don't understand. Why does a[5] == 5[a]?


Find the last three digits of $6^{2002}$. I did some work and figured out that the last two digits is 36. Can anyone help me with the hundredth digit? By the way, I used modular arithmetic and the recursion method for the tens digit, but it fell short when I attempted to do the hundreds digit. Thank you in advance!  How I figured out the last two digits: I used the formula $\frac {1}{10^k} [n-a_k (n)]$. The last digit is obviously 6. I obtained the tens digit this way: $\frac {1}{10}(6^{2002}-6)=\frac {6}{10}(6^{2001}-1)=\frac {3}{5} (6^{2001}-1)=\frac {3}{5}(6-1)(6^{2000}+6^{1999}+...+6^2+6+1)=3(6^{2000}+6^{1999}+...+6^2+6+1)\equiv3(6+6+...+6+6+1)=3(2000\cdot6+1)\equiv3 (mod 10)$ Therefore, the last two digits of $6^{2002}$ are $36$.

Find The Last 3 digits of the number $2003^{2002^{2001}}$  BY number theory or otherwise,   Also i would like to ask is there a property observed in the numbers of the form $k^n$, where for some $k, n$ is varied then the digits of $k^n$ are periodic,  for example,  $2^n$,  its last digit is periodic with period 4, its second last digit is periodic $4\cdot 5 = 20$ its third last digit is periodic with periodic with period $20\cdot 5 =100$  I have observed this property with other numbers as well, though period might vary,for different values of $k$.


I have been studying the group theoretic formalism of quantum mechanics and I have yet to find a satisfying explanation for the need for projective representations in the theory of angular momentum. I understand the connection between SO(3) and angular momentum, and I understand the the projective representation of SO(3) is given by the usual representation of the double cover, SU(2). The thing that I am missing is $\textit{why}$ the projective representation is important in the first place.   Furthermore, I understand the consequences of studying SU(2) rather than SO(3), namely that for half-integer spin particles a rotation of $2\pi$ under SU(2) transforms the wavefunction to its negative, but for integer spin particles the rotation is equal to the identity, but as I said, I see this a a consequence rather than motivation for studying SU(2) over SO(3). Is there a more satisfying answer to my question other than "we do it this way because it works"? Thanks!

$SU(2)$ is the covering group of $SO(3)$. What does it mean and does it have a physical consequence?  I heard that this fact is related to the description of bosons and fermions. But how does it follow from the fact that $SU(2)$ is the double cover of $SO(3)$?


Why is cardinality the of real numbers $2^{\aleph_0}$? While I know that real numbers can be constructed using sets of natural numbers, that solely does not mean that the real numbers has cardinality $2^{\aleph_0}$. So, what makes the real numbers cardinality $2^{\aleph_0}$?  I can't find why it is like this in my textbook...

What is the simplest way of proving (to a non-mathematician) that the power set of the set of natural numbers has the same cardinality as the set of the real numbers, i.e. how to construct a bijection from $\mathcal{P}(\mathbb{N})$ to $\mathbb{R}$?


I know there are a lot of questions like this but I've tried pretty much to understand what to do and failed.  By df -h I know that my /dev/sda1 /boot is with 100% use.  I'm not understanding what I should remove, at all. I'm running nginx and wanted to install nodejs but I was alerted of unmet dependencies when trying sudo apt-get install nodejs and sudo apt-get -f install failed for lack of space. Can I get some specific guidance on this one please? I'm feeling totally lost.  dpkg --list | grep linux-image:  ii  linux-image-3.8.0-29-generic      3.8.0-29.42~precise1                 Linux kernel image for version 3.8.0 on 32 bit x86 SMP ii  linux-image-3.8.0-34-generic      3.8.0-34.49~precise1                 Linux kernel image for version 3.8.0 on 32 bit x86 SMP ii  linux-image-3.8.0-35-generic      3.8.0-35.52~precise1                 Linux kernel image for version 3.8.0 on 32 bit x86 SMP ii  linux-image-3.8.0-36-generic      3.8.0-36.52~precise1                 Linux kernel image for version 3.8.0 on 32 bit x86 SMP ii  linux-image-3.8.0-37-generic      3.8.0-37.53~precise1                 Linux kernel image for version 3.8.0 on 32 bit x86 SMP ii  linux-image-3.8.0-38-generic      3.8.0-38.56~precise1                 Linux kernel image for version 3.8.0 on 32 bit x86 SMP ii  linux-image-3.8.0-39-generic      3.8.0-39.58~precise1                 Linux kernel image for version 3.8.0 on 32 bit x86 SMP ii  linux-image-3.8.0-42-generic      3.8.0-42.62~precise1                 Linux kernel image for version 3.8.0 on 32 bit x86 SMP iU  linux-image-generic-lts-raring    3.8.0.44.44                          Generic Linux kernel image         uname -r: 3.8.0-42-generic         sudo apt-get purge linux-image-x.x.x.x-generic  You might want to run 'apt-get -f install' to correct these: The following packages have unmet dependencies.  linux-image-generic-lts-raring : Depends: linux-image-3.8.0-44-generic but it is not going to be installed E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).         sudo apt-get -f install  dpkg: error processing /var/cache/apt/archives/linux-image-3.8.0-44-generic_3.8.0-44.66~precise1_i386.deb (--unpack):  failed in write on buffer copy for backend dpkg-deb during ./boot/vmlinuz-3.8.0-44-generic': No space left on device No apport report written because the error message indicates a disk full error                                                                               dpkg-deb: error: subprocess paste was killed by signal (Broken pipe) Examining /etc/kernel/postrm.d . run-parts: executing /etc/kernel/postrm.d/initramfs-tools 3.8.0-44-generic /boot/vmlinuz-3.8.0-44-generic run-parts: executing /etc/kernel/postrm.d/zz-update-grub 3.8.0-44-generic /boot/vmlinuz-3.8.0-44-generic Errors were encountered while processing:  /var/cache/apt/archives/linux-image-3.8.0-44-generic_3.8.0-44.66~precise1_i386.deb E: Sub-process /usr/bin/dpkg returned an error code (1)

My /boot partition is nearly full and I get a warning every time I reboot my system. I already deleted old kernel packages (linux-headers...), actually I did that to install a newer kernel version that came with the automatic updates.  After installing that new version, the partition is nearly full again. So what else can I delete? Are there some other files associated to the old kernel images?  Here is a list of files that are on my /boot partition:  :~$ ls /boot/ abi-2.6.31-21-generic         lost+found abi-2.6.32-25-generic         memtest86+.bin abi-2.6.38-10-generic         memtest86+_multiboot.bin abi-2.6.38-11-generic         System.map-2.6.31-21-generic abi-2.6.38-12-generic         System.map-2.6.32-25-generic abi-2.6.38-8-generic          System.map-2.6.38-10-generic abi-3.0.0-12-generic          System.map-2.6.38-11-generic abi-3.0.0-13-generic          System.map-2.6.38-12-generic abi-3.0.0-14-generic          System.map-2.6.38-8-generic boot                          System.map-3.0.0-12-generic config-2.6.31-21-generic      System.map-3.0.0-13-generic config-2.6.32-25-generic      System.map-3.0.0-14-generic config-2.6.38-10-generic      vmcoreinfo-2.6.31-21-generic config-2.6.38-11-generic      vmcoreinfo-2.6.32-25-generic config-2.6.38-12-generic      vmcoreinfo-2.6.38-10-generic config-2.6.38-8-generic       vmcoreinfo-2.6.38-11-generic config-3.0.0-12-generic       vmcoreinfo-2.6.38-12-generic config-3.0.0-13-generic       vmcoreinfo-2.6.38-8-generic config-3.0.0-14-generic       vmcoreinfo-3.0.0-12-generic extlinux                      vmcoreinfo-3.0.0-13-generic grub                          vmcoreinfo-3.0.0-14-generic initrd.img-2.6.31-21-generic  vmlinuz-2.6.31-21-generic initrd.img-2.6.32-25-generic  vmlinuz-2.6.32-25-generic initrd.img-2.6.38-10-generic  vmlinuz-2.6.38-10-generic initrd.img-2.6.38-11-generic  vmlinuz-2.6.38-11-generic initrd.img-2.6.38-12-generic  vmlinuz-2.6.38-12-generic initrd.img-2.6.38-8-generic   vmlinuz-2.6.38-8-generic initrd.img-3.0.0-12-generic   vmlinuz-3.0.0-12-generic initrd.img-3.0.0-13-generic   vmlinuz-3.0.0-13-generic initrd.img-3.0.0-14-generic   vmlinuz-3.0.0-14-generic   Currently, I'm using the 3.0.0-14-generic kernel.


I have a very big problem with the following question: Is the operator $T$ defined by $(Tx)t=tx(t)$, $(0<t<1)$ compact in $L_2(0,1)$?  My guess is no and I've tried 3 different approaches to show this.  I've been considering the closed unit ball $\overline{B}_1(0)$ and I have assumed that ${T\overline{B}_1(0)}$ is compact in desire to derive at a contradiction.   I've considered the image $\{Tx_n\}$ of a sequence $\{x_n\}$ in $\overline{B}_1(0)$ which has no cauchy subsequences, using that $L_2(0,1)$ is a infinite dimensional complete NLS. I've tried to show that neighter the sequence $\{Tx_n\}$ can have any convergent subsequences, but this failed.  Then I tried to show that if there is no $\epsilon > 0$ and no $x\in {T\overline{B}_1(0)}$ such that the closed ball $\overline{B}_{\epsilon}(x)$ is fully contained in the image of $T$ then ${T\overline{B}_1(0)}$ can not be compact, but I can't seam to make the argument. Sadly, since othervise, the implication $\overline{B}_{\epsilon}(x)$ is a closed set of a compact set would result in a contradiction. (Since $\overline{B}_{\epsilon}(x)$ is not compact since $L_2(0,1)$ is not finite) My last effort was considering the inverse of $T$ restricted to ${T\overline{B}_1(0)}$, I managed to show that $T$ is one to one and hence the inverse welldefined, but it seams to fail to be bounded and hence the desired contradiction failed. (The contradiction being $\overline{B}_1(0)$ is a continous image of a compact set.)   Now, I turn to you for help! Preferably, also with some comments on my different approaches... Can you find a proof in any of these lines or is it not possible?   I also must add that I may not use the theory of Hilbert spoaces because we have not yet reached those sections in my course! So for example there is no use proving that $T$ is not the limit of finite range bounded operators...

Suppose we have an bounded linear operator A that operates from $L^2([a,b]) \mapsto L^2([a,b])$.  Now suppose that $A(f)(t) = tf(t)$.    Is A compact?  Edit: I know $A = A^*$ but I'm not really sure how to start on this.  It's not homework, just summer fun :D


A  was raised on MSE:  I am still seeing notifications of edits on a post I followed, which was deleted:   at  states that:  Going forward, you should be able to unfollow deleted posts from both the question page itself and from the "Following" tab on your user profile.  But right now, neither the followed and deleted post nor the "Unfollow" button are showing up in my Followed posts tab.  Those with the  privilege will not be bothered by this problem, owing to the fact that they can see deleted posts, but those of us who don't have that privilege can't. As the ability to unfollow deleted posts from the Following tab existed before, assuming the quote above is accurate, could we reinstate that ability?  UPDATE The  this question was duplicated to is now marked , but I am still unable to unfollow a deleted post from my "Followed Posts" tab, so I'd like this to be reopened.  See  at the duplicate for more details.

I can't unfollow a deleted post. This may be a regression, or a corner case which has not yet been reported. I have very low rep on Economics (currently 105) and my "Following" tab simply says I have no questions which I follow:  And yet I have received multiple inbox notifications for a question I followed which was then deleted, and which has apparently then still been edited by its author:  I  and Glorfindel helpfully pointed me to  but ... it doesn't work; as reported above, I don't see the post in the Followed tab. The "solution" at  does not work; it only fixes it for users who have the privilege to see deleted questions in the first place.


At this time I am running technology related blog and I'm tired of it because of writing only tech related articles, because of this reason I want to make a blog on sub-domain of root domain where I'll share stuff that I like and mostly stuff that make me feel good. Its content is totally going to be different from root domain's. Is it secure to make another blog on sub-domain of my main blog or should I buy new domain name. Thing is, I want to stick with my old domain name.  I am going to make a sub-domain like this fun.domain.com  I read somewhere that Google treat sub-domains as spam. Because it could be used to takeover search results by making too much subdomains e.g. About.com have different sub-domains for different categories but Google don't take it as spam.  Update: Thanks for letting me know about another question about this topic. . It answered my question but I want to know little more if anyone can help.

If I have example.com, and blog.example.com, do search engines see those as one site or two? Will using subdomains hurt SEO? I have some technical reasons why I can't use example.com/blog.


Is there a way to disable lock screen notifications at startup? Reason I am asking is that every time I boot up my laptop, I get the "printer added" notification, and it gets incredibly annoying. Disabling printer notifications and lock screen notifications does NOT work (it only works after login, which defeats the purpose) I have tried to see if the printer added notification could be fixed as a bug, but the bug report has since been ignored...

I've just upgraded to Ubuntu 17.04, using the GNOME desktop. Suddenly, I've started seeing 'printer added' notifications as OSD popups - approximately every 2 minutes! It's really distracting.  Anyone have any idea how I can either stop them at source, or at the very least filter them out from the OSD notifications?


EDIT: This post was marked as "duplicate," which I think missed my original point. So I have clarified my question, and I hope it will be re-opened.  I recently came across a situation in which I needed random access to a collection of Python objects. The collection did not fit in memory, so I consulted the .   The documentation mentions two options for non-serial persistence:  and .   shelve is a Python-specific library that works with some kind of Unix built-in. (I'm not familiar with the specifics.) sqlite3 is a widely supported, highly dependable mini-database that is used all over the place.   So my first reaction was to use sqlite3, as it's highly flexible and has a rich ecosystem. But according to , storing pickled Python objects in sqlite3 is considered very bad form.  In the question marked above, it is noted that pickling data into sqlite3 prevents queries within that data. However, there's nothing stopping me from adding two, three, or many columns by means of which I could retrieve cross-sections of the data. shelve does not enable this.  To me, this presents a whole range of use cases that shelve simply does not offer. Nevertheless, in the post noted above, it is claimed that "doing this sort of thing is indicative of bad design," as well as a host of other judgmental statements.  My question is: why is this? Why is doing this a sign of unhealth? I can think of numerous use cases where I might want the flexibility and capacity of sqlite3 without the overhead of a full-fledged database system.

Any gotchas I should be aware of?  Can I store it in a text field, or do I need to use a blob? (I'm not overly familiar with either pickle or sqlite, so I wanted to make sure I'm barking up the right tree with some of my high-level design ideas.)


Let L be a linear transformation with a matrix M and K is a linear transformation with a matrix M^2. I need to prove that ker(L) ⊆ ker(K)

If $\vec{y} \in \ker(A)$ then $A\vec{y} = \vec{0}$ so that $(A*A)\vec{y}= A*(A\vec{y})=\vec{0}$ and $\vec{y} \in \ker(A*A)$.  If $\vec{y} \in \ker(A*A*\cdots *A)$, then $(A*A*\cdots *A)\vec{y}=\vec{0}$ so that $(A*A*\cdots *A^{i-1})*(A\vec{y})=\vec{0}$ so that $\vec{y} \in \ker(A)$.  Does this mean that the $\ker(A)=\ker(A^2)=\cdots=\ker(A^n)$?


My book says that:     A monoid is a set M equipped with a binary operation $.:M\times M\to  M$ and a distinguished unit element $u\in M$ such that for all    $x,y,z\in M$:      $$x\cdot(y\cdot z) = (x\cdot y)\cdot z$$ and      $$u\cdot x = x = x\cdot u$$      Equivalently, a monoid is a category with just one object. The arrows   of the category are the elements of the monoid. In particular, the   identity arrows is the unit element $u$   So, a monoid is a category with just one object. What it means exactly? $M$ has more than one object. Later the book cites $\mathbb{N}$ as being a monoid. Why?

I'm only in high school, so excuse my lack of familiarity with most of these terms!  A monoid is defined as "an algebraic structure with a single associative binary operation and identity element."   A binary operation, to my understanding, is something like addition, subtraction, multiplication, division i.e. it involves 2 members of a set, a single operation, and the resulting third member within that set. And an identity element is a special type of element of a set, with respect to a binary operation on that set, which leaves other elements unchanged when combined with things. Examples are "$0$" as an additive identity and "$1$" as a multiplicative identity.   How does this definition correspond to a category with a single object? What are some examples of monoids?


How come that the system partition is C:\ and not A:\ or B:\?  I know A:\ was used for floppy drives, but why not use B:\ then? And why was floppy drives used as A:\ as if it was more important than the system drive?  In regard of duplicate post I will paste the comment that has been posted below as it sums up what i think:  QUOTE Michael Kjörling:      I'm not sure I agree with that duplicate suggestion. The proposed duplicate asks "what and where are A: and B:?" while this question asks "why is the system partition labeled C:?". The two are certainly related, and answers are going to draw from much of the same knowledge, but the focus is different

In Windows you have a C-drive. Everything labeled beyond that is with the following letter.   So your second drive is D, your DVD is E and if you put in a USB stick it becomes F and the following drive G. And so on and so forth.  But then, what and where are A and B-drives?


I'm using the Auction module now. The Auction works fine, but there are no emails sent to users when they place a bid. When you insert your bid      Unable to send e-mail. Contact the site administrator if the problem persists.   When I create an account, then i get a email with instructions. Only by the Auction module the mails will not sent. I saw one topic:    But there was no good answer for me. I used this module

When my web form is filled and submitted, I get redirected to a page that says:     Thank you for submitting.   but theres a red warning box there that says:     Unable to send e-mail. Contact the site administrator if the problem persists.   I think its the SMTP server, but I don't know how to fix that.


Supposedly  only spawn between 640 and 1152 blocks from the origin and there are only three per world.  On the SMP server I play on, all that land has been explored for a very long time, so it obviously won't be regenerated unless somehow deleted.  Does this mean that the strongholds will never spawn?  Can they be generated in new chunks that are further out if they don't exist yet?

I'm a new Minecrafter, and was wondering if new updates are backwards compatible. Specifically, will the new "Adventure Update" features (Beta 1.8) appear in existing worlds created with Beta 1.7 and earlier? Or will I need to create a new world for this version?


I have a div with Gb/F# as id.  For example, and I'd like to make it visible/hidden using jQuery in this way:    var string= "Gb/F#" $("#"+ string).css("visibility", "visible");     But I got error because of that # in the id. How can I solve my problem? I can't even solve the problem in the css file to declare the div characteristics.

What characters/symbols are allowed within the CSS class selectors? I know that the following characters are invalid, but what characters are valid?  ~ ! @ $ % ^ & * ( ) + = , . / ' ; : " ? > < [ ] \ { } | ` #


In Python, if l1 is a list and if we assign l2 = l1 and change l1 directly to some other list by assigning it, then l2 will also change to the list that we assigned l1 to.  It is being the case that this can be avoided by using something like this.  l2 = list(l1)   or  l2 = l1[:]   or  import copy l2 = copy.copy(l1)   or  import copy l2 = copy.deepcopy(l1)   For my question,  I have a 4 × 4 grid of numbers within into some type of two dimensional structured list of table, that is being something like this:  ------------- | 0| 1| 2| 3| |--|--|--|--| | 4| 5| 6| 7| |--|--|--|--| | 8| 9|10|11| |--|--|--|--| |12|13|14|15| -------------   such that table[n/4][n%4] = n, for all values of n, 0 ≤ n ≤ 15.  The case that, I am trying out to solve a  4 × 4 size of board for its extended version of , a game in which one of the two players must (and then should) win definitely after 14 moves by using both of the two players, unlike the drawish version of Tic Tac Toe n × n size of board, for any value of n ≥ 3 only.  For solving within this very problem, for being writing into Python,  let win = [[0, 1, 2, 3], [4, 5, 6, 7], [8, 9, 10, 11], [12, 13, 14, 15], [0, 4, 8, 12], [1, 5, 9, 13], [2, 6, 10, 14], [3, 7, 11, 15], [0, 5, 10, 15], [3, 6, 9, 12]] that which essentially corresponds enough within into four horizontal elements, four vertical elements and two diagonal elements.  I have a list  line = [[]] * 16   For all values of i, 0 ≤ i ≤ 15, I will have to add win[item] within into line[i] if win[item] contains i.  Consider within this very following piece of code, for being written into Python,  for item in win:     for i in line:         line[i].append(item)   That is being simplifying within into,  it is being right now that,  why ever does line[i].append(item) add the structured list of item for all indices of structured list of line, values of indices, 0 ≤ index ≤ 15, but not only for the index i of structured list of line?  Why ever do these two very pieces of problem happen?  What ever are the alternative ways and then methods available, in order to resolve within this very following piece of issue, for being written into Python?  By making use of the same way only, I am only making use of database instead of dictionary, for the former's ability to store data in hard disk and continue computing at any period of time from its last saved state, and then I am trying to avoid using slower enough operations such as those like Multiplication, Division, Modulo and Power and making use of faster enough operations such as those like Addition, Subtraction, Logical And, Logical Or, Logical Not, Left Shift and Right Shift only.  Thank you in advance.

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


I have some jobs which I need to stop if the current server is secondary. I found this code  DECLARE @rc int set  @rc = sys.fn_hadr_is_primary_replica('DatabaseName') ; IF @rc = 0 BEGIN;     --Not Primary, exit job and terminate with error.     Print 'Not the Primary, ==>EXITING JOB';      DECLARE @name sysname;     SELECT  @name = (SELECT name FROM msdb.dbo.sysjobs WHERE job_id = CONVERT(uniqueidentifier, '$(ESCAPE_NONE(JOBID))'));      EXEC msdb.dbo.sp_stop_job @job_name = @name;     PRINT 'Stopped the job since this is not a Primary Replica'; END;   However, it is failing at SELECT @name = blah blah step giving an error 'Conversion failed when converting from a character string to unique identifier'.  Any help is truly appreciated.

I'm looking for best practice in dealing with scheduled SQL Server Agent jobs in SQL Server 2012 availability groups. Maybe I missed something, however at the current state I feel that SQL Server Agent is not really integrated with this great SQL2012 feature.  How can I make a scheduled SQL agent job aware of a node switch?  For example I have a job running on the primary node which loads data each hour. Now if the primary goes down, how can I activate the job on the secondary which now becomes primary?   If I schedule the job always on the secondary it fails because then the secondary is read-only.


I want to replace my hardly working vista with ubuntu.  I downloaded the 32 bit ubuntu from   I got it as a comressed file. I decompressed it using winrar.  i then followed some steps that i cant seem to find right now,wich basically just said   burn it to a cd and restart, but vista keeps booting.

I've never used Ubuntu before. Just heard from some friends. "IT'S GREAT!!!", they used to say. So i decided to try it. I downloaded WUBI, and ran it but 'twas takin' too much time. So I decided to download the .ISO Image file separately. It couldn't download more after 150 mB, and got interrupted (and cancelled) itself. I just went to , and further went to , and searched for my question. After having found a related one, which told     "try the torrent way"   So I downloaded it through the torrent. And after that when I opened the .rar file, there wasn't any .ISO image file; just some folders with names like .disc, boot, ISOLINUX, etc. I searched for the .ISO file but nothin' there: ANYONE HELP ME, PLEASE!!! or this will drive me into never thinkin' about Ubuntu again.


I wanted to ask a question, but another user had already asked the same 3 hours before. Now he doesn't get any answer, so I would like to offer a bounty, but I can't ask a duplicate question. Is there a way to offer a bounty ?

It's possible to offer and award bounties of reputation on questions.   What is a bounty? How can I find questions that have a bounty attached? How do I start a bounty? When can I start a bounty? Why is the system requiring me to choose a bounty amount that's higher than the minimum? Can I use Markdown formatting in the bounty remarks? Can I edit the remark? How long is the bounty period? How do I award a bounty? Can I award a bounty to my own answer? Can I award a bounty to an old answer? If I offer a bounty on someone else's question, can I award the bounty to their answer? After awarding the bounty, can I remove it or move it to another answer at a later time? What happens if there's no answer after the bounty period? What happens if I feel my question is still unanswered? What is automatic awarding? Are bounty awards exempt from the 200 points/day reputation limit? How does Community Wiki mode affect bounties? How does user deletion or post dissociation affect bounties? Can I award a bounty to an answer from a deleted user or one where the author was dissociated? Can I offer a second bounty after the first one has expired? Can I raise my bounty? What happens if a bounty question is closed or deleted? Why can't I vote to close or migrate a bounty question? What happens if I delete my account while I have an active bounty? Do I keep an awarded bounty when I delete my answer? What happens if a question where I awarded a bounty later gets deleted or migrated? Can I cancel my bounty? Can I affect / divide / share part of my bounty to two (or more) users? How many outstanding bounties can a single user have?      See also:  in the Help Center


I'm not able to figure out how to get any code coverage on an Apex HttpPost method. Apex class: @RestResource(urlMapping='/approve/*') global with sharing class exAppClass { jstcl__TG_Timesheet__c ts = new jstcl__TG_Timesheet__c();     // GET request    @HttpPost     global static String doGet() {     RestRequest req = RestContext.request;          String secid = req.params.get('id');       String approverId = req.params.get('appid');       String ipString = req.params.get('ip');       System.debug(secid);       String alreadyApproved = 'expired';       String error = 'error';       String success = 'approved';       String primApprover;       String secApprover;       jstcl__TG_Timesheet__c ts;       ts = [SELECT Id, jstcl__Week_Ending__c, jstcl__Status__c, jstcl__Placement__r.jstcl__SecondaryApprover__c, jstcl__Placement__r.jstcl__TimecardApprover__c FROM jstcl__TG_Timesheet__c WHERE Id = :tsid FOR UPDATE];       primApprover = String.valueOf(ts.jstcl__Placement__r.jstcl__TimecardApprover__c);       secApprover = String.valueOf(ts.jstcl__Placement__r.jstcl__SecondaryApprover__c);         if (ts != null && ts.jstcl__Status__c == 'Approved' && (primApprover == approverId || secApprover == approverId )) {         return alreadyApproved;       } else if(ts != null && ts.jstcl__Status__c == 'Submitted' && (primApprover == approverId || secApprover == approverId)){         try{             insertLog(ts, approverId, ipString);             ts.jstcl__Status__c = 'Approved';             update ts;            } catch(Exception e) {             System.debug('Exception caught: ' + e.getMessage());              return error;            }        return success;       }else {       return error;       }     }       private static Express_Approval_Log__c insertLog(jstcl__TG_Timesheet__c ts, Id approverId, String ip){       Express_Approval_Log__c log = new Express_Approval_Log__c();       log.Name = 'EAL '+ts.jstcl__Week_Ending__c;       log.Timesheet__c = ts.Id;       log.Approval_Date_Time__c= DateTime.now();       log.Status__c = 'Approved';       log.Timesheet_Approver__c = approverId;       log.IP_Address__c = ip;      try{         insert log;      }catch(Exception e) {         System.debug('Exception caught: ' + e.getMessage());         }        return log;   } }  Test Class (so far): @isTest private class exAppClassTest { @isTest static void exAppClassUnitTest() {  Test.startTest();  Contact con = new Contact(         FirstName='fname',         LastName = 'lname',         Email = 'email@gmail.com',         Phone = '9743800309');  insert con;  ts2__Placement__c plc = new ts2__Placement__c(); plc.jstcl__SecondaryApprover__c = con.Id; plc.jstcl__TimecardApprover__c = con.Id; insert plc; jstcl__TG_Timesheet__c ts =new jstcl__TG_Timesheet__c (); date mydate = date.parse('12/27/2009'); ts.jstcl__Status__c='Test'; ts.jstcl__Week_Ending__c=mydate ; insert ts; Express_Approval_Log__c log = new Express_Approval_Log__c(); log.Name = 'EAL '+ts.jstcl__Week_Ending__c; log.Timesheet__c = ts.Id; log.Approval_Date_Time__c= DateTime.now(); log.Status__c = 'Approved'; log.IP_Address__c = '12:12:123'; log.Timesheet_Approver__c = plc.jstcl__TimecardApprover__c;     insert log; RestRequest req = new RestRequest();  RestResponse res = new RestResponse();  req.requestURI = '/services/apexrest/exAppClass/';  //Request URL //req.requestBody = Blob.valueof(JsonMsg);  req.httpMethod = 'POST'; RestContext.request = req; RestContext.response= res; exAppClass.doGet(); Test.stopTest(); } }

This is a canonical question and answer developed by the community to help address common questions. If you've been directed here, or your question has been closed as a duplicate, please look through the resources here and use them to shape more specific questions. To browse all canonical questions and answers, including more unit test resources, navigate to the  tag.  This canonical question is intended to address several classes of common questions by providing a quick summary and links to comprehensive resources:   How is code coverage obtained and calculated? How do I increase my coverage?  Why can't I cover these lines? Why isn't the body of my loop or conditional statement covered?


What I Have: A static ArrayList which stores Integers. I add an Integer via reference to it and then I change the value but the value is not updated.  import java.util.ArrayList;  public class Main {      public static final ArrayList<Integer> integers = new ArrayList<>();     public Integer integer;      void addInteger(Integer i){         integers.add(i);     }      public static void main(String[] args) {          Main main = new Main();         main.integer = 3;          integers.add(main.integer);          main.integer = 4;          System.out.println(integers.get(0));      } }   Output: 3  Question: Why is the output not 4 ?  Further Question based on follow ups: What is really stored within the ArrayList ?  EDIT BASED ON THE ACCTPTED ANSWER:  Since integer is an Integer (and not an int) the 3 is autoboxed. The ArrayList stores actually Integer.valueOf(3).

I always thought Java uses pass-by-reference. However, I've seen a couple of blog posts (for example, ) that claim that it isn't (the blog post says that Java uses pass-by-value). I don't think I understand the distinction they're making. What is the explanation?


I want to download BitTorrent Sync to synchronize my Android and PC.  Question #1  What's the difference between download from  or ?  Since I'm not interested in register myself on Google Play, can I download an APK file from any site and run it with some sort of "double click" over the name of the file, in the same way as in Windows?   Question #2  After download a file where do I save it? In the smartphone RAM? In the SD Card?  Thank you

I downloaded the APK file for an app to my PC.  How can I install it on my phone?


Now, The azimuthal part of the Schrödinger's equation for a hydrogen atom (after separating variables) is: $$ \frac{d^2 \Phi}{d \phi^2} + m^2 \Phi = 0$$ Which has solution $A e^{im\phi} + B e^{-im\phi}$, but I often see people assuming $B=0$, why?

In Griffith's book, section 4.1.2, the angular equation for Schrödinger equation in 3D is expressed as $$\sin\theta \frac{\partial}{\partial \theta}(\sin \theta \frac{\partial Y}{\partial\theta})+\frac{\partial^2 Y}{\partial \phi^2}=-\ell(\ell+1)\sin^2\theta Y.$$ Using the separable solutions $Y(\theta,\phi)=T(\theta)P(\phi)$, he eventually arrived at $$\frac{1}{P(\phi)}\frac{\partial^2 P(\phi)}{\partial \phi^2}=-m^2$$ $$\frac{\partial^2 P(\phi)}{\partial \phi^2}=-m^2P(\phi)$$ where $m$ is a constant.  He then went on to say that the solution for $P(\phi)$ is $$P(\phi)=Ae^{im\phi}$$ instead of the usual $$P(\phi)=Ae^{im\phi}+Be^{-im\phi}$$ by saying that he allows $m$ to be negative.  How are the above two solutions equivalent? For a particular value of $m$, his solution to $P(\phi)$ will always be lacking an extra term $Be^{-im\phi}$, no matter whether $m$ is positive or negative.


I've read both that the speed of light must remain constant and that light is slowed down the greater the index of refraction. So does the speed of light actually get slower or does space-time warp to accommodate for the constancy of the speed of light?

So light travels slower in glass (for example) than in a vacuum. What causes light to slow down? Or: How does it slow down? If light passes through the medium, is it not essentially traveling in the "vacuum" between the atoms?


I have downloaded Chrome on 14.04 as .deb package. Whenever I try to install it, it gives error  "Dependency is not satisfiable".

I am trying to install chrome browser via command line.  I tried this:  $ apt-cache search chrome browser   The results show that the proper term is "chrome-browser," so I tried that:  $ sudo apt-get install chrome-browser   And then "Y" for the Y/n question.  But the installation threw errors.  Does someone see anything wrong with the commands I issued?


In the last scene at the diner in Men in Black 3 Agent K is humming a tune that is playing. Agent J is confused how he knows the song. What changed? What makes Agent K happier now than he used to be?

In MIB3, the proposed explanation for K's lack of emotion and human interaction can be traced to the happening at Cape Canaveral. When J goes back to change the otherwise altered past, K comes out more lively and joyful. As far as I know, though, the only thing that changed was that he killed Boris the Animal rather than arresting him, so what changed him so much for the better?  J's dad still died, if that isn't what devastated him, what did?


Give a proof by cases that shows that $n(n ^2 − 1)(n + 2) $ is a multiple of  $4$, for all integers $n$  I have already done case 1 where n is even. I am doing case 2 where n is odd and I'm a bit confuse how to finish off the problem..Uploaded a picture of my work.. Is this work sufficient enough to prove that it is a multiple of 4? The 6k would not have any affect of the result in general?   I feel it is wrong because of the 6k. Right now my thoughts are if (statement) is a multiple of 4, then (statement) is a multiple of 2 as well. And work from there.

Prove that $n(n^2 - 1)(n + 2)$ is divisible by $4$ for any integer $n$   I can not understand how to prove it. Please help me.


Since the integration of a function is the opposite of a the derivative of a function, and there are clear steps to follow when we want to find the derivative of a function, I thought there would be clear steps to follow too when we want to find the integral of a function.  What is it about finding the integration of a function that makes it impossible to come up with a guaranteed method to find it?  Edit: I am only considering elementary functions.

If a function is a combination of other functions whose derivatives are known via composition, addition, etc., the derivative can be calculated using the chain rule and the like. But even the product of integrals can't be expressed in general in terms of the integral of the products, and forget about composition! Why is this?


I am on a Raspberry Pi, and I am using a program called fswebcam, which allows you to take pictures with a webcam.  ~$ fswebcam image.jpg   That command if entered in terminal takes a picture and saves it to your computer, however I want to build a simple python program that can access the terminal and execute that same command as I have listed above.  I have tried to import os and use os.system('fswebcam image.jpg') But it isn't working for me.   How can I have python execute terminal commands?

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


The question is in the title "Is there an algebraic $a$ such that $\ln(a)$ is algebraic other than 1?" It was inspired by .   I don't see an easy answer, but might be missing something.

It's famously unknown whether the natural log of 2 is rational or not.  How about the natural log of other numbers. Is it known/unknown whether these are rational?  Obviously ln(1) is 0, and ln(2^n) is n*ln(2) (and is thus rational iff ln(2) is rational), but how about other cases?


What is derivative of $\sin\sqrt x$ using the definition of the derivative ?  The definition of derivative is:-  $$\lim_{h\to 0}\frac{f(x+h)-f(x)}{h}$$

The definition of derivative of a function $f(x)$ is $$\lim_{h\to0} \frac{f(x+h)-f(x)}{h}$$  Using this definition, the derivative of $\sin\sqrt{x}$ will be:  $$\lim_{h\to0} \frac{\sin\sqrt{x+h}-\sin\sqrt{x}}{h}$$  $$\lim_{h\to 0} \frac{\cos\left(\frac{\sqrt{x+h}+\sqrt{x}}{2}\right)\sin\left(\frac{\sqrt{x+h}-\sqrt{x}}{2}\right)}{h}$$  Now i got stuck. How to find the limit or simplify this expression?  I get intuition that we have to use $$\lim_{x\to0}\frac{\sin x}{x} = 1$$  but that too is leading no where. I am unable to remove h from denominator.  NOTE  I know the derivative of $\sin\sqrt{x}$ is $\frac{\cos\sqrt{x}}{2\sqrt{x}}$ using chain rule, but this exercise was given to us for practice using division quotient.


Apparently Google wants to break Gmail again: They switched off the old editor today for everyone and made  their new editor (see ) mandatory which does top-posting and allows no fixed text font.  How can I get the old plain text editor back? I found no config option for that.

Today, when trying to reply to a message in Gmail, I was told that there is a new reply mode and then it was automatically enabled. I find it difficult to use, and it doesn't let you reply to the message in accordance with the netiquette I'm used to.  How do I opt-out of this brand new reply mode? It wasn't there yesterday.


Where can I find the commands for the startup programs? The name part is easy but I have no clue about where the commands are. Browsing option does not help much. I'd like to have at start Chromium, Audio recorder, Focus Writer, SD card, Sound setting.  I am looking for the commands to enter in the command box of the Startup Applications. The question "How do I start applications automatically on login?" does not explain how to show the Main Menu.

How can I make an application automatically start when I have logged in?


I'm a high school senior and this question has been on my mind since 8th grade, since I've learned Euler's formula but I've thought about it a lot more recently. According to Wolfram Alpha:   How is this possible?????? In other words, if $$ e^{iπ} = -1 $$ $$ e^{2iπ} = 1 $$ $$ (e^{2iπ})^i = 1^i $$ $$ e^{-2π} = 1 $$ Where is the error in this reasoning?

$$e^{i} = e^{i2\pi/2\pi} = (e^{2\pi i})^{1/(2\pi)} = 1^{1/(2\pi )} = 1$$  Obviously, one of my algebraic manipulations is not valid.


Is there any way that i can put this calculation into the price result without decimal.    private void calculate() {      double b = Double.parseDouble(berat.getText().toString());      if (b <= 0.5) {         totalPrice1 = 7;         serviceFee1 = totalPrice1 * 0.2;         carierFee1 = totalPrice1 * 0.8;     } else {         totalPrice1 = b * 12.9;         serviceFee1 = totalPrice1 * 0.2;         carierFee1 = totalPrice1 * 0.8;     }  }   for example if i add 0.5 the price result will be in the carrier fee is 5.60000000000. I want that will be display as 5.60.

What I would like is a method to convert a double to a string which rounds using the half-up method - i.e. if the decimal to be rounded is 5, it always rounds up to the next number. This is the standard method of rounding most people expect in most situations.  I also would like only significant digits to be displayed - i.e. there should not be any trailing zeroes.  I know one method of doing this is to use the String.format method:  String.format("%.5g%n", 0.912385);   returns:  0.91239   which is great, however it always displays numbers with 5 decimal places even if they are not significant:   String.format("%.5g%n", 0.912300);   returns:  0.91230   Another method is to use the DecimalFormatter:  DecimalFormat df = new DecimalFormat("#.#####"); df.format(0.912385);   returns:  0.91238   However as you can see this uses half-even rounding. That is it will round down if the previous digit is even. What I'd like is this:  0.912385 -> 0.91239 0.912300 -> 0.9123   What is the best way to achieve this in Java?


I am having issues installing 12.10 on a laptop from bootable USB Drive 4GB FAT32. Also I changed order on BIOS to boot from USB.  But only I see is the black screen with  SYSLINUX 4.06 EDD 4.06-pre7 Copyright (C) 1994-2012 H. Peter Anvin et al _   I tried to install 12.10 into my older laptop using the same bootable USB drive just to be sure, and it's all works fine!   I have also trying different USB drives, but results were the same. So it looks like there is nothing wrong with my bootable USB drives. Something is wrong with my laptop, but I can't figure out what exactly, because it's very new and Windows7 boots and runs just great. I Googled but found nothing useful.   My laptop is really a small one:   Acer AOD270 Protcessor: Intel(R) Atom(TM) CPU N26OO 1.60 GHz RAM: 1 GB Windows 7 Starter 32 bit It has no CD drive   Any help would be really appreciated please.    Thank you guys for the help!   No, ekaj I am using Universal USB Installer-1.9.1.5 But I'll try your variant, maybe it works!  @ Arup Roy Chowdhury unfortunately it doesn't work. For a few seconds i saw the screen with some basic information about computer, and then it just stuck on this:  SYSLINUX 4.06 EDD 4.06-pre7 Copyright (C) 1994-2012 H. Peter Anvin et al

I am trying to install linux on my laptop, a Toshiba Satellite C6550-S5200. I did it once but something happened so I removed it then I had to destroy all data on hard drive so now I have nothing on it. Well I got a iso file burned to a CD and to a flash drive. With the flash drive I get.   SYSLINUX 4.06 EDD 4.06-pre7 Copyright (C) 1994-2012 H. Peter Anvin et al  With the CD it will start booting it but somewhere loading it up, the dots turn all orange and stay that way and my CD drive turns quiet.  Oh and some more info the images work because I tried loading them up on another pc and it worked just fine.  I manage to get the CD to boot I just had to let me pc boot up first then insert the CD and have it boot the CD then. Once I get done installing ubuntu it works fine but I have to leave the PC on 24/7 for if I turn it off the PC will freeze 5-10 seconds after booting back up no matter how I install it.


I changed the permission for /etc folder to 777 with chmod. When I try to run Sudo after that it refuses to work. I found a few fix, such as going to recovery mode to fix things but recovery mode is not an option for me as Grub is not loading at all. Even holding shift key or repeat Esc does not load Grub. I tried to update grub but again, that requires sudo!    r2d2@Sdnhbuz-r2d2:~$ sudo update-grub sudo: /etc/sudoers is world writable sudo: no valid sudoers sources found, quitting sudo: unable to initialize policy plugin

I needed to edit a .config file (which I know for a fact is not creating these problems, just to clear that up) and it wouldn't let me save it, so I took ownership of /etc and all contents with the command chown -hR username /etc and that let me edit the .config file but now whenever I try to install any packages or use any sudo commands, it doesn't work  (I've checked for errors in the sudo file in sudoers.d and there was nothing wrong with that).   So how do I return it to the previous owner?


I have a piece of land (vector) with, for example, potatoes and I want to make a grid for spraying. That means i need a grid with size 45mx10m with different values per box. Important is that the grid is parallel to one boundary of the vector. With Vector Grid the grid is always facing north. Could anyone help me?      Imagine this is the field. The grid should be parallel to the left boundary of the field. The size of the boxes should be the same size, exactly. Except the right side of course.

I have been using a process called "Create Polygon Graticule" to create a grid within a polygon with assigned row and column attributes. It is a SAGA tool which I have been running in QGIS. It generates a grid based on the extent of the input polygon with the cell running N to S and E to W. It would be better for my analysis if the direction of the grid was parallel to the longest edge of the polygon. For reference I have attached images of the current automated output and an output that I manually altered to align the grid with the polygon. The grids originally covered the entire extent of the polygon but have been clipped to show only the cell parts that are inside.    Above image is what the tool out puts by default.   This is an image of a grid that was edited manually to fit the necessary parameters.  My question is, is there a way to produce grids that are aligned such as the one in the second image in an automated fashion? I will need to generate grids for a few thousand polygons.


I try to prove that the power of any infinite set must be equal/bigger then the power of the natural א0.  I tried to show that for any infinite set there exists a subset of it, that its power is the power of the naturals.

Assuming the axiom of choice, it can be shown that every infinite set contains a countable subset. Also, it is my understanding that the proof of this statement requires at least countable choice - i.e., it is consistent with ZF that there exist infinite sets which contain no countable subset.  However, consider the following proof:  Given an infinite (i.e. not equinumerous to any natural number) set $S$, let $A_1$ be a set containing one element in $S$, and construct $A_n$ by adding to $A_{n-1}$ any element from $S$ not already in $A_{n-1}$. This can be done since $S$ is finite, so at no point is $A_{n-1}$ equal to all of $S$. We can construct every $A_n$ using only ZF, since we are only making finitely many choices. Now, define $f: \mathbb{N} \rightarrow S$ by defining $f(n)$ to be the unique element in $A_n \backslash A_{n-1}$. $f$ is injective since $f(n) \notin A_m$ for every $m < n$, so $f(n) \neq f(m)$. Hence, $f$ is an injection from $\mathbb{N}$ to $S$, and the image of $f$ is a countable subset of $S$.  My problem is figuring out where in this proof the axiom of choice is used. It seems the construction of the $A_n$'s can be done without AC, since we are only making a finite number of choices. The construction of $f$ involves choosing an element from $A_n \backslash A_{n-1}$, but since we have a systematic way for choosing (take the unique element in the set) that should be allowed. I know this proof must depend on the axiom of choice, but where is it used?