im trying to compare a text in android to avoid refreshing texts if it's not necessary (otherwise the texts for different fields are refreshed every 50ms).  With normal texts it is not a problem. Everything works fine.  But: If there are numbers in text the text seems not to be equal. Why?  Some examples: "Abschaltpunkt" is equal to "Abschaltpunkt" (OK) / "Gewicht" is equal to "Gewicht" (OK) / "100 kg" is NOT equal to "100 kg" (NOK) / "Abschaltpunkt 2" is NOT equal to "Abschaltpunkt 2" (NOK"  A new question after edit (the comparsion works fine now). As you see I use the UI thread for refreshing the text. This app works in a network and receives arround 300 messages per second with different data (yes, it is necessary). Therefore I need the comparsion otherwise the thread is blocked and the app won't respond on user inputs.  Is there another solution? Or is my solution a good one?   This is my code:     /**   * Compares the current and new text und updates the text if necessary   * @param RessourceID given by R.id...   * @param New text   */  private void ChangeText (final int RessourceID, final String sText) {    try {    TextView tv = (TextView) findViewById(RessourceID);    // Erst prüfen ob Text ersetzt werden muss -> Spart Rechenzeit    if (tv.getText().toString().equals(sText)) {     Log.e(this.getClass().getSimpleName(), "Text nicht ersetzen: " + tv.getText() + " != " + sText);    } else {     ChangeTextThread(tv, sText);     Log.e(this.getClass().getSimpleName(), "Text ersetzen: " + tv.getText() + " != " + sText );         }   } catch (Throwable t) {    Log.e(this.getClass().getSimpleName(), "ChangeText", t);   }  }      /**    * Change the text in UI tread     */   private void ChangeTextThread (final TextView tv, final String sText) {    this.runOnUiThread(new Runnable() {       public void run() {                try {         tv.setText(sText);        } catch (Throwable t) {        Log.e(this.getClass().getSimpleName(), "ChangeTextThread", t);        }            }     });   }


wrong voltage when splitting from 5V to 3.3V

I am trying to connect the MMA5452Q accelerometer to arduino on 5V (later it will be substituted with attiny85, hence the 5V voltage). It works just fine when i supply arduino's 3.3V. When i try the 5V supply and split it with resistors (R1, R2, R3) the accelerometer does not work any more. I measured the voltage of the circuit. It is 1.1V but MMA5452Q requires 1.6-3.3V. I was trying different combinations but i am afraid that doing it blindly at some point I will just burn the chip. What is going on here? Could anyone tell me how to connect it so the voltage maches? (And how to calculate this - so I dont need to ask every time :)  )  P.S. R5 and R4 are pull ups required by accelerometer's documentation. Works when the circuit is powered with 3.3V  P.S.S. I am not an electrical engineer. I am hoping that this question is not terribly stupid.         – Schematic created using


When we use mv command, what changes take place in HDD?

Under following conditions-   mv within the same HDD partition mv to a different partition in the same HDD mv to a different device (e.g. USB HDD)   Is the complete file moved or is it a very small change like some pointer reassignment ?


In Star Trek: Discovery (Season 1, Episode 4), the “tardigrade” that the crew of the Discovery had taken from the Glenn      killed Landry, the Security Officer of the Discovery.    This felt, for lack of a better word, rushed. She ordered the tardigrade tranquilized, and was prepared to rush in to lop off a claw, despite Michael’s rather sensible warnings. She was, after all, the Security Officer, and hadn’t shown such extreme recklessness previously. In-universe, why was she so confident that a few seconds of sedation would render it safe to drop the containment field?   It was also rushed on the scale of the show: she was pronounced dead very quickly, and the show moved on to other things (despite her having seemed, in my impression, Lorca’s right hand).  So on a highly related note, was there an out-of-universe explanation for this, which might explain the apparent sloppiness? For example, did the actor not want to sign on for more episodes?


Android studio doesn't detect any connected android device

My device ran into a problem running my test project on my android device after downloading android studio.   How can I configure android studio 2.X to connect to my device through the adb port?


Font not available despite being installed

I have TeX Live installation at ~/texlive/2014.  I installed Lato font package using tlmgr. There are now several .ttf files in ~/texlive/2014/texmf-dist/fonts/truetype/public/lato/  But when I try compiling a file that contains:  \setmainfont[Ligatures=TeX]{Lato}   using xelatex it gives an error:  kpathsea: Running mktextfm Lato /home/user/texlive/2014/texmf-dist/web2c/mktexnam: Could not map source abbreviation  for Lato. /home/user/texlive/2014/texmf-dist/web2c/mktexnam: Need to update ? mktextfm: Running mf-nowin -progname=mf \mode:=ljfour; mag:=1; nonstopmode; input Lato This is METAFONT, Version 2.7182818 (TeX Live 2014) (preloaded base=mf)   kpathsea: Running mktexmf Lato ! I can't find file `Lato'. <*> \mode:=ljfour; mag:=1; nonstopmode; input Lato  Please type another input file name ! Emergency stop. <*> \mode:=ljfour; mag:=1; nonstopmode; input Lato  Transcript written on mfput.log. grep: Lato.log: No such file or directory mktextfm: `mf-nowin -progname=mf \mode:=ljfour; mag:=1; nonstopmode; input Lato' failed to make Lato.tfm. kpathsea: Appending font creation commands to missfont.log.   !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ! ! fontspec error: "font-not-found" !  ! The font "Lato" cannot be found.   How do I correct this?


CSS. Can't center class and it's ':before' element

I'm learning the :before and :after pseudo-elements but I don't understand why it's not centering.  what I have:   my code :  jsfiddle down here     If I remove display: inline-block; the :before element would transition from the left of the page, But I want it from the left of the .title main element.  In short I want to achieve the same effect of transition but I want the text to be centered horizontally.  I want the .title class to be centered horizontally and the .title:before also to be centered horizontally.


What is the temperature inside a black hole?  It may be very cold, or very hot. Or just the surrounding temperature.  Or maybe neither, because the concept of temperature makes no sense inside somehow?


Using Array From Another class Show Null pointer Exception

I'm trying yo use an array that is created in one class and using Clone() To clone it into another class by triggering a method but its throwing a null pointer exception   int[] mat[]; int N;  int SRN; int K; int send[][]; Generate() {   } Generate(int N, int K)  {      this.N = N;      this.K = K;       // Compute square root of N      Double SRNd = Math.sqrt(N);      SRN = SRNd.intValue();      mat = new int[N][N]; }  public int[][] SendAry() {     return send.clone(); }   and call this method from another class and string it in an array      Generate ARY=new Generate();     int Values[][]=ARY.SendAry();


n-1 Independent events , but no n-wise independent examples

For all n ≥ 3, construct an example of a probability space $(Ω_n, P_n)$ and events $A_1, A_2, . . . , A_n$ such that $P(A_i) = 1/2$ for each i, any n − 1 of the events are independent, but the n events are not independent. Can anyone help me construct a concrete example for me? I've been keeping constructing mutually independent events for an hour....  (I tried to use the example of dividing n people into 2 groups...but this does not work well)  Thank you!


sudo apt-get install ubuntu-desktop, Error: unable to locate package

When I try sudo apt-get install ubuntu-desktop I get the error message: unable to locate package ubuntu-desktop. Where do I obtain the package? Or what am I doing wrong?


How do I have my flexbox center on a page?

I have been trying to center my flexbox by adding the code into my parent element but it does not work. What I have now is this  and I would like it to be at the center of my page. I would appreciate some guidance!   .content {   display: flex;   justify-content: center;   align-items: center;   width: 60%;   height: 70%;   box-shadow: 0px 0px 20px 10px rgba(112, 144, 176, 0.2);   margin: 0; }  .content1 {   height: 100%;   min-width: 0;   flex-grow: 2;   /*fills up the space */   flex-basis: 0; }  .content-2 {   height: 100%;   background-color: #7D8FA1;   flex-grow: 1;   flex-basis: 0; }  .photo1 {   width: 100%;   height: 100%; }

Book a consultation

Our team will bring your dream to life.


Is there a parent class/interface for DML Result classes?

I have a generic method that performs DML operations. I want it to return a result list, and I am wondering if there is a parent class/interface that DML Result classes derive from.  All DML Result classes such as SaveResult and DeleteResult seem to share the same methods, which makes me curious about the existence of a higher order.


I'm trying to dual boot Ubuntu 16.04 with Win10 on my MSI and do understand that they're fairly notorious for making linux installs a hassle. I've made pretty minimal progress with the install and get stuck and the load screen whenever I try to install from an ISO on a usb. Ive turned off secure boot, fast boot, and Intel speed technology in the BIOS. I can only boot to the USB when its in Legacy mode, but I feel like it needs to be in UEFI mode for it to boot properly to Ubuntu. I used RUFUS for the USB installer which is compatible with UEFI. Am I no longer looking at BIOS issues and should be looking elsewhere? Any help is appreciated.  EDIT 1: Ive now got a working Ubuntu partition on the HDD however now when I boot the computer back up I can't access grub no matter the priority I set in the BIOS. It just goes straight to windows...  EDIT 2: Ive successfully got my computer to boot to grub every time giving me the option of windows or ubuntu, now there are issues with ubuntu allowing me to log on and use the os. Ive done editing with nomodeset after hitting E with Ubuntu highlighted, but that change doesn't save and if I dont do it every time I cant boot to ubuntu...  EDIT 3: Now I run into a new boot issue. I had it working for a while, got some drivers and Gnome set up, then when I went to restart to check it was solid and sturdy on boot, it hung at the boot screen. Typical purple/black hang error usually solved by nomodeset or nvidia/nouveau.modeset=0, however these solutions didn't work for me. I either experienced the same hang or was left with a text-based boot screen that yet again got stuck  EDIT 4: Last update before I let this question sit. I reinstalled Ubuntu, had to do nomodeset in the try ubuntu option and then install it back into the reformatted partition. Got into the os, it was scaled pretty large so I downloaded the nvidia driver. Restarted to apply changed and wasnt able to boot so went back and did nomodeset again. Got access into OS but the nvidia driver was gone. Redownloaded it with some other drivers and Gnome. Went to log out to change to gnome and every time Id log in the Id get a notification saying Ubunutu has encountered an error followed by a short pause and then I would get kicked from my account and put back to the log in screen. I'm now right back to where I was. Ive narrowed it down to graphic drivers and possibly gnome? I will wait to see if there are other options.  GRAPHICS CARD: Nvidia Geforce 970M CPU: Intel i7 6700 HQ


Does one hold a M.A. 'in' something or 'of' something?

In reading a curriculum vitae, I noticed an author used both   2013 M.A. of Information Science   and    2008 M.A. in Philosophy.   Is there any logic to this? Which one should be preferred for academic cv's?


LaTeX document to epub or mobi ebook formats (with mathematical formulas)

Recently I purchased an ebook reader (Kindle), and I want to export some of my document in LaTeX to an ebook format.  I tried exporting from LaTeX to PDF, but isn't perfect because I have to zoom in-out and move around the page many times (isn't confortable like when you read a normal ebook purshased in book stores). I tried too exporting to RTF, but none of my mathematical formulas were in the output document.  So, do you know a better way to export from LaTeX  documents to ebook formats that includes mathematical formulas? And, that works with Kindle (mobipocket)!


How do you prove that $n^2-1$ is composite when $n>2$?

When $n=2$ we know that  $n^2-1$ is prime but is this the case, when $n>2$?


Saving project with layers as one compiled file?

Is there a way to save a QGIS project as one large file that includes the layers it points to?   I am working with Tecplot quite a bit, which has the option of referencing individual data files or saving all the data as one compiled file. I was wondering if QGIS has a similar capability.  As long as layer locations don't change, I can simply point to the absolute layer location. However, if I want to create a backup disk or hand over the project to a third party, the folder structure may not be preserved.  I found some discussions about QCompile and GeoPackage, which should do what I want, but from what I understand they are still in development stage.


Example of a non invertible fractional ideal

I'm giving a seminar talk on the ideal class group, and am looking for an example of a fractional ideal that is not invertible. Does know of a simple example in say $k[x,y]$ or $\mathbb{Z}[\sqrt{-3}]$. Such examples must exist but computation there is very hard.   Thanks.


Battery warning "Service battery". This warning have appeared in my MacBook Pro (2008) with Snow Leopard. Is there a way to find out what a reason of this warning, without apply to service centre?


When I got confused with the meaning of the phrase "empty use" I searched on the internet for the meaning. I found a section in the book CBSE(Central Board of Secondary Education) entitled INTERACT IN ENGLISH WORK BOOK-Class 9. In this book under Unit-4 (Modals) they say, "Empty use of can and could." Below this headline they gave some examples:         I can smell a fire.   I can hear a weird noise.   She could feel her hair standing up.      Now my question here is why they used the phrase "empty use." I need to know how to use modal verbs in depth because my first language is Kannada so it's very difficult to learn this aspect of English.


Inner div not respecting margin-top relative to parent div

Check this extremely simple html structure. One div inside another, the inner (green) div has margin-top: 100px, the outer (red) div has no margin-top. The outer div is twice (200px) as high as the inner div (100px).   So what would you expect the result to look like? If you're like me, you get the opposite of what you'd naturally expect to get.  My question is NOT how to prevent this. My question is WHY ist this happening this way consistently across all browsers? I mean, this obviously must be the way it's inteded to work, but to me it's strongly counter-intuitive.    .red {     background-color: #a00;     height: 200px; }  .green {     background-color: #0a0;     margin-top: 100px;     height: 100px; }


Why it is good to take log on Finance data? Does it have nice properties?

Just like what I am asking in the title. I see nearly all the financial datas take logs before the data analysing step, Why? Dose it have nice properties?


Parsing mulit-name spaced repeated blocks in XML with C#

I am trying to parse some data out of a response to a SOAP request using C#.  The response has the a Soap Envelope and the Soap Body contains the response from the system.  The response includes a header and then a bunch of repeated blocks of XML information from the original request.  The request was to get the status of a list of tasks, and the response lists each task, the status and some other information.  Here is a mock-ed up sample.  <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">   <soapenv:Body>   <GetTaskStatusResponse xmlns="http://tasktracker.com/2011">      <ResponseHead>         <ResponseId>345234523452346</ResponseId>                     <Timestamp>2014-11-05T09:23:51-06:00</Timestamp>      </ResponseHead>                  <TaskStatusList>            <TaskStatus>               <TaskId>20141155448</AckId>               <FilingId>672</FilingId>               <Status>COMPLETE</Status>         </TaskStatus>          <TaskStatus>               <TaskId>20141135448</AckId>               <FilingId>673</FilingId>                <Status>COMPLETE</Status>         </TaskStatus>         <TaskStatus>               <TaskId>20141154878</AckId>               <FilingId>674</FilingId>                <Status>ERROR</Status>                 <ErrorList>                     <Error>34-5</Error>                     <Error>34-6</Error>                     <Error>77-8</Error>                 </ErrorList>             </TaskStatus>         <TaskStatus>               <TaskId>20154448</AckId>               <FilingId>675</FilingId>                <Status>COMPLETE</Status>         </TaskStatus>      </TaskStatusList>   .... ....  So far I've been able to load the file and add in the first namespace for soapevn to the Namespace Manager  nm.AddNamespace("soapenv", "http://schemas.xmlsoap.org/soap/envelope/");   When I try and Select a single node, this works:  XmlNode node = xml.SelectSingleNode("/soapenv:Envelope/soapenv:Body", nm);   But when I try to dive deeper I get no node found.    XmlNode node = xml.SelectSingleNode(         "/soapenv:Envelope/soapenv:Body/GetTaskStatusResponse/", nm);             if (node == null)             {                 Console.WriteLine("No node found.");             }             else             {                 Console.WriteLine("Found Node");                 Console.WriteLine(node.Value);                 Console.WriteLine(node.InnerText);   I am assuming that it is because of this element:  <GetSubmissionStatusResponse xmlns="http://tasktracker.com/2011">   I tried adding an entry with "" or empty.String with the associated Uri () to the namespace manager object, I does not resolve my issue. My ultimate goal will be to parse the repeating task list and dump those details into a table.  So once I get passed this roadblock, I believe I will need to figure out how to loop through blocks of repeated nodes.


I'm just learning about Cronbach's $\alpha$. I have recently tried to carry out this test. Having 80 completed questionnaires with 15 questions (variables), the questionnaire used the Likert scale 1-5 (1 strongly agree) I have filled the data in, however I've ended up with a negative result! What might I have done wrong?


Is there a Python equivalent to the C# ?. and ?? operators?

For instance, in C# (starting with v6) I can say:  mass = (vehicle?.Mass / 10) ?? 150;   to set mass to a tenth of the vehicle's mass if there is a vehicle, but 150 if the vehicle is null (or has a null mass, if the Mass property is of a nullable type).  Is there an equivalent construction in Python (specifically IronPython) that I can use in scripts for my C# app?  This would be particularly useful for displaying defaults for values that can be modified by other values - for instance, I might have an armor component defined in script for my starship that is always consumes 10% of the space available on the ship it's installed on, and its other attributes scale as well, but I want to display defaults for the armor's size, hitpoints, cost, etc. so you can compare it with other ship components. Otherwise I might have to write a convoluted expression that does a null check or two, like I had to in C# before v6.


The method to get synchronous D-flip flop with three inputs,D,CLK and reset

I want a synchronous D-flip flop with three input,reset,D and CLK,but i can't find it,only four or two inputs,and four inputs just D,CLK,Set and reset ,but find the asynchronous D-flip flop with three input on the Internet.  Can i do anything to let asynchronous D-flip flop become synchronous D-flip flop ? For example,change NAND by AND .  Someone told me : take the 4 input one and ignore the set, that is, hold it false and remove any following logic that no longer changes state as a result,but i don't know last sentence meaning and the method.


How to calculate the percentile, in data NOT grouped?

If i have this sorted data:  $1, 2, 2, 2, 3, 3, 4, 4, 5, 5, 5, 6, 6, 6, 6, 6, 7, 7, 8, 8, 8, 9, 9, 10, 10$  They are 25 numbers.  How should I calculate the quartiles and percentiles?  I try this:  $Q_2 = 2 * \frac{25}{4} = 12.5$  $Q_1 = 1 * \frac{25}{4} = 6.25$   $P_{50} = 50 * 25/100 = 12.5$  Well, but what should I do when it is decimal, for non-clustered data? In some part I have seen,     approach the nearest larger whole.   So, $12.5 \rightarrow 13$  So, $6.25 \rightarrow 7$  In other places I read:     the value will be the average between the data that is at the left of   the position with the data on the right.   So, What should I really do?


Checking from shell script if a directory contains files

From a shell script, how do I check if a directory contains files?  Something similar to this  if [ -e /some/dir/* ]; then echo "huzzah"; fi;   but which works if the directory contains one or several files (the above one only works with exactly 0 or 1 files).


In the ring of continuous functions $\mathbb{R} \to \mathbb{R}$, the set of all $f$ with $f(0) = 0$ is a maximal ideal.

Problem Let $R$ be a ring of continuous functions from $\mathbb{R}$ to $\mathbb{R}$. Show that $A = \{f \in R \mid f(0)=0\}$ is a maximal ideal of $R$.  If $f,g \in A$, then $f-g(0) = f(0)-g(0) = 0$ . So $f-g$ is in $A$. Also $f(0) h(0) = 0$ for all $h \in R$. So $A$ is an ideal. Attempt to show $A$ is maximal If  $R/A$ is a field then $A$ is maximal. Let $f \notin A$. Then $f(0) \neq 0$. Let $g(x)=0$. Then $f-g \in A$. So $f+A = g+A$. $1/g$ is the inverse of $g$. So $f$ has unity (not sure about this). Is this correct?


Evaluate the integral (using partial fractions maybe?)

Evaluate the following integral  $\int{\frac{1}{(x+a)(x+b)}}$  (this might involve partial fraction decomposition, $\int{\frac{1}{x^2+x(a+b)+ab}}$ this is what my first step was)


Can't update ubuntu 14.04 LTS - libpam-systemd reinstall needed

Here is the error:   E: The package libpam-systemd needs to be reinstalled, but I can't find an archive for it.   When I try to update Ubuntu 14.04, I receive the following pop-up windows:     Could not initialize the package information   An unresolvable problem occurred while initializing the package information.      Please report this bug against the 'update-manager' package and include the following error message: E:The package libpam-systemd needs to be reinstalled, but I can't find an archive for it."     I reviewed the following post:   When I attempted to input sudo apt-get install aptitude into Terminal, I received the exact same error message.  Per request, full verbatim results from Terminal:


How to enable numlock at boot time for login screen?

I am trying to force numlock to be on upon initial boot at the login screen on Ubuntu 12.04. The only solutions I have found so far switch numlock on only after initial login.  I'm looking to force numlock to be on when the login screen is displayed, and before the user has logged in. Can anyone assist?


$\newcommand{\intd}{\,\mathrm{d}}$On an AOPS forum a user solved that  $$\int\frac{1}{x(x+1)(x+2)\ldots(x+n)}\intd{x}=\frac1{n!}\sum_{k=0}^n(-1)^k\binom{n}{k}\ln|x+k|+C$$ This to me is absolutely amazing and their solution interesting enough, I am curious as to how I would go about proving this. To me this shouts induction, it is obvious for $n=0$ ($\int\frac1x\intd{x}$) however on the inductive step I could not figure out what to do. Integration by parts did not help and beyond that I am at a loss. I look forward to your responses


Why does "$ sudo echo 'yo' " work even though echo is a shell built in function?

I understand that   sudo cd /directory   will return:  sudo: cd: command not found   because cd is a shell builtin and not a binary. But then, why does   sudo echo 'this is a test'   works fine?  What is really going on here? How does sudo find the command echo if it's not a shell?


Change Mac Address permanently inside /etc/network/interfaces

QUESTION:  How might I be able to specifically change the Mac Address of the enp3s0 and wlp2s0 interfaces through the /etc/network/interfaces file? What code would I have to include inside? I have been trying for some time now without success sadly enough.    ELABORATING:  So I found this great article online explaining how to change a Mac Address permanently through the /etc/network/interfaces file on my Ubuntu.  In the article, it says:      On Debian, Ubuntu, and similar systems, place the following in the   appropriate section of /etc/network/interfaces (within an iface   stanza, e.g., right after the gateway line) so that the MAC address is   set when the network device is started:      hwaddress ether 02:01:02:03:04:08   Source:   Now when I use the following code:  cat /etc/network/interfaces   I get the following output  # interfaces(5) file used by ifup(8) and ifdown(8) auto lo iface lo inet loopback   And when I do ifconfig on my ubuntu, I get back 3 different interfaces:   enp3s0 lo wlp2s0   I would like to change the mac address of all of my interfaces (enp3s0, wlp2s0) (lo is loopback so no need there), but I am unfamiliar with the commands in the /etc/network/interfaces file. I have been looking at tutorials online though I can't seem to get stuff right, and my computer even started acting very strangely a few times afterwards.


Too many (similar) subsites bad for the network/community

There are too many (similar) stackexchange sites! Reasons why this is bad:  Waste of resources (it would be easier to manage and maintain to have fewer) Difficult to choose which one question is best suited for (, ). For a non-tech example, is  really a physics question or more about ?  There is a lot of overlap, for example there is , , and . Furthermore stackoverflow has tags that would make many of the questions on this site be suitable for it. Question may get migrated to a site you don't have an account for  () and may accumulate down and close votes. Smaller community base means fewer people are reading the questions and as such the chance of quality answers goes down Diffusion of responsibility () Sometime questions may be asked with the hope of getting different perspectives and since posting the same question to multiple stackexchange sites is not allowed, this could be a problem. Say for example you want to design something that is user friendly and secure. Different answers we be given on  vs  problems with migration, such as rejected migrations. more difficult to search for questions/answers. Now each possible site must be checked to see if the question was asked. (for example you wouldn't normally think to check both  and  for the same question)  I'm not saying there should only be one site, I am saying there should be fewer and beta sites shouldn't be created so liberally and that the boundaries between sites should be more clearly defined. I've heard a counter argument to this is that subsites were created as a response to new rules being made giving a smaller scope to Stack Overflow. This is not properly addressing the issues, those rules should be changed. Another example is, if someone is trying to setup and IDE on a Mac, should it go on super user, apple exchange, stackoverflow or programmers? It may not be known to the individual if the problem is specific to Mac or the IDE in general. Furthermore, we're now starting to .


Prove that the limit of $\sqrt{n+1}-\sqrt{n}$ is zero

How would I go about proving that $\lim_{n\to\infty}\sqrt{n+1}-\sqrt{n}=0$? I have tried to use Squeeze theorem but have not been able to come up with bounds that converge to zero. Additionally, I don't think that converting to polar is possible here.


I am using the new Photos App (Yosemite). Everything is synchronised (iCloud) but the faces.  Is this a feature or a bug?


VirtualBox not showing 64-bit, even though my laptop is running a 64-bit operating system

I installed VirtualBox 5.2 on an HP 540 laptop running Windows 10 Pro 64-bit.  But in VirtualBox, I can't find 64-bit option.  I didn't find any virtualization technology option in my BIOS setting. After that, I tried to import 32bit virtualbox image and here is an error that is Vt-x ; how to solve it.


Expected Number of Flips for a Sequence of 4 to Repeat

I recently had this question in an interview:     You are flipping a fair coin until a sequence of four flips repeats itself. The sequences are allowed to overlap. What is the expected number of flips?   For example, if you flip HTHTHT, the sequence HTHT appears in flips 1-4 and 3-6. In this case, we are done after 6 flips. As another example, if you flip HHTTHHTT, the sequence HHTT repeats in flips 1-4 and 5-8, and we are done after 8 flips. What is the expected number of flips?  I've been thinking about this question for a few days now, and I haven't come to an answer. I've tried the simpler problem where we consider a sequence of two flips instead of four flips, but it is still rather difficult. I suspect that there is a nice recursive way to solve this problem, but I can't figure it out.  I am also interested in generalizations of this problem. For example, what is the expected number of flips for a sequence of $n$ to repeat itself? What happens if the coin isn't fair?  I have another interview in a few days, so I would very much like to see how to solve this problem in advance. Any help is appreciated.  Edit:  Based on computational evidence (assuming I didn't make a mistake in the code), it appears that the expected number of flips is about 9.81. I would like to know the exact answer, as well as an analytic solution to this problem.  Edit 2:  Another piece of information that may be of use: I had 30 seconds to answer the question. This makes me believe that there is some "easy" way to get the answer, or they were looking for an approximate answer.  Edit 3:  @r.e.s. has kindly provided exact solutions for $n=1,2,3,4,5$. For $n=6$, numerical computation seems to indicate that the answer is around $18.977$ or $18.978$. I will be updating periodically with approximations for other values of $n$.  Edit 4:  $$ \begin{array}{|c|c|} \hline n & E(L_{n}) \\ \hline 1 & \frac{5}{2}\\ \hline 2 & \frac{35}{8}\\ \hline 3 & \frac{435}{64}\\ \hline 4 & \frac{2513}{256}\\ \hline 5 & \frac{57922047}{4194304}\\ \hline 6 & \approx 18.9775\\ \hline 7 & \approx 25.928\\ \hline 8 & \approx 35.288\\ \hline \end{array} $$


How can I get a cabinet projection camera?

How can I get a camera to render with a ?  I know it is possible to get a , but that's not really what I want.  I've tried positioning an orthographic camera in almost all possible ways but still can't get one. Actually an orthographic camera wouldn't work because as soon as you get the world x-axis parallel to the viewport x-axis, the world y-axis is always parallel to the viewport y-axis.  I think it is something like shearing, but I am not so sure.  Cabinet projection:


How do I preview the look of my frame before taking the shot, on the LCD of my D5100 after altering the settings?

I just bought a Nikon d5100 and everything seems to be working pretty fine. Except for the fact that I am unable to preview the shot I'm willing to take. When I turn my LCD it shows me what the camera is seeing. But when I change settings like iso, f stop etc and try to see how it has affected my frame, the LCD just doesn't show it. It still shows me what my camera is seeing.  If there are any adjustments I need to make in the settings please let me now. I would like to see how the change in iso or f stops would affect my image even before I click like in Canon, on my LCD. The reason I'm stressing on the same point again and again is because someone asked this question earlier and most of the people who replied didn't understand the question.


Need to Typeset twice for correct compile?

Whenever I press CMD+T in TexShop, the PDF created is not always updated correctly. I usually have to re-compile it to update the Table Of Contents and other changes I have made. How can I fix this ?  Using MACOSX 10.8 - TEXSHOP 3.11


I see from this question that you can transfer a world from PE version to the PC version. ()  Is it possible to go from the PC back to the PE? (IOS)  Basically, my son is only using PE version now. If I got the PC version can you keep the two synchronized and if so how hard is it to do?


Getting actual file name (with proper casing) on Windows

Windows file system is case insensitive. How, given a file/folder name (e.g. "somefile"), I get the actual name of that file/folder (e.g. it should return "SomeFile" if Explorer displays it so)?  Some ways I know, all of which seem quite backwards:   Given the full path, search for each folder on the path (via FindFirstFile). This gives proper cased results of each folder. At the last step, search for the file itself. Get filename from handle (as in ). This requires opening a file, creating file mapping, getting it's name, parsing device names etc. Pretty convoluted. And it does not work for folders or zero-size files.   Am I missing some obvious WinAPI call? The simplest ones, like GetActualPathName() or GetFullPathName() return the name using casing that was passed in (e.g. returns "program files" if that was passed in, even if it should be "Program Files").  I'm looking for a native solution (not .NET one).


I have written a loop to iterate all .out c binary file and copy their outputs into a text file (the output for every binary file is just a one line hash value, one line output for one program). Here is my code so far:  for j in {1..10} do     ./gcc-$j.out >> gcc-result.txt done   Unfortunately, some binary files have some unknown issues and cannot be correctly executed (they got stuck and cannot proceed to the next program).  I am not going to fix those c code but I want my bash to automatically jump to executing the next program within a given timeout (say 10 secs), and also write "0" to the gcc-result.txt.  Thanks in advance if you have idea to solve this issue.


maximum of modulus polynomial of degree $n$ in circle of radius 1

Good time of day. Can you help me please with this task? Consider a polynomial of degree $n$ with leading coefficient equal to 1. Prove that the maximum of its modulus in a circle of radius 1 not less than one. When it is equal to one? I tried to use Rouche's theorem. But it was unsuccessful. Thank you


Let $R$ be a ring, and let $M$ be an $R$-module. Can we characterize when the canonical map $M \rightarrow [[M, R]_{R \text{-mod}} , R ]_{R \text{-mod}}$ sending $a$ to $\hat{a} : [M, R]_{R \text{-mod}} \rightarrow R$ sending $\phi$ to $\phi(a)$ is an isomorphism? If $R$ is a field and $M$ is finite dimensional over $R$, then this map is an isomorphism. Are there other criteria on $R$ and $M$ for this map to be an isomorphism? What is a general context for this to hold?


Duty Free in the USA. Why do I have to be given my purchase as I board the plane?

I am not one for buying things in airports but recently my wife asked me to get her an alcoholic beverage while flying from the USA to Ireland (JFK-DUB). I made the purchase in JFK and was surprised to be told I had to collect it when departing for my flight as I board the plane. The sales assistant's English wasn't their best so I may have misheard and my Yorkshire twang may have thrown her, but I was somewhat surprised as to why I couldn't carry the bag myself to the plane.  Is there a law that prevents me from carrying my purchase to the plane or is this an added service I was charged, which I was duped into paying?  When boarding the plane there were several others who had to pick up their sealed duty free bags (why sealed?) so it wasn't just me. No explanation was given.


How do I share a single computer among different users?

I know that every operating system worth using supports multiple independent users; this makes it easy for several people to share a single computer, with their own documents and everything. However, there is one small problem: the sharing can't occur simultaneously.  Remote Desktop or other similar software allows people to connect to a computer from somewhere else and log-in as any user, without disturbing other users. However I wonder, isn't is possible for multiple people with different user accounts to use a computer at the same time, locally, via multiple monitors and input devices? I tried plugging in a second keyboard, mouse and monitor, however, Windows will mirror or extend the display to the second monitor and the second set of input devices become pretty much like... well... I can't think of anything useless enough to compare them to.  How would I share a single computer with different people? Assume I have a keyboard, mouse and monitor for everyone, connected to multiple video cards (either multiple outputs on a single video card or one monitor/card).


Magnetic stripe or EMV (chip-and-pin) credit cards in France?

We are US travelers who will be spending 2 weeks in France (Bordeaux through Provence to Nice) in mid-April 2013.  We understand that Europe is well ahead of the US in the use of EMV (chip-and-pin) technology for credit cards, and all of our cards are traditional magnetic stripe only.  We would like to use a credit card for as many expenses as possible.  We will be using public transport as well as renting a car, purchasing gasoline, etc.  What is the current state of EMV vs. magnetic stripe card acceptance in France?  Should we inquire about EMV cards with our card issuers?


I'm trying to display a 4-bit binary number on a 7 segment LED as a hexadecimal number (0-F). I have an assortment of 7400 series ICs including the 7447. But that one only works for BCD (0-9). The 7400 series doesn't seem to have a hex to 7-segment decoder and I don't have one on hand.  So I figure I'd have to build my own. The datasheet for a 7447 comes with the internal circuitry but I couldn't find a similar circuit for hex to 7-segment. I did K-diagrams for each LED segment by hand but the terms are rather large, much larger than for BCD.  Does anyone have a finished circuit for this that I can check my work against?  Does anyone have an optimized circuit for this that takes advantage of common subterms? There aren't many duplicate terms (like A0 & ~A1 & A2) but maybe using (A0 & A2) & ~A1 would allow sharing the (A0 & A2) subterm and overall reduce the gate count.  Or maybe some tricks to use NAND, NOR or XOR gates for some parts?  I don't care about different path length or races in the circuit as it's only going to drive LEDs and should be far too quick to see any of that.


Fibonacci Numbers Identity ${F_n}^2 + {F_{n+1}}^2 = F_{2n+1}$

Prove the following identities involving Fibonacci numbers: $${F_n}^2 + {F_{n+1}}^2 = F_{2n+1}.$$ I am not sure how to work with the 2n's.


We all know  Leptokurtic ~ Kurtosis > 3 and Platykurtic ~ Kurtosis < 3  I am bit confused about the shape of the curve. Somewhere I had read that since the area under the curve should be 1, for leptokurtic distributions (since the peak is higher than the Normal distribution), the tails approach the X - axis much earlier than in case of Normal distribution i.e. when the pdf is plotted, the tails in case of leptokurtic lie below Normal curve tail so I guess leptokurtic has got a thin tail.   On the other hand, in case of platykurtic, the peak is less than the normal curve, however it's tail will lie above the Normal curve tail and is fat tailed. This is my understanding and I might be grossly wrong.  However, when I had referred many sites or went through Google images, I came across many instances where the Peak was shown much higher than the Normal distribution and also the tail lying above Normal distribution curve.  So I am very confused now as I am not a hard core statistician but will certainly love to clarify my doubts and learn few things. Also, I am not sure if FAT tail is synonym for HEAVY tail. Can someone explain this in simple words so that a moron like me will be enlightened.


Do legendaries respawn after defeating them?

If I kill a legendary in ORAS that I find in a mirage spot will it respawn?


Is it correct to use "their" when referring to a single person when the gender is known?

I have come accross this sentence:     There is a 2.5% probability that whenever we measure a woman, their height will be less than 142 centimeters.   Is the use of their correct here? Shouldn't it be rather her?


How are children prepared when they have to swear

In Stranger Things Season 2, , and in Kick-Ass Chloe Moretz  her parents gave her permission to swear as well.  When the script is written and given to the children, do the parents read it and determine if it's okay for them to swear?   Are the children told by the production crew that these words should only be said on set of this movie and not in real life?


I am asking this as there does not seem a clear way to diagnose the problem. I have searched several sites including this one.  After a few minutes Xubuntu freezes and I can't use the mouse or keyboard. I need to hard reboot but the cycle starts again. I have a desktop PC running Xubuntu 14.04 LTS on kernel 3.13.0-48-generic. It is an older PC.


Callback after the record was created using e.force:createRecord

Are there a way to add callback after the user created a record and clicked the Save button?  I am using a custom tab and custom components and open the Create a record modal window using e.force:createRecord, but I was not able to find out how to attach callback to the event.  I even found :     Currently force:createRecord event does not accept any callback method or any after save event to handle custom action. Current force:createRecord always redirects to the newly created record. But in case if you want to just close the force:createRecord popup after save and refresh some other related component using the refresh is not possible.    So, is it really impossible? If so, what are current workarounds here?


sum of perfect cubes formula proof without induction

is there any proof for the sum of cubes except induction supposition? there are some proofs using induction in below page


Applying Mapnik style for OpenStreetMap data in ArcMap?

I am loading OpenStreetMap vector data into ArcMap (using the Download and Symbolize OSM Data tool of ). I'm sure there must be a simple way to apply the style/symbols of the Mapnik baselayer as rendered on the OSM website (), rather than using the ArcMap defaults or manually adjusting symbology for each feature type, but I just can't figure it out.  Can someone point me to a potential solution?


Why universal instantiation cannot be used here?

I have a following sentence:      $$\forall x~(Fx \to \forall y~(Fy \to Gy)) ~\vdash~ \forall x~(Fx \to Gx) $$   Why I cannot use UI twice and get:      $$Fa \rightarrow (Fa \rightarrow Ga) $$   This is my proof:  1) $\forall x~(Fx \to \forall y~(Fy \to Gy))$  $\quad$2) $Fa \to (Fa \to Ga)$  $\qquad$3) $Fa$ (Assumption)  $\qquad$4) $Ga$ (From 2,3)  $\quad$5) $Fa \to Ga$  6) $\forall x~(Fx \to Gx) $  And the second line was marked as the wrong one by somehow.  Thanks in advance.


How to restore Mac OS X on a new hard-drive?

I am going to upgrade my MacBook Pro hard-drive, but before doing so I'm trying to figure out how to restore OS X on it. My DVD drive doesn't work so I cannot re-install from the DVD.  I have a recent Time Machine backup, is that enough to restore the OS? And in that case, what would be the procedure? Also, in case the Time Machine restoration fails, is there any way to re-install OS X from a USB or external hard-drive? Any suggestion would be much appreciated.


Community Wiki posts don't change usernames if the user does

If a user changes their username, it appears that Community Wiki posts of theirs don't update to display the new username.  See it in action: .  (It's also possible that this is caused by the lock on the question, but it should be updated either way.


Can we contact the author of a rejected edit?

I just saw a user who has   to  a question on Meta. Judging by the edit comments, the user seems to be mistaken about the nature of Meta Stack Overflow.  I would like to point this out to the user, but this user has no posts on any Stack Exchange sites; this user's reputation comes strictly from suggested edits.  Can we @-comment the submitter of a rejected edit? It would be helpful in showing editors how the system works.


I´m using ubuntu 12.04 LTS (precise/amd64), I have installed virtualbox-4.3, I was forced to install it with a downloaded package (.deb) because I could not download it normally, I used "Free Download Manager" to download it because the speed was horrible (50KB/s and stuck everytime), and today I was doing apt-get update/upgrade and have a update for virtualbox.  First, I want to know if I download the virtualbox-4.3_4.3.12-93733~Ubuntu~precise_amd64.deb and use the dpkg -i it will update the package without overwriting my settings (or not).  Second, I want to know if is just with me this problem that is so slow the speed (In all computers in my network).  I found a similar question here: .  I think this will solve my problem, I will test and after I will post if it worked.


python raw string notation with a variable. Lib.re / pypi.regex

I'm familiar with how to use something like pattern = re.compile(r"stuff")  where stuff is whatever regex pattern I want to use.  What I am trying to figure out is there a way to use the r flag with a variable?  Like below  def getFileLike(foo):    pattern = re.compile(r foo)    result = re.search(pattern,"some string")   i've tried pattern = re.compile(usr_pattern, -r) and pattern = re.compile(r usr_pattern) but none of it compiles and they throw various errors.  So I'm sticking with something like  def getFilesLike(flag):     if flag:        pat = re.compile(r".txt")     else:        pat = re.compile(r".png")   I've also tried reading the documentation below and also searching for "raw string". I'm not finding anything.  I would love it if someone could confirm if this is possible or point me in the right direction.


How to extract text between 2 words in PostgreSQL?

I have a column criteria which contains below similar text in each of its row:-  inclusion : ajjsdijd sdsjdjs ieroeito trorg inclusion sdkjwedk  exclusion : sdkjwdowek  ksdldk exclusion skdkefk kfkwkfwe    I want to extract the text between first inclusion and exclusion occurance. So, here i want result as   ajjsdijd sdsjdjs ieroeito trorg inclusion sdkjwedk   Also, I want to extract the text after first exclusion keyword:  sdkjwdowek  ksdldk exclusion skdkefk kfkwkfwe    I am currently using below PostgreSQL but this creates issue and picks text between first inclusion and last exclusion..  substring(lower(criteria) from 'inclusion(.+)exclusion') substring(lower(criteria) from 'exclusion(.+)')


Linux - Understanding an stdin/stdout command "<"

I just started a short video course on Linux and kind of get the use and function of stdin and stdout. I saw on the course though that the instructor used cat < [nameOfExecutable]. I tried looking around though I can't seem to find what its call and what's for (possible due to my lack of fundamentals).  What is difference does it make adding the "<" symbol?  Let us say for example: cat < [nameOfExecutable] vs regular cat [nameOfExecutable]?


does $x^{ \frac{1}{3} }$ have a tangent line at x=0?

it is not differentiable but it should have a tangent line, x=0 as in the y-axis, still, no?  how is the notion of the derivative and the existence of a tangent line reconciled here?  (yes, I know there are repeated versions of this question but I haven't seen one talk about the tangent line perspective)


ConcurrentModificationException when trying remove element from list

Well, i already read the others posts and can't solve my problem. I have a dataTable (JSF) binding in my ManagedBean. I have a list of selected elements and i wanna remove this elements, see:  public void removeSelected() {      for (Map.Entry<Integer, Boolean> entry : registrosSelecionados.entrySet()){        if (entry.getValue() == true){            int id = entry.getKey();            Iterator<Bean> it = beans.iterator();            while(it.hasNext()){            Bean b = it.next();            if (b.getId().equals(id)){                setBean(b);                deletar();            }            }        }     }     }   My method above call another method named 'deletar()', see:   public void deletar() {     try {           //Se o bean for nulo então capturamos o bean selecionado no DataTable, se este existir         if (bean == null){         if (dataTable == null){             throw new RuntimeException("O bean é nulo e não há dataTable vinculado ao ManagedBean. A deleção será abortada");         }         bean = (Bean) dataTable.getRowData();         }          beforeRemove();         getBoPadrao().delete((AbstractBean) bean);         addInfoMessage("Registro deletado com sucesso");         beans.remove(bean);         bean = null;         afterRemove();     } catch (BOException e) {         addErrorMessage(e.getMessage());         FacesContext.getCurrentInstance().validationFailed();     } catch (Exception e) {         e.printStackTrace();         logger.error((new StringBuilder()).append("Erro ao deletar: ")             .append(e.getMessage()).toString());         FacesContext.getCurrentInstance().validationFailed();         addErrorMessage((new StringBuilder()).append("Erro ao deletar. ")             .append(e.getMessage()).toString());     }     }   The Bean is deleted from Database but when try remove from "List" i got error:  Jan 31, 2015 5:38:32 PM com.sun.faces.context.AjaxExceptionHandlerImpl handlePartialResponseError Grave: java.util.ConcurrentModificationException     at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:859)     at java.util.ArrayList$Itr.next(ArrayList.java:831)     at br.com.jwebbuild.mb.BasicCrudMBImpl.removeSelected(BasicCrudMBImpl.java:226)   EDit 1  I tried to edit my deletar() method putting a iterator to remove element but didn't work, the error continue.  public void deletar() {     try {           //Se o bean for nulo então capturamos o bean selecionado no DataTable, se este existir         if (bean == null){         if (dataTable == null){             throw new RuntimeException("O bean é nulo e não há dataTable vinculado ao ManagedBean. A deleção será abortada");         }         bean = (Bean) dataTable.getRowData();         }          beforeRemove();         getBoPadrao().delete((AbstractBean) bean);         addInfoMessage("Registro deletado com sucesso");          Iterator<Bean> it = beans.iterator();         while (it.hasNext()) {         Bean b = it.next();         if (b.equals(bean)) {             it.remove();         }         }          bean = null;         afterRemove();


Where shall we go? Where should we go? Shall we eat outside? Should we eat outside?   Which is correct and why? Thank you in advance.


Not sure if this belongs here or at serverfault...  I've seen websites where, to login to the website, requires a digital certificate to be installed for the user logging in. As far as I can tell, this certificate is in addition to the website using an SSL certificate (https)  I'm just looking to be pointed in the right direction on how to code for this (apache / php hopefully), who issues these certificates (must it be a trusted var or can I ?) or even what to search for via google.  -Mario


Script to convert images in subfolders to individual PDF's

I am looking for a way of automating a manual conversion of directories containing images (jpgs & pngs) into PDF's.  For example ..  I currently use the following command to achieve what I want but I have to do this manually for each directory so it can become a little time consuming, etc  convert DIRECTORY1/*jpg DIRECTORY1.pdf convert DIRECTORY2/*jpg DIRECTORY2.pdf convert DIRECTORY3/*png DIRECTORY3.pdf   I would like a way of converting all the directories in the current location to individual pdf files at once.  Any help would be appreciated.


Can the ECDSA still work without present of hashing function?

According to walkthrough steps for ECDSA topic from wikipedia as shown below, What if the impact if we don't apply the hashing function (highlighted in blue in the image) to the raw messages? Although this sounds a bit silly, but let's say we have both with or without SHA256 engine test cases like below. Hex Message (256 bits): "0123456789012345678901234567890123456789012345678901234567890123" Hex Message after SHA256 (256 bits): "9674d9e078535b7cec43284387a6ee39956188e735a85452b0050b55341cda56" Can anyone explain what is the problems with the first Hex Message if I proceed with this to the subsequent ECDSA signing flow? Just assume Alice signed the raw message in this case?


Where an ellipsis exists, is there a term for the missing text?

Suppose there is a long sentence like:      This London hit show took America by storm, full of charm, humour and delightful songs that make it a perfect theatrical event for the entire family.   And you want to cut it off after an arbitrary specified amount of characters like so:     This London hit show took America by storm, full of charm, humour and delightful songs that make...   What is the name for the missing text indicated by the three-dot ellipsis?


Articles in English, the use of "the" and "a"

The following are sentences I picked up from newspaper articles.   "A smiling Ichiro Suzuki(a popular baseball player) talked at the interview through an interpreter." "The 22-year-old XXX (a popular golf player) is a 12-time champion on the International Golf tour."      I don't understand why they put an article "a"  in the sentence 1)  and "the" in the sentence 2).  Please help me understand why.  Thank you in advance.


How to Remove Autostart for Certain Apps?

is there any way you can install an app (for instance WhatsApp) on Android 4.2.1 ICS but at the same time remove its autorun properties sothat it becomes a standalone app and ONLY uses memory, processing power and even more dear battery, only during the time that I start the application. After closing it I want it to remain unstarted!  Note: this is different than autokilling it with taskkiller and alike. I want the app to not start in the first place).  I find myself installing and de-installing certain apps to overcome this dilemma and I hope there is a better solution otherwise whats the point of Android freedom feeling, right?


Hey all I am stuck I don't know what video format I need to do to export as mp4 in blender animation


Showing that the sequence $z^n$ is normally but not uniformly convergent

I was able to show that $z^n$ is normally convergent on the unit disk centred at the origin, but I am not sure how to show that it is not uniformly convergent on the unit disk centred at the origin.  I've read in a few places that this is true, but I have not seen a proof.  My first idea was to fix an $\epsilon$ such that $\epsilon=1/2$.  Then $|z^n|<1/2$.  However, I haven't been able to get this to work out.


From distribution function to probability measure

So assume we have a probability space $(\Omega, \mathcal{F}, P)$ and a random variable $X : \Omega \rightarrow \mathbb{R}^*$. We can derive from this a distribution $P_X$, and a distribution function $F$. My book says that when working with distribution function directly we have no need to know the underlying probability space since everything is well determined. We just need to show that we can find one. So here is my attempt :   Here we start with the distribution function $F$. increasing and right continuous, st. $F(\infty) = 1$ and $F(-\infty) = 0$. We define :   \begin{align} P_I : I &\longmapsto [0,1] \quad I \in \mathbb{R}^2 ( interval) \\ [a,b] &\longmapsto F(b) - F(a) \end{align}   We can define $P_X$ on the borel sets by decomposing the set into disjoint intervals :    \begin{align} P_X : \mathcal{B}(\mathbb{R}^*) &\longmapsto [0,1] \quad B = \dot \bigcup B_i \quad B_i \in \mathbb{R}^2 \\ B &\longmapsto \sum_i P_I[a_i,b_i]  \end{align}   By taking $X$ as the identity function we have $\Omega = \mathbb{R}^*$ and $P = (P_X)_{\Omega}$   I suspect that I can use the fact that F is increasing and right continuous to say that we can find a measure $\mu$ s.t $\mu(a,b) = F(b)-F(a)$ and then use this measure as probability measure. But I'm scared to miss any vital step along this way.  I would like to know if there is any flaw in my reasoning. Or anything missing. Thanks for any input !


If I want to create new taxonomies (e.g. Project / Documents / Etc...) is it better to create them in the theme's functions.php or within a plugin?

I'm trying to create new taxonomies. What is the best practice? Many thanks.


Display reputation by post type on user summary page

I would like to see a breakdown of reputation by post type on the user summary page.    This would help show, at a glance, how much someone actually knows vs. how good they are at asking questions.  For instance:     Reputation from Questions - 10,015 from 1024 posts   Reputation from Answers - 110 from 11 posts   Reputation from Edits - 400 from 1000 edits     I would take any answers the above person gave me with a grain of salt instead of assuming they were knowledgeable because they have 10k rep.  We already have a multitude of other readouts on the new page, so this shouldn't up the clutter factor too much either.


Why are there only RGB and RGBW-LEDs, but none with more chips inside one housing?

In  the question emerged, where the LEDs with 5 or more dies of different colours are. (Kudos to Brian Drummond) The background is as follows:  RGB LEDs are very popular for creating colourful lighting effects. In fact, due to the three receptor types in the human eye virtually every possible colour we can perceive can be produced with a red, a green and a blue LED although the LEDs can produce only a very delimited section of the visible spectrum. With three colours it is even possible, provided a perfect mixture ratio, to produce a light perceived as a pure white. The human vision cannot recognise different light sources if they excite the three colour sensing cones in the eye at the same levels. This effect is called metamerism.  However the human can very well perceive the quality of light sources when light is being reflected by coloured surfaces or objects. Because the reflection of light on coloured surfaces is effectively a multiplication of the light spectrum with the remission spectrum of pigments. The remitted spectrum differs vastly for different sources of white light.  To cut a long story short: White light from RGB-LEDs is a mess. If you try to use it for general illumination purposes, colours of artwork are reduced to a greyish mélange and human skin looks like beeing afloat in a quarry pond for a week.  White LED having a blue chip and a conversion layer produce considerably better light for illumination but can't be tuned to produce light with different colour temperatures let alone pure colours.  While there are some LEDs with a white chip and three colour chips in one housing, those usually tend not to address a better colour rendering but to have a higher luminous flux at white light.   So the question with some additional words is:   Why are there no multichip LEDs (5 or more chips) for the production of light with higher colour rendering?


Which version of Debian is Ubuntu 18.04 based on?

Which version of Debian is Ubuntu 18.04 LTS based on? Assuming I do not have access to verify this on an existing Ubuntu 18.04 instance.


Is there a way to set mouse work like this: If i move cursor to one side of edge of screen instead of stopping it came out from opposite side of screen. I have pretty good reason for this.  I am trying to play game on chrome OS in android and using octopus keymapper but mouse stuck on edge of screen.


How to enable core dump in my Linux C++ program

My program is written in C++. compiled with gcc, using -g3 -O0 -ggdb flags. When it crashes, I want to open its core dump. Does it create core dump file, or I need to do something to enable core dump creation, in the program itself, or on computer where it is executed? Where this file is created, and what is its name?


should base case always be the front of mathematical induction?

For both strong and common induction, $K + 1$ seems not rely on base case(s), just needs $K$ be true,   However, if base cases are not true, the induction below are meaningless.   so can I put base case anywhere, just before the conclusion(e.g. So, the statement holds true!)


I am using Linux Mint and tethering Internet through my phone.  Every time I enable tethering, my DNS on computer is being set to 127.0.0.1 which results in being unable to resolve any name. I have to manually open "network settings" panel and change DNS to 8.8.8.8 (google's DNS). It works till next time I enable tethering (that is, multiple times per day).  I have tried saving them in network connection panel for this particular connection, but it seems to be completely ignored.  I have also tried to edit /etc/resolv.conf and even remove write permissions, but sooner or later it gets overwritten anyway.  What is changing my DNS settings and how to make it stop?


Can not get the changed value of input fields which are created dynamically

I have a button in my Html. If I clicked the button then two input field generates. I set a default value for the input fields. But I want to change the value. Whenever I change any value, I try to get the changed value of the input field through jQuery. But I can not access that. I only get the event.target. But I want the changed value. So far  I tried the following.    <button type='button' id="add">click</button>


What would happen if there were two Collectives?

Consider this: An instance occurs where two Borg Collectives are formed. I'm not asking how that would happen, I'm asking WHAT would happen. The two groups are the same in practically every way, but they were somehow programmed to be enemies. Would one eventually assimilate the other, and become one? Would they simply fight until there's nothing left? Thank you for your time.


automatic replacement of 1+ authors with et. al. in citations in text

I have looked into multiple questions about this already, but none of the answers seems to work on my problem. I am using biblatex for referencing. When citing in text, i would like to have : (Author et. al. 2010). For now it is working for all my references, but for 2 or 3 articles.   Here is my code   \documentclass[12pt,a4paper,oneside]{book} \usepackage[backend=biber,style=authoryear,maxbibnames=20,maxcitenames=1]{biblatex}  \addbibresource{mybibliography.bib}  \printbibliography   and mybibliography.bib  @article{pinxten2017risk,   title={At-risk at the gate: prediction of study success of first-year science and engineering students in an open-admission university in Flanders—any incremental validity of study strategies?},   author={Pinxten, Maarten and Van Soom, Carolien and Peeters, Christine and De Laet, Tinne and Langie, Greet},   journal={European Journal of Psychology of Education},   pages={1--22},   year={2017},   publisher={Springer} }   I want to get :  \parencite{pinxten2017risk}      (Pinxten et al. 2017)   but instead i get:   \parencite{pinxten2017risk}      (Pinxten, Van Soom, et al. 2017)   How can i fix this?


I need to debug JavaScript in Internet Explorer 7. Unfortunately, its default debugger doesn't provide me with much information. It tells me the page that the error showed up on (not the specific script) and gives me a line number.  I don't know if that is related to my problem. It'd be nice if it could narrow down the error to a line number on a specific script (like Firebug can). Is there an addon to debug JavaScript in IE7 like Firebug does in Firefox? Thank you! See also:


Possible to make MySQL use more than one core?

I've been presented with some dedicated MySQL servers that never use more than a single core. I'm more developer than DBA for MySQL so need some help  Setup  The servers are quite hefty with an OLAP/DataWarehouse (DW) type load:   Primary: 96GB RAM, 8 cores + single RAID 10 array Test: 32GB RAM with 4 cores The biggest DB is 540 GB, the total is around 1.1TB and mostly InnoDB tables Solaris 10 Intel-64 MySQL 5.5.x   Note: The biggest DB is the replicated one from the OLTP DR server and the DW is loaded from this. It isn't a full DW: just last 6 months to 6 weeks so it is smaller than the OLTP DB.  Observations on a test server   3 separate connections each has a concurrent (and different) ALTER TABLE...DROP KEY...ADD INDEX the 3 tables have a 2.5, 3.8 and 4.5 million rows CPU usage goes up to 25% (one core is maxed out) and no higher the 3 ALTERs take 12-25 minutes (a single on the smallest takes 4.5)   Questions   What setting or patch is required to allow more than one core to be used? That is, why doesn't MySQL use all cores available? (like other RDBMS) Is it a consequence of replication?   Other notes   I understand the difference between an RDBMS "thread" and an OS "thread" I'm not asking about any form of parallelism Some of the system variables for InnoDB and threads are sub-optimal(looking for a quick win) Short term, I'm unable to change the disk layout OS can be tweaked if needed A single ALTER TABLE on the smallest table takes 4.5 minutes (shocking IMO)   Edit 1   innodb_thread_concurrency is set to 8 on both. Yes, it's wrong but won't make MySQL use multiple cores innodb_buffer_pool_size is 80GB on primary, 10GB on a test (another instance is shut down). This is OK for now. innodb_file_per_table = ON   Edit 2   innodb_flush_log_at_trx_commit = 2 innodb_use_sys_malloc = ON innodb_flush_method should be O_DIRECT (but SHOW VARIABLES doesn't show this) innodb_doublewrite = OFF File system = ZFS (And my sysadmin found this: )   To test   innodb_flush_method isn't showing as O_DIRECT when it should be will follow RolandoMySQLDBA's settings   Let me know if I've missed anything important  Cheers  Update  Changed innodb_flush_method + 3 x thread settings in RolandoMySQLDBA's answer Result: > 1 core used for the tests = positive result


How do I find a point a given distance from another point along a line?

I have $(x_1, y_1), (x_2, y_2)$.  How do I find the point that's $d$ distance away from $(x_1, y_1)$ on a straight line to $(x_2, y_2)$?  I know I can get the length of the line with Pythagoras. I know if I drew a circle I could use the radius as distance and the point would be where the line and the circle intersect.  Could someone briefly explain each step to me please?  I don't understand


Survival probability of 1D Random Walker

For a 1 D random walk on $Z$ axis, starting at $z=0$, equal probability to go to right or left, what is the probability that during the first k steps the walker's position remains $z\leq m$?  This is also called the survival probability. I can write is as a sum of first passage time probabilities, but I am looking for a closed form.  Thanks,


Why does this hyperboloid change into a surface?

Given this equation $x^2+y^2+z^2+2xy+2xz+2yz-x-y-z=6$ and the corresponding quadric:    If I rearrange the equation to $(x+y+z-3)(x+y+z+2)=0$ (which is equivalent), I get:    So, which is the right quadric to my equation? Why does it have two representations?


Limit without l'Hopital or Taylor series: $\lim\limits_{x \to 0} \frac{x\cos x- \sin x}{x^3}$

find the limit without l'Hôpital and Taylor rule :  $$\lim\limits_{x \to 0} \frac{x\cos x- \sin x}{x^3}=?$$  My Try :  $$\lim\limits_{x \to 0} \frac{x\cos x- \sin x}{x^3}\\=\lim\limits_{x \to 0}\frac{x\cos x \sin x- \sin x\sin x}{x^3\sin x}=\\\lim\limits_{x \to 0}\frac{x\sin 2x- \sin^2 x}{2x^3\sin x}=$$?  what now ?


Square bracket notation for dimensions and units: usage and conventions

One of the most useful tools in  is the use of square brackets around some physical quantity $q$ to denote its dimension as  $$[q].$$  However, the precise meaning of this symbol varies from source to source; there are a few possible interpretations and few strict guidelines. What conventions are there, who uses them, and when am I obliged to follow them?


How to create a label with QGIS project path in print composer?

Is there a way in the Print Composer of QGIS to create a label that will automatically update the path of the QGIS project?


How to automatically set the width of an HTML element to the width of the enclosed text

Here is an example:  I would like for the width of the h1 or a surrounding div to "clip" the text so that I can, for example, draw a border around only the text.


Is Object(argument) a function? what does it return?

The following code is used to check variable type and filter array   const filter = (predicate, xs) => xs.filter(predicate) const is = (type) => (x) => Object(x) instanceof type filter(is(Number), [0, '1', 2, null]) // [0, 2]   Q1: I don't understand what the usage of Object(...), what does it return? if I directly use x, the code doesn't work  const filter = (predicate, xs) => xs.filter(predicate); const is = (type) => (x) => x instanceof type; filter(is(Object), [0, '1', 2, null]) // [];   Q2: the value returned by Object(...) is instance of Object and Number/String, why is that?     Object('1') instanceof String && Object('1') instanceof Object;//true Object(2) instanceof Number && Object(2) instanceof Object;//true typeof Object(2) //"object"   It really confuses me a lot, thanks for your support!


Let $G$ be a graph of order $n$ with $\kappa (G) \geq 1$. Prove that $n> \kappa(G)[\operatorname{diam}(G)-1]+2$   I know $\kappa(G) \leq n-1$. I do not know if do we have to prove it by induction or there is another way.


In C#, how to check if a TCP port is available?

In C# to use a TcpClient or generally to connect to a socket how can I first check if a certain port is free on my machine?  more info: This is the code I use:  TcpClient c; //I want to check here if port is free. c = new TcpClient(ip, port);


For an outer measure $m^*$, does $m^*(E\cup A)+m^*(E\cap A) = m^*(E)+m^*(A)$ always hold?

Let $m^*$ be an outer measure on a set $X$. Is the following equality always true for every  $A \subset X$ and measurable set of $ E\subset X$ ?   $m^*(E\cup A)+m^*(E\cap A) = m^*(E)+m^*(A)$  Note: I read Another thing on   .  but in the book of Aliprantis that is always true . thanks


bounded monotone continuous function is uniform continuous

If $f: \mathbb R \to \mathbb R$ is bounded, increasing and continuous. Does $f$ have to uniform continuous?     I know the answer is yes if $f$ has domain to be any open interval, say $(0,1)$. But I don't know how to prove this case. Any help is appreciated.


Lost Ubuntu upon re-installing windows 7

After re-installing Windows 7 I can't boot to Ubuntu anymore.  I keep getting message:   can't find `\Ubuntu\winboot\wubildr.mbr   Prior to the re-install there was no problem.


Show that every open set in ℝ can be written as a countable union of open intervals

This is what I have so far.   Let U ⊆ ℝ where U is open. By a theorem we have that all real numbers are uncountable and that rational numbers are dense in ℝ.


Difference between real_escape_string and prepare()?

prepare() seems a bit tedious and unnecessary for a majority of my code. If I send a string in a SQL command, why can't I just sanitize it with real_escape_string? What's the difference? That's what I've been doing all the time and it worked well against SQL injections... Thanks.


Sort user defined objects with multiple constraints in a single stretch using java

I'm having employee objects and i want the sorted list by name in descending order and salary in ascending order.   class Employee {      String name;     Long salary; }


How can I save apples pieces that became black?

Apple pieces became black very quickly. How can I save them?


Python:How is the output of first code a list ?Can't understand

Code:  def op(*ar):   for i in ar:     print(i)  arg=['yel','5',6] op(arg)   Output: ['yel','5',6]  Code:  def op(ar):   for i in ar:     print(i)  arg=['yel','5',6] op(arg)   Output:   yel \n5 \n6(This output is understood)


Hierarchy in chat between sender & receiver

Why is it that many chat applications, the chat messages you send yourself are often highlighted with color, whereas the messages of the person you are talking to are often grey & seemingly lower in hierarchy?  Isn't the message of the other person more important than your own message, as the content of this message is the reason why you're visiting the chat, not to read your own message again.  Is it because it makes it easier to make the difference between you vs. the rest in group-chat?  Examples:   Whatsapp  Facebook Messenger


Compare two views that present two different content type and delete nodes

this question is like this:   I didn't know why but i make this question with another account that i cannot got access now So the problem is: I got two views. View A and View B. View A rapresent contents of type A (30 contents for example) and view B rapresent contents of type B (30 contents for example). By comparing the various nodes contained in these two views i want to found (among the nodes contained in the view B) contents with the same title of some nodes caontained in the view A and delete them. After this operation, View A got 30 nodes and View B got 3 nodes because got 27 nodes with same title of some nodes in the View A. I try to do this in a Rule with view loop but i didn't know how to delete nodes with the same title. I try with VBO but i cannot make this process i think, cause i need to delete nodes selectively  Thanks and sorry for the duplicate post (i need to do this cause i cannot reply with old account)


Special character from mysql to a php form

So I have a problem with a simple character. I am trying to print º from mysql but I always get �. Database is set to utf8, connection and meta too.  $conn->set_charset("utf8");  <meta HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">


I have a couple of questions about tensor products:  Why is $\text{Hom}(V,W)$ the same thing as $V^* \otimes W$?   Why is an element of $V^{*\otimes m}\otimes V^{\otimes n}$ the same thing as a multilinear map $V^m \to V^{\otimes n}$?   What is the general formulation of this principle?


If a function $f$ is continuous $\implies$ $|f|$ is continuous.(Answered by Myself)

$(i)$ Given a function $f:E \rightarrow \mathbb{R}$ define $|f|:E \rightarrow \mathbb{R}$ by $|f|(x)=|f(x)|$ for $x \in E$ show if $f$ is continuous at $c \in E$ then so is $|f|$.        $(ii)$ Now the converse is not true, find $f$ such that $|f|$ is continuous but $f$ is not.


I'm using Ubuntu 11.10, and am trying to mount a freenas server.  I have the server set to share in cifs and nfs with no luck.   I have tried smbmount //192.168.1.### /mnt/  I am not new to Ubuntu but am nowhere near a power user, so I'd prefer a GUI option if available.  How do I mount a cifs share in 11.10?


Apache serves some files, others get 403

I've just setup a CentOS 5.5 install with Apache and Mapserver.  While trying to do the tutorial for mapserver, I've found that Apache returns 403 forbidden when accessing any of the tutorial files, yet for any file I create and upload it serves it normally.  When checked with ls -l the permissions are exactly the same, the user and group are exactly the same, and the files are in the same folder - yet I can't access a .txt from the tutorial whereas if I copy the contents into another file I can access it.  Apache's error logs simply say I don't have permission to access the file, so isn't telling me anything more useful, and my searches have all told to ensure the permissions are set correctly (they look the same).  It's a fresh install with my web docs residing in /var/www and find /var/www/ -name .htaccess doesn't return anything so I'm confident there aren't any .htaccess files preventing my from accessing anything.  nginx can serve the files properly, Apache can't, so I think this narrows it down to a permissions issue within Apache but don't have a lot of experience with Apache and can't think of where to begin.  Any idea where I should look next?


Why do I have to enter my password to log in?

Using the Stack Exchange login, why do I have to enter my password again and again to log in? Wasn’t the whole purpose of OpenID to do away with this?  This doesn’t even only happen when visiting a new Stack Exchange site – it also happens for sites where I already have an account but which I don’t visit regularly. Here’s what I mean:    Of course I don’t remember my password (it’s a long random string). And so I have to go to my password manager and manually copy the password from openid.stackexchange.com’s account into the login form. – And incidentally, this is what my password manager looks like now:    (And, by the way, those are the only entries in my keychain so far, but by far not the only SE sites where I have an account.)  … I feel that this defeats the purpose of site-wide login and OpenID. In the olden times when MyOpenID was still working properly, I’d simply enter my OpenID on the login form, and the software would take care of the rest – namely, redirect to the OpenID service, (automatically) verify that I was authorised to use it, and redirect back to the original website, having logged me in. It was literally one button click for me. It’s substantially more work now, and I’d like to understand why this regression is necessary.  (Note: of course once a site’s password has landed in my password manager I (probably?) won’t have to enter it again. But still: wasn’t site-wide login and OpenID supposed to solve this already?)


Getting a webpage to take up 60% and be centered?

I'm trying to create a website whose body up the middle 60%. I thought I'd do this:     body {   align-items: center;   text-align: left;   justify-content: center;   width: 60%; }     But that's not working :(   I even tried using translateX to translate right 20%   Any advice? Suggestions?


Why does the 'i' in 'explain' disappear when written as 'explanation'?

The word 'explain' has an 'i'.  Why does that 'i' disappear when we write it as 'explanation'.


Show $E(T^r) = e^{r\mu +\frac{r^2 \sigma^2}{2}}$ in a lognormal distribution.

I'm asked to prove that, if $T$ follows the $LN(\mu, \sigma^2)$, then  $$E(T^r) = \exp\left(r\mu+ \frac{r^2\sigma^2}{2}\right)$$  Can anyone help?


My program cannot find the properties file

I'am making a multimodule maven project with Swing. I need to load and upload some properties but when I try to load the inputStream it gives me null. So if i try to use that data the console gives me a NullPointerException.  My console:  java.lang.NullPointerException     at java.util.Properties$LineReader.readLine(Properties.java:434)     at java.util.Properties.load0(Properties.java:353)     at java.util.Properties.load(Properties.java:341)     at Configuration.PropertiesMenager.getPropertiyByValue(PropertiesMenager.java:18)     at GraphicInterface.GInterface$3.actionPerformed(GInterface.java:176)     at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2022)     at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2348)     at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402)     at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)     at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:252)     at java.awt.Component.processMouseEvent(Component.java:6539)     at javax.swing.JComponent.processMouseEvent(JComponent.java:3324)     at java.awt.Component.processEvent(Component.java:6304)     at java.awt.Container.processEvent(Container.java:2239)     at java.awt.Component.dispatchEventImpl(Component.java:4889)     at java.awt.Container.dispatchEventImpl(Container.java:2297)     at java.awt.Component.dispatchEvent(Component.java:4711)     at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4904)     at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4535)     at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4476)     at java.awt.Container.dispatchEventImpl(Container.java:2283)     at java.awt.Window.dispatchEventImpl(Window.java:2746)     at java.awt.Component.dispatchEvent(Component.java:4711)     at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:760)     at java.awt.EventQueue.access$500(EventQueue.java:97)     at java.awt.EventQueue$3.run(EventQueue.java:709)     at java.awt.EventQueue$3.run(EventQueue.java:703)     at java.security.AccessController.doPrivileged(Native Method)     at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)     at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:84)     at java.awt.EventQueue$4.run(EventQueue.java:733)     at java.awt.EventQueue$4.run(EventQueue.java:731)     at java.security.AccessController.doPrivileged(Native Method)     at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)     at java.awt.EventQueue.dispatchEvent(EventQueue.java:730)     at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)     at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)     at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)     at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)   My method. The param String value is hardcoded for now and it belongs to my "keyset" in my properties file:  public String getPropertiyByValue(String value) throws IOException {         Properties prop = new Properties();         String propFileName = "AutoDeploymentModel\\configuration.properties";         String result = "";         InputStream stream = getClass().getClassLoader().getResourceAsStream(propFileName);         try {             prop.load(stream);             result = prop.getProperty(value);         } catch (Exception e) {             e.printStackTrace();         }         return result;     }   SOLVED  Call easy way the file without any kind of path, and resolved the body intructions with:  InputStream i = null; try { i = new FileInputStream("configuration.properties"); prop.load(i); ..... }


The observable universe is limited by a cosmic horizon. Galaxies beyond the horizon move away from us faster than light, so we cannot see them. Imagine a spaceship in the vicinity of our horizon. If the ship is stationary relative to the local galaxies there, we would see it moving away from us near the speed of light due to the space expansion.  Now the ship takes off in the direction away from us with a relativistic speed relative to the local galaxies there. What would be its speed relative to us? Would the ship cross the horizon and disappear from our view even though the ship still is not as far away from us as the actual horizon? Or would the relativistic speed addition apply allowing us to still see the ship (albeit deeply redshifted)?


Install libopencv-dev 32bit on 12.04 64bit

I've already installed the 64bit version of the package libopencv-dev and want now to install the 32bit version.  I tried the command:  sudo apt-get install libopencv-dev:i386   but got the following error message  The following packages have unmet dependencies:  libopencv-dev:i386:    Depends: libopencv-core-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-ml-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-imgproc-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-video-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-objdetect-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-gpu-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-highgui-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-calib3d-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-flann-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-features2d-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-legacy-dev:i386 (= 2.3.1-7) but it is not going to be installed    Depends: libopencv-contrib-dev:i386 (= 2.3.1-7) but it is not going to be installed  E: Unable to correct problems, you have held broken packages.   Is there a conflict with the 64bit version?


How do I connect two PS3 to the same PSN account

I have two ps3's and wanted to know if I can connect them to the same PSN account as when I try to log the second one onto the account I created on the first one it says you cannot log onto someone eses account (or something like that).  I set up a psn account on the second ps3 but want to use the same one as the first.  The first machine was switched off at the time; I want to be able to download purchases onto both my machines.


What are we plotting the residuals of a simple linear regression against if we want a normal probability plot?

I understand the interpretation of what occurs when we plot residuals for a normal probability plot, but I am trying to recollect/understand what we are plotting those residuals against?  It would make sense to plot the residuals against the theoretical "error" values, but we don't have those. So what is it we are using per se? This is all under the assumptions of a simple linear regression where the errors are assumed to be normally distributed with constant variance. I should also add this is at the level of an introductory course on linear regressions.


How do you pronounce it would, it was, etc ( in American English) ? That is, how do you pronounce the "T" when it precedes a semi-vowel like w? Is it a stop T, or even no T at all when pronounced fast ? When followed by a vowel, it's a "flap T" ( ex: " it is") , and when followed by a consonant, it's a full T ( ex: "it looks"), as far as I can see, but this I can't nail down.


Why can only some of the Pokémon speak English

I recently saw the 1998 film Pokémon: The First Movie (I can't recommend it), which from my understanding is a direct tie-in to the show. What I don't understand about this film is that all of the Pokémon can only talk using their name... except for two. Mewtwo can talk, and so can this cat-like Pokémon whose name eludes me (he works with Team Rocket). Oddly enough the cat-like Pokémon’s clone cannot speak but I assume that because it was just 'born' it just hasn't learned how yet. I assume that Mewtwo's ability to speak is because the engineers made him that way since Mew can't speak, but I still don't know about the other one. Is there an explanation for this?


On a grid, what is the area of effect of Spirit Guardians?

I'm unclear on what the area of effect of Spirit Guardians is on a grid.  The spell has a range of Self (15-foot radius).  Additionally, the description of the spell says that      You call forth spirits to protect you. They flit around you to a   distance of 15 feet for the Duration.   The problem here is that on a grid, an "area of effect with a 15-foot radius" is not the same as a "all targets within a distance of 15 feet".   An area of effect with a 15-foot radius would fall under the general rules for areas of effect on a grid (DMG p.251), for example as discuss .  The later could be interpreted as a range of 15 feet, or 3 squares away on a 5 feet grid.  On a 5' grid, what does the area look like?  Does it take one of the following shapes?          EDIT: this is not a duplicate of the Scroll of Protection question; the Scroll clearly has a cylinder area of effect, while the Spirit Guardians affects targets 15 feet away from the caster.


$$\sum_{r=1}^{45} \tan^2(2r-1)°$$  I tried simplifying it to Cosecant terms and use complex numbers and binomial theorem... I know the answer but not the solution so I can verify your answer once you post it... I am using the Euler form for Sin but then I am stuck..


What's intended by the semi-colon in this sentence?

Purposely means both "on purpose, by design; intentionally, deliberately".  Why use a semi-colon here rather than a comma?


Preprocessing for Text Classification in Transformer Models (BERT variants)

This might be silly to ask, but I am wondering if one should carry out the conventional text preprocessing steps for training one of the transformer models? I remember for training a Word2Vec or Glove, we needed to perform an extensive text cleaning like: tokenize, remove stopwords, remove punctuations, stemming or lemmatization and more. However, during last few days I have had a quick jump into transformer models (fascinated btw), and what I have noticed that most of these models have a built-in tokenizer (cool), but none of the demos, examples, or tutorials are performing any of the these text preprocessing steps. You may take  for instance, there are no text preprocessing involved for the demos (maybe it is just a demo), but at  the whole sentences are passed without any cleaning: texts = ['I really love the Netflix original movies',          'this movie is not worth watching'] predictions = learner.predict_batch(texts)  The same is true for the  by HuggingFace. Or many tutorials that I have looked at (take  or ). I can imagine that depending on the task this might not be required, e.g. next work prediction or machine translation and more. More importantly I think this is part of the contextual-based approach that these models offer (that is the innovation so to say) that are meant to keep most of the text and we may obtain a minimum but still good representation of the each token (out of vocabulary word). Borrowed from  by HuggingFace:  Tokenisation BERT-Base, uncased uses a vocabulary of 30,522 words. The processes of tokenisation involves splitting the input text into list of tokens that are available in the vocabulary. In order to deal with the words not available in the vocabulary, BERT uses a technique called BPE based WordPiece tokenisation. In this approach an out of vocabulary word is progressively split into subwords and the word is then represented by a group of subwords. Since the subwords are part of the vocabulary, we have learned representations an context for these subwords and the context of the word is simply the combination of the context of the subwords.  But does that hold true for tasks like multi-label text classification? In my use case the text is full of not useful stopwords, punctuation, characters and abbreviations and it is multi-label text classification as mentioned earlier. And in fact the prediction accuracy is not good (after a few rounds of training using ). What do I miss here?


How to convert this very simple .htaccess to Nginx?

I'm using this .htaccess that pass everything after URL to $param, so example.com/news/id goes to PHP as $_GET['param']='news/id'. But Nginx is always throwing me to 404 page.  My .htaccess:  RewriteEngine On RewriteCond %{SCRIPT_FILENAME} !-f RewriteCond %{SCRIPT_FILENAME} !-d RewriteRule  (.*) index.php?param=$1    What I tried in Nginx default.conf:   server {         listen 80;         listen [::]:80;     server_name domain.com;         root    /var/www/html;          location / {                 if (!-f $uri){                         set $rule_0 1$rule_0;                 }                 if (!-d $uri){                         set $rule_0 2$rule_0;                 }                 if ($rule_0 = "21"){                 rewrite ^(.*) index.php?param=$1;                 }         } }


What's the simplest way to add water mark using DPP4 that is professional looking?

Whats the best but simplest way to add water mark using DPP4?  I cant find anything to create and save watermarks to use.


Java division operator is not giving the expected result

I am doing a simple operation of a multiplication and a division in the following manner in Java.  100 * 44907280.59 / 44907280.59;   I was expecting it to give me 100, but it was giving me 99.999999....  I tried searching Google for the related help, but I could not get any. And if I remove the multiplication part and just divide like below  44907280.59 / 44907280.59;   the result I see is 1.0  Can someone please explain me what is going on here?


python Using variable in re.search source.error("bad escape %s" % escape, len(escape))

i have this simple string : ss = os.path.normpath('sql/foo/my-script.sql') regex1 = re.compile(r'{}'.format(ss))  getting : Traceback (most recent call last):   File "c:\Python36-64\Lib\sre_parse.py", line 855, in parse     p = _parse_sub(source, pattern, flags & SRE_FLAG_VERBOSE, 0)   File "c:\Python36-64\Lib\sre_parse.py", line 416, in _parse_sub     not nested and not items))   File "c:\Python36-64\Lib\sre_parse.py", line 502, in _parse     code = _escape(source, this, state)   File "c:\Python36-64\Lib\sre_parse.py", line 401, in _escape     raise source.error("bad escape %s" % escape, len(escape)) sre_constants.error: bad escape \c at position 17  UPDATE here is the full example with the re.escape the result is None sss = os.path.normpath('sql/foo/my-script.sql')     xx = r"C:\xxx\xxxx\temp\downloads\xxx\sql\foo\my-script.sql"     regex22 = re.compile(r'{}'.format(re.escape(sss)))     gg1 = regex2.search(xx)


R raster: masking a raster by polygon also remove cells partially covered?

I want to mask out a raster based on the values of a polygon: i.e., set to NA all values of the raster that are not covered by the polygons. However, it seems that raster::mask() masks out cells (i.e. set them to NA) even if they are partially covered?  This is similar to the question: , but unlike crop(), mask() does not have the snap="out" option.   Check: here the right point of the triangle touches a cell, yet that cells is masked out.   library(raster) library(sp)  r <- raster(xmn=1, xmx=5, ymn=1, ymx=5, nrows=4, ncols=4) r[] <- 1:length(r)  Sr1 = Polygon(cbind(c(2,4,4,1,2),c(2,3,5,4,2))) Sr2 = Polygon(cbind(c(4.1,4,2),c(2,3,2)))  SpP = SpatialPolygons(list(Polygons(list(Sr1), "s1"), Polygons(list(Sr2), "s2")), 1:2)  plot(mask(r, SpP)) plot(SpP,  add=TRUE)


I found this problem and according to Wolfram Alpha, the answer is 2.  $$\prod_{n=0}^{\infty} \left (1+\frac{1}{2^{2^n}}\right)$$  Please do the favor of explaining me how the product is 2.


I would like to create my own server so that my brother and I can play together. I have tried writing in seeds and it won't work for me. How can I create my own server?


Is it possible to use Druidcraft and Control Weather to tell if a given event will succeed?

Example: a Druid and his party decide to go get rid of an orc tribe. The weather is currently clear, with no precipitation. If the party succeeds in clearing the orc tribe, the Druid will use control weather to make it rain heavily. If they don't, he'll not change the weather.  Is it possible to tell if a given event will succeed by using this trick?


I am using python to extract Emails from web using re library. it does its job but it extracts links that match the pattern. For example: /images/paramproofs/services/pgp/logo_black_16@2x.png /images/paramproofs/services/twitter/logo_black_16@2x.png /images/paramproofs/services/github/logo_black_16@2x.png /images/paramproofs/services/reddit/logo_black_16@2x.png /images/paramproofs/services/web/logo_black_16@2x.png /images/paramproofs/services/web/logo_black_16@2x.png /images/paramproofs/services/stellar/logo_black_16@2x.png /images/badges/install-badge-windows-168-56@2x.png /images/badges/install-badge-windows-168-56@3x.png  This is the pattern I use: (?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[ a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])


I am using Ubuntu 16.04 and now I need to install Windows 7 along with it.  I only have one sda1 partition on my HDD and it occupies the whole space, so how can I dual boot my system?


By mistake I created a file named --help trying to get help about the command >  > --help   If i try to delete the file like this:  rm --help   the help about the command rm is shown.


Finding $A$ and $B$ using $ A \times B = \text{lcm}\,(A,B)\times\text{hcf}\,(A,B)$

The highest common factor and lowest common multiple of two numbers $A$ and $B$ are $12$ and $168$ respectively. Find the possible values of $A$ and $B$ with the exception of $12$ and $168$.  I know this question involves the concept of  $ A \times B =  \text{lcm}\,(A,B)\times\text{hcf}\,(A,B)$   But I'm not sure how to apply it. Can someone guide me? Thanks!


How do you find all $n$ such that $\phi(n)|n$

Where $\phi(n)$ is the Euler phi function, how do you find all $n$ such that $\phi(n)|n$?


I want to Create a slideshow lockscreen using the GNOME desktop. I am running Ubuntu 16.04 LTS.  I am particularly talking about the "lockscreen" not the Login screen, and definitely not the wallpaper...  It should basically be like Windows spotlight.   Any help will be highly appreciated,


Prove that $f(x)=\begin{cases}1& \text{if x is rational},\\0 &\text{if x is irrational}\end{cases}$ is discontinuous at every real number.

Let $f:\Bbb{R}\to \Bbb{R}$ be defined by  $$f(x)=\begin{cases}1& \text{if x is rational},\\0 &\text{if x is irrational.}\end{cases}$$  Prove that $f$ is discontinuous at every real number. I realize that if $x_0\in\Bbb{R} $, then every neighborhood of $x_0$ contains rational points (at which $f(x)=1$) and contains irrational points (at which $f(x)=0$). I see that the existence of $\lim\limits_{x\to x_0}f(x)$ is also in question. From here, I don't know how to proceed. Can anyone help me out?