Consider $X \times Y$ for metric spaces $X$ and $Y.$  I'm trying to show that $d_E(p,q) = \sqrt{d_X(p,q)^2 + d_Y(p,q)^2}$ fulfills the triangle inequality, but I can't workout the algebra so that things fall into place and it is clear that $$d_E(p_1,p_3) \leq d_E(p_1,p_2) + d_E(p_2,p_3).$$  I avoided writing out everything that I have written on paper because it is messy, but here is a little bit:  Consider $$d_E(p,p'') = \sqrt{d_X(p,p'')^2 + d_Y(p,p'')^2}$$ and $$d_E(p,p') = \sqrt{d_X(p,p')^2 + d_Y(p,p')^2}$$ and $$d_E(p',p'') = \sqrt{d_X(p',p'')^2 + d_Y(p',p'')^2}.$$          It must be shown that $$d_E(p,p'') \leq d_E(p,p') + d_E(p',p''),$$ or that $$d_E(p,p'')^2 \leq (d_E(p,p') + d_E(p',p''))^2.$$  I then proceeded to expand it out via the square, and it became messy and not, in the end, clear that the left was less than or equal to the right.

I have the following problem:  Let $(S,d)$ and $(T,e)$ be two metric spaces. Their product space has underlying set $$S\times T=\{(s,t)|s\in S,t\in T\}$$ and metric $$m\big((s_1,t_1),(s_2,t_2)\big)=\sqrt{(s_1-s_2)^2+(t_1-t_2)^2}.$$ Verify that $(S\times T,m)$ is a metric space.  As for proving the triangle inequality, I made the following attempt:  \begin{align*} m\big((s_1,t_1),(s_3,t_3)\big)&=\sqrt{(s_1-s_3)^2+(t_1-t_3)^2}\\ &=\sqrt{(s_1-s_2+s_2-s_3)^2+(t_1-t_2+t_2-t_3)^2}\\ &\leq\sqrt{(s_1-s_2+s_2-s_3)^2}+\sqrt{(t_1-t_2+t_2-t_3)^2}\\ &\leq\sqrt{(s_1-s_2)^2+(t_1-t_2)^2}+\sqrt{(s_2-s_3)^2+(t_2-t_3)^2}\\ &=m\big((s_1,t_1),(s_2,t_2)\big)+m\big((s_2,t_2),(s_3,t_3)\big) \end{align*}  My friend has told me that I am making too large of logical jumps in the "less than or equal to" steps. Can anyone point out my error?  I know I need to use the established metrics, but I don't know how.


I am making a diagram using Tikz in an attempt to match the one below.    So far I have this:    My problem is that the two paths from each 'trigger' node going into the 'susceptibility' node only converge on the western side of it. How do I get them to converge in the middle of the gap like in the first image? My code for the paths is as follows:  \path[draw]     (trigger1.east) -| (susceptibility.west); \path[draw]     (trigger2.east) -| (susceptibility.west);   I understand that I need to have a path shape more like -|- rather than -| to achieve what I need, but I get an error saying 'cannot parse this coordinate' when using -|- . Is there any way to get a path with the -|- shape?  For context, I am using Overleaf.  This is my first time submitting a question here so please let me know if more info is needed or the images are broken.

It is easy to produce a path between two nodes consisting of a single horizontal and a single vertical line (from the manual):  \begin{tikzpicture}   \draw (0,0) node(a) [draw] {A}  (1,1) node(b) [draw] {B};   \draw (a.north) |- (b.west);   \draw[color=red] (a.east) -| (2,1.5) -| (b.north); \end{tikzpicture}   However, what if I wanted the same short syntax to produce a path between (a) and (b) using a horizontal line, a vertical line, and a second horizontal line. It isn't to difficult to calculate the intermediate points, but how could the following syntax be defined?  \begin{tikzpicture}   \draw (0,0) node(a) [draw] {A}  (3,1) node(b) [draw] {B};   \draw (a.east) -|- (b.west); \end{tikzpicture}


Why is the following sentence correct: "The forum was a success as it had generated a plethora of ideas."      Why is the sentence, "The forum was a success as it generated a plethora of ideas." not correct.

I have never had this problem before. But after seeing some questions posted on ELU, I started to doubt. I have been through links1, pages of grammar books2, a lot of questions3 posted here and ELU. I now still can't seem to understand how the past perfect is exactly used. The references sometimes even contradict each other.  What I had understood so far was      The past perfect is not necessary if we are not 'going back' to the earlier past, and simply moving from one event to another.   but I then saw a lot of other 'rules' including      If the sequence is clear, the past perfect is not needed.   which is slightly different, less 'narrow' and can be applied in more situations than the first ruleA, and      The past perfect is optional only when talking about an action at a specific time.   This is confusing. Can anyone here clarify things out please?    A For example, for  Doing the survey [completed] -> Showing the result      We showed the result of the survey we did.      If the second rule is applied, the sentence above is fine (the sequence is clear), but not if the first rule since we are not moving from any event to the next and possibly even going back.    1  and   2 Practical English Usage (2005) by Michael Swan, Collins Cobuild Student's Grammar (1991). Upper-Intermediate Cutting Edge.  3 including , , ,  etc.


sorry this seems to be a repeated question but it confused to why I can't get a drop-down box to differentiate between null and 0.  I have a drop-down box with some PHP which select a value from a database and assigns it to $user. The default value is null, but I then want to change it to a 0 or 2 (its for number of tickets, so null is I haven't assigned any, 0 is I don't want to give them any, and 2 is they get 2). Basically the code below doesn't distinguish between null and 0 and based on other posts I read I feel it should but obviously I'm missing something.    <option value="" <?php if( is_null($user)){ echo 'selected'; }?>>Not Set</option> <option value="0" <?php if($user === 0){ echo 'selected'; }?>>0</option> <option value="2" <?php if($user === 2){ echo 'selected'; }?>>2</option>   I have also tried  <option value="" <?php if($user === NULL){ echo 'selected'; }?>>Not Set</option> <option value="0" <?php if($user === 0){ echo 'selected'; }?>>0</option> <option value="2" <?php if($user === 2){ echo 'selected'; }?>>2</option>   and   <option value="" <?php if($user === ''){ echo 'selected'; }?>>Not Set</option> <option value="0" <?php if($user === 0){ echo 'selected'; }?>>0</option> <option value="2" <?php if($user === 2){ echo 'selected'; }?>>2</option>   Any help appreciated.  EDIT  var_dump($user) = string(1) "0"   This is the same where $user = NULL and $user = 0  on my local xampp  var_dump($user)=int(0) and var_dump($user)=NULL the same code is acting different on the live version.

What is the difference between == and ===?  How exactly does the loosely == comparison work? How exactly does the strict === comparison work?  What would be some useful examples?


I know that if a ray is incident at the medium boundary at critical angle, the ray after refraction moves towards the medium boundary. So, is it possible that if a ray is passed through the medium boundary, it will deviate towards the denser medium? if not then can it be called an exception of principle of reversibility of light rays. Please help me through this paradox.

A lot of textbooks and exam boards claim that light incident at exactly the critical angle is transmitted along the media boundary (i.e. at right-angles to the normal), but this seems to violate the principle of reversibility in classical physics.  How would a photon or ray travelling in the reverse direction "know" when to enter the higher refracting medium?  It can't know, so I conclude that such light is simply reflected?  Is this correct?


How do I format text here? I keep getting this message:        Please add some context to explain the code sections (or check that you have not incorrectly formatted all of your question as code).

Error Message:  Oops! Your question couldn't be submitted because: Please add some context to explain the code sections (or check that you have not incorrectly formatted all of your question as code).  How do I fix this issue? It says that I need to explain my code more when I try to post this as google-apps-script. I have explained almost every part of the code. Also, this code was posted previously and I just added a few extra lines with explanations. What do they mean by "context" function doGet() {   var app = UiApp.createApplication();   //Create listBox   var listBox = app.createListBox();   //Add items to listBox   listBox.addItem("item 1").addItem("item 2").addItem("item 3").setName("myListBox");   //Create hidden app   var hidden = app.createHidden().setName('hidden').setId('hidden')   //Create button handler   var handler = app.createServerHandler("buttonHandler");   // pass the listbox into the handler function as a parameter and the hidden widget as well   handler.addCallbackElement(listBox).addCallbackElement(hidden);    //Create flextable   var table = app.createFlexTable().setId("myTable");    //Create flex table style attributes     table.setStyleAttribute("border-style", "solid")     table.setStyleAttribute("border-width", "1px")     table.setCellPadding(1);      //Create flex table headers   table.setWidget(0, 0, app.createLabel("Product Type")).setStyleAttribute("color", "blue");   table.setWidget(0, 5, app.createLabel("Size"));    var button = app.createButton("+", handler);    // add all widgets to the app   app.add(table).add(hidden);   app.add(listBox).add(button)   return app; }  function buttonHandler(e) {   var app = UiApp.getActiveApplication();   // get the position (is a string)   var pos = e.parameter.hidden;   // initial condition, hidden widget is empty    if(pos==null){pos='0'};   // convert to number    pos=Number(pos);   var table = app.getElementById("myTable");   // add the new item at the right place   table.insertRow(pos).insertCell( pos, 0).setText(pos, 0, e.parameter.myListBox);   // increment position   ++pos;   // save value   app.getElementById('hidden').setValue(pos);   // update app   return app; }


is a  feature which states (XGtE, p. 43):     At 11th level, you gain the ability to pass between the planes in a   blink of an eye. When you use the Attack action, you can teleport up   to 10 feet before each attack to an unoccupied space you can see.   The  spell description states, in part:     A prison in the shape of a box can be up to 10 feet on a side,   creating a solid barrier that prevents any matter from passing through   it and blocking any spells cast into or out from the area.      When you cast the spell, any creature that is completely inside the   cage’s area is trapped. Creatures only partially within the area, or   those too large to fit inside the area, are pushed away from the   center of the area until they are completely outside the area.      A creature inside the cage can’t leave it by nonmagical means. If the   creature tries to use teleportation or interplanar travel to leave the   cage, it must first make a Charisma saving throw. On a success, the   creature can use that magic to exit the cage. On a failure, the   creature can’t exit the cage and wastes the use of the spell or   effect. The cage also extends into the Ethereal Plane, blocking   ethereal travel.   Can the ranger attack a location and thus teleport 10 feet outside the forcecage?

