Correct code structure for class/function templates?

Let's say we have a class with a function template.  Header file Sort.hpp with the class definition:  #ifndef TEST_SORT_HPP #define TEST_SORT_HPP  #include <vector> using namespace std;  class Sort { public:     template <typename T>     static void mergeSort(vector<T>& arr); };  #endif //TEST_SORT_HPP   Source file Sort.cpp with the function implementation:  #include "Sort.hpp"  template <typename T> void Sort::mergeSort(vector<T> &arr) {     // the implementation is irrelevant at the moment }   This structure would not work for . As also stated in the referenced answer, there are ways to work around this issue, if I do not want to include the implementations straight into the header file.  However, those solutions do not work for me:   If I add #include "Sort.cpp" in the end of the header file (before #endif), I get the error: redefinition of 'static void Sort::mergeSort(std::vector<T>&)' I do not know in advance all the types the sort is used for and cannot declare them explicitly in the end of the source file. I also cannot remove #include "Sort.hpp" from the Sort.cpp file, because then 'Sort' has not been declared   How is this actually done to make it work?  What are the best practices for organizing code into files in case of:   ... creating class templates with unknown types (unlimited)? ... creating class templates where it is known which certain types will be used?


Show that $H$ is a normal subgroup of $G$ is it has index $2$.

I'm stuck on this question for hours. I think I need a little help and a different point of view to complete it.   Let $H$ be a subgroup of a group $G$ and suppose that $H$ has index two in $G$, i.e., that there are precisely two elements in $G/H$. Show that $H$ is a normal subgroup of $G$.  Thanks in advance.


Can I push an enemy into a bag of holding?

Here is the scenario I envision: I hold a bag of holding in one hand and use the other to make a shove attempt against an enemy.     If I succeed can I shove him into the bag of holding? He can just open the bag from the inside but what if I hold the bag shut/put it inside a box/tie the top off? Can I destroy the bag effectively teleporting the enemy into the astral dimension? Can he destroy the bag from inside?   some extra info:     A bag of holding has a 2 foot diameter mouth (a quick google tells today's well fed humans are about 15-16 inches in the shoulders) A bag of holding has the volume of a 4*4*4 foot room, its square so while most medium creatures wont fit standing they will still fit by volume, maybe require a push to prone first and/or a grapple?   I'm asking because artificers potentially have a free way to make bags of holding daily and I'm wondering if this can be used for wrestling shenanigans or candlejacking


Is it feasible to build a stream cipher from a cryptographic hash function?

A few years ago I devised a symmetric-key system that worked like so:  H()   = some hashing function h     = the number of bits in the result of H() key   = bits to be used as a key ^     = the XOR operation +     = concatenation len() = the length function (in bits)  max = ceiling(len(cipertext) / h) pad = pad_0 + ... + pad_max pad_0 = H(key) ^ H(plaintext) pad_n = H(pad_(n-1)) cipherpart_n = plaintext_n ^ pad_n ciphertext = H(plaintext) + cipherpart_0  + ... cipherpart_max   Basically, it builds up a "pad" based on the hash of the message and hash of the key and XORs the message against it.  I am not actually an expert, so I was wondering why an approach like this isn't very common.


I am trying to put a Minecraft world onto a USB stick. My problem is that when I launch Minecraft the world is there, but when I go into Minecraft saves it is not in my finder. I need this for a school project and cannot take my Mac with me to school. Any suggestions on where it might be?


When you are standing in a running train if you jump means will you be in same place or will you be in front or back?


Conjugate prior for a Gamma distribution

I need to update the failure rate (given as deterministic) based on new rate of failure about the same system (it is a deterministic one too). I read about conjugate priors and Gamma distribution as a conjugate for the Poisson process.   Also, I can equate the mean value of Gamma dist. ($\beta/\alpha$) to the new rate (as a mean value) but I do not have any other information such as standard deviation, Coefficient of Variation, 90th percentile value,...etc. Is there a magic way to manipulate that and find parameters for the prior Gamma hence I get the posterior which Gamma too?


For example, if there is a lava river surrounding a castle. There is a drawbridge that can be lowered, but the lever is on the other side. PCs couldn't find a hidden passageway,either because PCs failed necessary check and couldn't find it or just because there isn't one. They don't have rope to try to pull the lever down. Or if PCs want to rob a house, but can't pick a lock, they see that window on the second floor is open. Can one PC use his Strength to throw another PC that is one size smaller, with other PC using his Dexterity or Strength to not fall down or lose balance?


How can I switch between starting a coroutine vs running the routine all at once?

I'm generating a level, and I have an optional delay to show the steps level generation one by one.  If my generationDelay boolean is true, I want to use StartCoroutine to spread the generation out over time. If it's false, I want to call the same method but without StartCoroutine.  The problem is that the method is type IEnumerator.  I can make two methods one type of IEnumerator and one not. But I wonder if there is a way to use one method.  In the first script top i did:  public bool generationDelay = false;   Then in a method:  private void BeginGame()     {         mazeInstance = Instantiate(mazePrefab) as Maze;          if (generationDelay == true)         {             StartCoroutine(mazeInstance.Generate(generationDelay));         }         else         {             mazeInstance.Generate(generationDelay);         }     }   Then the other script where the method Generate is: In the top:  public float generationStepDelay = 0.01f;   Then the method Generate:  public IEnumerator Generate (bool generationDelay) {          if (generationDelay == true)             WaitForSeconds delay = new WaitForSeconds(generationStepDelay);         cells = new MazeCell[size.x, size.z];         List<MazeCell> activeCells = new List<MazeCell>();         DoFirstGenerationStep(activeCells);         while (activeCells.Count > 0) {             yield return delay;             DoNextGenerationStep(activeCells);         }     }   I'm getting an error on the line:   WaitForSeconds delay = new WaitForSeconds(generationStepDelay);      "Embedded statement cannot be a declaration or labeled statement"   And an error on the line:  yield return delay;      "The name 'delay' does not exist in the current context"   The reason I want to use a bool variable is that when i'm using StartCoroutine it's kind of slow, even if I change the value of generationStepDelay to 0 it's kind of slow. And if I'm not using StartCoroutine and not using the Generate method as IEnumerator it will work fast.  So i wonder what should I do and how?


Do the Earth and I apply the same gravitational force on each other in GR?

Our high-school teacher told us that the Earth pulls us with some force $F$ and we pull the Earth with the same force $F$. Within Newtonian physics this is true because of , but let’s consider . My mass is small; so I don’t warp space-time much. But Earth’s large mass warps space-time to a far greater extent.  So do I pull Earth with the same force it pulls me? If yes, how?


If $f'(x) = 0$ for all $x \in \mathbb{Q}$, is $f$ constant?

Let $f$ be a differentiable function on $\mathbb{R}$ such that  $$f'(x)=0,\forall x\in \mathbb Q.$$  Prove or disprove that  $$f(x)=c$$  for some constant $c$. I've heard this problem is true, but I'm not sure. Can you prove it or provide a counterexample?  Auxiliary question: I wonder the converse of it, if $f′=0$ for all irrational, can we say that $f$ is constant?


A term for providing irrelevant and hiding relevant information

For example, you're doing a research for a car to purchase. You get a list of cars with engine number, city where a car was assembled, and a color. What's missing is make, model and price.


I know that we can not use yield in a try-catch block according to the documentation:     A yield return statement can't be located in a   try-catch block. A yield return statement can be located in the try   block of a try-finally statement. A yield break statement can be   located in a try block or a catch block but not a finally block.   I also know that Python has the same .  My question is: Why?  Why does this result in a compiler error? Is there some sort of underlying reason why this isn't allowed?


The questions here are not about meaning. They are about the usage of the verbs get and catch in the context of getting a cold.   says that get can be used to mean 'to become infected with an illness; to suffer from a pain, etc.' and gives the example:     I got this cold off you.   My grammar confirms the dictionary and talks about get a cold in the chapter dedicated to the verb get. It also brings catch a cold to exemplify English collocations.  However, I was browsing the Internet and it seems that, at least for Americans, if we say I got a cold it is kind of uneducated. I caught a cold is what we should say.  1) Is this true? Is it better to say I caught a cold than I got a cold? 2) If it is the case, does this apply to British English as well?


When is it better to use String.Format vs string concatenation?

I've got a small piece of code that is parsing an index value to determine a cell input into Excel.  It's got me thinking...  What's the difference between   xlsSheet.Write("C" + rowIndex.ToString(), null, title);   and  xlsSheet.Write(string.Format("C{0}", rowIndex), null, title);   Is one "better" than the other? And why?


How can i read an entire text from a txt file?

