i am facing the app crash error in android studio when app try to run and the error which logcat is showing is below: **   com.google.android.apps.nexuslauncher E/System: Uncaught exception thrown by finalizer 06-29 18:19:05.002 2840-2849/com.google.android.apps.nexuslauncher E/System: java.lang.NullPointerException: Attempt to invoke interface method 'boolean java.util.concurrent.BlockingQueue.isEmpty()' on a null object reference   ** the home activity and welcome activity is written below  this is the welcome activity  void onCreate(Bundle savedInstanceState) {     super.onCreate(savedInstanceState);     setContentView(R.layout.activity_welcome);      Thread th = new Thread() {         @Override         public void run() {             try {                 sleep(5000);              } catch (Exception e) {                 e.printStackTrace();             } finally {                 Intent home = new Intent(WelcomeActivity.this, HomeActivity.class);                 startActivity(home);             }         }     }; }  @Override protected void onPause() {     super.onPause();     finish(); }   }  and now this is home activity  public class HomeActivity extends AppCompatActivity {  @Override protected void onCreate(Bundle savedInstanceState) {     super.onCreate(savedInstanceState);     setContentView(R.layout.activity_home); }   } in here home activity is not ready yet because i am working on the welcome activity. please help me to solve my issue thank you

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


There is a webserver which has example.com, www.example.com, my.example.com, shop.example.com, static.example.com.  All sites except www.example.com is on https.  My problem is when I type randomstring.example.com -> shop.example.com gets served. But I want nothing to be served.  For example mail.google.com is a valid subdomain.  if you type johndoe.google.com you see "This webpage is not available". How to achieve this via Vhost/.htaccess file.

This is a  about Apache's mod_rewrite.   Changing a request URL or redirecting users to a different URL than the one they originally requested is done using mod_rewrite. This includes such things as:   Changing HTTP to HTTPS (or the other way around) Changing a request to a page which no longer exist to a new replacement. Modifying a URL format (such as ?id=3433 to /id/3433 ) Presenting a different page based on the browser, based on the referrer, based on anything possible under the moon and sun. Anything you want to mess around with URL   Everything You Ever Wanted to Know about Mod_Rewrite Rules but Were Afraid to Ask!  How can I become an expert at writing mod_rewrite rules?   What is the fundamental format and structure of mod_rewrite rules? What form/flavor of regular expressions do I need to have a solid grasp of? What are the most common mistakes/pitfalls when writing rewrite rules? What is a good method for testing and verifying mod_rewrite rules? Are there SEO or performance implications of mod_rewrite rules I should be aware of? Are there common situations where mod_rewrite might seem like the right tool for the job but isn't? What are some common examples?   A place to test your rules  The  web site is a great place to play around with your rules and test them. It even shows the debug output so you can see what matched and what did not.


I've been studying geometric optics and I'm still a little confused with this idea of light . In the book I'm studying everything is being done starting from Fermat's principle which states that the ray path is the one which extremizes the optical length.  Now, I thought that because of this, geometric optics viewed light as particles and I thought that a light ray then would be a trajectory of those light particles. But my question  confirmed that geometric optics doesn't care if light is made of particles or waves.  On the other hand, if we think of light ray as "the path taken by light between two points", this is no good, because the idea of trajectory in this sense is not well defined for waves. Indeed, this idea of light ray doesn't even seen clear to me, because as we know if we have some light source, the light doesn't go along one single path, but as a wave it spreads out in all of the directions at once.  So, if geometric optics doesn't care about if light is made of particles or waves, what really is a light ray? How should we understand light rays and ray paths?

I'm a newbie with physics but I'm wondering how a ray of light can essentially be represented. I have always known that a ray of light proceeds in a straight line until it encounters another object (or material) that refracts/reflects it. But a light ray should be part of an electro-magnetic wave, is this correct? If it is so, it should obey to the  and this doesn't seem to me to describe a straight line ray.  I'm having problems visualizing how light is emitted and how it relates with the wave equation. Can someone with a clear understanding of the problem explain it to me in simple terms?


So I have an issue where when I change the viewport to Solid or Wireframe, nothing shows up apart from one small segment of my object as if its being cast towards by the camera. Below is a screenshot of my model in the workbench renderer where it is all rendering correctly, but when I switch it to solid view the second image is what I see.   To me it looks like the camera is projecting some kind of small ray that is only rendering the part of the model that is in that area but I have no idea how to fix it. Wireframe view has the same issue as you can see on the image below.

When looking at my objects in 3d view I'm seeing a gray cone that seems to be hiding other objects.   Can anyone help me turn this off and explain what it is please.  Screenshots attached.


After switching from Debian stable to Debian testing i have a problem to mount my FreeBSD root partition on my system:   I find out what filesystems my Linux kernel supports through this command cat /proc/filesystems :  nodev   sysfs nodev   rootfs nodev   ramfs nodev   bdev nodev   proc nodev   cpuset nodev   cgroup nodev   cgroup2 nodev   tmpfs nodev   devtmpfs nodev   debugfs nodev   tracefs nodev   securityfs nodev   sockfs nodev   bpf nodev   pipefs nodev   hugetlbfs nodev   devpts nodev   pstore nodev   mqueue     ext3     ext2     ext4 nodev   autofs     btrfs   By default The Linux Kernel can’t read/write on FreeBSD-ufs  partition.  How to enable Unix file system (ufs) support on Linux kernel?  Update  the output of:  modprobe ufs mount -t ufs -o ufstype=ufs2 /dev/sda4 /mnt/ufs_mount   is:  mount: /dev/sda4 is write-protected, mounting read-only mount: wrong fs type, bad option, bad superblock on /dev/sda4, missing codepage or helper program, or other error     In some cases useful info is found in syslog - try    dmesg | tail or so.   The output of dmesg | tail :     [ 1136.965142] ufs: ufs_fill_super(): bad magic number [ 1255.758946] ufs: ufs_fill_super(): bad magic number [ 2098.945757] ufs: ufs was compiled with read-only support, can't be mounted as read-write [ 2098.946045] ufs: You didn't specify the type of your ufs filesystem        mount -t ufs -o ufstype=sun|sunx86|44bsd|ufs2|5xbsd|old|hp|nextstep|nextstep-cd|openstep ...        >>>WARNING<<< Wrong ufstype may corrupt your filesystem, default is ufstype=old [ 2098.967212] ufs: ufs_fill_super(): bad magic number [ 2927.982112] perf: interrupt took too long (2504 > 2500), lowering kernel.perf_event_max_sample_rate to 79750   My sources.list:  deb http://httpredir.debian.org/debian/ stretch main deb-src http://httpredir.debian.org/debian/ stretch main  deb http://security.debian.org/debian-security stretch/updates main deb-src http://security.debian.org/debian-security stretch/updates main   And uname -a:  Linux debian 4.6.0-1-amd64 #1 SMP Debian 4.6.4-1 (2016-07-18) x86_64 GNU/Linux

In order to mount my /dev/sda4  under /mnt/ufs_mount on Debian Testing , i have tried the following commands (it works fine under Debian Jessie):  modprobe ufs mount -r -t ufs -o ufstype=ufs2 /dev/sda4 /mnt/ufs_mount   and:  mount -t ufs -o ufstype=ufs2 /dev/sda4 /mnt/ufs_mount   But i get this error:  mount: /dev/sda4 is write-protected, mounting read-only mount: wrong fs type, bad option, bad superblock on /dev/sda4,    missing codepage or helper program, or other error     In some cases useful info is found in syslog - try    dmesg | tail or so.   The output of: dmesg | tail :  [ 1136.965142] ufs: ufs_fill_super(): bad magic number [ 1255.758946] ufs: ufs_fill_super(): bad magic number [ 2098.945757] ufs: ufs was compiled with read-only support, can't be mounted as read-write [ 2098.946045] ufs: You didn't specify the type of your ufs filesystem        mount -t ufs -o ufstype=sun|sunx86|44bsd|ufs2|5xbsd|old|hp|nextstep|nextstep-cd|openstep ...        >>>WARNING<<< Wrong ufstype may corrupt your filesystem, default is ufstype=old [ 2098.967212] ufs: ufs_fill_super(): bad magic number [ 2927.982112] perf: interrupt took too long (2504 > 2500), lowering kernel.perf_event_max_sample_rate to 79750   Edit My sources.list:  deb http://httpredir.debian.org/debian/ stretch main deb-src http://httpredir.debian.org/debian/ stretch main  deb http://security.debian.org/debian-security stretch/updates main deb-src http://security.debian.org/debian-security stretch/updates main   And uname -a:  Linux debian 4.6.0-1-amd64 #1 SMP Debian 4.6.4-1 (2016-07-18) x86_64 GNU/Linux   How to mount ufs file system under Debian testing?


I have a class:  public class MyObject { public string Name; public int Age; }   I have a List of Myobject objects:  Name Age ABC 12 BBC 14 ABC 11   How to sort this list with condition: sort Name first & sort Age later. With this list, the result after sorting:  Name Age ABC 11 ABC 12 BBC 14

I have two tables, movies and categories, and I get an ordered list by categoryID first and then by Name.  The movie table has three columns ID, Name and CategoryID. The category table has two columns ID and Name.  I tried something like the following, but it didn't work.  var movies = _db.Movies.OrderBy( m => { m.CategoryID, m.Name })


I want to set an environment variable from a bash script that I wrote.  So I created a bash script and called it set.sh. Its content is as follows:  #!/bin/bash  export DEV_SRC="/home/m/mydata/sourecCode" echo $DEV_SRC   When I run this script, the output is   /home/m/mydata/sourecCode   But if I run this code on the same terminal that I ran the above script from,   echo $DEV_SRC   I cannot see any value, so I think the value is not exported.   Why is the value not exported?

I came across this example when trying to mount a usb device inside a openvz container and I have never seen the construct in the second line before. Can you explain what it signifies?  #!/bin/bash . /etc/vz/vz.conf


Is there any reason why I can't paste my code into the question block? As per the comment below I tried indenting it all 4 spaces and all of it 8 spaces; it just doesn't work what is the trick too it ?

How do I post text so that it is formatted as code?  What do I need to do so that my code shows up properly — not escaped or removed — when posted? And how to get the correct syntax highlighting?     For more information, see "" in the .


I need help on exporting both private keys and public located in ssh into one file. id_rsa and id_rsa.pub

