i want to call the mainActivity in getView override method .....it showing Fatal exception..how to resolve it

mainActivity.java  public class MainActivity extends AppCompatActivity {      ListView listView;     ListViewAdaptor adapter;     TextView txtname1,txtrank1;     RelativeLayout relativeLayout;     Context context;     ArrayList<String> name;     ArrayList<Integer> rank;     int highestRank = 39;      public MainActivity() {     }     @Override     protected void onCreate(Bundle savedInstanceState) {         super.onCreate(savedInstanceState);         setContentView(R.layout.activity_main);          listView = findViewById(R.id.listview);         relativeLayout = (RelativeLayout) findViewById(R.id.rlFloter);         txtname1 =  findViewById(R.id.txtName);         txtrank1 =  findViewById(R.id.txtRank);          name = new ArrayList<>();         rank = new ArrayList<>();         for(int i=1 ; i<40 ; i++){             name.add("Winit Employer"+i);             rank.add(i); }         txtname1.setText("Winit Employer39");         txtrank1.setText("39");         adapter = new ListViewAdaptor(this,name,rank);         listView.setAdapter(adapter);     }      public void visible() {         txtname1.setVisibility(View.VISIBLE);         txtrank1.setVisibility(View.VISIBLE);     }      public void gone() {         txtname1.setVisibility(View.GONE);         txtrank1.setVisibility(View.GONE);     }      public void toast() {         Toast.makeText(context,"Toast",Toast.LENGTH_LONG).show();    } /////////////   ListView_data.java  public class ListViewAdaptor extends BaseAdapter {      private final Context context;     ArrayList<String> name;     ArrayList<Integer> rank;     Integer highestRank = 39;     MainActivity ma = (MainActivity) getActivity();      public ListViewAdaptor(Context context,ArrayList<String> name, ArrayList<Integer> rank) {         this.name = name;         this.rank = rank;         this.context=context;     }      @Override     public int getCount() {         return name.size();     }      @Override     public Object getItem(int i) {         return i;     }      @Override     public long getItemId(int i) {         return i;     }      @Override     public View getView(int i, View view, ViewGroup viewGroup) {         LayoutInflater inflater = (LayoutInflater) this.context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);         View rowView = inflater.inflate(R.layout.listview_data, null);          TextView txtname = (TextView) rowView.findViewById(R.id.txtName);         TextView txtRank = (TextView) rowView.findViewById(R.id.txtRank);          txtname.setText(name.get(i));         txtRank.setText(rank.get(i).toString());      main.visible();//hear it shows error          if(highestRank == rank.get(i)){           main.gone();             main.toast();          }         return rowView;      }  }     Logcat  AndroidRuntime: FATAL EXCEPTION: main  Process: com.example.akash.listview_frame, PID: 7445  java.lang.NullPointerException     at android.widget.Toast.<init>(Toast.java:93)    at android.widget.Toast.makeText(Toast.java:241)    at com.example.akash.listview_frame.MainActivity.toast(MainActivity.java:66)    at com.example.akash.listview_frame.ListViewAdaptor.getView(ListViewAdaptor.java:60)


I have taken a look at other questions, and I don't see any answer to my question. If this is a duplicate for some question I haven't seen, feel free to comment.  I am an experienced TeX user, I've been writing with TeX for about 3-4 years now. I am pretty good with TikZ too. The problem is, all that I have learned comes from one of my teachers that gave me packages so that I don't have much to worry about, and I never got in the technical stuff on my own (or at least never understood a thing of it).  I want to write a book, so I need to be able to deal with stuff like margins, labels, pagination, separating my TeX files into many files so that I don't have to compile the whole book each time I wanna remove/add a comma, etc. I am looking—not for a user manual that states what all commands do like a dictionary, because I know there are plenty out there and I have some—but rather like an introduction to using a book class, with examples and such. If you know what I'm talking about, the PGF-TikZ pdf is a great example of a such PDF ; it describes commands, yes, but there are plenty of examples and little commands are usually detailed while constructing a bigger example.


How does uncertainty of observations propagate through linear regression fits

I'm quite new to statistics, so please bear with :)  I'm trying to estimate the uncertainty of a variable which is predicted using a linear equation. The linear equation is estimated with a series of observations. These observations have uncertainty in them.   I have dependent variable Y, an independent variable X, and an uncertainty in Y of u    Doing a linear regression produced the following parameters    Now, when I use the parameters and predict a Y value for an X lets say X = 4.5. With the parameters, we get a Y = a*4.5 + b  Doing Root Square Sum on Standard Errors of a and b gives 0.1426.   Is this the right way to estimate uncertainty from a linear regression prediction. Also this does not seem to take into account the uncertainties in the initial U of Y.   Sorry if this is a trivial question, but any help is much appreciated.  Thanks


Restrictions on the use of universal generalization

I am currently reading a book on natural deduction, and it states that for universal generalization or $\forall$-introduction, defined as:  $$\frac {\phi[t/x]} {\forall x \phi}$$  The following restrictions apply:   The term $t$ cannot occur in any undischarged assumption of the derivation of $\phi[t/x]$ The term $t$ cannot occur in $\phi$   The first of these restrictions is easy to understand, but for the second I just can't quite understand why it is needed?  In the process of going from the top formula to the bottom, you replace all instances of t with x, so therefore $\phi$ should have no $t$'s in it.  Therefore, what's the use of a restriction on a situation that can never occur?  Can someone give me a (realistic) example of where this restriction may be needed?


What is `. command` means and how it works in Linux?

Example when start a Virtualenv of python. It will need to type . someenv/bin/activate. However, even if it works fine, I still a little bit confuse about how it works.  Is there anyone who can give me a explanation in more general view about . command in shell?


Is Cyclops’ mutant power just an organic version of Iron Man's repulsor tech?

They occupy the same universe so we have to assume the same physics apply. Iron Man's repulsor tech is described as an inertia-less one-way kinetic blast. At higher energy levels, it can can even disintegrate matter in front of it. Cyclops’ eye beams are described exactly the same way. Is there any place in comics or the animation where the two beams are shown to have different powers?


It's true that $(n) (n + 1) (2n + 1)$ is a multiple of 6?

Show that for all n ∈ N, it is true that $(n) (n + 1) (2n + 1)$ is a multiple of 6, that is: $$\exists m\in \mathbb{N}: n (n + 1) ( 2n + 1) = 6m$$ I think I can prove it by induction, but I don't know how proceed.


I want to install npm. I've updated everything but I can't fix the problem.   The message I get is:  Reading package lists... Done Building dependency tree        Reading state information... Done Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation:  The following packages have unmet dependencies:  npm : Depends: node-gyp (>= 0.10.9) but it is not going to be installed E: Unable to correct problems, you have held broken packages.   Could you help me?


Evolution of the Redundancy of the Genetic Code

In short  Looking at the genetic code, it appears that most redundancy is on the third letter rather than on the first or the second letter of the codon. Why has it evolved this way?    Longer version  In order to compare the relative redundancy accounted by each letter of the codon, let's assume that that every codon occurs at equal frequency. It is probably wrong but useful for the sake of the calculations. Using observed frequencies of codon usage in a given population would change the following probabilities but the question of why some positions in the codon has more redundancy than some others still hold.  A substitution of the first letter of the codon has a probability of $\frac{1}{2048}≈0.00005$ (Stop codon) to be synonymous. A substitution of the second letter of the codon has a probability $\frac{3}{256}≈0.012$ (nucleobases U and G) to be synonymous. A substitution of the third letter has a probability of exactly $\frac{2}{3}$ to be synonymous.  Probability of a substitution to be synonymous given that it occurred on the...   First letter: $\frac{1}{2048}≈0.00005$ Second letter: $\frac{3}{256}≈0.012$ Third letter: $\frac{2}{3}$   Why are there more redundancy on the third position than on the second (which has more redundancy than the first position) in the codon?


how to shutdown my ubuntu-server 16.04.2

When I use sudo init 0 to shutdown the system ,it always staying at      [ok] Stopped LVM2 metadata daemon     What can I do？


I got some new hard discs and would like to set my PC up in the following way:   Ubuntu is currently installed on one drive I want to put Windows on a second drive I would like a third drive for shared content (music and stuff) that both OSes can access     What I need to know is what format should the content drive be?  How should I configure the drive order in my bios for GRUB to be boot manager and how to configure GRUB for multi-HDD booting?


What is the maximum length of serial cable I can use, to connection work properly? Is length of serial cable in connection with baud rate? I am using about 5 meter cable at speed 38400 bauds and RS232 communication, is it too long?


Is there a way to get the c++ code after substitute all the head files and macros?

I want to search the way a c++ library works, so I want to know the code after the maro and head files are substituted.


Proof that a continuous function maps connected sets into connected sets

I'm trying to prove that, if f is a function from C to C, and its domain, D, is connected, then f(D) is also connected. How would I go about doing this?  The definition of conectedness at play is "S is disconnected iff there exist open disjoint sets A and B such that none contains S, but their union does", and that of continuity is "f is continuous iff, if a sequence of members of the domain tends to z, then the image of the sequence tends to f(z)".


Is there a way to change the extension of a WCF Service. I have developed a service with the name customservice.svc. I want to change the extension to customerservice.wso. But the same WCF service have to be invoked. How can you do this.


Generally: why use click-handlers instead of subclassing?

My question is purely general. Why does Java force you to write complicated handlers that need to be attached to objects for a simple thing like a click?   So, why do I need to write:  public class ClickMe implements OnClickListener {      void someMethod() {         Button button = (Button) findViewById(R.id.button1);         button.setOnClickListener(this);     }      @Override     public void onClick(View v) {         ....     } }   instead of something like  class myButton extends Button { @override void onClick() { // do something special }   and then use that button on my layout?   I'm sure there are good reasons for this design, I just can't think of them!


What are the differences between Holmes, Moldvay, and Mentzer D&D?  Also, which one came first?


Proof that it exists at least one graph G planar, bipartite and with $\delta$(G) $\ge$ 4

I know this is possible, but how can I rationally get to an answer rather than just trying to draw several graphs until I find one?


In △ABC, BD : DC = CE : EA = AF : FB = 1:4. Let K, L and M are points of intersection of AD, BE and CF, as shown on the picture...

In $\triangle ABC$, $BD:DC = CE : EA = AF : FB = 1:4$. Let $K$, $L$ and $M$ are points of intersection of $AD$, $BE$ and $CF$, as shown on the picture. Suppose the area of $\triangle ABC$ is 1, find the area of $\triangle KLM$.


Should I add a ; after putting a function into a variable? is this code right?  pj.RemoveProjectTask = function (e, scope) {     e.preventDefault();     scope.remove(); };  pj.ToggleProjectTask = function (e, scope) {     e.preventDefault();     scope.toggle(); };   or this code:  pj.RemoveProjectTask = function (e, scope) {     e.preventDefault();     scope.remove(); }  pj.ToggleProjectTask = function (e, scope) {     e.preventDefault();     scope.toggle(); }


How can I put my iMessage settings on my phone number instead of my apple ID?

I've just updated my iPhone 4s to ios 7.0.3 and I've set up a new apple ID but iMessage doesn't work on my phone even after I activated iMessage in settings.   It used to work with my phone number before but I cannot set it on my phone number anymore. I can just choose my Apple ID to send and receive iMessages.   When I try to send iMessages it doesn't work and nobody can send me iMessages.


Is there any way to attract or repel neutrons?

I know that neutrons are neutral and have no charge, but is there any other way to interact with them?


Regular Expression for alphanumeric and underscores

I would like to have a regular expression that checks if a string contains only upper and lowercase letters, numbers, and underscores.


Why is $\int 2 \cos x \sin x \neq \int \sin 2x$?

So I had this school assignment with this question: $\int (\cos x - \sin x)^2 \ dx$ And through computations I came up with this: $\int \cos x + \sin x \ dx - \int 2 \cos x \sin x$ And this is where I got stuck, that when I integrate $2 \cos x \sin x$ right away, I would actually get $x - \sin^2 x + C$, which is different if I applied the double angle trigonometric identities in $2 \cos x \sin x$ , rewrite it to $\sin 2x$ , and it will give me a different answer. $x + \cos(2x)/2 + C$ I went to Symbolab, a math solver app, and it really shows the difference, whether I integrate it right away or apply the trig identity first before integrating:   I tried to plot the points in Desmos, two answers seems close enough that it's just one constant away (particularly 0.5), but still mathematically not equal  So, does this mean that this trig identity changes the actual answer that I should avoid using it as much as possible. Or this is just an exception? Which one is right? Is it both of the two answers? I already passed my answer to the teacher, but what I actually did before passing it is integrating right away. But this problem haunts me in sleep that I actually opened my pc to ask this question here. Still learning integration techniques that I got introduced to this kind of problem, that overall it's pretty fun and stressing.


How can I drop voltage from 20V to 12V at 3.5A?

Here's the problem: I carry around two devices, but at different power requirements - one at 20V/3.5A and the other at 12V/3.5A. I'd like to only carry around one power brick and just carry an adapter cord.  I've looked around everywhere for universal power supplies, but the only one I found that included both 12V and 20V was at 5A. I don't want to risk damaging my batttery at the higher amps.  So now I'm looking to an engineering solution. I have a basic understanding of electrical engineering, but I'm having a little trouble here figuring out what I'll need.  From my research, I believe I can use a 20V/3.5A power supply and a 12V step down voltage regulator. The problem is I can't find any voltage regulators at the correct amps - either too low at like 600 mA or way to high at 20A. Does anyone know where or how I can find the part I'll need?   I assume, using the pinout diagram, I can essentially just run the power from the 20V power supply thru the voltage regulator and come out with 12V. Am I missing anything?  And if anyone has a better solution, I'm all ears (or eyes).


I've deleted Google Play Store. How can I reinstall it?

I've been having an issue with my apps where an error "" keeps appearing. I read a tutorial somewhere which told me to "uninstall updates" for the Google Play Store application. I was told doing this would uninstall the application, and then the device would automatically reinstall Google Play Store.  I did this, restarted my phone, but the application never reappeared.  I think tried downloading an .apk file to install this manually, but on install the application wouldn't load.  Has anyone done this before? How can I reinstall this application? I believe I need it for all future downloads and updates to my applications.  For the record, my phone is not rooted.


External hard drive very slow to load after dropping it and can't be repaired with Disk Utility

Today as I was using my WD HDD, it fell off my corner. After I fixed the thing, I plugged it into the Mac and it loads the HDD but it's very very very very slow. It also does not work sometimes. The entire laptop just hangs  Tried running Disk Utility First Aid but it won't work.  It says some error and hangs  Can someone advise me on what I can do in this case?


How many 4-digit numbers ($0000-9999$; including $0000$ and $9999$) can be formed in which the sum of first two digits  is equal to the sum of last two digits?  Assumption : every number is valid even if it starts with a zero.  For ex: $1230, 0211, 4233$ and so on...


class object is not created in main class and giving NullPointerException error

I have three classes Product, Cart, Shop. Cart class inherits with Product class. Shop class has the main function and I am trying to create an object of Cart class. but it's not getting created. It's my homework assignment they mention that I have to use ArrayList in Cart class and create an object of Cart in Shop Class. if I inherit Cart class with Shop class public class Shop extends Cart{ ....  then I can use Cart class Methods but I can't submit it like this I have to create an object of Cart in Shop and have to use it Error: Exception in thread "main" java.lang.NullPointerException: Cannot invoke "Cart.a ddItem(Product)" because "this.myCart" is null         at BookShop.addItem(BookShop.java:109)         at BookShop.showGUI(BookShop.java:42)         at BookShop.main(BookShop.java:10)  here are the classes these are a piece of code, not the whole program. Product.java public class Product {     private String name;     private int quantity;      public Product(){         System.out.println("Object Created");         name = null;         quantity = 0;     }          public Product(String name,int quantity){         this.name = name;         this.quantity = quantity;     }     public Product(Product p){         this.name = p.name;         this.quantity = p.quantity;     }     public void setName(String Name){         this.name = Name;     }     public void setQuantity(int quantity){         this.quantity = quantity;     }     public String getName(){         return this.name;     }     public int getQuantity(){         return this.quantity;     } }  Cart.java import java.util.ArrayList;  public class Cart extends Product{     private ArrayList<Product> CartItems;      public Cart(){         super();         System.out.println("Object Created");         CartItems = new ArrayList<Product>();               }     public Cart(String name,int quantity){         super(name,quantity);     }     public Cart(Cart c){         this.CartItems = c.CartItems;     }     public void addItem(Product p){         this.CartItems.add(p);     }     public void setCart(ArrayList<Product> cart){         CartItems = cart;     }     public ArrayList<Product> getList(){         return this.CartItems;     } }  Shop.java import javax.swing.JOptionPane;  public class Shop{     public Cart myCart;     public static void main(String[] args) {         Shop myShop = new Shop();         myShop.showGUI();     }     public Shop(){              }     public Shop(Shop s){         this.myCart = s.myCart ;     }      public Shop(Cart c){         this.myCart.setCart(c.getList());     }      public void showGUI(){                  String input= JOptionPane.showInputDialog("Enter Quantity");         Integer qualtiy = Integer.parseInt(input);         Product p = new Product("Book", qualtiy);          this.myCart.addItem(p);         }       }


Recently, when I tried to encrypt a folder in my external HDD, I was presented with a dialogue box as given below:  What' the difference between Apply changes to this folder only and Apply changes to this folder, subfolders and files in encrypting a folder? If I select the first one, will the folder be accessible to others(and the files inside it)?  UPDATE: answers my question partially, but not the second part about the accessibility of the files inside that folder.


Book where human thoughts are affecting the universe

Basically our thoughts are ruining everything. Like when humans are taught stars are giant balls of gas. To the rest of the universe they aren't but humans think it and destroy alien planets. I think they come to seal us off from the rest of the universe.


Extended titles for subsections gets my TOC all pilled-up

Some of the sections and subsections of my work has extended titles, i.e.: \section{bla bla bla ....... bla}, so when pdflatex creates my .pdf, the toc gets all pilled-up, as show in picture.    How can I prevent this?


Handling a Unicode String in Delphi Versions <= 2007

Background: This question relates to versions of Delphi below 2009 (ie without Unicode support built in). I have a specification that requires me to transmit a Unicode encoded string over a TCP connection but I do not have Delphi 2009.   Question Is there a single function or very small library (I don't need too much bulk) that I can use to encode a single string into UTF-8 immediately prior sending over the wire? As a second part of my question: if there are UTF-8 encoded strings being sent back as a response, I guess I would then need another function to get it back into a Delphi string format. I understand the limitations of such Unicode support in this way.


What happens when I click "Send" after Ubuntu experienced an internal error?

I am using Ubuntu 18.10. Sometimes, when some program has just crashed, a window pops up saying the following: "Sorry, Ubuntu 18.10 has experienced an internal error. Send problem report to the developers?" Then there are three buttons: "Show details", "Don't send" and "Send".  If I click "Show details" then it does show details nicely, for example that "gjs-console crashed with SIGABRT" and lots of other info. It seems like a good idea to send this to the developers, so I click "Send". Then the window is closed. I do not get any confirmation that anything was actually sent. I would have liked to get some confirmation like "OK, problem report sent successfully" or something but there is no such confirmation so I am a little worried that something went wrong when I clicked the "Send" button.  My questions:   Is anything actually sent to the developers? Is there any way for me to verify that something was actually sent? Can I even see the details of the resulting automatically generated problem report in a public bug tracking system somewhere?   EDIT: according to an answer here:  it should be possible to see the resulting bug report by going to  but that does not work for me -- that page just says "There are currently no open bugs." So I am still not sure if any problem report was really sent and if so, where did it end up.  EDIT 2: this seems related also:  but after reading that I still don't know how to verify if a problem report was really sent.  EDIT 3: in /var/log/syslog there are a few lines mentioning "whoopsie" saying for example "Uploading /var/crash/_usr_bin_gjs-console.1000.crash." and "Sent; server replied with: No error" which sounds good. Also, the file /var/crash/_usr_bin_gjs-console.1000.crash does seem to contain all the collected error report info.


Showing that $e^z=z$ has infinitely many solutions

One of our review problems for my complex analysis final is the following:     Show that $e^z=z$ has infinitely many solutions in $\mathbb{C}$.   I've seen a few solutions online, but none of them have used material that was covered in our introductory complex analysis course. Would anyone be able to provide a simple solution?  I'm trying to think of ways to invoke bounding in some way but I can't seem to come up with anything.


Is there any formula for strong and weak nuclear force?

As we know, there is an equation for gravitational force $$F = \frac{Gm_1m_2}{R^2}$$ While for electromagnetism, it is $$F = q(E + v × B)$$ So is there any true formula to find the weak and strong force?


Just... take a look at this, please:        , see sidebar. (It's much worse there, my screen recording frame rate isn't great.)  I think it's needless to say... but: it's irritating, and I don't want to see animations there.


Problems with conditional statements in Java

An extremely simple login system was one of the better ways I could think of to practice with Java conditionals. All I'm trying to do is compare two string variables, and it appears there's something wrong within that process. It always just goes to the final "else" statement, and I've done a lot of troubleshooting which has shown that the username and password are in fact the same by the time the conditionals come around. Here's the code: import java.util.Scanner;  public class HelloWorld {      // Pre-defined username and password requirements     String RequiredUsername = "test";     String RequiredPassword = "test";      // Initializes the textinput     Scanner input = new Scanner(System.in);      public static void main(String[] args) {          // Creates a new "object" of the main program called loginpage          HelloWorld logingpage = new HelloWorld();          // Starts the "start" method         logingpage.start();      }      public void start() {          // // Main Screen in console         // System.out.println("+-----------------------------------------------+"         //                + "|                                               |"         //                + "|          Welcome to the Login Screen          |"         //                + "|                                               |"         //                + "+-----------------------------------------------+");          // Prompts the user for a username and gathers it         System.out.print("[*] Please enter Username\n>>> ");         String username = input.nextLine();         System.out.println("");          // Prompts the user for a password and gathers it         System.out.print("[*] Please enter Password\n>>> ");         String password = input.next();         System.out.println("");          // Conditionals to check username and password         if (username == RequiredUsername && password == RequiredPassword) {             System.out.println("[*] The secret message is: The eagle has landed!");         } else if (username == RequiredUsername && password != RequiredPassword) {             System.out.println("[*] ERROR, Password Not Valid");         } else if (username != RequiredUsername && password == RequiredPassword) {             System.out.println("[*] ERROR, Username Not Valid");         } else {             System.out.println("[*] ERROR, All Credentials Invalid");         }          // input.close();          } }


About 5 years ago, I managed to convert a pointer to a int, store it temporarily and then take that int and convert it back to a pointer (Objective-C). But I can't for my life remember how I did it.  Can anyone help me out?


How is decreasing hotness score of successive questions from same site by 2% supposed to work?

Per my reading of  hotness score of successive questions from same site is penalised by 2%. Taking into account that there could be no more than 5 questions from the same site this means that maximum possible penalty is 8%. I am looking for an explanation of how this is supposed to make a meaningful impact, because at the first glance, it looks too small for that. To have a better idea of what possible impact it could have I sampled score of several questions in some snapshot of hot list. Hotness score values I observed were 46.422, 17.269, 10.194, 7.485, 5.825, 4.658, 3.891 for questions ##1, 16, 31, 46, 61, 76, 91 respectively (for that sample I simply picked top question from each page of the hot list configured with ). Distribution of the scores in above sample suggests that even maximum of 8% would "push" the penalised questions less than 10-15 places down in the list, how is this supposed to make a difference (particularly since questions from the list are anyway randomly shuffled before getting displayed in the sidebar)?  Alright, that limit of 5 is relatively recent thing - but closer look at sample distribution of scores suggests that even without it, even if system allowed 10-20 questions from same site like it did before, the effect of penalty would be negligible. Max penalty in this case would be 20-40% - meaning that question would still have solid chance to stay in the list and get shuffled to sidebar - and this is the most penalised case, for other questions from same site the difference would be even less than that. I really don't understand how this parameter is intended to work.


I cannot figure out why the bullet points are not showing up.   \documentclass{beamer} % % Choose how your presentation looks. % % For more themes, color themes and font themes, see: % http://deic.uab.es/~iblanes/beamer_gallery/index_by_theme.html % \usepackage{fourier}  \usepackage{array} \usepackage{makecell} \usepackage{longtable} \usepackage{enumitem} \usepackage{comment}  \mode<presentation> {   \usetheme{CambridgeUS}      % or try Darmstadt, Madrid, Warsaw, ...   \usecolortheme{beaver} % or try albatross, beaver, crane, ...   \usefonttheme{structuresmallcapsserif}  % or try serif, structurebold, ...   \setbeamertemplate{navigation symbols}{}   \setbeamertemplate{footline}[frame number]   \setbeamercovered{transparent} }   \usepackage[english]{babel} \usepackage[utf8x]{inputenc}   \title[Your Short Title]{Post-Circumcision Risk Compensation: A Systematic Review} \author{Dana Ivanova, Njeri Kamau} \institute{Topics in Epidemiology} \date{15 January 2019}  \begin{document}  \begin{frame}   \titlepage \end{frame}  % Uncomment these lines for an automatically generated outline. %\begin{frame}{Outline} %  \tableofcontents %\end{frame}   \section{Background}   \begin{frame}{sub-Saharan Africa}     \begin{itemize}      \item globally 35 million people are  HIV positive      \item role of sub-Saharan Africa     \end{itemize}


Postfix relay smtp to 2 relayhosts for same domain

have a setup in which Postfix relays mail for a specific domain to another mail server (Exchange) via the usual transport file:  # /etc/postfix/main.cf  transport_maps = hash:/etc/postfix/transport  # /etc/postfix/transport  blah.local  smtp:[192.168.2.11]  So email for anything@blah.local coming into Postfix will be relayed to the Exchange Server at 192.168.2.11.  The Exchange will be replaced soon with something else though, hence I want to test another server in addition to the Exchange, i.e. I want to relay all mails to blah.local to TWO servers at the same time. No failover or load balance, but mail to blah.local relayed to 2 relayhosts at the same time. have been researching this but don't think this is possible with Postfix alone. Ideas anyone?  Any help on this would be greatly appreciated!


Instead of read a dictionary by keys, read by values (mydict[key] = value >>> mydict[value] = key)

This question could sound something stange, but normally you can get values by the key, e.g:  >>> mydict = {'a':1,'b':2,'c':3} >>> mydict['a'] 1 >>> mydict['b'] 2 >>> mydict['c'] 3   But I need to do:  >>> mydict[1] 'a' >>> mydict[2] 'b' >>> mydict[3] 'c' # In this case, my dictionary have to work like >>> mydict = {1:'a',2:'b',3:'c'}   In my program my dictionary could be open by the two ways, I mean:  >>> mydict = {'a':1,'b':2,'c':3} # Sometimes I need the value of a letter: >>> mydict['a'] 1 # And somethimes, I need the letter of a value. >>> mydict.REVERSAL[1] a   I can do something like: (I don't know if this work, I don't test it)  >>> mydict = {'a':1,'b':2,'c':3} >>> mydict['a'] 1 # etc... >>> def reversal(z): ...     tmp = {} ...     for x,y in z.items(): ...         tmp[y] = x ...     return tmp >>> mydict = reversal(mydict) >>> mydict[1] a # etc >>> mydict = reversal(mydict) >>> mydict['c'] 3 # etc, etc, etc...   Is there an easy way to do that?  FIRST: I know about chr() and ord(), my code isn't about letters... this is only and example.  SECOND: In my dictionary there won't be two same values, so there won't be any problems with duplicate keys...


Why is $a^{-1} \cdot a \equiv 1 \text{ mod } m$ a lemma in universal hashing?

I have been given the following lemma in a online lecture on universal hashing: Lemma: Let m be a prime. For any $a \in \{ 1, \dots, m-1 \} $ there exists a unique inverse $a^{-1}$ such that $a^{-1} \cdot a \equiv 1 \text{ mod } m$ ($\mathbb{Z}_{m}$ is a field) Example. m = 7                a 1 2 3 4 5 6   $a^{-1}$ 1 4 5 2 3 6     So to understand this question, I have found out that the $a^{-1}$ is actually what we call the Modular Multiplicative Inverse. So i went to some online calculator of that and inserted for example 2 and 7 as modulu. But what i don't understand is, if we replace the modular muliplicative inverse in this equation we get for example: $$ 4 * 2 \equiv 1 \text{ mod } 7$$ $$ 5 * 3 \equiv 1 \text{ mod } 7$$ $$ 6 * 6 \equiv 1 \text{ mod } 7$$ Which is not true. The only way this is true is that $$ (4 * 2) \text{ mod } 7 \equiv 1 \text{ mod } 7 $$ But I am not sure if that's what they mean and why they wouldn't write that out?


Which John Sheppard was Rodney referring to in S5E19?

In Stargate Atlantis, Season 5, Episode 19 - Vegas, we are presented an alternate reality of the universe. At one point, we find out that:  McKay tells Sheppard that a little while ago, he and his team accidentally opened a rift in space/time and visited another reality, in which that Sheppard is somewhat of a hero having saved the world several times over   Is Rodney referring to the reality we are familiar with in the show, or do we simply not know? Also could It possibly have something to do with episode 5, "Daedalus variations"?


Side scroller terrain generating and scrolling

I am creating a side scroller game for android devices but I encountered a problem. The game looks like this:    The black dot is a player. Player's x doesn't change, only the y does. When the player collides with the green terrain the game is over.   I have a problem with how should I handle a map storing and drawing. What I did is store the level file in a large png file (like 1k px height and 20k px width), same with the collision mask (basically the same file but with black colored collision terrain). I guess this approach isn't to good beacuse I was getting the out of memory exceptions due to large bitmap on some devices. I've learned that some people use tile based maps but with this sinusoidal map it could be to hard for me to do small tiles and collsion masks for them. I want the map to be as long as possible and if it's possible random-generated but I don't know what's the best approach to do this with this kind of terrain and how to handle pixel perfect collisions when doing so.


Find subgroup of $S_5$ isomorphic to the quaternion $Q$

I'm trying to solve this problem from my abstract algebra course:  Find a subgroup of $S_5$ (Symmetric group of order 5) isomorphic to the quaternion group $Q$.  I started writting down the elements of $Q$ to start trying some examples and see if the quaternion properties where verified: $$Q=\{\pm 1,\pm i,\pm j,\pm j\}.$$ Obviously the element $1$ is $(1)(2)(3)(4)(5)$ in $S_5$. Then I tried with: $$i=(1234)(5)\ \ , \ \ -i=(1432)(5).$$ Both verify they have order $5$, and from them I get $-1=(13)(24)(5)$. Now, I'm stuck, since I think I pick wrong elements because I can't find good elements for $\pm j$ and $\pm k$. What is the easiest way to do this kind of problem where you're asked to find a subgroup isomorphic to a certain group? Any help will be appreciated.


Do local flows of left-invariant vector fields satisfy $\Phi_X^t\circ L_x=L_x\circ \Phi_X^t$?

Given $G$ a lie group and $X$ a left-invariant vector field. Let $\Phi_X^t$ be the local flow of $X$. Why can we conclude that $\Phi_X^t \circ L_x=L_x \circ \Phi_X^t$? Thanks!


I'm working with the XmlTextReader and use a switch to determine which operations I want to do depening on the XmlNodeType.  switch(xmlTextReader.NodeType) {     case XmlNodeType.Element     {         ...         break;     }     ... }   and so on...  Now I have a small problem. As far as I know,   XmlNodeType.Element    matches any node with the following syntax   <xxx>    and   XmlNodeType.EndElement    matches   </xxx>    But what XmlNodeType matches   <xxx/>   ?


Is there anything in the physics that enforces the wave function to be $C^2$? Are weak solutions to the Schroedinger equation physical? I am reading the beginning chapters of Griffiths and he doesn't mention anything.


I have servers running VMWare. The server is a Intel Xeon with 96 Gio of RAM. We need to increase the RAM on the server (assume with the same memory model). Somebody told me adding more memory to a computer can slow it because there's more address space to look after.  I'm pretty sure it's bullshit and I can't find any paper that confirm that adding memory can slow down a computer. Instead, I have only documentation that confirm that it can speed it because it can have a bigger swap.  So my question is : Can adding RAM to a server can make it slower? If so, is it perceptible? Do you have any documentation on the subject?


Prettiest way to typeset "C++" (cplusplus)?

Writing "C++" in plain text results in an ugly setting, as the '+' signs are too big and too spaced:    I've seen around the web several marcos for typesetting the "C++" symbol, ranging from mild kerning to shrinking, raising and lowering the '+' signs.  What is your version of a \cpp{} macro?


"This date and time is" vs. "this date and time are"

The following sentence appears in a letter I am editing:     If this date and time are not convenient please contact me at ...   Structurally, this seems okay, but it feels very awkward. Shouldn't it read:     If this date and time is not convenient please contact me at ...


Can I leave the UK with a non-UK passport

I am a UK citizen and I also have a Canadian passport. I am in the process of applying for a work visa in the US with my UK passport. I have an upcoming trip in Europe (I am currently in the UK). My question is: Will I be able to leave the UK with my Canadian passport (as I didn't enter the UK with my Canadian passport)? I'm slightly concerned there might not be time between getting back my passport from the US Embassy and my travel.  Thank you.


Struct and object oriented in JavaScript

I come from C, C++, Java background. I want to create a struct/ class with some attributes and methods like:  MyClass{     string text;     array characters;     printText(){         print text;     }     printLen(){        print characters.length();     } }   So next time I can create an object like above by just calling its constructor. How do I implement this in JavaScript? I am new to the programming principles followed in javascript, I want to create a custom data type here for reusability.


Show that $\bf (a^\top Q b)^2 \le a^\top Q a \ b^\top Q b$!

where $Q \in \mathbb{R}^{n\times n}$ is a positive definite matrix and $a, b \in \mathbb{R}^n$. The actual problem is, that $\bf ||x||_Q = \sqrt{x^\top Qx}$ should be a norm, but this is as far as I've gotten trying to show that $\bf||a+b||_Q \le ||a||_Q + ||b||_Q$.


According to the story line in the new Justice league movie, why wasn't  included in the character list?   As per wiki, the original creation of the Justice League comprised of 7 founding members. How come they chose not to include Hal Jordan?     It's pretty understandable that they chose not to show J’onn J’onzz, a.k.a , as most people who has no knowledge about DC or the JL wouldn't know who the strange, green martian is. Also for the fact that he wasn't a part of the original 7, but was the first inductee into the established JL. But as for Hal Jordan, we already saw a movie (although, an awful one) about the Green Lantern.  Is there any reason that you know of, why the will-powered powerhouse was excluded from the movie?


EDIT:  question's top answer talks about different compilation and production environments. The second answer is about fixing it in Eclipse. I am running this code in IntelliJ and I don't have different environments for compilation and production. I am just hitting the Run button in IntelliJ. Also the question is nowhere a duplicate of what is asked there.  I am trying to build a simple Spring program. This is the folder structure:  . ├── firstSpringProject.iml ├── pom.xml ├── src │   └── main │       ├── java │       │   └── com │       │       └── webograffiti │       │           ├── MainClass.java │       │           └── Student.java │       └── resources │           └── applicationContext.xml   Here is the code written in these files:  Student.java  package com.webograffiti;  public class Student {      private String name;      public String getName() {         return name;     }      public void setName(String name) {         this.name = name;     }      public void displayInfo(){         System.out.println("Hello "+name);     } }   MainClass.java  package com.webograffiti;  import org.springframework.context.ApplicationContext; import org.springframework.context.support.ClassPathXmlApplicationContext;  public class MainClass {     public static void main(String [] args){         ApplicationContext context = new ClassPathXmlApplicationContext("applicationContext.xml");         Student obj = (Student) context.getBean("student");         obj.displayInfo();     } }   applicationContext.xml  <?xml version = "1.0" encoding = "UTF-8"?>      <beans xmlns = "http://www.springframework.org/schema/beans"        xmlns:xsi = "http://www.w3.org/2001/XMLSchema-instance"        xsi:schemaLocation = "http://www.springframework.org/schema/beans         http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">      <bean id = "student" class = "com.webograffiti.Student">         <property name = "name" value = "Piyush"/>     </bean>  </beans>   I am trying to run MainClass.main(). But getting this exception:  Exception in thread "main" java.lang.NoSuchMethodError: org.springframework.beans.support.ResourceEditorRegistrar.<init>(Lorg/springframework/core/io/ResourceLoader;)V     at org.springframework.context.support.AbstractApplicationContext.prepareBeanFactory(AbstractApplicationContext.java:446)     at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:355)     at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)     at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:83)     at com.webograffiti.MainClass.main(MainClass.java:8)   I have all the dependencies needed to run this code, viz. spring-core, spring-beans, spring-osgi-core. This could be a classpath error but I am not able to figure out a solution.


Find the determinant of a Vandermonde-like matrix

I reduced a certain determinant to the following which has the form: \begin{vmatrix} 1&1&\cdots & 1 \\ -a_1&a_2&\cdots &a_n\\ -a_1^{2}&a_2^{2}&\cdots&a_n^{2}\\ \vdots&\vdots&\ddots& \vdots\\ -a_1^{n-1}&a_2^{n-1}&\cdots&a_n^{n-1}\\ \end{vmatrix}  To clarify a bit, it is exactly the Vandermonde determinant except the first column is negative, while the $(1,1)$-entry is still $1$.   I think the key is to apply Vandermonde determinant yet I can't proceed. There may be a quick answer to this, however. Any hints?


I have these three lines:    export bunion_uds_file="$bunion_socks/$(uuidgen).sock";   "$cmd" "$@" | bunion   rm -f "$bunion_uds_file"   I need to make sure the last line always executes..I could do this:    export bunion_uds_file="$bunion_socks/$(uuidgen).sock";   (     set +e     "$cmd" "$@" | bunion     rm -f "$bunion_uds_file"   )   or maybe like this:    export bunion_uds_file="$bunion_socks/$(uuidgen).sock";   "$cmd" "$@" | bunion && rm -f "$bunion_uds_file" || rm -f "$bunion_uds_file"   I assume creating the subshell and using set +e is slightly less performant etc.


My dad has forgotten his Password. He knows his username. We have tried every thing  and he needs that account.   Is there anything he/we can do to reset/retrieve the password?  We have read way to do the Recovery but don't quite understand them.


Using dd to clone a disk while mounted - risks?

I want to clone a hard disk using dd. Because I want to keep a process on the machine alive continuously, I would like to do this while the filesystem is still mounted. I understand this is not the "ideal" way to do this, but it also seems from Googling that it is possible.  The clone is being used as a backup; in the event of a hard disk failure I would like to have an image to dd back onto a new hard disk. The OS that is running lives on the disk I want to clone.  The process I have running does do some disk I/O but not with the disk I wish to clone. As far as I know, only the OS/system processes would be reading or writing to the disk while I do this operation. What I want to know is if this light use is likely to ruin the whole cloned image? I imagine that there's a danger of getting a few files corrupted if they're being written as they are read by dd, but I have no idea how likely it is to ruin the backup. Can anyone share some insights?  Short of putting the it on a disk and trying to start it, is there any way I can verify the integrity of the image?  Thanks!


I have looked at several pages and still am not getting clear instructions on how to download and install a .deb file. Specifically I would like to download this one:   How can I do this?


I've read the other inset thread but it didn't help me. I'd like to inset the face proportionally, so without distortion. The result I'd like to have:


Will using a mailto link on your web site still get that address spammed in 2018?

It seems that having a clickable mailto link is a good UX, especially for mobile users. But from what I understand, mailto links open up an email to spam more easily due to spam bots. At least, that's what used to be said about them years ago (today is 2018).  The question is, are mailto links still as 'dangerous' as they once were? Is spam / bots something to worry about, or does the good UX of a clickable link outweigh the negative?  I tried to find the answer to this but can't seem to find much relevant info in 2018. A few sites like Hubspot talk about using mailto links still, so it seems that maybe mailto is back to being a good option.  What do you think?


Why is Matt Damon's name not mentioned in Thor Ragnarok credits?

In Thor: Ragnarok Matt Damon plays the role of Actor Loki, but in the cast list his name is not mentioned. The name of Luke Hemsworth who played Actor Thor and Sam Neill who played Actor Odin is mentioned.   link shows the scene where Matt Damon appeared in the movie dressed as Loki, and Luke Hemsworth is also present playing the role of Thor.  What is the reason for not mentioning Matt Damon's name?


In the movie version of Ender's Game, Col. Graff's computer shows a very short time until the end of Ender's training

In the movie version of Ender's Game, there is a scene where Col. Graff is in his office, and they show a big HUD with all sorts of data - including      28 days until the attack on the Formics   This implies a much more rapid and accelerated rate of training for Ender - it would appear that the amount of time between his arrival at Battle School and his "training" at Command School is much shorter than the 7 or so years which it is in the book. Is there a way to explain this in-universe? Why would they change this in the movie to such a radical extent? Could Ender have really be trained in this amount of time?


Why does "ls > foo" produce a file containing "foo"?

I removed all files in a directory and then ran ls > foo in that same directory.  Running cat foo reveals that the newly created file "foo" contains "foo". Why is the file "foo" not empty? When ls executes, there are no files in the directory yet, right?


Community♦ has gone crazy on Code Review meta

The  user on Code Review meta has had a strange behaviour recently:   First of all, it has 5 reputation instead of 1. Thirty minutes ago, it felt that it was a good idea to update 91 questions at once. Right now, the "active questions" page is totally meaningless since there are only old questions in a somewhat random order. It removed some inline tags in some answers (, "" -> "teaching") while it did not removed them in the questions.   Has it gone crazy?  EDIT:  Including screenshots:


What is an efficient way to remove loose vertices?

I have a mesh that has some vertices between edges that do not need to be there. How can I easily remove these vertices without selecting them manually? I tired using limited dissolve but that get rid of anything that coplanar not just the floating vertices.


measuring a distance on QGIS 2.2. in meters not degrees

Im using QGIS 2.2.0 and when I want to measure the distance on a map, the units are in degrees instead of meters. I have tried this :  Right click on layer -> "Save as..." -> CRS: Selected CRS (WGS84)  but nothing has happened.   Does anyone have any ideas?


Why python want me to use hashables as dict key?

Why python restrict us to use hashable as dict key? How this mechanism works?


I came across a different symbol for the letter 'S' on Wikipedia:      What is the symbol called, replacing the letter 'S' in "Paradise" and "Lost" (and lower down in many other words, like "Bishopsgate-street")?  Further, why does it only replace some 'S' symbols? It seems that when used for pluralization, the modern 'S' is used. Examples in the image above are "Books" and the first and final 'S' in "St. Dunstons", but not the 'S' in the middle of that word.  What are the rules for when to use one vs the other?  The symbol looks rather like a lowercase 'f'...


Is "Each person should do their own work" really not logical to say?

I am taking English Language Studies as my bachelor's. It happened when one of our subjects' professor, Advanced English Grammar professor, said that the sentence "each person should do their own work" is not logical to say because of "their"'s usage -- or it is grammatically wrong based on prescriptive grammar's view. I think I kind of get it, but I am not satisfied nor convinced with her explanation. Can someone justify why or why not it is not logical? Thank you!


Can a basement bathroom be vented through a stack servicing sinks on the floor above?

Can a basement bath (toilet, sink and shower) macerating pump system be workably (not codes) vented into a 3" PVC that vents out the roof if the 3" PVC vent pipe also has 2 vanity sinks on the floor above using the 3" PVC for both a drain and vent (the sinks have traps of course where no smell at the vanities from the pump will exist; and, the basement pump vent will be hooked into the 3" PVC from above it where no vanity drainage can drain into it); and, if done, what are the actual drawbacks? Is the only possible actual problem that the basement bath will not drain as well only when the vanities are being used?


In my current project, I'm using the boxed versions of certain operations. The amsmath package provides convenient \boxtimes and \boxplus operators for this, which are the same size as \square.  However, I haven't been able to find a box with a slash (i.e. set-minus symbol). Is there a straightforward way I could make one, e.g. by somehow removing one of the lines from \boxtimes, or overlaying \square with an equally-sized slash symbol? The straightforward \not\square looks rather dreadful: . \cancel\square looks somewhat better, but the line still extends beyond the edges of the square: .


Showing new questions that are tagged with one of my favorite tags

On the app, the only way you can filter by your favorite tags is by using the unanswered (my tags) filter. However, this brings up very old questions (dating from more than a year, which have less value because noone is actively waiting for an answer one year later). It would be better to see the latest questions, like what you can see on the site when selecting a tag.  Explanation  When I'm on the app, I usually want to do one of the following   Check my feed, to look at hot questions, responses, comments in answers I have posted Look for new questions I could answer   For the point 2., it's very important to me to be able to find questions I could possibly answer. These questions are the questions tagged with my favorites tag, and it seems natural to me that the newest question should appear first, as questions asked more than a week ago are not very likely to find an answer and the OP has probably no more interest in that question.


What should I do to understand why my computer freeze?

After updating to Ubuntu 15.04 I am experiencing several freezes of my laptop: suddenly everything stops, the screen freezes and the last sound emitted keep playing forever. I am then forced to manually reboot the machine.  I really would like to avoid going with trial-and-error and understand what's really going on. I saw other questions about freezing, but the best answer I could find was "reboot". Which I am already doing regularly. I am more interested in understand where the problem is (it may even be a hardware problem).  Where could I start to investigate? Which logs should I look at? Is there anything I need to do to ensure that those logs stay there after the reboot?  Many thanks for all the advices!  Michele  Edit #1 - Video card info  As suggested in the comments, here is my Video Card info.  > lspci -k | egrep 'VGA|3D' -A2 02:00.0 VGA compatible controller: NVIDIA Corporation G98M [GeForce 9200M GS] (rev ff) 03:00.0 VGA compatible controller: NVIDIA Corporation C79 [GeForce 9400M G] (rev b1)     Subsystem: Dell Device 0271     Kernel driver in use: nvidia   Now: Is there any log file where I can look if it's the Video Card which freezes? (Given that I could somehow get back to a console with the Magic SysRq key)


Materials have no color when put in unity

So I am just adding a sphere that has just 1 material to unity and when I add it to the asset folder there's no material, When I extract material its just a blank material. I have tried EVERYTHING what am I doing wrong? (using blender 2.8)


Trying to install Rainlendar-lite on Ubuntu 18.04

I'm trying to install rainlendar-lite on ubuntu 18.04.1 and keep getting  Download is performed unsandboxed as root as file '/home/jim/Downloads/rainlendar2-lite_2.14.2.b157-1_amd64.deb' couldn't be accessed by user '_apt'. - pkgAcquire::Run (13: Permission denied)  jim@jim-Z1-7623:~/Downloads$ sudo apt-get install ./rainlendar2-lite_2.14.2.b157-1_amd64.deb [sudo] password for jim:  Reading package lists... Done Building dependency tree        Reading state information... Done Note, selecting 'rainlendar2-lite' instead of './rainlendar2-lite_2.14.2.b157-1_amd64.deb' The following NEW packages will be installed:   rainlendar2-lite 0 upgraded, 1 newly installed, 0 to remove and 7 not upgraded. Need to get 0 B/17.9 MB of archives. After this operation, 20.5 MB of additional disk space will be used. Get:1 /home/jim/Downloads/rainlendar2-lite_2.14.2.b157-1_amd64.deb rainlendar2-lite amd64 2.14.2.b157-1 [17.9 MB] Selecting previously unselected package rainlendar2-lite. (Reading database ... 180109 files and directories currently installed.) Preparing to unpack .../rainlendar2-lite_2.14.2.b157-1_amd64.deb ... Unpacking rainlendar2-lite (2.14.2.b157-1) ... Processing triggers for mime-support (3.60ubuntu1) ... Processing triggers for desktop-file-utils (0.23-1ubuntu3.18.04.1) ... Setting up rainlendar2-lite (2.14.2.b157-1) ... Processing triggers for gnome-menus (3.13.3-11ubuntu1.1) ... N: Download is performed unsandboxed as root as file '/home/jim/Downloads/rainlendar2-lite_2.14.2.b157-1_amd64.deb' couldn't be accessed by user '_apt'. - pkgAcquire::Run (13: Permission denied)   EDIT: Thanks everyone. I've given up on installing rainlendar 2.14, and gone back to rainlendar 2.13, which works fine. In checking on the rainlendar forum, some people are having the same issues I'm having, but not everyone (a really bizarre problem that only affects some users???). So for now, my issue is solved, but not the install problem with rainlendar 2.14. Thanks again.


Completely remove everything of Microsoft Office to reinstall it from crash

I want to have complete Microsoft Office suite be removed as nothing related to Office exists on my computer.  I tried to uninstall from Control Panel but it seems the underground data still remained somewhere after I reinstall the software. E.g. the previous Office license, my Outlook mail box.  Currently I have Office 2013 and Visio 2010 on my machine.  How can I completely remove Office?


I have to calculate amount of light from IR emmiter. The only equipement, that I can use is Sekonic Light Meter like this one:   The problem is that i need to have the light level in lux or lm, and the metter gives me the values in EV. Could anybody tell me how could I recalculate those results: 11,6EV 11,4EV 11,1EV 10,4EV 9,3EV


Prove $\liminf a_n + \liminf b_n\le \liminf (a_n +b_n) $

$a_n$ and $b_n$ are two bounden sequences  Prove  $$\liminf(a_n) + \liminf(b_n)\le \liminf(a_n +b_n)$$  Should I use  $$\inf(a+b) = \inf(a) + \inf(b)$$ and i could not come up with how to proceed from this. Or should i use a different approach?


want to check answer given in my book is correct or not

The problem is to find coefficient of $x^n$ using binomial theorem for rational index in the expansion of $$\frac{1}{1-x+x^2-x^3}.$$  In my book the answer is given as $$\frac14+\frac{n+1}{2}+\frac{(-1)^n}{4}.$$ I think the answer in book is wrong.  I will be grateful if anyone check and tell this answer is correct or not with explanation. thanks


Proving that if $A$ is an $n\times n$ orthogonal matrix, then $\det(A) = \pm1$

I have a question on my assignment asking me to prove that if $A$ is an $n\times n$ orthogonal matrix, then $\det(A) = \pm1$. What I did so far is:  We know that $A\cdot A^t = I$ (since it is orthogonal), and that would mean that if $A$ is a matrix with elements $a,b,c,d$ then :  \begin{cases}a^2 + b^2 = 1\\ ac + bd = 0\\ c^2 + d^2 = 1\end{cases}  which implies that \begin{align}\det(A)&= ad - bc\\ &= -\frac{bd^2}{c} - cb\\ &= -\frac{bd^2}{c} - \frac{c^2b}{c}\\ &= -\frac{bd^2 + bc^2}{c}\\ &= -\frac{b(d^2 + c^2)}{c}\\ &= -\frac{b(1)}{c}\\ &= -b/c\end{align}  I might be doing something wrong here, could someone please help me out understand this?


How to bring up a precise Emoji in the iOS QuickType menu

In iOS 10, the QuickType menu is a lifesaver whenever the user needs to type a long word and doesn't feel like typing it (and it's also fun to make up ).  It also randomly suggests Emojis. But finding what to type to make the intended Emoji appear can be quite discouraging. For example if I want to type the "" 😈 there doesn't seem to be a way to QuickType it without having to go in the Emoji Keyboard. See examples below showing attempts at entering "Demon", "Evil" and "Devil":        My questions:   Can all the Emojis be called through QuickType without having to go into the Emoji Keyboard?  How do I know how what to type to call the right ones?


Ubuntu not booting on HP pavilion 17 177-sb with uefi BIOS

I bought my new laptop yesterday it's a HP pavilion 17 177-sb i believe and it has a UEFI BIOS so I usually install ubuntu the day I buy laptops and I did that this time too. I can only boot and shutdown the OS a few times before it crashes at the gnome logo saying it stopped all the services and then the screen goes black and the windows 8 HP logo appears and it just boots Win8 perfectly fine but ubuntu won't boot I currently have Secure boot turned on(doesn't really matter because it doesn't get fixed when I turn it of) and legacy support disabled! Only a reinstall helps and it just keeps screwing it up  if someone can help me with this I would appreciate it!  thanks,  noahvt


How to obtain the distance traversed by a free falling body equation?

I know that the distance that a free falling body has traverse through time is given by $d=0.5*g*t^2$. I would like to know how to get to this equation to study a bit more how it was obtained. I have been searching around with any luck. Could anybody give any tip?


I previously used to create image files using dd, set up a filesystem on them using mkfsand mount them to access them as mounted partitions. Later on, I have seen on the internet that many examples use losetup beforehand to make a loop device entry under /dev, and then mount it. I could not tell why one would practically need an image file to behave as a loop device and have its own /dev entry while the same behaviour can be obtained without all the hassle.   Summary: In a real-life scenario, why do we need a /dev/loopXentry to be present at all, when we can just mount the fs image without it? What's the use of a loop device?


Subdivision surface modifier distorts shape

My model looks how I want it to as it is, but when I use subdivision surface seemingly random chunks get added or taken away. How can I prevent this?


Solution for recurrence $T(n+1) = T(n) + \lfloor \sqrt{n+1}\rfloor $

ould someone please give me an idea as to how the solve the following.   $$T(1) = 1$$ $$T(n+1) = T(n) + \lfloor\sqrt{n+1}\rfloor$$  I converted the recurrence to $T(n) = T(n-1) + \lfloor\sqrt{n}\rfloor$ and then tried to solve it using the method taught in the "" at MIT and got the solution as $T(n) = n^\left(3/2\right) + 1$.  But the page I found this problem in asks for $T(n^2)$ and gives the answer as $\frac n6\left(4n^2 - 3n + 5\right)$, which I'm not able to derive.  Can someone please help me solve this recurrence?  Thanks


Resting time after specific operation is done

I have two sets which returns a specific value. I would like to carry out an operation on set apple. if length of this this set is greater than 0, i woulf like to calculate the elapsed time. If the time passed more than 10 sec, i would like to reset time to zero. Any suggestion to deal this?  apple = set([1,5,9,13]) orange = set([2,4,6,8,10])  def fruit(apple,orange):      if len(apple)>0:         time_now = time.time()     if time_now >10:         apple.clear()         time_now == 0 return apple, orange


I can get goosebumps at will, regardless of the environment. Its mostly visible on my arms, and I can feel it on my head. It requires some level of concentration to achieve this.  My questions are : what biological mechanisms are involved in doing this ? Is it common ? Is it useful ?


use authoryearstyle in biblatex with year label letter for same first author

I use \usepackage[backend=biber, style=authoryear-comp, maxcitenames=2]{biblatex} for my bibliography, which works perfectly fine. However, when an author appears multiple times biblatex also shows the name of the second author before printing the year. This even happens in cases of different year entries. How is it possible to suppress the printing of the second author and to label the citation with the year 2015a, 2015b instead?  Here is my bibfile:   @article{first,   title={Paper 1},   author={Ambigous, Alan and John Doe and others},    year={2015}, }  @article{second,   title={Paper 2},   author={Ambigous, Alan and Richard Roe and others},    year={2015}, }  @article{third,   title={Paper 3},   author={Miles, Juliane and Paul Waterman and others},    year={2000}, }  @article{fourth,   title={Paper 4},   author={Miles, Juliane and John Smith and others},    year={1999}, }


I keep dying when I'm mining Obsidian on Minecraft. Why?

When I'm mining Obsidian I keep either missing the broken block and watching it burn up in the lava, or dying when I try to catch the broken block. Why? I keep falling in lava below – is that the problem? I'm new to Minecraft.


Find $x$ in the following equation: $$3^x+x^3=17$$


The purpose is to help the addicted user stick to a decision to concentrate on a different, short-term real-life problems s/he urgently has to deal with.  I've seen this feature on some high-activity community forums. "Ban myself" button should offer several pre-defined periods for banning: starting with a few days, and up to 2 weeks (or maybe even a month, but that seems too much).  Optionally, this button should ban the requesting user on all profile-linked SO sister sites.  Clearly, there should be no way out of self-ban period.     Related       ()       ()


An alternate solution to the hat-matching problem, probability of exactly $k$ matches

the setup: $N$ people arrive at a party all of whom are wearing hats. We collect all the hats and then redistribute them. What is the probability that exactly $k$ of the party members receive their own hats back? let $E_i$ denote the probability that the $i^{th}$ man receives his own hat back. Then, $\space\space E_{i_1}E_{i_2}\dots E_{i_n} \space\space$ is the event that men labelled $i_1 , i_2 , \dots i_n$ get their own hats back. which implies... $P(E_{i_1}E_{i_2}\dots E_{i_n}) = \frac{(N-n)!}{N!}$ and $\color{red}{\sum\limits_{i_1<i_2<\cdots <i_n}}P(E_{i_1}E_{i_2}\cdots E_{i_n}) = \binom{N}{n}\frac{(N-n)!}{N!} = \frac{1}{n!}$ question1: are the above two formulas correct? The probability that at least $k$ of the party members receive their own hats back (using the inclusion-exclusion principle) is  $$\sum_{i_1 < i_2<\dots<i_k}P(E_{i_1}E_{i_2}\dots E_{i_k}) - \sum_{i_1 < i_2<\dots<i_{k+1}}P(E_{i_1}E_{i_2}\dots E_{i_{k+1}}) + \dots + (-1)^{n-k}\sum_{i_1 < i_2<\dots<i_n}P(E_{i_1}E_{i_2}\dots E_{i_n}) + \dots + (-1)^{N-k}\sum_{i_1 < i_2<\dots<i_N}P(E_{1}E_{2}\dots E_{N})$$ question2: is the above formula correct? Assuming that the above formulas are correct, the probability that at least $k$ of the party members receive their own hats back, comes out to be $$\sum_{i=k}^N \frac{(-1)^{i-k}}{i!} = \frac{1}{k!} - \frac{1}{(k+1)!} + \frac{1}{(k+2)!} - \dots +(-1)^{N-k} \cdot \frac{1}{N!}$$ question 3: is this correct? $ \text{ the probability that exactly k of the party members receive their own hats back is} $ $$||$$ $$\text{(the probability that at least k of the party members receive their own hats back)}$$ $$-$$ $$\text{(the probability that at least k+1 of the party members receive their own hats back)}$$ question4: is the above formula correct? Assuming everything until now is correct, the probability that exactly $k$ of the party members receive their own hats back, comes out to be $$= \bigg[\frac{1}{k!} - \frac{1}{(k+1)!} + \frac{1}{(k+2)!} - \dots +(-1)^{N-k} \cdot \frac{1}{N!} \bigg] - \bigg[ \frac{1}{(k+1)!} - \frac{1}{(k+2)!} + \dots +(-1)^{N-(k+1)} \cdot \frac{1}{N!} \bigg]$$ $$= \frac{1}{k!} - \frac{2}{(k+1)!} + \frac{2}{(k+2)!} - \dots +(-1)^{N-k} \cdot \frac{2}{N!}$$ but the given answer is $$\frac{1}{k!} \cdot \sum_{i=0}^{N-k}\frac{(-1)^i}{i!}$$ so something is definitely wrong What I want to ask: could you please answer questions 1, 2, 3 and 4? edit: I know that a simple way to answer the question is to use the concept of derangements, which gives the answer as $$\frac{\binom{N}{k} D_{N - k}}{N!}$$, where $D_n = n! \cdot \sum_{i=0}^{n}\frac{(-1)^i}{i!}$ edit1:


Cardinality of Natural and positive Rational numbers

I'm trying to prove that $\mathbb{Q}^{+}$ has the same cardinality with $\mathbb{N}$ by using the theorem Schroder-Bernstein.  So I just have to prove that $\mathbb{Q}^{+}\preceq \mathbb{N}$ and $\mathbb{N}\preceq \mathbb{Q}^{+}$.  For the first one we have to find a function $f:\mathbb{Q^{+}}\rightarrow \mathbb{N}$ one-to-one.Is this the same like showing that there exists $f:\mathbb{N}\times \mathbb{N}\rightarrow \mathbb{N}$ one-to-one ???Because $\mathbb{Q^{+}}$ it's of the form $\left \{ \frac{p}{q},p,q\in\mathbb{N} \right \}$.  Also the same idea for $\mathbb{N}\preceq \mathbb{Q^{+}}$,is it true that is the same with finding an one-to-one function $f:\mathbb{N}\rightarrow \mathbb{N}\times\mathbb{N}$???  Any advise will be helpful.


How do you override page.tpl.php in Omega 4?

I am using the  base theme, and am trying to override page.tpl.php.    This file is in the base theme in sites/all/themes/omega/templates/system.  When I copy it into my theme, edit it, clear caches, I don't see my changes?  Why can't I override this template?


How to prove the square integrable functions on $[0,1]$ are integrable on $[0,1]$.

How to exactly prove that the square integrable functions on $[0,1]$ are integrable on $[0,1]$? That is, For a function $f$, $\int_{[0,1]}f^2 dx < \infty~\Rightarrow \int_{[0,1]}f dx < \infty$ Or how to prove $\int_{[0,1]}f^2 dx$ diverges whenever $\int_{[0,1]}f dx$ diverges?


I have a script called teleport in my path. When I type tele and hit tab, I'd like for tab-completion to complete this to teleport.  However, there's another program installed on my system: telepathy-gabble-xmpp-console This starts with the same letters, so tab completion only gets up to telep.  If this were my system, I would just remove that one executable to improve my workflow. However, this is a shared server. (Accounts are not shared.)  Alternately, I could change my $PATH to exclude it. However, telepathy-gabble-xmpp-console is in /bin, and obviously I can't just remove /bin from my path.  The solutions described in  don't work, because defining a function or alias will still autocomplete to that function or alias.  How do I take a single executable out of my $PATH?  (Yes, I realize that this is a lot of work for a small benefit.)


chmod has no effect on files on flash drive

My old box running ubuntu 9.04 passed away, so I plugged a flash drive into a newer box running ubuntu 16.04.  But, I can't run scripts from there, because all files lost the x-permission. I can copy those files, but I can't chmod them, not even chmod a+w, not even using sudo.  chmod returns with no errors, echo $? shows 0.  It all worked perfectly on 9.04.  Here is what mount says:  /dev/sdd1 on /media/user/LABC type vfat     (rw,nosuid,nodev,relatime,uid=1000,gid=1000,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,showexec,utf8,flush,errors=remount-ro,uhelper=udisks2)   I am aware of  and I don't think it's a duplicate.  Firstly, with my problem here, not only +x is ignored. Secondly, the file where the answer proposes a change does not exist on my box.  Edit: What I don't understand, if FAT does not support linux-like flags, why did it work with ubuntu 9.04?  Edit2:  Nope, this didn't work. I unmounted the device, created a new directory, mounted it with  mount /dev/sdd1 /media/LABC -o dmask=000,fmask=111   I can see the files, but still cannot chmod or chown (as root user). chown gives "Operation not permitted".


How many constructor arguments is too many?

Let's say you have a class called Customer, which contains the following fields:   UserName Email First Name Last Name   Let's also say that according to your business logic, all Customer objects must have these four properties defined.  Now, we can do this pretty easily by forcing the constructor to specify each of these properties.  But it's pretty easy to see how this can spiral out of control when you are forced to add more required fields to the Customer object.    I've seen classes that take in 20+ arguments into their constructor and it's just a pain to use them.  But, alternatively, if you don't require these fields you run into the risk of having undefined information, or worse, object referencing errors if you rely on the calling code to specify these properties.  Are there any alternatives to this or do you you just have to decide whether X amount of constructor arguments is too many for you to live with?


Polynomial division over different fields

Suppose that we have irreducible polynomials over a field, $f,g\in F[x]$, and that $g$ divides $f$ in $L[x]$ where $L$ is a field containing splitting fields of $f$ and $g$ over $F$. Can we say that $g$ divides $f$ in $F[x]$? I've got this question from the following proof: "If there is finite group $G\subseteq \text{Aut }E$ satisfying $F=\text{Inv}(G)$ then $E/F$ is a Galois' extension." Considerations:  $f\in F[x]$ irreducible; $r$ such that $f(r)=0$; $\mathcal{O}_r=\left\{\sigma(r):\: \sigma\in G\right\}=\left\{r_1,...,r_m\right\}$; $g=\prod (x-r_i)$.  The author concludes that $g$ divides $f$ in $F[x]$ immediately after showing that $g\in F[x]$. But I don't consider that so trivial. I proved that it's true because if $f=gh$ for some $h\in L[x]$ then $\widehat{\sigma}(h)=h$ for any $\sigma\in G$ where $\widehat{\sigma}\:\colon E[x]\to E[x]$ is the unique ring homomorphism mapping $a\mapsto \sigma(a)$ and $x\mapsto x$, hence $h\in F[x]$. Is there any forward way?


How do I make a Villager Trade a Spawn Egg

I am trying to make a Custom Trade on a villager. I need to make him buy 8 gold nuggets and sell a Cow Spawn Egg.  basically you pay 8 nuggets for a Cow Spawner.  The ID of the Cow Spawn Egg is 92 but I don't know where to put it in the command /summon Villager ~ ~2 ~ {Invulnerable:1,CustomName:Spawner_Vendor,Profession:2,Career:1,Offers:{Recipes:[{buy:{id:gold_nugget,Count:8},sell:{id:spawn_egg,Count:1}}]}}


Headphone volume is way too loud in windows 10 even with an external usb sound card

I have a pair of Bose QC2 headphones and the volume is WAY too loud in windows on all jacks:  I have tried the following jacks:   speaker out on back of motherboard headphone out  external USB sound card (Sabrent Aluminum USB External Stereo Sound Adapter)   In each case, even a windows volume setting of 1/100 is too loud. Using the same headphones on my macbook pro the lowest volume is MUCH lower.  Is there any way to reduce the volume levels? I'm debating purchasing a more expensive external sound card that has a volume knob that is independent of the windows system volume.


How can I draw a rectangle around venn Diagrams?

I have tried some of the solutions to similar questions, but none of them included minipages, which seems to be the problem (I`m fairly new to LaTeX)  So, here's the coding:  % Definition of circles \def\firstcircle{(0,0) circle (1.5cm)} \def\secondcircle{(0:2cm) circle (1.5cm)}  \colorlet{circle edge}{black!50} \colorlet{circle area}{grey!20}  \tikzset{filled/.style={fill=circle area, draw=circle edge, thick},     outline/.style={draw=circle edge, thick}}  \setlength{\parskip}{5mm}  % Set A or B \begin{tikzpicture} \begin{minipage}[t][2cm][t]{.48\textwidth}     \draw[filled] \firstcircle node {$A$}                   \secondcircle node {$B$};     \node[anchor=south] at (current bounding box.north) {$M$}; \end{minipage} \end{tikzpicture} % Set A and B \begin{tikzpicture} \begin{minipage}[t][2cm][t]{.48\textwidth}     \begin{scope}         \clip \firstcircle;         \fill[filled] \secondcircle;     \end{scope}     \draw[outline] \firstcircle node {$A$};     \draw[outline] \secondcircle node {$B$};     \node[anchor=south] at (current bounding box.north) {$M$};     \node[anchor=west] at (current bounding box.east) {$A \cap B$} \end{minipage} \end{tikzpicture}     Also, if you know how to put the "B" in the center of the circle on the right I`d appreciate your help! Thank you.


I asked a question on Stack Overflow: . I want to award my bounty to  by user  However, my Stack Overflow account is suspended recently for 7 days, and the suspension still has 5 more days to end.And I know I can't vote, ask, answer or comment as pointed on  by  with the sentence below.  You will be unable to vote, ask, answer, or comment.  I couldn't find anything about not being able to accept an answer or award bounty so I tried to accept the mentioned answer above and award my bounty to it and I got a  Suspended users cannot vote  rejection which can be seen below with a screenshot.  I know this  If you do not award your bounty within 7 days, the highest voted answer created after the bounty started with at least 2 upvotes will be awarded half the bounty amount.  from . None of the answer given to my question is upvoted and the answer I mentioned is not the oldest one after the bounty started so it won't be awarded by community. What can I do? (except being a good guy and not get suspended :))


On SU there's the  which is suspended for quite some time. And I also know that it is used for spammers, but how does it work? Does the account of the spammer get 'linked' to Deposit? Do the answers get moved there?


How do I get add-apt-repository to work through a proxy passwd protected network?

I am trying to install ubuntu SDK but  when I enter this command:  sudo add-apt-repository ppa:ubuntu-sdk-team/ppa && sudo apt-get update && sudo apt-get install ubuntu-sdk   I got an ppa error to check internet connection. So to over come this problem, I used these commands  export http_proxy=htt://username:passwd@proxyserver.net:port/export sudo su  add-apt-repository ppa:ubuntu-sdk-team/ppa && sudo apt-get update && sudo apt-get install ubuntu-sdk   But now I am getting this error:    No passwd entry for user 'add-apt-repository   Please help me out, as I really want to work on this SDK as I want to do something in open source world and want to develop something. Thanks!


Exactly two solution of differential equation.

Does there are differential equations of the form $y'=f(x,y),y(x_{0})=y_{0}$ which has exactly two solutions. Actually i have only differential equations which has either no solution or unique solutions or infinitely many solutions. Thanks.


If $\gcd(a,b)=1$, then $\gcd(a^n,b^n)=1$   This seems clear, but I don't know how to prove this..  I was trying to show this by induction such that if $a^{n+1}$ = $rs$ and $b^{n+1}$ = $rt$, then $s,t$ are divisible by $a,b$ respectively, but i think this is a wrong way..


64-Bit Supporting Processor and 3GB RAM. Should i go for Windows 8 32-bit or 64-bit?

This might sound like a duplicate but i couldn't find a clear answer in any of the questions answered in this site or any other.  I have a laptop with AMD Athlon(tm) II Dual-Core M320 processor  and it has 3GB DDR2 RAM.  Currently I am having Windows 7 64-bit OS installed.Now i'm about to upgrade it to Windows 8.I was wondering whether i should go for a 64-bit one or 32-bit one...  Now i know that 64-bit Operating System is better if you have a RAM higher than or equal to 4GB. Since i have a processor which supports 64-bit would it be a disadvantage to go for a 32-bit OS?   Which Operating System Would be best for me, X64 or X86 ?


I have this implementation of an array handler where it takes an array and adds a new value of the array.   at the moment I have it working for long type.   I want it to work for any type, if that is possible.  current implementation :   public class ArrayHandler  {     public static long[] add(long[] arr, long value)     {         long[] newarr = new long[arr.length+1];         if(arr.length == 0)         {             newarr[0] = value;         }         else         {             for(int i = 0 ; i < arr.length ; i++)             {                 newarr[i] = arr[i];             }         }         newarr[arr.length] = value;         return newarr;     } }


Getting Script Error has occurred in script on this page when running polygon to raster conversion?

i keep getting the script error problem every time i try using polygon to raster tool in ArcGIS 10.1. Please help me how I can solve this?  screenshot embedded


Let $(a_n)_{n\ge 1}$ is an increasing sequence of of positive numbers such that $a_n \to \infty$ as $n \to \infty $. Then $\sum_{n=1}^\infty \frac{a_{n+1}-a_n}{a_{n+1}}$ diverges.


"The total area underneath a probability density function is 1" - relative to what?

Conceptually I grasp the meaning of the phrase "the total area underneath a PDF is 1". It should mean that the chances of the outcome being in the total interval of possibilities is 100%.  But I cannot really understand it from a "geometric" point of view. If, for instance, in a PDF the x-axis represents length, would the total area underneath the curve not become larger if x was measured in mm rather than km?  I always try to picture how the area underneath the curve would look if the function were flattened to a straight line. Would the height (position on the y-axis) of that line be the same for any PDF,or would it have a value contingent on the interval on the x-axis for which the function is defined?


Im trying to draw the following graph: |x − 1| + |y − 1| ≤ 1  This is what I have:  \documentclass{standalone} \usepackage{pgfplots} \begin{document} \begin{tikzpicture} \begin{axis}[   xlabel=$x$,  ylabel={$y$} ]  \addplot {|x−1|+|y−1|≤1};  \end{axis} \end{tikzpicture} \end{document}   However this doesn't work. Would anyone be able to suggest why?


I have obtained a large chunk of approximately week old moose meat that has been never stored in a freezer. I'm planning to eat it during the next week or two.  I cut it to 8 smaller steak-sized chunks, and cut 4 of those into small bits of which I'm going to make moose stew with carrots and onions. I'm just fried the small bits in my frying pan, and am currently making the stew in my pot.  The trouble is, I don't have a large frying pan or a large pot. I only have one small pot which I have free to use for the moose stew. The small bits of half of the moose meat fit in there with carrots and onions.  What should I do for the 4 other steak-sized chunks?   Should I just store them unfried in the refrigerator and cook when I need to, which will be approximately week from now? (Currently they are in the refrigerator, but I can always fry them in my frying pan that is free now.) Should I fry them in my frying pan and store them in the refrigerator after frying them?   I want to maximize the amount of time the meat stays edible. If it stays edible for only one week from now, I have to eat moose meat every day. If it stays edible for two weeks, I can eat moose meat only every other day.  I of course theoretically have the option of just storing the rest in my freezer, but my freezer (or actually two freezers) are half full with frozen moose meat!


I am brewing a Black Rock..."Miners Stout" .  and it's been nearly a week in the fermenter with none to very little movement in the airlock. ! Seems odd as to all the other stouts that I have brewed. Would this mean a faulty beer mix ?  the fermenter is sealed as for using vasaline  around the thread and rubber seal...plus the rubber bung and the end of the airlock. Temp; has been at 24c .  (as on a heat pad). OG= 1055. There is a thin line of Krausen around fermenter. Your thoughts would be welcome. From ...Darkest-porter


Is it dangerous to use a reference in PHP?

$referer = null_change($_SERVER["HTTP_REFERER"], "");   When I execute the above, the following error is displayed.  Notice: Undefined index: HTTP_REFERER in (path) on line (number)  To solve that error, I created the following function and used it to assign default values of $_SERVER, $_POST, and $_GET.  function null_change(&$var, $type) {     if(is_null($var) === true) { $var = $type; } } $referer = null_change($_SERVER["HTTP_REFERER"], "");   This does not indicate any error, and now I can set default value to $_SERVER ["HTTP_REFERER"] with "".  However, some of posts below say that to use reference variables in PHP is dangerous.      I have read the above posts in detail, but I can't understand why using reference variables could be a problem in my case.  using reference variables can be a problem in my case?  update :  this question is about danger of reference variables. not about reliability of HTTP_REFERER.


Find all possible values of $z$ such that $\cos z=\frac{3}{4}+\frac{i}{4}$.   Here is my attempt:  $\cos z=\frac{\mathit{e}^{zi}+\mathit{e}^{-zi}}{2}=\frac{3}{4}+\frac{i}{4}$  $2\mathit{e}^{zi}+2\mathit{e}^{-zi}=3+i$  $2\mathit{e}^{2zi}+2=3\mathit{e}^{zi}+i\mathit{e}^{zi}$  Rearranging and using the quadratic formula, I get:  $\mathit{e}^{zi}=\frac{3+i\pm \sqrt{-6-6i}}{4}$  The answer in the back of the textbook is $z=\pm (\frac{\pi}{4}+2\pi n-i\frac{1}{2}\log 2)$. But after logging both sides of my equation and dividing each side by $i$, I do not get the same $z$. Is this because my solution is wrong or is it because I simplified wrong?  Any tips are appreciated!


Kolmogorov-smirnov two-sample confidence level

I do not find information about how to calculate the $c(\alpha)$ "by hand" (see wikipedia article for two samples: ) for the formula:  $ D_{n,m} > c(\alpha)\sqrt{\frac{n+m}{nm}} $  I would like to try different levels of $\alpha$ not included in the table provided in the article.


What preposition should I use when talking about computer and softwares

My question is about prepositions and what to use when talking about computer and software.   I will Install a software (in,on,into) my computer a software was installed (in,on,into) my computer


Let $p$ and $q$ be different prime numbers.   How to show that $[\mathbb{Q}(\sqrt{p}, \sqrt{q}):\mathbb{Q}]=4$?  I did it this way:  $\textbf{Edit: (Is there something to improve?)}$  Proof:  $\mathbb{Q}(\sqrt{p},\sqrt{q})=\mathbb{Q}(\sqrt{p})(\sqrt{q})$, because the first one is the smallest field that contains $\sqrt{p}, \sqrt{q}$ and $\mathbb{Q}$, and the second one is the smallest field that contains $\sqrt{q}$ and $\mathbb{Q}(\sqrt{p}$).  It's $\sqrt{q} \notin \mathbb{Q}(\sqrt{p})$, since if we suppose that we had $\sqrt{q}\in\Bbb Q(\sqrt{p})$ and since $\Bbb Q(\sqrt{p})$ is quadratic over $\Bbb Q$ that would mean that $\sqrt{q}=a+b\sqrt{p}$, for some $a,b \in \mathbb{Q}$.  Taking squares and isolating $\sqrt{p}$:  $\sqrt{p}=\frac{q-a^2-b^2p}{2ab}\in\Bbb Q$, which is impossible.  So $[\mathbb Q(\sqrt{p},\sqrt q):\mathbb Q(\sqrt p)]=2$, since $x^2-q$ is the minimal polynomial of $\sqrt{q}$ over $\mathbb{Q}(\sqrt{p})$.   The same for $[\mathbb{Q}(\sqrt{p}):\mathbb{Q}]$, since $x^2-p$ is symmetric.  $\Rightarrow [\mathbb{Q}(\sqrt{p},\sqrt{q}):\mathbb{Q}]=[\mathbb{Q}(\sqrt{p},\sqrt{q}):\mathbb{Q}(\sqrt{p})]\cdot[\mathbb{Q}(\sqrt{p}):\mathbb{Q}]= 2 \cdot 2 =4$.  Is there something I can improve?


Meaning of notation with two letters inside of parentheses [binomial coefficient]

What does the notation in the red box mean?   $$\Huge e^{\displaystyle \large \sum_{k=0}^n \bbox[2px,border:2px solid red]{\color{black} { {n \choose k}}}~\omega^k}$$


I was given this chunk of code to place in my html page but I know nothing about javascript so I have no idea where to place it and what kind of tag to place it in.  $('input[type=radio]').change(function() {  $('input[type=radio]').each(function(index) {   $(this).closest('tr').removeClass('selected'); });  $(this).closest('tr').addClass('selected'); });


Full Disk Encryption using Ubuntu Core\Snappy

I'm not sure if this is the right place to ask , but anyway :   I'm running ubuntu-core (snappy) on Raspberry Pi 3 and I'm willing  to perform partition\full disk encryption using cli\code. is it possible?  thanks


I've an issue with an obj file. Importing this file in blender:  the mesh not appear. Only by rotating and zooming-out something apperas, but not the whole geometry.  With other CAD and obj viewer the mesh is displayed correctly. What's wrong?  Thanks!


Ubuntu 13.04/13.10 - low graphics mode/black screen after login

Since last week, my Ubuntu 13.04 installation started booting up in low graphics mode out of nowhere. I tried a number of solutions found on this site but to no avail. The other night, I decided to upgrade to 13.10 to see if the issue would be fixed in the process. Since then, the system starts fine, but when I login to my account, I'm just presented with a black screen. I switched to the terminal and did any necessary updates, but to no avail. I don't even know where to start debugging this issue, so I'd appreciate if someone could point me towards the first place to start looking?


My video (.mkv) thumbnails are green (or monochromatic)?

When I installed Ubuntu Gnome 17.04 , Then it automatically got fixed, now it's generating the Thumbnails but as weird as it may sound, they're all green (or purple or pink but they are all monochromatic for sure). files are not affected by this only the thumbnails. other video file formats are okay as well, .mp4 .flv, just the .mkv's are affected.   I've no idea where should I start to fix this.    affected .mkv files    not affected .mp4 files


Let the polynomial  $f(x)=x^n+a_1 x^{n-1}+a_2 x^{n-2}+.....a_{n-1}x+a_n$ have integral coefficients. If there exists four distinct integers $a,b,c$ and $d$ such that $f(a)=f(b)=f(c)=f(d)=5$ show that there is no integer $k$ such that $f(k)=8$  I have tried to prove it but I somehow feel that my proof is incorrect please point out the errors and suggest some other way to do the question. This how I proceeded  $\frac{x^{n+1}-1}{x-1}=x^n+a_1 x^{n-1}+a_2 x^{n-2}+.....a_{n-1}x+a_n $  $\frac{a^{n+1}-1}{a-1}=5$  hence $\frac{a^{n+1}-1}{5}=a-1$  Since $a$ is an integer $a-1$ will also be an integer hence $5|a^{n+1}-1$  Using fermat's little theorem we know that $a^4-1\equiv_5 0$  Since $f(a)=5$ we get $n+1=4$  Let k be an integer such that $f(k)=8$ $\frac{a^4-1}{8}=a-1$ Since  $a-1$ is an integer $8|a^4-1$   We will consider two cases    when $a$ is an even integer when $ a$ is an odd integer   If $a$ is even then $a^4-1$ will be odd and it not be divisible by $8$  If $a$ is odd then it will be relatively  prime to $8$ hence $8$ will be Carmichael number  $a^7-1\equiv0(mod8)$  which proves that $a^4-1$ is not divisible by 8. $\therefore$ there  is no integer k such that $f(k)=8$


Title Case for a sentence ending with parentheses

I would like to title case every sentence ending with parentheses containing uppercase letters only NB: do not title case certain words such as "for, and, the" for instance. So the original sentence is:  foundation for economic education (FEE)  And it should be like that:  Foundation for Economic Education (FEE)  Any help is much appreciated! Here is my "faulty" code, it capitalizes everything before the parenthesis... (^[\p{L}\W]+)([(][\p{Lu}]{3,}[)]$)  \U\1\2


How to remove (or hide) Chat Status Icons from Messaging Menu

I would know how to remove or hide in Ubuntu 12.04 the  (available, away, busy, invisible and offline) from Messaging Menu as I am not using any instant messenger. I do not want to remove the entire menu, just that section.  Thank you very much and best regards!!


My passport was detached from the front cover but all the pages are intact. what shall i do?

My passport was detached from the front cover but all the pages are intact. I have an Indian passport and wants to travel from Philippines to India, is it possible?


After the downfall of Voldemort, what happened to the Death Eaters?  They committed many crimes, including mass murder and torture. Nothing in the books made mention of their punishments. What happened?


automatically zoom map to maximum extent of wms layer

I try to automatically zoom map to maximum extent of layer after adding layer to map. I tried to code like this.  var layer = OpenLayers.Layer.WMS(.......);  map.addLayer(layer);  map.zoomToExtent(layer.getDataExtent());   But it doesnt' work. I also changed like this  map.zoomToExtent(layer.getMaxExtent());   It still doesn't work. What can I do to solve this issue.


Where can I get the grid representation for a projection on meters?

In PostGIS I have the following projection:  aut_srid = 21781      text = "PROJCS["CH1903 / LV03",GEOGCS["CH1903",DATUM["CH1903", SPHEROID["Bessel 1841",6377397.155,299.1528128,AUTHORITY["EPSG","7004"]], TOWGS84[674.374,15.056,405.346,0,0,0,0],AUTHORITY["EPSG","6149"]],      PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]], UNIT["degree",0.0174532925199433,AUTHORITY["EPSG","9122"]], AUTHORITY["EPSG","4149"]],PROJECTION["Hotine_Oblique_Mercator_Azimuth_Center"], PARAMETER["latitude_of_center",46.95240555555556], PARAMETER["longitude_of_center",7.439583333333333], PARAMETER["azimuth",90],PARAMETER["rectified_grid_angle",90], PARAMETER["scale_factor",1],PARAMETER["false_easting",600000], PARAMETER["false_northing",200000],UNIT["metre",1,AUTHORITY["EPSG","9001"]], AXIS["Y",EAST],AXIS["X",NORTH],AUTHORITY["EPSG","21781"]]"   I found this picture in the PDF at the end of the  but I need a map file with the grid representation, something in shapefile, tab or similar.


Prove that for a nonzero element $a$ of a field $F$ with $q$ elements $a^{-1} = a^{q-2}$

This is a statement from "The Linear Algebra a Beginning Graduate Student Ought to Know" by Jonathan S. Golan.  Let $F$ be a field having $q$ elements and let $a$ be it's nonzero element. Then $a^{-1} = a^{q-2}$  If $a = 1$, than it holds.  If $a \neq 1$, then $a^{q-1} = 1$( the multiplicative order $|a|$ of a divides $q-1$ ).  What can be done next?


An equivalence for $\operatorname{grade}(I,M)\ge 2$.

Let $R$ be a Noetherian ring, $M$ a finite $R$-module and $I$ an ideal of $R$. Show that $\operatorname{grade}(I,M)\ge 2$ iff the canonical homomorphism $M \mapsto\operatorname{Hom}_R(I,M)$ is an isomorphism.   This question is Exercise 1.2.24 in the book: Winfried Bruns and Jürgen Herzog, Cohen-Macaulay Rings, Cambridge University Press, 1998.


I'm trying to include an image inside a text but it does not work ...  Here is an example of what I would get in latex ...    Somebody can help me plz?  Thx :)


Use workflow to move document within document library to different folder in same library

I am looking to use a workflow to move documents within a document library to a specific folder in the same document library (this to manage access rights on different documents via the libraries). Could anyone advise how I can setup a workflow to move a document to a folder? I expected this to work similar as moving documents between document libraries, but it appears to be more complex.  Appreciate your input.


Convert GROUP_CONCAT statement into SQL Server

I am trying to convert the following query into SQL Server from MySQL:  SELECT name, GROUP_CONCAT(DISTINCT language) FROM table GROUP BY name   It seems like STRING_AGG() is the related function name in SQL Server, but I haven't yet been able to write the correct query.  How would this be properly be done?  Update: I believe I may not have access to that function (pre 2017). How would I then do something like:  SELECT name, (select language from table ??) FROM table GROUP BY name


Is there a way to fake a dual (second) monitor

Is there a way to fake a dual monitor for testing.    I have only one monitor and I have to make an application that is suitable for two monitors.  The second monitor screen should appear as a window on my primary monitor.


How to write the metric transformation of conformally related $S^3$ and $R^3$

This should be a simple problem, yet I'm having trouble seeing the answer. Given two Riemannian metrics related by a conformal transformation $e^{2\sigma(x^{i})}$ . The relationship between them is simply:  $$\bar{g}_{\mu\nu}=e^{-2\sigma(x)}g_{\mu\nu}$$  Yet when it comes to the sphere $S^{3}$ and the flat space $R^{3}$, I know they are conformally related, and yet I can't find a way to write them in the above form. I'm supposing it may have to do with the fact that $R^{3}$ has had a point removed (ie. one point compactification). Is there actually a way to write this? As an aside I study physics, but would like to understand the deeper mathematical relationships that are often “swept under” the proverbial rug.


The proof of the formula $z = |z|e^{i \phi}$

I would like to proof that: $$z = |z|\big(\cos(\phi) + i \sin(\phi)\big)$$ of course the second part can be shown using Euler's formula. That's why I would like to prove that: $$z = |z|e^{i \phi}$$ I can use only the series definition of exp and some basic properties like $e^{a+b} = e^ae^b$. I think it must be quite trivial but I really don't know how to do it properly.    I think that my problem is a bit different to the one in the suggested  post. I do know how to prove that $e^{i\phi} = \cos \phi + i\sin \phi$ but I do not know how to prove that  $$\forall_{z \in \mathbb{C}} z = |z|\exp(ix)$$ for some $x \in \mathbb{R}$.


When graphing the implicit equation $y^x=x^y$ it seems like it consists of two possibly explicit curves. On the one hand there is the linear solution $y=x$. But as it appears there is a second curve monotonously decreasing as x increases, intersecting with the curve $y=x$ at coordinate point $(2,2)$. Is there any way to find out the explicit form of this other curve?


What does the phrase "good for you" mean?

What does this phrase mean? And in what cases is it appropriate to use it?


I've recently changed the default 700x35 tires and 35mm Schrader inner tube to 700x25 slicks with 25mm Presta inner tubes.  However whilst fitting the new tire and inner tube, I noticed that the inner tube had about an inch or two of excess length to it. This mean I had to tuck it into the tire, doubled back on itself.  I've doubled checked the inner tube packaging and it's definitively for a 700 diameter rim.  I presumed that it would sort itself out when I pumped up the tires. Is this normal?


Alien creature ends up taking over its whole planet. Starts small and takes over slowly

I've been trying to remember the title of this short SF story for ages now.   There is a creature (I think its actually immobile) that has a small plot of land on a planet. It starts growing and there is something to do with a small pool of water that it uses to help it breed/grow. It ends up taking over more and more of the planet's surface.   It's likely to be by a science fiction big name from the golden age (I think that's most likely anyway)


How do reputation bonuses for associations between accounts work?

I've just joined super user, and I've associated my super user account with other accounts (at least one of which has >200 reputation), but my SU account still has a reputation of 1. Is it working like it should?