Im working on a project for school, and im stuck at reading a txt file, i tried using this code   public static String txt (String a)     {       String[] Text= new String[Readfile.counter(a)]; // Creates a string array for every word       String s="";         int i=0;       try{          Scanner scan =new Scanner(new File(a));           while(scan.hasNext()){              s =scan.next(); // läser en rad från fil till s             Text[i]=s;             i++;            // System.out.print(s + " "); // skriver ut den            }        }       catch( Exception exp) {}       String txt= Arrays.toString(Text);       return txt;       }   wanted to save the strings in an array as it loops then turn it into a string, but the problem here is that the results will have brackets"[]" and commas "," in it. Is there any way to read the entire txt file and save it in a single variable?


Why deleting pointer to list causes core dump

While learning , I notice that there is no delete adj for the new list<int> array:   adj = new list<int>[V];   Will it cause a memory leak? For this question, I made a  to using delete to release the memory explicitly.   #include <iostream> #include <list> #include <algorithm>  using namespace std;  int main() {     list<int> *adj = new list<int>[3];     cout << adj->size() << endl;      delete adj; }   delete operation will cause coredump. So why does deleting pointer to list cause core dump?  How to release the memory by new operation?


how to make a 360 video (turntable) of an Object using a python script

How to make a video of a PLY mesh from python script? I need to place the model in space and rotate it of 360 degrees on an axis.  Here is a ply example:


Present Simple or Present Continuous with "these days"

"These days" express the period around now. Then, I wonder, why is used the Present Simple in the following sentence?:   These days I travel a lot.  I’m spending more and more time away from home. (Considering the rule given above, I would say: These days I am travelling a lot.)   I've also come across the sentence where both  tenses are considered correct:   These days, more and more people prefer / are preferring to retire    early.   So, is it optional whether we use present simple or continuous with "these days"?


How to calculate GCD of Gaussian integers?

Let $\mathbb Z [i] =\{a+bi: a,b \in \mathbb Z\}$.  What is the gcd of $11+7i$ and $18-i$ in $\mathbb Z [i]$?


What's the difference between a Key Derivation Function and a Password-Hash?

It seems to me that anything that was sufficiently good as a KDF would work just fine as a password hash, though the reverse might not be true.  Are there considerations specific to password-hashing that don't apply to KDFs?  To clarify: This is about key-stretching KDFs.  Not the kind for diversifying keys (eg. HKDF)


I am attaching my phone via usb to my ubuntu box to charge it.  Unfortunately, every few seconds a popup appears with the following error:  Unable to open MTP device '[usb:003,009]'   I don't care if ubuntu is able to open the device or not, I just want to supress the error.  How can I do this?


How to show eigenvalues of $X^T X$ are all non-negative?


$\lim _{x\to 0}\left(\frac{a^x-1}{x}\right)$ I replace ${a^x-1} = t$ but dont know, what doing next.


I have never used blender before, and I don't know how to control the windows on the interface.


How do I use command line to install the "GNOME Shell Integration" package?

Via the  webpage, to activate this package, I need to click on the button "Available on Chrome".  I would like to install/active this  package via the terminal command line. How can I do so?


Imputation before or after splitting into train and test?

I have a data set with N ~ 5000 and about 1/2 missing on at least one important variable. The main analytic method will be Cox proportional hazards.   I plan to use multiple imputation. I will also be splitting into a train and test set.  Should I split the data and then impute separately, or impute and then split?  If it matters, I will be using PROC MI in SAS.


phpinfo() and php -v shows different version of PHP

I wanted to know which php version I am using so I wrote the standard script:   phpinfo();   Which gives me  PHP version 5.6.10   The correct PHP version needed for my application. When I tried in terminal:  php -i   or  php -v   It shows me:  PHP version 5.3.2   Which I don’t need. Then I tried with:  which php   It shows me:  /usr/bin/php   Now I am confused which version of PHP I am using. The files are uploaded to the hosting website and I cannot make any changes to the config files like httpd.conf or php.ini.


Parsing error when bootstrapping on Windows

I am trying to get Juju working on Windows 8 but I am running in to some errors when trying to get juju to see my ssh keys:  C:\Users\username> juju bootstrap error: error parsing environment "azure":     read C:\Users\user\SkyDrive\Documents\Azure\ssh\: The handle is invalid.   I've added a public key I generated with putty to the directory above called azure  My environments.yaml file has this in it:  authorized-keys-path: C:\Users\user\SkyDrive\Documents\Azure\ssh\   Any ideas?


I want only the section name in my header, not the section number

I have a problem regading fancy headers. I want to have the section name only in my header, but when I am using the following code I get the section number as well:   \pagestyle{fancy} \fancyhf{} \renewcommand{\sectionmark}[1]{\markright{\arabic{section}.\ #1}} \fancyhead[LE,RO]{\nouppercase{\rightmark}} \fancyfoot[RE,RO]{\thepage} \renewcommand{\headrulewidth}{1pt}   Anyone knows a way to solve this?


How to use phonetic IPA characters in LaTeX

I wish to write a paper about linguistics, so I thought about trying LaTeX. Sadly I couldn't figure out how to write the unique characters I need for my work, for example epsilon with a little tilde above it, i with two dots above it, velar nasal and so on.  I know I can write stuff like ó with \'{o}, but I couldn't figure out how to put the epsilon in there, or how to write more unique characters.


Implementing variadic method in C++ issue

I'm trying to implement a variadic method but when I try the following code it doesn't compile:  Configurations.h  #ifndef Test_Configurations_h #define Test_Configurations_h  #include <vector>  class Configuration { public:     Configuration(){}     int someData; };   class Configurations { public:     void addConfiguration (Configuration config);      template<typename... Args>     void addConfiguration (Configuration first, Args... args);  private:     std::vector<Configuration> _configs;  };  #endif   Configurations.cpp  #include "Configurations.h"  void Configurations::addConfiguration (Configuration config) {     // do something }  template<typename... Args> void Configurations::addConfiguration (Configuration first, Args... args) {     // Do something }   main.cpp  #include <iostream> #include "Configurations.h"   int main(int argc, const char * argv[]) {      Configuration c1;     Configuration c2;      Configurations configurations;      configurations.addConfiguration(c1, c2);      return 0; }   When I try to call the method  addConfiguration (config1, config2)   The compiler give me the following error:  Undefined symbols for architecture x86_64:   "void Configurations::addConfiguration<Configuration>(Configuration, Configuration)", referenced from:       _main in main.o ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation)   I think that I'm not declaring properly the method, but I don't know where is the error.  Thanks in advance!


Is string Object Created in Heap if we use new String("abcd")

String s1 = new String("anil");     String s2 = s1.toUpperCase();     String s3 = s1.toLowerCase();     System.out.println(s1 == s2);     System.out.println(s1 == s3);   if string object created in heap then both are false.But it gives false,true.


SSL certificate for www. and non-www domain

What SSL certificate should I buy to get my domain work? I use nginx web server and want that all users requests go to https.    http://example.com -> https://example.com http://www.example.com -> https://example.com https://example.com -> https://example.com https://www.example.com -> https://example.com   Do I have to buy 2 certificates for both domains example.com and www.example.com? Or may I buy only one certificate with subdomain support? What does SAN mean in SSL-certificates and how can it help me?    What nginx config do I need to get desire redirection?  Thanks.


Broken icon of Skype in the Windows 7 taskbar

Usually, I have Skype pinned to the taskbar on Windows 7 and its icon prints normally. For a few days, this icon has seemed broken/not found :    If I un-pin the program from the taskbar, the icon shows as usual :    But if I re-pin it (or even simply right-click on it), the icon is broken again.  The program itself doesn't bug for the moment, but I wonder why this happens, and how I could fix this.  EDIT : My question has been marked as a possible duplicate (see comments), but the fixes provided to the other thread don't work for me, which is why I need other methods of fixing this.  UPDATE : After magicandre's and user1167442's answers, the icon now looks like this :    UPDATE 2 : When I right-click on the pinned Skype "icon", then right-click again on the program's name to see its properties (see screenshot) ; when I click on "Change icon", a dialog box says      File not found : %SystemRoot%\Installer{6A0549A9-...-B19}\SkypeIcon.exe.     I also noticed the link's target is joined with the /secondary argument, which is still there even when I erase it and apply.


I have a simple armature that has three loose bones that I would like to join at one joint. Is there a way I can join these 3 into a single joint?


Windows 7 PID consumes 50% CPU almost everyday for hours

I'm trying to determine why these services consume 50% of my CPU for hours at a time each day.  I cannot restart the services without error and killing the PID just restarts it in a few minutes and it's back to chewing through CPU.  Using process explorer these are the DLL's that run under the PID in question.  Windows 7 I take MS updates about once a month.  Any ideas?


Why do we only look at the sample from MCMC? (And ignore the sample points' posterior probabilities?)

I'm new to MCMC, so this might be obvious.  Let's say we're using MCMC to estimate a posterior distribution. We run MCMC, and it returns a representative sample from that posterior distribution.  The sample is just a collection of data points. To actually use it, we just plot a (normalized) histogram of those data points to draw our estimated posterior.   However, we also know the posterior probability of each data point in the sample! This is even explicitly calculated in the Metropolis MCMC algorithm. Why do we ignore this?     Edit: Here's .


Answered questions appear as unanswered on feed

I've noticed this a few times on the Feed activity on the Android app, but never thought anything of it.  Why does this question (How To auto enable checkbox?) appear as "Unanswered" when there is an icon which denotes there are 5 answers, one of which has been marked as the answer?  Dragging down to refresh doesn't seem to clear the unanswered flag either.  Device: Nexus 5


I currently have the following template for a cheatsheet:  \documentclass[10pt]{article}  \usepackage{amsmath,subfigure,color,verbatim} \pagestyle{empty}  \usepackage{multicol} \usepackage{savetrees}  % Begin the actual document content here. \begin{document} \begin{tiny} \begin{multicols}{3}  \section*{Section I} This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. This is section I. \begin{align}     x^2 + y^2 = 2 \end{align}   \end{multicols} \end{tiny} \end{document}   which results in the following:   The content spreads itself out over the three columns, but I want it to fill up one column before going to the next. How can I do that?


please could you help with the regex to get everything unto the ";"..  window.egfunc = {   name: "test name",   type: "test type",   storeId: "12345" };   I have the following which works when all the data would be on one line, but as soon as there are returns, it won't work...  window.egfunc\s+=\s+(.*);


identify classes referencing unnecessary interfaces

I have inherited an application in which a "God" (hundreds of methods) interface is used as a base class/interface for many other interfaces.  These interfaces are then implemented in many classes.  A lot of the classes that implement these interfaces don't use any of the methods in the base interface.  Is there a plugin or some tool that can identify if these classes are using none of the base interface methods so I can then remove the base interface implementation from the child interfaces?


I have the following codes:  class Solution:     def three_sum(self, nums: List[int]) -> List[List[int]]:         nums.sort()         output_set: set = set() #Notice          if len(nums) < 3:             return []          for i in range(len(nums)-2): #at least 2 element left             sub_nums = nums[i+1:]             sub_target = 0 - nums[i]             logging.warning(f"sub_target: {sub_target}")              two_sum_output = self.two_sum(sub_nums, sub_target)             logging.warning(f"two_sum_output: {two_sum_output}")             if two_sum_output != None:                 temp = { (nums[i],) + tuple(l) for l in two_sum_output }                 output_set.update(temp)         output = [ list(t) for t in output_set] #conver to list         logging.warning(f"final output count: {len(output)}:\n {output}")          return output    I want to delete lines with logging,   grep could them   $ grep "logging" twoSum.py  import logging # logging.disable(level=CRITICAL) logging.basicConfig(level=logging.debug,  logging.info(f"Start of twoSum Process {os.getpid()}") # logging.debug(f"{ps.stdout.decode('utf-8')}")             logging.info(f'find: {find} ')             logging.info(f"j: {j}")   How could delete them?


One screen on two displayed and wrong resolution

I have recently installed ubuntu in dual boot with windows 10 and everything was working, until I switched on the computer and ubuntu was 1024x768 instead of 1920x1080 and only one monitor was connected. How can I fix this?


Efficiently searching geolocations - LAT/LNG and DECIMALs

I have a database with > 7.5 million rows (and growing), each with an image record that has a specific LAT/LNG geolocation representing where the photo was taken, stored as DECIMAL values -    mysql> describe image_meta;  +---------------------+------------------+------+-----+-------------------+----------------+  | Field               | Type             | Null | Key | Default           | Extra          |  +---------------------+------------------+------+-----+-------------------+----------------+  | id                  | int(11) unsigned | NO   | PRI | NULL              | auto_increment |  | media_id            | varchar(255)     | YES  | UNI | NULL              |                |  | user_id             | int(11) unsigned | YES  | MUL | NULL              |                |  | create_time_unix    | int(11) unsigned | YES  | MUL | NULL              |                |  | create_time_zulu    | datetime         | YES  |     | NULL              |                |  | latitude            | decimal(12,10)   | YES  | MUL | NULL              |                |  | longitude           | decimal(13,10)   | YES  | MUL | NULL              |                |   I want to search within a rectangular area, defined by LAT/LNG, and the queries are very slow.    I am using this query:   SELECT user_id FROM image_meta WHERE (latitude BETWEEN 40.779769 AND 40.792399 AND longitude BETWEEN -73.988457 AND -73.963308);   with the result:  123569 rows in set (8 min 28.99 sec)   What's the best way to go about making this go faster? Should I search a broader area with fewer significant figures, then use PHP to narrow the results by the more precise LAT/LNG boundaries?  I'm a novice SQL guy (always had DBAs to help me in the past) but I'm doing this project solo. Thanks in advance...


Gauge symmetries and elementary particles

The  (disclaimer: I don't know this wikipedia entry) is usually mentioned as the reason why gravitons may not be composite particles. I do understand the proof of the theorem, but not the previous conclusion.   The theorem states that in an interacting and Poincare invariant quantum field theory, there are not massless, spin-2 particles unless there exists a gauge symmetry — which makes the energy-momentum tensor non-covariant (actually covariant up to a gauge transformation) under Lorentz transformations in the Fock space. So the immediate conclusion of the theorem is that the existence of a massless, spin-2 particle (like a graviton) requires linearized diffeomorphisms.  My question is: why do linearized diffeomorphisms imply that gravitons are elementary particles? Or, more in general, why  the particle corresponding to a gauge field must be elementary (I know that a gauge symmetry must be exact, but why this implies that the corresponding particle must be elementary?).


What is the significance of logistic regression coefficients?

I am currently reading a  concerning voting location and voting preference in the 2000 and 2004 election. In it, there is a chart which displays logistic regression coefficients.  From courses years back and a little , I understand logistic regression to be a way of describing the relationship between multiple independent variables and a binary response variable. What I'm confused about is, given the table below, because the South has a logistic regression coefficient of .903, does that mean that 90.3% of Southerners vote republican? Because of the logistical nature of the metric, that this direct correlation does not exist. Instead, I assume that you can only say that the south, with .903, votes Republican more than the Mountains/plains, with the regression of .506.  Given the latter to be the case, how do I know what is significant and what is not and is it possible to extrapolate a percentage of republican votes given this logistic regression coefficient.  As a side note, please edit my post if anything is stated incorrectly


Is it a good idea to redirect http://www.example.com to http://example.com or keep both?

Is it a good idea to redirect http://www.example.com to http://example.com or keep both ?


$$\lim_{h\to 0}\frac{\sin(x+h)-\sin(x)}{h}$$ Using the fact that: $$\lim_{x\to 0}\frac{\sin(x)}{x}=1.$$  Thank you in advance for any help.


Let $D$ be an integral domain and let $a^m=b^m$ and $a^n=b^n$ where $m$ and $n$ are relatively prime integers, $a,b \in D$.   How do I show $a=b$?


Why does using a for loop change the output for this dictionary class?

I am essentially creating my own Dictionary class where it works as a stack. I can put key-value pairs (another class i created myself) into my dictionary which holds them in an array. When I manually put the key-value pairs by righting each call to put() line by line it works fine. But when i use a for loop it does not work properly. If i check to see if a key is in my dictionary it returns false with the dictionary created with the for loop and true with the other one.  Both dictionaries print the exact same thing with the method i created. But the dictionary created with the for loop does not gives correct outputs when methods are used.  here is the code for the main :    Does anyone know why the two dictionaries are different?  Edit : my code for put() is as follows  public class Dictionary implements Map<String, Integer> {      private final static int INITIAL_CAPACITY = 10;     private final static int INCREMENT = 5;     private int count;      Pair[] elems;      public int getCount() {       return count;     }      public int getCapacity() {       return elems.length;     }      public Dictionary() {         elems = new Pair[INITIAL_CAPACITY];         count = 0;     }      @Override     public void put(String key, Integer value) {         Pair elem = new Pair(key, value);         elems[count] = elem;         count++;          if (count == elems.length) {           increaseCapacity();         }      }      private void increaseCapacity() {       Pair[] newElems = new Pair[count + INCREMENT];       for (int i = 0; i < count; i++) {         newElems[i] = elems[i];       }       elems = newElems;     }      @Override     public boolean contains(String key) {         for (int i = 0; i < count; i++) {           if (elems[i].getKey() == key) {             return true;           }         }         return false;     }      @Override     public Integer get(String key) {       boolean got = false;       Integer value = 0;          for (int i = count - 1; i > - 1; i--) {           if (elems[i].getKey() == key && !got) {             value = elems[i].getValue();             got = true;           }         }          return value;      }      @Override     public void replace(String key, Integer value) {       Pair newPair;       for (int i = count - 1; i > - 1; i--) {         if (elems[i].getKey() == key) {           newPair = new Pair(key, value);           elems[i] = newPair;         }       }     }      @Override     public Integer remove(String key) {       Integer saved = null;       boolean removed = false;       for (int i = count - 1; i > - 1; i--) {         if (elems[i].getKey() == key && !removed) {           removed = true;           saved = elems[i].getValue();           elems[i] = null;         }       }        return saved;     }      @Override     public String toString() {       String res;       res = "Dictionary: {elems = [";       for (int i = count-1; i >= 0 ; i--) {           res += elems[i];           if (i > 0) {               res += ", ";           }       }       return res +"]}";     }  }   Pair is another class I have created that just represents a key-value pair.


Best way to start investing, for a young person just starting their career in Europe?

I'm in my 20's and just starting my career as a data scientist. I live between the United Kingdom and the rest of Europe. I have read the answers to  but it seems to be very US-centered.   Generally speaking (could apply to most Europeans):   I don't have to worry too much about the pension scheme as it seems that  So I don't even know what a 401k is. However the UK is not my home country, so I don't know that would work out when I will decide to go back home to Europe. I have no student debt because education is free, as is healthcare. I don't intend to move out of Europe.   Personally speaking:   I earn £3750 a month, I pay 850 bills not included in my accommodation. I pay £400/500 a month for travel (between my workplace in the UK and my home on the Continent). So far I have just try to diversify the income I receive in three currencies to reduce the volatility, I don't even know if it is the wises option.   My goal is not to worry about money now and forever. (a subgoal is to have enough money if someday I decide to try to live for my artistic activities). I am risk-friendly.


Using the F word in the middle of the word

Not sure if I can use the F words here, therefore I will refer to it as f*** or f***in  I know that we can use F word in the middle of the sentence  like     You may f***in not do that   or      She is f***in hot.   I am not sure where I heard this but I recall someone was using it in the middle of the word such as     abso-f***in-lutely = absolutely   or     ex-f***in-cuse me = excuse me   I know it is not alright to use this kind of language in home or work or any other place, yet many people use it. So is this right way to use the F word in the middle of the word or it is wrong


My Macbook Pro often hangs up at shutdown - what should I do?

My system:    System Version: macOS 10.13.6 (17G5019)   Kernel Version: Darwin 17.7.0   Boot Volume: Macintosh HD   Boot Mode: Normal   Model Name: MacBook Pro   Model Identifier: MacBookPro14,3   Processor Name: Intel Core i7   Processor Speed: 2.9 GHz   Number of Processors: 1   Total Number of Cores: 4   L2 Cache (per Core): 256 KB   L3 Cache: 8 MB   Memory: 16 GB   Boot ROM Version: 185.0.0.0.0   SMC Version (system): 2.45f0   With alarmingly increasing frequency, when I shutdown my Mac at the end of the work day, it hangs. This means that I have to stop it by keeping the Touch ID button pressed - with the result that when I turn my Mac on again, OSX complains about the forced shutdown. I'm worried this may compromise the stability of my system, and maybe even the life of my Mac.   This is a company machine, so probably the best thing to do would be to log a case for IT and wait for them to solve the issue. However, I'm on a long business trip and I likely won't be able to give them my laptop before the end of the month. Is there anything I can do on my side, to reduce the risk of instabilities/life reduction?


Choose $\rho$ such that $\rho$-norm minimizes the matrix condition number

I'm solving questions from am exam that I failed miserably, so I would love it if someone can take a look at my proof and make sure I'm not making any gross mistakes.  Question  Let $A$ a symmetric matrix. Which $\rho$-norm minimizes $A$'s condition number: $\kappa(A,\rho)$?  Edit  Well, my solution was clearly wrong. I would love any suggestion or direction for solution you might have.  Thanks! :)


What is the Quickest method for determining which postcode is 2 miles north of original postcode?   For instant L17.  I know how to determine the distance between 2 points as below, but the above formulae eludes me.  Code:      public static final double PI = 3.14159265;     public static final double deg2radians = PI/180.0;      double lat1 = latitude1  * deg2radians;     double lat2 = latitude2  * deg2radians;     double lon1 = longitude1 * deg2radians;     double lon2 = longitude2 * deg2radians;      radd=2*Math.asin(Math.sqrt(Math.pow(Math.sin((lat1-lat2)/2),2.0) +                   Math.cos(lat1)*Math.cos(lat2)*Math.pow(Math.sin((lon1-lon2)/2) ,2.0)));


Is it possible to legally visit uninhabited islands in the Pacific for a couple of days/weeks like Robinson Crusoe

Do you know any way how can I visit uninhabited islands in the Pacific (French Polynesia, Micronesia etc.) and stay there for a couple of days or weeks?  The only condition, these island (or islands) should have drinking water.  Could it be done legally or only illegally?  Does any company do such crazy things via plane or boat?  Any information is appreciated.  I am mostly interested in French Polynesia.  Boat or plane... that's not very important.


SQL Server 2008 server cannot connect to itself with alias name or “localhost”

We have a SQL Server 2008 ENT 64bit SP3 server running Server 2008 R2 Standard SP1 64-bit. This is also a windows/sql clustered environment. There is the cluster alias for the server, and then we have 2 AD DNS aliases as well for the server  Suddenly I can't connect to the sql instance in Management Studio, or with a Powershell Invoke-SQLcmd IF I am doing it from that actual server, when using one of the dns alias names, or "localhost". If I use the Cluster alias name it works and if I use the other dns alias name it works.  Using management studio with the non-working dns alias I get "Login failed. The login is from an untrusted domain and cannot be used with Windows authentication."  If I use localhost, I get "A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server) (Microsoft SQL Server, Error: 2)"   Shared Memory and TCPIP are enabled in SQL Server Config manager but named pipes is not. But we've NEVER had named pipes enabled, and don't have it enabled on any of our other sql servers and they're set up the same (clustering, dns aliases...etc) and are having no issues.  I've Googled around and had a view people suggest listing what other SQL servers it can see (cmd prompt sqlcmd -L) If it do it from a good server I see all other servers on my network including the "bad" one. If I do that command from the "bad" server, I get no results at all.  Pretty much checked everything from this blog and it's all ok except the sqlcmd -L issue I just mentioned above.    Windows firewall is not enabled.  This was working just fine for a couple of years. I'm not sure when this started happening, but I know that at some point, it was not happening.  And the other kicker...it's only happening locally to this server. If I connect with management studio or run a powershell Invoke-Sqlcmd from another machine, or my local machine connecting to the "bad" server, it works fine no matter what alias I use.  I'm stumped. I think it sounds like an issue with the AD alias (there are 2 ad aliases, 1 works locally the other doesn't)...but not being able to connect with localhost makes me question that.  any help is greatly appreciated.


BrE. Why do these expressions little/very little; few/very few exist if they are the same?

I can’t understand these words. “ he has got little money” and “ he has got VERY LITTLE money”; “ I have got few friends” and “I have got VERY FEW friends”.


Why does a class method equal itself, but isn't itself?  >>> class Test: ...     def test(self): pass ... >>> t = Test() >>> t.test == t.test True >>> t.test is t.test False


Give me some hints in calculation this limit.


Finding the minimal $n$ such that a given finite group $G$ is a subgroup of $S_n$

It is a theorem that, for every finite group $G$, there exists an $n$ such that $G \leq  S_n$. Given a particular group, is there any way to determine or bound the smallest $n$ such that this occurs? The representation of the group is up to you, though bounds that use less information are preferred.  If this problem is too hard, specific special cases are also interesting, as are bounds on $n$.


Variance of a linear combination of vectors

Let $A$ and $B$ be two constant matrices and let $x$ and $ y$ be two random vectors, what is the general formula for $Var(Ax+By)$? I know the formula for when $x$ and $y$ are scalar random variables and $A$ and $B$ are constants, but what about the matrix case?


How do I play Pokemon Go without a celluar connection or Wifi?

I would like to play Pokemon Go, but my phone does not have mobile data. My friends appear to be able to play Pokemon Go without SIM card or personal hotspot. When I asked them, they have claimed they're using a beta version that does not need Wifi. I have read  but it does not help. Can I play Pokemon GO without a mobile data connection or wifi internet?


I've been trying to solve this problem for hours now.  I successfully installed Drush locally and it works fine when I'm using it within XAMPP's htdocs folder. However, I want to move the Drupal folder to a virtual host outside htdocs. When I run drush inside the new folder, it says:  $ drush status  PHP Warning:  pcntl_exec(): Error has occurred: (errno 13) Permission denied in phar:///usr/local/bin/drush/includes/startup.inc on line 359  Warning: pcntl_exec(): Error has occurred: (errno 13) Permission denied in phar:///usr/local/bin/drush/includes/startup.inc on line 359 Error has occurred executing the Drush script found at /Users/ivan/drush (errno 13) Permission denied   Tried to change folder owner to admin group, chmod -R 777 - nothing worked. I am running on OS X 10.11.6 and XAMPP 5.6.12.  Thank you for any help.


Sci-Fi book where aliens are sending sub-light bombs to destroy planets, protagonist has imprinted memories and behaviours

I read it in the 80's.  Cover had a person in a spacesuit standing in a river of lava.  On the shore was some sort of alien critter(s).  Think perhaps this was inside a cave? Premise of the book was a group of people were decimating planets for some unknown reason.  Main character (?Bron?) was "imprinted" with the memories/behaviors of a person the "ravengers" would want to abduct.  Main character was in contact with remote "handlers" who could communicate with him and assist via implants.  One of the controllers was a woman called or nicknamed JC. Ended up that aliens in the far distant past were sending sub-light "bombs" to destroy the planets which took eons to finally show up and deliver their payload. There was also some sort of prognosticating going on -- the main character was imprinted with the memory of one of the main teacher/leader/something of this technology. Final explanation is that the aliens foresaw that humans would one day visit their planet, and in a fit of xenophobia decided to try to destroy the humans.  Main character figured this out and then backtracked to the aliens home world.  When humans showed up, the race had degenerated back into savagery.


Open sets and holomorphic functions in Complex analysis

Let $U \subset \mathbb{C}$ be an open set such that {$ z\in\mathbb{C};|z|\leq2$}$ \subset U$ and $f:U\rightarrow\mathbb{C}$ a holomorphic function.   Show that there exists infinitely many natural numbers $n \in \mathbb{N}$ such that $f(\frac{1}{n})\neq(\frac{1}{n+1})$  So i have been told to start by comparing with the function $g(z)=(\frac{z}{z+1})$  however i am still not getting very far with this. Would i have to prove by a contradiction?   Completely stuck and unsure, some help would be fantastic, many thanks!


Computing $ \int_0^{\infty} \frac{ \sqrt [3] {x+1}-\sqrt [3] {x}}{\sqrt{x}} \mathrm dx$

I would like to show that  $$ \int_0^{\infty} \frac{ \sqrt [3] {x+1}-\sqrt [3] {x}}{\sqrt{x}} \mathrm dx = \frac{2\sqrt{\pi} \Gamma(\frac{1}{6})}{5 \Gamma(\frac{2}{3})}$$  thanks to the beta function which I am not used to handling...  $$\frac{2\sqrt{\pi} \Gamma(\frac{1}{6})}{5 \Gamma(\frac{2}{3})}=\frac{2}{5}B(1/2,1/6)=\frac{2}{5} \int_0^{\infty} \frac{ \mathrm dt}{\sqrt{t}(1+t)^{2/3}}$$  ...?


Knowing pre-encryption data, can we find the private key CryptoWall used?

I'm just repurposing  for CryptoWall:     "If we know exact contents of some of the files prior to them being encrypted, would it be feasible to use those files to discover the private key?"   There's an answer posted for the case of CryptoLocker, but what about for CryptoWall?  I've read it is not as thorough, for instance not using the type of RSA encryption meant for large blocks of data.


Difference between I have lived or I have been living?

1) I have lived here since 2006  2) I have been living here since 2006.   What's the difference between the above cases? Are there different conditions to use each one of them? Or can they be used interchangeably?  I have already read this answer but what I want is simple answer and explanation that whether I have lived here since 2006 mean I am not living here now or I am still living.No doubt this answer is well explained but I am unable to understand it completely that's why I said earlier that I want easy explanation. Hope you get my problem now.


Biblatex: How do I truncate in-text author-list after first appearance?

I am using biblatex with citestyle=authoryear and maxnames=5, along with \parentcite in the text. For papers with 3-5 authors, I would like them to appear with the full list the first time they are cited (as it does now), and with et al. the following times.  Example:  First appearance:  (Author 1, Author 2, Author 3 and Author 4, 2018)   Second appearance:  (Author 1 et al., 2018)   In , this seems to be done with the longnamesfirst command, but I haven't found a way to do this biblatex.


I would like to write    \overline{Y}_n   in order to display the mean of Y. This yields:    However when I do this there is a gap between the Y and the n. Using  \bar{Y}_n   yields:    This avoids the gap however in that case the bar above the Y is not long enough for my liking.  I have seen that there exists a question  but that question asks about subscript added to the bar symbol, not subscript added to the symbol(s) which are under the bar.  I'm also aware of this question:  but that question is about what you should or shouldn't do; not a method to solve this problem.  Thanks in Advance!  EDIT: I realize that this question is very similar to this one: , however the answer given below is better than the ones to that question.


Can't kill frozen Visual Studio code on mac

Somehow My visual studio code froze  when  It was idle for some time and I was using my Injellij application.  When I found, I tried quitting the application by doing right +click on visual studio code icon and quit- nothing happened. Then I tried force quit -still nothing happened. opened activity monitor-saw electron(not responding)- tried quit and force quit- still nothing. then tried everything from this post  - still nothing.  Also in taskbar, the vscode icon is not present but if I try to relaunch, I get an error message saying  "Another instance of Code is running but not responding Please close all other instances and try again." I am not sure what actually happened but if someone can help me to trace this and fix without restarting my system . I would also be happy if someone can help me find error logs for vscode or macos to investigate what actually happened. below are app and system information. visual studio code package name: VSCode-darwin-universal.zip version : 1.57.1 system mac Os catalina version 10.15.7


I really like the Geany text editor, and would like to use it instead of gedit for all text editing.  However, every time I try to launch Geany from the terminal using sudo geany file.conf, I get this error:  (geany:10203): Geany-WARNING **: Geany tried to access the Unix Domain socket of another instance running as another user. This is a fatal error and Geany will now quit.  I am the only user logged in to the machine.  There are no instances of Geany already running when I type that command into the terminal.  Geany has no trouble launching from the command line if I don't use a sudo.  I also don't have any trouble running Gedit with elevated privileges; the command sudo gedit file.conf functions flawlessly. What is going on here?  How can I fix this so that I can edit text files in Geany with elevated privileges?


Recommend guide book of algebraic geometry

I have a little knowledge about geometry and algebraic topology . I want to learn some basic conception and thought of algebraic geometry. Besides , I want to know main of theory of sheaves. What book I should read ?


difference between put the fire out and put out the fire

what is the difference between these two? put out the fire and put the fire out what are the use cases? do they mean the same or not? another example is take off take it off or take off it => here it seems the first one is correct


How can I run a simple rsync shell script at boot with root?

I have  a shell script that contains a single rsync command to rsync two local directories. I want the script to run at startup/during boot and I can't seem to find the solution for this problem.   The file is marked as executable. I tried adding it to init.d and symlinking to rc2.d as I have seen suggested elsewhere. I tried running the script as a startup application from Gnome, and I've tried adding it to rc.local. None of these options seem to start the rsync command.   How can I achieve my goal of starting this rsync command at startup or during boot with root?


How can I create a DC-DC voltage multiplier

I want to take the 5V output from a USB port and make it 12V, so that I can run a cooling fan which is 12V. Is there any circuit I can make at home myself? If the output voltage is not exactly 12V, it can be at least 11V so the fan can run smoothly.


I am a total novice when it comes to hardware settings.  I am using Windows Server 2012 64 Bit.  It has 12GB RAM. I have a C and virtual D drive.  The build is i5-2400 3.10 GHz.  There is no current settiugs for virtual memory.  What is the rule of thumb please?


how using GPU from c# code to compress bitmap

I want to compress bitmap that i getting from some source ( compress bitmap to image in jpeg or png format or compress group of images to clip )   I want to try to do it by using the GPU to have better performance.   I know that Intel and Nvidia have some dll that expose those abilities.   How to do it ? Does using those library will have better performance than using simple C# GDI+ ?


Maximum Likelihood Estimate with different parameters

Suppose that X and Y are independent Poisson distributed values with means $\theta$ and $2\theta$, respectively. Consider the combined estimator of $\theta$ $$ \tilde{\theta} = k_1 X + k_2 Y $$ where $k_1$ and $k_2$ are arbitrary constants.   Find the condition on $k_1$ and $k_2$ such that $\tilde{\theta}$ is an unbiased estimator of $\theta$. For $\tilde{\theta}$ unbiased, show that the variance of the estimator is minimized by taking $k_1 = 1/3$ and $k_2 = 1/3$. Given observations $x$ and $y$ find the maximum likelihood estimate of $\theta$ and hence show that $\tilde{\theta}$ is also the maximum likelihood estimator.   I have gotten (1) and (2) okay, but it's (3) I am having trouble with, I'd be okay if $X$ and $Y$ had the same parameter but I'm having trouble with $X$ and $Y$ having different parameters, any help would be appreciated.   NOTE   For (1) I got $k_1 = 1 - 2k_2$.   For (2) I found the variance of $\tilde{\theta}$, then differentiated and let equal to zero to minimize - therefore we get (after subbing in $k_2 = 1 - k_1/2 $) $$3k_1-1=0,$$ which when subbing in $1/3$, we see it is minimised.   Thank you.


How can I make a black 3d border around an object in BGE during gameplay?

I am trying to make a black border appear around a building in BGE (it is an RTS).  I don't know how this could be done (without drawing black around the textures and the textures on the building do not match that way) if anyone could help then that would be awesome! Thanks!


Showing that $\sin(x^2)$ is not uniformly continuous

Let $f(x)=\sin(x^2)$. Determine if $f$ is uniformly continuous.  I initially tried to determine the uniform continuity by checking if $f$ was Lipschitz. From MVT I got that $$|f(x)-f(y)| = |f'(c)||x-y|$$ and since $f'(x) = 2x\cos(x^2) \le 2x$ I have $$|f(x)-f(y)| \le 2x|x-y|$$ but the term $2x$ can blow up so this clearly isn't Lipschitz. How can I determine uniform continuity? Trying to bound $$|f(x)-f(y)| = |\sin(x^2)-\sin(y^2)| = \sin(x^2)+\sin(y^2) \le 2$$ but this doesn't seem to help.


I'm trying to boot an ISO containing a Linux live system from an existing NTFS partition on a PC. The PC has UEFI, and the hard disk is partitioned with GPT, so GRUB4DOS is not an option. Can this be done at all?  I know that the question has been asked before: , but there is no approved answers there - that's why I'm asking again. Also I would like to use my own kernel instead of some fixed and precompiled one.  From the other answers it seems like I would need to include some sort of customized kernel file (I assume place it to EFI partition), which is then capable of loading the rest of the ISO(?) from the NTFS itself.  This can be done on FAT partition already, by simply doing a GRUB entry  menuentry "Boot LINUX FROM ISO FILE" {   set iso_path=/path_to/image_on_FAT_filesystem.iso   loopback loop (hdX,msdosY)$iso_path   linux (loop)/path_to/vmlinuz nomagic base_only norootcopy from=$iso_path }   Edited to propose an answer, which was NOT posted to the other "duplicate" question.


finding the position of an element within a numpy array in python

I want to ask a question about finding the position of an element within an array in Python's numpy package.   I am using Jupyter Notebook for Python 3 and have the following code illustrated below:  concentration_list = array([172.95, 173.97, 208.95])   and I want to write a block of code that would be able to return the position of an element within the array.   For this purpose, I wanted to use 172.95 to demonstrate.   Initially, I attempted to use .index(), passing in 172.95 inside the parentheses but this did not work as numpy does not recognise the .index() method -  concentration_position = concentration_list.index(172.95)  AttributeError: 'numpy.ndarray' object has no attribute 'index'   The Sci.py documentation did not mention anything about such a method being available when I accessed the site.   Is there any function available (that I may not have discovered) to solve the problem?


Why is the word watch pronounced differently from words like patch, latch, match, catch, and batch?

Why doesn't watch rhyme with catch, batch, latch, patch, and match?


How does the planet Starkiller base in the Force Awakens remain day light once the weapon is charged?

How many suns are around Starkiller base in the Force Awakens? Is it just one? If its sucks the power out of one star from the back of the planet how is the front of the planet lit up like the sun is shinning on it when the Rebels attack it? If the weapon is charged shouldn't the plant be in the dark?


I've seen that in Kaggle competitions people are using lightgbms where they used to use xgboost. My question is: when would you rather use xgboost instead of lightgbm? What about catboost?


Could quark star becomes a neutron star?

Fusion of quarks release 8 times more energy than hydrogen fusion, so I was wondering if quark star exists and before quark degeneracy pressure kicks in wouldn't these tightly packed sea of quarks start fusing and eventually becoming a miniature neutron star?  I think in normal scenario due to the short range of strong force and quark/neutron cannot be found alone in nature compare to the condition of quark star where quarks should easily fused with each other and outshines almost everything in the night sky.


How to prove $\sum_{k=1}^n(2k)^2 = \frac{2n(n+1)(2n+1)}{3}$ using mathematical induction?

I need to prove $$\sum_{k=1}^n(2k)^2 = \frac{2n(n+1)(2n+1)}{3}$$ using mathematical induction. I tried solving this but I got stuck when proving that this is true for n=k+1.  I would be very thankful if someone could help me.


Is there a way to perform a 'reverse' of the clip function in ArcMap?  I am not exactly sure how to explain this so here is a diagram:


When I try to search on google.com (United States), it redirects me on google.ca (the local one for me).  I can access all google's sites in , except the one for United States.   Can someone explain why ? Is there a way to access google.com from Canada ?


How to install visual studio 2015 on Ubuntu 14.10

how can i install visual studio on Ubuntu and run it with having any crash? Tell me please because i want to move from windows operating system to Ubuntu. So help me to find a way for this.


How is Deleted Data Recoverable Even When Overwritten?

Would this make a file unrecoverable (Windows OS)?   Delete the file (i.e. send it to the recycling bin). Empty the recycling bin (i.e. remove the reference to where the data is stored in memory). Overwrite the memory with different data (assume you knew the blocks of memory used, and forced those to be used with new data).   I've read that only once overwritten several times the data is truly unrecoverable.  Is that true?  How could the data be recovered if the memory where it was store has something else stored in it?


How to make your own Linux distro based on Ubuntu?

I want to create an Linux distro based of Ubuntu 14.04 with a graphical user interface(GNOME) and cool terminal theme.


Need to check time execution on client side    var start = new Date().getSeconds(); // code... var end = new Date().getSeconds(); let time = end - start console.log(time);     Result: 0;  I suppose it's a part of second, for example 0.05. How can I get it?


How downgrade macOS to previous versions safely?

I working on macOS Mojave 10.14.5  I am new to macOS and I don't know much about installing different versions. I can't dare to uninstall the current as I am afraid to lose my file and installed packages.   how can I safely downgrade to 10.11 or 10.10?  Updates: info about my MacBook:   MacBook Pro (Retina, 13-inch, Late 2013)  The reason why I want this is that I want to install wifi USB adapter but it seems that it's only compatible with os 10.11 or below that. Having this wireless adapter working is so much important to me though.   Adapter details:  EDUP 802.11n USB Wireless  Model : EP-N8553


How can a skull/head works as an 'amplifying' antenna?

When you hold your remote control to your head it seems that the reach of that remote control is longer. But how does precise work.  It is only working with radiowaves, not infrared. But how can a head or skull make the signal better. Are those radiowaves going in your head and than reflect to give a parabola to focus more. If so, why are those waves not going (bend) around your head as the wavelength would be large.   Or does your head support in a totaly other way?  In a similar question, there are mainly two ways of explaining this. First our head function as a resonance chamber and second there is magnetically coupling from our head/body with the remote control antenna. But if our head is a resonance chamber how can this work? As the radiowaves has to go inside our head and then going out with larger reach. I don't understand how em-waves can get larger reach to use a resonance chamber.  And what is exactly meant with magnetically coupling is that the same as the resonance coupling?


Can we use Moto G2 with google Cardboard

Can I use Moto G2 with Google Cardboard. I just want to experience Virtual reality in a cheapest way possible. I've a Moto G2, So I was wondering If I can use Moto G2 with Google Cardbaord. If anybody has used it then please suggest me, What kind of stuff I would be able to see and what I won't be able to.


Does the spouse of British national with UK permanent residence need a Schengen visa to travel to France?

My wife is an Indian national with an Indian passport. She holds an indefinite leave to remain in the UK (permanent residence card). Does she need to apply for a Schengen visa before travelling to France or any other Schengen countries?


I need to show that $f:[0,1] \rightarrow \mathbb{R}$ is Riemann integrable on $[0,1]$ if for all $x \in [0,1]$, $\lim\limits_{t \rightarrow x} f(t)$ exists.  I need to show first $f$ is bounded. Using the compactness of $[0,1]$, I tried using a finite subcover of $[0,1]$ generated from the definition of the limit existing. Now to show that $U(P,f) - L(P,f) < \varepsilon$, I have no idea how to start that part of the proof. Any help is welcome, although help with an elementary approach is preferred since chapter 6 of baby Rudin is mostly what I can work with.


Is there a word that describes a person who dies on his/her birthdate?

I have found references to birthdays and "deathdays," many words that reference either death or birth (natalis, obitus, quietus) but not both sharing the same day and month (even sharing the same year in the case of some children).


Can "This edit will be visible only to you until it is peer reviewed" link you to the review page?

When I make an edit and then get the text "This edit will be visible only to you until it is peer reviewed" am I just supposed to guess the URL for the peer review page? Can't you just link me there direct from the question? Am I missing something?


How to prevent someone from powering off an android device?

I have a Nexus 5. Even if I enable security passcode or pattern, someone can still switch off my mobile using the power button. How can I prevent it?


Hartshorne Problem 1.2.14 on Segre Embedding

This is a problem in Hartshorne concerning showing that the image of $\Bbb{P}^n \times \Bbb{P}^m$ under the Segre embedding $\psi$ is actually irreducible. Now I have shown with some effort that $\psi(\Bbb{P}^n \times \Bbb{P}^m)$ is actually equal to $V(\mathfrak{a})$ where $\mathfrak{a}$ is the ideal generated  by the set of all monomials   $$\Big\{z_{ij}z_{kl} - z_{il}z_{kj} \hspace{1mm} \Big| \hspace{1mm} i,k = 0,\ldots, n; \hspace{2mm} j,l = 0,\ldots,m\Big\}.$$          My main problem now is in showing that $\mathfrak{a}$ is actually equal to the kernel of the ring homomorphism $$\varphi : k[z_{ij}] \to k[x_0,\ldots,x_n,y_0,\ldots,y_m]$$     that sends $z_{ij}$ to $x_iy_j$.      I have spent quite a few hours playing around with monomial orderings and trying to show that $\mathfrak{a} \supseteq \ker \varphi$ but to no avail. Of course the other inclusion is immediate.   Is there anything I can do apart from playing around with monomial orderings to try and show that the kernel of $\varphi$ is equal to $\mathfrak{a}$? Perhaps maybe something along the lines of inducting on $n$, those this does not look promising.  Note: Please do not close this question; my question is different from the other questions on this site concerning the Segre embedding. Also, I can show my work concerning how I arrived at the conclusion that $V(\mathfrak{a}) = \psi(\Bbb{P}^n \times \Bbb{P}^n)$.


Can Anyone Tell me the Time Complexity of these scenario?

This Code in C Language and I wanna know the time complexity of these two scenarios? a.)     for(i=1; i<=n; i++)        for(j=i; i<=n; j++)           printf("Hi");  b.)     for(i=1; i<=n; i*=3)         for(j=1; i<=n; j++)            printf("Hello");