A SSH private key as generated by ssh-keygen contains a public key part. How do I retrieve this public key from the private key? I've lost my public key and need to put the contents of this public key in the servers authorized_keys file and do not want to create a new key pair.  Alternatively phrased: how do I create the id_rsa.pub file from a id_rsa file?


Let $X_{k}$ be i.i.d random variables with $E[X_{k}]=\mu$ and $Var(X_{k})=\sigma^{2}<\infty$ and let $\bar{X}=\frac{1}{n}\sum_{k=1}^{n}{X_{k}}$. Let $$S^{2}=\frac{1}{n-1}\sum_{k=1}^{n}{(X_{k}-\bar{X})^{2}}(n\geq 2)$$ be the sample variance. Does $S^{2}$ converges almost surely and what is (if it exists) its limit?

Suppose $X_{1},X_{2},\ldots$ be i.i.d. random variables such that $E\left[X_{i}\right]=\mu$ and $Var(X_{i})=\sigma^{2}<\infty$. Let $\bar{X}=\left(X_{1}+\cdots+X_{n}\right)/n$. Show that $\frac{1}{n}\overset{n}{\underset{i=1}{\sum}}\left(X_{i}-\bar{X}\right)^{2}\rightarrow\sigma^{2}$ a.s.  Solution: Let $S_{n}=\frac{1}{n}\overset{n}{\underset{i=1}{\sum}}\left(X_{i}-\bar{X}\right)^{2}$. By Chebyshev's Inequality, $\sum_{n=1}^{\infty}P\left(\left|S_{n}-E\left[S_{n}\right]\right|>\varepsilon\right)\leq\sum_{n=1}^{\infty}\frac{Var(S_{n})}{\varepsilon^{2}}$. And we know that $E\left[S_{n}\right]\rightarrow\sigma^{2}$, so I would like to finish this proof by using first Borel-Cantelli Lemma if I can show the right hand side is summable. However, $Var(S_{n})=\frac{2\sigma^{4}}{n-1}$, so the sum is infinity, which means it doesn't converge almost surely. Where am I wrong?


Lets say i have a piece of code like that:  String name1 = someObject.getClass().getName(); System.out.println(name1);//The result of println in console is: entities.player.Shotgun  String name2 = someObject.getClass().getSimpleName(); System.out.println(name2);// The result of println in console is: Shotgun  String name3 = someObject.getClass.getName().substring(16); System.out.println(name3);//The result of println in console is: Shotgun  if(name1 == "entities.player.Shotgun")System.out.println("condition1 true"); if(name2 == "Shotgun")System.out.println("condition2 true"); if(name3 == "Shotgun")System.out.println("condition3 true");   In my opinion all three if clauses are true but in reality only first fires in console: condition1 true. My question is why? What is the problem here?

I've been using the == operator in my program to compare all my strings so far. However, I ran into a bug, changed one of them into .equals() instead, and it fixed the bug.  Is == bad? When should it and should it not be used? What's the difference?


I have just installed ubuntu, I am picky about UI design choices and have spotted something I do not like, but this time instead of just hating it I wish I could tell the ubuntu team so maybe just maybe someone in a future release might take 5 minutes to change it...  Where do I report such an issue?  The issue in question is :      I think the little arrow down and the labels next to it are too close to the edge. The arrow should be padded at least 5px and the label should be further from the arrow. When a whole list of such items shows up it looks real naff.

Many people have opinions or want to give feedback about Ubuntu.  If they are simple bugs with a crash or display corruption, that's fine, they can .  But, comments about the design or concept of the system are more problematic.  They come up all over the place, such as "" in other places that are not really about Unity.  Ideally the answer will be a place where the comments   will actually be read by the design team  will tend to encourage people to read the existing comments and not post the same thing again and again perhaps will tend to bubble up good solutions rather than strange ideas will not be annoying to people who are trying to use that place for something else


I've got a little question. I want to get specific information out of my database via mysqli query:  public function get_searchorder_single_information($soid, $information) {          global $mysqli;          $stmt = $mysqli->prepare("SELECT ? FROM pr_hr_searchorders WHERE id = ?");         $stmt->bind_param('si', $information, $soid);         $stmt->execute();         $stmt->bind_result($result);         $stmt->fetch();         echo $result;          $stmt->close();      }   In my example, $information is set 'job', but it can have other values, too (e.g. 'salary'). When I try to use my query with this variable, echo outputs just 'job' and not the value that is saved in my database. When I write 'job' instead of the '?', echo outputs the correct value.  So now I could make a function for each information I search, but this would end in spaghetti code. So I ask you if there is any possibility to use my search query like above with correct output. How would I do that?  Thanks in advance and sorry for my bad english writing.

Why can't I pass the table name to a prepared PDO statement?  $stmt = $dbh->prepare('SELECT * FROM :table WHERE 1'); if ($stmt->execute(array(':table' => 'users'))) {     var_dump($stmt->fetchAll()); }   Is there another safe way to insert a table name into a SQL query? With safe, I mean that I don't want to do  $sql = "SELECT * FROM $table WHERE 1"


The code for multi labels eg.: Field1 || '\n' || Field2  works fine, unless you have a missing value (NULL) in one of your fields, in which case QGIS doesn't show any labels at all (for the specific object). I use QGIS 3.10.14-A Coruna. Any suggestions?

I am having some issues trying to show multiple fields for a single label in QGIS. In QGIS2.6, attempting to display labels for a feature consisting of multiple fields results in an empty label if one of the fields is null. So for example, in the label expression dialog:  concat("Temp Site",'\n',"Notes",'\n',"Function")   will function normally unless one of the fields is null, then it results in no label being shown. Using the '||' operator instead in the expression dialog also results in the same behaviour:  "Temp Site" || '\n'  ||  "Notes" || '\n'  ||  "Function"   Is there a way to display the labels even if one of the fields is null?


I am trying to figure out the effect of two independant variables (country and device_type) on a binary dependant variable (conversions). I am running a logit regression on a dataset with only the independent categorical variables. Both of these variables have several values. The event (conversions) occurs approximately 0.2% of the time (on 750 000 observations).  I am trying to establish which country and device have the greatest effect on conversion.  For certain countries, the coefficients are significant, but I do not have any positive event for this country. How can this happen ? How can I establish if my model converged. I have no warning. Any help on the issue is appreciated.  I am using the glm procedure in R: logit1 <- glm(conversions ~ device_type + country, data = reg_data)  this is a repost (under my name) of this :  Thank you,

I am running a logit regression on a dataset with only 2 independent categorical variables, country and device type. Both of these variables can take several values. The dependant variable is binary. The event occurs approximately 0.2% of the time.  For certain countries, the coefficients are significant, but I do not have any positive event for this country. How can this happen ?  I am using the glm procedure in R.  Thank you,


Is Chris's Carpet Repair correct or should it be Chris' Carpet Repair?

Many questions already ask about this topic ( , , etc.) and their answers vary, but they always give exceptions to the apostrophe-s rule, for example:      6.24 The general rule for the possessive of nouns covers most proper nouns, including most names ending in sibilants."   Examples they give include Kansas’s, Ross’s land, and Jones’s reputation. Exceptions include Jesus’  and Moses’.  Which names does this apply to?  Is the Aeneas’  form correct, or is it Aeneas’s instead?


I installed Wine to run Windows applications on Ubuntu. As soon as I opened Wine a message popped up saying it needed to download and install some stuff to run Windows apps. I clicked okay and as they were being downloaded/installed, my PC shut down because my battery drained. I turned my PC back on and tried to open Wine (the app's called Winetricks) but it won't open at all. It's logo appears in the launcher but it closes after a few seconds. I don't know what to do. I tried completely uninstalling it using Synaptic or purging it via the terminal to install it again. These methods 'work', they uninstall Winetricks and Wine Configuration, that comes along Winetricks, but I install Wine again from the beginning and it still won't open. I really need to get Wine working. I know Play on Linux is an alternative but I've heard it doesn't work as well as Wine. I need newbie-type help, I've had Ubuntu for a day and I basically know nothing. I'd appreciate detailed help for me to get things done. Thank you in advance.  UPDATE: When trying to install Wine sometimes I get the message ''Some index files failed to download. They have been ignored, or old ones used instead.'' I suppose that I basically need a way to completely remove Wine, configuration files, index files, anything it downloaded.

How can I remove the wine folder and all the applications in that folder?  I've tried via synaptic but it keeps showing up in the application menu.


use nginx + php-fpm + mysql error like this : ["Allowed memory size of 134217728 bytes exhausted (tried to allocate 214769672 bytes)"]  What i try: I set php-fpm/www.conf php_admin_value[memory_limit] = 1024M, and restart php-fpm, and phpinfo() show the right value 1024M, like this picture:  php_admin_value[memory_limit] is the highest limit, it could not overwrite by php.ini or ini_set(). and phpinfo show the current memory_limit = 1024M, but this error is also exist. I realy realy dont know why this error happened. please help me!

I have a bunch of client point of sale (POS) systems that periodically send new sales data to one centralized database, which stores the data into one big database for report generation.  The client POS is based on PHPPOS, and I have implemented a module that uses the standard XML-RPC library to send sales data to the service. The server system is built on CodeIgniter, and uses the XML-RPC and XML-RPCS libraries for the webservice component. Whenever I send a lot of sales data (as little as 50 rows from the sales table, and individual rows from sales_items pertaining to each item within the sale) I get the following error:  Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 54 bytes)   128M is the default value in php.ini, but I assume that is a huge number to break. In fact, I have even tried setting this value to 1024M, and all it does is take a longer time to error out.  As for steps I've taken, I've tried disabling all processing on the server-side, and have rigged it to return a canned response regardless of the input. However, I believe the problem lies in the actual sending of the data. I've even tried disabling the maximum script execution time for PHP, and it still errors out.


I plan to use this line in /etc/fstab on Ubuntu a 14.04 server running LAMP: /run/shm/tmp  tmpfs   nosuid,nodev,noexec,size=8G   0  0  My question is, does anyone know if I will create problems by mounting /tmp with nosuid and noexec?  Edited Jan-31-2015: The answer referred to above in "" does not answer my question about what problems might occur if I mount /tmp with nosuid and noexec. It simply mentions that its not necessary to do so, and that something "might" break if I use those options. The answer below, by aFoP and muru does answer my question by enumerating what will fail, and how to work around the problem. Thanks aFoP and muru!