Can you take the Attack action without attacking, just to get any side benefits?  For example, Blade Flourish says:     Whenever you take the Attack action on your turn, your walking speed increases by 10 feet until the end of the turn [...]   In all examples the bard has a speed of 30 feet and does not have Extra Attack.  First relevant scenario:     The Bard and the enemy is 40 ft apart. If the Bard can take Attack action before spending all 30 ft movement, then he can reach the enemy and attack them with the added extra movement. If not, the Bard and the enemy are now 10 ft apart.   Second relevant scenario:     There is an enemy around the corner. The Bard might or might not know there is an enemy there. With the added movement from Blade Flourish, he will be able to walk around the corner and attack the enemy.   Third relevant scenario:     Same as second scenario, but he will only be able to walk around the corner without being able to attack. He does not know if he can reach to attack the enemy at the end of the turn.   Is taking Attack action allowed without being able to make an attack?


Querying a street on OSM may result in multiple matches for the same street if it spans a postal code boundary (i.e. parts of the street have different postal codes). How can all nodes for the street be retrieved? Is there an option to get the street geometry as GeoJSON or similar to use as map overlay to highlight the street?

I'm working on a game () where you build buildings along real world roads. Currently investigating a feature where a player who controls the most buildings along a street gets points based on the streets length.  The problem i'm having is that streets as humans understand them do not exist as data in OSM. The best way to get a street is to traverse the ways with the same names that are connected by nodes, taking some wild cards like roundabouts into account.   The main question is, can i get an entire street via OverpassAPI with a single query using one of it's ways osm_id or similar value? A street in this case is a series of ways with the same name connected by nodes.  Things that need to be considered are that many ways have the same name where we work, Sweden. Almost every major city has a Kungsgatan for example (Kings Street), so it's not simply a matter of getting a list of all the ways with the same name and calling it a street, they need to be connected with nodes.  Another issue is that there is to my knowledge any other reference or value that binds these ways together.   I can without a problem build function in my server that achieves this using multiple queries, but that seems not performance efficient and also i'd like to avoid making my own endpoints and changes to Overpass, if possible. Performance is also the reason i won't be making multiple calls like that from the client which will be running on a mobile device.


Last year I got a new Western Digital WD Blue 500GB HDD to replace my old drive. The first thing I did was to install latest Windows 8. While installing Windows 8 I created 3 partitions, C drive for the OS and others for storage. The OS partition is 120GB (which at the time I thought would be plenty big) but I'm now realizing its too small! I wonder if it's possible to re-size HDD partition without reformatting and re-install my Windows 8. So that is my question, Can i enlarge os c drive of my windows 8 without having to re-format?   I've used the Norton Partition Magic and Disk Management to make this happen but there doesn't seem to be any options to make it happen. Thanks for any help you guys can give regarding my question. I've worked hard to optimize my current install of Windows 8 and would hate to start all over again.

I have a 320GB hard drive currently partitioned as below:     A long time ago, a computer expert formatted my hard drive like this because I wanted to install Ubuntu. I'm now ready to do this, but I'll never need so much free space (103.09GB). I want to enlarge the D:\ volume because it already has lots of data on it.  I know that when I open diskmgmt.msc, I could possibly enlarge the D:\ volume using some free space from the unformatted 103.09GB volume, because the program offers me the option to enlarge. However I'm afraid that I might lose data doing this.  Is it possible to enlarge the partition with this Windows 7 tool or am I better using GParted via "Try Ubuntu" on my Live CD? Would either of them cause data loss in this scenario?


As seen in the image below, the numbers (which represent seconds left for a timeout to end) are chopped off.  They start as a whole from the bottom left corner, but are chopped off on the way, first at a higher speed, and then slowly such that at the end, only the o of 6 or 8 remains visible.

The time out countdown which is flying in is missing half of the number.  Note the 33 here:        Can this be fixed please?


I was providing an install directory for SteamCMD to install a server to, but it created a "~" directory as the parent directory for the directory I wanted.  Example: /home/steam/SteamCMD/~/ArkSurvivalServer/  I can't get into the server directory.  Any help?

I was trying to test out this buggy/new tool to see how it works, and it prompted me to choose a directory to use for stuff I am doing. From the directory ~/Code/indep, I typed in ~/Code/indep/tarbell. (Stupid, I could have just typed 'tarbell', but whatever.) It prompted me to create it because it didn't exist, I said yes. When I inspected the contents of this directory, here is what I see:  brian@navis:~/Code/indep$ ls ~ project1 project2 project3 ...   I thought "oh, weird, it created a symlink to ~". However:  brian@navis:~/Code/indep$ file ./~ ./~: directory   file thinks it's a directory.   brian@navis:~/Code/indep$ ls -l drwxr-xr-x 3 brian brian 4096 Nov  8 16:50 ~ drwxr-xr-x 8 brian brian 4096 Oct 14 18:42 project1 drwxr-xr-x 3 brian brian 4096 Sep 10 21:15 project2 drwxr-xr-x 5 brian brian 4096 Oct 14 19:33 project3 ...   And so does ls -l.   I thought, "oh, ... is it a hard link? I've never really used those." But I tried to reproduce, and it's impossible to create a hard link to a directory. So... I guess I've narrowed this down to things I don't understand. Did I mount my home directory in this other directory somehow?   My main goal at this point is to remove the reference to my home directory in this folder (rm doesn't seem like the answer), but I'm also curious to know what's going on.  EDIT:   In retrospect, I understand exactly what happened. As was answered below, the program created a directory called "~" inside my current directory. The only really obfuscating fact about this is that I wasn't consistent with how I was actually viewing what the directory was. Sometimes I referred to it as  "~" and sometimes as "./~". It's only if you do the latter that you can actually see what's going on, but until I understood this, I was conflating what I was seeing from using the absolute path of "~" to to what was in fact a local directory.


I'm assisting a daily phone meeting with people from Asia, Europe and North America. One of the Americans is using "Sir" sometimes to address the team leader. Is it appropriate to address a colleague in the same job rank, by "Sir"?

According to Wiktionary:  Noun sir or Sir (plural sirs)  A man of a higher rank or position. An address to a military superior. Yes sir. An address to any male, especially if his name or proper address is unknown. Excuse me, sir, could you tell me where the nearest bookstore is?   I assume you'd not use this for young boys for example, and certainly not for girls or women. In what circumstances are sir the right one to use, and are there alternatives when it's not?


I don't understand how we could bruteforce a symmetric cipher. Let's take AES with a key size of $128$ as an example. It means that there are $2^{128}$ possible keys, and as many ways to decrypt a ciphertext $c$. Given that there are so many different keys, it is theorically possible to decrypt $c$ into multiple plausible messages (e.g. message that read like english). So while we are bruteforcing $c$, if at some point we obtain a plausible message we can't tell for sure that we found the good key because there are plenty of other plausible messages that we haven't found yet. It's not like with hash functions or asymmetric ciphers, where we have a way to make sure that we found the good antecedent/private key. So I don't understand what they mean in this article:  For example:  For instance, Triple DES was designed to have a $168$ bit key, but an attack of complexity $2^{112}$ is now known (i.e. Triple DES now only has $112$ bits of security, and of the $168$ bits in the key the attack has rendered $56$ 'ineffective' towards security).  Even if Triple DES only had 50 bits of security, we would still be able to decrypt multiple plausible messages that are not the original message, let alone the case where the original message is gibberish and not necessarily natural language. I feel like the notion of "security level" is not the same for hash functions/asymmetric ciphers and symmetric ciphers. For both, it refers to the subset of the antecedent/key space that we know the good antecedent/key is in, but for the latter, we can never be sure that we have found the good secret key, and thus that we bruteforced successfully. Could you explain it to me please? Thank you for your help.

I am wondering whether there is a bulletproof way to know if one is successful in decrypting a file.   As an example, say I encrypt a text file and protect it with a 3 letter password. I use brute force to decrypt it, but two different passwords lead to a file that contains English intelligible text. Is there a way for me to know which one is the original one? In other words, is there an infallible way to know I've entered the password correctly?


Within the Star Wars Extended Universe, there is a science base on a small object within a near impenetrable sphere of Black Holes. These Black Holes remain in roughly the same position and, according to the books, have remained there since discovered. Is this possible?  The place referenced is called the Maw Installation

Imagine a sphere of black holes surrounding a piece of space. Will this piece be separated from the rest of normal spacetime (at least for some time, till these black holes finally attracted themselves).  So, seen from the outside, we have a black hole, but with a non-singular interior.  Is this possible?


We know that inside a semiconductor diode, there is an internal electric field from the N side to the P side. This implies that the N side is at a higher potential than the P side of a semiconductor diode. Thus, if we connect the two terminals of a diode with a simple wire then the current should flow, but my textbook (Concepts of Physics - H C Verma) says that the current will not flow. The reason is not explained in the book. Could somebody explain to me, why the current will not flow when it seems it should? Following diagram shows the internal electric field and corresponding potential barrier.

I know this question sounds silly, as if there was a potential difference a current would be created when the terminals are connected together and this would mean energy has come from somewhere.  The reason I ask this though is that from my understanding of the depletion region and built in potential of a diode it seems like if you connected a voltmeter across the whole diode it would show the value of the built in potential.  This is explained in the image below:    At first, electrons flow from the n type to the p type because there are a higher concentration in the n type, and holes do vise versa. This is called the diffusion current. The first electrons and holes to cross the pn boundary are the ones which are closest to it; these carriers recombine when they meet each other and are then no longer a carrier. This means there is a depletion region of no carriers near the pn boundary. because electrons have left the n type material, and holes have left the p type material, there is a surplus of positive and negative charge on the n and p side of the pn boundary respectively. This causes an electric field that opposes the diffusion current, and so no more electrons or holes cross the boundary and combine. In short, only the electrons and holes near the boundary combine, because after they have done that an electric field is formed that prevents any more carriers from crossing. The current due to this electric field is called drift current, and when in equilibrium this will equal the diffusion current. Because there is an electric field at the boundary (pointing from the positive charge to the negative charge) there is an associated voltage. This is called the built in potential.  If you sample the electric field at each point along the diode from left to right, you would start with 0 in the p region because there are an equal number of protons and electrons. As you approach the depletion region you would see a small electric field pointing back towards the p region, caused by acceptor impurities which now have an extra electron (due to recombination) and therefore now have a net negative charge. This electric field would increase in strength as you get closer to the boundary, and then die away as you get further away.  This electric field means there is a voltage, as shown in graph (d). The p side is at an arbitrary potential, and the n side is at a potential higher than this because there is an electric field between them. This means there is a potential difference across the depletion region; this is known as the built-in potential.  But why when I connect a volt-meter across the whole diode will I not see this built in potential?  Edit:  I've also asked this question on another  And they say that the reason is because the net potential difference across the diode once it has been connected to a wire or volt meter is zero, because a metal-semiconductor junction has an electric field between it, and the overall effect of the electric fields at the junctions of the m-p-n-m materials results in zero potential difference.  Regardless of the fact that voltage does not equal electrostatic potential difference, can you please confirm that there is also no net electrostatic potential difference across a diode connected to a wire or volt meter because of the m-s junctions? I'd like to get a physicists answer on this, to see if this is the truth or just a simplified explanation to make it easier to accept.