I am making a basic word scrambling and guessing game. To make sure the same word doesn't appear again (example words used) I need to delete the selected word. I have looked all over for solutions however none have worked. Any help is appreciated! //word bank   string[] wordBank = {   "iphone", "airpods", "laptop","computer","calculator","ram","graphics", "cable","internet","world wide web"   };    //select random word   Random wordRand = new Random();   int index = wordRand.Next(wordBank.Length);   string wordSelect = wordBank[index];                //delete word so can't be used again


How to add ubuntu to windows 10 boot manager, but it will be in another hard drive?

I want it to be look like this:    I have an HDD and an SSD in my PC, I want to install Ubuntu to SSD, I have windows on HDD. I want to be able to boot ubuntu from the windows 10 uefi boot manager. How do I do it?


How can the damage reduction from Armor in League of Legends not have diminishing returns?

The formula for calculating damage reduction from armor in League of Legends is  Damage Reduction = Total Armor / (100 + Total Armor)   It seems clear to me that this formula dictates that adding more armor has diminishing returns.  For example, let's say my champion has 50 armor, which gives damage reduction of 33.33% and I buy an item that gives 25 more armor; then my champion's total armor would be 75 and damage reduction would be 42.86%.  That means I saw a 28.6% increase in damage reduction (damage reduction was increased by 9.53%).  Now let's say I buy another of these items with 25 armor.  Now my champion's armor will be at 100 which gives damage reduction of 50%.  That means I saw a 16.66% increase in damage reduction (damage reduction was increased by 7.14%).  Therefore, from the first 25 armor item I bought got me 9.53% damage reduction, while the second time I bought the item it only got me 7.14% damage reduction.  It looks to me like it was 25.08% less effective the second time I bought it.  That screams diminishing returns to me.  Why would someone say otherwise? Would they say anything different about Magic Resistance?  Note:  This question was inspired by a comment thread which started off of this question: .  I have heard similar insinuations made before, though, implying that magic resist and armor are somehow different in the department of diminishing returns (although I am not sure if that was implied in the comments on the related question).