What is the best way (options, those numbers on the end) to mount a /tmp partition in /etc/fstab in terms of security and speed on a desktop (laptop) computer (read: not server)?  I've heard about nosuid, nodev and noexec, but I have no idea what they do, how to use them or even if I should used them.  I'm using LVM btw.


Why is the principal value of the argument of z always in the interval of -pi and pi?

Why the principal value of complex number argument is taken within $(-\pi,\pi]?$ What is the harm in considering similar other intervals like $[0,2\pi)$ for the purpose?


It is a single book story about a girl who, along with a fish, a cat, a frog and maybe some other familiars, escapes the witch who was holding them captive.  The fish had a pearl in its mouth, the frog a stone on its head, the cat had something in its paw and the girl, something in her stomach.  I don't remember much more than it being their journey to finding out who they really are and why the witch had captured them.

The story is set in a vaguely medieval world in which a young woman has been cursed by the evil witch who has enslaved her and caused her to lose her memory. With the aid of her talking animal friends who have also been cursed (toad has a huge stone under his tongue meaning he can't feed and a crow with a gem embedded in its wing and there's a little grey kitten too who never grows up) she sets out on a journey to break the curse for herself and her friends. Along the way she meets an injured unicorn and a horny-but-moral soldier rendered impotent by a curse after refusing the disguised witch's sexual advances.  After adventures there's a 'happy ever after' for all of the heroes and the witch meets a sticky end.    In the UK the book had a deep red cover with an illustration. I read it in either the 1990's or the early 2000's. Cracking book, definitely for adults given some of the situations, language and humour.


I have some data and I would like to test the hypothesis that they come from a homogeneous Poisson process. I can of course look at the inter event times and test if these are exponentially distributed. However this misses lots of reasons why it might not be Poisson it seems .  Is there a list of tests, or a particular good test, that I can use that does more than look at the set of inter event times between consecutive events?  If you take all the differences between arrival times, that is not just consecutive arrival times, can this be used to make a more powerful test for example?

I have some discrete times of events and I would like to do a test to see if they are likely to have come from a homogeneous Poisson process.   From this pdf, I see:       REMARK 6.3 ( TESTING POISSON ) The above theorem may also be used to test the hypothesis that a given counting process is a Poisson process. This may be done by observing the process for a fixed time $t$. If in this time period we observed n occurrences and if the process is Poisson, then the unordered occurrence times would be independently and uniformly distributed on $(0, t]$. Hence, we may test if the process is Poisson by testing the hypothesis that the n occurrence times come from a uniform $(0, t]$ population. This may be done by standard statistical procedures such as the Kolmogorov-Smirov test.     However I don't quite understand what to do in practice.  Say my times are   [1, 7, 18, 22, 41, 43, 66, 73, 86, 92]   and the time interval I chose was from $1$ to $100$.  How exactly do I do the Kolmogorov-Smirov test in this example?


Let $X$ and $Y$ are random variables and they are both independent from the $\sigma$-algebra $\mathscr F$. Given a Borel measurable function $f(x,y)$, is $f(X,Y)$ also independent from $\mathscr F$?  I guess it is right, but actually not quite sure. Here is what I do:  Let $A$ be a Borel set, then $B = \{ f(X,Y) \in A \}$ is also a Borel set. I consider the case where $B = B_1 \times B_2$ is a rectangular area. Then given $E \in \mathscr{F}$, $P(\{f(X,Y)\in A \}\cap E) = P((\{ X \in B_1\} \cap E) \cap (\{Y \in B_2\} \cap E))$. It seems I cannot proceed any more. And I even get skeptical whether it is right.  Any help is appreciated!

Let $X_1,...,X_n$ be mutually independent RVs. Suppose $X_i \perp \mathcal F $ for $1\ \leq \forall i \leq n$.    How can I show that:  $$\sigma (X_1,...,X_n) \perp \mathcal F$$ ?  What I have tried:  $\sigma (X_1...X_n) = \sigma(\cup_{i=1} ^n \sigma(X_i))$ holds. I think I need some Dynkin's lemma-ish argument but can't see how.


Yes, I'm working on 14.04 LTS... And if I could have another year for updates I won't change. Despite having used Ubuntu since 10.XX, this is the first time I need to upgrade (not install from scratch).  And, I'm asking if it easy to upgrade directly to the 20.04 LTS (I have read a lot of good things) or it will be a problem (of any type) and it's best to move first to 16.04 or 18.04...  I'm not asking for an install guideline. I'm asking for the community knowledge about upgrading Ubuntu. Maybe some packages will cause tremendous hardships or something like that.

I am currently using Ubuntu 10.04. I know there is a 10.10 release, but can I upgrade directly to 11.04? Could you walk me through the steps please?


