Why does the second section of java code always takes considerably more time to run?

While trying to benchmark as suggested when I asked  question, I found that no matter what, whichever piece of code I tested second was dramatically longer by a factor of 1000 ns. I even swapped the pieces of code being tested to see if one really just was longer than the other, and the longer time swapped meaning it is placement in code that affects how long it runs. Here is my benchmark code:  public class JavaAsmTest {     public static void main(String [] args)     {         int numOfTrials = 10;          long [] codeATimes = new long [numOfTrials];         long [] codeBTimes = new long [numOfTrials];         for(int trial = 0; trial < numOfTrials; trial++)         {             {                 long startTime;                 long endTime;                 long deltaTime;                 startTime = System.nanoTime();                 for(int x = 0; x < 0x10000; x++)                 {                     for(int y = 0; y < 0x10000; y++)                     {                         codeB(x, y); //the code being tested                     }//end y loop                 }//end x loop                 endTime = System.nanoTime();                 deltaTime = endTime - startTime;                 codeBTimes[trial] = deltaTime;             }//end codeB Trial             {                 long startTime;                 long endTime;                 long deltaTime;                 startTime = System.nanoTime();                 for(int x = 0; x < 0x10000; x++)                 {                     for(int y = 0; y < 0x10000; y++)                     {                         codeA(x, y); //the other code being tested                     }//end y loop                 }//end x loop                 endTime = System.nanoTime();                 deltaTime = endTime - startTime;                 codeATimes[trial] = deltaTime;             }//end codeA Trial          }//end trial loop          long codeASum = 0;         long codeBSum = 0;          for(int x = 0; x < numOfTrials; x++)         {             codeASum += codeATimes[x];             codeBSum += codeBTimes[x];         }          long codeAAvg = codeASum / numOfTrials;         long codeBAvg = codeBSum / numOfTrials;          System.out.println("codeA avg: " + codeAAvg);         System.out.println("codeB avg: " + codeBAvg);      }//end main      private static void codeA(int a, int b)     {         int result = (a + b) & 0xFFFF;          if(result == 0)         {             setZeroFlag(true);         }         else         {             setZeroFlag(false);         }         setSubtFlag(false);         if((((a & 0x0FFF) + (b & 0x0FFF)) & 0x1000) != 0)         {             setHCarryFlag(true);         }         else         {             setHCarryFlag(false);         }     }      private static void codeB(int a, int b)     {         int result = (a + b) & 0xFFFF;          if(result == 0)         {             setZeroFlag(true);         }         else         {             setZeroFlag(false);         }         setSubtFlag(false);          setHCarryFlag((((a & 0x0FFF) + (b & 0x0FFF)) & 0x1000) != 0);     }      private static void setZeroFlag(boolean flag)     {     }     private static void setHCarryFlag(boolean flag)     {     }     private static void setSubtFlag(boolean flag)     {     } }   Please explain why this happens and how to prevent it to give me a realistic benchmark.


Electroweak symmetry breaking and mass generation

Can someone please describe how the mass of the fermions is generated by the Higgs relative to electroweak symmetry breaking? Or other way around: Why does a breaking of the electroweak symmetry generate a  fermion mass?  Hence, what's the difference to chiral symmetry breaking which causes, e.g., the pion masses?  I found it on  and there is maybe an another question related to:   That are probably very plain questions aiming at a general understanding/access. I'm trying to separate the involving terms and mechanisms from each other..


I am looking for a way to redefine the font that \mathcal uses in math mode. I would like any characters using the \mathcal{} function to be written in, for example, Asana Math font, and all other math text to be written in the default text. So far, I have:  \documentclass[11pt]{report}  %%%Packages%%%  \usepackage{amssymb} \usepackage{amsmath} \usepackage{amsthm} \usepackage{amsfonts} \usepackage{amsmath} \usepackage{fontspec} \usepackage{unicode-math} %\DeclareMathAlphabet{\mathcal}{OMS}{cmsy}{m}{n}  %\setmathfont{Asana Math} \let\mathcal=\mathscr  \begin{document}  \begin{equation} \mathcal{p} = U(x,t) \end{equation}  \end{document}   as my MWE.


The strong topology on $U(\mathcal H)$ is metrisable

The strong operator topology on a Banach space $X$ is usually defined via semi-norms:  For any $x \in X$, $|\cdot|_x: B(X) \to \mathbb R, A \mapsto \|A(x)\|$ is a semi-norm, the strong topology is the weakest/coarsest topology which makes these maps continuous.  Alternatively it is generated by the sub-base $\left\{B_\epsilon(A;x)=\{B\in X \mid |B-A|_x<\epsilon\}\phantom{\sum}\right\}$.  If we define this topology on a separable Hilbert space $\mathcal H$ and restrict it to the subset of unitary operators, a statement in a book I am reading is that this is then a metrisable topology.  My question is then, how can I prove this (especially, why do we need separability)? What does the metric look like (is it constructable)?  When can this result be extended to other bounded subsets of $B(\mathcal H)$?


Can I use two shields and get the AC bonus from both?

The question title sums it up fairly quickly. If a character is wielding two shields, one in each hand, does she gain the shield bonus to AC from both, or only the higher one? And where in RAW is this written?


I need to replace existing sshd config on the remote PC and restart sshd, so I try to use this:  cat /sshd_cfg | ssh user@192.168.0.47 "cat > /etc/ssh/sshd_config && service sshd restart"   but I get bash: /etc/ssh/sshd_config: Permission Denied   So to use sudo I try "echo pass | sudo -S" like that: cat /sshd_cfg | ssh user@192.168.0.47 "echo pass | sudo -S cat > /etc/ssh/sshd_config && service sshd restart" but getting the same output - Permission Denied, may be because of pipes collision? What shall I do?  Linux 190 4.3.0-2-generic #11-Ubuntu SMP Fri Dec 4 20:36:35 UTC 2015 i686 i686 i686 GNU/Linux   **   upd   As I found, the problem is in user privileges.  If I connect directly to PC and try to execute sudo cat /dev/null > /etc/ssh/sshd_config, I get Permission Denied, but it' okay If I try sudo -H -u root bash -c 'cat /dev/null > /etc/ssh/sshd_config'.  So I tried that from remote: cat /sshd_cfg | ssh user@IP "echo password | sudo -S -H -u root bash -c 'cat > /etc/ssh/sshd_config'"  And this time no errors appeares. And the file was changed, but it became ...blank. Instead cating /sshd_cfg in it.  Why?


Fragment: Attempt to invoke virtual method 'android.view.View android.view.View.findViewById(int)' on a null object reference

I am trying to insert a GridView which is populated from my SQLite Database, but I am getting the error   "Attempt to invoke virtual method 'android.view.View android.view.View.findViewById(int)' on a null object reference"  MyAdapter.java class  public class MyAdapter extends BaseAdapter { Context context; ArrayList<Players> playerList; private static LayoutInflater inflater = null;  public MyAdapter(Context context, ArrayList<Players> playerList){     this.context = context;     this.playerList = playerList;     inflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE); }   @Override public int getCount() {     return playerList.size(); }  @Override public Object getItem(int position) {     return position; }  @Override public long getItemId(int position) {     return position; }  @Override public View getView(int position, View convertView, ViewGroup parent) {     if (convertView == null)         convertView = inflater.inflate(R.layout.layout_grid_item, null);      TextView idTextView = (TextView) convertView.findViewById(R.id.tv_player_id);     TextView nameTextView = (TextView) convertView.findViewById(R.id.tv_player_name);     TextView roleTextView = (TextView) convertView.findViewById(R.id.tv_player_role);      Players p = new Players();     p = playerList.get(position);     idTextView.setText("ID " + String.valueOf(p.getId()));     nameTextView.setText("Name " + String.valueOf(p.getName()));     roleTextView.setText("Role " + String.valueOf(p.getRole()));      return convertView; }   }  GameActivity.java Class  public class GameActivity extends Activity { DatabaseHelper db;  @Override protected void onCreate(Bundle savedInstanceState) {     super.onCreate(savedInstanceState);     setContentView(R.layout.game_activity);     db = new DatabaseHelper(this);  }  public void FragmentOneClick(View view) {     Fragment myfragment;     myfragment = new RolesFragment();      FragmentManager fm = getFragmentManager();     FragmentTransaction fragmentTransaction = fm.beginTransaction();     fragmentTransaction.replace(R.id.fragment_switch, myfragment);     fragmentTransaction.commit(); }   }  RolesFragment.java  public class RolesFragment extends Fragment {  GridView gridView; ArrayList<Players> playersList; MyAdapter adapter;  public View onCreateView(LayoutInflater inflater,ViewGroup container,                          Bundle savedInstanceState) {      View view = inflater.inflate(R.layout.fragment_viewroles, container, false);      gridView = (GridView) getView().findViewById(R.id.gv_players);      DatabaseHelper databaseHelper = new DatabaseHelper(getActivity());     playersList = new ArrayList<Players>();      playersList = databaseHelper.getPlayers();     adapter = new MyAdapter(getActivity(), playersList);     gridView.setAdapter(adapter);      return view; }   }


There is one piece of information that makes me wonder why finitely sized black holes are even possible: to an observer from afar, anything that approaches a black hole's event horizon is never observed to cross the event horizon, instead asymptotically approaching.  If that is indeed the case, then that would suggest that, for the generation of a black hole, the instance an event horizon arises from a singularity, surely, to outside observers, no more mass should be observed to cross that infinitesimal event horizon. Therefore, that would suggest that no more mass contributes to the singularity, and the mass of the singularity does not change. Therefore, the event horizon would remain infinitesimal in size, and no black holes would have the opportunity to grow to a size that any outside observers could observe in the first place.  This, of course, seems to be unlikely, given how black holes have indeed been detected. Therefore, I suspect there is a flaw in my logic, or that I'm making an incorrect assumption. However, I do not know where the flaw lies.  For example, perhaps the initial formation of a black hole does not start off with an infinitesimally sized event horizon. I assume this as I thought the generation of an event horizon occurs instantaneously whenever enough mass is collected within a certain volume.  Perhaps objects do indeed pass the event horizon, but only after an extremely long time passed.  Or could it be that objects just at the event horizon contributes to the mass of the black hole, even without passing through, until the event horizon grows in size and eventually consumes that which was just beside the event horizon.  Or, as a wild afterthought, is it feasible for black holes to have existed since the very start of the universe?  Any help with this would be very much appreciated!


Though I'm a while in this field I recognized that I can't say for sure that I understood this basic, very simple equation $ \hat{y} = xw + w_0 $ I know $ w_0 $ denotes the bias term (mostly given as $ b $) which is basically the offset of the function. But how do I understand $ xw $? Does $ x $ represent the feature(s) like speed and acceleration so it would have two dimensions with $ x_i , i=0,1 $ Or does it stand for all the data points of a feature with $ x_i, i=0,..,n $ ? And $ w $ is then exactly, what?


Do virtual images exist in the real world?

I have been reading an article here in physics stack exchange that talks about if it is possible to see virtual images, and i read an answer saying it is actually your brain that understands the refracted rays and creates the image, but in high school class I remember this image of converging lenses. As it can be seen we projected the refracted rays back to form the virtual image. so I just want to clear my confusion does this really happen in the real world or is this a way we humans have developed in order to understand what happens. and can we see the object if it is put in this position, if so how would that be (how does the eye do it if there is no canvas for the image to be formed and reflect). And one more question if the image were to be seen at all in what direction should be the viewer be, on the left or the right?


My questions do not appear on Stack Overflow main page

Few months back, when I asked some question at stackoverflow.com, it used to appear on its main page questions list, in just few minutes. But for my last 2 questions, (during last 20 days) I've noticed that my question do not appear on main page. I even see other questions time stamps as 1s ago, 3s ago, 1hour ago, etc. Then, how come my question do not appear? Is there something changed? Or am I missing something?


How many nonnegative integer solutions are there to the pair of equations $x_1+x_2+…+x_6=20$ and $x_1+x_2+x_3=7$?

How many nonnegative integer solutions are there to the pair of equations  \begin{align}x_1+x_2+\dots +x_6&=20  \\ x_1+x_2+x_3&=7\end{align}  How do you find  non-negative integer solutions?


Infinitely many primes of the form $pn+1$

Prove: Given a prime $p$, there are infinitely many $n\in \mathbb{Z}^+$, for   which $pn+1$ is a prime.   This is a simplified version of , so is there any elementary solution to this problem?  A proof by contradiction is recommended. Just like the proof of the existence of infinitely many primes by Euclid.


--shell-escape - Consequences and Reasons

For certain packages to work properly, it seems to be necessary to enable the option --shell-escape, for example with pdflatex and auto-pst-pdf. I am informed that it enables external programs to interact with the engine, in the case of auto-pst-pdf a perl-script, and that this possibility is otherwise not enabled per default.  My question is: What are the dangers or known negative effects of setting this option as a standard?  (Two related questions could be: What is the exact reason this is set per default? Wouldn´t it be desirable to enable pdflatex to interact with external programs per default?)  The reason I am asking this is that I have know set --shell-escape as the standard in my editor. It is necessary for me to do this for certain documents, and I don`t want to bother thinking about it with every new document.


Difference of the floor of a product and the product of floors

Is there any way the following can be simplified?  $$\lfloor f(x)\cdot g(x) \rfloor - \lfloor f(x) \rfloor  \cdot \lfloor g(x) \rfloor$$


Showing that an Isometry on the Euclidean Plane fixing the origin is Linear

Suppose $f$ is an isometric (i.e., distance preserving) function on $\mathbb{E}^2$ such that $f(0,0) = (0,0)$.  Then I want to show that $f$ is necessarily linear.  Now $f$ is linear iff $f$ is both additive and homogenous.  The following is an attempted proof for the homogeneity of f (missing the last step); still more, I have no idea how to argue for the additivity of $f$.  Any ideas?  Let $x \in \mathbb{E}^2$ and $\alpha \in \mathbb{R}$   We know that $\forall x \in \mathbb{E}^2$, $\Vert x - 0 \Vert = \Vert f(x) - f(0)\Vert = \Vert f(x) - 0 \Vert$ so that $\Vert x\Vert = \Vert f(x)\Vert$.  From this we immediately have the following facts:  $\Vert x \Vert = \Vert f(x) \Vert$  $\Vert \alpha x \Vert = \Vert f(\alpha x) \Vert$  We can then argue that since $\Vert \alpha x\Vert = |\alpha| \Vert x \Vert = |\alpha| \Vert f(x) \Vert = \Vert \alpha f(x) \Vert$, we also have that $\Vert f(\alpha x) \Vert = \Vert \alpha f(x)\Vert$.  Finally, we have that  $\Vert \alpha x - x \Vert = \Vert \alpha f(x) - f(x) \Vert$   iff $ \Vert (\alpha - 1)x \Vert = \Vert (\alpha - 1) f(x) \Vert$   iff $|\alpha - 1| \Vert x \Vert = |\alpha - 1| \Vert f(x) \Vert$  Since the last of these statements is in fact true, we now have $\Vert \alpha x - x \Vert = \Vert \alpha f(x) - f(x) \Vert$ as desired.  Now at this point it seems like I have all of the facts required to assert that $f(\alpha x) = \alpha f(x)$, but I can't figure out how to formally state why without illegally appealing to visual intuition.  Any ideas?


Prove that $S^1{\setminus\{(1,0)\}}$ is homeomorphic to $]0,1[$

I'm currently working on this book called "Topology Without Tears". One of the exercises on the chapter of non-homeomorphic spaces. I'm asked to prove that $S^1{\setminus\{(1,0)\}}$ is homeomorphic to $]0,1[$, but I couldn't find any homeomorphism.  Plus I was told that I should use the stereographic projection On $\mathbb{R}$, but I don't know what that is.


Disable cache website for javascript.js files

I have a web app where I do updates constantly.  All my js files for a web pages are in this format to force no cache from browser:  <script src="./js/scripts.js?v=1.1"></script>   where ?v=1.x is incremented on each modify of my js.  The problem is that sometime some users tell me the page doesn't work (like form not submitted after fields check: stuck and other problems...). I tell him to reload page with CTRL+F5 and try again.... all works great.  I've read already some post about caching and this is the method used from all people: querying with ?v=....  But in my case some browser seems to not view this changed url and reload js from cache instead reload it. Why?  Why the browser doesn't reload all my js when url is changed??


Using only a calculator's $\sin$, $\cos$, $\tan$, $\cot$, $\arcsin$, $\arccos$, $\arctan$ buttons, convert $1$ to $3/\sqrt{5}$

A calculator is broken so that the only keys that still work are the $\sin$, $\cos$, $\tan$, $\cot$, $\arcsin$, $\arccos$, and $\arctan$ buttons. Assume that the calculator does real number calculations with infinite precision. All functions are in terms of radians, and you may assume all the values of $x$ below are positive. (a) Find, with proof, a sequence of buttons that will transform $x$ into $\frac{1}{x}$ . (b) Find, with proof, a sequence of buttons that will transform $\sqrt x$ into $\sqrt{x+1}$. (c) The display initially shows $1$. Prove that there is a sequence of buttons that will produce $\dfrac{3}{\sqrt{5}}$.  I got parts (a) and (b) pretty easily, but I can't figure out how to get (c).


Limit evaluate $ \lim\limits_{x \to - \infty } {{|\arcsin ({2 \over x})|} \over {\arctan ({5 \over x})}} $

Please help me with this limit without using L'Hôpital's rule. I would by happy if you use simple solving. Thank you as much as I can ;).  $ \lim\limits_{x \to - \infty } {{|\arcsin ({2 \over x})|} \over {\arctan ({5 \over x})}} $


Do you know how LaTeX implements environments? To be more precise, what does  \newenvironment{<env-name>}[<n-args>][<default>]{<begin-code>}{<end-code>}   in terms of TeX commands (i.e., how is the LaTeX command \newenvironment defined in TeX)?


\I understand that it can be just a coincidence, but maybe there is a reason?  The closest I could find is using the property that $\log_2 x \approx \ln x + \log_{10}x$ and approximate values of $\log_2 10 \approx 3.3$ and $\log_{10}2 \approx 0.3$. Is there a better explanation?


Incoming DDoS Attack, It Looks Like An ICMP Attack, So What Do I block?

I recently have been getting hit by an attack that is very small around 70MBPS but causes TONS of upload...All signs point to ICMP. I realized in my firewall I have CSF firewall running on CentOS, that I had no limit on my outgoing ICMP rate...Woops. :P  Anything else I should block? We are primarily game servers so obviously blocking all incoming ICMP traffic is a no no. Or is it? That's why I'm here :D  Thanks for any tips,  Jeremy  **Also quick edit, we are on a 100MBPS port and the current firewall is able to block generic  DDoS attacks excess of 600MB without breaking a sweat.


I am running a web server on a machine with Ubuntu 11. Everything is accessible from the local network, but not from outside. What can I do to check to make sure the appropriate ports are open?  I am relatively new to Ubuntu and server management, so any "dumbing down" is just fine.  Appreciate any help.  Google search hasn't given me much actionable advice.


I am having trouble with this proof.     If $a,b$ are integers, then $(a+b)^3 \equiv a^3 + b^3 \pmod{3}$     What I am confused about is using the definition of modulo. So can $b^3 \pmod{3}$ be written as $3\, |\, [b^3 - (a+b)^3]?$ How does the $a^3$ term come into play with writing the modulo definition.   Also I apologize for the messiness of the math equations, I am new to math exchange and haven't gotten the TeX concepts down yet.


Add eventlistener for element that was created by javascript code

I write html and javascript:    $(document).ready(function(e) {   $('#btadd').click(function(e) {     $('#content').html('' + $('#result').html());     $('.btnmsg')[i].click(function(e) {       alert('span ' + i);     });     i++;   }); });  var i = 0; <input type='button' value='add' id='btnadd'>

     On html code, I create a button and a div. When click on button, on div will add new element span.   I want that when click on span, there will be a alert message. I don't want to use inline js (add onClick to span), because I write this addon for browser.   So I just want to write this event for span in js only.   I write as above code, but nothing to see (no alert message). What can I do?


Spending Time Rendering Transparent Tiles

I'm doing a motion tracking scene, and I'm wondering why blender is spending so much time rendering the transparent tiles.  If somebody could explain how to prevent this, that would be great!  Thanks!


Temperature range for seasoning a carbon steel pan

I have this , but the seasoning that I created with  is very brittle and flakes off easily into my food. I have not been using anything acidic in the pan, so I think I just need to start from scratch.  Most information on seasoning is geared towards cast iron. I want to know what temperatures can I use with the carbon steel pan without it warping. Can I strip the old seasoning with a self-cleaning cycle or is that too hot? What temperature should I use during the reseasoning?


Wifi connected but Internet drops frequently

I spent more than 2 weeks searching for a solution to the following problem without success:  On my Ubuntu 18.04, I am connected to a Wifi (named "SmartCampus") but the internet keeps dropping frequently (I don't know exactly the intermittent time interval, but I think it is variable. For a rough estimate: between 5 min to 15).  However, I can confirm the following:   This happens only with this wifi "SmartCampus". I am also connected to this Wifi using my phone but everything is fine and internet is always available. In the first days I try to turn off Wifi then reconnect to get internet working but recently I found that I don't need to turn off wifi but only by displaying the list of available wifis As follows         When I do that , the internet works again.  Could you please tell me what is the problem? What can I do to fix this, because that's very annoying.  Here is the result of wireless-info script:   I appreciate your help


What  theories  do I  use to  find  the  integer  solutions  of  $$y^2+2=x^3\ ?$$  Extremely sorry  for  no  work  on  my  part. I  could  not  begin  actually.


Getting 'live' controller variable values within Javascript

I'm calling an actionFunction from Javascript to set a controller variable.  Even though the variable is being updated within the controller, when I subsequently access it from the same piece of script it still holds the old value. Now I understand that the updated value will become available after rerendering, but I'd like to access the new value later in the same script. Is there any way I can refresh the controller variable during the lifetime of the script, or is it easier just to create a JS variable that holds the new value, and use that instead?  UPDATE  I'm not sure why this has been marked as a duplicate. This post describes a different issue, and the fix offered for my other post does not help with what I describe here.  PAGE  <apex:page controller="MyController">     <apex:form >         <apex:outputPanel id="panel">             <apex:outputText value="MyString = {!MyString}"/>             <apex:actionFunction name="SetString" rerender="panel">                 <apex:param name="param1" value="" assignTo="{!MyString}"/>             </apex:actionFunction>             <script>                 function JSetString()                 {                     console.log('before: ' + '{!MyString}'); // shows last value assigned                     SetString('{!MyString}' + '.');                     console.log('after: ' + '{!MyString}'); // doesn't show updated value                 }              </script>             <apex:outputPanel onclick="JSetString()" styleClass="btn">                 Grow {!MyString} (works)             </apex:outputPanel>         </apex:outputPanel>     </apex:form> </apex:page>   CONTROLLER  global class MyController {      public MyController() { MyString = 'hello'; }      public String MyString {get;set;} }


Is this a way light/information could escape from a black hole?

Since we have now confirmed that two black holes can combine into one, I have wondered about the Lagrange point (balancing of gravity) that has to exist between them.  As the two holes approach and get very close, would the Lagrange point temporarily become a place where there is no event horizon?  For a moment, would it be a place where trapped photons and information could escape from the black holes?


How to average a set of n rasters using gdal or other GRASS module?

I need to average a set of n rasters using gdal or some other GRASS module. What command exists for this purpose?


Writing shapefile of multiple geometry using Python

How to make a shapefile containing points, polygon, and line using python shapely or pyshp?


python 2-dimensional list changes an entire column at once?

So given a m*n matrix represented as columns, I'm supposed to increment one index at a time to fill a specified amount of row and column, say if I'm supposed to increment (2,0), it'll ONLY increment (2,0). So I wrote this code: for i in range(row):     for j in range(col):         print("X")         print(matrix)         content = matrix[i][j]         matrix[i][j]=content+1         print("matrix ({},{}) = {}".format(i,j,matrix[i][j]))  I added several prints to debug the code, and on the first index it outputs: X [[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]] matrix (0,0) = 1 [[1, 0, 0, 0], [1, 0, 0, 0], [1, 0, 0, 0]]  it's supposed to increment (0,0) to 1 so it's supposed to look like this: [[1, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]]  but as you can see....it increments an entire row at once... I don't know why it happened, did I miss something?


Best phone provider for a three-month visit to Thailand?

I am going to visit Thailand in January 2018. I only have 3 Thai numbers and I hope to use a SIM card primarily for navigation and internet browsing (around 6 GB per month). I will be staying in Bangkok for all 3 months.  What is the best package and network provider that suits my requirements?


Visual Studio could not load file or assembly 'System.Web.Mvc' or one of its dependencies?

I have been working on a MVC5 project using Visual Studio Community Edition on Windows 10. One fine morning, when I started Visual Studio to resume work and run the webapp I got the following error     Could not load file or assembly 'System.Web.Mvc' or one of its   dependencies.    What really happened all of a sudden, I have absolutely no clue. . It's my personal machine. Can anyone please help me out? What happened to my dear Visual Studio? Is it sick or something?  I have tried all the things that are mentioned in a similar question asked on SO. In that question the OP compiled his own version of ASP.NET from its sources. I have not performed any such thing. Those Jks. who have been finding similarity in that question should read the 2 questions fully before declaring that they are exact duplicates.


Why does a smaller aperture size have a high depth of field? What is the physics behind this?


Prove that $\frac{(n-2)s^2}{\sigma^2} \sim \chi^{2}_{n-2}$

Consider the following simple linear regression model involving the $\epsilon_i$ error term,  $$y_i = \alpha + \beta x_i + \epsilon_i$$  such that,  $$\epsilon_i \sim \mathcal N(0,\sigma^2)$$  we know that if $Z_1, Z_2, ..., Z_n$ are independent, standard normal random variables,   $$Z_i \sim \mathcal N(0,1)$$  then the sum of their squares is distributed according to the chi-square distribution with $n$ degrees of freedom,  $$\sum _{i=1}^{n} Z_{i}^{2} \sim \chi^{2}_{n}$$  Now let's prove that $\frac{(n-2)s^2}{\sigma^2}\sim \chi^{2}_{n-2}$ such that,  $$s^2 = \frac{\sum _{i=1}^{n} \hat{\epsilon}_i^2}{n-2}$$  Proof:  $\require{cancel}$  $$\epsilon_i \sim \mathcal N(0,\sigma^2)$$  $$\frac{\epsilon_i - \cancelto{0}{\overline{\epsilon}}}{\sigma} \sim \mathcal N(0, 1)$$  $$\sum _{i=1}^{n} \left(\frac{\epsilon_i}{\sigma}\right)^2 \sim \chi^{2}_{n}$$  $$\sum _{i=1}^{n} \frac{\epsilon_i^2}{\sigma^2} \sim \chi^{2}_{n}$$  How do I now move from this expression $\sum _{i=1}^{n} \frac{\epsilon_i^2}{\sigma^2}$ which uses the error term $\epsilon_i$ to this expression $\sum _{i=1}^{n} \frac{\hat{\epsilon}_i^2}{\sigma^2}$ which uses the residual term $\hat{\epsilon}_i$?


Symplectic structure on $\mathbb{S}^{2}$

This question has been asked several times but I cannot find a satisfactory answer. Consider $\mathbb{S}^{2} \subseteq \mathbb{R}^{3}$ and define, for every $p \in \mathbb{S}^{2}$ and every $u,v \in T_{p}\mathbb{S}^{2}$, the $\mathbb{R}$-bilinear form $\omega_{p}(u,v) := \langle p, u \times v \rangle = \det(p,u,v)$. It is clear that the assignment $p \longmapsto \omega_{p}$ defines a symplectic form on $\mathbb{S}^{2}$. What I want to show is that, in cylindrical polar coordinates $(\theta,z)$, $w$ can be written as $\omega = d\theta \wedge dz$.  I guess that the idea is to write first $\omega$ in the canonical coordinates $(x,y,z)$ in $\mathbb{R}^{3}$ and then do a change of coordinates. But, how can I write $w$ in standard coordinates first?   it is answered, but I don't understand how $\omega$ is written in standard coordinates.


I am studying  projective modules, but I can't understand why the direct product of projective modules need not be projective in general. Can anyone give me such example? Thanks for any help.


Why Collection class methods contains() and remove() don't use generic types in parameters?

Why methods   boolean contains(Object o) boolean remove(Object o)   aren't defined like   boolean add(E e)   using generic type?


I've seen the term used in many online games but I'm not sure what it means. What does 'ping' mean? Is it better to have high or low ping?


Why does Newton's method get stuck between 2 guesses/iterations

I have a complex function to which I applied Newton's method using a range of different initial (complex) values. I plotted a heatmap of how many iterations it took for the method to converge for each initial guess with reals on the x axis and imaginaries on the y axis. I found that there were some regions where the method did not converge at all. So I picked a point in one of these regions and re-used it as an initial value for Newtons method. However, this time i printed out the first 50 iterations of the method. The result was that after a while, the iterations were stuck between 2 guesses - by this I mean that at some point, the iterations printed ... a, b, a, b, a, b, a, b... After a point, these were the only 2 results from the Newton Method. My question is what is the mathematical explanation for Newtons method being stuck/trapped between 2 guesses when the method has an initial value that does not lead to convergence? I hope that's clear enough. THanks


I have a very basic question about the termination resistor of the CAN Bus. I know that a termination resistor is needed in order to avoid unwanted reflections. Since the characteristic impedance of a loseless line is defined as $$Z=\frac{L'}{C'}$$ and the inductance as well as the capacitance is depending on length, I am asking myself why the termination resistor of CAN is always recommended to be 120 Ω. Shouldn't it vary for Highspeed- and Lowspeed-CAN?


For a positive integer $n$, prove that: $$\sum_{d\mid n} (-1)^{n/d} \cdot \varphi(d) = \begin{cases} 0 & \text{if $n$ is even}  \\ -n  & \text{if $n$ is odd}  \end{cases}$$  I can't even think, how, to begin with, this problem, please provide easy proof of this.


I am confused in the following expression: we do say "it's not a bad idea" but we do not say "it's not too bad an idea" but instead, we say "it's not too bad of an idea" right?  What is the function of "of" here? Why do we put "of" just because we put "too" in the sentence?  Also how would you comment on the following examples:  1) "He is not as good a player as he could be" would you put "of" between "good" and "a"? or is it more natural with the above?  2) "She is as good a friend as any"  Again, would you put "of" between "good" and "a" here?   Thank you very much for the answers in advance!


if $X^2 +AX+B=0$ has a rational root, prove it is an integer.

If $x^2 + Ax +B =0$ has a rational root, prove it is an integer.  I don't even know where to start on this problem. I've had it on my white board for about a week and keep looking at it, but can't see any part of it.


How to display a specific range of random numbers in java using Math.random

So, I am fairly new to programming and I started learning about Math.random. I am trying to code a program that will print values in between 4 - 12 but i can't seem to print only the values inside that range. It prints 13 which i don't want to   My Code:   public class MathRandom{     public static void main(String[] args){          for(int x = 0; x < 10; x++){ //Just to test what numbers are displayed         System.out.println((int) (Math.random() * 10) + 4);          }     } }   Did I miss something? thanks in advance for the help


Wacom Graphics Tablet CTH-480 / CTL-480 Not Detected In Ubuntu 13.10

My Wacom tablet (CTH-480) is not detected by the Wacom Tablet option under settings. The Tablet shows up when I run lsusb but does not show up under settings. Again Thanks.


Bessel function representation of spacelike KG propagator

Preliminaries: In their QFT text, Peskin and Schroeder give the KG propagator (eq. 2.50) $$  D(x-y)\equiv\langle0|\phi(x)\phi(y)|0\rangle = \int\frac{d^3p}{(2\pi)^3}\frac{1}{2\omega_\vec{p}}e^{-ip\cdot(x-y)},  $$ where $\omega_\vec{p}\equiv\sqrt{|\vec{p}|^2+m^2}$.  For lightlike separations, we can choose a frame where $x-y$ is purely in the time-direction and the propagator can be put into the form (2.51) $$ D(x-y)=\frac{1}{4\pi^2}\int^\infty_m d\omega\sqrt{\omega^2-m^2}e^{-i\omega (y^0-x^0)} \tag{1}\label{timelike_prop}, $$ where I use the $\text{diag }\eta=(-,+,+,+)$ convention. Now, one has the following integral representation of the modified Bessel function () \begin{align} K_1(z) &= z\int^\infty_1 dt \sqrt{t^2-1} e^{-zt} \\        &= \frac{z}{m^2} \int^\infty_m dt \sqrt{t^2-m^2} e^{-zt/m}, \tag{2}\label{int_rep} \end{align} where we go to the second line by rescaling the integration variable $t \to t/m$.  Comparing \eqref{timelike_prop} with \eqref{int_rep} suggests $$ D(x-y)=\frac{m}{(2\pi)^2|y-x|}K_1(m|y-x|), $$ where we have written the time separation in terms of the Lorentz invariant $i (y^0-x^0)=|y-x|$.  (Note: there is an issue in what I've written here in that the integral representation \eqref{int_rep} is only valid for $|arg z|<\pi/2$ and $|y-x|$ is on the imaginary axis ($|arg z|=\pi$), but I think one could infinitesimally displace $z$ off of the imaginary axis to get a convergent integral.  Check me on that.) Anyway, for spacelike separations, we can choose a frame where $y-x=\vec{y}-\vec{x}\equiv\vec{r}$.  Performing the polar integrations yield $$ D(x-y)=\frac{-i}{2(2\pi)^2 r}\int^\infty_{-\infty}dp\frac{p e^{ipr}}{\sqrt{p^2+m^2}}. $$ Finally, PS claim that taking a contour integral in the upper half plane (making sure to avoid the branch cut at +im) will give $$ D(x-y)=  \frac{1}{(2\pi)^2r}\int^\infty_m d\rho \frac{\rho e^{-\rho r}}{\sqrt{\rho^2-m^2}}, \tag{3}\label{spacelike_prop} $$ where $\rho\equiv-ip$. Question: I know from plugging into Mathematica that the spacelike propagator \eqref{spacelike_prop} can also be expressed as a modified Bessel function $K_1$.  Moreover, the integration bounds of \eqref{spacelike_prop} and \eqref{int_rep} are even the same.  However, I don't see how to transform the spacelike propagator integral \eqref{spacelike_prop} into the form of \eqref{int_rep}.  Any ideas? (I'd prefer, if at all possible, to use the integral representation that I've quoted \eqref{int_rep} and used for the timelike case rather than some other representation of the modified Bessel function.)


So England has attacked Denmark with a fleet in the Skagaric support from Helgoland Bigbt and the North Sea. Russia has attacked the Skagaric from the Baltic Sea and with support from Sweden and the German fleet in Denmark. Would the offensive prevail?


Why doesn't the moon crash into the Earth?

I was searching about 'why do not moon crash to earth due to its gravity?'Then by reading physics stake exchange existing questions I came to know that its the sideways motion of the moon that keeps moon in its orbit.   So my question is:- Moon is in circular or ellipthitical orbit and during its orbit moon is always pulled towards the centre of the earth but moon is changing its direction at every point because it is in circular or ellipthitical orbit, so the direction of force pulling moon towards the centre of the earth will also change at every point on the other hand the sideways motion of moon is always in a particular direction then there must be a point in the moon's orbit when sideways motion and gravity will act in same direction and moon should crash to earth.Then why it does not crash?


Show selected records from Opportunity List on Lightning Page

I have an existing Lightning page that display records and some action buttons against each record. I want to have a Button on Opportunity List view, So that, a user can pass the selected records to that lightning page  and I want to have a button that can pass these selected opportunities to the similar page. Currently the above page is fetching the records based on a SOQL query.


My PC with Windows 10 doesn't show the date - refer to the picture. How to fix that?


i want to write like this           /ki    if 0<I<IO        |  t(i)= <        |         \c     if I>Io   here is curly bracket


He has only laid down for an hour today?

I would like to express that a person has only reclined for an hour so far today.  Is it correct to say:     He has only laid down for an hour so far today.   or is it perhaps:     He has only lay down for an hour so far today.


Authentication pop-up issue with Selenium

How to enter credentials using Selenium (Java)? I am not able to enter credentials in the Pop-up window, which is shown above. Please help me in this. Thanks in Advance


How do I make Firefox 7 remember my history shorter/longer?

I want to setup Firefox 7 to store my history for longer or shorter (setting period of time, just like in Options), but I can't seem to find an option to do that in dialog; all I can see is "Remember History".


Adding Favorites to the Stack Exchange global inbox

We're considering adding favorite notifications to the global inbox, and are looking for feedback on the idea (as we're not completely sold on it).  But first, some history.  Favorites are kind of like bookmarks, in that they're kept in a handy centralized place.  They also follow you across browsers.  Ok, ok... "bookmarks, on the internet" is not the most compelling feature, but Favorites also opted you into notices for those questions as if you were the owner (edits and new answers, at least).  This was probably the most confusing part (though a  feature) of the old envelope behavior judging by erroneous bug reports, so a way to opt out of this .  Now, favorite updates go nowhere.  But we could* put them into the inbox.  Here's how we envision this feature working:   Every current user has their "notify me on favorite changes" preference cleared (new users start with it cleared). The first time someone favorites a question, they're prompted to opt-in to favorite notices. Whenever a question is commented on or answered (or, possibly, edited) a new notice is pushed into the inbox of users who have favorited it, and have opted in.   Opt-in would be per-site, and it would remain possible to opt-out from your profile page.   This is not a final design, but the basic idea is correct  As I mentioned above, we're not 100% sold on this idea.  We've had a policy to date that nothing goes into the inbox that isn't specifically targeted at a user; this would be tweaking that policy.  *We could also put changes into their tab on the user page, but that reduces their visibility.


How to achieve optional selection in regular expressions?

I have regular expression: (?<message>.*)[\.](?:[\s]id:(?<id>.*)[\.])? code:(?<code>.*)[\.]  I have 2 cases for input text: 1. Failed to send sms. code:5063. 2. Failed to send sms. id:23. code:5063.  For the 1st case I want to have output like this: 1. Group message: Failed to send sms 2. Group code: 5063  For the 2nd case I want to have output like this: 1. Group message: Failed to send sms 2. Group id: 23 3. Group code: 5063  For the 1st case it's ok, but for the 2nd case I have: 1. Group Message: Failed to send sms. id:23 2. Group Code: 5063  It concatenates message and id. I can't understand why this is happening. You can check it in the online editor here:  Thank you in advance!


Natbib "et" instead of "&" for 2 Author Names

i have to use "et" instead of "&" in my article's citations. I am using Natbib and Har2nat.      some text  (Author, A. et Author, B.)   but i get just     some text (Author, A. & Author, B.)   Is there any possibility to do this.


Why is 'that' in 'beyond that of"? I think it is clear without 'that'. Can we  omit 'that' here?     The nature of peace-keeping operations had evolved rapidly and   expanded beyond that of traditional military observer missions.


How can I remove formatting from a phone number?

I have an MVC Application that asks the user for the Phone Number. There is a mask so it always looks like "(567) 222-0001.  When this phone number is saved in the database, it gets saved with these brackets and the hyphen. Instead, I would like to save it to the DB without the brackets and the hyphen i.e. a raw phone number. The application uses LINQ.  Any help is appreciated. Also, I am new to MVC, so I have a very rough idea where to look in the code.


At the end of this nice video (), she says that  is a chain reaction of electric and magnetic fields creating each other so the chain of wave moves forward.  I wonder where the  is in this explanation. What is the relation between electromagnetic wave and photon?


How to get the location of a program in Ubuntu terminal?

How to get the location of a program in Ubuntu? For example I have Oracle, how to get the folder racine (location) of Oracle?


I asked , and it was marked as . Although it's clear to me, and those who read both, that the questions are different.  My question----raised to issue the meaning of the phrase joga bonito, while its purported original pointed out the incorrect spelling of the word bounito.  So my question is about language usage (joga, a verb, versus jogo, a noun), while the original is about a spelling mistake (bounito should be spelt bonito).  Is there something I am missing about the definition of a duplicate question? The help center states the following:     The fundamental goal of closing duplicate questions is to help people   find the right answer by getting all of those answers in one place. ...   There are many ways to ask the same question, and a   user might not be able to find the answer if they're asking it a   different way.   It's obvious that the two questions are different. And why would mine warrant several down votes, while the purported original garnered 17 up votes? Is it so different to point out that usage might be incorrect?


removing the last line of a file not working?

I have this TXT file that is created by a bash script and at the end I want to remove the last line of that file that is an empty one.  head --lines=-1 r3.txt > r4.txt  sed '$d' r3.txt > r4.txt  cat r3.txt | head -n -1  > r4.txt   r4.txt continues to have the last empty line...  I am on a linux CentOS 6.x server.  Does this have anything to do with line endings (unix x windows)?  Any clues?


Can an object achieve speed greater than speed of light?

An object of mass 1 kg at rest experiences a force of 1 N in space with no resistance force. What will be the speed of the object after 20 years?  If I go with the high school physics. F=ma ; gives the acceleration of 1 m/s^2. And v = u + at; gives me v = 0 + 1 * 20 * 365 * 24 * 60 * 60 = 6.3 x 10^8 m/s (which is ~2 times speed of light) I am sure something is wrong here, but I am not able to find the theory behind it.


proof of an identity for exponential function

I am asked to prove $e^{(Y \log(1 + Z))} = (1 + Z)^Y$ using the power series definitions for both $\log(Z)$ and $e^Z$.  Our hint is to find a formula for the nth derivative of the power series expansion of $e^{(Y \log(1 + Z))}$ with respect to Z and then use it to find the coefficient on $Z^n$.  I have found that the formula for the nth derivative is $$\frac{(Y)_n}{(1 + Z)^n}\sum_{n = 0}^\infty\frac{1}{n!}\left[Y \log(1 + Z)\right]^n$$ where $(Y)_n$ is the falling factorial.  I am stuck from here though and cannot figure out how to use this to find the coefficient on $Z_n$.  Any help would be greatly appreciated.  Thanks in advance.


Ok, please ignore my silliness.  So, why do we use radians in calculus and why is it considered more scientific than degrees. And how did mathematicians know or prove that radians would work for all integration, differentiation in other fields or is there a method to prove it?


A questionnaire is carried out to find the percentage of men that pick   their nose. Since most men are embarrassed to answer this questions,   they are told to do the following. Secretly roll a dice. If the number   is 1 always say I do not pick my nose regardless of what the truth is,   if the number is 2 always say I pick my nose regardless of what the   truth is, if the number is 3, 4, 5 or 6 then tell the actual truth.   This way, it is not possible to ever be sure which men pick their nose   or not. If we assume that 2/3 of men answered I pick my nose, what is   the probability that a man picks their nose? If instead we assume that   fraction of men that pick their nose is 3/4, what is the probability   that a man picks his nose given that he answered I do pick my nose.   So far I have that (for part a). $P(t|y) = \frac{P(y|t)\cdot P(t)}{P(y)}$ where $y=$ yes they pick nose. $t = $ telling the truth... However, I can't find $P(y|t)$ Thanks.


How does one evaluate $$\mathbb{E}[S_n]$$ if  $$S_n = \left\{      \begin{array}{lr}        X_1+X_2+...+X_n & : \text{with probability } \frac{1}{2}\\        Y_1+Y_2+...+Y_n & : \text{with probability } \frac{1}{2}      \end{array}    \right.\\$$  where, $X_i$, $Y_i$ are random variables.  Does the expectation "reduce" into the $X_i$s and $Y_i$s?  I.e.  $$\mathbb{E}[S_n]=\frac{1}{2}(\mathbb{E}[X_1]+...+\mathbb{E}[X_n]) + \frac{1}{2}(\mathbb{E}[Y_1]+...+\mathbb{E}[Y_n])$$?  Is this called "conditional expectation"?


I am using Texstudio to write my paper and I need to include graphics figures as eps format. I have a problem when I use \includegraphics, as shown in the below image the eps figure, is converted from eps to PDF then the PDF image is added into the resulted PDF. Is it available to import eps image without converting it into PDF?  Thanks in advance     output PDF file    the ABER_VS_SNR.eps was greater after I have run the code.


Unexpected behavior when changing values in multidimensional list

I use the following function to create a multidimensional list of shape dimension:  def create(dimensions, elem):     res = elem     for i in dimensions[::-1]:         res = [copyhelp(res) for _ in range(i)]     return res.copy()  def copyhelp(r): #when res begins as elem, it has no .copy() function     if isinstance(r,list):         return r.copy()     return r   So if I say mylist = create([3,3,2],0), I get    >> mylist   [[[0, 0], [0, 0], [0, 0]],    [[0, 0], [0, 0], [0, 0]],    [[0, 0], [0, 0], [0, 0]]]   Great. Now I use this function to change the value at an index given by a list index to v:  def replacor(array, index, v):     if not isinstance(array[0],list):         array[index[0]] = v     else:         return replacor(array[index[0]], index[1:], v)    Now when I do replacor(mylist, [1,2,0], '.'), I get this:    >> mylist   [[['.', 0], [0, 0], [0, 0]],    [['.', 0], [0, 0], [0, 0]],    [['.', 0], [0, 0], [0, 0]]]   I'm suspicious it has to do with array pointers, but I used copy() at every step, so I'm not sure where I went wrong. Clearly the issue is the way I define my first list, but I still don't understand why I'm getting this behavior since ints, bools, and strings are immutable.


Why is arr[0]  * 7 changing all element of arr to 7 and also  arr[1][0] does not exist but the interpreter is result is 7. I am quite confused rn     arr =[[]]*3     arr[0].append(7)     print(arr[0])   #[7]     print(arr)      #[[7],[7],[7]]     try:        print(arr[1][0])  #7     except IndexError:        print("0")


which projection for preserving distances in USA (all 50 states)?

I have a shapefile of different administrative regions that are in all 50 states in the USA. I also have many lat/long coordinates, and I'm using NNJoin in QGIS to find the distance from each point to the nearest polygon.  I'm wondering which projection (if any) should I use to minimize distortion when calculating distances in the entire USA region? Or would it be better to do three batches, one for contiguous USA, one for Alaska and one for Hawaii (if so, which projections then)?


Do floating islands exists in pre-hardmode?

My friend says that Floating islands are in pre-hardmode, but I can't find them. Do floating islands exist in pre-hardmode?


How do I find all complex numbers $z$ such that $z^2+|z|=0$?

I need help solving this task, if anyone had a similar problem, it would help me. The task is:  Determine the complex numbers $z$ from the condition. $$z^2+|z|=0$$  By my logic, the solutions are : $-i$ and $i$. But I don’t know how to come up with those solutions.


PHP function returning MySQL syntax error

I don't think there is too much to explain here. The codes are self explanatory. I have written this function function checkDuplicate($table, $field, $value){   global $pdo;   $stmt = $pdo->prepare("SELECT COUNT(*) as cnt FROM :table WHERE :field = :value");   $stmt-> bindValue(':table', $table);   $stmt-> bindValue(':field', $field);   $stmt-> bindValue(':value', $value);   $stmt-> execute();   $f = $stmt->fetch();    if($f['cnt'] > 0){     return 1;   }else{     return 0;   } }  I call it this way if(checkDuplicate("members", "mem_uname", $uname) == 1){   echo alert_danger("An account with this username already exists.");   exit(); }  Calling returns this error Warning: PDOStatement::execute(): SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ''members' WHERE 'mem_uname' = 'shrey'' at line 1 in E:\xampp\htdocs\buxhost\includes\functions.php on line 35  What is my mistake here? Why am I getting that error? As far as I have checked multiple times, I did not find anything visibly wrong in my codes.


Why don't Voldemort and DEs spam Avada Kedavra?

I know that in order to successfully cast AK, you need to mean it and have a powerful mindset at that moment.   However during DH, in the RoR Crabbe is using it twice in a really short period toward Hermione.  My question is, why doesn't Voldemort/Bellatrix/other powerful Death Eaters spam AK to kill.  One could argue that Bellatrix likes to "play with her food before eat it" and Voldemort wants to prove that he's above everyone else, so he probably wants to give a showdown of his talent before killing the target. But if he was afraid of Dumbledore, why did he need to duel him in a spectacular way in OotP instead of spamming killing curses everywhere ? And every other Death Eater should spam it too...


Cannot access Windows after dual booting with Ubuntu on different drives

I recently tried to dual boot Ubuntu 18.04 with my Windows 10, but I messed up the installation and now I can't access Windows 10. Please note that Ubuntu is on a different HDD than Windows.   I tried update-grub, but it didn't work and the boot-repair displays the following message:     GPT detected. Please create a BIOS-Boot partition (>1MB, unformatted filesystem, bios_grub flag). This can be performed via tools such as Gparted. Then try again.   Alternatively, you can retry after activating the [Separate /boot/efi partition:] option.   Any ideas on how to fix that?


OnClick JavaScript Button, Invalid or unexpected token error

Here is the field I am trying to update, the far left is the picklist I am wanting to update. the field on the left is another picklist. both lists have the same values.   As you can see below I have tried a number of approaches. Is this possibly a limitation with the Javascript button?  Any help would be appreciated.   Example 1   00N5000000AIfdn = {!TEXT($User.New_Business_Admin__c)};   Error: Invalid or unexpected token error   Example 2   app.New_Business_Admin2__c = {!TEXT($User.New_Business_Admin__c)};   Error: Unexpected Token ; (I am not missing one nor do I have duplicates)   Example 3  app.New_Business_Admin2__c = '{!$User.New_Business_Admin__c}';   Error: Field New_Business_Admin__c is a picklist field. Picklist fields are only supported in certain functions.   Example 4  00N5000000AIfdn = {!$User.New_Business_Admin__c};   Error: Field New_Business_Admin__c is a picklist field. Picklist fields are only supported in certain functions


Do I need a transvit visa for a 2 days stay in London?

I am a Canadian PR holder with an Indian passport. I am planning to visit London for 3 days on my way to India. What kind of visa will I need? I will be going out in London and rent a car to see the whole city.


I have an array that randomly gets a coin put into it (denominations: 0.01, 0.05, 0.10, 0.25). The array is a Double array. It seems to work, but at times values get added that look like this:  [0.050000000000000003] [0.050000000000000003, 0.01] [0.050000000000000003, 0.01, 0.10000000000000001]   I'm not sure what I'm doing wrong to have these extra zeros show up.  Thanks in advance for any help.


Do LINQ operations return collections with the same indexes as collection being operated on?

If I perform .Select() on a collection, will the resulting collection share exact index values between the two collections.  Perhaps I haven't explained myself well. Here's what I mean:  int[] nums = new int[]{ 50, 100, 200};  var moreNums = nums.Select(num => num / 2);   Will moreNums[0] = 25? [1] = 50? [2] = 100?  Can you bank on this, 100% of the time? I always feel a sense of ambiquity with LINQ because of this. This is important because I have two lists where I can use a single index to refer to a pair of values between the two lists. I don't want my lists to go out of sync.


I've read and have heard of both 'as per' and 'per' being used conversationally, both with the same connotation of either 'according to' or 'on authority of'  Examples:  "Tell Ron to start molding new rollers for the mecanum wheels, as per me"  "Per Mr. Crane, you need to start the molds for the new rollers."  They both establish the same context by setting that something should be done on the authority of someone else (or the speaker, per the first example (see what I did there?)). Or it acts as a way to cite a source of a statement, directive or fact in conversational speech.  My question is, what is, if any, the functional and syntactical difference between as per and per. If there are no differences, which is apropos to use?


Why does 'ls > ls.out' cause 'ls.out' to be included in list of names?

Why does $ ls > ls.out cause 'ls.out' to be included in list of names of files in current directory? Why was this chosen to be? Why not otherwise?


Grep options for Regular Expressions. (ERE, BRE, Perl regex) differences

I am getting the hang of grep and regex, but I am confused about the different options.   grep --help | grep -i "reg.*ex"   -E, --extended-regexp     PATTERN is an extended regular expression (ERE)   -G, --basic-regexp        PATTERN is a basic regular expression (BRE)   -P, --perl-regexp         PATTERN is a Perl regular expression   I have a general knowledge of regular expressions, but often I find myself stumbling on the basics (e.g. Using '*' when it actually requires '.*'), which I blame on not knowing the differences between the types of regular expressions (ERE, BRE, Perl regex).  Is it explained somewhere in detail?


Let $a_1$ be an integer. Then we assume        $$ a_{n+1} = \begin{cases} 3a_n+1,&\text{$a_n$ is odd}\\ \frac{a_n}{2},&\text{$a_n$ is even} \end{cases} $$   Now we prove that     for any $a_1\in\mathbb N$, there exists $N$ which satisfy: $a_n=1,2$ or $4$,$n\geq{N}$.   At first I want to give it a suitable category for the problem: analysis. And I want to use the basic method: evaluate the upper bound for $a_n$, however I find it's not easy because the iteration is rely on the odd or even property of $a_n$. So I attempt the method of number theory. But I failed to find any way to go over it. Can anyone have idea? Thank you.


GeForce GT 710: Drivers installing forever

I recently had to reinstall ubuntu (albeit an old version, 20.04) since my Ubuntu installation suddenly stopped booting for some reason (nothing's wrong with the pc) But now when I try to install my GPU's drivers, it's just stuck at about 33%. It starts at this 33% and, even after an hour, it's still at 33%. How do I do this? I'm downloading from Software and Updates. I've stared at a motionless progress bar for an hour and I'm starting to lose my sanity, so I hope that I can get this installed. Edit: 5 minutes since I posted this, the progress bar still hasn't moved


Earth invaded by alien entities feeding on electricity

I'm looking for a book that was purchased in the late '70s or early '80s. The action takes place in the '60s to '70s. Some day a radio amateur was puzzled by a strange Morse code message he received. This message came from nowhere, or, more precisely, his gonio showed it was coming down from the sky. It turned out that this message was the first radio message ever broadcast by Marconi in 1897. The guy kept monitoring this source, and he got more and more messages, which were all identified as known historical messages. He kept getting more and more messages, the pace was accelerating, he got vocal messages, and within a few months he was overwhelmed by communication from WW2. One day he identified messages dating a few hours back, and then the catastrophe occurred: anything electrical started to malfunction, and some time later the entire Earth suffered a total electrical blackout. The Earth had been invaded by immaterial beings who were feeding on electricity and all kinds of electromagnetic waves. Humanity had to return to the "good old times" with horse carriages, watermills, etc.


I get an Image as a Blob from a database and want to draw it into a JPanel. If i run the following code nothing is drawn but there isn't an error. Can anyone tell me what's wrong? I Never worked with images in java...     Blob image = rs.getBlob("com_img"); Graphics2D g2; BufferedImage img; try {         img = ImageIO.read(image.getBinaryStream());         g2 = (Graphics2D)ImageIO.read(image.getBinaryStream()).getGraphics();         g2.drawImage(img,0,0, panel);         panel.paint(g2);       } catch (IOException e1) {         // TODO Auto-generated catch block         e1.printStackTrace();     }


Can “to punt something” mean “not to do something”?

Somewhere, I picked up the use of “to punt something” (or “to punt on something”) to mean “choosing not to do something” or “choosing not to do something now”. Examples:     The weather looks bad, let’s punt (on) the bike ride.   But I am having doubt that this is a correct use of the term, and I can find hardly any related references, so I am seeking clarification.  Also, is it to put something or to punt on something, or both?  Some of the possibly related references I found are:      Let’s extend all the tax cuts and punt again. ()   says:        Informal To cease doing something; give up: Let's punt on this and try something else.     Multiple slang dictionarlies ( and ), which maybe indicates that this used in computer jargon, but not in general English. According to , it is also business jargon.


I tried to solve this question but without success:     Find all the integer solutions of the equation: $x^2+y^2=3z^2$   I know that if the sum of two squares is divided by $3$ then the two numbers are divided by $3$, hence if $(x,y,z)$ is a solution then $x=3a,y=3b$. I have $3a^2+3b^2=z^2$ and that implies $$ \left(\frac{a}{z}\right)^2+\left(\frac{b}{z}\right)^2=\frac{1}{3} $$ so I need to find the rational solutions of the equation $u^2+v^2=\frac{1}{3}$ and I think that there are no solutions for that because $\frac{1}{3}$ doesn't have a rational root, but I dont know how to explain it.  Thanks


Regex for Word not have some specific words before

I am Looking for Regex for this result  String = This is Cold Water and this is Hot Water, have some Water.  I want to check whether this String has the word 'Water' which doesn't have these 'Cold' and 'Hot' words before it.  String mydata = "This is Cold Water and this is Hot Water, have some Water"; Pattern pattern = Pattern.compile("[^(Cold|Hot)]\sWater");     Matcher matcher = pattern.matcher(mydata);     if (matcher.matches()) {         String s = matcher.group(1);         System.out.println(s);     }   But it is resulting a no match


Why does the slope of the same coefficient change when we add new variables?

There is this question that I could not really find an answer to online. Let's say that we do a simple linear regression model with y and x1, and we compute the slope of x. Then, we make a multiple linear regression model with y, x1, and x2. But now the slope of x1 changed. Why is that?


What a beginner should know/learn for sysadmin job?

This is a  about System Administration Careers   When I start my job as System Administrator, what basics skills should I know/learn?  Are there any key differences for Network, Storage, Database, and other Administrators?


sed search and replace with variable containing slash

I am trying to replace a string inside a text file with a variable.  I am using this code:   sed -i "s/search text \/TAG\//replace text ${variable}/" ${textfile}   The content of the variable is /newTAG/. And the content of the variable is the problem, more accuratelyte the / at the beginning and the end.   When both / are removed so the content is only newTAG everything works fine.  I already tried the following  sed -i "s/search text \/TAG\//replace text "${variable}"/" ${textfile} sed -i 's/search text \/TAG\//replace text "${variable}"/' ${textfile}   Can anybody help me? Thanks


Array.push() won't update Lightning Web Component View

We are migrating over to Lightning Web Components in the last couple of weeks now and we had some struggles with the arrays in Javascript. On a trackable array, when I call push in a wiredMethod, Array.push won't update the view. We found a workaround but I was wondering if there is a more elegant solution to this. Please take a look at the code snippets:  import { LightningElement, wire, track } from 'lwc'; import getData from '@salesforce/apex/LWCController.getData';  export default class myLWComponent extends LightningElement {     @track error;     @track dataArray = [];     @track processedArray = [];      @wire(getData)     wiredMethod({ error, data }) {         if (data) {             this.dataArray = data.arr;             this.dataArray.forEach(function (value) {                 // do some work on data here                 this.processedArray.push(value);             }         } else if (error) {             this.error = error;         }     }                  }   And on the view here:  <lightning-card title="Card Title">     <template for:each={processedArray} for:item='item'>         {item.title}     </template> </lightning-card>   Here is our workaround:  export default class myLWComponent extends LightningElement {     @track error;     @track dataArray = [];     @track processedArray = [];      @wire(getData)     wiredMethod({ error, data }) {         if (data) {             this.dataArray = data.arr;             let tempArray = [];             this.dataArray.forEach(function (value) {                 // do some work on data here                 this.tempArray.push(value);             }             this.processedArray = tempArray;         } else if (error) {             this.error = error;         }     }                  }   As you can see from the work around, if we set array to the temp array, framework understands that the array is updated and updates the view accordingly. We also tried setting values as follows which didn't work:  this.processedArray[index] = value;   We are wondering why push doesn't work and/or if there is a better way to do this.


Is $\operatorname{Quot}(R)/R$ an injective $R$-Module?

Let $R$ be an integral domain. Is the $R$-Module $\DeclareMathOperator{\Quot}{Quot}\Quot(R)/R$ injective? ($\Quot R$ denotes the fraction field of $R$.)  By Baer's criterion it is sufficient to show that for any ideal $J \trianglelefteq R$, all $R$-linear maps $J \to \Quot(R)$ are of the form $a \mapsto c a$ for some $c \in R$. The statement is true if $R$ is a PID because $\Quot(R)/R$ is a divisible $R$-Module.


So I tried looking through the various other questions but they mostly focus on disabling the middle mouse paste.  Basically the middle mouse button on my Logitech G500s is broken, and it keeps "clicking" randomly so it's screwing up any chance of doing work.  Is there any way to disable it? Or map it to nothing?  Thanks and sorry if this is a duplicate.  xinput list output:  ⎡ Virtual core pointer id=2 [master pointer (3)] ⎜   ↳ Virtual core XTEST pointer id=4 [slave pointer (2)] ⎜   ↳ Turtle Beach Turtle Beach PX3 (XBOX) id=8 [slave pointer (2)] ⎜   ↳ Logitech G500s Laser Gaming Mouse id=9 [slave pointer (2)] ⎜   ↳ Logitech G500s Laser Gaming Mouse id=10 [slave pointer (2)] ⎜   ↳ Razer Razer DeathStalker id=12 [slave pointer (2)] ⎜   ↳ Razer Razer DeathStalker id=13 [slave pointer (2)] ⎣ Virtual core keyboard id=3 [master keyboard (2)]     ↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]     ↳ Power Button id=6 [slave keyboard (3)]     ↳ Power Button id=7 [slave keyboard (3)]     ↳ Razer Razer DeathStalker id=11 [slave keyboard (3)]


Science fiction short story with blind woman one cannot tell is blind

Short Story of man wandering who comes across area with strange ground, topography. Meets young woman who is barefoot. He eventually learns she is blind but can move without limitations because her world is designed to allow full functionality for the disabled. The story is forty maybe fifty years old.


Attaching a custom javascript library to a Drupal module

I am trying to attach a custom js library to the contact module. Here is the content of my js/custom.js file: function myFunc(){    console.log('hello toto'); }  document.addEventListener('click', myFunc, false);  Here is the content of contact.info.yml: name: Contact type: module description: 'Provides site-wide contact forms and forms to contact individual users.' package: Core # version: VERSION core: 8.x configure: entity.contact_form.collection  # Information added by Drupal.org packaging script on 2020-10-07 version: '8.9.7' project: 'drupal' datestamp: 1602100551 libraries:   - contact/custom  and contact.libraries.yml: custom:   version: 1.x   js:     js/custom.js: {}  However, the custom.js library is not listed in js files when I open the contact page... Can someone please help?


Phone forgetting networks after turning off wifi

Whenever adding a new wireless network, android seems to forget the network after disabling then re-enabling wifi. I am forced to manually connect to the network and enter the password each time. This also happens with open networks. The problem occurs on any wireless network, at home, work, public networks, etc.  Further inspection on the /data/misc/wifi/wpa_supplicant.conf file shows "disabled=1" added to the end of each network.    click image for larger version  This has been going on for weeks. Any help would be much appreciated.  Phone: Nexus 4 Version: 4.4.4


I have 238gb of timelapse photos which was taken over a period of twenty days and all the photos are split up into 20 folders. I would like to put this together into a timelapse, I tried using Premiere Pro but that is taking very very long, any tips on putting it together fast btw Im on a Mac, thanks.


Find the limit of: $\lim_{n\to\infty} \frac{1}{\sqrt[n+1]{(n+1)!} - \sqrt[n]{(n)!}}$

Could be the following limit computed without using Stirling's approximation formula?  $$\lim_{n\to\infty} \frac{1}{\sqrt[n+1]{(n+1)!} - \sqrt[n]{(n)!}}$$  I know that the limit is $e$, but I'm looking for some alternative ways that doesn't require to resort  to the use of Stirling's approximation. I really appreciate any support at this limit. Thanks.


Unable to install anything on Ubuntu server 16.04.3 (openssh for example)

I've just installed Ubuntu Server 16.04.3. During the installing I kept getting the message:     select and install software failed   I have no idea why. I'm not an expert so I had no idea on how to find any reason why that kept happening. Anyway, the OS seemed to have installed just fine so I figured to just install OpenSSH through command line.  First I tried: sudo apt install openssh-server. That resulted in the request of the CD. So I modified etc/apt/sources.list and commented out the cdrom entry as advised here:   Of course I did sudo apt-get update after. Which strangly enough returned Reading package lists... Done straight after.  After that I tried installing OpenSSH again, which resulted in:  Unable to locate package openssh-server.  So perhaps there was something wrong with my internet connection, but ifconfig gave me the network interface with the ipaddress I expected. So I think that's working fine.  Next I found some advise to run:  sudo rm var/lib/apt/lists/* and do sudo apt-get update after. Tried this, but no effect.  I have a feeling my installation simply has no repositories listed at all and therefor can't find any packages of course. Unfortunetely, if this is the case, I have no idea on how to fix it. Any advise would be welcome!


Why do neutrino oscillations imply nonzero neutrino masses?

Neutrinos can pass from one family to another (that is, change in flavor) in a process known as . The oscillation between the different families occurs randomly, and the likelihood of change seems to be higher in a material medium than in a vacuum.   Why does the oscillation of neutrinos directly imply that they must have a nonzero mass, since the passage of one flavor to another can only occur in massive particles? And What are the cosmological implications of these oscillations?


Keyboard stopped detecting multiple keypresses

I have been playing CSGO on my Lenovo Ideapad 300-15isk for more than two years. Few days back when I was playing CSGO multiple keypresses stopped working. It still detects two keys pressed at once. But, it is not detecting more than two keys. Now I can't move diagonally while shooting or I can't shoot while crouch moving. This is really annoying and the game is almost unplayable. What could be the reason behind it and how to fix it?


Repeating label on every page, not header, not tabular, but multicol

How can I print repeating label on every page in first column?  The example below, I would like to repeat \plab on other pages at the same place. It is not header actually.  \documentclass{article} \usepackage{multicol} \usepackage{lipsum} \usepackage{geometry} \usepackage{xcolor}  \geometry{  a4paper,  landscape,  margin=1cm  } \newcommand*{\plab}{ {\LARGE label1} \\ \textcolor{gray}{\rule{\columnwidth}{2pt}} \par }  \begin{document} \begin{multicols*}{3}   \plab  \lipsum[1-20]  \end{multicols*} \end{document}   EDIT: I found very simmilar need and solution on TEX at   But I am not able to make it working in my example, though.


I took my D4 out for a walk yesterday. Out of nowhere it started to rain heavily. Of course I did not have any cover or whatsoever with me. I walked about 20 minutes with it through the rain back to the car. I was not worried too much since I had used other Nikon DSLRs in heavy rain multiple times in the past and they never let me down. Back in the car I turned on the camera to check if everything is okay and the camera did turn on. I did not take a picture, I just checked the upper display. I let the camera dry over night. This morning I wanted to use the camera and she did not turn on. The upper display was indicating the battery was empty so I took out the battery to charge it. In this moment I realized, that the battery was a little bit wet. I immediately got a hairdryer to get possible moisture out of the battery compartment. A few hours later the battery was fully charged and I placed it back in the camera but the camera wont turn on. When I put in the battery the upper display shows an empty battery symbol. I also tested a second battery which wasnt in the rain with me yesterday. When I turn on the camera the green LED on the back lights up for a second as normal and also the backlight of the buttons and display work fine but I cant use the camera. Of course when nothing helps I will have to get the D4 to a dealer but maybe you have some suggestions for me. Please let me know. EDIT: I sent the camera to Nikon and they sent it back immediately without even opening it because they dont have replacement parts for it. However I wont give up on my D4. I cant accept to sell it as defective. I opened the body and just like I assumed there was corrosion on the power board:  I cleaned everything from all sides with alcohol but camera still doesnt turn on. Do you know a place/person where I can get a replacement for this board? I cant find anything on ebay. If I cant find anything I might get down to component level repair. Im pretty sure the rest of the camera is fine. I guess there is a tiny transistor or cap that might be blown.


Write solution(s) of $z$ in the form $a + bi$

$z$ is a complex number. I have to write its solution(s) in the form $z= a +bi$ given that :  $$ z^2 + 1 - i = 0 $$  I put $1 -i$ on the other side and took the root. That would give $z= \sqrt{-1+i}.$ I tried to manipulate $ -1+ i,$ obtaining $ z=i \sqrt{1+i^3} $ but that doesn't help me further.   Thanks for your help.


Strings are equal, but if-statement doesn't trigger

I'm trying to construct my own expressions evaluator based on the Shunting-yard algorithm. I'm having difficulty adding String objects to the stack I have though. My code just skips over these lines every time, even when the condition is met. Any suggestions? I have the operatorStack declared as:  Stack operatorStack = new Stack();   I'm thinking that it has something to do with my if statement. I've tested it with the Eclipse debugger and when the currentChar variable shows as "(" it still skips over the push to the stack.  Here is the excerpt in question:  int count = 0; String currentChar=new String();  //While loop to test for the conditions stated in the Shunting-yard algorithm. while (count<=temp.length()) {      currentChar = temp.substring(count, count+1);     if(currentChar == "(")         operatorStack.push(currentChar);      if(expressionEval(currentChar) instanceof Integer)         outputQueue.offer((Integer)expressionEval(currentChar));      if(currentChar == "+" ||                 currentChar == "-" ||                 currentChar == "<" ||                 currentChar == "?") {          while(operatorStack.peek() == "+" ||                            operatorStack.peek() == "-" ||                            operatorStack.peek() == "<" ||                            operatorStack.peek() == "?") {             outputQueue.offer((Integer)operatorStack.peek());             operatorStack.pop();         }          operatorStack.push(currentChar);     }


why the value duplicated in all the list elements?

I have a list with the following structure: l = [[[],0]] * 5  each node in the list contains another list:  first element in the inner list contains another list second element in the inner list contains wight  I'm trying to add value to the inner list: index = 0 l[index][0].append('s')  but it add the values 's' to all list (l) values: l = [[['s'],0], [['s'],0], [['s'],0], [['s'],0], [['s'],0]]   why the value 's' duplicates to all the list element ? how can I add the value 's' only to the first inner list (i.e l = [[['s'],0], [[],0], [[],0], [[],0], [[],0]])  Python 3.6.8


How to show that $\text{tr}\left(A^T B\right) \le \|A\|_{op} \|B\|_1$?

Let $A$ and $B$ be two matrices. How can I prove that $$ \text{tr}\left(A^T B\right) \le \|A\|_{op} \|B\|_1$$  where $\|\cdot\|_{op}$ is the largest singular value of $A$, and $\|B\|_1$ is the sum of all singular values of $B$? I can see this is true if $A=B$ by using SVD, but don't know how to prove this more general statement.


Is there an advantage to use a Synchronized Method instead of a Synchronized Block?

Can any one tell me the advantage of synchronized method over synchronized block with an example?


This might be a technical question or maybe there's a better way of approaching the area but what is the best interaction for asking users to select either an unknown or the specific items.


Bought new computer, downloaded Ubuntu, want to wipe Windows 10 and get started

I bought a new computer and downloaded Ubuntu. I want to wipe  Windows 10 and get started with Ubuntu. What do I do first ?


What GUI applications are there to assist in generating graphics for TeX?

I found  to be a useful tool to help generate code for graphs. I suppose there must be other tools to help draw diagrams such as Sets/Venn Diagrams or Electrical Circuits (Logic Gates). Which ones would you suggest?


How to format my HDD when installing Ubuntu?

How do I format the hard drive on my machine before installing?


Filtering text through a shell command in Emacs

In vi[m] there is the  through a shell command -- like sort or indent -- and get the filtered text back into the buffer. Is there an equivalent in emacs?


DDoS attacks are killing all my services

I've a few servers running as ssh proxy, someone started to DDOS me, i've installed ddos deflate and apf. The traffic made by ddos downgrade from 10 MB/s to 1 MB/s but it still make my users kick from my servers. My question is: if I make a rule to monitor all my traffic and lock new connections when someone start ddos will work? I mean, lock new connections and keep the others running!


How to visualize the possibility of drag'n'drop?

My web application contains a list of elements, which can be sorted by drag'n'drop. How should this feature be visually represented to users?


Way to Reboot and Restore All Programs, ETC on Restart

I am looking for a way that I can reboot my desktop pc and have it restart in the same state as when it shut down, e.g. all programs/files I had opened, etc.   I guess I am looking to do something similar to a hibernate sleep/wake on a notebook.   Is this possible on a desktop pc with a full reboot?  Is there any software for this?   I am NOT looking to recover any UN-Saved work, etc, but rather, to restore my desktop to its same state e.g. same programs and documents open, etc.  I am running a windows based x64 PC with windows 7 professional.


I'll tell you the story of how I started to notice the problem with my PSU. I was just playing some minecraft, just doing my thing when I started to hear a strange buzzing noise from my PC. So i opened it up to so what was up. I couldn't clearly hear where the noise was coming from. So I took off both of the side panels and heard it was coming from the PSU.  After this I started looking up online for what this might be. At this point I should tell you my hardware. I'm running an RTX 2080 and I5-9600k with my PSU being a 750W MasterWatt from coolermaster.  I came across this post from Dante R.    I thought, hey this guy has the same GPU as me. He might have the solution. But in his post the problem was with the GPU, not the PSU. So I went back to checking if it indeed was my GPU. But after listening closely I could clearly hear it was coming from my PSU. (Which is why I posted this Question since the other post was fixed by fixing the GPU)  Here is a video so you can get an idea of what it sounds like.   Afterwards I did some testing as to why it only started when I was playing Minecraft. I loaded up Prime95 to do some CPU stress testing... no noise. I launched up Heaven Benchmark... As soon as my GPU started doing it's thing, the noise came back! So it has something to do with GPU aswell.  From what I read I think it may have something to do with Coil Whine. And if so,can it be dangerous for my PC and how can I stop it?  So I'm looking for any advice you lovely people can give me on how to stop this problem.  Thanks in advance!


get list item by id using COM sharepoint 2013

I need to get item from list sharepoint by Id I use this code and it give me all the items of the list :     so how can I get only the considered item ?


Here's Some Pics Of Forks SR Suntour V3s !    ![enter image description ![


Where can I find an online General Relativity course(s)?

Not sure if this is the right place to ask, but all well, I will ask anyway...    I am hard-pressed with finding an online course that teaches General Relativity in full. I would like to learn General Relativity but I cannot seem to find anything on Google. Is there an online course or courses (free or paid, it doesn't matter to me) that someone can recommend or show me? Maybe it's a University that offers it, and I would be fine with that.  Note: I am a beginner to General Relativity.


Completely delete a folder in Windows using command line

I need to delete one folder containing other folders and files inside. I tried del and rmdir commands but sometimes they fail with some error lines: [PATH]: The directory isn't empty.  Is there any good alternative?


Where does the energy come from when a magnet moves a compass?

My very limited understanding of magnetism is that it is essentially stored energy. However what I'm confused on is about the following situation: If you have a compass and you move a magnet close to it the compass will move. My question is, where is that energy coming from? Is the magnet losing some magnetism or energy related to the magnetism? And if so does that mean that a "permanent" magnet would actually lose magnetism faster if you were to bring it around things that react to magnets easily than if it were left in an area devoid of such things?


Someone who appears more of an expert than they are

I believe there is a term for a person who uses 'expert sounding' terminology and exudes confidence, even when their actual abilities are significantly short of their 'presentation'.  Using 'wine' a subject.... if a person described a taste as:     Magnificent bouquet, the esters resonate with hints of mulberry and   asparagus. This must be an oak-matured red from Bordeaux. Perhaps....   2003 vintage, that was a year when unusual rainfall produced an   outstanding crop that had the same rich tannins.   A person describing the wine like that has apparent confidence, apparent technical expertise, and so on. Yet, if he was a fraud, and knew nothing about wines, and the "wine" was really vinegar.... what would you call that person? Additionally, this would not be a one-off thing. This would be a person who consistently "bamboozles" people, and only when you dig below the posturing, or put them in the company of a 'real' expert, do you see the reality.  A fraud, a cheat, an imposter. Those would be true, but I'm sure there's a word which also covers the confidence, charisma, and presentation style too.  I just can't think of it.


Where does Google Chrome automatically save pages?

I opened the following page:   When disconnecting WiFi and even after rebooting the mobile phone, the page can still be read due to being saved automatically.  Left to the URL bar, an indicator looks like this:  This also shows up when opening manually saved pages, which are saved as MHTML files in the default download folder.  However, an automatically saved page can not be re-downloaded manually to get to the download folder, because the arrow is greyed out.I wish to copy some automatically saved pages into the download folder.  Where are the files of automatically saved pages stored?


I saw some scenarios that used the structure "to + V-ing", such as the following:   Looking forward to hearing. Disposed to using few words. I would like to apply what I learned in school to helping make more money. This is the closest we have come to winning the league.   When can I use this structure? I'm confused about that.


How to find the solutions of a^2 = [29] mod 35?

How to find the solutions of: $$a^2 = [29]_{35}$$ ?  (Brutal) Attempt: Since $Z_{35}$ contains only 35 elements, one could just brute force the calculation of $a^2$ for every element a $\in Z_{35}$ that GCD(a,35). When you find a number that verifies the equation, automatically you find another solution which is the inverse of that solution $\in Z_{35}$.  Do you know any non brutal way?  NOTE: it doesn't have to require the quadratic congruence solving (I have only studied linear congruences)


Why are oscillations so ubiquitous in nature?

I'm aware that you can always approximate a potential by a quadratic term. But is this the most 'fundamental' reason for the pervasiveness for oscillations?


How can I use int.TryParse with nullable int?  I am trying to do something like the following, which doesn't compile, obviously.   int? nr1 = int.TryParse(str1, out nr1) ? nr1 : null;  What is the correct way to achieve it?


Terminal : needs full path to execute a command

Let's suppose i have an application in /Applications/MacPorts/KDE4/myapp.app/Contents/MacOS/myapp.  When i use cd to reach the directory 'MacOS' and then issue the command myapp it says command not found.  But when i issue the command with the full path like /Applications/MacPorts/KDE4/myapp.app/Contents/MacOS/myapp it works.  I had the same problem with mysql inside xampp.  Why is that?


What is the Difference Between Controllers and Extensions?

Can any one explain the usage of controller and extensions in Visualforce? In which scenario we have to use controller and extensions?


What is the difference between visibility:hidden and display:none?

The CSS rules visibility:hidden and display:none both result in the element not being visible. Are these synonyms?


If nothing can travel faster than the speed of light, how can there be parts of the universe we can't see?

Assuming we originated from a single infinitely dense point in space time in the big bang, how can there be parts of the universe that we can't see as the light has not reached us yet, if nothing can travel faster than the speed of light relative to our frame of reference? Is that because the universe can expand faster than the speed of light? Or am I missing something?


Why is my shadow deformed and not the shadow of the ceiling?

Look at these two photos of my shadow from sunlight.  Case 1: My shadow is separated from the shadow of the ceiling and my head is round.  Case 2: But when I walk a little more and the shadow of my head and the shadow of the ceiling are almost together, the shadow of my head tends to deform. Why?  Edit: Ok. The deformation is because the sun is not a point source and there are fuzzy shadows. But when I look the second picture only my head is deformed and not the ceiling, why?   Here is another picture.


Whenever I open a terminal, I always end up with this same error.  -bash: export: `/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/bin:/usr/local/hadoop/bin': not a valid identifier   And when I run command lines, I get errors like this:  -bash: sudo: No such file or directory   I can't even edit ~/.bashrc through gedit ~/.bashrc which I think could be the problem. echo $PATH gives me an empty line.  All this stuff happens under my personal account. There's a dedicated hadoop user account, which I created specifically for running hadoop and that works fine without a glitch.  In the process of hadoop setup, which involves editing environment variables, I edited ~/.bashrc as instructed by some tutorials.   What could be the problem, and how might I fix it?


Converting standardized betas back to original variables

I realise this is probably a very simple question but after searching I can't find the answer I am looking for.  I have a problem where I need to standardize the variables run the (ridge regression) to calculate the ridge estimates of the betas.   I then need to convert these back to the original variables scale.  But how do I do this?  I found a formula for the bivariate case that  $$ \beta^* = \hat\beta \frac{S_x}{S_y} \>. $$  This was given in D. Gujarati, , page 175, formula (6.3.8).  Where $\beta^*$ are the estimators from the regression run on the standardized variables and $\hat\beta$ is the same estimator converted back to the original scale, $S_y$ is the sample standard deviation of the regressand, and $S_x$ is the sample standard deviation.  Unfortunately the book doesn't cover the analogous result for multiple regression.  Also I'm not sure I understand the bivariate case? Simple algebraic manipulation gives the formula for $\hat\beta$ in the original scale:  $$ \hat\beta=\beta^* \frac{S_y}{S_x} $$  It seems odd to me that the $\hat\beta$ that were calculated on variables which are already deflated by $S_x$, has to be deflated by $S_x$ again to be converted back? (Plus why are the mean values not added back in?)  So, can someone please explain how to do this for a multivariate case ideally with a derivation so that I can understand the result?


Is $\lim \space (n \sin n)= +\infty$ , or $\lim \space (n \sin n)= -\infty$ , or none of these?

Is the sequence $(n\sin n)$ properly divergent i.e. do we have $\lim \space (n \sin n)= +\infty$ , or $\lim \space (n \sin  n)= -\infty$ ? ( I think the answer is know because $(n)$ is increasing unbounded but $(\sin  n)$ is bounded and divergent i.e. oscillating , but that is just a justification not a proof , I would really appreciate a rigorous proof )


Evaluate   $$ \lim_{n\to+\infty}\frac{1}{n}\sum_{k=1}^n\Big[\frac{2n}{k}\Big]-2\Big[\frac{n}{k}\Big], $$   where $[x]$ means the largest integer that no more than $x$.   Let $\Delta=\Big[\frac{2n}{k}\Big]-2\Big[\frac{n}{k}\Big]$, I found that  $$ \Delta= \begin{cases} 1,&\mbox{$\Big[\frac{2n}{k}\Big]$ is odd.}\\ 0, &\mbox{$\Big[\frac{2n}{k}\Big]$ is even}.\end{cases}   $$  By trying several cases for small number, I found that the cases $\Delta=1$ are quite rarely.


Application icon not displaying for running app

I created a .desktop file for an AppImage application that I downloaded. The icon I used for the application displays on the application screen and on the side-bar but not on the running application on the side-bar. So when I click on the application it starts running and creates a new icon in the side-bar but the new icon has no image and does not display the one specified in the .desktop file. The main application icon still displays correctly but not the icon for the running application. Hopefully this explanation makes sense...if not I can provide a screenshot to display what I am talking about. Is there a way I can make the running application icon use the same icon as the docked application icon specified in the .desktop file? Thanks


How to play encrypted dvds on ubuntu 12.04

I am trying to play a movie on ubuntu and it will not work. It tells me that I need to install dvd decryption. I was researching online and found out that I need to install libdvdread4, I did that. I also read that I needed to install libdvdcss, and this is where there was a problem. I ran:  sudo /usr/share/doc/libdvdread4/install-css.sh into the terminal and got the following:  --2013-10-10 20:52:33--  http://packages.medibuntu.org/dists/precise/free/binary-i386/Packages Resolving packages.medibuntu.org (packages.medibuntu.org)... 88.191.127.22 Connecting to packages.medibuntu.org (packages.medibuntu.org)|88.191.127.22|:80... connected. HTTP request sent, awaiting response... 404 Not Found 2013-10-10 20:52:33 ERROR 404: Not Found.  Dynamic fetch failed; Falling back to static fetch --2013-10-10 20:52:33--  http://packages.medibuntu.org/pool/free/libd/libdvdcss/libdvdcss2_1.2.10-0.2medibuntu1_i386.deb Resolving packages.medibuntu.org (packages.medibuntu.org)... 88.191.127.22 Connecting to packages.medibuntu.org (packages.medibuntu.org)|88.191.127.22|:80... connected. HTTP request sent, awaiting response... 404 Not Found   I am wondering if there is any other way to install libdvdcss. Thanks


what if set x.domain.com and y.domain.com to the same ip address in DNS?

if I set x.domain.com and y.domain.com to the same ip address, Does it mean Nginx couldn't tell the differences between x.domain.com and y.domain.com?  Is it impossible to map x.domain.com and y.domain in the server directive in the server context to the different folder?  I also want to learn more about how the computer network work? Anyone could give me some resources?


How can I distinguish a terminal window (GUI) from a console (CTRL+ALT+F3)?

I use a coloured bash prompt like so:  blue=$(tput setaf 4) reset=$(tput sgr0) bold=$(tput bold) export PS1='($?) \[$bold$blue\]\u@\h:\w\[$reset\]$(__git_ps1)> '   I usually work in a terminal window (gnome-terminal) but sometimes in a full-screen console (CTRL+ALT+F3).   My coloured prompt is fine in the GUI terminal but hard to read in full-screen because the colours look different. So I'd like to use a different colour (e.g. cyan=$(tput setaf 6)), when in console window. For this to work I need to figure out which mode I'm currently in and set my $PS1 accordingly.  I tried the tty command. It gives  /dev/pts/0  # GUI terminal /dev/tty3   # console    I also tried to examine the value of $TERM. It gives  xterm-256color  # GUI terminal linux           # console   Both of them would work for me but my question is: Is that the correct way to reliably distinguish console vs. terminal or are there better ways? I'm on 17.10.1 if that matters.


How do I autorun a file when a USB drive is inserted in another computer?

Some guy in my class shut my pc down while I was working on something. I want to get him back by automatically running a file after having inserted a USB in his USB port. The computers at our school run windows 7 and are even allowed to open cmd as an administrator. Is there a relatively easy way to do that? (And I have tried shutting it down remotely, but I I just got a response saying: "Access denied (5)")


A real life example for the linear transformations

This was what I wanted to say in my previews questions. I need a real life example that can be solved only with linear transformation. I will be verry grateful if you can give me a problem and it' s solution. Bun I really need a "real life application". I cound't find what I wanted anywhere and I hope that maybe this time I was more specific.


I have a panel on which I have drew several shapes, text and added picture boxes dynamically. I want to take a screenshot of the panel so I can save it. I tried the code below but it only gives me the panel's background image and the child controls, the drawings are missing. Help!  Bitmap bit = new Bitmap(pnlKanvas.Width, pnlKanvas.Height); pnlKanvas.DrawToBitmap(bit, new Rectangle(0, 0, bit.Width, bit.Height));


(Potentially) Low GPA with No Reserach Experience, Am I Screwed for math PhD program?

I am a Japanese junior student who is thinking of applying to the PhD program(Applied Mathematics/Statistics) in the U.S. for the 2021 cycle, but I think I have an incredibly low chance to be accepted to any programs.  Firstly, my GPA is really bad compared to other applicants. I have seen GPA of applicants on  and most of the people in that forum have at least a GPA of 3.8 or even 4.0. However, my overall GPA until the first semester of junior year was 3.48/4.0(Math GPA 3.5), which is really low for grad school. This was because I took too many courses and could not handle some of them(did not fail any but low grades). Moreover, my GPA in the third quarter this year is not going to be good because my grade in a literature class(it was mandatory to take it) is going to be C in S(4)-A(3)-B(2)-C(1) grading and I messed up in quantum mechanics exam. Grades in math classes are not going to be all S too. I am trying to get nice grades in this fourth quarter, but it will not be as good as average applicants.  Secondly, I literally have no research experience. From what I have seen, college students in the U.S. have an opportunity to do REUs. However, it is not the case in Japan. Math majors are not even expected to write a senior thesis and research opportunities are very limited here. I have asked my advisor about this but could not get any good results.  I still have not taken GRE, but from what I have heard, the GRE score does not matter as long as it is not astronomically bad, which does not help in my case.  Should I just give up or is there anything I can do?