What does the type parameter  in the method definition mean?

public class GenericMethods {     public <T> void f(T x) {         System.out.println(x.getClass().getName());     }     public static void main(String[] args) {         GenericMethods gm = new GenericMethods();         gm.f("");         gm.f(1);         gm.f(1.0);         gm.f(1.0F);         gm.f('c');         gm.f(gm);     } } /* Output:   java.lang.String   java.lang.Integer   java.lang.Double   java.lang.Float   java.lang.Character   GenericMethods  */   What does public <T> void f(T x)  mean? Is it a return type? But the function doesn't actually return anything. What does it refer to? I couldn't place it under any of the general function header categories : like acces-specifier, return-type,etc.


Across the Stack Exchange network you may leave comments on a question or answer.  How do comments work? What are comments for, and when shouldn't I comment? Who can post comments? Who can edit comments? How can I format and link in comments? My comment doesn't contain some of the text I typed in it; why? My comment appears to be long enough, but I can't post it because it's too short; why? Who can delete comments? When should comments be deleted? Why can't I comment on specific posts even if I have enough reputation to comment? When can comments be undeleted? What are automatic comments? How can I link to comments? Anything else I should know about comments?  Also see the FAQ articles on  and .


Cast DateTIme without affecting timezone in C#

Tried to cast the datatime object ,which is queried from database. Value is in UTC time. is it affect the local timezone when i tried to cast the object ? var daytime = (DateTime)reader["day"]; reader["day"] is a object and value is in UTC time. For accessing the value i changed it into DateTime. my intention is i want to convert this value to epoch time. var daytime = (DateTime)reader["day"]; long epochTicks = new DateTime(1970, 1, 1).Ticks; long unixTime = ((daytime.Ticks - epochTicks) / TimeSpan.TicksPerSecond);


