Inducing orientations on boundary manifolds

Given a $k$-manifold $M$, such that $\partial M$ is a $(k-1)$-manifold, there is a standard way in which $\partial M$ inherits the orientation of $M$. So if $M$ is oriented by the form field $\omega$, then $\omega_\partial=\omega(v_{\text{out}},v_1,\dots,v_{k-1})$ orients $\partial M$, where the $v_1,\dots,v_{k-1}$ are basis vectors for a tangent space on a point of the boundary, and $v_\text{out}$ is an outward pointing vector (see here: , which follows the exposition of Hubbard & Hubbard).  In practice I find this very difficult to interpret. How can one find this $v_\text{out}$ in practice?   For instance, take $M$ to be defined by $z=x^2+y^2$ for $x\ge0$ (technically a manifold with boundary, in fact a half-paraboloid). It's a fact that $\partial M$ is defined by the parabola $z=y^2$. If $M$ is oriented by $dx\wedge dy$, how does this induce an orientation on the boundary (in fact we should obtain a 1-form that induces an orientation on the boundary)?   Note: I find the whole discussion of boundary orientation to be rather clumsy in its exposition. In the case of surfaces inducing orientations on boundary curves, I was originally taught to imagine that the normal vector that induces the surface orientation is me walking on the surface. This normal should walk along the boundary such that the surface lies to its left. OK - but how does this translate to the $v_{\text{out}}$ interpretation, so that we can generalize to other dimensions easily?)  Edit: An ideal answer would merge the intuitive approach with the rigorous approach, if possible. I would grateful to anybody who could help order my (at present confused) understanding!


How do I use PGP with Thunderbird in 16.04?

I'm an Ubuntu newbie. Can anyone tell me how to set up PGP on Thunderbird today? It looks like it may have changed.  Should I download more of the canonical apps (an option in software setup)?


How to convert android.net.Uri to java.net.URL?

Is there a way to convert from Uri to URL? I need this for a library I'm using, it only accepts an URL but I need to use an image on my device.


Let A and B be subsets of a universal set U.  If $A \subseteq B,$ then $B' \subseteq A'$ For the above question I'm trying to solve it by contrapositive proof. I was suggested by some friends that it can also be solved using proof by contradiction. Can someone tell me how this could be done by proof by contradiction?


Proof that two basis of a vector space have the same cardinality in the infinite-dimensional case

I am having a difficulty setting up the proof of the fact that two basis of a vector space have the same cardinality for the infinite-dimentional case. In particular, let $V$ be a vector space over a field $K$ and let $\left\{v_i\right\}_{i \in I}$ be a basis where $I$ is infinite countable. Let $\left\{u_j\right\}_{j \in J}$ be another basis. Then $J$ must be infinite countable as well. Any ideas on how to approach the proof?


How to tell latex what i write should stay as it is, and not as a mathematical expression

I'm trying to write my thesis on Latex and I don't have much experience with it. I try to put an information about some arrays i used as a table one like looks like this: column names:      FileName, Strain, Replicate   for this i use this code:  \begin{tabular} US45102998_251897210500_S01_GE1_107_Sep09_1_3.txt & RAL765 & 1 \\ \end{tabular}   what LaTeX thinks it is: US45102998251897210573S01GE1107Sep0911.txt It creates this line where the numbers after underscore are subscripts of the former text. I used  \textdollar{} and it didn't work for me . I used \verb{}, and it worked (it didnt turn the text into a mathematical expression), but now I see "}" sign right after the text and it doesn't break the line.   the full code is:  \begin{center} \tablehead{Array Information} \toprule \tableheadline {File Name} & \tableheadline{Strain} & \tableheadline{Replicate} \\ \midrule  \hline} \tabletail{\multicolumn{4}{r} {Continued on next page...} \\} \tablecaption{Array information} \xentrystretch{0} \begin{tabular}{llll{5 cm}} \label{xtab: arrayinformation}   And at the end it is:   \hline \end{xtabular} \end{center}   Any suggestions? Note: i'm not so familiar with LaTeX lingo.


What is @property_name declaration means in C#?

I was browsing sources for  microsoft .netcore runtime and came across these lines of code  as you can see they are using @ symbol infront of every error message getter like @Error_InvalidFilePath. My question is, what is this language feature that is being used here? And, Where can I read more about it? Thanks


Number of ways to split a list into consecutive parts

How many ways can a list of size $n$ be split into consecutive sublists? For example, for $n=3$ the answer is 4: $$ [[[1, 2, 3]], [[1], [2, 3]], [[1, 2], [3]], [[1], [2], [3]]] $$ In general it is $2^{n-1}$ - why?


Please ,how to prove that the space $\mathbb{R}$ endowed with the metric $d(x,y)=|e^x-e^y|$ is  not a complete space?  I don't find a Cauchy sequence   but not convergent   Please  Thank you.


When I asked my coworker where the boss is, she answered me:   He is at the meeting.   Is this correct? I thought it should be:    He is in the meeting.   Because he is physically inside the room having the meeting.


Let $f = x^3+x+1 \in \mathbb{F}_2[x]$. We know that $K = \mathbb{F}_2[x] / \langle f \rangle$ is a ring. I just need to show that is also a field.   Its actually the first time that I need to work with a polynomial in $\mathbb{F}_2[x]$ and Im not sure how to show that $K$ is a field.


What is the macro/primitive for the current run time?

I've seen (I don't know where) a couple of interesting metadata-oriented control sequences, and I was wondering if such a sequence exists for the job runtime.  I can't expect it to give me the total run-time, but the run-time at that specific point would work well enough.  I'm putting in a rather braggy , for the interested.  My use case would be something like  \documentclass{silly} \usepackage{mwe} \begin{document} \lipsum\lipsum\lipsum  This document was typeset with \XeTeX, which is based on the \TeX\ typesetting system by Dr.~Donald~Knuth... which is very fast.  This entire work took only \pdfjobtime\ seconds to compile! \end{document}


How can I make a bootable, unattended USB restore disk?

I have a load of 14.04 kiosk systems, halfway across the country. These are horrible little integrated devices. I need to upgrade them all to 16.04 to support a new software stack. do-release-upgrade works half the time. The other half it destroys the install. In addition, the CPUs are really slow and  network connections at some sites are also pretty shoddy. So even when it works, upgrading takes a long time.  So new plan. I can make a fully-installed system image for each kiosk in Virtualbox, or LXC, or whatever. I need a way to get these images unpacked onto the systems.  The main problem here is there are very few technical people available at the other end. And I don't want to fly 200 miles to do this myself. I need something that is almost completely automated and doesn't require a keyboard.  I'm imagining a scenario where:   I make a system image for each kiosk I make a bootable USB drive for each kiosk and copy on the kiosk image. I label each and post them. At the other end, a staff member with physical access to the USB ports just plugs in the right drive and reboots. The bootable element of this then writes and expands the disk image.   It's that "bootable element" that I'm looking for. I was expecting that something like this might already exist (for bulk reimaging installations) but it's possible I'm in new territory. Anything that gets my images installed without manual interference (past plugging it in) gets points.  As far as I know, options like Clonezilla require somebody with a keyboard to tell it what to do. I need something that doesn't require a keyboard, just gets on and does it.


I was trying to understand UART fundamentals.It is understood that   It is an asynchronous communication protocol and hence the TX and RX clocks are independent of each other The data reception is guaranteed by the usage of start bit and one or more stop bits.Additionally the receiver must be aware of the data rate so as to generate suitable clock to drive the SIPO register used for  reception.   The questions here are  It is mentioned that normally a clock of 16X the bit rate is used to recover the data. So how is the conversion of bps to clock frequency possible? Please provide me some references to study the clocking mechanism employed in UART receiver.


You can never stop people who are wiling to die   May I use "that" instead of "who"?


I feel like when two conjectures are inconsistent with one another, it's a clear sign of our misunderstanding of deeper mathematics.  I was wondering if anyone knew of a comprehensive list of conjectures that contradict other conjectures.