Currently i'm getting a DDoS attack directly to this URL: myserver.com/?task=randompost, the "?task=randompost" doesnt exist anymore so they get redirected to the home webpage. Considering that they are attacking directly to that url path, its there any way to block all users that tries to enter that path??  Thanks!

This is a  about DoS and DDoS mitigation.   I found a massive traffic spike on a website that I host today; I am getting thousands of connections a second and I see I'm using all 100Mbps of my available bandwidth.  Nobody can access my site because all the requests time out, and I can't even log into the server because SSH times out too!  This has happened a couple times before, and each time it's lasted a couple hours and gone away on its own.  Occasionally, my website has another distinct but related problem: my server's load average (which is usually around .25) rockets up to 20 or more and nobody can access my site just the same as the other case.  It also goes away after a few hours.  Restarting my server doesn't help; what can I do to make my site accessible again, and what is happening?  Relatedly, I found once that for a day or two, every time I started my service, it got a connection from a particular IP address and then crashed.  As soon as I started it up again, this happened again and it crashed again.  How is that similar, and what can I do about it?


Is it possible to use  offline, or some way to implement an offline solution?

Can Cognito form work offline? I need a form that works both online and offline. When offline, user can still fill in the form. Data is stored in the app and be sent to database once the iPad is connected to internet again.  Can Cognito form be embedded in iPad app?


I made a bootable Ubuntu 16.04 64 bit USB drive using the startup disk creator utility on an Ubuntu 12.04 32 bit computer. The final message of the startup disk creator utility said that the bootable drive is successfully created and I can use it. When I boot my other 64 bit computer using this Ubuntu 16.04 64 bit USB drive I get the following message:   What could be the problem?

I downloaded Ubuntu 14.04 (64 bit) lts. I made a bootable usb stick. But I keep receiving this error message upon booting:  SYSLINUX 4.04 EDD 20110518 Copyright (C) 1994-2011 H. Peter Anvin et al Unknown keyword in configuration file: gfxboot.c32: not a COM32R image


Please make me understand why does it happens. When I try to determine run time of my methods, the first one is always more slower than second. Even if I will change order of methods and their invokes, the first one will always be slower.  import java.util.Arrays;  public class FindTheUniqueNumber {      public static double findUniq(double arr[]) {         Arrays.sort(arr);         if (arr[0] != arr[1])             return arr[0];         else             return arr[arr.length - 1];     }      public static double findUniq3(double[] arr) {         Arrays.sort(arr);         return arr[0] == arr[1] ? arr[arr.length-1]:arr[0];     }      public static void main(String[] args) {         final long endTime, startTime = System.nanoTime();         findUniq(new double[]{ 1, 1, 1, 2, 1, 1 });         endTime = System.nanoTime();         System.out.println("Code took "+(endTime-startTime)+" nano seconds");          final long endTime2, startTime2 = System.nanoTime();         findUniq3(new double[]{ 1, 1, 1, 2, 1, 1 });         endTime2 = System.nanoTime();         System.out.println("Code took "+(endTime2-startTime2)+" nano seconds");     } }   and results are like  Code took 357969 nano seconds Code took 5103 nano seconds   Doesn't matter which one I invoke first. As fact it will runs much slower. Even if I made the methods identical.

How do you write (and run) a correct micro-benchmark in Java?  I'm looking for some code samples and comments illustrating various things to think about.  Example: Should the benchmark measure time/iteration or iterations/time, and why?  Related:


I know that the escape velocity exceeds the speed of light but, what stops a rocket which can thrust constantly from returning, like, to escape earth we don't have to exceed escape velocity if we have constant thrust.

I understand that the event horizon of a black hole forms at the radius from the singularity where the escape velocity is $c$. But it's also true that you don't have to go escape velocity to escape an object if you can maintain some kind of thrust. You could escape the earth at 1 km/h if you could maintain the proper amount of thrust for enough time. So if you pass just beneath the event horizon, shouldn't you be able to thrust your way back out, despite the $>c$ escape velocity? Or does this restriction have to do solely with relativistic effects (time stopping for outside observers at the event horizon)?