I'm using Photoshop for designing websites and whenever I compare a photoshop design with the live browser preview the fonts appear to be rendered differently.    Basically any anti-aliasing method I choose in photoshop, the text always gives the impression of bold text. So I'm always forced to turn off antialiasing (for normal 12px/14px text).  Is there a method I can achieve the same kind of font rendering in Photoshop like the one that Windows uses with cleartype?  If not, are there any fonts out there that look better than Arial when anti-aliasing is off ?


Lebesgue Outer Measure is not Finitely Additive.

We know that Lebesgue Outer Measure is countably sub-additive. It is not even finitely additive. I am trying to find two sets of real numbers which are disjoint and yet $\mu ^*(A\cup B) = \mu^*(A) +\mu^*(B)$ doesn't hold.


Should you use "will like" or "would like" for a request/response in the present tense?

I ran into these sentences that got me thinking about would/will:  I will like to have your number. I would appreciate a text.  Is that grammatically incorrect or just impolite? I suppose the above could be construed as a question. I'm also curious if the same rule holds true if you are responding to a question where you are compelled to provide a response. For example, assume someone asks:  For your fruit, an apple or an orange?  Why do these sound like correct responses?  I will take an apple. I would like an apple.  At the same time, this sounds contrived?  I will like an apple.  Is there a rule behind this, or is it just convention?