I am planning on getting my first DSLR soon. I'm torn between the 1300D and 650D because they are about the same price right now. I love the fact that the 650D has a movable touchscreen and a mic input, but I'm not sure if buying a nearly 7-year-old model over the 2016 1300D is a good idea. So what would be better more features but older sensor or new sensor but fewer features? (I know the 1300D has wifi capabilities. but I value that less than the movable screen. But I have never owned a DSLR so if wifi is crazy useful and I don't realize it please tell me.)

I am thinking of buying a digital SLR camera. What things should I be looking for?


How to prove $$1+\cfrac{1}{1+\cfrac{e^{-2\pi}}{1+\cfrac{e^{-4\pi}}{1+\cfrac{e^{-6\pi}}{\cdots}}}} = \left(\sqrt{5\phi}-\phi\right) e^{2\pi/5}.$$ i dont know how to do it. like if there were repeating terms we put it to be $z$ and then again $1/z$ and solve the quadratic  but how to go for this. Note that I am interested if there is a  way using elementary knowledge as I am only in grade $12$. Thanks!

I found this problem on a well-known problem solving website. It is apparently from Ramanujan.     With   $$\LARGE{a = \frac{1}{1 + \frac{e^{-2\pi}}{1 + \frac{e^{-4\pi}}{1 + \ddots}}}},$$   what is $a$?   The basic methods I know for questions of this type were not helpful to me.  I do not require a full solution, but feel free to post one if you would like. Hints or lecture notes on how to solve problems of this nature would be appreciated.   Keep in mind that I am at an undergraduate level in mathematics.


I can just run systemctl suspend in my terminal without sudo, and my laptop goes to sleep.   However, when I want to make a crontab for the same user that previously ran the command just fine without sudo (me) this doesn't work, and I have to run sudo crontab -e instead of just crontab -e to generate the crontab.

I have this cronjob set :  * * * * * /usr/bin/systemctl suspend   And it is not working. But I can run it in a shell and it works. I don't understand what could be not working.  EDIT Redirecting error output to /tmp/error gives this :  Failed to issue method call: Access denied Failed to issue method call: Access denied   My question is then : Are cronjobs run as a special user (cron for example), which would explain that my user can run the command, but not cron itself?  Additional explanation :   This is a minimal example to show a problem I have in a script (that makes more sense than the single command provided here) systemctl is part of systemd. I think reboot, shutdown, suspend are working with a non-root user with systemd. Anyway, it is working on my system. Finally, I use Arch Linux and /bin, /usr/sbin, /sbin are all symlinks to /usr/bin.


I am trying to restart my Apache but I keep getting this error:  Jan 28 20:34:05 localhost systemd[1]: apache2.service: Failed with result 'resources'. Jan 28 20:36:22 localhost systemd[1]: apache2.service: Failed to run 'start' task: No space left on device Jan 28 20:36:22 localhost systemd[1]: Failed to start The Apache HTTP Server. Jan 28 20:36:22 localhost systemd[1]: apache2.service: Failed with result 'resources'. Jan 28 20:37:37 localhost systemd[1]: apache2.service: Failed to run 'start' task: No space left on device Jan 28 20:37:37 localhost systemd[1]: Failed to start The Apache HTTP Server. Jan 28 20:37:37 localhost systemd[1]: apache2.service: Failed with result 'resources'. Jan 28 20:45:03 localhost systemd[1]: apache2.service: Failed to run 'start' task: No space left on device Jan 28 20:45:03 localhost systemd[1]: Failed to start The Apache HTTP Server. Jan 28 20:45:03 localhost systemd[1]: apache2.service: Failed with result 'resources'.   I have tried this  but it does not work:     fs.inotify.max_user_watches = 262144 (Add this to /etc/sysctl.conf and   then run sysctl -p.)   This is some more info if it helps?  sudo df -h Filesystem      Size  Used Avail Use% Mounted on /dev/root        20G   20G     0 100% / devtmpfs        488M     0  488M   0% /dev tmpfs           490M     0  490M   0% /dev/shm tmpfs           490M   51M  440M  11% /run tmpfs           5.0M     0  5.0M   0% /run/lock tmpfs           490M     0  490M   0% /sys/fs/cgroup tmpfs            98M     0   98M   0% /run/user/0   Any ideas what I can do?  EDIT:  There is no solution from this . How is this duplicated?

I'm using Ubuntu 11.04 and I want to free up some space in my root directory, which is overloaded. I especially want to change the path used for installing applications (they are getting installed directly to the root drive).  Another consideration is that I'm working on a MySQL database server. The server is installed in the root directory itself, so I don't want to  risk losing any data.  Please give me some tips to help sort out this problem.


Is there a way in pure Javascript to turn links in an HTML document into clickable links? I do not want to use regex to solve this problem.  Let's say I have this list in an HTML5 doc:
 http://www.test.com http://www.example.com http://nicelink.com
   And I want it to automatically turn into this when the page is loaded:
 http://www.test.com http://www.example.com http://nicelink.com
   What would the vanilla JS code look like if I put a script in the header? Something looping through the HTML code and replacing the lines I suppose but I cannot write it in JS.  Signy

I am using the function below to match URLs inside a given text and replace them for HTML links. The regular expression is working great, but currently I am only replacing the first match.  How I can replace all the URL? I guess I should be using the exec command, but I did not really figure how to do it.  function replaceURLWithHTMLLinks(text) {     var exp = /(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/i;     return text.replace(exp,"$1");  }


I installed Ubuntu 12.04 LTS into Windows XP using Wubi.exe.  Update Manager tells me an upgrade to 14.04 is available, and the Manager has an "Upgrade" button.  If I click that, will it upgrade my wubi-installed Ubuntu in Windows and leave Windows intact, or will it install the upgrade on top of Windows, thereby, eliminating Windows?  I want to keep things just as they are except have Ubuntu 14.04 LTS instead of 12.04 LTS.  Would it be better for me to uninstall 12.04 and do a fresh install using Wubi.exe (14.04)?

I've got Windows 7 with Wubi 11.10 installed. I would like to upgrade to 12.04 but I'm not sure what the best path would be.  I'm not skilled enough to use Ubuntu all the time, and my iPhone requires me to run some Windows version for the damn iTunes software. I would love to run Windows XP but I can't figure out how to install it via USB -- my computer has no cd drive.  I'd like to run Windows XP and Wubi 12.04 on top of that. Or, perhaps, Ubuntu 12.04 natively and Windows XP alongside of that. So I guess I have 2 questions:   (lazy) Should I upgrade my Wubi from inside Ubuntu, or should I remove Wubi 11.10 from within Windows and install a brand new Wubi 12.04? (proper) How can I install Windows XP and Ubuntu 12.04 alongside each other?   Update: I am going to create a separate question post about the above #2 question... I realize it's wrong to ask two questions in one post when they are that different.


In my code I need to unregister and register an event handler, This works perfect:  _favoritsImageView.Click -= _favoritsImageView_Click(this, new CustomeClickEventArgs(item)); _favoritsImageView.Click += _favoritsImageView_Click(this, new CustomeClickEventArgs(item)); void _favoritsImageView_Click(object sender, CustomeClickEventArgs e) {        // handles the event }   But for an awaitable event handler i have to use this syntax:  _favoritsImageView.Click -= async (s, e) =>  { await _favoritsImageView_ClickAsync(s, new CustomeClickEventArgs(item)); };  _favoritsImageView.Click += async (s, e) =>  { await _favoritsImageView_ClickAsync(s, new CustomeClickEventArgs(item)); };  async Task _favoritsImageView_ClickAsync(object sender, CustomeClickEventArgs e) {        // does async task }   This does not work. Because anonymous methods do not have the same reference. So the first line does not un-register the already registered handler. And eventually the second line adds an extra event handlers to the click.  Which syntax do I need to use to add and remove an async event handler?  Thanks for any suggestion.

Is it possible to unsubscribe an anonymous method from an event?  If I subscribe to an event like this:  void MyMethod() {     Console.WriteLine("I did it!"); }  MyEvent += MyMethod;   I can un-subscribe like this:  MyEvent -= MyMethod;   But if I subscribe using an anonymous method:  MyEvent += delegate(){Console.WriteLine("I did it!");};   is it possible to unsubscribe this anonymous method?  If so, how?


There is often organic shape, very minimalist illustration of a person(s).    I know these are flat vectors, I want to know name of artistic style.

I want to buy some stock photos like the ones below. What is this design called?  I don't even know how to start searching...


I am making an applications that works for multiple users and use data from registry that is written by another user. currently I am writing to HKCU. and it is not working because HKCU is local. and after it failed i tried to write on Local Machine but it has some permision issues.  So what is the suitable location to write the registry in this scenario. I am using following code to create to key.  RegistryKey regKey = Registry.CurrentUser; RegistryKey  subKey = regKey.CreateSubKey(subKeyName);

I have some program settings that are currently stored in HKEY_LOCAL_MACHINE. Due to Vista and locked down users, some users don't have permission to HKEY_LOCAL_MACHINE, and those values don't really belong to HKEY_LOCAL_USER either (it has to be the same for all users), what's the best alternative location for storing these?  Majority of settings are stored in the DB already, but there are some that the program needs to know about before connecting to the DB. Ideally I'll like a way to implement this without needing to check what operating system is running.  This is for a desktop app written in Delphi.


I am from Chennai India, travelling to Auckland tonight with Student Visa, I have booked ticket in Malaysian Airlines,  Chennai - Kuala Lumpur, Kuala Lumpur - Melbourne, Melbourne to Auckland.  I will be staying in Melbourne for 3 hours, do I require a transit visa?

Indian passport holder. Do I need transit visa in Sydney?


Is it possible to add a question classification option? For example users who will be answering it may have preference for fixing issues (problem solving) vs how to build something (creativity). An analogy of question classification vs question tagging would be soft skills vs hard skills on your resume. As an example please see image below from ZenDesk help desk system. For SO question classifications can be site specific or defined by moderators as needed.

Apparently I inadvertently irked a moderator by creating a tag.  The moderator told me that my tag was "meta" and therefore not appropriate.  Having been a SO user for a long time (and a lurker on MetaSO), it was not clear to me what makes my tag "meta" and why meta tags would be inappropriate.  Many of the questions I see on SO aren't really about the topics in the title or the existing tag list.  For example, , isn't really about C++ or SetWindowText (or the Windows API as tagged).  It's simply somebody who had a bug, couldn't find it, and tried to outsource the debugging.  This seems to be a common category of question on SO.  So I started tagged questions like this with the label "findmybug".  Lots of frequent SO contributors regularly answer questions in this category rather than voting to close them as "Too Localized".  I took that as a cue that I should also try to answer rather than voting to close.  But leaving these questions open and tagged with "c++" and "winapi" even though the question isn't really about C++ or the Windows API seemed misleading.  Someone searching for answers on using SetWindowText from C++ probably isn't making exactly the same mistake and won't find that entry useful.  (In the end, the sample question was closed as "Too Localized", but this doesn't seem common for these types of questions.)  The Tags page says:     A tag is a keyword or label that categorizes your question with other, similar questions. Using the right tags makes it easier for others to find and answer your question.   It seems to me that the "findmybug" tag does group these similar questions together.  So from that perspective, it seems to fit.  Lots of users seem to enjoy answering these types of questions, so it makes sense they'd want a way to find them.  If you want to suggest that all the questions I would tag as "findmybug" should be closed as "Too Localized", that's fine.  But I'm trying to ask the more general question:  What makes a tag meta, and are meta tags inappropriate?


I am having a hard time figuring up why this code of mine gives me an unhandled exception error where in fact it is an if statement..           If (Not System.IO.File.Exists("C:\file.txt") And System.IO.File.ReadAllText("C:\file.txt").Length <> "20") Then             MessageBox.Show("Code executed!")         Else             MessageBox.Show("Failed to execute!")         End If   Can you please tell me what have I missed?

In VB.NET, what is the difference between And and AndAlso? Which should I use?


The past two nights, our nightly index job has caused our log drive to fill up.   We complete log file backups every 15 minutes, and the log file still grew to 250GB.  This is a SQL Server 2008R2 SP3 instance.  Our DBCC LOGINFO shows 1500 rows, with all but 6 with a status of 2.  There are no open transactions.  (dbcc opentran) The wait_type_desc = 2 / Backup Log The database used to replicated, (long ago). Even ran the command to turn off replication.  However, completing a log backup does not seem to clear the VLFs.   The only way I've been able to clear is to convert the database to simple recovery and then shrink the logfile.   Which, obviously, this is not desirable.   I'm not sure where else to look.  Any help would be appreciated.

This one seems to be a common question in most forums and all over the web, it is asked here in many formats that typically sound like this:  In SQL Server -  What are some reasons the transaction log grows so large? Why is my log file so big? What are some ways to prevent this problem from occurring? What do I do when I get myself on track with the underlying cause and want to put my transaction log file to a healthy size?


If $a ≡ b$ (mod $n$), prove that $a^5 ≡ b^5$ (mod $n$).   I know there is some way of solving this using binomial expansion but it has me stumped.

I am working on a problem I am pretty close to solving but I can't figure out the last part. I used some algebraic manipluation to break the problem down. The problem is:     Show that the following congruence is true      a^b = ((a mod n)^b) (mod n)      for any positive integers a, b, and n.      Hint: Number a can be written as a = q*n + r, where q = floor brackets a/n, and r = a mod n.   My attempt it:     (q*n +r)^b = ((a mod n)^b) * (mod n)      (q*n)^b + (a mod n)^b = ((a mod n) ^b) * (mod n)      (a)^b -(r)^b = ((a mod n) ^b) * (mod n)      (a)^b = modn  ----> divided by ((a mod n)^b)   Am I doing this correctly and if so how can I prove this is true? Is there a trick I am missing? I think that by simplifying it further I would just keep going in a loop.  Thanks!


After reading the other question about the Monty Hall problem, and seeing the solution of it, before giving my perspective to the question, I would like to point out that, to explain the possible cases, we either fix the doors that I choose and Monty Hall opens, and permutate the values of the doors, i.e what is behind them, or we fix the values of the door, and permutate the door we and Monty Hall chooses.   Given that, let WLOG I choose the first door and Monty Hall opens the 3rd door, then we have the following cases;  1-> car 2-> goat 3-> goat  or  1-> goat 2-> car 3->goat  Since, we do know that the car is not behind the door 3.  So, there is only 2 option in one of them I win, and in the other I loose, hence the there is no difference in changing the door I chose first, hence the probability of the door 1 has the case is 1/2.  So my question is what exactly wrong with this argument ? Exactly which step of the argument fails to be true ?  Edit:  In this question, I was pointing out some of the problems that I general answer to Monty Hall problems contains, so it is different than the question that is claimed that this question to be duplicate of.

I'm confused about why we should change door in the Monty Hall Problem, when thinking from a different perspective  gives me equal probability.   Think about this first: if we have two doors, and one car behind one of them, then we have a 50/50 chance of choosing the right door.   Back to Monty Hall: after we pick a door, one door is opened and shows a goat, and the other door remains closed. Let's call the door we picked A and the  other closed door B. Now since 1 door has already been opened, our knowledge has changed such that the car can only be behind A or B. Therefore, the problem is equivalent to: given two closed doors (A and B) and one car, which door should be chosen (we know it's a 50/50 thing)? Then, not switching door = choosing A, and switching door = choosing B. Therefore, it seems that switching should be equally likely, instead of more likely.   Another way to think: no matter which door we choose from the three, we know BEFOREHAND that we can definitely open a door with a goat in the remaining two. Therefore, showing an open door with a goat reveals nothing new about which door has the car.   What's wrong with this thinking process? (Note that I know the argument why switching gives advantage, and I know experiments have been done to prove that. My question is why the above thinking, which seems legit, is actually wrong.) Thanks.


My girlfriend and I are travelling to Jakarta, Yogyakarta and Bali this month and we will share the same room throughout the trip. We are both Chinese citizens. Recently I have seen news reporting that Indonesia is finalising a new criminal code that will criminalise unmarried couple living together.  I have googled relevant information but haven't found anything regarding when the new criminal code will be in effect. All I found were some pieces of news in early 2018 reporting the finalisation of the new legislation, but I have no idea whether the new criminal code is in effect or not. Can anyone advise me when the new criminal code will be carried out and if this will be a concern to our upcoming trip? Do we need to use two separate rooms in a hotel in Indonesia?

Basically  but then for Indonesia.  In the coming year I (male) plan to travel through Indonesia (Java and Sumatra) with my girlfriend. We will probably travel several weeks, aim to stay in the larger cities, but also plan on several multi-day hikes in the nature where we would camp or sleep in smaller villages.  Indonesia is mostly an Islamic country and , meaning that at least there one should adjust their behaviour (compared to how couples behave in Western Europe).  How about the other provinces of Java and Sumatra?  To make this question not too specific I am omitting any possible cities we might visit (itinerary is far from set), in the hope that an extended and broad answer is given that is also useful to others visiting these islands.


I have this class:  public class Person {     private String id;      @Override     public boolean equals(Object obj) {         return obj instanceof Person &&             this.id.equals(((Person) obj).id);     }      @Override     public int hashCode() {         ...     } }   The field id consists solely of digits. My question is, should the hashCode method look like this:  @Override public int hashCode() {     return id.hashCode(); }   or this:  @Override public int hashCode() {     return Integer.parseInt(id); }   Provided that id <= Integer.MAX_VALUE.

What issues / pitfalls must be considered when overriding equals and hashCode?


When a request comes in, it gets rerouted to one of several available servers for the request. But there's only 64k ports available so at any given time there can only be 64k outgoing requests max. So how can some websites serve millions of concurrent requests then? If someone could clear up this confusion that would be awesome. Thanks!

If there is a limit on the number of ports one machine can have and a socket can only bind to an unused port number, how do servers experiencing extremely high amounts (more than the max port number) of requests handle this? Is it just done by making the system distributed, i.e., many servers on many machines?


I want to run my java program outside of eclipse as an .exe file, I am very new to programming so I just wanted to know if there's an easy and free way of converting my program into an exe file after exporting it.

If I have a Java source file (*.java) or a class file (*.class), how can I convert it to a .exe file?  I also need an installer for my program.


I am a student and I had this question asked in my viva voce today and I hadn't even heard about it before.  I have searched over the internet about it and I always found the results to be very confusing and hard for me to interpret and understand.  Please, can any veteran present on this community explain it to me in a simple language.  I don't want to ask for any spoonfeeding but I tried my best to search for it and just couldn't understand a thing.  Please, explain it to me in a simple language(I am good at programming, but yet I found this concept hard to understand).

When is it a good idea to use factory methods within an object instead of a Factory class?


I don't know exactly which one is more official and correct? Master's Student Masters Student MSc Student   What is main difference?

The question asks it all really. When referring to a master's degree, do you use an apostrophe or not? That is, is it "a master's" or "a masters"?


The serial number on my haro frame is RVW1K00270. it is a bmx frame, i wanted to try find out which model and year is it please?

I have a BMX forsale, but I would like to know what make the frame is so I can determine how much it is worth. Does anyone recognise this symbol on the frame?  Thanks for your help Jon


I am trying to go in this direction only. Is this proof correct? ($A$ is an $m \times n$ matrix).   I am considering the contrapositive of the statement:  Suppose $A^TA$ is singular.  Then $\det (A^TA) =0$.  $\det(A^TA) = \det(A^T) \det(A)$ and since $\det (A^T) = \det(A)$, we must have $det(A) = 0$. In other words, the columns of $A$ are linearly dependent.   $\blacksquare$

How can I understand that $A^TA$ is invertible if $A$ has independent columns? I found a similar , phrased the other way around, so I tried to use the theorem  $$ rank(A^TA) \le min(rank(A^T),rank(A)) $$  Given $rank(A) = rank(A^T) = n$ and $A^TA$ produces an $n\times n$ matrix, I can't seem to prove that $rank(A^TA)$ is actually $n$.  I also tried to look at the question another way with the matrices  $$ A^TA = \begin{bmatrix}a_1^T \\ a_2^T \\ \ldots \\ a_n^T \end{bmatrix}   \begin{bmatrix}a_1 a_2 \ldots a_n \end{bmatrix} = \begin{bmatrix}A^Ta_1 A^Ta^2 \ldots A^Ta_n\end{bmatrix} $$  But I still can't seem to show that $A^TA$ is invertible. So, how should I get a better understanding of why $A^TA$ is invertible if $A$ has independent columns?


I'm looking for a suitable word or expression, for someone who really loves to learn, search and read about new things (Technologies, science, economics, politics..), so that his passion is only to acquire more knowledge.

Is there a term that means "a person who enjoys learning"? This term might be used to describe someone who:   Is a self-motivated learner. Is curious, wants to understand many things.   I understand the term "philosopher" might be a good fit, in terms of its root words, however, the general population has an inconsistent understanding of this term, so I am looking for a more precise term.


I just logout to see what will the home page look like. Now, I can't login into my local site.

I moved my site from one server to another in the same way I moved another site. But it won't get out of maintenance mode.  I can access phpMyAdmin and I can access the server files easily.  I've tried /user and /q=user.  Any suggestions?


I have a mysql table customer, column reference. 1000 lines of data  There are alot of reference data. 'Customer credit note XXXXX' I want to replace 'Customer credit note'  with ''  How do I do that?

What MySQL query will do a text search and replace in one particular field in a table?  I.e. search for foo and replace with bar so a record with a field with the value hello foo becomes hello bar.


I've seen several questions similar to this one, but mine is how I can protect my PDF:   Extract contents. Print. And, eventually, customize all the meta tag.

My questions is very simple. How can I set security setting for a PDF file created with PDFLatex?  I should set some password or print permissions, etc.


I have an SSD with 2 partitions.  The first partition belongs to Windows 10 and it worked fine. I installed Ubuntu 15.10 on the second partition and it also works fine.  When I boot, grub is correctly displayed and shows both Windows and Ubuntu. If I select Ubuntu it can boot without issue and I can even access the Windows partition from Ubuntu, but if I try to boot Windows 10 it displays a black screen (like it will start normally) for a few seconds (perhaps 2 or 3 seconds) and then it goes back to grub without showing any message.

I installed Windows on my computer, followed by an installation of Ubuntu. However, now I'm unable to boot into my Windows install.  What can I do to fix this?


I am trying to publish maps from QGIS Map Composer.  I would like to automatically add the credits of the background layers displayed in the composition (like OSM, Bing, ...)  I am aware of such a feature in main QGIS window using  View -> Decorations -> Copyright label but    this data is not shown in composer I am looking for an expression to adapt the text depending of the active layer    (Currently using either qgis 2.18 or 3.4)

I am using OpenStreetMap as a base layer via XYZ tiles in QGIS 3.01.  I can't seem to find a way of having source acknowledgement appear on the lower right corner of the map.  Can somebody point me in the right direction?


I have upgraded my Ubuntu 16.04 to 18.04. System upgraded successfully but graphics is not coming properly. After that run some commands for resolved graphics issue. But not corrected. Now the system is running but showing a blank screen with cursor blinking. Created users show and type the password for login but not getting login. Please help me. How to take backup my data?

For some reason I can't boot my system. I get an error akin to Operating System Not Found.   I tried bootrepair, and that didn't work. So then I decided I would just save my personal files, wipe everything, and reinstall.   But in the live session, when I go to the /home directory, my username folder isn't there, instead it goes to the Live CD's desktop and other directories. Is there some other error occurring? Is there a way to recover the files?


Indefinite (and definite) articles are sometimes associated with a person's name.  is the best summary of the uses I have found.  Also,  addresses the issue that was not mentioned in the summary with the example sentence "when a defeated Napoleon rode off the battlefield and into exile", and it is followed by a couple of useful answers.  My question is related to the latter.  Let me add three more examples to clarify the point.   "muttered a startled [Michael] Fallon" (Author  or ) "an elated Sarah Storey after her victory" () "one photo showing an unsmiling Francis standing next to a beaming Trump" (   In any of these cases, as well as the Napoleon-related example, the person(s) referred to is precisely specified in the text and only one in the world.  I have heard of a hypothesis (from a friend) people sometimes use an indefinite article before a particular person's name when it is accompanied with a preceding modifier, which tends to be (though not necessarily limited?) the present or past participle form of a verb; in other words, the modifier is sandwitched between the article and person's name.  All the cases listed above fit the hypothesis and the modifiers are "startled", "elated", and "unsmiling" and "beaming".  If this hypothesis is correct, there is no expression like "a John Smith delighted with blah-blah" (as long as the referred John Smith is already narrowed down to a particular person in the given context).   to the aforementioned question explains     It's a literary/oratorial device. You certainly wouldn't often come acrosss it in normal speech - only somewhat flamboyant prose or speechifying.      Think of it as meaning that Napoleon is a man of many aspects, victorious on other occasions, but defeated this time. Using the article implies that this is only one of several possible Napoleons that have or will exist.   The first part fits my little Googling research; it seems this use of the indefinite article is more commonly seen in novels and fictions than other types of writings.  Applying the second part to my examples, the three example sentences are interpreted as "Fallon/Storey/Francis/Trump is a person of many aspects, but in this case s/he is only one (=startled/elated/etc) of several possible Fallon/Storey/etc", which seems fitting.  Now I am asking for further clarifications:   What is the condition where this use of an indefinite article is accepted?  Is the above-mentioned hypothesis (i.e., always(?) having a modifier in between) correct?  Are standard adjectives like "happy", as opposed to verbs in conjugation, accepted for it? What is the nuance of the expression?  Specifically, what is the difference from the phrase without an indefinite article? For example, how about "'blah-blah', muttered startled Fallon"? I think the definite article "the" would feel a little unnatural in this case, as explained in detail in .

I noticed an infinite article; ‘a’ was used before ‘defeated Napoleon’ in the following sentence of Jeffery Archer’s novel, "Fales Impression" :  “General Sir Harry Wentworth sat at the right hand of the Iron Duke that night, and was commanding his left flank when a defeated Napoleon rode off the battlefield and into exile."  I’m curious to know why it should be “a defeated Napoleon,” not “the defeated Napoleon” or simply “defeated Napoleon.” Isn’t it only one Napoleon who was defeated the battle and exiled (to St. Helena). It looks like as though there were many (defeated) Napoleons who were exiled.  It’s always headache for me to handle articles as we Japanese (I think Chinese too) don’t have article as the basic part of speeches in our language system. I’ve studied it on English grammar text books at school, but have never reached full understanding of the usage of articles, because we don’t have that practice. Is there any special knack to master how to use articles?


I've just shown for a homework problem that if $f$ is an open continuous function from $X$ onto a $T_2$-space $Y$, and $X$ is locally compact, then $Y$ is locally compact. I wonder, does this hold for closed continuous functions too? Intuitively, I want to say no, but I'm not sure if I can find a counter example. Am I correct? How can I prove / disprove it?

If $X$ is locally compact and $f : X \rightarrow Y$ is continuous closed and surjective, must $Y$ be locally compact? This seems like it should be relatively simply to answer, but I am unable to find either a proof or a counterexample. Any ideas?


I made a simple code whis keeps adding 0.1 to zero. this is the code:  static double num = 0;     public static void main(String[] args) {         num+=0.1;         System.out.println(num);          try {             Thread.sleep(100);         } catch (InterruptedException e) {             e.printStackTrace();         }         main(null);     } }   This is what it outputs:  0.1 0.2 0.30000000000000004 0.4 0.5 0.6 0.7 0.7999999999999999 0.8999999999999999 0.9999999999999999 1.0999999999999999 ...   But I want the output to look like this:  0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 1.1 ...   Any ideas why it does that or how to fix it please?

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


Here is my code:-   package com.example.covid19;      import androidx.annotation.NonNull;     import androidx.appcompat.app.AppCompatActivity;        import android.content.Intent;     import android.os.Bundle;     import android.view.MenuItem;     import android.widget.TextView;      public class DetailActivity extends AppCompatActivity {          private int positonCountry;         TextView tvCountry,tvCases,tvRecovered,tvCritical,tvActive,tvTodayCases,tvTotalDeaths,tvTodayDeaths;          @Override         protected void onCreate(Bundle savedInstanceState) {             super.onCreate(savedInstanceState);             setContentView(R.layout.activity_detail);              Intent intent= getIntent();             positonCountry=intent.getIntExtra("position",0);               getSupportActionBar().setTitle("Details of "+AffectedCountires.countryModelList.get(positonCountry).getCountry() );             getSupportActionBar().setDisplayHomeAsUpEnabled(true);             getSupportActionBar().setDisplayShowHomeEnabled(true);               tvCases=findViewById(R.id.tvtotalCases);             tvActive=findViewById(R.id.tvActive);             tvCountry=findViewById(R.id.tvCountry);             tvCritical=findViewById(R.id.tvCritical);             tvRecovered=findViewById(R.id.tvRecovered);             tvTodayCases=findViewById(R.id.tvtodayCases);             tvTodayDeaths=findViewById(R.id.tvTodayDeath);             tvTotalDeaths=findViewById(R.id.tvtotalDeaths);               tvCountry.setText(AffectedCountires.countryModelList.get(positonCountry).getCountry());             tvCases.setText(AffectedCountires.countryModelList.get(positonCountry).getCases());             tvActive.setText(AffectedCountires.countryModelList.get(positonCountry).getActive());             tvCritical.setText(AffectedCountires.countryModelList.get(positonCountry).getCritical());             tvRecovered.setText(AffectedCountires.countryModelList.get(positonCountry).getRecovered());             tvTodayDeaths.setText(AffectedCountires.countryModelList.get(positonCountry).getTodaysDeaths());             tvTodayCases.setText(AffectedCountires.countryModelList.get(positonCountry).getTodayCases());             tvTotalDeaths.setText(AffectedCountires.countryModelList.get(positonCountry).getDeaths());     enter code here              }          @Override         public boolean onOptionsItemSelected(@NonNull MenuItem item) {             if(item.getItemId()==android.R.id.home)                 finish();             return super.onOptionsItemSelected(item);         }     }   Cause of the error:- Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.widget.TextView.setText(java.lang.CharSequence)' on a null object reference         at com.example.covid19.DetailActivity.onCreate(DetailActivity.java:41)  The Error is in line which is in Bold

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


I have been taking math and going through various forms of factorials for the purposes of probability, but I have not been able to find a conclusive reason as to how one accounts for 0!  I am not sure if there is a way to solve it?

How can I prove  from first principles that $0!$ is equal to $1$?


I'm new to PHP and was wondering why my like query is only returning one value.  Here is my Model   //For search public function getSearchResults($username){     $stmt = $this->_connection->prepare("SELECT * FROM users WHERE username LIKE :username");     $stmt->execute(['username' => '%'.$username.'%']);     $stmt->setFetchMode(PDO::FETCH_CLASS, "User");     return $stmt->fetch(); }   Then in my controller  function search($name){      //Get search results     $searchResults = $this->model('User');     $searchResults = $searchResults->getSearchResults($name);     $data = (array) $searchResults;      $this->view('User/search', $data); }   However, it is only returning 1 result rather than 3. (I have 4 usernames with "hi" inside it, but it's only returning one)

Here's my attempt at it:  $query = $database->prepare('SELECT * FROM table WHERE column LIKE "?%"');  $query->execute(array('value'));  while ($results = $query->fetch())  {     echo $results['column']; }


I am writing my thesis and came to a problem that I have no idea how to solve it. The problem is explained as following:   My thesis has a TOC and LOF and LOT. As some of the figures are referenced to sources their citation were appeared in the LOF. I used \caption[text in LOF]{text in caption \cite{author:20xx}} and the numbers are disappeared from the LOF. However, in the chapter one of my diss., the first reference is numbered to [14], which is totally not desired.   My question: Is there any way to reset the number of citation from chapter one? I also tried \bibliographystyle{unsrt} in my config file.  regards AM

When using the \cite command in figure captions and the ieeetr bibliography style, then  BibTeX numbers the citations as appearing earlier than they do in reality (i.e. the first citation in the document ends up being [42]).  Is there any way to get BibTeX to ignore the \listoffigures section when numbering?


When I cast the double value 44.000000 to int, I get the desired value of 44. But, When cast the same double value (44.000000) that was derived by some arithmetic operations to int, I get 43. How can I get rid of this problem and get 44 instead of 43 in the second case? Below is the code I used, #include<stdio.h> #include<math.h>  int main(){      double newd = 44.00;     printf("Simple Direct Conversion: %d\n\n", (int)newd);      double d = 100.44;     double decPart;     double fracPart = modf(d, &decPart);      printf("Original Values:      %lf - %lf\n", decPart, fracPart);     printf("Multiplied by 100:    %lf - %lf\n", decPart * 100, fracPart * 100);     printf("Converted to Integer: %d - %d\n", (int)(decPart * 100), (int)(fracPart * 100));      return 0; }  and the output is,  Simple Direct Conversion: 44 Original Values:      100.000000 - 0.440000 Multiplied by 100:    10000.000000 - 44.000000 Converted to Integer: 10000 - 43


I'd like bash history to behave like vim's, i.e., if I start typing a command and then press the up arrow, it completes to the last command that that shares the initial string with my incomplete input. I think zsh does it but I'm only interested in bash.  Say my latest commands are  vim bubi.txt killall firefox   If now I type v and then the up arrow the command line switches to killall firefox, while I'd like it to skip to vim bubi.txt.

On the bash command-line, ↑ gives me the previous command. On the command-lines in ipython or matlab, when I type a few characters, ↑ gives me the previously entered command starting with those characters. How can I enable exactly this behaviour in bash? I am aware of more advanced ways of searching through the command-line history, but sometimes a simple way is more convenient.


The task is to write a function that receives two portions of a path and joins them. The portions will be joined with the "/" separator. There could be only one separator and if it is not present it should be added.  Example:     joinPath("portion1", "portion2") ➞ "portion1/portion2"      joinPath("portion1/", "portion2") ➞ "portion1/portion2"      joinPath("portion1", "/portion2") ➞ "portion1/portion2"      joinPath("portion1/", "/portion2") ➞ "portion1/portion2"   My code:  public class Challenge {     public static String joinPath(String portion1, String portion2) {         return (portion1.substring(portion1.length()-1) != "/" && portion2.substring(0,1) != "/")              ? portion1 + "/" + portion2 :              (portion1.substring(portion1.length()-1) == "/" && portion2.substring(0,1) == "/")              ? portion1.substring(0) + portion2.substring(1) :              portion1 + portion2;     } }   I know the code seems complex but the demand of the question was to try to solve it without if-else conditions. I don't know why my code is failing almost all the tests.   I think I made a silly mistake. Can someone please point out the error? Also, is there a better way I can solve this question without using if-else conditions?

Is there a Java equivalent for  in C#/.NET? Or any code to accomplish this?  This static method combines one or more strings into a path.


I'm a complete beginner so I really don't know what is happening.

I think my question relates to a fundamental of 3D modeling that I haven't picked up on yet. It's very simple:  Let's say I have a flat quad. A plane on the XY plane inserted into am empty blender file is a great example. Now let's say I start moving each of the 4 vertices around on in any direction, especially the Z axis.   At this point, there would still be one face, but its extremely unlikely that the face would be planar (I just learned this word). So blender does its best to make sense of what this should look like.  The problem I'm having is that it seems like my quads are always like this, but they never look the way I want. There are edges and seams that look like they are dangling in space, and what tends to happen is that my mesh looks great when viewed from most angles, but if you look at it from just the right angle, you notice the dangling edges or sometimes even some kind of impossible geometry. And so I might try to nudge the problematic vertices around, but this often seems to either make it worse, or just hide the bad geometry until you see it from a different angle.  For me, this always seems to happen whenever I'm trying to move vertices to add roundness to something that is originally square.   There is another question on here about how to actually flatten the quads. That's great, and I might use some of the techniques mentioned there. My question is:   Why does this happen? (Can someone explain this better?) What are some tips and tricks to avoid this situation? What are some tips and tricks to mitigate this situation?   EDIT Here is an illustration:  The overall mesh as viewed from a distance looks decent (for my skill level)    But if you get closer and look from a certain angle...    Super close up:    The "edge" that is pointed to by the arrow is not actually an edge, but some kind of artifact created when blender tries to show the quad. The way the vertices are positioned, it shouldn't actually be possible to see the sliver of the face that I marked in red, since this face is supposed to be around the corner from the edges. The edges should form the silhouette on the right side of my figure.     Here is the side view. Maybe it is the angled topology that skews the face in a funny way?  But I'm not looking for help with this one particular issue, but rather a better understanding of why this happens, and ideas to prevent this in future models.


one of my site hacked few times :( first I lost all databases, some tables were cleared and some of table's data had changed! than at the second hack, all tables were cleared and some php files' codes had been changed :/   it is hosted in Bluehost, and now they advise me some fixing;        Fix any loose file permissions (this may be the most common exploit   vulnerability)   Delete all non-system Ftp Accounts that were created, or at the very   least, change the passwords to the FTP   Accounts.   Remove any Access Hosts by clicking the “Remote Mysql” icon and clicking   the Remove Red X by each entry if   there are any entries.   Check your scripts for any Header Injection attacks, Sql Injection   attacks, Cross-Site Scripting attacks,   etc., as well as your php.ini file   settings.   If your scripts are infected, you may want to rollback to the last good   snapshot backup of your account. If   your backups are also infected, then   you may want to consider having us   reset your account to start afresh.      I tried to do all these as much as I could, especially about "Header Injection attacks, Sql Injection attacks, Cross-Site Scripting attacks, etc., as well as your php.ini file settings". I'm kind of beginner at this work, so I dont have fully control on thiese things...  my question is; is there any way to find out how I was hacked? What was the weak point?

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


Is there an irreversible process, where the entropy of the isolated system does not change?

My question is very similar to , but I decided to ask another question because I felt that the problem deserved to be addressed in a more specific and formal way and I also wanted to discuss a specific example.  Let's start from Clausius' inequality.  For a reversible transformation between the points $A$ and $B$ we have  $$\Delta S_{AB} = \int_A^B \frac{\delta Q}{T}$$  While for an irreversible transformation we have  $$\Delta S_{AB} > \int_A^B \frac{\delta Q}{T}$$  For an adiabatic process, $\delta Q =0$.   Is thus easy to see that  $$\text{adiabatic}+\text{reversible} \Rightarrow \text{isentropic} \ (\Delta S =0)$$  and  $$\text{adiabatic}+\text{irreversible} \Rightarrow \Delta S >0$$  My question is:   Is   $$\text{adiabatic}+\text{isentropic} \Rightarrow \text{reversible}$$  also true?  I think that this is not true in general because for a general process we have  $$\Delta S_{AB} \geq \int_A^B \frac{\delta Q}{T}$$  If the process is adiabatic and isentropic, we obtain  $$0 \geq 0$$  which is trivially verified and tells us nothing about reversibility or irreversibility.   I would also like to bring a possible example of an adiabatic, isentropic transformation which is also irreversible.  I'll start by remarking two facts upon which I hope we agree:   A non quasi-static transformation cannot be reversible. Quasi-staticity is a necessary condition for reversibility. Since entropy is a state function, every cyclical transformation is isentropic.   Let's take an ideal gas enclosed in an adiabatic vessel with an adiabatic movable piston. From the initial state $(P,V,T)$, where $P$ is the ambient pressure (we suppose that the weight of the piston is negligible), we irreversibly (i.e. non quasi-statically) push the piston downwards, taking the system to the state $(P',V',T')$. Now we irreversibly (non quasi-statically) pull the piston back to its original position so that the final volume is $V''=V$. Since $P''=P$ also (because the pressure must be equal to ambient pressure in order to have mechanical equilibrium), from the ideal gas law $T''=T$, so we have performed a cyclical, adiabatic, irreversible transformation.  PS: In case of positive answer (adiabatic+isentropic implies reversible), it would be best if the answer pointed out the flaw in my example but provided also a formal proof of the above-mentioned implication.


I need a simple video editor, just pasting several video files in mov format and producing mp4. tried openshot and pitivi and they keep crashing and cannot produce anything. quite pathetic.

What video editing software would you recommend on Ubuntu (or Linux in general) and why?  It can be for either beginners or experienced users.  Please only place one piece of software per response and include details to what makes it great!


I have just installed Ubuntu 16.04 on a machine. When I try to boot I get sent to grub, and entering the following commands allows me to boot correctly:   set root=(hd0,4)    linux (hd0,4)/boot/vmlinuz-4.13.0-38-generic root=/dev/sda4   initrd (hd0,4)/boot/initrd.img-4.13.0-38-generic   boot   I have gone into the system, run an update, run sudo update-grub (no errors), shut down and booted back up. I still get sent into grub rather than straight to ubuntu. What is going wrong?

I have a vps using Ubuntu 12.04 LTS and I my host corrupted my vps so now it won't boot up. When it boots up it says:  Booting from Hard Disk... error: file not found. grub rescue>   How can I fix/repair this?


Prove that the repeated sum of the digits of a perfect square can only be 1,4,7 or 9. Example- 169- Sum-16, Sum of digits of 16 = 7. Please try to explain without log, mods. I am a grade 10th student. Thank You.

Prove that the sum of the digits of a perfect square can't be 2, 3, 5   , 6, or 8.   I'm completely stumped on this one, how would I go about proving it?


I am a beginner in java programming. I am trying to develop a program but when I ran my program which is posted below and it came back with this error:     Exception in thread "main" java.lang.NullPointerException       at dist.main(dist.java:13)   import java.lang.Math; class Point {      int x;   int y; }  public class dist {     public static void main(String[] args) {             Point[] pt = new Point[3];         pt[0].x = 40; pt[0].y = 40;         pt[1].x = 40; pt[1].y = 30;         pt[2].x = 26; pt[2].y = 30;  for(int i = 0 ;i < pt.length ; i ++){          pt[i] = new Point(); }           int ux = pt[0].x - pt[1].x;         System.out.println("ux:" + ux);          } }

What are Null Pointer Exceptions (java.lang.NullPointerException) and what causes them?  What methods/tools can be used to determine the cause so that you stop the exception from causing the program to terminate prematurely?


This is a question as much about color perception as the physics of light. Since I have normal vision, without color blindness, I will draw on my experiences in formulating my question. I will add that this is similar to an existing question, but I am not satisfied with the answer.   Our eyes have sensitive rod cells that roughly act as our black and white vision, as well as less sensitive cone cells which distinguish color. Three sets of cones exist, responding to red, green, and blue light. Their frequency responses, pictured below, explain how we can perceive colors like yellow and cyan. If yellow light reaches our eye, the red and green cones will both respond, perceived as yellow. If both red and green light reaches our eyes, the red and green cones will both respond, so while the physical phenomenon is different, two wavelengths of light instead of just one, the perception is the same, yellow. The same is true for cyan with green and blue light. There seems to be a lot of confusion concerning pigmentation. My understanding is that a cyan pigment will absorb a range of wavelengths around red light and a yellow pigment will absorb a range of wavelengths around blue light, so what is reflected back is a mixture of green and blue for cyan or red and green for yellow. A red pigment, then, absorbs wavelengths covering across green and blue, similar is true for other primary color pigments.  Things get confusing with magenta however. A magenta pigment will reflect light that stimulates our red and blue cones, therefore magenta pigments must absorb wavelengths around green. This makes good sense so far. However, what about purple light? Purple light is weird because it's of an even shorter wavelength than blue light. You'd expect it to just be blue, and maybe a bit darker than you were expecting.  My experience with a violet laser pointer: My friend has a violet laser pointer, a relatively pure single wavelength. It's a very strong laser, similar power to his green one which is extremely bright, but the spot is very faint, yet definitely purple. It seems like my suspicions about short wavelengths appearing darker than expected are true, but it isn't a dark blue, it's a dark purple.  Obviously there's some difference between violet and magenta other than how bright they are. If I were to guess, I'd say the violet light stimulates the blue cone most and the red one little to not at all, while magenta colors (wavelength mixtures) stimulate blue and red simultaneously. Okay, but then how is the violet light reproduced on a computer screen with blue and a little bit of red? If the slight amount of red light is important to our perception of violet, then it seems like blue light might seem more violet (red/blue mixed) to us than violet (single wavelength).  Now, you see, my head is melting. Can we finally get a satisfying answer on how we perceive purple light and how that fits in with the physics of light and pigments?

When people are asked to match monchromatic violet light with an additive mix of basic colours, they (paradoxically) mix in red.  In fact, the CIE 1931 color space chromaticity diagram shows this effect begins at about 510nm (greenish-cyan), where people mix in no red.  From that point on, the higher the frequency of the light source, the more red they mix in.    This effect is reflected by the red curve of the , which has an additional bump in the area of blue light.  However, that curve does not match the actual spectral sensitivity of red cones.  So where does this additional perception of red at higher frequencies come from?


My task is to prove that:  Given $E_1 \supset E_2 \supset E_3 \supset ...$ is a decreasing sequence of set with the form $E_k =  (-\infty, t_k]$ which is an interval in $\mathbb{R}$ and we have $\lim \limits_{k \to \infty} t_k = -\infty$. Prove that: $\mu(\bigcap \limits_{k = 1}^{\infty} E_k) = 0$ with $\mu$ is a probability measure.  My attempt was to claim $\bigcap \limits_{k = 1}^{\infty} E_k = \lim \limits_{k \to \infty} E_k = \lim \limits_{k \to \infty}(-\infty, t_k] = (-\infty, \lim \limits_{k \to \infty} t_k] = (-\infty, -\infty]$ and that $\mu((-\infty, -\infty)) = 0$ which leads to the proof. But it seems to me there isn't notation of limit of intersection of a sequence (the first "$=$" in my proof above), as well as I'm not sure if we can write $\lim \limits_{k \to \infty}(-\infty, t_k] = (-\infty, \lim \limits_{k \to \infty} t_k]$ (it seems wrong). Could you please have a look at my proof and tell me if it is true or not ? If it is not, could you please give a brief sketch of the proof ?

One of the consequences of the axioms of probability ($\sigma$ field and probability axiom) is the "infinite subset" and "infinite union" property, I can't figure out how it follows from them.  if $A_1 \subseteq A_2 \subseteq \cdots$ then   $$P\left(\bigcup_{i=1}^{\infty}A_i \right) = \lim_{k \to \infty} P(A_k)  $$  If $A_1 \supseteq A_2 \supseteq \cdots$ then   $$P\left(\bigcap_{i=1}^{\infty}A_i \right) = \lim_{k \to \infty} P(A_k)  $$


I'm still using Ubuntu 19.04 because it's what was current when I installed the OS but it is no longer supported so I want to upgrade to 20.04 LTS (or even just 19.10).  This should be very simple. There are loads of tutorials on how to upgrade from from 19.10 or 18.04 to 20.04. But it seems like it's not possible from 19.04. Could this be true?  If I run sudo apt upgrade I get a bunch of 404 errors because the disco archives don't seem to exist anymore. But I ran:  $ sudo apt dist-upgrade Reading package lists... Done Building dependency tree Reading state information... Done Calculating upgrade... Done 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.  $ sudo do-release-upgrade Checking for a new Ubuntu release Your Ubuntu release is not supported anymore. For upgrade information, please visit: http://www.ubuntu.com/releaseendoflife  Please install all available updates for your release before upgrading.   I tried  $ update-manager -c   And it told me I was no longer supported and needed updates but when I said "ok" to installing updates it gave me the exact same error.  I'm not sure what to do here. I can't update any more because I can't apt update. I guess I could manually set all my apt repos to the Eoan Ermine ones and update again. Is that what I need to do? Where do I set that?

Recently I have installed an older version of Ubuntu on my old machine. Whenever I try to install any software, I get an error saying it couldn't be found:  $ sudo apt-get install vlc Reading package lists... Done                Building dependency tree        Reading state information... Done     E: Couldn't find package vlc


Note that in this question, I will use the word non-integers to mean all rational non-integers. I've been working on problems on non-integers lately, and a few thoughts popped into my head.  How do you define non-integers as even or odd?   How do you define non-integers as prime or composite?  I thought of some of the possibilities. Do you round to the nearest integer and define parity on that? Do you take away the decimal point to find primes and composites? Or are non-integers described as neither even or odd, neither prime or composite? Any help on this would be appreciated greatly.

Is the concept of even/odd numbers applicable to decimal numbers? For e.g. - 4.222 is a even number?


I had my singleton class initially like this   private static MqttHandler instance = new MqttHandler();  private MqttHandler(){};  public MqttHandler getInstance(){     return instance;  }   Now in one phone it was working as expected, but in another, seems like it was creating many instances, since whenever I tried to log something, it did log multiple times. I have no idea why.  The second time I tried using this    private MqttHandler instance;   private MqttHandler(){};   public MqttHandler getInstance(){       if(instance==null) instance == new MqttHandler();       return instance;   }   Seems to be working, at least for now, not sure if its going to crash later, Does this mean that, in my first method, whenever I returned instance, it was calling   new MqttHandler();   thus creating new instances all the time? Why would it work on one device correctly, and then refuse completely on a different one?

What is an efficient way to implement a singleton pattern in Java?


I search for: title:change - I get results I search for: title:chang* - No results I search for: chang* - I get results (body & title)  Wildcard searches in the title should work or the text of  info page should be changed.

I am trying to find all questions that meet certain criteria and contain Matlab in the title. My original attempt was this:  title:"matlab" -[matlab*] is:question closed:no answers:0   However, it turns out this does not contain all results, for example not the ones containing matlab: (with colon). After this I tried various things including:  title:"matlab*" -[matlab*] is:question closed:no answers:0   But the only way to find this result was by using a colon in the search query. As a result I don't know whether I am missing other results, for example with matlab- or MatlabToolbox in the title.    So my question is: Can we get all results containing a certain word in the title?    I have searched around for a while but have found mostly questions about using wildcards in tags. The closest I have come is this:   However, this question is different as it recommends "keyword" to find "keyword{punctuation}", whilst I would expect it to work at least for "keyword{wildcard}"


I am thinking of switching to Ubuntu Linux from Windows 10, but I still want to dual boot windows. I plan to dual boot by installing Windows 10 first because I was recommended to with Ubuntu later. I am using a 1TB SSD and a 2TB HDD and I wanted to ask how I could install my applications to my HDD. In windows, I could have the user directory (documents, downloads, videos, etc) and some applications allowed me to choose where to install. Is there something similar to this where I can have my documents and downloads as well as my applications in my separate 2TB HDD? I want to keep my SSD relatively clean.

I'm a new Linux user and a Windows convert. I tried Ubuntu (Dapper Drake) a few years ago and liked it quite a bit, and I'm in the process of installing Xubuntu 13.10 along side Windows7 on my brand new SSD! At this point, Windows is still being installed because I need it to be, but Linux is getting installed because I want to use it! I've done quite a bit of research and I've toyed around with Linux before, but I'm still a newbie and I have a few questions concerning partitions and program installations..  My new SSD isn't huge (120GB Samsung 840 EVO), and I'll be using my old 800GB HDD as a secondary drive. The thing is, I plan on using Linux as much as possible; only switching over to Windows7 when I absolutely need to. Because of this, I'll be doing a 50:50 split of my SSD for each OS (60GB for Linux, 60GB for Windows). I'm also planning on splitting my old, 800GB HDD into 3 partitions: some space for extra linux programs, some space for extra windows programs, and then a shared NTFS partition for all of my data (music, videos, documents, etc.).  So to sum up my space situation:   ~60gb SSD + 200gb HDD for Linux..  ~60gb SSD + 200gb HDD for Windows.. ~400gb shared NTFS..   This leads me to my questions.. While I have a fairly good idea of how my Windows setup will work (60gb C: drive, 200gb D: drive, etc.), the Unix/Linux directory structure is still very new to me and is making this process a little bit confusing. I know that it's possible (and common) to partition your "/" directory and "home" directory separately, and - as I understand it - the "/" partition is meant to contain system specific programs and data, while the "home" partition contains the programs and data of the various users.  However, I've also heard that most (if not all) of the programs that you install from repositories using APT are installed into the "/" directory. As someone who works with music/art programs and plays games (which can take up a LOT of space), this leads me to believe that I'll need a large "/" partition!  I've also read (from here: ) that the "home" directory is "the place where all the user-specific files, your data in other words, are stored. It is roughly equivalent to the “My Documents” folder on a MS Windows desktop". But, as I mentioned above, I intend to keep all of my non-OS-specific data (music, documents, videos, etc.) on my ~400gb shared partition, anyway. This really leads me to believe that I don't need a big home partition at all and that I should focus on partitioning as much space as possible for "/". And still, I've heard other people claim that you only need around 10gb of space for your root partition!?   Edit: Also, I just found out that programs like Steam and Wine take up space inside the "home" directory.  So, what should I do? I basically have 60gb SSD and 200gb HDD space for holding nothing but Linux programs. All of my data will be going onto my 400gb shared NTFS partition, so is it even worth making separate partitions for "/" and "home"? If I install both root and home on my 60gb SSD, how can I also use the extra 200gb of HDD space for more Linux programs? Can I expand root across multiple drives somehow, or maybe have a symlink or something that connects the two drives together?  As I said before, I'm still a major Linux newbie, so there may be something that I've completely misunderstood or overlooked. As someone who does a lot of art/music creation and gaming on my PC, I tend to use up a lot of program space quite quickly, especially since games and music libraries just keep getting bigger and bigger every year! Thanks for the help, I'm looking forward to learning more about Linux! :]


We need to use contour integration to solve $$\int_{-\infty}^\infty {e^{ax}\over e^x+1}dx$$ given that $0<a<1$. My question is about what contour to use, knowing that the singularities are at $z=i(2n+1)\pi$. I tried the standard D-shaped contour in the upper half plane, but I'm not being able to show that the integral will vanish along the semi circular curve as R goes to infinity.

I'm trying to compute $\displaystyle \int_{-\infty}^\infty \frac{e^{ax}}{1+e^x}dx$, $(0<a<1)$ Let $f$ denote the integrand.  I'm using the rectangular contour given by the following curves: $c_1: z(t) = R+it, t \in [0, 2\pi]$ $c_2: z(t) = -t+2\pi i, t \in [-R, R]$ $c_3: z(t) = -R + i (2\pi - t), t \in [0, 2\pi]$ $c_4: z(t) = t, t \in [-R, R]$    There is one singularity within the contour, at $z = \pi i$. Expanding out the denominator as a power series shows that it's a simple pole, and allows us to evaluate the residue as $\displaystyle \lim_{z \rightarrow \pi i} f(z)(z-\pi i) = - e^{a \pi i}$    This is computed by expanding $1+e^z$ as a Taylor series around $\pi i$. The first coefficient will be 0, and the second will be $-1$. The rest will have orders of $(z - \pi i)$ greater than 1, and will thus vanish when we take the limit.  So the integral over the entire contour is $- 2\pi i e^{a \pi i}$    An easy enough estimate on the $c_1$ shows that the integral vanishes as $R \rightarrow \infty$. With a variable change, c_3 is the same as c_1 and also vanishes. $c_4$ becomes the integral we want when we take a limit. $c_2$ becomes $c_4$ with a constant:    \begin{align*} \int_{c_2} f(z)dz &= \int_{-R}^{R} \frac{e^{-at}e^{a 2\pi i}}{1+e^{-t}e^{2\pi i}}dt \\ &= e^{a 2 \pi i}\int_{-R}^{R} \frac{e^{-at}}{1+e^{-t}}dt \\ &=e^{a 2 \pi i}\int_{R}^{-R} - \frac{e^{au}}{1+e^{u}}du \ \ \ (u = -t, du = -dt)   \\ &= e^{a 2 \pi i}\int_{-R}^{R} \frac{e^{au}}{1+e^{u}}du \\ &= e^{a 2 \pi i} I(R) \end{align*}    Where $I(R)$ is the line integral over $c_4$. Putting it all together and taking the limit gives us $\displaystyle \lim_{R \rightarrow \infty} I(R) = \frac{- 2\pi i e^{a \pi i}}{(1 + e^{a 2 \pi i}) }$    But this can't be the value of the integral, because it's a real-valued function integrated over $R$. I can't figure out where I'm going wrong. Note that I've avoided posting all the details of my solution since this is from a current problem set for a class on complex analysis.


without using the truth table:  Show that      $(p \to q) \vee (p \to r) \to (q \vee r)$ and $p\vee q\vee r$    are logically equivalent.

Without using the truth table, I need to prove:  $$\big((p\rightarrow q) \lor (p \rightarrow r)\big) \rightarrow (q\lor r)\equiv p \lor r \lor q$$  Up until now, we've been using truth-tables to verify equivalences. So I'm a bit lost on where to begin without using a truth-table.


so I tried to make my first animation in blender, but it does not want to start. Rendering animation did not work at start, so i was trying to figure out on my own and now I cant even render an image. All I can see when I press render or render animation is that in the picture below. I also provide link for my file, if anyone could take a look. 0

A scene I made is not rendering, at all. This grey screen stays the same and nothing changes.  Here are my settings:  [