I am new to Mockito framework, and I am working on writing tests for the class containing ElasticClient. Below is my actual method: @Service @Slf4j public class CreateIndex {      private final RestHighLevelClient elasticClient;      @Autowired     public IndexService(final RestHighLevelClient elasticClient) throws IOException {         this.elasticClient = elasticClient;     }      public boolean createIndex(String id, String index) {         try {             IndexRequest request = new IndexRequest(index);             request.id(id);             elasticClient.index(request, RequestOptions.DEFAULT);             return true;         } catch (IOException e) {             log.warn(e.getMessage());         }         return false;     }  My test code looks like this: public class TestCreateIndex {    CreateIndex createIndex;     @Mock     RestHighLevelClient elasticClient;     @Rule     public MockitoRule rule = MockitoJUnit.rule();     @Before     public void before() throws IOException {         createIndex = new CreateIndex(elasticClient);     }  @Test     public void TestCreateIndex() throws IOException {             IndexRequest request = new IndexRequest("1");             request.id("1");             Mockito.when(elasticClient.index(request,(RequestOptions.DEFAULT))).thenReturn(indexResponse);      } }  For the line Mockito.when(elasticClient.index(request,RequestOptions.DEFAULT )).thenReturn(indexResponse);(RequestOptions is some Class), I am getting below error: java.lang.NullPointerException: Cannot invoke "org.elasticsearch.client.RestClient.performRequest(org.elasticsearch.client.Request)" because "this.client" is null      at org.elasticsearch.client.RestHighLevelClient.internalPerformRequest(RestHighLevelClient.java:1514)     at org.elasticsearch.client.RestHighLevelClient.performRequest(RestHighLevelClient.java:1484)     at org.elasticsearch.client.RestHighLevelClient.performRequestAndParseEntity(RestHighLevelClient.java:1454)     at org.elasticsearch.client.RestHighLevelClient.index(RestHighLevelClient.java:871)   Not sure, how to mock elasticClient properly. Please help.

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'm using Windows 7 SP1. Recently I feel it runs slower and slower. The applications do not consume much RAM, so I guess some services do. How can I see the memory consumption by each service?

In windows 7, is there a way (by using common interface or a custom utility) to know how much memory a specific windows service is using ?   It seems most services are hosted by svchost.exe processes ( some svchosts.exe processes seems to host tons of services). While it is possible to know which services are hosted by a specific process, I found no way to get information about how much memory a service take.


I have a Lollipop AOSP ROM without any Google related service (Google Play is missing also).  To get Google Play working it seems(but I'm not sure) that I need to install:   Google Play apk Google Services apk Google Services Framework Google Login Service   I have also read that I have to convert them into system apps. My device is rooted so it should not be too difficult to convert these apps into system apps, but I have no idea of where I could find the updated version of the needed files. I have only found some tutorial for old kindle devices with an older OS.  Could someone help me to find updated version of needed files for Lollipop 5.1?  Any other solution is welcome.

I have recently installed a custom ROM and cannot find the Play Store. It seems like all apps that belong to Google are missing.  How can I install the Google Apps Package (Play Store, ...) on my Android device?


In microsoft word it can't understand every mathematical equation that I input in latex correctly.the only language that it understands correctly is the mathml code. But to do so I have to input the equation in latex to this script in a notepad [example]  <html> <head> <title>MathJax TeX Test Page</title> <script type="text/javascript" async src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS_CHTML"> </script> </head> <body> Your test: $$\mathbf{F}_{2}=k \frac{q_{1} q_{2} \hat{\mathbf{r}}_{21}}{r_{21}^{2}}$$ </body> </html>   then I have to save this file as a HTML file.Then I have to open the file in chrome and when the equation appears I have to extract the mathml code[by right clicking the equation and selecting to show the code].Then when I paste the code in word as keep text only,then it gives the exact equation. Is there any easier way like a software or an online converter to convert latex into Mathml code[not mathml]? thank you

As far as I understand there are two ways to display LaTeX on the web:   The MathJax JavaScript library, which allows you to embed LaTeX directly within HTML tags, but such LaTeX is converted by MathJax to MathML, an XML format which browsers can understand, unlike LaTeX. The disadvantages of this approach is that MathJax support for LaTeX is limited (and perhaps it would be useful if someone could outline some of its most important limitations). Use a command-line tool to convert LaTeX to MathML (I've found , but wonder if there is a command line tool I can install on Linux or Windows or better on both). Apparently, this solution has fewer limitations. I would like to know what the best tools to use for this conversion are, and whether MathML has any limitations as far as the following go:    the MathML language's ability to encode everything that can be encoded with LaTeX syntax, and  any possible limitations due to incomplete browser support for MathML (judging from , Chrome support seems to be severaly limited compared to Firefox, but this also means that if a user of my site is not using Firefox, then they will not be able to see math properly, which is a real drawback!).    Furthermore, if there are any other approaches to displaying math on the web, without resorting to images and PDF files, then I would like to know about them, but I think the alternatives I mentioned are most likely the two and only most viable ones.


I Made some Random Int in C#    Random rnd = new Random();                 int guess = rnd.Next(0, 11);                  int guess1 = rnd.Next(0, 11);                    int guess2 = rnd.Next(0, 11);                 int guess3 = rnd.Next(0, 11);   but I don't know what should I do if I want to have not repeat Number ?!?! (Its for guess number game)

I'd like to generate unique random numbers between 0 and 1000 that never repeat (i.e. 6 doesn't show up twice), but that doesn't resort to something like an O(N) search of previous values to do it. Is this possible?


Hello how to show the following:  Observations $(X_1,X_2,..,X_n,)$ are i.i.d. over $[0,2\pi)$ with density  $f(x,\theta) = \exp[\theta_1\cos x + \theta_2 \sin x -c(\theta)]$ where  $\theta =(\theta_1,\theta_2) \in R^2$  Find an expression for the Fisher information $I(\theta)$ involving integrals and show that it is positive definite for all $\theta \in R^2$  Thank you!

Let $\theta \in R^{n}$. The Fisher Information Matrix is defined as:  $$I(\theta)_{i,j} = -E\left[\frac{\partial^{2} \log(f(X|\theta))}{\partial \theta_{i} \partial \theta_{j}}\bigg|\theta\right]$$  How can I prove the Fisher Information Matrix is positive semidefinite?


Basically I wanted to sort my arrays from higher humbers to lowe numbers using "Arrays.Sort". Sadly though I don't know how to sort it from higher to lower as "Arrays.sort" sorts those arrays from lower to higher.  Any suggestions?  Code:      double sortArrays[] = {         (float) probabilityOfFlush,         (float) probabilityOfFullHouse,         (float) probabilityOfOnePair,         (float) probabilityOfPoker,         (float) probabilityOfRoad,         (float) probabilityOfRoyalFlush,         (float) probabilityOfTriple,         (float) probabilityOfTwoPairs     };      Arrays.sort (sortArrays);     System.out.println(Arrays.toString(sortArrays));   Well, the output would be like this for an example:     [0.0, 0.18018017709255219, 0.36036035418510437, 2.3423423767089844, 2.882882833480835, 2.882882833480835, 4.504504680633545, 45.76576614379883]

I've got a large array of primitive types (double). How do I sort the elements in descending order?  Unfortunately the Java API doesn't support sorting of primitive types with a Comparator.  The first approach that probably comes to mind is to convert it to a list of objects (boxing):  double[] array = new double[1048576];     Arrays.stream(array).boxed().sorted(Collections.reverseOrder())…   However, boxing each primitive in the array is too slow and causes a lot of GC pressure!  Another approach would be to sort and then reverse:  double[] array = new double[1048576]; ... Arrays.sort(array); // reverse the array for (int i = 0; i < array.length / 2; i++) {      // swap the elements      double temp = array[i];      array[i] = array[array.length - (i + 1)];      array[array.length - (i + 1)] = temp; }   This approach is also slow - particularly if the array is already sorted quite well.  What's a better alternative?


I'm trying to enumerate over an array in C, much like pythons enumerate method.  static void enumerate(char *choices[]) {     int i;     int length = sizeof(choices)/sizeof(*choices);      for (i = 0; i < length; i++)     {         printf("[%d] %s\n", i, choices[i]);     } }   How I'd expect this to work is, create an array (or list): char *test[] = {"test", "testing}; then pass that array (or list) to the function: enumerate(test); and the expected output should be:  [0] test [1] testing   However when I try this, the output I'm getting is just the first item in the array:  [0] test    What am I doing wrong to where this will not work as I'd expect it to?

First off, here is some code:  int main()  {     int days[] = {1,2,3,4,5};     int *ptr = days;     printf("%u\n", sizeof(days));     printf("%u\n", sizeof(ptr));      return 0; }   Is there a way to find out the size of the array that ptr is pointing to (instead of just giving its size, which is four bytes on a 32-bit system)?


Using the boolean operator a lot creates a lot of junk vertices and edges that make it really difficult to clean up a model so my question is: is there a way to delete all vertices connected to one or less edges?

I have cut a hole in a plane, but I am left with some loose edges.  Is there an easy way to select and delete them all?  See this screenshot:    See this edges siting out with no face?


I've read   but I didn't get the answer I need. I want to run my PC using 3 monitors. This is my current situation:   I'm running a PC with Windows 8.1 NVIDIA GeForce 9600 GT with 2 DVI ports Motherboard ASUS P5Q3 Deluxe/WiFI-AP @n with no VGA/DVI ports (see more ). The PCIe slot is already used by the video card. 2 DVI monitors (currently in use connected to the video card) I do software development (Visual Studio, ReSharper, Chrome, etc) I don't play games    Since I'm planning to upgrade my PC in the future but don't want to spend more money since this PC will go away. What would be a good solution?   Can a use one of those splitter cables like ? (from 1 DVI to 2 DVIs) Should I buy a new decent video card? That I may use in the future when I upgrade my PC? Will my PC work if I buy a cheap video card to support the 3rd monitor?

Possible Duplicate:          My work PC has (as you can guess from the title) a single Geforce 9600GT card. According to the  for this card, both DVI ports are Dual-Link DVI. Both are currently in use on Dell 19" 1280x1024 screens. I'm running Windows 7, with Aero enabled, for what that's worth.  What I'm wondering is if I can use a standard DVI splitter cable to drive a third screen from one of the ports -- specifically a Samsung 22" 1680x1050. I'm really outgrowing the two-screen setup, and am strongly considering bringing in my home monitor (which is almost never used) to bolster my usable space. If I can't, then my alternative is to replace one of these Dells with that Samsung, to give me at least a "little" more space.  (Before you ask, there's probably no chance I can get my company to spring for a second video card and third monitor. Even if I could, it would not be politically expedient, as a number of my other coworkers are already pretty jealous at my setup.)


There is no clear and standard definition of a complex number, I recall a prof being at a loss when a freshman aske him what is a complex number.  I read somewhere that a great mathematicians was not ashamed to say, re the formula $e^xpi = -1$ I think, that nobody knows what it means , but they are proud of it, is that true?*  I suppose nobody has a clear answer, I am just asking to specify what is more or different from the regular operations on a vector field taken as a 360° circle, where points are identified by  cosine of the relative angle (real part) and sine (imaginary part)  Edit  The linked question/answer resembles only superficially my question. I stressed the crucial feature that the vector is defined by sin and cos and consequently obeys the rules of duplication etc of angles. I am not familiar with all details of that theory and I am asking , if any, about the differences. If there are none or minor ones, then complex numbers ar not numbers and not complex at all.  *I found the quote:      Benjamin Peirce, a noted American 19th-century philosopher,   mathematician, and professor at Harvard University, after proving   Euler's identity during a lecture, stated that the identity "is   absolutely paradoxical; we cannot understand it, and we don't know   what it means, but we have proved it, and therefore we know it must be   the truth   *

What is the relation  between complex numbers and vectors?  I have read in some places "a complex number a 2-dimensional vector".  One can easily observe that $i\cdot i=-1$ in complex multiplication like the cross product of vectors.    Is  vector only the generalisation of complex number to n dimensions?   Is there any fundamental difference between those two?


There are many waves and oscillations books out there that also include Fourier analysis but very few give the subject a thorough treatment, they just pass it in a few pages. If anybody has any sources(particularly books) that have Fourier analysis and particularly Fourier Transforms, I would appreciate if he could share his information with me.    Waves, Oscillations, Quantum Mechanics or Mathematics books are all ok if they have an intuitive Fourier analysis in them.

I'm taking a course on waves and oscillations using Crawford from the Berkeley series (out of print excluding international copies), and would like to know if anyone has any suggestions for a better book. We cover:    coupled oscillators, forced oscillators,  Fourier analysis,  traveling waves,    and some other topics. Any help with the topic would be appreciated.


I'm currently using the  with strong requirements on text with and text heigth. After compilation of my latex file I got a lot of warnings of the following kinds   Underfull \hbox (badness 10000) or Overfull \hbox (3.7778pt too wide)   for instance. As a consequence some black boxes appear at the end of some lines or in some diagrams of the generated pdf file.  How can I take care of these warnings ?  To be more specific, please find below a few lines of code that causes a warning "Overfull \hbox (3.778 too wide)":  $$\xymatrix{\underset{~}{Z}\ar[rr]^t \ar@{ >->}[dd]_*[@]{\hbox to 4pt{$\sim$}}_-{h\quad}&&X\ar[dd]^f\\&\circlearrowright&\\Z'\ar[rr]_u &&X'}$$ one has $$\xymatrix{\underset{~}{Z}\ar[rr]^t \ar@{ >->}[dd]_*[@]{\hbox to 4pt{$\sim$}}_-{h\quad}&&X\ar[rr]^r \ar[dd]^f&&Y\ar@{->>}[dd]^g\\&\circlearrowright&&\circlearrowright&\\Z'\ar[rr]_u&&X'\ar[rr]_{r'}&&Y'}$$   If I change the 4pt{$\sim$} by 8pt{$\sim$} then the warning disappears and the small undesired black box in the pdf file does too. However by incrementing to 8pt the \sim symbol is a bit too far above the arrow for my taste but it's not a big problem.  Do you have a better solution ? Especially for avoiding to make this change by hand in every single diagram where the problem occurs ?   Thanks

Often, TeX outputs underfull hbox and vbox warnings when running and in the generated log file. What are these and how can I get rid of them?


Which of the following sentences is correct? Could you use both? Why is this?  "That dress looks really good!" "That dress looks really well!"

Most of the time, I use good and well interchangeably. However, on many occasions I would find well or good a misfit. Please suggest the proper usage.


In AWS EC2, I am using Centos 7, I observe strange behaviour where a binary for Hashicorp Vault CLI (/usr/local/bin/vault) is available during boot to commands I run in user data.  It is also available for users normally.  However, if I run sudo -i it is not available.  If I run sudo su - root, then it is available! Why would a command be available in user data as root, but not if I try to login as root using sudo -i?

When I run sudo, what exactly happens to my environment?  When I run sudo command, it doesn't seem to see my or root's environment. For example, my path for both includes /usr/local/bin, but if I try to run one of the program's without the full path, it fails.  I thought sudo ran as root, and hence got root`s environment. Is there a different way that bash executes under sudo than under root or my normal user?  EDIT:  I have been using sudo -i lately, but recently it has been causing problems because my current working directory gets set to /root. This is as expected (sorta), but I still don't understand why sudo isn't recognizing my executables in /usr/local/bin.  EDIT:  I am running Fedora 15.


I happened to read a book and I saw the sentence : I was sitting between my mother and father But then I thought among would also fit the sentence: I was sitting among my mother and father I am actually unsure as both fit the sentence well and I also want to know their meaning and usage in sentences.

Consider the following two versions of a question:1   Version 1: What is the difference in meaning between "[to be] not invited" and similar negation forms?  Version 2: What is the difference in meaning among "[to be] not invited" and similar negated forms?    Personally, I think Version 1 might subtly suggest a Star Topology (see below) with the target sentence "[to be] not invited"at the center.  And Version 2 might subtly suggest a more free-form comparison like the Mesh or Fully Connected, with the target sentence simply "one among many":   Between approx equal "Star" and among approx equal "Fully Connected"?  Don't get me wrong: I do think this is quite subtle, not always applicable, and I don't think anyone would intuit such a "network topology" meaning without further explanation.   So the main question is, are both grammatically correct?  If yes, is there a semantic difference to choose one over another, perhaps as I suggested?  Or does the plurality aspect of between and among trump other semantic and stylistic issues?    1. In my question , another user provided a very helpful edit. However, the change of the word between to among prompted this question.


I've removed SSL from a website, permanently.   I would like Google (and other search engines) to pick this up ASAP as of course people will be seeing a warning/error in their browser when they click on the search engine result which still thinks my site is https://  Is there a way to tell Google and Bing that my site is no longer https://, other than simply submitting it for crawling again? Maybe some tool within their respective webmaster tools areas?  Thanks

I need to remove HTTPS results from Google search rankings for the domain A that has been redirected to another domain B. So domain A does not have any pages on it at the moment and it will not have in the future. Customers still go to Google and type company domain A, Google gives them HTTPS version of it as SSL certificate was installed at some point in the past. When they click on it (HTTPS version), redirection does not work as I can't redirect HTTPS but only HTTP.  So how do I remove or ask Google to remove HTTPS version? My client does not know whether HTTPS site was submitted through webmaster tools before and does not have any Gmail accounts for me to check what has happened in the past.


I am taking 2 pictures using:     Nikon D3400 APS-C sensor and an APS-C kit lens, 18-55mm set at 50mm   Nikon D850 full frame camera and a full frame lens 50mm that is designed for full frame Nikon camera   Both systems have lenses mounted on them that is specifically designed for them. I am NOT putting FF lens on APS-C camera nor I am putting APS-C lens on FF camera. Shouldn't both 50mm images taken by above 1 and 2 have same field of view? What am I not getting here? Please clarify.

I have a Canon 7D, which has a crop factor of 1.6x.  When using a Canon EF-S lens I get the focal length stated on the lens, when using a Canon EF lens I get the focal length times 1.6 when used on the APS-C body. At least that's what I thought.  I just compared two lenses:   Canon EF-S 15-85mm f3.5-5.6 Canon EF 70-200mm f4   .  The top photo is shot with the 15-85, the bottom photo with the 70-200 - both lenses are set to 70mm. Now why do they look the same?  I thought I would get 112-320mm (70mm*1.6 crop factor). What did I misunderstand about the crop factor calculation? Lightroom also displays the photos as having "70mm" and not 112mm.


I know there is something wrong with this but I don't know where. It's some kind of a math fallacy and it is driving me crazy. Here it is: $$-1= (-1)^3 = (-1)^{6/2} = \sqrt{(-1)^6}= 1?$$


Idea: I thought of using the Mean value theorem for integrals   It says that if $f:[a,b] \rightarrow \mathbb{R}$ and $g:[a,b] \rightarrow \mathbb{R}$ are two integrable functions, and if $g(x)$ does not change sign on $[a,b]$.  Then $\int_{a}^{b} f(x)g(x) dx = \alpha\int_{a}^{b}g(x)dx$ where $m \le \alpha \le M$ .  Now take $g(x) = x^n$ and the above problem reduces to $\lim_{n \rightarrow \infty} \alpha\int_{0}^{1}x^ndx$.  Now if we evaluate $\int_{0}^{1}x^ndx$ we get $\frac{1}{n+1}$ which whe $\lim_{n \rightarrow \infty}$ is taken gives $0$.  Is the approach correct?  Can the integral be evaluated before taking the limit?

I am trying to solve the following problem at the level of a senior undergrad analysis level. So, the problem is as follows: We are given a function $f$ which is continuous on the interval $\left [ 0,1 \right ]$, and the question is to find the limit: $$\lim_{n\rightarrow \infty}\int_{0}^{1}x^{n}f(x)dx\;.$$ The second part of the problem is to deduce the following limit: $$\lim_{n\rightarrow \infty}n\int_{0}^{1}x^{n}f(x)dx\;.$$  For the first part: I just did the following: For every $0\leq x< 1$: $x\leq M$, where $0< M< 1$. Then: $$\int_{0}^{1}x^{n}f(x)dx\leq M^{n}\int_{0}^{1}f(x)dx\;.$$ Then: $$\lim_{n\rightarrow \infty }\int_{0}^{1}x^{n}f(x)dx\leq \lim_{n\rightarrow \infty }M^{n}\int_{0}^{1}f(x)dx= 0.\int_{0}^{1}f(x)dx=0\;,$$ so $$\lim_{n\rightarrow \infty }\int_{0}^{1}x^{n}f(x)dx=\lim_{n\rightarrow \infty }f(1)\int_{0}^{1}1dx=f(1)\;.$$ Does that make sense? If not, please show me the correct one.  As for the second part, I have no idea what to do. Any help?


I downloaded the pistoleer font from this website  and i want to apply this font to my 3d text. When I click on the folder next to font and search for the pistoleer font, it is not there. Is there a way I can use this font?

Is there a way to select a typeface (I have 15,000 fonts) for a text object, or must I set type in AI and save as SVG, then import into Blender?


When I install my Xamarin-generated package with the terminal command from   sudo installer -pkg /path/to/package.pkg -target /   the place it actually gets installed is inconsistent, even from the same package.  Sometimes it goes to Applications. Sometimes it goes to   myProject/bin/debug   Sometimes it goes to  myProject/bin/Distribution/   What gives?

Is it possible to install a .pkg using a terminal ? (I wanted to install an app through ssh).


My problem is that after I export my meshes to Ue4 it shows me that the normals are flipped. I tried both way, flipped and not flipped normals. This is what I get every time. Any tips what I might be missing?

Hellow everyone.  I'm exporting simple tent model into Unity. I want both outside and inside of the tent to be 'visible'. I checked double-sided on the properties panel, but in Unity tent interior is still invisible. I can't just flip normals, because then outside of tent would be invisible. I know I could use Solidify, but it doubles vertices number, which is not good for optimalisation.  Is there any other way?


In my loose reading about category theory, categories are usually introduced in terms of sets, often with some structure (such as algebraic or topological), and functions between them that preserve that structure. I find this easy to intuit, and makes ideas like commutative diagrams easy to understand.  However, I know that categories can be much broader than this, even before we get into higher notions like functors and such, and that categories describing structured sets and the functions between them are only an important but small portion of them. Despite this, I find it hard not to unconsciously interpret diagrams and category theoretic statements in these terms unless I completely strip all meaning from the symbols and treat the whole thing as a purely syntactic game, and the times where I've seen people discussing categories where the morphisms aren't structure preserving functions have been very abstract and gone right over my head.  So what I would like are some simple, intuitive examples of things which can be described by category theory, but where -  A) The objects are not sets,  B) the morphisms aren't (possibly structure preserving) functions, or  C) both.  I've wanted to learn more about category theory for a while, but I've found I kept being held back by my lack of a strong, accurate mental model for the sorts of things categories can represent, in the way that I have a strong model for the ways sets work and the things they can represent.

I have encountered a statement in Lang's Algebra (Revised Third Edition, page 53) concerning morphisms of objects that seems strange to me: "In practice, in this book we shall see that most of our morphisms are actually mappings, or closely related to mappings."  I have always been under the impression that the terms 'mapping' and 'morphism' are synonymous in the context of categories. Perhaps it is just the case that Lang defines the two in a way that they disagree, but I can't find such an instance. Are they in fact different? If so, what is an example of a morphism that is not a mapping?


I bought some lights off of Amazon in both the "White" and "Warm white" options (). I think they are 3 V and operate at 15 mA, whatever that means. I want to wire the lights in a series/parallel circuit. Key:  Red: Positive Yellow: Negative / Ground Blue: Resistor (Green numbers are for ohms - See below) Green: Switch Grey: Lights with back numbers (Lights #3&4 are "White" and Lights 1,2,5,6,7 are "Warm White"). Purple: 9 V battery   The problem: Only some lights will light up. Some only partially light up, etc. (Note: this is when I had fewer resistors in weird spots, not relevant anymore) The solution: Add a resistor (Blue in diagram) Where I get stuck: What resistors do I need? The resistors that come with the lights (Labeled "5.1V-9V use") power one just fine (Like #5), but don't power the pairs well (Every light but #5). I think I need a 200 Ω (or maybe 180 Ω) resistor on the dual pair. And 390 Ω or 100 Ω on the single one. But I honestly have no clue, and each person I ask says something different. The ones I'm using now for the lights that work are, I believe, 100 MΩ, but that makes no sense.  Also, I have no clue what side goes first...   Can anyone help me figure out what resistor (and 5-band color) would be needed for both the 1 and 2 light combinations? I am not sure if the ones that came with the lights are the best or not. Thanks! I'm also brand new at this, so sorry if the answer is obvious.

So I'm trying to power 2 of these  together in series. I know that I have to add the voltage of the two lights together and get a resistor that restricts the power to that level. I have a 9V battery and the lights are 3V each. I brand new to all of this, and understand almost nothing, so any help would be appreciated. Can someone help me choose the correct resistor (And how to identify that resistor with the color branding thing) so two of those lights listed above can be wired in series? Thanks!


Actually this kind of too much to ask I think.  But I want to remove all files matching the extension ".sh"(current folder only) which I can do with below command:  find . -maxdepth 1 -type f -name '*.sh' -exec rm {} +   But still I want to keep file "cron.sh" in the current folder unaffected.  How can I achieve this in single command line ?

I need to remove all files with .gif extension except one file with name say "filename.gif". What is the optimal way to go about doing this in terminal?  The command rm *.gif removes all gif files including the file filename.gif.


I can't install any updates due to this disk space problem. Having reviewed various blog posts on this subject, I've understood that it has something to do with an accumulation of old kernels, but the solutions are not straightforward. Can anyone guide me to a tailor-made solution for my system (Ubuntu 16.04 LTS) ?  Output of sudo parted:  Model: ATA HITACHI HTS72323 (scsi) Disk /dev/sda: 320GB Sector size (logical/physical): 512B/512B Partition Table: msdos Disk Flags:   Number  Start   End    Size   Type      File system  Flags  1      1049kB  256MB  255MB  primary   ext2         boot  2      257MB   320GB  320GB  extended  5      257MB   320GB  320GB  logical                lvm   Model: Linux device-mapper (linear) (dm) Disk /dev/mapper/ubuntu--vg-swap_1: 4148MB Sector size (logical/physical): 512B/512B Partition Table: loop Disk Flags:   Number  Start  End     Size    File system     Flags  1      0,00B  4148MB  4148MB  linux-swap(v1)   Model: Linux device-mapper (linear) (dm) Disk /dev/mapper/ubuntu--vg-root: 316GB Sector size (logical/physical): 512B/512B Partition Table: loop Disk Flags:   Number  Start  End    Size   File system  Flags  1      0,00B  316GB  316GB  ext4   df -h | grep -v loop  udev 1,9G 0 1,9G 0% /dev  tmpfs 382M 11M 371M 3% /run  /dev/mapper/ubuntu--vg-root 290G 165G 111G 60% / tmpfs 1,9G 110M 1,8G 6% /dev/shm tmpfs 5,0M 4,0K 5,0M 1% /run/lock tmpfs 1,9G 0 1,9G 0% /sys/fs/cgroup /dev/sda1 236M 161M 64M 72% /boot cgmfs 100K 0 100K 0% /run/cgmanager/fs tmpfs 382M 68K 382M 1% /run/user/1000    @guiverc @mikewhatever @N0rbert @karel @vanadium  thanks for pointing out that an answer exists. I have read that answer but I wasn't confident about following the instructions, so I would appreciate one of you walking me through what needs to be done.

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.


Assume that the metric space (X, d) is not compact. Show that there exist a real-valued function like f which is continuous but not bounded.

Let $E\subset\mathbb{R}$ a non-compact set. Show that      i) Exists a continuous function in $E$ that is not bounded.      ii) Exist a continous and bounded function in $E$ that doesn't have   maximum.      iii) If $E$ is bounded then, exists a continuous function in $E$ that   is not uniformly continuous   I started writting one definition that I have doubt     Def: A set $E\subset \mathbb{R}$ is compact if and only if it is   closed and bounded.   If a set is non-compact then I can say that that it is not bounded or not closed?  i) $f(x)=\sqrt{x}$ is a continous function and it is not bounded.  ii) From the doubt that I have in definition, if a set is non-compact and it is bounded then it is not closed so doesn't have a maximum.  iii) I don't know how to find a example.