Experiments are done to see if a process is symmetric (or asymmetric) with respect to the reversal of time. So if a process happens if the particles move in one direction, but not the other way round if you reverse the velocities of the particles participating in the process (after the process) the other way around it is asymmetric with respect to time reversal. Does this mean that time is reversed locally by giving the velocities of the particles after the process an opposite direction, while the velocities of all the other particles in the Universe stay the same (the clock in the lab runs forward)? Is time (locally or globally) reversed if you give all the particles velocities the opposite direction (disregarding for the moment the collapse or development of the wave functions or the expansion of the Universe? Would the locally changed velocities of the above-described process will still be asymmetric in time if you give all particles an opposite velocity?


SCP Automation in production environment

I want to implement the use of scp command in a production environment. I don't want to provide my password in the automation script.  Is there any way?  I need step by step solution.


What are the primary differences between Canon 600D and 700D?

I'm planning to buy a new SLR Camera . I'm confused between the Canon 600D and 700D. What are the primary differences?


I want to create a outline like this in my slide deck, but between every subsection of my talk. (Instead of between sections). Any ideas of how I accomplish this? Thanks!


Why is Bayes theorem more popular than the normal definition of P(A|B)?

As everyone knows, the conditional probability of A given B is $P(A|B) = \frac{P(A\cap B)}{P(B)}$, and Bayes' theorem is derived from that equation to $P(A|B) = \frac{P(B|A)P(A)}{P(B)}$.  I'm pretty new to probability, so I'm more than likely missing something, but why has Bayes' theorem become the "popular" equation? It seems to be just a complicated rewriting, and requires more information than the original definition of conditional probability (which Bayes' rule "decomposes" to anyways).


Show that if $U$ is an open connected subspace of $\mathbb{R}^2$, then $U$ is path connected. (Hint:Show that given $x_0 \in U$, the set of points can be joined to $x_0$ by a path in $U$ is both open and closed in $U$.)  This should not be too difficult, but I am stuck at some point.  Let $x_0 \in U$  Let $A = \{ x \in U | \text{there is a path connecting $x$ and $x_0$} \}$ $\subset U$.   I want to show that $A$ is open, so let $x \in A$. By openness of $U$, we can find a basic open set $\prod_{i=1}^2 (a_i,b_i)$ such that $\prod_{i=1}^2 (a_i,b_i) \subset U$. But I am stuck in showing that $\prod_{i=1}^2 (a_i,b_i)$ lies entirely in $A$.


Non-surjective map $F$ implies $\int_M F^* \eta=0$

This is a problem from Lee 17.12:     Suppose $M$ and $N$ are compact, oriented, smooth n-manifolds, and $F:M\rightarrow N$ is a smooth map. Prove that if $\int_M F^*\eta \neq 0$ for some $\eta \in \Omega^n(N)$, then $F$ is surjective.   I want to show the contrapositive, that non-surjective map implies $\int_M F^*\eta = 0$, and we know $\int_M F^*\eta = \text{deg}(F)\int_N\eta$. But I am not sure why non-surjectivity implies that $\text{deg}(F)=0$. Please help!   PS: I prefer to use techniques from Lee, as this is a problem there.


Verb+Noun Parsers and Old School Visual Novels

Hi  I'm working on a simple old school visual novel engine in Lua. Basically I have most of the code set up besides one important feature. The Text Parser.  Lets get into how words are generally structured. In the screenshot I input the command "my wish is for you to die"  --How would a human understand this?  my = noun/object  wish = verb  is = connective_equator similar to =  for = connective_object (for all objects of ..)  you = noun/object  to = connective_action similar to do  die = verb  --the computer can then parse this and understand it like this (pseudo example)  my = user  you = get_current_label()  you = "Lost Coatl"  wish = user_command  user_command = for all_objects of "Lost Coatl" do die() end  execute user_command()  What other ways do videogames use text parsers, what would be the simplest way for a newbie coder such as myself?


In the Definition and Lemma body environment I want non italic content

I am using a book style file and in the preamble I defined some theorem environment. But in the Definition and Lemma part I want nonitalic content. Please suggest. My preamble are  \newtheorem{theorem}{Theorem}[chapter] \newtheorem{exercise}{Exercise}[chapter] \newtheorem{example}{Example}[chapter] \newtheorem{definition}{Definition}[chapter] \newtheorem{lemma}{Lemma}[chapter]


How to determine the smallest $\ m\ $ with $\ G\le S_m\ $?

Let $\ G\ $ be a finite group with $\ |G|=n\ $  Caley's theorem states that $\ G\ $ is isomorphic to a subgroup of the symmetric group $\ S_n\ $  However, in many cases, the smallest positive integer $\ m\ $, such that $\ G\ $ is isomorphic to a subgroup of $\ S_m\ $ is smaller than $\ n\ $.     How can I determine $\ m\ $ , if I do not have access to GAP ?   Is there some applet or online calculator that can do this ? Or can $\ m\ $ be calculated by knowing specific properties of $\ G \ $ ?


A flying fly inside a sealed box on a scale

suppose there is a scale able to measure weight with an uncertainty of $10^{-9}kg$ . On the scale, an airtight plastic chamber is placed. Initially, a fly of mass $10^{-5}kg$ is sitting at the bottom of the chamber, which sits on the scale. At a later point in time the fly is flying around the chamber. Will there be a difference in the observed weight as measured by the scale when the fly is sitting at the bottom of the chamber compared to when it is flying around the chamber at some point in time? If so, what does the value of this difference depend on (I am most concerned with the case where the fly has not touched any surface of the container in enough time for the scale to reach some equilibrium value (or do the pressure variations induced from the flies wings cause constant fluctuations in the scale)?


I have some tables in Latex and I need to add some notes at the end, I tried this code, but the note that I have to add is too large for the table and I dont know how to fix it, there is another way to do it?      \begin{table}[!htbp] \centering    \caption{xxxxxxxxxxxxxxxxxxxxxx}    \label{}  \begin{tabular}{@{\extracolsep{5pt}}lccccccc}  \\[-1.8ex]\hline  \hline \\[-1.8ex]  Statistic & \multicolumn{1}{c}{Mean} & \multicolumn{1}{c}{St. Dev.} & \multicolumn{1}{c}{Min} & \multicolumn{1}{c}{Pctl(25)} & \multicolumn{1}{c}{Median} & \multicolumn{1}{c}{Pctl(75)} & \multicolumn{1}{c}{Max} \\  \hline \\[-1.8ex]   A & 1.539 & 2.896 & 0.140 & 0.218 & 0.420 & 2.820 & 5.540 \\   B 1.722 & 1.871 & 0.190 & 0.355 & 0.630 & 3.090 & 5.630 \\   C & 1.889 & 1.822 & 0.280 & 0.540 & 0.930 & 3.185 & 5.555 \\    D & 3.259 & 1.274 & 1.348 & 2.214 & 2.896 & 4.478 & 5.765 \\  \hline \\[-1.8ex]  \multicolumn{8}{l}{Note: xxxxxxxxx xxxxx xxxxxxxxxxxxxx xxxxxxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxxxxxxxx xxxxxxxxx xxxxxxxxx xxxxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxx xxxxx xxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxxxxxxxx \\  \end{tabular}  \end{table}    Thanks in advance.  Kind regards,


I want to build a small , but how is the power (and if possible a communication line) transmitted to the spinning part?  I've looked at some POV project, but they usually don't explain that part much...


I'm in Belgium (french part) and I cannot find the proper keyboard layout in Settings > Region and Languages > Input Sources.  the closest I found is the french (AZERTY) one but for the symbols such as ! and _ it's not the same keys...  what can I do to solve it ?  Thank you.


How to work out the limit of  this bounded sequence?

There's a bounded sequence $\{{a_n}\} $ s.t. $\lim\limits_{n \rightarrow  \infty}(a_{2n} + 2a_n) = 0$. Try to prove $\lim\limits_{n \rightarrow  \infty}a_n = 0$ (You must prove the existence of its limit before   getting the exact value)   The above problem is located in the chapter about "limsup and liminf", so you may use their property while proving.  EDIT  By the way, I find it hard to do the exercises at the end of each section of my textbook though I DO UNDERSTAND almost everything in that section. So I'm eager to know some other books that can help me to solve problems like the one described above. That would be a great help, thanks!


Plural or singular verbs with singular they

Q. How good is the teacher at that school?   A. They're a good teacher. They just sometimes hit(s)  their students if the students don't pay any attention to what he's saying, and then call(s) for parent-teacher conference.   Are we to use plural verbs with the singular they? It seems to me that with the first one, it should be hit but with the second one it should calls.


Lighting looks strange and planes are disappearing

I'm trying to make a dolphin model for 3d printing. While making the dolphin, I realized that in object mode the tailfin's lighting looks strange:    As you can see, the lighting of the fins is split, with one side being noticeably darker. To make the tailfin I first used the knife tool on a (squished) cube to make one half of the fin. Then I reflected it to make the other side and joined them in order to connect their edges with faces. When I was done, I realized the strange lighting on the tail. I first thought that I connected some faces incorrectly, but I checked and nothing seemed wrong to me.  Another strange thing I experienced was that when I tried to slice the model on the AstroPrint slicer, some of the planes on the tailfin were missing:   What's also strange is that the pieces that were missing were the pieces part of the tailfin where the lighting was abnormal. The only part that was shown is the bottom part of the fin.  I made the dolphin's body by shaping a cylinder. I made the fins by using the knife tool on a cube and connected them with the join operation. I edited them together and joined their edges with faces.   Does anyone know why this happens and how to fix this?


How to remove dead ubuntu dash application links?

I attempted to test out Lutrix on ubuntu 17.10 with League of Legends. Everything worked fine and well.  After testing it out I no longer needed Lutrix, Wine, or the game so I purged both Lutrix and Wine and deleted the Wine directory along with its contents.  However I can still see the League of Legends and Uninstall League of Legends launcher in Dash.  I have searched in /usr/share/application and in /usr/local/share/applications but can't find anything. I also performed a full system search and came up with no *.desktop files that fit the description.  Is there any other way that Ubuntu registers launchers in Dash that I am missing?


I couldn’t solve this question and I don’t know how to figure this out from beginning. Hint from my school was to think about euclid method on $ α^m-1,α^n-1$,and better to think $α$ as Polynomial. Here is the question ***There are  positive integer m,n and $gcd(m, n) = d$ . At this time, show that $gcd (a^m -1,a^n −1) = a^d −1$ is valid for 2 or more integer a.***


If $x\in \Bbb R$ ; then is the sequence $\{a_n\}$ where $a_1=x$; $a_{n+1}=\cos (a_n)$ convergent?  Obviously $|a_n|\le1$  and hence $(a_n)$ is bounded.  Also $f(x)=\cos x$ is decreasing for $x>0$.  But here $x\in \Bbb R$ .How to proceed here?Please help.


is the group of rational numbers the fundamental group of some space?

Which path connected space has fundamental group isomorphic to the group of rationals? More generally, is every group the fundamental group of a space?


Prove using natural deduction that $(R \rightarrow (P \rightarrow Q))\vdash (Q\rightarrow P) \lor (P \rightarrow Q)$

I ran into some trouble proving the following:  $(R \rightarrow (P \rightarrow Q))\vdash (Q\rightarrow P) \lor (P \rightarrow Q)$  My approach thus far:  Honestly I'm really stuck. So basically my hypothesis requires this $R$, hence the first thing that came to my mind is the Law of Excluded Middle. Using $R$ is trivial. The problem comes with $\neg R$. I can't seem to proceed from there.  Any help or insights is deeply appreciated.


Finding $ \int^1_0 \frac{\ln(1+x)}{x}dx$

There is supposed to be a clean solution to the integral below, maybe involving some symmetry $$ \int^1_0 \frac{\ln(1+x)}{x}dx$$ I have tried integration by parts as followed: $\ln(x+1)=u$ ,$\frac{1}{x+1} dx = du$ and also $\frac{1}{x}dx=dv$, $\ln(x)=v$. Then, the integral becomes $$\int^1_0 \frac{\ln(1+x)}{x}dx=- \int^1_0 \frac{\ln x}{1+x}dx$$ which does not make this easier. I have also tried using the identity $\int_a^bf(x)~dx=\int_a^bf(a+b-x)~dx$. So let $I = \int^1_0 \frac{\ln(1+x)}{x}dx$ and also $I = \int^1_0 \frac{\ln(2-x)}{1-x}  $. Then $$2I= \int^1_0 \ln(1+x)+\ln(2-x)$$ which is not any easier, either. Any ideas? :)


How to Install a C/C++ compiler in Ubuntu 14.04LTS?

Is there a need to install a C/C++ compiler in Ubuntu 14.04 LTS? Where to write the program? How to compile the same?


Prove that the equation $x^2-y^2 = 2002$ has no integer solution

Prove that the equation $x^2 − y^2 = 2002$ has no integer solution.   If I had the equation $x^3 - 7y = 3$ I would easily conclude that for it to have any integer solution then $$x^2\equiv3\pmod 7$$ must be true.  Applying the same logic here, I know that $x² = y^2 +2002$ so I can conclude that for it to have any integer solution then $$x^2\equiv2002\pmod y$$ must be true.  Is this conclusion correct?  From that congruence I can prove that the equation hasn't any integer solution without much trouble but I am not sure if that congruence is valid.


How to calculate and display someones age by having their birthdate

I apologize for creating a duplicated question. I'm sure this has been asked before but I simply could not apply the other fixes to mine due to my lack of understanding and knowledge.  So I have a class called Patients.cs and within that, all of a patient's data is stored. I have added a field for the birthdate with the following line   public DateTime birthdate { get; set; }   I am now creating a front-end form that will allow users to input information into the database through the webform. The field responsible for inserting the birthdate is as follows   <%--Birthdate--%>         Birthdate
           <asp:TextBox  class="form-control" ID="inputBirthDate" runat="server" placeholder="day/month/year"></asp:TextBox>
   For the back-end of the form page, I've created a new method that submits the data upon submitting the form and it is as follows  public void AddPatient() {      Patient newPatient = new Patient()     {         firstName = inputFirstName.Text,         middleName = inputMiddleName.Text,         lastName = inputLastName.Text,         gender = inputGender.SelectedValue,         birthdate = inputBirthDate.Text,         age = ,   The first few lines of the method / function seem to work fine, but when it comes to the birthdate, I get the following error Cannot implicitly covert type 'string' to 'System.DateTime'. I am unsure as how to handle this and then how to be able to display a patients age based on the birthdate they have put.


How to install utorrent in Ubuntu 18.04?

I have tried the installation with basic running the file,  then with the instructions given by the post   But after all of this, on running the following command  utserver -settingspath /opt/utorrent-server-alpha-v3_3/   I found that the terminal is not even responding.  It's been 5 minutes waiting in that screen before taking the screen shot    By my search, there are no guides for installing utorrent in the Ubuntu 18.04.   Please help me in the comments to clarify the question.


Am I allowed to upload Winter Bash-related content on personal sites?

As mentioned in , Stack Exchange owns the copyright to all WB hats and WB-related content. However, I am wondering if I can upload images of hats onto a public-facing personal site to make some sort of a gallery of past WB hats and maybe include some past and present WB site styling or even the knitting tool there for indefinite fun. (Just to be clear, such a site will distinctly state its status as a fan site and attribute its content to SE.) Also, I recognise that SE logos , but can WB logos be used for such a fan site? In the past, an SE employee allowed the usage of WB hats as  so I just want to check if that is still the case for non-commercial fan projects. (I haven't started work on such a site or anything like that; just thought I'd check first.)  Note regarding the (previously marked) : The marked duplicate is narrower as it specifically relates to hats, I am trying to ask about the usage of other WB content, such as the  and also the knitting editor on the WB2017&18 site. But, I reiterate that all WB-related content (hats, styling, knitting editor, etc.) used will be clearly attributed to SE, on such a fan site if I decide to create one.


LibreOffice problem while openning a document

My problem is that when I try to open one specific .odt document, I can't move the page or do anything except moving the mouse, which is useless. Also, the mouse, when I'm on the document, is freaking out switching between mouse and loader couple of times per second. It also becomes dark when I click on the document like if it's not responding.


C# how to output all the items in a class(struct)

i have class basically just a row of a table.  this row contains many columns.   for testing purpose, i  will need to output the reads i get .  so i need to output all of the columns in the row.  the class is like       public class tableRow     {         public tableRow()         {}     public string id     public string name     public string reg     public string data1     ....     ....     ....    <lot more columns>  }     then i need to write like:  Console.WriteLine("id: " + tableRow.id); Console.WriteLine("name: " + tableRow.name); Console.WriteLine("reg: " + tableRow.reg); Console.WriteLine("data1: " + tableRow.data1); ... ... ... <lot more Console.WriteLine>   So i want to know ,  is there an easy way to get all of these output , without so much console.writeLine?  thanks


Trying to recover a partition! Which cylinder should I begin searching at?

The entire hard disk is 1.5TB   The partition I hope to recover is 900GB  There were two partitions     [ 600 GB - OS partition ] [ 900 GB - the data partition I want to recover ]   Which cylinder should I begin searching at?    And which program do you recommend?    TestDisk EaseUS   I can use Windows 7 / GParted / Knoppix


What is the appropriate / preferred method for questions concerning programming nomenclature?

For example, how should one pose questions concerning what a programming concept should be called? I am not talking about naming within code.  The general purpose of such questions would be to enable users to find the right terminology to use to make further enquiries such as searching on Google / Stack Overflow.  For example, what is the name for combining two tables?  By this question I mean are there common terminologies for this? Are there specific methods of combining tables that certain phrases refer to?  Is this an appropriate Stack Overflow question?  I'm not even sure if this meta-question makes sense.


Nonabelian group with all irreducible representations one-dimensional

All irreducible representations of an abelian group are one-dimensional. For a finite group, the coverse is also true - if all irreducible representations are one-dimensional then the group is abelian.     Is there a nonabelian group $G$ such that all of its finite-dimensional complex irreducible representations are one-dimensional (such group $G$ is necessarily infinite of course)?


How to transfer old pokemon account to new phone

I started playing pokemon on my old S5 but now have a shiny new S7, however I don't seem able to transfer the pokemon I have caught to the new phone. I can transfer the app but have to create a new account and begin again. I couldn't register as a trainer initially so had to sign up using Google account.  Any help appreciated.


linux : find a lastname that has 5 characters only in a text

Name, lastname, phone number .This is the text  :   Hace, Apoio, 703-2101  Yoliot, Apostolos, 4222-1124  Jenny,Thano,105-4122   Heriom,Koun, 510-4122   Dekon, Atolo, 502-2522   Feow, R,685-3431   I want to find all lastnames that have 5 characters only   Edit: I tried  egrep -i '[^:]+[a-z]5$' file2    but that doesn't work


When I try to do   sudo dpkg --add-architecture i386  [sudo] password for shailendra:  dpkg: error: unknown option --add-architecture.    this happens while installing skype.


I am a beginner in Ubuntu. And I have just installed Ubuntu 11.10 in my Dell laptop. When I plugged my WD external hard drive in, it read the first time, but since I have a unlock.exe file (password for the hard drive). So I installed Wine to read it. But it gives me an error. I restart the machine, and plugged the hard drive in again. And it is not recognized anymore. Can anybody help me, please?  Thank you!


I have had this laptop for just more than a year and never faced any problem with it until sometime back when I got a "tingling sensation" using the track pad, just around the edges. That happens only when running on AC.  When I Googled I see there seems to be a problem with this laptop. However, many posts in different forums talk about two pinned adapter as a probable cause but I have a three pinned one. The wall outlet is earth grounded properly.  Since I never had this problem, is this about faulty hardware or other environmental factors? It had been a hot day and the night is cold (but it has been so mostly this season), also I have scrapped my fingers around the nails lightly (just thinly peeled off skin) doing gardening.  I just want to know what's happening, as I cannot call the customer care till Monday. Any clues?  Update:   The harder I press the track pad, the more the sensation. I got it again, even when running on battery but with the adapter chord plugged in and AC off! I unplugged it and the shock was gone. I plugged it back in and the shock didn't return! Its funny. I am not even able to see a pattern.


How to include uneditable information on a form's display?

I am using a django formset containing forms that specify user friendship preferences.   My form fields are:      siteuser_id = forms.IntegerField(widget=forms.HiddenInput())     subscribed = forms.BooleanField(required=False)     ally = forms.BooleanField(required=False)     enemy = forms.BooleanField(required=False)   The goal is to display all of a person's friends and that person's status within the game.  When I display the forms in the formset, I'd like to display the nickname (nicknames are not unique or I would just use it instead of siteuser_id) of the person alongside the friendship preference for that person.   I tried making username a form field, but that makes it editable, and I just want it to display within the table, not be editable.  Help?


Let $\sqsubseteq$ be the boolean ordering of $X$, so for every $x$ and $y$ applies $x \sqsubseteq y$ if $x \sqcap y = x$. Let $v, w, a, b \in X$ with $v \sqsubseteq a$ and $w \sqsubseteq b$. Show that $v \sqcup w \sqsubseteq a\sqcup b$ and $v \sqcap w \sqsubseteq a\sqcap b$.  Should this be solved algebraically, or in a different way? And if so, where would be my starting point?


How to color SVG symbols in QGIS 2.18.14?

Why can I color some SVG symbols, but not others?  At symbol # 1 I can change the color, but not the others.  In the XnView viewer, the symbols are shown differently.    What qualifies an SVG symbol to change the color?   Even editing it in Adobe Illustrator, I do not understand what's happening!


discontinuous solutions of the functional equation $f\left(a^b\right) = f(a)^{f(b)}$

This is a followup to . It's well known that Cauchy's functional equation, $$f(x+y) = f(x) + f(y)\text,$$ has discontinuous solutions. In fact, any discontinuous solution is discontinuous everywhere (except perhaps 0). Now let's consider the functional equation $$f\left(a^b\right) = f(a)^{f(b)}\text.$$ For simplicity we will restrict the domain to $\mathbb{R}_{\ge 0}$. We have seen in the original question that the only continuous solutions are trivial. However, we have not explored what discontinuous solutions there are. Let $$U = \{a \in \mathbb{R}_{\ge 0} | f(a) \not\in \{0, 1\}\}\text.$$ One property of any discontinuous solution is that, because $$f\left(a^{1+\mathrm{d}x}\right) = f(a)^{f(1+\mathrm{d}x)}$$ for all $a \in U$, continuity at any such $a$ is equivalent to continuity at 1. Therefore any solution that is discontinuous anywhere on $U$ is discontinuous everywhere on $U$. However, this property does not obviously prove or disprove the existence of such functions, not to mention provide us with an example of one if they exist. So the questions are: are there discontinuous solutions, how are they characterized, and what is a canonical example of one?


System.CalloutException when doing HTTP response

I keep getting System callout error when updating a contact field for multiple contacts.  System.CalloutException: You have uncommitted work pending. Please commit or rollback before calling out  public static List<Id> getId(){         //find a list of contacts with birthdays today       Contact[] c1 = [SELECT Id, email, Birthday__c, Name                    FROM Contact                    WHERE email <> '' AND                       DAY_IN_MONTH(Birthday__C) = :Date.today().day() AND                    CALENDAR_MONTH(Birthday__C) = :Date.today().month()];          //add the list of contacts to a list      List<Id> mailToIds = new List<Id>();            for(Contact r : c1) {             //Add contacts that have birthdays to the list             System.debug('recipient' + r.Birthday__c);             mailToIds.add(r.Id);  // add to email contact array                      }     return mailToIds; }  public static void updateContact(){     List<Id> idList = new List<Id>();     idList = getId();       GiftLink giftLink = new GiftLink();              Contact queryContact;     for(Id t : idList){         queryContact = [SELECT id, Name, gift_link__c FROM Contact WHERE id = :t];         queryContact.gift_link__c = giftLink.apiCall(queryContact.Name);         update queryContact;         System.debug(queryContact.Name);     }        }


Bootable USB appearing as HDD not Removable Device

I have a unique problem with an older Toshiba satellite laptop that happens to be a LegacyFree laptop meaning you can't access the bios via the normal F2, Del, Esc, etc.  I can only select a boot option in the beginning such as HDD, Removeable, CD, Floppy, etc.  The problem I ran into is the bootable USB I created is appearing as a bootable HDD not as a removable device and thus it is booting from the HDD in the computer because I can't change the HDD device priority.  Is there anyway when making the bootable USB to make it appear as a USB instead of HDD?  I've been using unetbootin and LinuxLive to create these bootable USBs.  NOTE: I am aware you can access LegacyFree Bios is through a program called Tsetup or HwSetup through windowsXP problem is that The laptop doesn't have any OS currently installed.


I'm having trouble following a proof of this generalization of the Cayley-Hamilton theorem:     Suppose that $M$ is an $A$-module generated by $n$ elements, and that $\varphi \in \operatorname{Hom}_A(M,M)$; let $I$ be an ideal of $A$ such that $\varphi(M) \subset IM$. Then there is a relation of the form $$(**)\quad \varphi^n + a_1 \varphi^{n-1} + \cdots + a_{n-1}\varphi + a_n = 0,$$ with $a_i \in I^i$ for $1 \leqslant i \leqslant n$ (where both sides are considered as endomorphisms of $M$).   This is theorem 2.1 in Matsumura's Commutative Ring Theory. The proof there goes as follows:     Let $M = A\omega_1 + \dots + A\omega_n$; by the assumption $\varphi(M) \subset IM$ there exist $a_{ij} \in I$ such that $\varphi(\omega_i) = \sum_{j=1}^n a_{ij}\omega_j$. This can be rewritten $$\sum_{j=1}^n(\varphi\delta_{ij} - a_{ij})\omega_j = 0 \quad (\text{for }\  1\leqslant i \leqslant n),$$ where $\delta_{ij}$ is the Kronecker symbol. The coefficients of this system of linear equations can be viewed as a square matrix $(\varphi\delta_{ij} - a_{ij})$ of elements of $A'[\varphi]$, the commutative subring of the endomorphism ring $E$ of $M$ generated by the image $A'$ of $A$ together with $\varphi$; let $b_{ij}$ denote its $(i,j)$th cofactor, and $d$ its determinant. By multiplying the above equation through by $b_{ik}$ and summing over $i$, we get $d\omega_k = 0$ for $1 \leqslant k \leqslant n$. Hence $d\cdot M = 0$, so that $d = 0$ as an element of $E$. Expanding the determinant $d$ gives a relation of the form $(**)$.   I would like to understand this particular proof, but I'm having trouble concluding $d\omega_k = 0$ for $1 \leqslant k \leqslant n$ from the multiplication of the above equation by $b_{ik}$ and summing over $i$. It's clear that the right hand side remains zero, but I'm having trouble expanding the left hand side into a useful form. I'm pretty sure I have to use the fact that $d = \sum_{i=1}^n b_{ik} (\varphi\delta_{ik} - a_{ik})$ by the cofactor expansion of the determinant along the $k$th column, but I can only seem conclude $d\omega_k - d\omega_k = 0$, which is not very enlightening.  Thanks in advance.


my code is  import java.awt.EventQueue; import java.awt.Graphics; import javax.swing.JFrame; import javax.swing.JPanel; import javax.swing.border.EmptyBorder;  @SuppressWarnings("serial") public class point extends JFrame {  private JPanel contentPane;  /**  * Launch the application.  */ public static void main(String[] args) {     EventQueue.invokeLater(new Runnable() {         public void run() {             try {                 point frame = new point();                 frame.setVisible(true);             } catch (Exception e) {                 e.printStackTrace();             }         }     }); }  /**  * Create the frame.  */ public point() {     setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);     setType(Type.UTILITY);     getContentPane().setLayout(null);      JPanel panel = new JPanel();     panel.setBounds(0, 0, 300, 300);     getContentPane().add(panel);     setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);     setBounds(200, 200, 450, 300);     contentPane = new JPanel();      contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));     setContentPane(contentPane);     contentPane.setLayout(null);      Graphics g = panel.getGraphics();      g.drawLine(10, 10, 20, 20);   } }   in g.drawLine or another draw I have error but eclipse note have error in code my error is :  > java.lang.NullPointerException     at org.eclipse.wb.swing.point.<init>(point.java:54)     at org.eclipse.wb.swing.point$1.run(point.java:20)     at java.awt.event.InvocationEvent.dispatch(Unknown Source)     at java.awt.EventQueue.dispatchEventImpl(Unknown Source)     at java.awt.EventQueue.access$500(Unknown Source)     at java.awt.EventQueue$3.run(Unknown Source)     at java.awt.EventQueue$3.run(Unknown Source)     at java.security.AccessController.doPrivileged(Native Method)     at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)     at java.awt.EventQueue.dispatchEvent(Unknown Source)     at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)     at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)     at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)     at java.awt.EventDispatchThread.pumpEvents(Unknown Source)     at java.awt.EventDispatchThread.pumpEvents(Unknown Source)     at java.awt.EventDispatchThread.run(Unknown Source)   thanks for your help  I only need to draw any thing in to the panel My IDE is eclipse and using WindowsBuilder and My IDE not get error in code and I try to other Graphics Draw but have error too