Will I have to clear Customs, pick up my bag and recheck it when flying BFS-EWR-YVR?

Am flying into Newark EWR from Ireland en route to Vancouver, Canada, all on United.  Will I have to clear Customs, pick up my bag and recheck it?  Will I also have to change terminals?


One of My domain is not working on "Google-Chrome"

Since few days we are experiencing issue in one of a domain named "id-validation.us". Google is blocking this domain on browsing from google-chrome. We tried to rectify the issue and found that google blocking all hits which is being done to id-validation.us. We are using a wild card certificate on this domain and certificate is fine as it is working well on rest of the domain. We tried to remove the code from web server as well but result is still same.  Google is throwing below error once you browse the website from google-chrome. Currently, an index.html file is placed on this web-server for this domain but response is same.


Let $p$ be a prime, and $a$ and $b$ two integers, such that $p\not|$ $a$ and $p\not|$ $b$.   It can be possible that $p$ $|$ $ab$ ?


Simplifying composition of trigonometric functions

Sometimes when Integrating I end up with taking:   $$\sin \left(\tan ^{-1}\left(\frac{x}{2}\right)\right)$$, or other similar combinations however thats when I use the computer to extract:   $$\frac{x}{2 \sqrt{\frac{x^2}{4}+1}}$$  However, I want to find out how this is done and if there are any tricks I could use to evaluate similar expressions.


Is there an easy way to test if something is null, and if it isn't, do something with it?

So I've been working on my largest project yet, and I've found that a lot of my objects have fields that can be null. Because of this, I'm having to do something like this for every single instance:  if(box1 != null)      box1.draw();   This doesn't seem too bad, but when you have to do that like 8 times, it makes the code seem cluttered. I feel like there could be a simpler way to do this.


Is there a registry key or group policy to disable the "If you change a file name extension, the file might become unusable" warning in Windows?

In Windows, when you change a file extension, you get a warning     If you change a file name extension, the file might become unusable      Are you sure you want to change it?      Is there a registry key or group policy setting to disable this warning?  If you know of an authoritative reference indicating the warning can't be disabled, please link to it.  I change file extensions frequently and always have to confirm this dialog.


Make the MSE favicon grayscale (like all other meta icons are)

The new  for Meta Stack Exchange looks exactly the same as the one for the  site:        This can get a bit confusing, especially if you happen to have many tabs open from both sites.  It also looks a bit silly in the site switcher menu:  All the per-site metas (and MSO, even before the MSO/MSE split) have favicons that are grayscale versions of the main site icons.  Why not do the same for MSE? Conveniently, michaelb958 already wrote a nice  to do just that (and I  it to apply to the menu too), so you can easily see for yourself how it would look.  Or just see the screenshot below:  So here's my proposal: Let's make this gray icon the official MSE favicon.  Update: The meta.SE favicon has recently been changed to a simplified outline version of the SE logo:  I'm not sure how much I like the new logo (for one thing, it doesn't seem to match the dimensions of the main SE logo), but at least it's different, which was the main point of this request.


Show that the series $\sum\limits_{n=2}^{\infty} \frac {(n^3+1)^{1/3}-n}{\log n}$ converges

Show that the series $$\sum\limits_{n=2}^{\infty} \frac {(n^3+1)^{1/3}-n}{\log n}$$ converges.   I showed it using Abel's theorem and limit comparison test. Any other simpler method?


How does someone go about selling a game or making a royalties deal with Nintendo(or Pokemon Company)?

It seems like Niantic did just that. If someone were to create their own game(Pokemon, hypothetically), how would they, if at all possible, sell that game to Nintendo or at least make a royalties deal? Or any other game, for that matter?


Equivalent forms of Jensen's diamond principle

I try to prove that these four statements are equivalent:   $\Diamond$ There are $A_\alpha\subseteq \alpha\times\alpha$ for $\alpha<\omega_1$ s.t. for all $A\subset \omega_1\times\omega_1$, $\{\alpha<\omega_1:A\cap\alpha\times\alpha=A_\alpha\}$ is stationary. There are $f_\alpha:\alpha\to\alpha$ $\alpha<\omega_1$ s.t. for each $f:\omega_1\to\omega_1$, $\{\alpha:f\upharpoonright\alpha=f_\alpha\}$ is stationary. There are $f_\alpha:\alpha\to\alpha$ $\alpha<\omega_1$ s.t. for each $f:\omega_1\to\omega_1$, there is $\alpha>0$ such that $f\upharpoonright \alpha=f_\alpha$.   I prove that 1, 2 and 3 are equivalent and 3 implies 4, but I don't know how to prove the equivalence of 4 and 1. I try to prove that 4 implies 3 or $\lnot 2$ implies $\lnot 3$ however I have a struck. Thanks for any hints.


Let $(a_n)_{n=1}^{\infty}$ be a sequence, let $\; 0 < q < 1$ such that $\;\forall n \in \mathbb{N}$  $\;n>2$    $ \left | a_{n+1} -a_n \right | < q\left | a_{n} -a_{n-1}\right |$  prove that $(a_n)_{n=1}^{\infty}$ converges.  Well, I thought about proving it this way:  $ \left | a_{n+1} -a_n \right | < q*\left | a_{n} -a_{n-1}\right |<\left | a_{n} -a_{n-1}\right | $    therefore $ \left | a_{n+1} -a_n \right | <\left | a_{n} -a_{n-1}\right | \;$  for each $n>2$ and that obviously shows us that the sequence converges because the gaps between each $2$ indexes reduces as $n$ grows.  I have a feeling however that this is not a formal way of proving this, it seems too easy.