Facing a strange issue that a query runs incredibly slow (worse) when scalar variables are used as parameter.  Actual Query (Faster) - 9 secs  select   sum(v.sale_value) as col_0_0_,   sum(v.vat_value)  as col_1_0_,   sum(v.sale_fcy)   as col_2_0_,   sum(v.vat_fcy)    as col_3_0_ from my_view v where v.company_id = 1 and v.filing_year = 2018 and v.filing_month = 1;   Parameterized Query (Worse) - 16 mins  DECLARE @P0 int, @P1 int, @P2 int; SET @P0 = 1; SET @P1 = 2018; SET @P2 = 1; select   sum(v.sale_value) as col_0_0_,   sum(v.vat_value)  as col_1_0_,   sum(v.sale_fcy)   as col_2_0_,   sum(v.vat_fcy)    as col_3_0_ from my_view v where v.company_id = @P0 and v.filing_year = @P1 and v.filing_month = @P2;   Execution times for both queries were calculated by executing in command line client (IntelliJ Database console).  Query with this scalar variable is generated by our Hibernate Application as we've used setParameter(String name, Object value) to set the param values.  First, we suspected issue in hibernate generated query, but narrowed down to SQL Server query execution after identifying it as parameterized query using sys.dm_exec_cached_plans. Does query optimiser get confused when scalar variables are used?  In java code, we're setting the values as query parameters. In sys.dm_exec_cached_plans, the actual query is:  (@P0 int,@P1 int,@P2 int)select <columns> from my_view v where v.company_id= @P0 and v.filing_year= @P1 and v.filing_month= @P2   Note: my_view is pretty complex (nested views, group by, joins, order by, where clause...). We tried to compare the execution plans, but they're incredibly huge We are looking into it but might take some time.  If I run the slow query with OPTION (RECOMPILE), it executes in 9 secs.  SQL Server Version  Microsoft SQL Server 2012 - 11.0.2100.60 (X64)      Feb 10 2012 19:39:15      Copyright (c) Microsoft Corporation     Express Edition (64-bit) on Windows NT 6.2 <X64> (Build 9200: ) (Hypervisor)