In my table, in order to have texts centered in each cell, I am using  \newcolumntype{P}[1]{>{\centering\arraybackslash}p{#1}}    and instead of a simple p{1.5cm}, I am using   >{\centering\arraybackslash}p{1.5cm}    I am also using \toprule, \midrule, and \bottomrule along with \usepackage{booktabs}.  My code is the following:  \documentclass[12pt]{article}    \newcolumntype{P}[1]{>{\centering\arraybackslash}p{#1}} \usepackage{multicol} \usepackage{multirow} \usepackage{booktabs}   \begin{document}   \begin{table}[h] \centering \begin{tabular}{| >{\centering\arraybackslash}p{1.5cm} | >{\centering\arraybackslash}p{1.2cm} | >{\centering\arraybackslash}p{1.2cm} |  >{\centering\arraybackslash}p{1.2cm} | >{\centering\arraybackslash}p{1.2cm} |>{\centering\arraybackslash}p{1.2cm} | >{\centering\arraybackslash}p{1.2cm} | >{\centering\arraybackslash}p{1.2cm} | >{\centering\arraybackslash}p{1.2cm}|} \toprule \multirow{2}{*}{} & \multicolumn{4}{c|}{Payoffs} &  \multicolumn{4}{c}{ROR} \\ \cline{2-9}  & $\theta =1$ & $\theta =2$ & $E(P)$ & $\sigma(P)$ & $\theta =1$ & $\theta =2$ & $E(r)$ & $\sigma(r)$ \\ \midrule Asset 1 & 110 & 95 &   &   &   &   &   &   \\ Asset 2 & 105 & 90 &   &   &   &   &   &   \\ Asset 3 & 120 & 90 &   &   &   &   &   &   \\ \bottomrule \end{tabular} \end{table}    \end{document}    And my result looks very strange like this:    First, the far right vertical line is short; the first row is not closed on the right.  Second, all the vertical lines are cut.  Any thoughts?


This is a part of my query:  WHERE GroupId IN (@groupIds)   With @groupIds being a List of integers of IDs. How can I pass that list as a parameter in a SqlConnection? I'm trying:  return conn.Query<>(query, new { @groupIds }).ToList();   But that's not working.


How to position images before bibliography

I successfully included \usepackage[section]{placeins}, which positions my figures just before bibliography in a very nice way, but there is another problem. The first page of my paper which contained title, abstract and some introduction, now only has title and everything is flashed at the second page. How can i fix that? If i remove \usepackage[section]{placeins} then the first page problem does not appear, but there are the figure between bibliography in the end.


How can I use the Array modifier correctly?

I want this  This is my screen. version is 2.90.1 What's wrong with the array modifier?


A client wants to "Web-enable" a spreadsheet calculation -- the user to specify the values of certain cells, then show them the resulting values in other cells.  (They do NOT want to show the user a "spreadsheet-like" interface. This is not a UI question.)  They have a huge spreadsheet with lots of calculations over many, many sheets.  But, in the end, only two things matter -- (1) you put numbers in a couple cells on one sheet, and (2) you get corresponding numbers off a couple cells in another sheet.  The rest of it is a black box.  I want to present a UI to the user to enter the numbers they want, then I'd like to programatically open the Excel file, set the numbers, tell it to re-calc, and read the result out.  Is this possible/advisable?  Is there a commercial component that makes this easier?  Are their pitfalls I'm not considering?  (I know I can use Office Automation to do this, but I know it's not recommended to do that server-side, since it tries to run in the context of a user, etc.)  A lot of people are saying I need to recreate the formulas in code.  However, this would be staggeringly complex.


I got a couple of questions about game trademarks.   When should I submit a trademark for my game if I see that this is a serious project? Where do I submit a trademark request? Does it have to be local (In my country)? What do I need to be ready to submit a trademark request?   Thanks!


Since Inception is on, I have been thinking about this question a lot.       Cobb's totem used to be his wife's. Doesn't that invalidate its purpose. The other question...is his projection of her really her trying to wake him up?


Why can you compute $\dfrac{d}{dx}{x^x} $ by holding constant the base + exponent?

Pls discuss just the method below, and refrain from other methods. The  below looks wrong to me, because both the exponent and base are $x$! So how can you possibly pretend or playact that they're not, and treat the exponent and base separately as constants?     I once asked students to find the derivative of $x^x$ (with respect to $x$). One student figured that if the exponent were a constant then the answer would be $xx^{x-1}$ which is to say $x^x$, while if the base were constant the answer would be $x^x\log x$, so she added the two together to get $x^x+x^x\log x$. I was just about to mark the answer as wrong, when I realized that she had arrived at the correct answer – and, later, realized that it wasn't a coincidence, her unorthodox method actually works in a more general setting.


I'm facing a really stupid and infuriating problem, I was following a video on how to make a roguelike, I decided to stop after knowing how to print a level to the screen and actually start coding, then I got multiple errors on seamingly perfect code, I blammed the constructors so I decided to make a new project on visual studio to test the most stupid case, one main fuction, one clase with one constructor that does nothing, and I leaved all the work of making the class and the constructor to visual studio, I still got the goddammned issue, here's the error on that simplified version of the code, I would show the rogue like code but I would have to translate to english al the errors myself, and most of them have nothing to do with the actual error, because mostly they're complaining about missing ; in places where either there shouldn't be a ; or there alredy is one.  here's the code     main.cpp:     #include "stdafx.h"      int main()     {     return 0;     }     test.h     #include "stdafx.h"      class test     {     public:     test();     };     test.cpp     #include "test.h"     #include "stdafx.h"      test::test(){     }   yet with that simple auto-generated code, visual studio still complaints and gives me this error messages  c4430 missing type specifier - int assumed. Note: C++ does not support default-int  c2653 'test' : is not a class or namespace name  'test' : function should return a value; 'void' return type assumed  what should I do?


Job Search by distance isn't respecting the distance

The last couple of days job search by distance is returning jobs well outside of the query   includes jobs in Denmark which is a smidge further than 20 miles from the north of England :)


I need to find out whether the following improper integral converges:  $$\int^\infty_0\frac{1}{1+x^2\sin^2(5x)}\,dx$$  I tried two comparison tests that failed, any ideas?


Is there a single word that is a more vicious connotation of "competition"?

I'm writing a mildly dystopian scenario where competition is taken to vicious extremes, and I was wondering if there was a word that I could use (specifically a noun that was a synonym of "competition") to describe the sort of vicious, cutthroat ... _________ (the word that I want) that was going on.  I'm specifically looking for a word that doesn't refer to a one-off event (like "contest" or "tug-of-war"), but rather is more about the state of things.


I forgot to turn my slowcooker on overnight w/ chicken in it, can I eat it still?

I put chicken breasts and a bunch of salsa into a slow cooker to be cooked while I slept. I forgot to turn it on. When I woke up I noticed and put it back in the fridge.  I plan to cook it tonight (and hopefully not forget to turn it on).  Is this a bad idea?  I will note that the salsa appeared to insulate the chicken because it was still cool to the touch (not COLD though) when I discovered it in the morning.  Total time out of fridge would be about 9 hours.  EDIT: This is not a duplicate of the suggested question because I had a thought that it might be ok due to the chicken being slightly insulated and still cool. I have realized it is still not safe from the answers.


How to find $\lfloor 1/\sqrt{1}+1/\sqrt{2}+\dots+1/\sqrt{100}\rfloor $ without a calculator?

$$ \left\lfloor\frac{1}{\sqrt{1}} + \frac{1}{\sqrt{2}} +\dots+ \frac{1}{\sqrt{100}}\right\rfloor =\,? $$   I rationalized the denominator and then I think I should somehow group the numbers, but i don't know how.  Thanks in advance!


Why do the execution time of independent code blocks depend on execution order in Scala?

I have a program written in Scala. I wanted to measure the execution time of different independent code blocks. When I did it in the obvious way (i.e. inserting System.nanoTime() before and after each block), I observed that the the execution time depends on the ordering of the blocks. The first some blocks always took more time than the others.  I created a minimalistic example that reproduces this behaviour. All code blocks are the same and call hashCode() for an array of integers, for simplicity.  package experiments  import scala.util.Random  /**   * Measuring execution time of a code block   *   * Minimalistic example   */ object CodeBlockMeasurement {    def main(args: Array[String]): Unit = {     val numRecords = args(0).toInt     // number of independent measurements     val iterations = args(1).toInt      // Changes results a little bit, but not too much     // val records2 = Array.fill[Int](1)(0)     // records2.foreach(x => {})      for (_ <- 1 to iterations) {       measure(numRecords)     }   }    def measure(numRecords: Int): Unit = {     // using a new array every time     val records = Array.fill[Int](numRecords)(new Random().nextInt())     // block of code to be measured     def doSomething(): Unit = {       records.foreach(k => k.hashCode())     }     // measure execution time of the code-block     elapsedTime(doSomething(), "HashCodeExperiment")   }    def elapsedTime(block: => Unit, name: String): Unit = {     val t0 = System.nanoTime()     val result = block     val t1 = System.nanoTime()     // print out elapsed time in milliseconds     println(s"$name took ${(t1 - t0).toDouble / 1000000} ms")   } }   After running the program with numRecords = 100000 and iterations = 10, my console looks like this:     HashCodeExperiment took 14.630283 ms   HashCodeExperiment took 7.125693 ms   HashCodeExperiment took 0.368151 ms   HashCodeExperiment took 0.431628 ms   HashCodeExperiment took 0.086455 ms   HashCodeExperiment took 0.056458 ms   HashCodeExperiment took 0.055138 ms   HashCodeExperiment took 0.062997 ms   HashCodeExperiment took 0.063736 ms   HashCodeExperiment took 0.056682 ms   Can somebody explain why is that? Shouldn't all be the same? Which is the real execution time?  Thanks a lot, Peter     Environment parameters:   OS: ubuntu 14.04 LTS (64 bit)   IDE: IntelliJ IDEA 2016.1.1 (IU-145.597)   Scala: 2.11.7


Let $A_1 A_2 \dotsb A_{11}$ be a regular 11-gon inscribed in a circle of radius 2. Let $P$ be a point, such that the distance from $P$ to the center of the circle is 3. Find  $PA_1^2 + PA_2^2 + \dots + PA_{11}^2.$


Find $x,y,z$ such that:  $$ 6x+15y+20z=17 $$  I found this question in Hua Loo Keng's Number Theory under the Greatest Common Factor and Least Common Multiple section.


i am getting java.lang.NullPointerException in Automation testing selenium

i am getting java.lang.NullPointerException error at following line  in both files Base file and HomePage file at following line code  driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS); and  driver.get("");  Base class public class Base {      public WebDriver driver ;      public WebDriver InitializeDriver() throws IOException     {         Properties Prop =new Properties();          FileInputStream fis=new FileInputStream("C:\\Users\\Raj\\eclipse-workspace\\MavenSelenium\\src\\main\\java\\FirstMaven\\MavenSelenium\\Data.properties");          Prop.load(fis);         String browsername = Prop.getProperty("browser");          if (browsername=="Chrome")         {             System.setProperty("webdriver.chrome.driver", "C:\\Users\\Raj\\eclipse-workspace\\Work\\chromedriver.exe");             driver=new ChromeDriver();         }         else if (browsername=="Firefox")         {            System.setProperty("webdriver.chrome.driver", "C:\\Users\\Raj\\eclipse-workspace\\Work\\geckodriver.exe");            driver=new FirefoxDriver();           }         else if(browsername=="IE")         {             System.setProperty("webdriver.chrome.driver", "C:\\Users\\Raj\\eclipse-workspace\\Work\\IEDriverServer.exe");             driver=new InternetExplorerDriver();         }         driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);         return driver;     }   }  and HomePAge Class  public class HomePage extends Base{  @Test public void Navigation() throws IOException {  driver=InitializeDriver(); driver.get("https://www.google.com");  }      }


Searching SSIS packages for the use of specific tables

I have a number of SSIS packages, how can I search them to find the use of specific tables? I need to make tables changes and I am trying to assess the impact of these.


Can every real polynomial be factored up to quadratic factors?

I know that you can't factor a real polynomial into $\Pi_{i=1}^N(x-a_i)$ in general. But is it possible to factor every real finite polynomial into this form:    $(\Pi_{i=1}^N a_ix^2 + b_ix + c_i) (\Pi_{i=1}^Mx-d_i)$  where the second term is possibly empty?  This is at least true for polynomials with odd powers because they must have at least one real root. (My reasoning was false, edit see below) So I wonder if it is also true for even powers?    Edit: Berci has pointed out a lapse in my reasoning. For an odd power, once you factor out the first root, it is conceivable that you may hit an even-degree polynomial that is irreducible.


How can I /give myself a stone axe that can only break oak signs/planks in Adventure Mode?

I am trying to obtain a stone axe that can destroy oak signs and oak planks in Adventure Mode. The command that I have tried is: /give @p stone_axe 1 0 {can_destroy: {"blocks": ["oak_sign","oak_wood_planks"]}}  The error message that I get is: * Line 1, Column 2 Missing '}' or object member name  What is the mistake in this command, and what should I do to make it work?


Prove that vector space and dual space have same dimension

As an exercise in my textbook, I need to prove that if $V$ is a finite dimensional vector space with dual space $V^*$ over $\mathbb{R}$, then dim$(V)$=dim$(V^*)$.  Let $\omega\in V^*$ and let $\{e_1,...,e_n\}$ be a basis for $V$. Define $e^i\in V^*$ by $e^i(e_j)=\delta_{ij}$. We show that $\{e^1,...,e^n\}$ spans $V^*$. $\omega(v)=\omega(v_1e_1+...+v_ne_n)=v_1\omega(e_1)+...+v_n\omega(e_n).$ If $\omega(e_1)=\lambda_1,...,\omega(e_n)=\lambda_n$, then $\omega(v)=v_1\lambda_1e^1(e_1)+...+v_n\lambda_ne^n(e_n)$=$\lambda_1e^1(v)+...+\lambda_ne^n(v)$.   To show $\{e^1,...,e^n\}$ is linearly independent, suppose that $0=c_1e^1+...+c_ne^n$ is the zero mapping to $\mathbb{R}$. Consider the image of $e_1:$  $0(e_1)=c_1*1+...+c_n*0=c_1$ Hence, $c_1=0$. Repeating the procedure for $e_j$, $2\leq j\leq n$, we see that $c_1=c_2=...=c_n=0$.  Does this proof look correct?  If the proof is correct, I have an additional small question. It seems like this proof is dependent on the fact that $V$ is a real (or complex) vector space, since we define the covectors to have the image set $\{0,1\}$. Is there a proof that works for vectors spaces over general fields?


I am drawing some graphs with tangents. I calculated the tangent should be centered at x=57/27 which is approximately x=2.11. I'm currently using the pos and sloped keys for nodes to draw tangents, but I'm not happy about the result; the tangents don't really align.   I think this is because the pos key calculates the actual length of the graph while the graphs don't have the same length.  I'm sure I can somehow let LaTeX do the calculations for me so as to align the slopes vertically at an x value of my choice. But how?  PS: The below document requires a working installation of gnuplot to compile.    \documentclass{standalone}   \usepackage{pgfplots} \pgfplotsset{compat=1.10} \usetikzlibrary{arrows, decorations.markings,intersections}  \makeatletter \tikzset{     nomorepostaction/.code=\makeatletter\let\tikz@postactions\pgfutil@empty,      my axis/.style={         postaction={             decoration={                 markings,                 mark=at position 1 with {                     \arrow[ultra thick]{latex}                 }             },             decorate,             nomorepostaction         },         thin,         -,         every path/.append style=my axis     } } \makeatother  \definecolor{headtitle}{RGB}{167,63,63}  \begin{document} \begin{tikzpicture}   \begin{axis}[%       axis line style={my axis},       xlabel = $U_A$,       ylabel = $S$,       xmin = 0, xmax = 3.25,       ymin = 0,       xtick={1,1.5},       xticklabels={$U_{B,\mathrm{initial}}$,$U_{A,\mathrm{initial}}$},       xticklabel style={             inner sep=0pt,             anchor=north east,             rotate=35         },       ytick=\empty,       height=.66\linewidth, width=\linewidth-4.5\tabcolsep,       axis lines*=left,       every axis y label/.style={at=(current axis.above origin),anchor=east},       every axis x label/.style={at=(current axis.right of origin),anchor=west}]%     \addplot+[mark={},draw=headtitle] gnuplot[raw gnuplot] {%       set samples 51;       plot [0:3] log(3*(3-x)+1);       } node[sloped,above,pos=.63333,       minimum height=1cm,minimum width=1cm] (SB) {} node[pos=0.6,pin=45:{\color{black}{$S_B$}}] {};      \addplot+[mark={},draw=headtitle] gnuplot[raw gnuplot] {%       set samples 51;       plot [0:3] log(9*x^2+6*x+1);       } node[sloped,above,pos=.83333,       minimum height=1cm,minimum width=1cm] (SA) {} node[pos=0.25,pin=-15:{\color{black}{$S_A$}}] {};       \addplot+[mark={},draw=headtitle] gnuplot[raw gnuplot] {%       set samples 51;       plot [0:3] log(9*x^2+6*x+1)+log(3*(3-x)+1);       } node[sloped,above,pos=.775,       minimum height=1cm,minimum width=1cm] (St) {} node[pos=0.525,pin=165:{\color{black}{$S_\mathrm{total}$}}] {};      \path (SB.south east) edge[headtitle,very thick] node {} (SB.south west);      \path (SA.south east) edge[headtitle,very thick] node {} (SA.south west);      \path (St.south east) edge[headtitle,very thick] node {} (St.south west);   \end{axis}% \end{tikzpicture}% \end{document}


Is it safe to use an LG charger on a Moto X?

I have a 2014 Moto X, and a Nexus 4. Is it safe to charge my Moto X using my Nexus 4 charger?


Are everyone unable to log in right now? 2016 July 16. Where I live none can log in to the servers at the moment, and it all happened after the sudden release of the game in my country.   As I understand the game was recently released in 26 countries, so I guess they have problems and had the servers go offline in order to fix the issues.


I am converting a PHP 5.3 library to work on PHP 5.2. The main thing standing in my way is the use of late static binding like return new static($options); , if I convert this to return new self($options) will I get the same results?  What is the difference between new self and new static?


Why does $X_{n}\xrightarrow{L^{2}}X$ imply that $(X_{n})^{2}\xrightarrow{L^{1}}X^2$?

In a proof I saw the use of the fact that if $X_{n}\xrightarrow{L^{2}}X$ then it follows $(X_{n})^{2}\xrightarrow{L^{1}}X^2$. Now I initially I assumed that this means an inequality of the form: there exists $c>0$ such that  $\lvert x-y\rvert ^{2}\geq c\lvert \lvert x\rvert ^2-\lvert y\rvert^2\rvert $ for $x,y\in \mathbb R\;$. should hold. However, in a previous question on this site, it was proven incorrect. I am particularly interested in the $L^{2},\;L^{1}$ convergence in the case of underlying probability measures, in case that makes a difference to the statement.


Has there been a change in 19.04 with switching applications using (Super + tab)?

I've noticed that using Super+Tab in 19.04 starts on the focused application which is not very efficient for quickly switching back and forth between applications.   The old functionality was that when you typed Super+Tab it would start on the last application you had focused, not the current. Anyone else seeing this?


I thought many results in calculus need axiom choice. For example, I thought one needs AC to prove that a bounded sequence in the real line has a convergent subsequence. Recently I was taught that one only needs mathematical induction to prove it. So here are my questions.  Can most results in calculus be proved without AC? If yes, what are the exceptions, to name a few?  Obviously a theorem which uses Zorn's lemma most likely does need AC. So please exclude obvious ones.  Edit By "without AC", I mean without any form of AC, i.e. countable or not, dependent or not. In other words, within ZF.  Edit One of the motivations of my question is as follows. People often unconciously use AC to prove theorems. And it often turns out that their uses of AC are unnecessary. For example, an infinite subset of a compact metric space has a limit point. In his book "Principles of mathematical analysis", Rudin proves this by choosing a suitable neighborhood of every point of the space. He uses AC here, though he doesn't say so. However, since a compact metric space is separable, you can avoid AC to prove this theorem.  Edit I'll make the above statement clearer. You can even avoid countable AC to prove the above theorem. In other words, you can prove it within ZF.  Edit I'll make my questions clearer and more specific. By calculus, I mean classical analysis in Euclidean spaces. Take, for example, Rudin's "Principles of mathematical analysis". Can all the results in this book be proved within ZF? If not, what are the exceptions?


I frequently find this expression in literature and such. I couldn´t find anything on it on the net, only more of these expressions without explanations how to handle or understand them correctly:  "I have years of experience proofreading, editing and translating. From simple CVs and cover letters to Master Theses, it is important that your work be perfect and I will make sure that your end product is error-free."  Is that actually idiomatic language? Can it be replaced by "is"?


What is the rule determinating whether or not we need to capitalize them?  Sometimes I see "Math" ; "Physics" in the middle of a sentence, and sometimes lower case is used.


Constructor without arguments doesn't work

I wonder why the constructor doesn't work/get called in the first case.  #include <iostream> #include <typeinfo>  class Test{ public:     Test(){ std::cout << "1\n"; };     Test(int){ std::cout << "2\n"; }; };   int main() {     Test a(); // actually doesn't call the constructor     Test b(1); // "2"     std::cout << (typeid(b).name()) << std::endl; // "4Test"     std::cout << (typeid(a).name()); // "F4TestvE"     return 0; }   I've also found that typenames of created variables are strange. Can anybody explain such a behavior?     I use mingw gcc 4.7.2 for Windows to compile my projects  Thanks a lot.


Code on sender class:  public void sendQuestion(){        Random randomNumber = new Random();        final int rand = randomNumber.nextInt(19)+1;        Intent numbers = new Intent(this, Questions.class);        numbers.putExtra("randomNumber", rand);        startActivity(numbers);   Code on receiver class:  public class Questions extends Activity{ @Override protected void onCreate(@Nullable Bundle savedInstanceState) {     super.onCreate(savedInstanceState);     question(); }  int questionNumber = getIntent().getExtras().getInt("randomNumber"); public void question() {     String questionString = "Wrong";     switch (questionNumber) {   Why am I getting this error?  Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'android.os.Bundle android.content.Intent.getExtras()' on a null object reference


I just started learning Scripting in Shell Script, RHEL 6.3

How to write in Terminal RHEL 6.3 in a proper way?   If not exist LOCAL_WORKING_DIR LOCAL_EVENT_LOG_WORKING_DIR mkdir LOCAL_WORKING_DIR LOCAL_EVENT_LOG_WORKING_DIR ????   I have tried with this but seems didnt work My script :   if [! -f ] $LOCAL_WORKING_DIR $LOCAL_EVENT_LOG_WORKING_DIR     mkdir $LOCAL_WORKING_DIR $LOCAL_EVENT_LOG_WORKING_DIR   In Windows we use WINSCP & 7zip right , is it okay to use Nautilus 3.10.1 & p7zip_9.20.1???   Do help me , please :)


We have a SQL database on FULL back up with a client  and they have NOT implemented a Log file maintenance and noticed that the log file grows exponentially, filling the 20GB they have allocated to it in a matter of days.  Once they switch into 'maintained log file mode' this problem goes away.  As we are not SQL experts, I am writing to you as to whether exponential growth is normal if you do not maintain the log file.  Thanking you in advance,  Steve


How to compare correctly Strings (and objects) in Java?

For a mini game in where the user tries to guess a name. But when I want to compare two text strings just to check if are the same it seems that doesn't work.       final String miName = "Jhon";     Scanner input = new Scanner(System.in);     System.out.println("Guess my name: ");      while (true) {      String attempt = input.next();      if(attempt == miName) {        System.out.println("Congrats!");        break;      } else {        System.out.println("Try it again!");      }     }   The output:  Guess my name::  Karl Try it again! jhon Try it again! Jhon Try it again!


Expressing a Non Negative Integer as Sums of Two Squares

I'm writing a code in C that returns the number of times a non negative integer can be expressed as sums of perfect squares of two non negative integers.  R(n) is the number of couples (x,y) such that x² + y² = n where x, y, n are all  non negative integers.   How can I mathematically compute R(n)?  What is a very fast algorithm I can use to compute R(n)?


Could you move Thor's Hammer in a wheelbarrow?

If Thor put his hammer down on a wheelbarrow you wouldn't be able to take it out of the wheelbarrow. However would you be able to wheel the wheelbarrow around?  Similarly if you can move the wheelbarrow, would the hammer fall out if you tipped the wheelbarrow?


How to Rewrite Wordpress URL for a Plugin

I am trying to build a Wordpress plugin here with a custom user admin area. What I would like to do is when the user adds /edit at the end of the page, it should open a page from my plugin. So for example  example.com/page-1/edit  should load example.com/wp-content/plugins/custom-user-admin-area/index.php?u=page-1  I am trying to make use of WP_Rewrite but in vain.  class MyPlugin {     function create_rewrite_rules($rules) {         global $wp_rewrite;         $newRule = array('([A-Za-z0-9-].+)/edit/' => 'wp-content/plugins/custom-user-admin-area/index.php?u=' . $wp_rewrite->preg_index(1));         $newRules = $newRule + $rules;         return $newRules;     }      function flush_rewrite_rules() {         global $wp_rewrite;         $wp_rewrite->flush_rules();     }  }  $MyPluginCode = new MyPlugin(); add_filter('rewrite_rules_array', array($MyPluginCode, 'create_rewrite_rules')); add_filter('init', array($MyPluginCode, 'flush_rewrite_rules'));


Having been playing Pokemon GO for the past few days, I would like to know: How is Niantic selecting the pokestops? The reason why I ask is because of how some less popular places get selected for a stop, while popular places that are usually next-door don't have a stop.  TL;DR:  Anyone know what the PokeStop selection process entails? Are there any qualifications? Is there a bias between places?  Specifically, does anyone know how the game mechanic itself works?


How to fix "not a valid identifier" error after setting environment variables?

I'm trying to setup cocos2dx in Ubuntu 14.04 LTS but after setting the environmental variables (in .bashrc) I start getting this error:  bash: export: dev/cocos2d-x-3.2/tools/cocos2d-console/bin': not a valid identifier  bash: export:/home/john/android': not a valid identifier  bash: export: dev/android-ndk-r10b': not a valid identifier  bash: export:dev/adt-bundle-linux-x86_64-20140702/sdk': not a valid identifier   And I don't know what to do to fix it.


My server has been steady at about 2-3%, but today the CPU usage has raised to about 25%  When I run top in command line this is what I see.. user is still low about 1.3% and the same with system about 1.2% but then I look at wa.. 16.1% !?  What is wa and why is it suddenly so high?!


Prove the following identity (Fibonacci numbers)

$$\binom{n}{0}F_0+\binom{n}{1}F_1+\binom{n}{2}F_2+...+\binom{n}{n}F_n=F_{2n}$$   Where $F_n$ represents Fibonacci numbers. Can someone please aid me in solving this proof?


Can I put music files on an iPod without iTunes?

I can't find any definitive info on this and I need to know for sure before I purchase one.  I hate iTunes with a burning passion, but I like iPods and I have a whole lot of music on my PC.  How can I move music from a Windows computer to iOS without using iTunes?


Why doesn't the Doctor go back to Gallifrey before the Time War?

According to , it’s just the Time War that is time locked. So why does Eccelston's Doctor tell Rose:     My whole planet is gone. My people, my family, all gone. Don't you think I want to go back and save them?   Why hasn't he ever gone back to before the war?   All the other Doctors basically see Gallifrey as gone from them, and when you say the Doctor cannot go back on his own timeline, there will have been plenty of time periods he could go to; maybe to a time before they could regenerate, or maybe when Time Lords were using Tardises — as in "The Doctor's Wife" she says to Matt Smith:     I was already a museum piece when I stole you


Adding clause criteria based on logged in user to custom button

I need to add an statement into this custom button so that it only runs if it meets a certain, how would I do this?  The statement essentially needs to say if the logged in user is equal to the R_D_Service_Owner__c or the project_owner__c then it can run, or if the logged in user profile equals 'system administrator' it can run, or if the logged in user equals a specific user id, or another specific user id it can run.  {!REQUIRESCRIPT("/soap/ajax/19.0/connection.js")}    var proName = '{!$Profile.Name}';     var userId = '{!$User.Id}';    var proOwnerId = '{!Product2.Project_Owner__c}';    var serOwnerId = '{!Product2.R_D_Service_Owner__c}';  if(proName.includes("Administrator")||proOwnerId==userId||serOwnerId==userId){  var r = new sforce.SObject("Product2"); r.id = "{!Product2.Id}"; r.Convert_to_Service_Catalogue__c = true; result = sforce.connection.update([r]);   if ( result[0].getBoolean( "success" ) ) {  window.location.reload(); // refresh page  } else {  var errors = result[0].errors; var errorMessages = "The Lifecycle Status must be Beta, and the following fields must be populated; Name, Unique ID, Jisc Directorate, Include in    Dashboard, Service/Project Owner or else this record won't be converted to a     Service Catalogue record";  for ( var i = 0; i < errors.length; i++ ) { errorMessages += errors[i].message + '\n'; }  alert( errorMessages ); // display all validation errors  } } else{     alert("You are not eligible for this operation!");  }


Proof Verification for Lagrange's Theorem

I am reading I.N.Herstein-Topics in Algebra  Question:     For $G$ a finite group. Let $|G|=n$, then $O(a)|n \enspace \forall  a\in G$.   Note: I have already proved that if $G$ is a finite group, then $\exists N\in \mathbb{N}$ such that $a^N=e \enspace \forall a \in G$ and $N\leq n$.  Proof: Suppose $\exists a\in G$ and a minimal $m\in \mathbb{N}$ such that $a^m=e$ and $m\nmid n$.  Given $G$ is finite. Therefore, we have $$a^n=e\\\text{By using division algorthim,}\enspace  n=km+r\enspace\text {for some k}\in \mathbb{N} \\ \implies a^{n-km}.\{a^m\}^k=e \\ \implies a^{n-km}.e=e \\ \implies a^{n-km}=e$$ This Contradicts minimality of $m$.  Therefore, $O(a)|n \enspace \forall a\in G$. This also proves that $N|n$.  Is My proof Correct? Any Improvements and suggestions are appreciated.


What's the default credentials of Ubuntu 18.04 OVA ()


Infinite ring with nonzero characteristic

I was wondering as I read about characteristic of a ring: Is there an infinite ring with nonzero characteristic? We have $1+1+\ldots+1=0$, but that doesn't seem to imply that the number of elements in the ring is finite.


Does conservation of momentum really imply Newton's third law?

I often heard that conservation of momentum is nothing else than Newton's third law.   Ok, If you have only two interacting particles in the universe, this seems to be quite obvious.   However if you have an isolated system of $n$ ($n > 2$) interacting particles (no external forces). Then clearly Newton's third law implies conservation of total momentum of the system. However presuppose conservation of total momentum you only get:  $$ \sum_{i\neq j}^n \mathbf F_{ij} = \frac{d}{d t} \mathbf P = 0 $$  Where $\mathbf F_{ij}$ is the forced acted by the $i$th particle upon the $j$th particle and $\mathbf P$ is the total linear momentum.  But this doesn't imply that $\mathbf F_{ij} = -\mathbf F_{ji}$ for $j \neq i$.  So does conservation of momentum implies Newton's third law in general or doesn't it? Why?


"Emergency Stop" when building simple qtree

Latex fails building the following code with error "Emergency stop."  \documentclass{article} \usepackage{tikz-qtree} \begin{document}     \begin{tikzpicture}     \Tree       [.a         [.b              [.c                 [.d                     [.e                         [.f]                     ]                 ]             ]         ]     ]     \end{tikzpicture} \end{document}   After removing the ".f" child, it compiles fine. Is there some limitation to qtree I have reached?


Where should I add/modify environment variables?

I would like to edit my .bash_profile file. However it appears that in Ubuntu (and perhaps other Debian distros) this is named as .profile.  However I cannot seem to find the expected variables like $PATH, $PS  etc. in the .profile file.  The .bashrc file doesn't seem to do any good either.   I am wondering how I can possibly modify my environment variables in this case.


Find Sylow p-subgroup (at least 1) of $S_{p^2}$. We know that $|S_{p^2}|=(p^2)!$ and hence $|P|=p^{p+1}$ (where P is p-subgroup). How can I describe this subgroup?


Multiple \usepackage vs comma separated package names

What, if anything, is the difference between   \usepackage{foo,bar}   and  \usepackage{foo} \usepackage{bar}


Can spilling a liquid on a keyboard or other input device connected to a desktop computer damage the computer itself?

I've heard that spilling liquid on the (wired) keyboard of a desktop computer can cause damage to the motherboard or other parts.  Is this possible, or will only the keyboard be damaged?  How does this apply to other input devices such as mice, assuming that they are wired?


To list all docker repositories I need to use an asterisk. But I am forced to add quotes because zsh globbing catches the asterisk.  sudo docker image list "hub.local/*"   I try aliasing with noglob, but sudo will fail, and docker needs sudo  alias docker="noglob docker"   I thought I could set zsh to not complain when it fails to match, but it seems zsh will remove the asterisk anyway.  setopt nomatch   I want to either disable zsh globbing entirely, or get zsh to pass through the globbing character if it fails to match. Or possibly set zsh globbing to behave like bash. I want to get around typing quotes all the time.


So I just saw TFA and was just wondering this about starkiller. How did it maintain orbit after destroying its Sun? I don't think that destroying a planets sun would be very good for it.


Where to ask a question if it would fit into different SE sites?

I'm currently interested in (programming) home automation with the rasp-pi.  The question is now where is the best place for that?   , because it is about programing?  , because it runs there?  or on the upcoming  (when we get the missing 28 users)?  Or, is it a better idea to copy (duplicate) the article?


Let $p(n)$ denote the largest prime factor of $n$. Prove that there are infinitely many $n$ such that $$p(n)<p(n+1)<p(n+2).$$  Edit:   My solution: Choose $n=\prod_{i=1}^{k}p_i$, product of the first $k$ primes. This means that $n+1=\prod_{i=1}^{k}p_i+1$ is either a larger prime or has a prime factor larger than that of all factors of $n$. Still not sure about $n+2$.


I have been given the following improper integral to evaluate     $$ \int_{0}^{1} \frac{x^2-1}{\log{x}} dx $$   I tried substituting $ u = \log{x} $ which gives the following improper integral $\displaystyle \int_{-\infty}^{0} \frac{e^{3u}-e^{u}}{u} du $  This integral can be evaluated by software like Wolfram but I am interested in the method. How does one solve the integral analytically? I have no real idea on this. Thanks to all helpers.


Suppose there are two sets, A={a,b,c} and B={x,y} All ordered pairs in form of (element of A, element of B) All ordered pairs in form of (element of B, element of A)


Wien's displacement law in frequency domain

When I tried to derive the  I used Planck's law for blackbody radiation:  $I_\nu = \frac{8 \pi \nu^2}{c^3} \frac{h \nu}{e^{h\nu/k_bT}-1}$  Asking for maximum:  $\frac{dI_\nu}{d \nu}=0:~0= \frac{\partial}{\partial\nu}(\frac{\nu^3}{e^{h \nu/k_bT}-1}) = \frac{3\nu^2(e^{h \nu/k_bT}-1) - \nu ^3h/k_bT \cdot e^{h\nu/k_bT}}{(e^{h \nu/k_bT}-1)^2}$  It follows that numerator has to be $0$ and looking for $\nu>0$:  $3(e^{h \nu/k_bT}-1) - h \nu/k_bT \cdot e^{h\nu/k_bT}=0$  Solving for $\gamma=h\nu/k_bT$:  $3 (e^\gamma-1) - \gamma e^\gamma=0 \rightarrow \gamma=2.824$  Now I look at the wavelength domain:  $\lambda = c/\nu:~ \lambda =\frac{h c}{\gamma k_b} \frac{1}{T}$  but from Wien's law $\lambda T = b$ I expect that  $hc/\gamma k_b$ is equal to $b$ which is not:  $\frac{h c}{\gamma k_b}= 0.005099$, where $b = 0.002897$  Why the derivation from frequency domain does not correspond the maximum in wavelength domain?  I tried to justify it with chain rule:  $\frac{dI}{d\lambda} = \frac{dI}{d\nu} \frac{d \nu}{d \lambda} = \frac{c}{\nu^2} \frac{dI}{d \nu}$  where I see that $c/\nu^2$ does not influence where $dI_\lambda/d \lambda$ is zero.


If $a < b$ and $c < d$, then $a + c < b + d$ if $a, b, c, d$ are positive integers.  My hunch is that this is true, but I'm having difficulty proving it.  Is there a property or definition pertaining to inequalities that exists to support/disprove the above?


Telnetting the local port working but trying with ip not working

My question is similar but opposite to to   For me, telnet to the local port works but trying with IP does not work :(  I am running pgbouncer on port 6432:  $ telnet 192.x.x.x 6432 Trying 192.x.x.x... telnet: Unable to connect to remote host: Connection refused   I set listen_addr = *, but still using telnet with IP from another server is not working.  See  for the same scenario (but no useful answer).  The output of netstat -plnt is   tcp 0 0 127.0.0.1:6432 0.0.0.0:* LISTEN 19879/./pgbouncer   How can I fix this?


Can you play a Progress Card even when you get nothing from it?

If I have a Progress Card for which initial preconditions do not hold, will I still be able to use it in order to discard it back to the pile? The goal is to prevent a spy from stealing it.  A few examples:   I am leading in victory points but I want to use Wedding card. I have Irrigation but I don't have any wheat hexagons. I have Blacksmith but I don't have any ore hexagons.


Java null point exxception occuring while trying out list view

Error:     java.lang.NullPointerException: Attempt to invoke virtual method 'void android.widget.ListView.setAdapter(android.widget.ListAdapter)' on a null object reference   Not getting anything, am confused!  Java code:  package com.listview;  import android.app.Activity; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; import android.widget.ArrayAdapter; import android.widget.ListView;   public class MainActivity extends Activity {    ListView lvAndroid;     @Override      protected void onCreate(Bundle savedInstanceState) {      super.onCreate(savedInstanceState);      String[] arrAndroid=    {"Cupcake","Donut","Jellybean","Kitkat","Lollipop","Marshmellow","Nougat"};        ArrayAdapter adapt = new ArrayAdapter<>(this,R.layout.lv,arrAndroid);    lvAndroid=(ListView)findViewById(R.id.lvAndroid);      lvAndroid.setAdapter(adapt);   } }   Lv.xml  <?xml version="1.0" encoding="utf-8"?> <!--  Single List Item Design -->  <TextView xmlns:android="http://schemas.android.com/apk/res/android"     android:id="@+id/label"     android:layout_width="fill_parent"     android:layout_height="fill_parent"     android:padding="10dip"     android:textSize="10sp"     android:textStyle="bold" > </TextView>   Main activity:  <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" android:id="@+id/activity_main" android:layout_width="match_parent" android:layout_height="match_parent" android:paddingBottom="@dimen/activity_vertical_margin" android:paddingLeft="@dimen/activity_horizontal_margin" android:paddingRight="@dimen/activity_horizontal_margin" android:paddingTop="@dimen/activity_vertical_margin" tools:context="com.listview.MainActivity">  <ListView     android:layout_width="match_parent"     android:layout_height="match_parent"     android:id="@+id/lvAndroid"     android:layout_alignParentTop="true"     android:layout_alignParentStart="true" />  </RelativeLayout>


Introducing the Stack Exchange Data Explorer aka SEDE

This is the announcement post of the Stack Exchange Data Explorer. Its answers were meant to iron out the initial glitches 6 to 8 years ago.  If you have found a bug or need support  today with any of SEDEs features, please ask a new question and tag it with   What does it do? Allows you to run arbitrary SQL queries on the data dumps, and share those queries with your friends. Technical details It is hosted on the Stack Exchange infrastructure , the database is hosted on the same SQL Server version all other sites are hosted on. You can use most of the TSQL commands, even create temporary objects (but not User Defined Functions). The controls used are jQuery based, the grid is  . All query results are cached, so sharing a link to a query will not result in the server going in to a tailspin. The query edit control is a slightly modified  control, I also am considering bespin cause the inter iframe communication is nasty complicated. It gives up nice syntax highlighting for queries. Parameters There is support for parameterized queries, to get it to work name your params like ##this##. For example have a . Query name and description A query can have a name and description, to name it lead with a comment, to describe it continue commenting, for example: -- This is my query name  -- This is my description -- I can span multiple lines  SELECT 1  Anonymous users can initially name a query, but can not change the names of any existing queries. Tutorial There's a  which helps you getting started in writing your own SQL queries. Logging in You can use your openid provider to log in, at the moment once logged in we will track the list of queries you execute (giving you basic history support) Also if there are any params named UserId they will be populated automatically if your EmailHash matches the one on the site being queried. Magic columns If you alias an id column with as [Post Link] it will automatically create a link in the result set to the parent site. Similarly if you alias an id column with as [User Link] it will display a link to the user page. select top 10 * from Posts will show you how tags are done. (Magic columns for images is planned) example (most controversial posts:  ) So what are you waiting for, check it out at  Any feedback would be greatly appreciated. I hope to have the login section working fairly soon and allow voting on the best queries and commenting. Featured Queries At the moment, admins have permission to feature interesting queries on this page , I am looking for better ways to manage the huge query list that is building up.


Why is $B^TB+\lambda\Omega$ positive definite?

In spline regression, it is not uncommon for the basis expansion to create a rank-deficient design matrix $B_{n\times p}$, but it is well-known that penalization of the estimation procedure solves the problem. I don't know how to show that penalization means that $B^TB+\lambda\Omega$ is positive definite. (I know that PD matrices are invertible.)  To set the stage, we seek $\min_{\alpha\in\mathbb{R}^p} \sum_i|| y_i-f(x_i)||^2+\lambda\int_a^b [f''(t)]^2dt $ for the $f(x)$ given by the basis expansion $f(x_i)=\sum_j\alpha_j h_j(x_i)$. Collecting the basis vectors in $B$, I can show rather easily that this optimization reduces to  $$ \hat{\alpha}=(B^TB+\lambda\Omega)^{-1}B^Ty. $$  where $\Omega_{ij}=\int_a^b h_j^{\prime\prime}(t) h_i^{\prime\prime}(t)dt$.   Here is my reasoning so far. We know that $B$ is rank-deficient because $p>n$. This implies that $B^TB$ is also rank deficient; I can also show that at least one eigenvalue is 0 and that it is positive semidefinite.  But now I'm stuck because I don't know how to reason about $\Omega$ or to show that $B^TB+\lambda\Omega$ is PD for any $\lambda>0$. I know that $\Omega$ is a Gram matrix, but that only gets us as far as showing that $\Omega$ is PSD.


How to sort order of map.keySet() in Java?

public class MapKeyExample {     public static void main(String[] args){          //Initializing a Map of type HashMap         Map<Integer, String> map = new HashMap<>();         Set<Integer> s = new HashSet<>();         map.put(1, "One");         map.put(3, "Three");         map.put(5, "Five");         map.put(7, "Seven");         map.put(9, "Nine");         System.out.println(map);         s = map.keySet();         System.out.println(s);     } }   Now the output is   {1=One, 3=Three, 5=Five, 7=Seven, 9=Nine} [1, 3, 5, 7, 9]   The expected output of s is:  [1, 5, 3, 9, 7]   Can someone show me how to modify this to Linkedhashmap or treemap? Many thanks.


Should we explicitly define a language hint for Dart code blocks?

Google Code Prettify currently does not support syntax highlighting for the Dart language (no wonder why). Currently there are already few questions (and answers) about Dart which contain code blocks. As they are not highlighted, would it be right to edit them and explicitly specify an other language (lang-javacript seems to provide the best highlighting options for Dart code)? Like this:  <!-- language: lang-javascript -->  Or it would be better to leave them as is and wait until Google Code Prettify author adds a support for the Dart?


What is the definition of a timelike and spacelike singularity?

What is the definition of a timelike and spacelike ?  Trying to find, but haven't yet, what the definitions are.


What differences and relation are between proof systems and deductive systems?

says  A proof system includes the components:  Language: The set of formulas admitted by the system, for example, propositional logic or first-order logic. Rules of inference: List of rules that can be employed to prove theorems from axioms and theorems. Axioms: Formulas in L assumed to be valid. All theorems are derived from axioms.    says:  A deductive system, also called a deductive apparatus or a logic, consists of the axioms (or axiom schemata) and rules of inference that can be used to derive theorems of the system.  Are proof systems and deductive systems the same concept? What differences and relation are between them?  mentions proof systems, but I don't find it says what relations and differences are between deductive systems and proof systems. Thanks.


Suspend on lid close, even with the option OFF

I've set up a friends laptop with Ubuntu 12.04LTS with the Cinnamon desktop, and I'm having a few issues with the power settings.  As far as I can tell I've got every setting to "Do Nothing" when the lid is closed, however it still Suspends when I close the lid. After much Googling I'm still no closer to a solution, so I came here for help.


Range of values of $R^2$ for a two-feature linear model based on the $R^2$s of one-feature linear models?

I was asked this in an interview. You have two features, $x_1$ and $x_2$. You fit a simple linear model on each feature, so  $$ \underbrace{y = x_1 \beta}_{\text{model 1}}, \qquad \underbrace{y = x_2 \beta}_{\text{model 2}}. $$  You compute the $R^2$ value for each model and find that each one has an $R^2$ of $0.1$. Now you fit a model on both features  $$ y = x_1 \beta_1 + x_2 \beta_2. $$  What range of values can you expect this model's $R^2$ to take? I was stumped and am curious how to reason through this.


Why the cross product of two vectors gives a vector in an orthogonal direction?

I understood the concept of cross product with an example of Torque. I understood the concept. But what confuses me is that how can cross product of two orthogonal vector in a plane give us the product which is in other axis.      i × j =k, how is that possible.  Eg:- This is a spinner.    Suppose we apply a perpendicular force and we multiply it with r so we get the torque (vector product). The spinner starts spinning.    So in this spinning picture how is there a motion or vector in 3rd dimension (k^), as the vector product theory suggests?


Transaction Log file of the secondary database in Log Shipping grows fast and fills up disk space

I have a log shipping setup for DR. The transaction log file of one of the secondary databases, which is in restoring mode, is 7 times larger than the data file and is filling up the disk space. What are the possible causes and fixes?  Note that it is the transaction log file of the secondary database in the DR site that is growing fast.   For your information, for the corresponding primary database, I take a Full backup every night and transaction log backup every 30 minutes. The transaction logs are shipped every 1 hour to the secondary database.  Thanks


how to interpret Interaction term in generalized linear model

I have an experimental condition  (dummy-coded)  as an categorical predictor, and one continuous predictor variable (treatment frequency).  The dependent variable (Y) is consumer satisfaction  This is an SPSS output,   My Q: is how to interpret the coefficients and Exp(B) of the categorical Variable and continuous predictor.   For Categorical variable:  Is it correct to say " Condition 0 is .34 more effective than Condition 1 in enhancing consumer satisfaction. Or, can I say if the treatment frequency is fixed, Condition 0 compared to Condition 1 will increase the odds of satisfaction by 0.40." ?   For continuous predictor: Is it correct to say " When 1 unit increases in frequency, the satisfaction increase by .15 when the condition is 1. Or, if the condition is fixed to 1, treatment frequency will increase the odds of satisfaction by 0.17." ?   My last question is how to interpret the significant interaction term. Could you help me interpret the interaction term using the coefficient and also Exp(B)?   If you can recommend an published article that describe results from generalized linear model using interaction term, that'd be appreciated. Thank you.


from JSON object to Java Script Object that contains js function name

I have this JS object:    { validator: myValidator }   myValidator is a java JAVASCRIPT function NAME that will be declared somewhere else. I am planning to use it like:  <TableHeaderColumn dataField='status' editable={ { validator: myValidator } }>Job Status</TableHeaderColumn>   where TableHeaderColumn  is a react component. So, the question is: What is the JSON string that after using JSON.parse or a similar command I will obtain the { validator: myValidator } object where  myValidator  is "the name of a function", not a string. This is not clear for me inclusive at the referenced solution.


In Harry Potter and the Philosopher's Stone, Harry buys a Chocolate Frog from the Trolley Witch. On the back, there is a trading card. It's of Dumbledore, but his picture disappears quickly. When Harry questions Ron, he is told Dumbledore has other places to be:     Harry turned the card back over and saw, to his astonishment, that   Dumbledore's face had disappeared.      "He's gone!"      "Well, you can't expect him to hang around all day," said Ron. "He'll be   back."   This means Dumbledore has to travel between pictures. Logical- only one picture version of him. But later, whenever a large piece of news came out, we saw  witches and wizards everywhere reading news on it, in stacks like these:    Presumably, all of these have the same pictures of people, the same ads, the same of everything. But, if there's only one picture of each person/creature, how can all of these share photos?


I am trying to download turtl, I download the tar.gz then I run  sudo sh install.sh put in my password but I don't see anything working. Are these steps correct or am I missing something? If you experience or similar problems please let me know, I am kind of new to installing software on Ubuntu.


Create Generic Class Depending on Type of Runtime Variable

Is it possible to create an instance of a class of type T depending on the type of a runtime variable?  For example:  var myType = myVariable.GetType(); var myTestClass = new TestClass<myType>();    This will not compile but hopefully shows what I'm trying to achieve.  Is there a way?  EDIT  Say the class is like this:    public class TestClass<T> {          public string StringValue     {         get         {             return this.TypeValue == null ? string.Empty : this.TypeValue.ToString();         }        }      public T TypeValue { get; set; }   }   If I did something like:  var test1 = TestClass((dynamic)x); // x is an int   I would be able to set like test1.TypedValue = 10  If I did something like:  var test2 = TestClass((dynamic)y); // y is a bool   I would be able to set like test2.TypedValue = true  At the moment I get an error stating      cannot implicitly convert type int to TestClass (or bool to TesClass)


I am wondering if it is correct to say, "I love it that the children enjoy school", or "I love that the children enjoy school", in colloquial speech?


Prove that solution of the equation $8x^3-4x^2-4x+1= 0$ has roots $\cos\frac{\pi}{7},\cos\frac{3 \pi}{7},\cos\frac{5 \pi}{7}$

Prove that solution of the equation $8x^3-4x^2-4x+1= 0$ has roots $\cos\frac{\pi}{7},\cos\frac{3 \pi}{7}\space \text{and}\space \cos\frac{5 \pi}{7}$.    How to even solve it ? I have no idea.   Because cubic have no formula like quadratic equations to obtain the roots and the expression like $\cos\frac{\pi}{7}$ is something that I don't think I can evaluate with my limited knowledge (I'm in highschool) of only $\cos 2x$ or $\cos 3x$ type. Since it has denominator of 7, I thought maybe the seventh root of unity might help me, but since only some of its multiples are used, I don't think so it will be of much use.   How do I solve this problem. Please help.


Is there a way to limit the scope of \usepackage?

When I tried to use the breqn package suggested by an answer to the question      It managed to break a whole bunch of unrelated equations (equations that did not use its functionality), including a definition for the control sequence \mf which I had previously defined myself.  Is there a way to limit the scope of a \usepackage declaration so that its (positive and negative) effects are limited to a particular segment of a document?  I have tried putting it inside an environment, but get the following error:  ! LaTeX Error: Can be used only in preamble.


I made a hard linked file in terminal by command: ln somefile somefile_h and used it for fun. Now I faced a question that how can I delete the link between these two files and use it separately? Anybody know?


What is the difference between framerate independent vs framerate dependent?  Can you please give an example.


I have found this piece of code in a project I am working on:  +new Date(DateTime)   Note the + before new. If I pass in this value:  '2020-09-15T01:00:00Z'   It outputs this value:  1600131600000   Can anyone explain to me what this value is? It is not unix time - or at least the unix time moment outputs:  moment().unix(DateTime) = 1531737560   I am cleaning up my date formats within the project and cannot work out how to recreate this with moment...  EDIT:  How can I recreate this in moment.js?


integral roots for $f(x) = 41$ if $f(x) = 37$ has 5 distinct integral roots.

Given a polynomial $f(x)$ with integral coefficients and $f(x) = 37$ has 5 distinct integral roots, find the number of integral roots of $f(x) = 41$?  My Approach: Say $f(x) = (x-r_1)(x-r_2)(x-r_3)(x-r_4)(x-r_5)g(x) + 37$, where $r_i$ are the distinct integers.   Now for $f(x) = 41$ we have $(x-r_1)(x-r_2)(x-r_3)(x-r_4)(x-r_5)g(x) = 4$, so the factors can be $\pm 1, \pm2$ or $\pm 4$. Given $r_i$ are distinct at most two of them will give $\pm1$, then there can be both of $\pm 2$ or one of $\pm 4$. This is where I get lost, since even if I use all of $\pm1, \pm2$, I will be still be left with one $x-r_i$ factor. What about that? Does it matter that 37 and 41 are primes, or is it just a coincidence?  Thanks in advance.


How to cover the below lines of code in a test class?

Please help me in order to write the test class for the below lines of code: Id objUser = UserInfo.getUserId(); UserRecordAccess objRecordAccess = [Select RecordId, HasEditAccess From UserRecordAccess Where UserId =: UserInfo.getUserId() And RecordId =: objRecordId]; Note: objRecordId is an Id passed as an argument to the method


How can I prevent blender from exporting fbx with-90 rotation on the x axis to unity?

When I create something in blender and than I export it to unity as an fbx, it is rotated -90 degrees on the x axis to keep it correct rotation but can I export it with (0,0,0) rotation by default ? So it will be correctly rotated and its rotation would be (0,0,0).