Split single string into character array using ONLY bash

I want to split 'hello' into h e l l o in an array using only bash, I could do it in sed with sed 's/./& /g' but I want to know how to split a string into an array in Bash when I do not know what the delimiter would be, or the delimiter is any single character.  I don't think I can use ${i// /} without some creativity because the delimiter is an unknown, and I don't think that expression accepts regex.  I tried using BASH_REMATCH with [[ string =~ ([a-z].).* ]] but it doesn't work as I expected.  What is the proper way to use only bash to accomplish a string.split() type of behavior?  The reason is that I am trying to write the rev utility in all bash:    while read data; do   word=($(echo $data|tr ' ' '_'|sed 's/./& /g'))   new=()   i=$((${#word[@]} - 1))   while [[ $i -ge 0 ]]; do     new+=(${word[$i]})     (( i-- ))   done   echo ${new[@]}|tr -d ' '|tr '_' ' '   done   But I used tr and sed, I want to know how to do the split properly and then I will fix it to be all bash.  Just for fun.


Javascript Regex - must starts with letters can only have one occurrence of special character

I am new to Regular Expressions and trying to create one for a specific requirement per below :    Must starts with letters a-Z or A-Z Can contain numbers 0-9 Can contain only allowed special characters i.e. @.-' Only one occurrence of above special characters is allowed i.e. test9@my.com or new-test10@me.com is valid but test5@new@com is invalid    I have tried below code but not able to fulfill all requirements -   var myregex = /^([a-zA-Z0-9@.\-'])*$/; if(!myregex.test(userIdVal)){     alert('invalid'); }   any help is appreciated.


Which tags are automatically added to per-site metas?

The four necessary tags (, , , ), plus the various moderator-only tags (, ,  et al), are presumably automatically included as tags on every per-site meta and not subject to the "automatic deletion of unused tags" algorithm.  I've noticed that other tags also seem to be given this special treatment. Some of the tags on meta.SFF have 0 questions to their name yet haven't disappeared, such as  and . I assume the same is true for often-used tags such as  and .  What's the complete list of tags which are automatic on per-site metas?


String concatenation showing unexpected behavior

Bellow is snippet of my code. I just want to know why if condition is not being executed even if variable "ans" has value 2020. private static void solve() throws Exception {              String str="20";         String str1="20";         String ans=str+str1;              if(ans=="2020")          System.out.println("matched");        else System.out.println("Not matched");          System.out.println(ans); }


A drone, or any lifting vehicle, enclosed in a container. Will it lift along with the container?

Consider a drone, or any lifting vehicle, enclosed in a container. Will it lift along with the container? Suppose I place a small drone in a large container of negligible weight and place them in space. Will drone move forward pushing container?   I know it doesn't work, but don't know the reason.


I tried to open a split pane to run another command but instead it displays the same in both panes and I can only interact with one of them. I thought it would split the view so I could use the two panes independently like two windows.  I have the Visor installed but I don't think it would interfere.  Terminal - version 2.1.1 Visor custom (84d1873) based on 1.5


How do neutrinos pass through the sun so quickly?

If it takes thousands of years for light to escape our sun then how can neutrinos generated in the very center of the sun reach earth in just 8 minutes? Why is their speed so great that they can easily escape the pull of the sun at near light speed?     Solar neutrinos originate from the nuclear fusion powering the Sun and other stars. The details of the operation of the Sun are explained by the Standard Solar Model. In short: when four protons fuse to become one helium nucleus, two of them have to convert into neutrons, and each such conversion releases one electron neutrino.   The Sun sends enormous numbers of neutrinos in all directions. Each second, about 65 billion ($6.5\times 10^{10}$) solar neutrinos pass through every square centimeter on the part of the Earth that faces the Sun.[8] Since neutrinos are insignificantly absorbed by the mass of the Earth, the surface area on the side of the Earth opposite the Sun receives about the same number of neutrinos as the side facing the Sun.   -


Eliminate desktop switching transition/delay

When switching desktops on Mac OS, there is always a fade in/out transition. This transition is quick, but still quite noticeable and annoying when one switches few times in a minute.  Is there a way how to make the switch insantaneous? (like in windows, gnome...) I've tried all the standard accessibility options, motion reducitons etc., to no avail.


Motivation for Gamma, exponential, & chi-squared distributions

I understand the binomial, geometric, Poisson, and normal distributions. However, I don't understand the usefulness or difference between the following: Gamma, exponential, and chi-squared. So far, it seems that certain populations just inherently have different properties and thus different distributions are used to deal with them. Given a new population how and why would one decide to use the Gamma, exponential, or chi-squared distributions? (I'm a beginner in statistics and am trying to wrap my head around the application of distributions)


Limit of Sum $\lim\limits_{n\to+\infty}n\sum\limits_{k=1}^{n}(n^2+k^2)^{-1}$

Problem: $$\lim_{n\to +\infty} n\left(\sum_{k=1}^{n}\frac{1}{n^2+k^2}\right)=$$ Source: AP Calculus BC  This looks like the definition of a definite integral to me, so I compared it to that equation. $$\int_a^b\!f(x)\,\mathrm{d}x=\lim_{n\to\infty}\sum_{k=1}^{n}f(x_i)\Delta x$$ where $\Delta x=\frac{b-a}{n}$.  However, I am now stuck because $\Delta x$ has $n$ in the denominator whereas the problem has $n$ in the numerator.  Is my approach incorrect or did I apply the definition incorrectly? How do I find the function that is being integrated and $\Delta x$?  Thank you in advance!


Why it is so? Please explain please help me

Why $ \infty - \infty \neq 0 ?$  Please explain


Puzzle about technique of fair using of unfair coin

There is an unfair coin. It tends to land on one side more than on the other. It is unknown which side is it.  There is Mr. A and Mr. B. They argue about something and they want to use that coin to decide who is right.  Is there any technique of using that unfair coin to get fair result?  My solution: I can think of only that there is going to be 2 rounds. First time Mr. A chooses HEAD, than Mr. B chooses HEAD if any of them wins twice they win.


Bash script Multiply only numbers from a text file?

I am looking for a bash command that will multiply only numbers from a text file. Below is the content of my text file. I need multiply all numbers by 100.      0 4530000 sil 4530000 11100000 ow 11100000 6320000 p 6320000 7600000 ah 7600000 8410000 n 8410000 12100000 sil   For single line with only number,I am using something like this below  for file in *.txt; \ do y=`sed -n '1 p' "$file"`;    z=$(bc<<<"$y*100")    sed $file -i -e 's/'"$y"'/'"$z"'/' done   But I dont know how to do it for multiple lines, with alphabets in them. Number of lines in my file are not fixed, each file has different number of lines with max being 8


Generating sublists using multiplication ( * ) unexpected behavior

I'm sure this has been answered somewhere but I wasn't sure how to describe it.  Let's say I want to create a list containing 3 empty lists, like so:  lst = [[], [], []]   I thought I was being all clever by doing this:  lst = [[]] * 3   But I discovered, after debugging some weird behavior, that this caused an append update to one sublist, say lst[0].append(3), to update the entire list, making it [[3], [3], [3]] rather than [[3], [], []].  However, if I initialize the list with  lst = [[] for i in range(3)]   then doing lst[1].append(5)gives the expected [[], [5], []]  My question is why does this happen? It is interesting to note that if I do  lst = [[]]*3 lst[0] = [5] lst[0].append(3)   then the 'linkage' of cell 0 is broken and I get [[5,3],[],[]], but lst[1].append(0) still causes [[5,3],[0],[0].  My best guess is that using multiplication in the form [[]]*x causes Python to store a reference to a single cell...?


In Adobe Photoshop I am able to select multiple layers at once with Shift+Click.  How can I do that in GIMP?


Why is the meter considered a basic SI unit if its definition depends on the second?

The metre is the length of the path travelled by light in vacuum during a time interval of 1  ⁄ 299792458 of a second. – 17th CGPM (1983, Resolution 1, CR, 97),    The meter (or metre) is considered one of the seven base units in SI, but since it depends on what is “a second”, shouldn’t it be a derived unit? Why is the meter considered a base SI unit, even though it depends on the definition of a second?  I am aware that other base units such as the ampere also depend on other base units (namely meter, kilogram and second), and this just increases my confusion even more. Perhaps my question boils down to: What property must a unit have so that it is called a base SI unit?


C# Prevent Application Opening New Instances?

I'm developing a media player and unlike other applications when i click and open with the application, it creates a new instance. how can i prevent it from doing that and actually play the song with the same application running.  Thanks


Tools required to burn code in a quad flat microcontroller

I always have a doubt that how do firmware engineers dump code into a quad flat microcontroller(with or without leads)? For a starter kit there is already connection like USB or some SPI ,I2C headers to burn the code. I know that for Dual inline Package there are some programmers in the market.Then what about quad flat micros used in industrial application?How do you all proceed?


I remember seeing somewhere that IDs are composed of a few pieces. I always have a hard time trying to find that information when I'm looking for it. What I mean by the above is that the various places in the ID represent different things - for example the first few characters represent what type of sObject it is.


I need some help with below. So according to Newton's 2nd law, $a=F/m$, for a given mass, the acceleration depends on mass.   But acceleration due to gravity is independent of mass. There seems some contradiction; I am sure I am missing something, but I can't pin-point what that is.


Can I submit a paper to a journal that is already on arXiv under a public domain license?

Is there any problem in submitting a preprint to a journal while this preprint is already on arXiv with the public domain license (which was selected by mistake)? If so, how can I solve this knowing that arXiv doesn't withdraw published papers?


I have written a latex document, and in this document I reference to equations, tables, and figures. Everything works perfectly.  Now I discovered that I have to use a specific template. Therefore I copy-past my latex code into the template .tex file, and now equation reference is broken. References to tables and figures still work, the bibliography is still fine, but any reference to an equation ends up with a (??).   I am not sure what could be causing this, maybe some loaded packages? (I only load hyperref last).  This is the list of packages I load:  \documentclass[11pt,a4paper,english,oneside]{book} \usepackage{etex} \usepackage[left=1in, right=1in]{geometry}  \usepackage[Lenny]{fncychap} \usepackage[utf8]{inputenc} \usepackage[british]{babel} \usepackage{dsfont} \usepackage{fancyhdr}  \usepackage{booktabs}  \usepackage[hang,bottom,stable,multiple]{footmisc}  \usepackage{appendix}  \usepackage{amsmath} \usepackage{amsfonts} \usepackage{amsmath} \usepackage{amssymb} \usepackage{mathtools} \usepackage[sort,round]{natbib}  \usepackage{etoolbox}  \usepackage{amsthm}  \usepackage{thmtools}  \usepackage{setspace} \usepackage{lipsum}  \usepackage{datetime}  %\usepackage{tocloft} \usepackage{graphicx,listings,xcolor,textcomp} \usepackage{mcode}  \usepackage[margin=10pt, font=small, labelfont=bf, labelsep=endash]{caption} \usepackage{chngcntr}  \usepackage{epstopdf} \usepackage{xparse} \usepackage{cleveref} \usepackage{array,hhline} \usepackage{rotating}  \usepackage{tabularx}  \usepackage{arydshln} \usepackage{tikz} \usepackage{multirow} \usepackage{csquotes} \usepackage{wrapfig}  %instructions to make the algorithm pseudo-code package work \usepackage{algorithm} \usepackage[noend]{algpseudocode} \makeatletter \def\BState{\State\hskip-\ALG@thistlm} \makeatother  \usepackage{hyperref}    Please tell me what other informations I should include.