[Salutations]  (check one)  [ ] Well trained professional, [ ] Casual reader, [ ] Hapless wanderer,   I have a (check all that apply)  [ ] query [ ] stored procedure [ ] database thing maybe     that was running fine (if applicable)   [ ] yesterday [ ] in recent memory [ ] at some point    but is suddenly slower now.  I've already checked to make sure it's not being blocked, and that it's not the victim of some long running maintenance task, report, or other out of band process.  What is the problem, what should I do, and what information can I provide to get some help?  [*Insert appropriate closing remarks*]


I was wondering how old Logan or James Howlett was in The Wolverine, not at the flashback but at the prime of the movie.

How old is Wolverine? Wasn't he in the civil war or something? It seems like movies keep showing flashbacks of earlier and earlier events.


This is really driving me nuts! Even Windows 10 went for this useless fashion in time reporting!!     How do I get Windows 10 to report exact time instead of this?

I'm trying to figure out exactly when I created a file. Windows 7 thinks I don't know how to subtract two times, and tells me it was created "1 hour ago." I need a little more detail than this, but I can't seem to find a setting to toggle this "feature" off.  Example below:


there is the whole recovery applications and commands . I actually need to delete some sensitive data permanently so nobody can access it anymore , no matter what application they use or commands they carry on , any help ??

Is there a way to make sure that a deleted file can not be recovered?   As you know, deleting a file by pressing shift-del or using trash doesn't mean that file is gone forever. It resides somewhere in the computer.  In day to day life, law enforcement or thieves use recovery programs to reveal our private data or something else.   They can recover all data that resides on hard disk, in RAM, and even USB.  To protect us from these people, what should one do? Which program should one use?  Note: I don't want an answer like first use a recovery program then erase that file with shred. With just one program, I want to erase all unused/deleted files on my computer.


I know that $f(x,y)=\sqrt{|xy|}$ when $(x,y)\neq{(0,0)}$ is differentiable since partial derivatives exist and they're continous. When I do by definition $f_x (0,0)$ and $f_y (0,0)$, both are equal to $0$. Due to "Sufficient Condition for the Differentiability of Functions", can I conclude that it is differentiable?  My problem is that I think it isn't diff. because of an analogy to single-variable $f(x)=|x|$, but not sure. Thanks.

I am trying to determine if the following functions are (totally)   differentiable at $(x,y)=(0,0)$.      $$f(x,y)=\sqrt{\vert xy \vert}$$      $$g(x,y)=e^{{{\vert x \vert}^3}y}$$   However I am not particularly sure where to start. The concept of the total derivative being the Jacobian matrix makes sense but I don't really understand how to work with functions that may not have a Jacobian matrix. Any help would be greatly appreciated!


I have an unrooted Galaxy Tab 10.1 (GT-P5113) running Android 4.2.2  I want to upgrade the Android version there, however, I have no idea how.  Right now the tablet claims it is up-to-date, but we all know it is not - Android 4.2.2 is old.  Samsung Kies refuses to upgrade the firmware with the message "gt-p5113 does not support initialising".  Is there a way to upgrade the Android version on this tablet (while still keeping it usable, obviously) ? Preferably without rooting, but I will root it if there is no other choice.  I am OK completely resetting it.

This Community Wiki question is designed to be the "canonical question" for questions asking how to upgrade one's device to a new Android version.   I want to get a newer version of the OS for my Android device. How can I do that?  See also:


I'm having a big doubt here regarding grid systems.  See, I have to design a medical dashboard application for a lot of devices: These are a 42 inch LCD screen, a regular computer screen (using 1200 as standard resolution), an iPad, and an iPhone.  My question is: I want a grid that has 10px gutters (that's very little so I'll probably make it custom), how should I standardize it across all devices?  Should I use a grid with the same columns and gutters and just take out column when the resolution gets smaller? Or should I get different grids for every device?

Twitter Bootstrap uses these break points for responsive design:  Large Display: 1200px Default: 980px Tablet: 768px Mobile: 480px  A client said they are using 1280px for their Large Display breakpoint.  Is there an industry standard for these or are they just made up as we go right now?


I have access to a Debian machine via SSH.  How do I find out what version of Debian is installed?  This is possibly a duplicate of .  That question is answered by:   lsb_release -a cat /etc/lsb-release   There is another answer in one of the comments:   cat /etc/debian_version   lsb_release -a does not work:  -bash: lsb_release: command not found   Nor does cat /etc/lsb-release:  cat: /etc/lsb-release: No such file or directory   I suppose that   cat /etc/debian_version   is the way to go as it gives me "8.1".  apt-cache show base-files    returns a bunch of properties including "Version: 8+deb8u1". How is the version of the base-files package related to the Debian version? I assume that the "deb8u1" part translates into "8.1". What does the first "8+" part mean then?  uname -a   returns  Linux deb2 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt11-1+deb8u2 (2015-07-17) x86_64 GNU/Linux   and  uname -rv   returns  3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt11-1+deb8u2 (2015-07-17)   How is the kernel version related to the Debian version? Does a specific Debian version always include the same kernel?  cat /etc/os-release   returns amongst other properties:  VERSION_ID="8"   So, for me "8" and "8.1" seem to be different. Is "8" the "generic Debian version"? How do you call "8.1" then ("full version"?) ?

Maybe this is a stupid question.  I would like to know how do I know what is the version of my debian system.  Thanks a lot


The definition of a primary ideal $P$ is : $ x y\in P $implies either $x \in P $or $y^n \in P$ for some$ n > 0$.  My question is, why is it $x$ and not $x^n$ in the definition? Replacing $x$ by $x^n$ doesn't make a difference, does it?

In a commutative ring, can I say   An ideal $\mathfrak q$ in a ring $A$ is primary if $\mathfrak q \neq A $ and if $ xy \in \mathfrak q \Rightarrow $ either $ x \in \mathfrak q$ or $y^n \in \mathfrak q $ for some $n > 0$ or either $ y \in \mathfrak q$ or $x^m \in \mathfrak q $ for some $m > 0$.  Why I am asking this question is if I use the above definition, and use the ideal $P^2$ in the question , then $\bar{x}\bar{y} = \bar{z}^2 \in P^2 \text{ and } \bar x^2 \in P^2 $ gives a contradiction to the fact that $P^2$ is not primary.  Where my understanding went wrong?


I think we use induction with base case, $n=7$. But then what?

Suppose $n \geq 2$ and $n$ is a divisor of $3^n + 4^n$. Prove that $7$ is a divisor of $n$.  My work so far:  I had a hypothesis that if $n| 3^n + 4^n$, then $n = 7^k$ for some $k\in\mathbb{N}$. But this is not necessarily so. Take $n = 7⋅379$, where $3^7 + 4^7 = 7^2⋅379$. Then, $3^7+4^7$ divides $3^n + 4^n$, and since $n$ divides $3^7+4^7$, we must have $n|3^n+4^n$.


So I'm trying to get ATS working on a new server. Noticed the official apt-get install trafficserver is only version 3.2.x but if I download and build ATS from code I'm at version 5.3.0.  I'm having issues with getting it running properly from source (built and configured fine but somehow is not starting properly). I've been looking for an updated 5.3.x package but can't find any.   Is there any reason why the official package management/distribution doesn't have this up to date with the latest ATS version?

