Heisenberg’s uncertainty principle states that we cannot determine the position and momentum of a particle at a time. I think I have an idea to prove it wrong ( although I believe I must be wrong here) : Taking two electrons,, $e_1$ and $e_2$ in motion, we can determine the precise position of $e_1$ and the precise momentum of $e_2$. Since we know that the momentum of both electrons is mathematically related to each other, we could conclude that the precise momentum that we measured of $e_2$ is the same as that of $e_1$. Hence the position and momentum of $e_1$ is determined at the same time.

In principle, it is possible to entangle any property of two particles, including speed and momentum. Surely then, this could be used to defy the Uncertainty Principle, which states that the momentum and position of a particle cannot be together measured with accuracy, but the more accurate one gets, the less accurate the other becomes:  $$\Delta x\Delta p=\dfrac{\hbar}{2}.$$  If one was to set up an experiment where two particles are entangled, one could then measure the position of one particle with great accurary at the same time as measuring the momentum of the other particle with great accuracy, which would mean that, as the two particles are entangled, one would then know the momentum of the particle they measured the position of.  Therefore, the Uncertainty Principle would have been defied, as both momentum and position have been measured with a high accuracy.  However, this can't be true, as someone would have thought of this before.  So why wouldn't this work?


I’m nearly level 7 as an Eldritch knight. Because of that, I’m planning how to do the most damage as I can to defeat a very threatening and greedy party member so obviously being an Eldritch knight will probably help in this situation.   I’m planning out a move that uses a combination of my extra attack I got from level 5 as a fighter, and my action surge from level 2. If I was level 7 though, I would get to use war magic which states that I can use a cantrip and still have the ability to attack as a bonus action. I just don’t know if my extra attack applies to that bonus attack. Can anyone help me out here?

I am wondering about the wording here. On PHB p. 75, the description of the Eldritch Knight fighter's War Magic feature says:  When you use your action to cast a cantrip, you can make one weapon attack as a bonus action.  Does the Eldritch Knight's War Magic feature benefit from the Extra Attack feature, allowing them to make multiple attacks? I feel like the wording would have to be "you can take an Attack action as a bonus action" to have access to multiple attacks. But the current wording doesn't so I read this as not allowing multiple attacks. Am I right, or does War Magic allow the Eldritch Knight to benefit from the "Extra Attack" feature too?


I'm an avid bicycler who has just moved to the city (Boston). As I (unlike many folks here) am unwilling to run red lights and violate traffic laws, I often have to come to a stop, dismount, and wait for the light to go green.  I've seen bikers, especially those in full kit on nice bikes, manage to come to a stop and stay on their bike, out of their saddles for some time. I can't manage to do this for more than a few seconds, and with spd pedals I am unwilling to try too hard lest I tip over and eat shit as they say. The best I can do is to brake hard while pedaling slowly, inching forward. This buys me a few seconds, given I am on level ground and I have room.  I ride a touring bike with panniers, so sometimes I don't have equal weight distribution laterally. Sometimes I do, and I've always wanted to learn how to do that stop and stand thing.  Is there any trick to it or is it just about balance and weight distribution? Should I be breaking hard on front and rear?

I want to be able to do a . I can almost come to a halt on my bike without taking my shoes out the cleats - but not quite.   In theory, on a  it should be easier, but I can't quite manage to maintain position, I always find myself rolling forward.   So I'm looking for snippets of advice, without being able to see what I'm doing wrong, can anyone tell me something to do right so as to perform a decent track stand; on either a free or a fixed hub, advice for either is fine.   What's your secret?  I promise that I'll go out and practice somewhere quiet ...