Prove that the entire function is constant over certain conditions.

Let $f$ a entire function such that there exists $3$ real numbers not   all zero $a$, $b$ and $c$ which $a \Re(f(z))+ b\Im(f(z)) \leq c$, $z \in \mathbb{C}$. Show that $f$ is constant.   I think we could consider the entire function $e^{\alpha f(z)}$ with $\alpha=a+bi$. I know that $|e^{\alpha f(z)}|= |e^{\Re({\alpha f(z)})+i \Im({\alpha f(z)})}|=e^{\Re({\alpha f(z)})}$, but I don't know how to finish it.  Is anyone could help at this point? Maybe we have to use Liouville theorem.


I'm using Ubuntu 14.04 LTS on a virtual machine and I'm trying to set it up so that when it starts up it also automatically follow the description on the startmeup.sh.desktop to start the script taskhome.sh.      The startmeup.sh.desktop script has the following code:  [Desktop Entry] Type=Application Exec=/home/kvm/scripts/taskhome.sh Hidden=false NoDisplay=false X-GNOME-Autostart-enabled=true Name[en]=Startmeup Name=Startmeup Comment[en]= Comment=   I put the file startmeup.sh.desktop on the folder config\autostart and I made it executable with the chmod +x command, but when I reboot Ubuntu the script taskhome.sh is not executed (I guess it's just because the startmeup.sh.desktop is simply not executed either).   If I launch the taskhome.sh script manually I don't have any problem.     If I open the folder that contains the script startmeup.sh.desktop, and I double click on it, the taskhome.sh script starts without any problem.   However if I try to execute the startmeup.sh.desktop script on a terminal with the command ./startmeup.sh.desktop then I get the error "  line 1: [Desktop: command not found.   Is there something I can do to make the script work on Ubuntu start up?


For a month or so now the default programs keeps reverting. And I have to manually re-set my desired applications for certain file types, however these keep reverting irregular (sometimes after a day and sometimes after a week). I'm getting sick of it.  It does not matter what way I set the default app for a file type, after a while its reverted at boot. I tried setting the default programs using: Set Default Programs, Set Associations (both in Control Panel) and by hand: right click > Properties > opens with...  .txt files changes to Notepad instead Sublime Text, images opens with Windows Photo Viewer and not Picasa Photo Viewer, .html files change from Chrome to Edge, .php files get no default program to be opened with, etc. etc.  Windows 10 Pro Version 1511 OS Build 10586.218


How do i search a mysql database for a specific column name

I'm trying to find if my database has a column named sort_method. I have had a look around the forums but don't seem to be able to find the right answer. My database has over 300 tables so manually looking for it is not an option.  I'm using phpMyAdmin - SQL query


How I can prevent my laptop from sleeping when a large file is downloading? Notice that I use windows 8 and the downloader program is IDM where I can find the related settings, in IDM or Windows? Thanks for any help


Help my sister peel oranges. Help my sister to peel oranges. Help my sister peeling oranges.  Help my sister with peeling oranges.   Which of the above is/are correct, and why are the others incorrect?


I am trying to solve this trigonometric equation:  $\sin 84^\circ \sin 18^\circ \sin x = \sin 12^\circ \sin 48^\circ \sin (18^\circ -x)$  I used calculator to get an answer $x=6$ but I don't know how to solve it. Please help. Thanks! Best Regards, Michael


How can I convert a .bbl file to a .bib file. I  lost my .bib file but I still have my .bbl file. Now , I need to add more references to my .bbl file according to a specific format which I need to produce using Bibtex, so how can I convert my .bbl file to a .bib file so I can add the new references according to the format.  Thanks for any insight.


$$ \sum_{i=0}^n {2n \choose 2i} = 2^{2n-1} $$  I know what this sum is supposed to equal.  I also have a hint that I am supposed to use ${n \choose r} = {n-1 \choose r-1} + {n-1 \choose r}$    I was just wondering if someone could help me with where to start.   Do you start with:   $$ {2n-1 \choose 2i-1} + {2n-1 \choose 2i}$$ $$={(2n-1)! \over (2i-1)!(2n-1-(2i-1)!}+{(2n-1)! \over 2i!(2n-1-2i)!}$$


Server Bandwidth requirements for a website?

I am currently developing a website application which should be able to handle around 2000+ users simultaneously when fully operational, what would be the server and bandwidth requirements to handle such capability?  The site is a PHP/MySQL ecommerce site, where users place orders for what they want bought (like a shopping list) and then the order would be complied in the backend side and the lists are then processed. If the supermarket is registered with us the order relating to it would be emailed to them and a supermarket interface is supplied for them so that they can be able to login to the system and view their orders. The site pages have an average size of 8.95kb.   It will run on a Linux server, I can provide more info if need be  Thanks


This is hardly a major issue, but in pursuit of standards, I noticed that the styling (and standard) of the descriptors in the closure dialog box is somewhat lower than expected:


Hey is there any known combinatorial formula for nth fibonacci number?  (n+1)th fibonacci number is given by summation of r=0 to (round)n/2:C(n-r,r) Can someone verify the formula?Help!


I'd like to replicate the picture below. I already know how to create the basic chocolate, however I'm unable to wrap my head around creating the rice krispy bumps on the surface. If anybody knows of an easy way to do this without individually making and placing hundreds of little rice krispy bits, that'd be greatly appreciated. Thankyou! :)


Tell me where is mistake in anacron task?

I have tried to make this task for abacron:  dm@dm-system:~$ cat /etc/anacrontab  # /etc/anacrontab: configuration file for anacron # See anacron(8) and anacrontab(5) for details.  SHELL=/bin/sh PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin HOME=/root LOGNAME=root  # These replace cron's entries 1   5   cron.daily  run-parts --report /etc/cron.daily 7   10  cron.weekly run-parts --report /etc/cron.weekly @monthly    15  cron.monthly    run-parts --report /etc/cron.monthly @daily 5 /home/dm/Devel/btsync && notify-send "Btsync loaded (pid `pidof btsync`)" "Link here."   this command well done from my xubuntu terminal   /home/dm/Devel/btsync && notify-send "Btsync loaded (pid `pidof btsync`)" "Link here."   but when i started my notebook i saw in /var/syslog:  Aug 14 10:49:06 dm-system anacron[904]: Anacron 2.3 started on 2014-08-14 Aug 14 10:49:06 dm-system anacron[904]: Invalid syntax in /etc/anacrontab on line 14 - skipping this line Aug 14 10:49:06 dm-system cron[841]: (CRON) INFO (pidfile fd = 3) Aug 14 10:49:06 dm-system cron[998]: (CRON) STARTUP (fork ok) Aug 14 10:49:06 dm-system cron[998]: (CRON) INFO (Running @reboot jobs) Aug 14 10:49:07 dm-system anacron[904]: Will run job `cron.daily' in 5 min. Aug 14 10:49:07 dm-system anacron[904]: Jobs will be executed sequentially Aug 14 10:54:04 dm-system anacron[904]: Job `cron.daily' started Aug 14 10:54:05 dm-system anacron[2616]: Invalid syntax in /etc/anacrontab on line 14 - skipping this line Aug 14 10:54:05 dm-system anacron[2616]: Updated timestamp for job `cron.daily' to 2014-08-14


CSS pseudo-selector to select the current element within querySelector usable for the sibling (+) or general sibling (~) selector?

If I have this HTML:

  and the JS let elem = document.querySelector('.elem');  Using elem.querySelector(":scope ~ div") does not return anything even though there are div siblings of elem. Using elem.querySelector(":scope > div") returns an element because also there are are div children of elem. How could I select the current sibling of elem?


hf-tikz.sty package installation on mountain lion

I want to install LaTeX on Mountain Lion and want to use some highlighting in my text for which I am using hf-tikz.sty package. I installed MacTeX and Texmaker on Mountain Lion but the package hf-tikz is not installed then I run the TeXLive utility to update all the packages but it gives an error that hf-tikz.sty package is not installed.   Then i downloaded hf-tikz.sty package from the internet and tried to copy in the directory "/usr/local/texlive/2012/texmf-dist/tex/latex/base" but it gives me an error of writing permission.  Can somebody will help me settling out this issue?


I want my method to have access to the variable defined outside the method, but even if i use global keyword it says it can't:  global var = 0 def test():   var = var +1   Compiler still says var is not defined in test method Where is my mistake?


how can I link "fig. 1" rather than "1"?

If I use \ref{fig:fig1} command, It only makes hyperlink to word "1"   Or \autoref{fig:fig1} , it write Figure 1, but link exists on only word "1" also.  As an other way, \cref{fig:fig1} write "fig. 1", but link exists on only word "1".  However, I want to make it to, word "fig. 1" is written, and the hyperlink to figure 1 exists on word "fig. 1" not only on "1"  How can I do that?


How can I change the standard directory of my bash terminal to root?

When I open the Bash Terminal the standard directory is /home/username/ however I want to change it to root. Please help!


If you allow your opponent to draw cards can they have more than 7 cards in their hand until their next clean up stage

I'm thinking specifically about . If I get them to exile 4 cards ie. , and allow them to draw 4 on my turn does that mean they can draw on their turn and do not have to discard until the end of their next turn?


Non EU citizen with German Residence Permit Transit in London

I have an Indian passport and I'm currently working in Germany.  I am travelling from Dusseldorf--London Heathrow--Chennai. Transit time in London Heathrow is 1 hour 30 minutes, and connecting flight to Chennai departs on the same day and it is also from the same terminal.  I have a German residence permit(Aufenthaltstitel), and my German visa is type "D".  Could you please let me know if I require a transit visa in London?


Special character \~{a} (ã) using bibtex not displaying

I am writing a document and I want to include a reference of a person called Catalão. I put the line related to the author in the entry on bibtex as:   author = {P. S. Catal\~{a}o}  However, when I compile my document on latex, I get the following outcome:   How can correctly insert the character ã on bibtex?


$$ \int_0^{\infty } \frac{\log (x)}{e^x+1} \, dx = -\frac{1}{2} \log ^2(2) $$  Anyone an idea on how to prove this?