What reasons are there for applications in Ubuntu not being the most up-to-date, and why are some applications not available, in its  repositories?


I applied to 16 graduate schools for this coming fall. I am a transfer student at a Top 10 Public US school. I had GPA 4.00 at the time I applied (Not yet took graduate course yet, but I wrote that I would have taken 8 graduate courses at the time I applied). I didn't have the REU (but I was proceeded algebraic geometry research thesis), and a few experience of presentations. I am an international male applicant. The person who wrote my letter of recommendation is famous/reputable (one Fields medallist and one very famous mathematician of algebraic geometry). But, I couldn't hit any of the graduate schools (including the Top 50-60 US math department schools). I am not sure what was the reason I can't get into any of the graduate schools to which other students in my school were admitted. What can I do to improve my prospect of getting into any graduate schools?

When applying to a PhD program in the US, how does the admissions process work? If an applicant is weak in a particular area, is it possible to offset that by being strong in a different area?  Note that this question originated from this . Please feel free to edit the question to improve it.


Is there a simple and easy app on Ubuntu to do some quick and dirty blocking of say... a license plate in a picture?    I'm hoping that I don't have to install anything, because it's going to long and painful if I do.

I want something similar to "preview" in macs.  For example: I want an image editor that ONLY does simple adjustments like increase/decrease contrast, saturation, exposure, color tinting.... rotate, flip vertically, flip horizontally, make black and white, change size or format, crop.  THATS IT.  I know gimp can do all those things but its a bit overkill.  I just want to right click an image, open it with this magical program i just described, do a few quick adjustments, and then save and exit.  Nothing really fancy.  Anyone know of anything like this?  Btw I am using ubuntu 12.04 :) It rocks and I am glad I switched from mac, i just need to replace this one piece of software.


I am using Ubuntu 15.10 and I have an email account configured on the terminal.   Probably a left-over from the time I tried to configure that account, I have some logs being printed to a file in my home directory a couple of times day.   An example of a log (one line, split here for readability):  28 12:36:02 host=smtp.gmail.com tls=on auth=on   user=***@gmail.com from=***@gmail.com recipients=&&& smtpstatus=553   smtpmsg='553 5.1.2 The recipient address <&&&> is not a valid RFC-5321 address. q65sm28155223wmd.6 - gsmtp'   errormsg='recipient address &&& not accepted by the server' exitcode=EX_DATAERR   It is printed to ~/msmtp.log  My question is how can I discover where does this printing comes from in order to kill it?  Solution: The log was printed by msmtp itself. A quick look at the msmtp manfile showed that the configuration file is ~/.msmtprc . I edited this file to change the log file.

Three files have suddenly appeared in my home directory, called "client_state.xml", "lockfile", and "time_stats_log". The last two are empty. I'm wondering how they got there. It's not the first time it has happened, but the last time was weeks ago; I deleted the files and nothing broke or complained. I haven't been able to think of what I was doing at the time reported by stat $filename. Is there any way I can find out where they came from?  Alternatively, is there a way to monitor the home directory (but not sub-directories) for the creation of files?


I'm going to apply for a visit visa with 2 of my dependants. I'm wondering if I can use my UK bank statement which has been idle for couple of years. Currently, I'm living in Pakistan since I completed my education back in 2013. I'm wondering If I transfer some amount in that account before applying for a Visit visa. This is important to add here that my bank account is active but no transaction has made since September 2013!

The UK Visas and Immigration Directorate publishes  that provides helpful tips that can result in successful visa applications. Section 2 of this guidance opens is entitled "other documents you may want to provide" (emphasis mine).  Section 2: other documents you may want to provide – all visitors This section provides guidance on the types of documents that you may want to provide to help us consider your application against the Immigration Rules. Previous travel documents/passports, which show previous travel. Financial documents showing that you have sufficient funds available.  These must clearly show that you have access to the funds, such as:  bank statements building society book proof of earnings such as a letter from employer confirming employment details (start date of employment, salary, role, company contact details) where a third party (who is either in the UK or will be legally in the UK at the time of your visit) is providing financial support to you e.g. a business, a friend or a relative, documents to show that they have sufficient resources to support you in addition to themselves and any dependant family should be provided   The first item is "bank statements" and this ties in with the , which says...  evidence that you can support yourself during your trip, eg bank statements or payslips from the last 6 months  (Note 'eg' is a Latin abbreviation meaning "for example"; this appears to be optional rather than a fixed requirement.) Question: How should someone interpret this such that the chances of success are maximized? How many statements should I submit? What are they looking for and what do my bank statements tell about me?


I try to find an example for a cochain map $ψ: A• → B•$ that exists :  $ψ^i:A^i→B^i$ is an injective map (for i>=0) but  $ψ∗ :H^k(A∙)→H^k(B∙)$ is not a injective map (for k>=0)? I use the fact that a short exact sequences of cochain complexes induces a long exact sequence on the cohomology. I will be happy if someone give me a hint. thank you!

I am looking for a injective cochain map $\psi: C^*\rightarrow D^*$ such that the map $\Psi^i$ from $C^i$ to $D^i$ is injective, but the map $\psi^*$ from  $H^i(C^*)$ to $H^i(D^*)$ is not injective for any $i\geq0$.


So I asked  question recently, and then figured out what was wrong myself after an hour or so of investigation.  Nobody else had put the correct solution down, so being a thoughtful chap I posted my answer and put an update in the question.  Being that there wwere no other upvoted answer and that I'm not able to mark my question as accepted for a couple of days I decided that I'd also put [SOLVED] in the title to show to anyone looking through the list of unanswered questions that its been solved.  Now clearly I've broken some sort of unwritten rule here, because someone has downvoted it - apparently because of the [SOLVED] in the question.  Never mind that the question is well written, correctly tagged, and that its even a pretty reasonable question - none of that is worthy of an upvote, but trying to be helpful and putting [SOLVED] in the title is worth of a downvote...  The best bit is that whoever downvoted the question was quite probably perfectly capable of editing the title themselves anyway, but they chose to downvote it instead...  Gah! (</rant>)  Anyway - so I take it there is a taboo against putting [SOLVED] in the title of a question?

I was confused when I saw this Question with [Solved] in its title where I couldn't find a solution: .  Then I found out that the "[Solved]" part was put there by someone else through editing like these:       I was feeling that this was not how it's supposed to be done and searched meta to find, that it is indeed discouraged to do so:        But on the other hand, the user who did the edits has a whole lot of reputation so I might me missing something here. So what's the correct thing to do? Should those edits be reverted?


I was using windows 7 before the update and before the update the driver was working good it was detecting all the WiFi networks but after the update there is a notification which is 'NO WIFI - ADAPTER FOUND'. My WIFI driver model is -07:00.0 Network controller: Broadcom Inc. and subsidiaries BCM43142 802.11b/g/n (rev 01) Please help me, I have to attend my classes, so please help me as soon. Thank you!

I'm having serious problems installing the Broadcom drivers for Ubuntu. It worked perfectly on my previous version, but now, it is impossible.   What are the steps to install Broadcom wireless drivers for a BCM43xx card?  I'm a user with no advance knowledge in Linux, so I would need clear explanations on how to make, compile, etc.    lspci -vnn | grep Network showed:   Broadcom Corporation BCM4322 802.11a/b/g/n Wireless LAN Controller [14e4:432b]      iwconfig showed:  lo        no wireless extensions. eth0      no wireless extensions.   NOTE: Answer below is updated every time new information is added and confirmed working.


I have a Canadian passport. I entered the UK with it, and I want to take a day-trip to Ireland.  Will my passport be checked, if so, will it be stamped at both ports (going by ferry)?

I'm soon travelling with a US citizen from UK to Ireland and back by ferry.  Based on my findings, it would appear entry stamps can be issued at Irish ports coming from the UK, but not at British ports coming from Ireland.  Is this correct?  Is there any difference between specific ports? The ports of interest are Fishguard, Holyhead, Liverpool and Pembroke in the UK, and Dublin and Rosslare in Ireland.


“Fascinating,” said Snape, without looking at it. “You should drink that directly, Lupin.”    To me, this quote seems to indicate that - since there was no immediate danger of Lupin turning into werewolf right this moment - there was a another reason for Snape to insist on Lupin drinking ASAP.  The only logical reason seems to be if the potion is more potent when drank right after making. But it could also be Snape just being snippy.  Based on both Slytherince's and Anthony Grist's answers , it is 100% clear that the potion still works well enough for several days later.  Is there any canon confirmation (books/JKR info/Pottermore etc..) other than the PoA quote above of whether the "drink that directly" was based on the fact that freshly brewed Wolfsbane potion is more potent - though not critically so - than non-fresh one?

Do we know how long potions (in general, or at least specific ones) are potent (no pun intended) in Harry Potter canon?  E.g. do they last a couple of hours? Minutes? Years?   I seem to vaguely remember some comments of Snape's about Wolfesbane potion therfore I think at least some information exists.


Using the follow theorem:     Let $a$ and $b$ two positive integers numbers so $gcd(a,b) = 1 \Leftrightarrow \exists s,t \in \mathbb{Z} : sa+tb = 1$   I want to prove that if $a\mid bc \mbox{ and } gcd(a,c) = 1 \rightarrow a\mid b$  Using the definition of divisibility I arrived at: $\exists k \in \mathbb{Z} : ak = bc$. Using this and the theorem I isolate the c, I arrived in $ak = b\frac{1-sa}{t}$. But I can not get anywhere from there,I can not see a way to do it the way I'm thinking

Well I thought this is obvious. since $\gcd(a,b)=1$,  then we have that $a\not\mid b$ AND $a\mid bc$. This implies that $a$ divides $c$. But apparently this is wrong. Help explain why this way is wrong please.   The question tells you give me two relatively prime numbers $a$ and $b$ such that $a$ divides the product $bc$, prove that $a$ divides $c$. how is this not obvious? Explain to me how my "proof" is not correct.


Is there a way to bring back the add menu that pops up in the bottom in Blender 2.8 when adding primitive object to your scene to change vertices?

When you first add a cylinder, you have the option to change the number of vertices, etc, but once you do anything else in blender, it seems you no longer can edit those parameters.   Is there a setting anywhere or an add-on that allows these parameters to be edited later on? If not, how easy would such an addon/feature be to create for anyone reading this?