I am making a profile card and I made div(.pic) in div(.profile-card) to let user show their profile photo. and i found weird margin at the right of the .pic Do you know why?   body {   height: 100vh;   background-color: #40407a;   padding: 0;   margin: 0;   display: flex;   flex-direction: row;   justify-content: center;   align-items: center; }  .profile-card {   background-color: #2c2c54;   display: inline-block;   padding: 30px 40px;   text-align: center; }  .pic {   width: 50px;   height: 50px;   border: 1px solid #33d9b2;   border-radius: 50%; } <!DOCTYPE html>      <meta charset="UTF-8">   <meta name="viewport" content="width=device-width, initial-scale=1.0">   <title>Document</title>   <link rel="stylesheet" href="style.css">

       Name here

How can I horizontally center a
 within another
 using CSS?

Foo foo


There is a similar post, but this one is slightly different. I have a csv file in which the second column contains some alphanumeric data. I need to delete this entire column and replace it with a new one. I need to do this for many files in the same directory. The files are named treatables-000.csv, treatables-001.csv, and so one. Here's an example : Original file:   t ,  group,     1 aaa,  baddata1,  bbb aab,  baddata1,  bbc ....... aaad  baddata2   bbb    Column 2 needs to be replaced with the columnp1,p2,p3,... p20,p1,p2,... It should be of the same length as the original. How can I do this using the command line? The files may all be of different length.

I have a csv file called scenario1.csv in which the second column has column names like "0-4 years high risk", "65+ years first responder" etc. There are 20 such values. The 21st row, 2nd column has the same entry as in the 1st row of the 2nd column. I would like to rename these values to p1-p20 respectively. So the 21st row would have the p1 tag with it. Everything without quotes. I have a 150 such files, named scenario1.csv, scenario2.csv ... How do I do this? Below is an example for a shorter file:  t,  group,               1,  3,  5 0,  0-4 years low risk,  0,  0,  0 0,  0-4 years high risk, 0,  0,  1 .....,  ....  0,  0-4 years low risk, 0,  0,   0   Expected output for each file:     t,  group,  1,  3,  5    0,  p1,     0,  0,  0    0,  p2,     0,  0,  0     .....,  ....     0,  p1,     0,  0,  0    Here's the dictionary I need:  0-4 years first responder   p1 0-4 years high risk         p2 ....... 65+ years low risk          p19 65+ years pregnant women    p20


Please tell me in detail about that. I need some reliable solution for my Mac OS X.

I have a lot of data on my macbook pro retina laptop and i am looking for the best backup strategy.  I have previously had a windows desktop with an external harddrive connected all of the time and a backup program that copied to the external harddrive incrementally.  I am trying to figure out the best backup strategy given its a laptop that i move around with and travel with alot (so can't really have a external hard drive always connected)  What is the recommended backup solution for map laptops?


Given a bounded set B of the complex plane, I want to prove that $f(z)=e^z$ maps $\Bbb C \setminus B$ ont $\Bbb C \setminus \{0\}$.   I have no idea where to start with this.   Does anyone have any recommendations on what theorems would be useful here ?

Prove that $f(z) = e^z$ maps $\mathbb{C} \setminus B $ onto $\mathbb{C} \setminus \{0\}$ where $B$ is a bounded subset of $\mathbb{C}$.  I have no idea how to even attempt this question so I would greatly appreciate some hints.


Is there a clever way to combine two or more geoJSON files? I would like to combine the two geoJSON files here:

I want OSM administrative boundaries from . I can get the geodata in different formats there, but the attribute data always is a separate JSON file. I want them both in just one file, or to be able to merge the information.   I haven't found a solution to merge the GeoJSON.   What's the workflow to get the two files joined and saved as a shapefile, for example?


I remember that 15 years ago I saw a movie where humanity found a cure for old age, but some people that used it turned to monkeys where other stayed alive.  Also, people had crystals that show something about their DNA and they were only allowed to mate with someone with the same crystal color or else their baby will turn to a monkey if he/she uses the old age cure  Do you know the name of this movie?

I'm trying to figure out the name of a movie I saw on TV as a kid, in the mid-to-late 90s, in the US, in English, on daytime TV.  I remember it being kind of Starship Troopers-esque, but everyone had these glowing lights in their chests.  They glowed in different colored patterns, and I think it had something to do with whether you were attracted to someone or not (I was probably like 7 when I saw it, I didn't really understand the context of that part yet).


I am trying to append a new row in a table with a variable   I used this line of code with no luck    $('.view-payments table').append('
Amount	' grandTotal '
');   What is the problem?

What is the best method in jQuery to add an additional row to a table as the last row?  Is this acceptable?  $('#myTable').append('
my data	more data
');   Are there limitations to what you can add to a table like this (such as inputs, selects, number of rows)?


After failing to update my desktop to Ubuntu 20.04.1 LTS (unable to boot, kernel 5 not working etc) I am going to replace my disk with a new disk and install Ubuntu fresh. I have a few question that I would appreciate advice:  Do I need to reformat the disk? I was planning to do it, but then I read that in the process of installation this can be done automatically.(  Do I really need a USB memory? or can I use another medium? perhaps the size of the image is too large and that is why I need a USB?  I am not planning on partitioning the disk. Should I?  My original problem was that apart from not booting, the Nvidia drivers were not correctly loaded and the GPU was not recognized. Any advice on how to avoid this problem?   Any other advice will be appreciated. First time I am doing this

This is the third time I've tried to install Ubuntu Server 14.04.03 64-bit on the same laptop, and each time it caused different problems.  Each time I wrote the same iso image to a USB flash drive by using a different application and OS.   Universal USB Installer (pendrivelinux.com) from Windows WinImage writer from Windows built-in image writer from Linux Mint 17.2    The iso image is the same in all three cases, the USB flash drive is the same, and the laptop is the same. However each time the installation of Ubuntu gave me different installation options. For example, the last time I installed Ubuntu, it didn't show all the packages to choose while installing (Basic Ubuntu server, etc.).


Assume $f:\mathbb{R}\rightarrow\mathbb{R}$ is continuous on $\mathbb{R}$ and such that $f(r)=0$ for every rational number $r$. Show that $f(x)=0, \forall x\in\mathbb{R}$ using the $\varepsilon-\delta$ definition of continuity.  I am attempting to do this by contradiction. If we assume $f(y)\neq 0$ for some irrational number $y$, we should be able to come up with a contradiction to the definition of continuity at point $y$. I am not quite sure how to arrive at the contradiction, though.  Relevant facts:   Let $A\subseteq\mathbb{R}, f:A\rightarrow\mathbb{R}$ and $c\in A$. Then $f$ is continuous at $c$ if $\forall\varepsilon>0, \exists\delta>0$ such that if $x\in A$ and $|x-c|<\delta$, then $|f(x)-f(x)|<\varepsilon$. If $x,y\in\mathbb{R}$ and $x<y, \exists r\in\mathbb{Q}$ such that $x<r<y$. If $x,y\in\mathbb{R}$ and $x<y, \exists z\in\mathbb{R\setminus Q}$ such that $x<z<y$.   The first is just the definition of continuity at a point. The second and third state that between any two real numbers you can find both a rational and irrational number, which I think may come in to play somewhere.

Akhil showed that the  is the same as the continuum, using as a step the observation that continuous functions that agree at rational points must agree everywhere, since the rationals are dense in the reals.  This isn't an obvious step, so why is it true?


I'm out with a new problem. I've downloaded a jdk7.sh file. Now I'm unable to change the permission of the file to allow executing the file as a program. I mark the check box and again it disappears.

How can I execute a file without giving myself execute permissions (with chmod u+x) for it?   If I try and tick the 'Allow executing file as program' checkmark, the checkmark is immediately removed.


How to downgrade Ubuntu Hirsute Hippo (21.04) to Focal Fossa (20.04) LTS? Or that's not actually an option?

I just installed a new version of Ubuntu and I want to roll it back to the previous version.  How can I do that? Is that even possible?


It is well-known that, for any $T\in\mathbb{N}^*$, a sequence $(u_n)_{n\in\mathbb{N}}$ converges iff all sequences $(u_{Tn+r})_{n\in\mathbb{N}}$, for $0\leq r < T$, converge towards a common limit. I was wondering if this could be generalized to functions: Let $f:\mathbb{R}_+\to\mathbb{R}$ and $\ell\in\mathbb{R}$. Assume that for every $t\in[0,1)$, the sequence $(f(n+t))_{n\in\mathbb{N}}$ converges towards $\ell$. Does $f$ necessarily converges at $+\infty$? Of course, my intuition believes this result to be true, but I cannot manage to prove it, since the sequences $(f(n+t))_{n\in\mathbb{N}}$ for $t\in[0,1)$ could converge at very different rates…

Let $f: \Bbb R \to \Bbb R$ be a continuous function satisfying $f(x+n) \to \infty$ as a sequence in $n$, for all $x$. Does $f$ satisfy $f(x) \to \infty$ as $x\to \infty$?   If we drop the continuity assumption then the claim is false, by considering a function tending more and more slowly to $\infty$ as we start at larger values in $(0,1)$. (Or many other examples)  As for context: a variant of this claim (when $f$ is analytic and we replace $n$ by a general increasing sequence $a_n$) could be useful to me at some technical exercise, and this is a simplification which I still cannot tackle.  Assuming by contradiction that $\exists M\forall x \exists x_0>x: f(x_0)\leqslant M$, we want to show that $\exists x \exists N>0 \forall n \exists n_0>n: f(x+n) \leqslant N$. No "quantifiers-level" logic seems to apply here.  Any ideas?


Is there a simple geometric proof that there exists a continuous bijective function between a square and its side?    And is there some explicit continuous function or formula $f^1(z)\mapsto (x,y)$ and $f(x,y)\mapsto z$, with $(x,y) \in [0,1]\times[0,1]$ and $z \in [0,1]$?  And is there a constructive proof that two sets of the same cardinality have a bijective function?

Is there a continuous bijection from $[0,1]$ onto $[0,1] \times [0,1]$? That is with $I=[0,1]$ and $S=[0,1] \times [0,1]$, is there a continuous bijection $$ f: I \to S? $$  I know there is a continuous bijection $g:C \to I$ from the Cantor set $C$ to $[0,1]$. The square $S$ is compact so there is a continuous function  $$ h: C \to S. $$ But this leads nowhere. Is there a way to construct such an $f$?  I ask because I have a continuous functional $F:S \to \mathbb R$. For numerical reason, I would like to convert it into the functional $$ G: I \to \mathbb R, \\ G = F \circ f , $$ so that $G$ is continuous.


whenever I make a new request in my application it takes to long to respond for the first time and all the subsequent requests are faster. If I do it again after some hours or tomorrow again it takes more time to respond and same subsequent requests respond quickly. I am not sure why this is happening every now and then even though the server is not restarted. I can understand if it is issue of explain plan creation. But the explain plan is created only once for the first time and it should not be slow there after. But I am keep on experiencing periodically even though the server is not restarted.

I noticed when running a SQL query it is faster the second time than the first. So my question is, in Oracle SQL Developer where can you see the statistics that explain this behaviour?


I'm trying to calculate the modifications in an entity before updating it.   display HTML form on submit:  start transaction load entity apply form data to entity calculate changes persist entity    Steps 2.1 through 2.3 are managed through my MVC framework (Spring MVC) so I never actually have a reference to the original entity without the changes.  So what I'm currently trying to do is the following:  // transaction is already started public Modifications store(Entity updated) {     Entity original = entityManager.find(Entity.class, updated.getId());     Modifications mods = calculateModifications(original, updated);     entityManager.merge(updated);     return mods; }   But unfortunately the entity I receive from the entity manager is the same (read ==) as the updated one.  Here's the question: How do I force the entity manager to load the entity again from the database without detaching my updated entity?  I am using Hibernate as my persistence provider, but I would like to keep this provider agnostic as much as possible.

I want to compare the current value of an in-memory Hibernate entity with the value in the database:  HibernateSession sess = HibernateSessionFactory.getSession(); MyEntity newEntity = (MyEntity)sess.load(MyEntity.class, id); newEntity.setProperty("new value"); MyEntity oldEntity = (MyEntity)sess.load(MyEntity.class, id); // CODEBLOCK#1 evaluate differences between newEntity and oldEntity sess.update(newEntity);       In CODEBLOCK#1 I get that newEntity.getProperty()="new value" AND oldEntity.getProperty()="new value" (while I expected oldEntity.getProperty()="old value", of course). In fact the two objects are exactly the same in memory.  I messed around with HibernateSessionFactory.getSession().evict(newEntity) and attempted to set oldEntity=null to get rid of it (I need it only for the comparison):  HibernateSession sess = HibernateSessionFactory.getSession(); MyEntity newEntity = (MyEntity)sess.load(MyEntity.class, id); newEntity.setProperty("new value"); HibernateSessionFactory.getSession().evict(newEntity); MyEntity oldEntity = (MyEntity)sess.load(MyEntity.class, id); // CODEBLOCK#1 evaluate differences between newEntity and oldEntity oldEntity = null; sess.update(newEntity);   and now the two entities are distinct, but of course I get the dreaded org.hibernate.NonUniqueObjectException: a different object with the same identifier value was already associated with the session.  Any idea?  EDIT: I tried the double session strategy; I modified my HibernateSessionFactory to implement a map of session and then...  Session session1 = HibernateSessionFactory.getSession(SessionKeys.DEFAULT); Session session2 = HibernateSessionFactory.getSession(SessionKeys.ALTERNATE); Entity newEntity = (Entity)entity; newEntity.setNote("edited note"); Entity oldEntity = (Entity)session1.load(Entity.class, id);  System.out.println("NEW:" + newEntity.getNote()); System.out.println("OLD: " + oldEntity.getNote()); // HANGS HERE!!!  HibernateSessionFactory.closeSession(SessionKeys.ALTERNATE);   My unit test hangs while attempting to print the oldEntity note... :-(


I have a Lenovo ideapad 110 with AMD E1-7010 and 4 Gigabytes of RAM. The whole sytem is very slow. When I open Google Chrome it takes a lot to respond or when I double click to make it full screen while watching videos on YouTube takes a lot ot time to change to full screen   Output of free -h                 total        used        free      shared  buff/cache   available Mem:           3.3G        1.6G        101M         51M        1.6G        1.3G Swap:          3.8G          0B        3.8G   Edit : I have installed windows 10 and the system is very smooth. So can anyone tell me what the problem with Ubuntu is? Is Ubuntu not compatible with SOC processors?

For a given hardware configuration, how do I find out if Ubuntu will run on it? What considerations should I take into account when choosing an Ubuntu version and  such as:    with a lighter desktop than the usual Gnome and Unity  with the even lighter LXDE desktop   Obviously Ubuntu does not run on some processor architectures. So how do I go about choosing the right version and derivate. How can I find out the minmal system requirements?


This is the flag indicator and the suggested edit indicator on Stack Overflow:    This is what they look like on Meta Stack Overflow:    And on Super User:    This is a flag indicator on sites where it hasn't been customized:    This is a suggested edit indicator on sites where it hasn't been customized:    This is Ask Ubuntu. Is that more of a default suggested edit orange or more of a Stack Overflow flag orange?    All these indicators have retained their color from back when each site has its own theme in the top bar. But now the top bar is uniform on every site. It doesn't make sense to vary the indicator colors.  Please make the indicator colors uniform across sites. And pick a color with good contrast — the beta suggested edit indicator has pretty bad contrast now, and the SO colors could use a bit more distinction. My preference goes for the default flag color with the SO suggested edit color.

The top bar is showing (again) the suggested edits count and 10K flags count, like it was before.  On Stack Overflow it looks like this: (that's the original color, same as in old top bar)        And on this very Meta site:        Same top bar. But different colors! Consistency broken.  I've just noticed the suggested edits count on Meta:        Black on black, I can see just a floating number - really confusing and out of any context.  In the name of Consistency, can we please have the same color on all sites?


In the script editor in QGIS, when choosing string parameter type, a default value must be added according to   What happen is that the parameter line in the GUI will be populated with the default value. 'average' in my case.     What I want to do is to add several different values so that the user can choose from. In my case, I want to add other statistics, so the user will have a drop-down list containing several options.  The solution in   does not work for me since I'm using QGIS 2.18.2, also the solution for check-box is not relevant.  Is it possible to create a drop-down list for the user in QGIS 2.18.2 las palmas?  In case it is needed, the full code is here:  ##Cell Statistics=name ##Select_directory=Folder ##statistic_name=string average ##Output_raster=Output raster import glob, os from PyQt4.QtCore import QFileInfo from qgis.core import QgsRasterLayer, QgsRectangle  os.chdir(Select_directory) raster_list = [] extent = QgsRectangle() extent.setMinimal()  statistic_dic = {'average':0, 'count':1, 'median':2,'mode':3, 'minimum':4, 'min_raster':5,'maximum':6, 'max_raster':7, 'std':8, 'range':9}   for raster in glob.glob("*.tif"):     fileInfo = QFileInfo(raster)     baseName = fileInfo.baseName()     rlayer = QgsRasterLayer(raster, baseName)     # Combine raster layers to list     raster_list .append(rlayer)     # Combine raster extents     extent.combineExtentWith(rlayer.extent())  # Get extent     xmin = extent.xMinimum() xmax = extent.xMaximum() ymin = extent.yMinimum() ymax = extent.yMaximum() # Run algorithm and set relevant parameters processing.runalg("grass7:r.series",                 {"input":raster_list ,                 "-n":False,                 "method":statistic_dic[statistic_name],                 "range":'-10000000000,10000000000',                  "GRASS_REGION_PARAMETER":"%f,%f,%f,%f"% (xmin, xmax, ymin, ymax),                  "GRASS_REGION_CELLSIZE_PARAMETER":0,                 "output":Output_raster})

I want to make a drop down box that shows 2 or 3 options and let the user choose 1 from them?  I would like to let the user to choose from "millimeter", "centimeter" and "meter". These Options are not from the field of input.  It seems like none of them here is valid:


I tried to install Ubuntu 14.04 on Windows 10 having created partitions for swap area and root. But when I am installing ubuntu it keeps saying "failed to install grub-efi-amd64-signed" into target. I have tried several times but it keeps saying the same thing and installation fails. Please help me as how to proceed further.

I am installing Ubuntu 16.04 in an Intel NUC computer with UEFI enabled. I am using an SSD from another computer. During the installation I chose Erase the disk and make a new full install  At the end of the process I see:  grub-efi-amd64-signed failed installation /target/ Ubuntu 16.04    And the system does not boot.  I tried to use boot-repair but apparently it does not solve the problem.


I'm studying managing  system, but actually need a set of instructions, how exactly could i add a repository to my  account (through terminal)? That may sound obvious for many of you, but I'm struggling in attempts to figure that out by my own.  What I want to do is:   login to github (via terminal, enter my account details) create a repo (in my git account folder) push files from my local repository to that newly created repository (upload existing projects in it)   Any help would be appreciated.

Ok, after seeing , I have decided to skip to the end and go with .  So what I need is a beginner's practical guide to Git.  "Beginner" being defined as someone who knows how to handle their compiler, understands to some level what a  is, and has touched source control without understanding it very well.  "Practical" being defined as this person doesn't want to get into great detail regarding what Git is doing in the background, and doesn't even care (or know) that it's distributed.  Your answers might hint at the possibilities, but try to aim for the beginner that wants to keep a 'main' repository on a 'server' which is backed up and secure, and treat their local repository as merely a 'client' resource.  So:  Installation/Setup    How do you set up Git?  Try to cover Linux, Windows, Mac, think 'client/server' mindset.         Working with the code          How do you handle binary files (visio docs, for instance, or compiler environments)? How do you merge files changed at the "same time"?    Tagging, branching, releases, baselines    How do you pull a particular 'release'?   How do you resolve conflicts and complete the merge? How do you merge parts of one branch into another branch?        Other   Describe and link to a good GUI, IDE plugin, etc. that makes Git a non-command line resource, but please list its limitations as well as its good.    - Cross platform, included with Git  - Cross platform history viewer, included with Git  - Mac OS X  - Mac OS X history viewer  - Cross platform, commercial, beta  - console GUI for Linux  - GUI for Windows, Linux  - package for Windows, includes friendly GUI  Any other common tasks a beginner should know?     How do I work effectively with a subversion repository set as my source control source?   Other Git beginner's references                 Delving into Git     (and )    I will go through the entries from time to time and 'tidy' them up so they have a consistent look/feel and it's easy to scan the list - feel free to follow a simple "header - brief explanation - list of instructions - gotchas and extra info" template.  I'll also link to the entries from the bullet list above so it's easy to find them later.


I have a User entity that contains the username, name and other non sensitive information.  During authentication, I need to query the password (hashed) and the password salt in order to do a hash comparison. Those two properties are not part of the model due to their sensitive nature.  How can I query those two properties in NHibernate without using CreateSQLQuery? I now that CreateSQLQuery works, but I was trying to find a non SQL way.

I have a class that is mapped to a table using NHibernate. The problem is that only some of the properties are mapped to columns in the table. This is fine because the only columns we use for display are mapped, however I was wondering if there is any way to query against other columns in the table that aren't mapped to properties in my class.  For example we have a table with the following columns:  Customer ----------- CustomerId Name DateCreated   and we have an object  public class Customer {     public virtual int CustomerId {get;set;}     public virtual string name {get;set;} }   and name and customerId are mapped however DateCreated is not because we never display it anywhere. We would like to query the Customer table for customers that were created by a certain date. Is there any way to do this without mapping the DateCreated?  Also it would be preferable to do this using the criteria API.


How do I avoid using instanceof and casting in this situation if I want to have different validators where the method signatures differ?  Code  for(BatchValidator validator : validators) {   try {          if (validator instanceof BatchErrorValidator) {       ((BatchErrorValidator<T>) validator).validate(targets);     } else if (validator instanceof BatchWarningValidator) {       ((BatchWarningValidator<T>) validator).validate(targets, header);     }   } catch (BatchValidationException e) {     handleImportExceptions(e, header.getSequenceId());   } }

Eclipse is giving me a warning of the following form:     Type safety: Unchecked cast from Object to HashMap   This is from a call to an API that I have no control over which returns Object:  HashMap<String, String> getItems(javax.servlet.http.HttpSession session) {   HashMap<String, String> theHash = (HashMap<String, String>)session.getAttribute("attributeKey");   return theHash; }   I'd like to avoid Eclipse warnings, if possible, since theoretically they indicate at least a potential code problem.  I haven't found a good way to eliminate this one yet, though.  I can extract the single line involved out to a method by itself and add @SuppressWarnings("unchecked") to that method, thus limiting the impact of having a block of code where I ignore warnings.  Any better options?  I don't want to turn these warnings off in Eclipse.  Before I came to the code, it was simpler, but still provoked warnings:  HashMap getItems(javax.servlet.http.HttpSession session) {   HashMap theHash = (HashMap)session.getAttribute("attributeKey");   return theHash; }   Problem was elsewhere when you tried to use the hash you'd get warnings:  HashMap items = getItems(session); items.put("this", "that");  Type safety: The method put(Object, Object) belongs to the raw type HashMap.  References to generic type HashMap<K,V> should be parameterized.


I am new to C. I have been searching for hours to find an answer to this problem but no luck. Your help would be greatly appreciated.  I need to write a function that takes the file path as argument (I am calling this argument WorkingDir below)  This function  void test1(char *WorkingDir) {     FILE *out_file1;     out_file1 = fopen(strcat(WorkingDir,"Th.txt"), "wt");      // the above attempts to open file   /WorkingDir/Th.txt     fclose(out_file1); }   called as  test1("/my/directory/")   does not work (it does not set the path as required), although this one works just fine  void test2(char *WorkingDir) #argument is not used anywhere {     char path[100]="/my/directory/";     FILE *out_file1;     out_file1 = fopen(strcat(path,"Th.txt"), "wt");     fclose(out_file1); }   Thank you all for your answers. An important detail that I did not mention is that I am calling the C function from R. To pass a string from R to C requires char ** argument. So this function sets the path as required:  void test101(char **WorkingDir){     const int MAX_PATH = 300;     char path_name[MAX_PATH + 1];     snprintf(path_name,MAX_PATH,"%s%s",*WorkingDir,"Th.txt"); }   The above function uses your inputs. Thank you for them.

I'm working in C, and I have to concatenate a few things.  Right now I have this:  message = strcat("TEXT ", var);  message2 = strcat(strcat("TEXT ", foo), strcat(" TEXT ", bar));   Now if you have experience in C I'm sure you realize that this gives you a segmentation fault when you try to run it. So how do I work around that?


Today one question pop up into my mind... What will happen if Earth spinning about its axis and around the sun will start moving in reverse direction... Whether it will affect us... What are all things will change?

In the Futurama episode "" they save the world by rotating the Earth backwards saying it shouldn't matter (which direction Earth rotates). If Earth rotated clockwise and remained in it's current counter-clockwise orbit around the Sun, would it affect anything beyond the direction the constellations move across the sky?


"You are going to fight in the war like David once did."   I have two questions:    Should "like" be replaced with "as"? Is it ever acceptable to use "like" in this sentence even though "as" is the proper word to use?

Is there any difference between the following couples of sentences?     Dress as you would if you were having guests.   Dress like if you were having guests.        She kissed him goodbye, as usual.   She kissed him goodbye, like the usual.        Sweet as she is, she doesn't pay his bills.   Sweet like she is, she doesn't pay his bills.


State true or false. Let $n \geq 2$ be a natural number. Let $S$ be   the set of all $n \times n$ real matrices whose entries are only $0, 1$ or $2$. Then the average of determinants of matrices in $S$ is greater than or equal to $1$.   This is how I think the answer should go, but I am not fully convinced.   False. The average value is zero. There are only finitely many matrices in $S$, and we can exhibit a one-to-one correspondence between the matrices with non-zero determinants as follows: given $A \in S$ with positive determinant, interchanging the first two columns of $A$ gives us a matrix in $S$ with negative determinant. As this function has an inverse (itself) it is bijective. Thus, the average value of the determinant of matrices in $S$ is zero.

Let $S$ denote the set of $A \in M(n,\mathbb R)$ such that every entry of $A$ is either of $0$, $1$ or $2$, then is it true that $$\sum_{A \in S} \det A \ge 3^{n^2}\ ?$$


For some reason, part of the Edges that are behind Geometry, still get drawn in the scene. The object neither has XRay enabled  nor is "limit selection to visible" active. "Backface Culling" also seems not to be the problem. This only appears in Ortho View and not in Perspective View. Any ideas? Perpective View:

I changed my Blender Units to Metric System, but when I'm building things, my meshes are transparent, i.e. I can see through faces like in wireframe even though my wireframe is turned off. All faces have a light white in non-wireframe mode, but I can still see through them.   How do I reverse this?  Another issue I get is this    Looks like clipping is not working properly.


Today a new version of vscode was available, so I went to  and downloaded the .deb file. I clicked the downloaded file, it opened in the Ubuntu Software Center and I clicked install to update my current version. So far this is a very user friendly process IF the installation would actually work :-)   What actually happened:  If I go to the Software Center after the installation it still shows me the old version of VSCode:   If I click the downloaded .deb file again it still shows me that I can install it and NOT launch it, even if the installation was successful (I can check it by opening VSCode from the dock and check the version).    My questions are:   What happened here?  Why is Ubuntu not showing me the updated version in the Software Center? Why does Ubuntu still show me that I can install the .deb file even if I have just installed it How can I show this post to Canonical, so they can finally implement a NOT buggy installation/update process?

I want to update my VS Code so tried multiple option in doing so all result in something like this  sudo dpkg -i code_1.45.1-1589445302_amd64.deb    martin@martin:~/Downloads$ sudo apt install code Reading package lists... Done Building dependency tree        Reading state information... Done code is already the newest version (1.45.1-1589445302). 0 upgraded, 0 newly installed, 0 to remove and 8 not upgraded.     But when i check in the VS Code about I see.    I needed to upgrade my VS Code because some extensions doesnt activate. The reason I think is because VS Code is not latest.    No matter how many times I reload them they dont activate  UPDATE:  martin@martin:~$ umake --list-installed  visual-studio-code: Visual Studio focused on modern web and cloud     path: /home/martin/.local/share/umake/ide/visual-studio-code  martin@martin:~$ snap list | grep -i code martin@martin:~$ flatpak list | grep -i code martin@martin:~$


I'm writing a bash script to create self-signed certificate.  The script works well until I have to sign the certificate. Indeed, i can't get my expect command to match the received string.  Here is the string my terminal returns :  Sign the certificate? [y/n]:   And here are my commands :  /usr/bin/expect <<EOD spawn sudo openssl ca -config CA/ca.cnf -policy policy_anything -out CA/newcerts/webserver.cert -infiles CA/certrequests/webserver.csr expect {Enter pass phrase for ./CA/private/cakey.pem:} {send "${PEMpassword}\n"} expect -re {Sign the certificate? [^:]*:} {send "y\n"} expect -re {1 out of 1 certificate requests certified, commit? [^:]*:} {send "y\n"} expect eof EOD   I'm not very familiar with expect nor regex but "[^:]*" worked for me until now for similar strings.  I have unsuccessfully tried those :  [?*] \* ?: [y/n] \[y/n\] "[y/n]" [\w/\w] [w+] [\w+]   Thanks in advance for your suggestions !

I am tired of always trying to guess, if I should escape special characters like '()[]{}|' etc. when using many implementations of regexps.  It is different with, for example, Python, sed, grep, awk, Perl, rename, Apache, find and so on. Is there any rule set which tells when I should, and when I should not, escape special characters? Does it depend on the regexp type, like PCRE, POSIX or extended regexps?


Trying to reinstall the Gerbera server. I get this message -  E: The repository ' bionic Release' does not have a Release file. N: Updating from such a repository can't be done securely, and is therefore disabled by default. N: See apt-secure(8) manpage for repository creation and user configuration details.  Kinda noobish with Linux. Hope I am not repeating a previously answered question. Thanks!

When updating, I get the following error message:   W: The repository 'http://ppa.launchpad.net/mc3man/trusty-media/ubuntu xenial Release' does not have a Release file.   Here, I find another statement on this error:   This recommends removing certain PPAs; and, I'm not sure if I should do that since it might mean not getting the updates that I need.    Is this what I should do?


I have two plots using scatter plot of which one is non linear and the other one is linear. And I require the intersection of these curves. How should I proceed ?  Edit: The plots are done by using a set of values in excel.  Curve 1:  x: 0, 0.5, 1, 1.5, 2, 2.5, 3, 3.5, 4, 4.5, 5, 5.5, 6, 6.5, 7, 7.5, 8  y:8.43, 8.76, 8.27, 7.87, 7.69, 7.76, 8.46, 8.85, 8.34, 7.92, 7.73, 7.79, 8.42, 8.76, 8.27, 7.87, 7.69  Curve 2: y=8.168  Thanks  Edit-2: In the other question  a trend line is made and then the intersection of those are dealt, which is clearly not possible for mine and not a duplicate  for the question you are referring to.

Given this table, chart and trend lines in Excel. I want to find the coordinates of the  intersecting point.  How can I do this?


I hear from indian colleagues      my TeamViewer password is six, nine, double-eight (to say 6988)   or      my telephonenumber is three, five, four, triple-nine, six, double-eight, two,   one (to say 3549996882)   My queestion is: using      double N   or      Triple M   is it correct?  I would like to know if it is common in the US and UK too.

I always have this problem of telling people my phone number which consists of a series of repeating numbers:     184 555 5555 (DO NOT CALL, this is just as an example)   I can tell people it is:   one eight four, five five five, five five five five, or; one eight four, five, double five, double five, double five, or; one eight four, five, triple five, triple five, or; one eight four, five, sextuple five.   Is there a prescribed way or a widely practised method of transcribing long repeating phone numbers?


I'm looking for a non-mathematic answer as I am yet to begin studying physics or calculus, still half a year away. Just a simple explanation in layman's terms. As i understood it, electrons for example are massless before interacting with the field, like photons. so why do electrons interact with the higgs field and not photons and gluons?

Why don’t photons interact with the Higgs field and hence remain massless?


I'm new to Latex, and I'm using an overleaf template called Concordia University Thesis Template to write my thesis. Furthermore, I have a wide table containing a lot of text, and since I'm obligated with specific page margins, I can't change them. the problem that the table is getting out of the page, and I tried to make the text under each other in the same cell but still didn't fix the solution for me, and the table looks like this the code that I used is like this %###################  BEGIN: Environment Setup  #######################  \documentclass[letterpaper,11pt,onecolumn,final]{report}              % define document type \usepackage[left=1.5in,right=1in,top=1in,bottom=1in]{geometry}    % margin settings, required by Concordia University \usepackage{setup/ConcordiaU}                         % page maker definition for Title Page, Signature Page, and styles customized for Concordia University \usepackage{setspace}                             % manually configuration to spacing is needed. \doublespacing                                         % double spaced, required by Concordia University \usepackage[natbibapa]{apacite}                  % citation and bibliography package \usepackage{amsmath}                            % equations/formulas \usepackage[dvips]{graphicx}                    % to include images. For those who use .eps images. The option [dvips] must be there. \graphicspath{{figures/}}                           % all figures are put in the folder named "figures" %\usepackage{subfigure}                            % enable subfigures \usepackage{multirow}                                % multirow in a table cellcc \usepackage{indentfirst}                           % add indent to the first line of each paragraph \usepackage{algorithmicx, algpseudocode}  %  write algorithms in pseudo code in a uniform style \usepackage{algorithm}                             % algorithm and pseudocode environment \usepackage[colorlinks,linkcolor=blue,anchorcolor=blue,citecolor=blue,urlcolor=blue]{hyperref}    % blue color for all links, urls and citations \usepackage{enumitem} \renewcommand{\labelenumi}{(\arabic{enumi})}        %  "(1)." style for enumerated items \renewcommand{\labelitemii}{$\circ$}      % (o) for the second level bullet items \usepackage[titletoc,title]{appendix}  \ref{table:GIS_API} illustrates all possible API that can be used to extract data from it. \begin{table}[htb] \begin{tabular}{|c|c|c|c|c|c|} \label{table:GIS_API} \hline Application name & Owned by                  & Has an API? & API NAME        & Pricing       & Number of transaction \\ \hline  openstreetmap    & Openstreetmap Orgnization & yes         & Overpass api    & Free                       & Unlimited             \\ \hline     Google Earth engine &       Google inc. &       yes &       Eearth engine api &       \begin{tabular}[c]{@{}c@{}}free for research, \\ education, and\\  nonprofit use.\\  For commercial\\  applications, \\ they offer paid \\ commercial licenses.\end{tabular} &       -- \\ \hline     Tomtom developer & tomtom                    & yes         & Tomtom maps-api & 0.42\$ per 1000 tranaction & Limited by the cost   \\ \hline     HERE developer &       Here &       yes &       Rest api &       Has a free version and paied version & \begin{tabular}[c]{@{}c@{}}The free version has \\ 250K transaction \\ and you can pay for more\end{tabular} \\ \hline \end{tabular} \end{table}  is there a way to make the table aligned within the page borders

I have a table that I want to insert on a page, but at least one (perhaps both) of the following conditions are met:   The table is too wide to fit within the text block or page. That is, I'm exceeding some horizontal restriction. The table is too tall to fit within the text block or page. That is, I'm exceeding some vertical restriction.   What are my options to make this table fit? If it doesn't fit, regardless of my attempts, what other options exist?


If an infinite number of coins are tossed infinitely often, is it true that there will be infinite subsets of those coins that repeat any finite sequence of heads/tails infinitely often? I.e., infinitely many coins will always produce heads, infinitely many always produce tails, infinitely many produce HTHTHT..., THTHTH..., HHTHHTHHT..., TTHTTHTTH..., etc.  And on each toss of all the coins, would some infinite subset of coins begin reproducing a finite sequence infinitely often? I.e, infinitely many coins that had previously produced irregular sequences of HT would begin producing HTHTHT..., THTHTH..., et

Of course, we've all heard the colloquialism "If a bunch of monkeys pound on a typewriter, eventually one of them will write Hamlet."  I have a (not very mathematically intelligent) friend who presented it as if it were a mathematical fact, which got me thinking... Is this really true?  Of course, I've learned that dealing with infinity can be tricky, but my intuition says that time is countably infinite while the number of works the monkeys could produce is uncountably infinite.  Therefore, it isn't necessarily given that the monkeys would write Hamlet.  Could someone who's better at this kind of math than me tell me if this is correct?  Or is there more to it than I'm thinking?


How can the hacking skill of my soldiers be improved?  Which of the following affects it?   Class (do Specialists get an innate hacking skill boost, or is it only via GREMLIN ?) Rank Special abilities GREMLIN upgrades Practise (eg, does attempting/succeeding in a hack improve skill?)

My main specialist seems to have a hard time hacking stuff. How can I make him better at it?


It is .  However, it is .   The combination of the two seems silly.  I can delete my answer because it strikes me it's wrong, do some research, edit and undelete. I've done that, it works. But if in the meanwhile I close the browser window or get distracted, I might not even find my self-deleted answer to edit and undelete. Because it won't show up on the list of my actions.  Please:   Allow seeing your own post deleted by you (and not by something else) on the Activity tab Introduce deleted action on that list to know you deleted your post.

I deleted one of my questions and would like to undelete it. This requires finding the question.  I think you shouldn't be prevented from seeing your own posts that you have deleted. It should be easier than me remembering the link or checking the browser history to easily look these up.   I would currently need 10K to see my deleted items and even then if I can find their URL.


Given A,B are independent identically distributed random variables  will  $$E[A^2B]=E[A^2]E[B]$$  (uncorrelation) $$P_{A^2B}(a,b)=P_{A^2}(a)P_B(b)$$  (independence)   hold?  An initial thought is that one-to-one mapping of random variable will not destroy independence  However the mapping $$f(x)=x^2$$ apparently is not an 1-1 mapping.  Any proof toy example to show if the above two property still holds after mapping?

Let $X$ and $Y$ be independent random variables. Prove that $f(X)$ and $g(Y)$ are independent for any choice of measurable functions $f$ and $g$.   This sounds very obvious, but I have no idea how to approach it.  EDIT: Two random variables are independent if $\Pr\{X = x \text{ and } Y = y\} = \Pr\{X = x\} \cdot \Pr\{Y = y\}$


I lost my complete iOS.  Oh no! Something has gone wrong A problem has occurred and the system can't recover. Please contact a   system administrator.

I upgraded to Ubuntu 20.04 today, choosing LightDM over gdm3 during the upgrade. During the upgrade I was asked if I wanted to keep or replace /etc/sane.d/dll.conf file. I decided for keeping it. Now, without actively rebooting, the "Oh no! Something went wrong" screen appeared. As I am still inexperienced with this kind of troubleshooting, I feel it wouldn't be safe to just try out answers from other threads that don't have exactly the same 'history'. Solutions I read included Ctrl+Alt+F4 and trying to login and get more information from the command line (). Is that safe to do? Ideally, I'd like to save my data that is stored on an encrypted harddrive before trying to fix errors. I'd like to avoid reinstalling the OS. From reading other threads, I know this post may be criticised as not being precise enough or haven't tried enough, but really I cannot get more information from that white screen myself and don't want to risk ruining everything just to provide more information... Thank you for your help!! :) Edit: I have no idea if the problem is related to lvm2-activation-generator, as in  This and other solutions include booting from a live usb. Can I do this 'safely' by simply switching the laptop off at this stage? Do I have to do sth before?


For both containers it is true that:  $p_{bottom}=p_{atm}+\rho gh$ and $F_{bottom}=a*p_{bottom} \iff F_{bottom}=a*p_{atm} + a\rho gh$  I do not know how a scale functions, but I guess that the only force it can count is the force by the liquid on the bottom of each container (the only surface that is in touch with the scale is the bottom of the container). Thus, if we measured the mass of these two masses of water (lets assume that the mass of the containers is negligible) it would appear to be the same in each case. Am I right?

Scenario description  Lets assume both containers have a capacity of 300 litres.  One is a vertical tube  as shown in pic 1  Other one is more or less a V shaped containers as shown in pic 2  Both are at ground level  Question  No doubt that whole weight of 300 litres will act on the base of the tube (pic 1). But will the weight of the whole 300 litres act on the base of the container as shown in pic 2?  I.e if you keep both the containers on a weighing scale, for sure, it will show a weight of approx. 300 kg each.  But what I'm asking is whether the weight of whole 300 litres acts on the base of container 2 (since the container's walls are slanting, as opposed to the walls of the tube in pic 1).  If the whole weight will not act on the base of the container, can you state the reasoning and also the principle, so that I can further get to know about it?  Pic 1             |         |                    |         |            |         |            |         |            |         |            |         |            |_________|   Pic 2           \              /           \            /            \          /             \________/


I have analyzed my websites in Bing Webmaster Tools and it's showing the error “There are multiple <h1> tags on the page.”   I have analyze the pages manually and I haven’t found multiple H1 tags on any of them.  Why is this error is being show in webmaster tools?

I used the Bing webmaster tool's SEO analyzer on my website, and it reported:     There are multiple  tags on the page.   It recommends that there should only be one
 tag on the page.  The page is a listing of blog posts for a category. So each blog entry is structured like this.

...

summary...

...

summary...

...

summary...

...

summary...

   How is this invalid? I thought this was the correct way to describe a post in HTML5.


I know that ${n \choose k}$ $ = $ ${n \choose n-k}$ $ = \frac{n!}{(n-k)!(k)!}$, so I would write $$ \sum_{k=0}^{n} {n \choose k} \cdot {n \choose k} = \sum_{k=0}^{n} \frac{n!}{(n-k)!(k)!} \cdot \frac{n!}{(n-k)!(k)!} = \sum_{k=0}^{n} \frac{(n!)^2}{((n-k)!(k)!)^2}$$ however from this point I do not know how to get it in terms of ${n \choose k}$. My book claims that this is equal to ${2n \choose n}$, but I can not see the connection between the two. Even when I write out ${2n \choose n}$, I do not see anything that is connection these two. $${2n \choose n} = \frac{2n!}{(2n-n)!(n)!} = \frac{2n!}{(n)!(n)!} = \frac{2n!}{((n)!)^2}$$ edit: Indeed the book claims indeed that $\sum_{k=0}^{n} {n \choose k} \cdot {n \choose k} = {2n \choose n}$ what has been suggested in the comments

Prove that $$\sum_{k=0}^n {n \choose k}^{\!2} = {2n \choose n}.$$  The exercise provides the following hint: $\,\,\displaystyle{n \choose k}={n\choose n-k}$.  Any help?


What do you think of these sentences? I found them on the Net. I mean, should they function here as a gerund or a participle? Are both of them possible? 1 Smoking cigarettes are dangerous 2 Smoking cigarettes is dangerous

What is the difference between a gerund and a participle?


I've done some researching on validating URLs in PHP and found that there are many different answers on StackOverflow, some better than others, and some very old and outdated.  I have a field where users can input their website's url. The user should be able to enter the URL in any form, for example:  example.com www.example.com http://example.com http://www.example.com https://example.com https://www.example.com   PHP comes with a , however, it marks the URL as invalid if it doesn't have http://.  How can I validate any sort of URL, with or without http:// or https://, that would ensure the URL is valid?  Thanks.

How can I check if a given string is a valid URL address?  My knowledge of regular expressions is basic and doesn't allow me to choose from the hundreds of regular expressions I've already seen on the web.


I understand that Arda is supposed to be set somewhere in a sort of vaguely ancient Earth, but does that mean that Middle Earth is supposed to take place in the area that eventually becomes modern-day England? I read that J.R.R Tolkien wrote LOTR because he wanted to create a mythology for the English, as they didn't really have one before.

As most Tolkien fans know, Arda (Tolkien's world) is supposed to be Earth in its past, and all its stories are supposed to have happened long ago on this very same planet. Of course, this is fiction, so this is not supposed to be actually true.  But, if one wanted to roll with it... how could it possibly make sense from a geographical standpoint? All maps of Middle Earth (before or after the destruction of Beleriand and Numenor) just don't match anything on Earth, even when considering continental drift.  Of course, one could simply say "the Valar reshaped it (again)", but not only this is a bit unsatisfactory, it also doesn't make much sense in context, as Valar are well known for not wanting to meddle with Arda unless absolutely needed, and even then, as little as possible.    Update:  Hey, please calm down, guys. Mine was not a rant at all. And I know perfectly well this is fiction (and I've stated it plainly). The sense of my question was: "If one wanted to follow this line of thought and assume Arda should be related to Earth as Tolkien said, then how could this relationship be explained?".


I am trying to integrate Google Admob into my project, but in running into an issue.    I will go over my project first.    My project is structure on 2 main Java files and around 7 .xml files.   The .xml files are shapes, the .xml files are neither linear or relative layout.  In my main Java file I draw those .xml file shapes to the screen.  So I do not depend on a .xml layout for my project.    EXAMPLE OF SHAPE .XML FILE   <?xml version="1.0" encoding="utf-8"?>  <shape xmlns:android="http://schemes.android.com/apk/res/android" >  <solid android:color="#000" /> <corners android:bottomLeftRadius="15dp" android:bottomRightRadius="15dp" android:topLeftRaidus="17dp" android:topRightRadius="17dp" /> </shape>   So I am trying to add Google ads into my project, so I will need to add the Google ad .xml code.  But I'm not for sure where.   When I put my ad .xml code in one of the shapes .xml code I get and error that says "You can not put this here".     So I thought a little bit and realized I still have my .xml layout file that was created when I created my project.  So I add my ad .xml code there and had no error.   So next I added my Java code in my mainactivity.java,  into the oncreate, and I had no error.    I have 2 Java files, one is my mainactivity.java and the other one is my MV.java.  My MV.java is where I draw all my .xml shapes to the screen.    My Java code looks like this:  protect void onCreate(bundle savedInstanceState) { super.onCreate(savedInstanceState); view = new MV(this);  Adview adView = (AdView) this.findViewById(R.id.adView); AdRequest adRequest = new AdRequest.builder().build(); adView.loadAd(adRequest);  }   I do not get any error with my Java code.  So I thought I could run my application and have my ad.  But when I run my app I get this error.   Attempt to invoke virtual method 'void com.google.android.gms.ads.Adview.loadAd(com.google.android.gms.ads.Adrequest)' on a null object reference    I also did add the Google ad code in my build.gradle and androidmanifest.xml.  how can I get ads to work?

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?


Why does my System Monitor show that I have 32 CPUs when my lscpu command shows that I have 96 CPUs?  I believe that my System has 48 Cores which makes it 96 with Hyper-threading.

I'm currently running Ubuntu 14.04.2 Desktop.  The System Monitor tool is showing me 32 CPUs when I'm expecting 56. Should I be concerned?  Screenshot of System Monitor:    As you can see, it shows 32 CPUs.  Output of lscpu:  ~$ lscpu Architecture:          x86_64 CPU op-mode(s):        32-bit, 64-bit Byte Order:            Little Endian CPU(s):                56 On-line CPU(s) list:   0-55 Thread(s) per core:    2 Core(s) per socket:    14 Socket(s):             2 NUMA node(s):          2 Vendor ID:             GenuineIntel CPU family:            6 Model:                 63 Stepping:              2 CPU MHz:               1337.882 BogoMIPS:              5189.07 Virtualization:        VT-x L1d cache:             32K L1i cache:             32K L2 cache:              256K L3 cache:              35840K NUMA node0 CPU(s):     0-13,28-41 NUMA node1 CPU(s):     14-27,42-55   As you can see, according to lscpu, I should have 56 CPUs.  htop is also showing me 56 CPUs.    My machine is . It has 2 Intel Xeon E5-2697 V3 processors, each having 14 cores and capable of 2 threads per core (as seen in the output of lscpu, and further confirmed in BIOs).  I recall seeing 56 cores under System Monitor when I launched it in the "try ubuntu" mode from the installation disk before installing Ubuntu.   Is there something wrong with my system configuration? If there is (e.g., hardware failure), what can I do to verify? Also, I noticed that my System Monitor does not have a "System" tab.


Print each item in the list ["The Walking Dead", "Entourage", "The Sopranos", "The Vampire Diaries"] and its index.  Make sure to print its index first.  Then, print the movie name. I am taking a python course in Udemy and this one of the tasks.  I keep getting an incorrect output.  I believe its because they want the output in a list.  This is the code I am inputing, but I am not sure how to get the output in a list. x = ["The Walking Dead", "Entourage", "the sopranos", "The Vampire Diaries"] index= 0 for i in x:     print(index, i)     index += 1

How do I access the index in a for loop like the following?  ints = [8, 23, 45, 12, 78] for i in ints:     print('item #{} = {}'.format(???, i))   I want to get this output:  item #1 = 8 item #2 = 23 item #3 = 45 item #4 = 12 item #5 = 78   When I loop through it using a for loop, how do I access the loop index, from 1 to 5 in this case?


How does a shuttle move in the space as, the whole mechanism of a rocket is based on 3rd law of newton but, we can not apply 3rd law of newton in space because there is no reactive force in space?

I know Newton's third law of motion might be the answer for this but still I am wondering how the rockets could thrust in the empty space and move in the opposite direction. I guess an astronaut wouldn't be able to push in the empty space with his hands or legs to move himself, but with a rocket engine it's possible. How? What might be the explanation for this in General Relativity?


The following LDO is supplied from 2 input sources. BAT, which is a battery from 2.5-4.2V and VBUS, which is a power adapter voltage of 12V. My understanding is that a diode has a forward voltage drop of about 0.7V. So what is the LDO input voltage if both sources are connected?    Edit: In the reference question that is linked below it is not explained how the power is shared between both sources.

Following an earlier question ,  I would love to implement the  as suggested by Russell McMahon.   That way I could switch between 4AA batteries (1.2V*4 or 1.5V*4) and USB power. The battery voltage would nicely be regulated to 5V too. And the idea was to use the shutdown pin of the chip IF USB power is detected. The device also has to work when no batteries are present.  I am not too experienced with this, but I thought to connect the 5V from the USB to the SHUTDOWN pin from the LDO chip. Pitywise, the pin function is inverted, if SHUTDOWN is low, Vout from the LDO chip is low.  I am now considering using an XOR gate to make the thing work:         – Schematic created using   I would love to limit the amount of components, but the number of diodes is already high, and the whole thing feels a bit crafted   My questions:    Is there a better suitable chip (with an inverted shutdown pin) is there a better circuit (without voltage drop) to get this (I would prefer to get rid of D1, but then, the XOR has no desired operation)


"He was watching the television when I called on him."  When I said this sentence to one of my friends  (an English teacher)  he corrected me saying that the definite article (the) should be omitted. Still, I can't understand why. ? Actually similar  question has been asked earlier but the answers were so ambiguous. So I put complete sentence.

Why are these different?        We heard the news on the radio.   We watched the news on television.      In this , the author says we must use television without the. Why? It makes me crazy. Is there a valid reason?


I thought my tire pressure was low.  I pumped air to the maximum resistance and after four hour there was hissing of air continuously while I was asleep and it woke me, how can I fix it?  It's a new one, bought three weeks ago and it's only the front tire went flat.

Bought a used mountain bike for mom. The bike  wasn't used in quite a while . Mom used it for 3 weeks , tire pressure was  ok but it needed some air. So I pumped air in both the tires to max recommended psi on the tire.  After sometime ,  both the tires were flat. I did not hear any sound of leaking air right after I pumped it. I tried it again, this time  I heard a hissing air leaking sound.  What could have happened ?Not sure if anything in the valve is stuck. How can I determine what is wrong ?  Thanks in advance.


I made a function in C++ to find the length of an array. I find the sizeof the array passed in the argument and divide it by the sizeof the variable type. This should work but it always returns 1! Am I missing something obvious? Or does this have to do with pointers and memory? This is my code:      #include <iostream>      using namespace std;      int lengthOf(int arr[]);      int main() {         int x[] = {1,2,3,0,9,8};         int lenX = lengthOf(x);         cout << lenX;         return 0;     }      int lengthOf(int arr[]) {         int totalSize = sizeof arr;         cout << totalSize << endl;         int elementSize = sizeof(int);          return totalSize/elementSize;     }   Output (should be 6 instead of 1):      4     1   I am fairly new so excuse me if this is a bad question.

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


I have a github project which can be compiled to native image. How can I make it available for people to install it via apt-get? I am okay with uploading just the native image to a central repository as well because this project mostly won't have any updates.

How do I create my own custom PPA to share with the Ubuntu community? I am trying to create my own custom package set and I would really like to share it with the community.


I'm an avid photographer and used bunch of cameras and memory cards that didn't given me any problem like this. Yesterday night when i was transferring files from the SD card to my Laptop, the power supply goes down accidentally and since then, I can't see any of my files stored in there. Moreover, whenever I try to access the stored files, it given me some kind of error messages i.e. Format the drive first!!   I don't know what the hell this is but I need the stored files back. I've found in previous threads that using recovery software could be your last resort. Fortunately, I've found few useful but none of them could actually recover those photos. Stellar Photo Recovery is the tool I've tried to recover photos and luckily, it is showing all my photos there but recovered files can't be open??  If you guys have some better suggestions, please do share it.  P.S. Please, I need the answer immediately or as soon as possible. I've to prepare the presentations for today meeting.   Thanks!!

I know this is not specifically a photography issue but since many of us with prosumer/professional-level DLSRs use Compact Flash cards, it is bound to happen to others as well.  I have a Sandisk 16GB Ultra card that occasionally had the camera reporting inability to access the card. I had to reinsert the card to continue using it. I was able to read the card and transfer the photo files to my computer drive. Today, the same thing happened again, just that nearing the capacity of the card, it failed one last time and the camera was subsequently unable to read it anymore. Despite reinsertion.  My other CF cards never once exhibited this problem, so it's pretty much isolated to this card.  The card is similarly unrecognisable on my computer CF card reader. I think the filesystem is toast, but I suspect the photo files are still intact. I would like to find ways where I can inspect the raw binary data in the card and hopefully recover the photos?


I am using beamer blocks in the default theme to delimit "paragraphs" in a frame. When I use a list within a block, the vertical spacing is different compared to the spacing for a block with no list, which looks odd. Specifically:   the spacing between the block heading and the first line of text in the block is different for simple text vs text in a list (compare blocks 1 and 2 in the MWE); the spacing between a block and the one that follows is different depending on whether the first of the two includes a list or not (compare blocks 1, 2 vs blocks 2, 3 in the MWE).   Is there are way to "fix" either or both of these features?  \documentclass{beamer}  \begin{document}  \begin{frame}{A slide with blocks}  \begin{block}{Block 1}     Some text. \end{block}  \begin{block}{Block 2}    \begin{itemize}    \item item 1    \item item 2    \end{itemize} \end{block}  \begin{block}{Block 3}    Some other text. \end{block}  \end{frame}  \end{document}     Edit Unlike this , the question and MWE here highlight how using a list within a block affects the spacing within the block and between blocks.  As explained in this  to that question, the spacing of items in a list within a block can be changed by resetting \topsep, \partosep, and \itemsep. Implementing the solution in the answer appears to resolve issues 1. and 2. above.

I have noticed that when I have "itemize" environments defined within blocks in beamer, that they introduce more vertical spacing between the top and the bottom of the blocks, than vertical text. Since I have a slide with some text filled blocks and directly after, a slide with only "itemize" holding blocks, I would like the spacing between the itemized text and the block to be the same as for regular text.   On  I have read about "squeeze" option, but it doesn't seem to work...   Additional info:  The problem is in the additional vertical space that is included by the "\itemize" environment. I have found  on how to remove vertical spacing from the itemize list, and I am using this approach. However, it is a brute force approach. What I would like to know if it is possible to have the same vertical space between the end of the itemize list and the bottom of a block, as the one set between the normal text and the bottom of the block.   MWE:   \documentclass[10pt]{beamer} \usepackage{amsmath} \usepackage{amsfonts} \usepackage{amssymb} \usepackage{exscale} \usepackage{epsfig} \usepackage{fancybox} \usepackage{lmodern} \usepackage[T1]{fontenc} \usepackage{overpic}  \usepackage{multimedia}  \usetheme{default} \usecolortheme{crane}  % -- Modifications that enable the footline and set black color for the fonts  \setbeamertemplate{footline}{%     \begin{beamercolorbox}[wd=\paperwidth,ht=2.25ex,dp=1ex,right, rightskip=1mm, leftskip=1mm]{titlelike}         \textcolor{black}{             %\inserttitle\hfill\insertauthor\hfill\insertframenumber%             Something\hfill Something Else \hfill\insertframenumber%         }     \end{beamercolorbox} }  \setbeamertemplate{itemize items}[square]  \setbeamercolor{item}{fg=black} \setbeamercolor{frametitle}{fg=black} \setbeamercolor{block title}{fg=black} \setbeamercolor{title}{fg=black} \setbeamercolor{block body}{bg=white}  % END Modifications  \begin{document}   \begin{frame}   \frametitle{text blocks}     \begin{block}{block}         block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   blockk     \end{block}{block}      \begin{block}         block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block     \end{block}     \begin{block}{block}         block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block   block     \end{block} \end{frame}  \begin{frame}   \frametitle{itemize blocks}     \begin{block}{item}         \begin{itemize}             \item item              \item item              \item item         \end{itemize}     \end{block}     \begin{block}{item}         \begin{itemize}             \item item              \item item              \item item         \end{itemize}     \end{block}     \begin{block}{item}         \begin{itemize}             \item item              \item item              \item item         \end{itemize}     \end{block}   \end{frame}  \end{document}


How can I get the Cartesian product (every possible combination of values) from a group of lists?  Input:   somelists = [    [1, 2, 3],    ['a', 'b'],    [4, 5] ]   Desired output:  [(1, 'a', 4), (1, 'a', 5), (1, 'b', 4), (1, 'b', 5), (2, 'a', 4), (2, 'a', 5) ...]


This is my first question about SQL Server, I'm new to SQL Server and I don't understand few things, so hope you can help me.  We got a SQL Server 2008 with 2 instances and also with Analysys Services installed (on same box).  The server is:     2 Quad core Xeon      80GB RAM   The SQL Server instances are configured by default, but we got times where memory consumption is high and also high pagination is presented, does this means that the memory is incorrectly configured?  Do I need to make changes in the configuration?  Actually, I'm starting to administer SQL Server, so I don't understand many things, any help or document is welcome.  Thanks.

SQL Server is consuming 87.5 % of my server RAM. This recently caused a lot of performance bottlenecks such as slowness. I researched this issue. One common solution I could find on the internet is to set the maximum limit for SQL Server. This was done and much improvement is gained. I want to know why if the maximum memory value is not set why SQL Server keeps consuming the resources


Evaluate the integral $$\int_0^{2\pi} \frac {dx}{1-2r\cos(x)+r^2}$$ and $0<r<1$, using residue theorem. I don't even know how to start this.

Evaluate:  $$\int_{0}^{2\pi} \frac{1}{1+a^2-2a \cos(x)} dx$$  where $a>1$.  I am trying to transform the integral into a contour integral in which the Residue Theorem would apply, but am having trouble.


I saw , where a guy did power line inspection from a helicopter, which is isolated from ground. When he held out a "magic wand," a small amount of arcing came off of the power line to the helicopter.     This got me confused, though, because I thought since he was isolated from ground, the power would not want to go anywhere.   The helicopter simply has no relationship to ground.   So, why does the Magic Wand arc to the helicopter?

When working on high voltage power-lines via helicopter the technician will "bond-on" with a steel wand called a hot-stick. During this process an arc is conducted from the line to the wand. Now, since the helicopter is floating both literally and electrically, why is there any potential between the line and the wand?  My guess is that because of the alternating electric current in the power-line there is therefore an alternating expanding and collapsing magnetic field present in close proximity to the helicopter. This sets up a charge polarization in the frame of the helicopter 180 degrees out of phase with the current and therefore an electrical attraction occurs which produces an electric potential.  If this is true, even though the electrons are not free to move in a bird (as they are in the metal helicopter frame) they are able to rotate and still set up a charge polarization (much like a charged balloon sticks to a wall) and therefore when a bird "bonds-on" to a wire don't you think they feel a little tingle at first?  One other thing. Is it true that by virtue of the fact the the helicopter circuitry is an isolated one, they can bond-on to either line and that line will be the ground reference for the ground of the helicopter circuitry?


When two objects are compared with each other, the latter term of comparison must exclude the former, as in "Iron is more useful than any other metal". If we say "Iron is more useful than any metal", that is the same thing as saying "Iron is more useful than iron", since iron is itself a metal.  I do not understand this. Please, can someone explain what it means?

I was going through the topic "formation of comparative and superlative".       The rule says     When two objects are compared with each other, the latter term of comparison must exclude the former, as in "Iron is more useful than any other metal". If we say "Iron is more useful than any metal", that is the same thing as saying    "Iron is more useful than iron", since iron is itself a metal.   I am finding difficulty to relate the rule with example.


I have been trying to solve this one but I have no clue, I put it into wolfram and the result is absurd, considering this one is taken from MIT bee qualifier 2012, this is the integral: $$\int\frac{x-1}{(x+1)\sqrt{x^3+x^2+x}} \, dx$$


I've run up against a wall trying to get an edit session to work on a version. These are the scenarios Ive gone through in the code and their error mesages:  Setting up an edit session not as a context manager: 'workspace already in transaction mode'  target = r'D:\GIS-DATA\bay-arcgis-pro_ParcelEditing.sde\sde.SDE.Staging\sde.SDE.SPRCodeEnforcementCasesStaging' try:     edit =  arcpy.da.Editor(r'D:\GIS-DATA\bay-arcgis-pro_ParcelEditing.sde')     edit.startEditing(False,False)     edit.startOperation()     with arcpy.da.UpdateCursor(target,'*') as cursor:         for row in cursor:             row[3] = 'test'             cursor.updateRow(row) finally:     edit.stopOperation()     edit.stopEditing(True)  Traceback (most recent call last): File "D:\GIS-DATA\editortest.py", line 9, in <module> for row in cursor: RuntimeError: workspace already in transaction mode   Setting up an edit session as a context manager: 'The requested operation is invalid on a closed state'  target = r'D:\GIS-DATA\bay-arcgis-pro_ParcelEditing.sde\sde.SDE.Staging\sde.SDE.SPRCodeEnforcementCasesStaging' with arcpy.da.Editor(r'D:\GIS-DATA\bay-arcgis-pro_ParcelEditing.sde'):     with arcpy.da.UpdateCursor(target,'*') as cursor:         for row in cursor:             row[3] = 'test'             cursor.updateRow(row)  Traceback (most recent call last): File "D:\GIS-DATA\editortest.py", line 8, in <module> cursor.updateRow(row) RuntimeError: The requested operation is invalid on a closed state   The data is versioned on a SQLServer geodatabase.

I am making my first attempt at editing an ArcSDE feature class with python through a da.UpdateCursor. I'm essentially taking code I've written for a file geodatabase feature class and applying it to an SDE feature class. Doing so produces an error, and I'm not sure how to rectify the problem.   I'm using ArcGIS 10.1 for Desktop.  Pertinent code:  Struxfeature = r"DatabaseConnections\PipelinePathways.sde\PPGIS.Strux\PPGIS.StruxPts_v04_all" P6feature = r"DatabaseConnections\PipelinePathways.sde\PPGIS.Strux\PPGIS.Land_Projects_Parcels_P6"  SDE = r"Database Connections\PipelinePathways.sde" UserID = "E1B8" Parent = "SDE.DEFAULT" version = "change_RW_VC_4447_14_to_C"  #Create Version print "Creating version" arcpy.CreateVersion_management(SDE, Parent, version, "PUBLIC") VersionName = UserID.upper() + "." + version  #Layers arcpy.MakeFeatureLayer_management (Struxfeature, "Struxlyr") arcpy.MakeFeatureLayer_management (P6feature, "P6lyr")  #Switch to version print "Switching version" arcpy.ChangeVersion_management("Struxlyr", "TRANSACTIONAL", VersionName) arcpy.ChangeVersion_management("P6lyr", "TRANSACTIONAL", VersionName)  #Start editing print "Initiating editing" edit = arcpy.da.Editor(SDE) edit.startEditing()  # Start an edit operation edit.startOperation()   #Change P6 project numbers    print "Updating P6.\n" P6Cursor = arcpy.da.UpdateCursor ("P6lyr", ["P6_NBR", "Name"]) for row in P6Cursor:     codecodecode   The error comes from the line 'for row in P6Cursor:'  Traceback (most recent call last):   File "C:\E1B8\ScriptTesting\ScriptsIUse\ChangeP6.py", line 81, in <module>     for row in P6Cursor: RuntimeError: workspace already in transaction mode


Can anybody help me with this? I have some friends that are NOT local so a LAN world would not be able  to reach them, so how would i do this i don't want to make a world wide server that anybody can join. I live in the northern part of the united state's, one of my friends lives in California and one lives in Australia. So how would i go about making a server that BOTH of them would be able to reach?!

I would like to create a minecraft server for me and and my boyfriend to play on.  How do I set it up? Do I need any additional software? Do you have some links to walkthroughs or tutorials?  I have tried to set this up a few times but have failed every time.


I'm looking for an adjective to describe someone who "love life" meaning they love the very fact of being alive, are excited to experience the possibilities of living.  I'm not talking about people loving THEIR personal lives (so words such as happy or fulfilled wouldn't work here) but rather loving life in itself.  This word may be used in a sentence like: " I wish I could be like John he really is a (...) person"

I’m looking for an adjective/ noun that describes a person who loves life, traveling, great food, always doing things which gets adrenaline kicking and is a always ready for attempting things for pleasure only


Prove the following theorem:  ⊢ (P → Q) → (¬ Q → ¬ P) Prove the following equivalence:  (P ∧ Q) → R    ⊣ ⊢     P → (Q → R) Prove the following set of sentences inconsistent: {P → (Q → R), ¬ R ∧ (P ∧ Q)

I can't seem to figure out how to get past this step. Any suggestions?


I have a mixture data. I used EM to estimate the model parameters. When I calculate  the log likelihood function, I found that the values is positive. So, is that ok. Can the log likelihood function be positive?   To be more clear:  $ll = \sum_{n=1}^{N}\log(\sum_{k=1}^{K} \pi_{k} f(x_n;\theta_{k}))$

On the , there is this line:      $p(\mathrm{height}|\mathrm{male}) = 1.5789$ (A probability distribution over 1 is OK. It is the area under the bell curve that is equal to 1.)    How can a value $>1$ be OK? I thought all probability values were expressed in the range $0 \leq p \leq 1$. Furthermore, given that it is possible to have such a value, how is that value obtained in the example shown on the page?


I can no longer see the day of the week by hovering over the date on my Dell latitude using windows 7. Going to  Control panel/ region & Language  / Formats +/- Additional settings doesn't give a dddd option.

Is it possible to configure Windows 7 to use YYYY-MM-DD instead of DD/MM/YYYY as the date format? How? Where?


I'm trying to prove the transformation rules for Dirac Bilinears under charge conjugation as given in "Fundamentals of neutrino physics and astrohysics" by Carlo Giunti et.al. According to them: $$\psi_b\stackrel{C}{\longrightarrow}\,{\psi_b}^C=\xi_b\,C\,\overline{\psi_b}^{\,T}\,,$$ $$\overline{\psi_a}\stackrel{C}{\longrightarrow}\,\overline{{\psi_a}^C}=-{\xi_a}^*\,{\psi_a}^{\,T}\,C^T\,,$$ $$C^\dagger=C^T=C^{-1}=-C\,,$$ so I tried to use these formulas to compute the transformation rule of the most basic scalar and I got \begin{align*} S_{ab}\equiv\overline{\psi_a}\psi_b\longrightarrow\overline{{\psi_a}^C}{\psi_b}^C&= -\,{\xi_a}^*\,\xi_b\,{\psi_a}^{\,T}\,\overline{\psi_b}^{\,T}= -\,{\xi_a}^*\,\xi_b\,(\overline{\psi_b}\,{\psi_a})^{\,T}\\&= -\,{\xi_a}^*\,\xi_b\,\overline{\psi_b}\,{\psi_a}= -\,{\xi_a}^*\,\xi_b\,S_{ba}\end{align*} but, apparently, the minus sign is wrong. Does it has something to do with the components of the spinors being C-valued (or Grassman) numbers? and, if so, which of my steps is wrong?. The book clearly states that it should be + instead of -

TL;DR  When we take the transpose of two Grassmann-valued spinors (fermions), should we add a minus sign because we end up anticommutating the two spinors?    More details.  I'm studying the behavior of 1+1-dimensional Majorana fermion. I use the same representation for the gamma matrices as in Lectures on string theory by Lüst and Theisen, chapter 7 appendix B. That is  $$\gamma^0 = i \sigma^2 \qquad \gamma^1 = \sigma^1 \qquad C= \gamma^0 \qquad \eta^{\mu\nu}=diag(-1,+1)$$  Equation B.3 of these lectures says that Majorana fermions obey the following indentity:  $$ \bar{\psi}_1 \gamma^{\alpha_1} \gamma^{\alpha_2} ... \gamma^{\alpha_n} \psi_2 = (-1)^n \bar{\psi}_2 \gamma^{\alpha_n} ... \gamma^{\alpha_2} \gamma^{\alpha_1} \psi_1.$$  However I cannot prove this identity, I always get the wrong sign on the RHS, even for simple cases such as $n=0,1$ or $2$. For instance for $n=1$, knowing that Majorana fermions are real and therefore $\bar{\psi} = \psi^\dagger \gamma^0 = \psi^T \gamma^0$, we can write the LHS as:  $$\psi_1^T \gamma^0 \gamma^\alpha \psi_2.$$  This is just a number, so it should be equal to its transpose. When we take the transpose, $\gamma^0$ takes a minus sign. If $\gamma^\alpha=\gamma^0$ then this one also takes a minus sign which cancels the first one and we get no overall sign. If $\gamma^\alpha=\gamma^1$ then the 2nd minus sign comes when we anticommute the two matrices. In every case I get:  $$ \bar{\psi}_1 \gamma^{\alpha} \psi_2 =  \psi_1^T \gamma^0 \gamma^\alpha \psi_2 = \psi_2^T \gamma^0 \gamma^\alpha \psi_1 = \bar{\psi}_2 \gamma^{\alpha} \psi_1,$$  even though the identity above says there should be a minus sign. My guess is that when I took the transpose of the LHS, I should have added a minus sign since I inverted two Grassmann-valued spinors in the process, otherwise I don't know what I did wrong.  On a related note, if the sign changes when we swap to spinors, does that imply that the trace of a fermion bilinear is no longer cyclic?  $$\text{Tr}\ \bar{\psi}\psi \neq \text{Tr}\ \psi \bar{\psi} ?$$     but the answer is unclear.  is actually pretty much the same question, but then why this "transpose antisymmetry" only rarely mentioned? Does it only hold for Majorana fermions?


Users can obtain their security token by changing their password or resetting their security token via the Salesforce.com user interface by following the path Your Name | Setup | (Personal Setup) | My Personal Information | Reset My Security Token, and then clicking on the Reset Security Token button.  The above option is not visible in salesforce.com website.

I cannot reset my Security Token in Sandbox Org. The "Reset My Security Token" button in the My Settings, Personal tab doesn't appear. Any idea?


I'm drawing splines in photoshop, exporting as AI, converting online to SVG and importing to blender to extrude and work on them. But they have no fill, so they won't extrude the way I usually extrude SVGs. I know I can fill them in inkscape and reexport, but I believe there is a way to extrude them directly in Blender. Am I right?

I have SVG of a tree. I want to make a 3D model of it. Also I want to add a texture on the front face (on the trunk) of this tree, to make it bumpy. But how can I add a 3d texture on it? I extruded the perimeter, but how to fill in the rest?


Angular velocity is $$\omega= \frac{dƟ}{dt},$$ here $\theta$ and $t$ are scalar quantities. But $\omega$ is a vector quantity. Why is it such?  So far I know the direction of $\omega$ is along the axis of rotation. If so, why?

Does anyone have an intuitive explanation of why this is the case?


Got this   All good, but after I insert a new activity (a new table) the buttons are not responsive even though I give them the classes and trigger the eventListeners.  Atm, my DOM consts are at the top of the JS page, but even when I moved them after the insertion of a new table (activity) in the JS page, still doesn't work.   tldr:    remove and check buttons work with html that is preset on the page; remove and check buttons don't work with html that is inserted with js   newDiv.innerHTML = `

       Title	       Priority	       Description	       Date	       Tasks	       Completed	       Remove

       ${newActivity.title}	       ${newActivity.priority}	       ${newActivity.description}	       ${newActivity.date}	       	       X

`;

I have a bit of code where I am looping through all the select boxes on a page and binding a .hover event to them to do a bit of twiddling with their width on mouse on/off.  This happens on page ready and works just fine.  The problem I have is that any select boxes I add via Ajax or DOM after the initial loop won't have the event bound.  I have found this plugin (), but before I add another 5k to my pages with a plugin, I want to see if anyone knows a way to do this, either with jQuery directly or by another option.


I write this question intrigued by  topic.  The best and accepted answer states that "functioning relationship" means "a relationship that is working properly".  I did some research. The English corpus clearly shows that using "functioning" as an adjective is acceptable. But it is seldom used in the phrase "functioning relationship", and more often used, understandably, in phrases "functioning machine", "functioning computer"...  Anyway to get to the point, can someone explain to me why/how "functioning relationship" means "a relationship that is wroking properly", and not "a relationship that is causing function" - which would be a logical conclusion of its meaning by observing other participial adjectives (boring homework, annoying noise, thrilling experience)  (Not a duplicate because in the other topic my question is not explained. It is just stated as a fact "2+3=5".)

What is the difference between    functional relationship  functioning relationship


I want to establish the following inequality for $x>0$:  $$\phi(x) \left( \frac{1}{x} - \frac{1}{x^3}\right)\leq 1- \Phi(x) \leq \phi(x) \frac{1}{x}$$ with  $\phi(x)=\frac{1}{\sqrt{2 \pi}}e^{-\frac{1}{2} x^2} $ and $\Phi(x)= \int_{-\infty}^x \frac{1}{\sqrt{2 \pi}}e^{-\frac{1}{2} t^2} dt $  Can somebody give me a hint to show this inequality?

$X \sim \mathcal{N}(0,1)$, then to show that for $x > 0$, $$ \mathbb{P}(X>x) \leq \frac{\exp(-x^2/2)}{x \sqrt{2 \pi}} \>. $$


I have model with id and date. Then I make it angular.toJson and send to server. The problem is in that: if my date is empty, model's date field on server shows as {1/1/0001 12:00:00 AM} but not null. How to solve this? I need null.  Here is angularjs controller where my function calls   $scope.filterModel = function (filter) {     postService.getFilteredByUserId($scope.bindModel, angular.toJson(filter)); };   Here is my server function that gets this model  [HttpPost] public IEnumerable<TimesheetModel> FilterModel(TimesheetFilterModel filter) {     return TimesheetService.FilterTimesheetListByFilter(filter); }   Here is model:  public class TimesheetFilterModel {     public int      UserId { get; set; }     public DateTime DateFrom { get; set; }     public DateTime DateTo { get; set; }     public int      TicketType { get; set; } }

I've been searching a lot but couldn't find a solution. How do you deal with a DateTime that should be able to contain an uninitialized value (equivalent to null)? I have a class which might have a DateTime property value set or not. I was thinking of initializing the property holder to DateTime.MinValue, which then could easily be checked. I guess this is a quite common question, how do you do that?


If you view one person's memories in a Pensieve, then how use it in a third-person point-of-view ? I mean, since a person can't see what's happening behind him, how can that the person watching the said memory can ?

You remove your memory from your brain to store in a Pensieve (as Snape or Dumbledore did). Then, you re-watch the memory (e.g. as Dumbledore re-watched his memories of Voldemort's investigations with Harry) in the Pensieve.   Does that mean that you now re-created the memory in your brain (because you remember watching it) and thus you'll need to extract/erase it from your brain again if you don't wish to keep it there for security/capacity reasons (which was why you stored it in the Pensieve in the first place?  Canon answers only please.


Is there a way for me to monitor the activity of a "Guest" on my computer? They know how to delete their browsing history, although they have missed a few.  I need to see what sites they are visiting, and who they are communicating with. If I put a password on the "Guest" account, I'll be the one inconvenienced. This person does need access to the computer in general, so I can't just lock them out. Instead I would like to be able to verify their activities.  Is this possible? Can I do this within Windows?

I have my laptop used by my room mates, I have a user account and everyone knows the password for the same. I don't want to put parental controls on my user account and want to create a room mate specific user account and set parental controls for specific things as below:   No Access to specific drive/ folder in the drive. A installed software in my login available/non-available to other login Limited usage of internet sites(I guess thats to be done in browser)   Just needed that much, :P hope no one gets mad on me. I tried to solve issue by my own but was unsuccessful in 2nd part. :(


So I echo output of my programs ran in terminal by command 2>&1 >> /path/toFile.txt  It creates few limitations that I want to overcome:   It "freezes" and gives no output in terminal - only way to see actual output is to open output file Opening output file is not giving live results. It gives results from time of opening that file     How to echo output to a file and be able to:  a) see live changes in that file (separate program would be needed I assume)  or  b) output to file and see that output in terminal in the same time

I am using:  user@unknown:~$ sudo command -option > log   to save the results of "command" to the file "log", but I'd like to also get the result on the terminal, is this possible?  I am using ubuntu 10.04 lts.


I often see regression expressed in two ways.  The covariates are random: In this scenario, we have $(x_i,y_i) \sim G$ for some distribution $G$ and are i.i.d. for $i = 1, \cdots, n$. We then posit $y_i \mid x_i \sim A$ for some distribution $A$, and we want to successfully parameterize $A$ using maximum likelihood or some other method. The covariates are fixed: In this scenario we have associated points $(x_i, y_i)$. We assume $y_i \sim A$ for some distribution $A$, and we assume $x_i$ parameterizes the distribution $A$ in some way. We then use maximum likelihood to find the best values of the other parameter(s) of $A$.  My question is, is this distinction between random covariates $x_i$ or non-random covariates $x_i$ important? At the end of the day it seems that $x_i$ figures in the pmf/pdf of our distribution $A$ anyhow.

If we have stochastic regressors, we are drawing random pairs $(y_i,\vec{x}_i)$ for a bunch of $i$, the so-called random sample, from a fixed but unknown probabilistic distribution $(y,\vec{x})$. Theoretically speaking, the random sample allows us to learn about or estimate some parameters of the distribution $(y,\vec{x})$. If we have fixed regressors, theoretically speaking, we can only infer certain parameters about $k$  conditional distributions, $y\mid x_i$ for $i=1,2,\dots,k$ where each $x_i$ is not a random variable, or is fixed. More specifically, stochastic regressors allow us to estimate some parameters of the entire distribution of $(y,\vec{x})$ while fixed regressors only let us estimate certain parameters of the conditional distributions $(y,\vec{x_i})\mid x_i$. The consequence is that fixed regressors cannot be generalized to the whole distribution. For example, if we only had $x=1,2,3,\dots,99$ in the sample as fixed regressors, we can not infer anything about $100$ or $99.9$, but stochastic regressors can. This is a rather obscure question as many textbooks only talk about the differences in mathematical derivation but avoid discussing the differences to the extent they can be generalized theoretically.


I need some help and very very fast because my database was injected. I need at least a script that won't allow users to use :[Spaces, Sybols like ('*','=','/','.') and a list of words ('SELECT','FROM','WHERE')] in the text fields of my register form.  I heared something about mysql_real_escape_string(). What is this command doing? And don't post links to PHP: mysql_real_escape_string() Manual because I already read that.

If user input is inserted without modification into an SQL query, then the application becomes vulnerable to , like in the following example:  $unsafe_variable = $_POST['user_input'];   mysql_query("INSERT INTO `table` (`column`) VALUES ('$unsafe_variable')");   That's because the user can input something like value'); DROP TABLE table;--, and the query becomes:  INSERT INTO `table` (`column`) VALUES('value'); DROP TABLE table;--')   What can be done to prevent this from happening?


let's say that I have a python file for some task written in OOP.  some classes in my code use libraries such as pandas, csv ...  Is it ok to import these libraries just before the main() function? Technically it works but I'm not sure if this is the right way  class A class B class C   import csv import pandas  def main ():     #pass if __name__ == '__main__': main()

states:  Imports are always put at the top of the file, just after any module comments and docstrings, and before module globals and constants.  However if the class/method/function that I am importing is only used in rare cases, surely it is more efficient to do the import when it is needed? Isn't this: class SomeClass(object):      def not_often_called(self)         from datetime import datetime         self.datetime = datetime.now()  more efficient than this? from datetime import datetime  class SomeClass(object):      def not_often_called(self)         self.datetime = datetime.now()


There is a new issue in Windows that is preventing mostly any use of the START button with you keyboard. Did anyone figure out a fix yet?   Editor's note from February 5, 2020: Some Windows 10 users appear to be experiencing an issue with task bar search, in which the box appears blank and does not display search results. We're currently investigating the issue and will update this post accordingly with any new fixes we may find.  Things that I tried and did not work for my machine:  Restart the Windows Search service from the task manager. Reindexing - Rebuilding indices from Control Panel -> Indexing Options -> Advance  One thing that works some of the time is to type what I want into the address bar inside File Explorer.

The Search menu on my Windows 10 suddenly stopped working. When I click the Search icon or type something in the Start menu, it just shows a blank search window.    I've tried rebuilding the index, SFC /scannow, DISM Restore, and creating a new local user account. None of them worked.   Windows 10 1909 build 18363.592.