I have a data set (I10:I18) containing the numbers 1-9 sequentially and I am trying to sum only the odd values within the set. The following formula seems like it should work but I keep getting a value of "0".  =SUMIF(I10:I18,IF(MOD(I10:I18,2)=1,I10:I18,0)  I realize adding the odd numbers in this example could easily be done without the formula. I am just practicing my excel skills. If someone could help me find the error I would greatly appreciate it. Thanks.

I'm trying to add only "odd" numbers from a range(named "data") which contains numbers, blank cells and text. No matter what I try I always seem to end up with a #value error. My latest attempt is as follows:  =SUMPRODUCT(N(MOD(Data,2)=1),Data) Any suggestions?


I already know how to delete strings, but the question here is: How do you delete them in a certain order without typing its value, for example, "Mathew", but I want to remove it without actually typing "Mathew" and without removing the value "Paul"? Is there a way behind this?  Note that "Paul" is the first string in the list, so I do not want to remove this, but the second string if it is possible.  usernames = ["Paul", "Mathew"] del_username = usernames.remove("Mathew")   I have tried adding a '1' to the .remove function, but it can't find the value somehow.  del_username = usernames.remove(1)

How do I remove an element from a list by index in Python?  I found the list.remove method, but say I want to remove the last element, how do I do this? It seems like the default remove searches the list, but I don't want any search to be performed.


I need to refer to a selection that contains zero or more products. This will be used in a marketing email that displays some products for sale. I consider the "selection" to be some kind of box in which I can put some products (no matter how many). To me, it's a "products selection", since the plural applies to the content of the selection. However, I have found  of "product selection" on the Internet. These did not seem to refer to "the selection of one product", but to the same as in my case. So what should I use: "product selection" or "products selection", and why?

Sorry for the title, it is not very evident and intuitive but I really do not how to tell it better...  Well, you know, several times, or better, many times, we use this form:  If I want to say:      "development of special weapons was   the first point in Hitler's   program..."   I will say this (a better form):      "special weapon development was..."   OK...  is it      "special weapon development"   or      "special weapons development" (note   the plural...)   what's the grammar rule in order to understand how to use this very used form?


I am trying to to write a test method for my custom apex controller which contains a constructor and multiple PageReference methods, all returning null. I am trying something like this: @isTest Public class matchingcontacts_test {     static testMethod void testmatchingcontactController()     {         test.startTest();         matching_contacts mc = new matching_contacts();                  PageReference pagerefacc = mc.get_account();         System.assertEquals(pagerefacc,null);                                    PageReference pagerefcreatecontact = mc.createcontact();         System.assertEquals(pagerefcreatecontact,null);          PageReference pagerefcreate_logs = mc.create_logs();         System.assertEquals(pagerefcreate_logs,null);          test.stopTest();     } }  Running this test always fails and I get an error "Argument cannot be null". Please guide me in the right direction.

I am facing difficulty in passing parameters to apex method from test method. In apex method, I am getting parameters from my VF page. Example of Apex Method: public PageReference create_contact()  {         String callfrom = System.currentPageReference().getParameters().get('callfrom');                  Contact newCon = new Contact(lastname = 'Anonymous', phone = callfrom);           insert newCon;                  return null; }  My Test method: static testMethod void testmatchingcontactController() {         test.startTest();         matching_contacts mc = new matching_contacts();         mc.create_contact();         test.stopTest(); }  On running test method, I get an error that "Argument cannot be null" because the parameter callfrom in apex code is provided by Visualforce page in application. I don't know how can I pass it from test method. Please help if you know solution to this problem.


[4] === 4 // is: false [4] == 4 // is: true  '0' == 0 // is: true '0' === 0 // is: false   Can anyone give the exact reason for this?Also what exactly does strict equality operator do or need for comparision?I learned that type and value should be same for strict(===) operator.Is this what strict equality operator checks .If yes,than how equl to operator works?

I'm using  to go through JavaScript, and it's returning many suggestions to replace == (two equals signs) with === (three equals signs) when doing things like comparing idSele_UNVEHtype.value.length == 0 inside of an if statement.  Is there a performance benefit to replacing == with ===?   Any performance improvement would be welcomed as many comparison operators exist.  If no type conversion takes place, would there be a performance gain over ==?


No matter what I do, I can't get the line to position properly. align* always wants to move it. and i can't use \noalignwithin \cee, or perhaps I'm not using it properly (beginner here)? Here's a MWE:  \documentclass{article} % [10] =10pt|11pt|12pt \usepackage[fleqn]{amsmath} % standard math package 1/3 \usepackage[version=3]{mhchem} % insert chem equations \usepackage[detect-none]{siunitx} % use proper si units \usepackage{cancel} %strike out text  \begin{document}   \begin{align*}     \cee{       \cancel{\mathrm{MgCl_{2(aq)}}} + \cancel{\mathrm{H_{2}O_{(l)}}} &-> MgO_{(s)} + \cancel{\mathrm{2HCl_{(aq)}}}       &\Delta H_r&=\SI{105.037}{\kJ\per\mole} \\        Mg_{(s)} + \cancel{\mathrm{2HCl_{(aq)}}} &-> \cancel{\mathrm{MgCl_{2(aq)}}} + \cancel{\mathrm{H_{2(g)}}}       &\Delta H_r&=\SI{-447.667}{\kJ\per\mole}\\         \cancel{\mathrm{H_{2(g)}}} + 1/2O2_{(g)} &-> \cancel{\mathrm{H_{2}O_{(l)}}}       &\Delta H_r&=\SI{-285.8}{\kJ\per\mole}  \\        \rule{6cm}{1pt} \\       Mg_{(s)} + 1/2O_{(g)} &-> MgO_{(s)}     }   \end{align*} \end{document}

Is there a package that supports the addition or subtraction of chemical equations, perhaps with automatic tabbing and a alignment.  Whilst it is obvious I could set up tables or use mathmode's align feature, it seems so much more efficient to have a package handle the tabbing automatically, since it is rather predictable in this application.  mhchem does not seem to have such a feature...      Another advantage is you could maintain the readability of your equations and you would not have the added clutter associated with tables, especially tabs &, which diminish the readability of your .tex document.  And of course, the line should be automatically inserted before the last row.


I had this very random and very debilitating bug occur in Windows 8.1 today and wanted to document it so others can learn how to fix it and maybe someone knows how to prevent it that can provide some advice.  Upon starting my PC, all of my text looked like this picture:   The only thing I know that happened before this is that I tried to install a ttc (Avenir Next Condensed.ttc) font to be used with a Photoshop design file that upon clicking "Install", windows said "this file does not appear to be a valid font". It should be noted that this font was installed on another computer before being transferred to mine (ie it works on another computer, not Windows 8.1, though.)  It also appears this could be a bug related to Visual Studio 2013. (My entire project was missing. - Fortunately, I checked in my code before turning it off... Thank god...)   Shows a solution of copying over fonts from another computer as well as others experience this issue seemingly at random.  To see this bug in action:

Some days ago I rebooted my windows 8.1 system. After the reboot all my system texts were very cryptic - showing only some strange symbols. After some investigation I discovered that my c:\windows\fonts folder was nearly empty. So I copied the font files from another windows 8.1 installation to the nearly empty folder. As soon as I had copied the files the system texts were readable again.  But after another reboot the problem occured again - the systems font folder was empty again. Does anyone know why windows deletes my font files during a restart?


Markdown supports special links to the StackExchange sites, such as [vi.se] to "Vi & Vim" or [unix.se] to "Unix & Linux." Do these only work in comments? Or in other contexts too? (They didn't seem to work in asking this question here on Meta, at least from what Preview was showing me.) Where can I find a list of the special site Markdown links for all sites in the StackExchange network? There are also some other special links such as [edit] to link to the form that will edit the question. Are there other special links such as that one?

Ask yourself how many times you typed the following in a comment:  [meta](https://meta.stackexchange.com)   Me, personally, I'm sick of it. Can we have some data.stackexchange.com-style "magic links" in comments?  (inn~iff)


In other words, is it possible in classical logic that two sets of sentences together ($\mathbf{A} \cup \mathbf{B}$) imply a contradictory proposition ($\alpha \wedge \neg \alpha$), but they fail to individually imply a sentence that contradicts a sentence of the other set (e.g. $\mathbf{A} \vdash \neg\beta$ and $\mathbf{B} \vdash \beta$)?  I'd like to know whether this is possible or not, the proof justifying the answer, and the name of the theorem, if it has one.  I would be even more grateful if I'm referred to a textbook explaining this in detail.  Answers in the framework of non classical logics (intutionistic, paraconsistent, relevant, etc.) are also welcome.  Thanks in advance.

If the union of two theories is not consistent there exists a sentence $P$ for which one of them implies $P$ and the other one implies $\lnot P$.  Can someone please check if this is true or not?  I used to prove this by contradiction. I assumed for every sentence $P$, if $T_1$ implies $P$, then $T_2$ satisfies $P$ or $T_2$ doesn't imply $P$ but never $T_2$ implies $\lnot P$. So i think there exists a model of $T_2$ as a substructure of a model of $T_1$( i'm not sure if this is true... I just say it intuitively ), so I take that model of $T_1$ as a model of  $T_1 \cup T_2$. Since the union doesn't have a model so there exists a sentence $P$ such that $T_1$ implies $P$ and $T_2$ implies the $\lnot P$.


I want to copy all the jpg files from a directory to another directory. How do i make to copy all files finishing in jpg?

I wish to recursively go through the folders of a directory structure and copy any .jpg I find into another directory.  I think I had the wrong idea with:  cp -R photos/*.jpg /cpjpg   How can I do this from the command line in Ubuntu?


Prove that : $$\lim_{x\to \infty} \sum_{n=1}^{\infty} \frac{n x}{(n^2+x)^2} = \frac{1}{2}.$$ Furthermore, can we have an asymptotic expansion here? Mathematica gives a pretty one, but I could not prove it.    Doing an Asymptotic expansion for the summand gives that it like $\frac{n}{x}$ for large $x$ but this is completely useless, what I'm I messing here?   I prefer that you do not write the full solution if you feel that it is easy.

I try to solve the following tricky limit:  $$\lim_{x\rightarrow\infty} \sum_{k=1}^{\infty} \frac{kx}{(k^2+x)^2} $$  For some large values, W|A shows that its limit tends to $\frac{1}{2}$ but not sure how to prove that.


I got some code using the PDFBox. Executing it with Eclipse no Error. But when I try to use the Windows Terminal it shows:  Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/pdfbox/pdmodel/PDDocument         at PdfReader2.main(PdfReader2.java:15) Caused by: java.lang.ClassNotFoundException: org.apache.pdfbox.pdmodel.PDDocument  Whats the problem?

I am getting a NoClassDefFoundError when I run my Java application.  What is typically the cause of this?