Comprehensive book on group theory for physicists?

I am looking for a good source on group theory aimed at physicists. I'd prefer one with a good general introduction to group theory, not just focusing on Lie groups or crystal groups but one that covers "all" the basics, and then, in addition, talks about the specific subjects of group theory relevant to physicists, i.e. also some stuff on representations etc.  Is Wigner's text a good way to start? I guess it's a "classic", but I fear that its notation might be a bit outdated?


vim-clang-format: clang-format is not found

I installed clang-format on Ubuntu 18.04 LTS with sudo apt install clang-format and the installation was successful. I can execute clang-format-6.0 now, but when I use ClangFormat in vim, it tells me that "clang-format is not found". How can I fix the problem?


Remove Google Search Bar on Nexus devices running on stock Lollipop

I have been reading for days about how to remove the Google Search Bar from the top of my Nexus 6 since I never use it. I have gotten mixed answers on exactly what file to delete and where it is.  I have heard quicksearchbar.apk but it's not in /system/app like in previous versions. Does anybody know where the file/files are I need to delete in order to get rid of the search bar, or else, how to remove it? Preferably not downloading another launcher, since I don't want to bloat my phone when I could reduce the size.


Problem with digits in URLs when using mathspec and hyperref

When I use mathspec's \setmathsfont and hyperref, and try to typeset a URL, most of the URL uses monospace, as it should. Good.  However, digits use the maths font. Anyone know how to fix this?  MWE  \documentclass{article} \usepackage{mathspec,fontspec,hyperref}  \setmathsfont(Digits){Minion Pro} \setmonofont{Source Code Pro}  \begin{document} \nolinkurl{abc123def} % same problem with \url{..} \end{document}   Output


Do I need a Mexican visa with my US valid visa to travel to Mexico?

I'm an international student in the US, and am traveling to Mexico on March 6th-12th. I'm a citizen of Tajikistan and have a friend from Russia who didn't need a Mexican visa with the valid student F-1 visa to travel to Mexico. I've been doing some research going to Mexican embassy for some info and asked my school adviser whether I need one he said yes, however, information on these web sites are confusing me: Take a close look at b)  On the other hand on the following link under the Requirements Tourist Visa to Travel to Mexico:   it's asking to bring a valid US visa to apply for the Mexican visa. While I was with J-1 in 2008 I did apply for the Mexican visa though and somebody else did the documentation on behalf of me. So this is my very first time applying by myself and am confused a bit. Note: I'm going to Cabo which doesn't do stamp by arrival. Thanks for the feedback in advance!  UPDATE: It looks like with the US visa stamp on a foreign passport we're not required to have a Mexican visa. I did travel to Los Cabos, Mexico and didn't have any visa trouble.


Event binding on dynamically created elements with jQuery

Can someone point out to me, on what could be done different in this code, so the On('click') event can be bound to the newly inserted link. Right now there is a link which gets replaced at the end of the function. But after it has been replaced, it doesn't have ON('clicked') attached to it any more. Any suggestions greatly appreciated.   (function(){     var form, $this, info, modal;     modal=$('#addPreviousCrop');     form=modal.find('form').first();     $("a[data-target='#addPreviousCrop']").on('click',function(){         modal.find('.panel-heading h4').first().text('Update Previous Crop');         $this=$(this);         if($this.data('method')==='PATCH'){             //get the record to be updated             resetForm(form);             $.get('dairyCrops/'+$this.data('id')+'/edit',function(data){             populateForm(form,data,data.id);         });         }         form.find('#company_field')                 .html(' <strong>'+$this.data('company_name')+' - '+$this.data('field')+'</strong>');         form.find('input[name=acreage]').val($this.data('acreage'));         form.find('select[name=dairy_crop_variety_id]').on('change',function(){             var selVal=this.options[this.selectedIndex].text;             form.find('input[name=seeding_rate]').val(getSeedingRate(selVal));         });         info = {property_id:$this.data('property_id'),status:'previous'};     });       //submit previous crop     form.on('submit',function(e){         e.preventDefault();         $.when(submitAjaxRequest(this,info)).then(function(data, textStatus, jqXHR){             modal.modal('hide');             $this.closest('td').html(data.crop).slideDown('slow');         });     }); })();


Does bash (or any shell, for that matter) have an 'overwrite' mode?

I'm running similar commands on (e.g.) a set of files. As an example, let's say I'm doing something like this (this isn't what I'm doing, it's just an example):  > cat path/to/dir/file01.txt   [file contents] > another-command path/to/dir/file01.txt   [more output] > cat path2/to/dir/file02.txt   [file contents, from which I can tell I should do something different] > different-command path2/to/dir/file02.txt   [yet more output] > cat path3/to/dir/file03.txt   [file contents] > another-command path3/to/dir/file03.txt   [output]   etc.  It would be convenient if, after using the ↑ key to return to a previous command, I could overwrite non-duplicated text ― like the file name, or a common part of the path — rather than having to delete it and retype it.  Is there a way to do this?


How to cd to a directory with a name containing spaces in bash?

I tried cd "~/Library/Application Support/" -bash: cd: ~/Library/Application Support/: No such file or directory  also cd ~/Library/Application Support/ -bash: cd: ~/Library/Application Support/: No such file or directory


Prove that the number $19\cdot8^n+17$ is not prime, $n\in\mathbb{Z}^+$

On a Google search, I've notice that often the "trick" involves factoring the expression (and thus showing that the expression isn't prime), but I can't see it. Is this how you would go about it in this case, or would that be a dead end? Any hints?


In a statement of purpose for a PhD in computer science in the US is it better to express interest in a single subdiscipline or multiple?

It seems that if I were to just express interest in a single subdiscipline (computer networking for example), and none of the networking professors are taking on students, I would not be considered based on any other merits my application may have. But if I were to express interest in several subdisciplines it may be difficult to create a structured statement of purpose.


I read somewhere that $E=mc^2$ shows that if something was to travel faster than the speed of light then they would have infinite mass and would have used infinite energy.   How does the equation show this?  The reason I think this is because of this quote from Hawking (I may be misinterpreting it):     Because of the equivalence of energy and mass, the energy which an object has due to its motion will add to its mass. This effect is only significant to objects moving at speeds close to the speed of light. At 10 per cent of the speed of light an objects mass is only 0.5 per cent more than normal, at 90 per cent of the speed of light it would be twice its normal mass. As an object approaches the speed of light its mass rises ever more quickly, so takes more energy to speed it up further. It cannot therefore reach the speed of light because its mass would be infinite, and by the equivalence of mass and energy, it would have taken an infinite amount of energy to get there.   The reason I think he's saying that this is as a result of $E = mc^2$ is because he's talking about the equivalence of $E$ and $c$ from the equation.


Proximal Operator of an $ {L}_{\infty} $ Norm with a Constraint

Dear Convex Optimization Experts,  My question is related to this post: , but not really same, I think, as I have a constraint. Apologies if it is obvious to extend the answer.   So, I am seeking a proximal operator $\textrm{prox}_{\lambda f}(x)$ of this function $$f(x) = I\left\{x \in C \right\} \ ,$$ $$C = \left\{x : \lVert x \rVert_{\infty} \leq \gamma \right\} \ ,$$ where $x \in \mathbb{R}^{n \times 1}$, $I\left\{\cdot \right\}$ is an indicator/characteristic function, $\gamma \in \mathbb{R}^{n \times 1}$, and the constraint $\lVert x \rVert_{\infty} \leq \gamma$ is element-wise.   EDIT: The desired constraint is: $$C = \left\{x : |x_i| \leq \gamma_i \right\} \ ,$$


How can I prevent a trigerred TNT to explode?

So I was just about to make a self-destruct button under the floor (don't ask me why I make such a dumb thing) and I accidently activated a single TNT. It is going to explode after 4 seconds, blowing up my structure as there is somehting like 7 TNT block in range.    Is there any way to delay/stop TNT from exploding after it has been triggered?    I cant use command block because there's only 4 seconds before the explosion. I'm on a normal single player map I can use commands, cheat is enable


I have been trying to make my footer go at the bottom for the past 2 hours and I can't quite get it fixed at the bottom part. My html code is in here ``https://pastebin.com/UE7NfbWB while I only use bootstrap for my css and I didn't change or add something major, just adding some colors. The red rectangular area is the free space like something is jammed in it.


Far from my expertise, but sheer curiosity. I've read that  ("a complexity class consisting of all of the computational problems solvable in polynomial time on a quantum Turing machine with postselection and bounded error") is very powerful.  Still, I don't understand the practical sense of assuming you can decide the value an output qubit takes.  My question: Have post-selection quantum computing experiments been implemented (or is it possible that they will be implemented)?  (And, if the answer is yes: how does post-selection take place in a way that practically enhances your computing power?)


In an attribute table, how should I go about adding a Unique ID into a field? For example, I have a Water Meter points layer with an attribute table but I need a field that list them numerically with WM attached to the numbers. I would like to have a field displaying WM1001, WM1002, etc. Is there any way to accomplish this? Thanks.


Do the last digits of powers of a number $n$ follow the same cycle as the last digits of the number $n$'s last digit's powers?

In many places it is said that the last digits of the powers of the numbers from 1 to 9 have certain cycles. For example the last digits of powers of 2 repeat in a cycle of $4, 8, 6, 2$, and the last digits of powers of 9 repeat in a cycle of $1, 9$.  It seems like this works for bigger numbers as well. The last digits of any number's powers seem follow the cycle of the number's last digit's cycle. For example, the cycle of the last digits of powers of 7 is $9, 3, 1, 7$, and the cycle of the last digits of powers of 1097 are $9, 3, 1, 7$. I've been experimenting with my calculator and I haven't found a single counterexample, so my guess is that it's true for all numbers. That is, the last digits of powers of a number $n$ follow the same cycle as the last digits of the number $n$'s last digit's powers. Could someone show me a proof of this?


How is Yu-Gi-Oh played with more than two players?

When I play Yu-Gi-Oh, I want to play with my brother and sister. The problem is that we don't know how to play with more than two people playing. Are there any additional rules I have to incorporate to be able to play this way?   For example, how do I determine whose monsters I can attack? Or do both my opponents count as a single one?  Just saying, nobody should be on teams*.


$H, K$ normal subgroups of a finite group $G$ with $G=HK$, $P$ is a Sylow $p$-subgroup of $G$, then $P = (P\cap H)(P\cap K)$

The proposition I want to prove is this: If $H, K$ are normal subgroups of a finite group $G$ such that $G=HK$, and $P$ is a Sylow $p$-subgroup of $G$, then we have that $P = (P\cap H)(P\cap K)$. Since $P$ is a Sylow $p$-subgroup of $G$, and $H, K$ are normal, we have that $(P\cap H)$ and $(P\cap K)$ are Sylow $p$-subgroups of $H$ and $K$ respectively. Then we also know that $|(P\cap H)(P\cap K)|= \frac{(|P\cap H|)(|P\cap K|)}{|P\cap H\cap K|}$, so the cardinality of $(P\cap H)(P\cap K)$ is a power of the prime number $p$. Edit: A not so immediate fact is that actually $(P\cap H)(P\cap K)$ is a group. To see that we could think of the normalizer of $P$ in $G$. Then $P\cap H$ is a normal subgroup of $N_G(P)$ and so is $P\cap K$, hence $(P\cap H)(P\cap K)$ is a group and actually it is a normal $p$-subgroup of $N_G(P) $. I'm not sure how to continue from there. Thank you in advance for any help!


Javascript plus equals 0.5 adding 0.50000000001

I'm adding 0.5 to a number every second. However, it seems to be adding 0.5000000000001 instead.  window.setInterval(function() {     number += 0.5;     // it says number as 0.50000000001, and after 1.00000000002 }, 1000);   Does anybody know why this is happening?


Why is the speed of light arbitrarily the limit?

I know Einstein was great and all. Why is it that exactly at the speed of light is where infinite energy is required to accelerate any object with mass? Is it simply because the math of relativity checks out and explains most of everything? Are there any physicists who disagree with Einstein's theory?


I have names of class a and b:  string nameTypeInput = activityNamespace + "." + className; string nameTypeOutput = activityNamespace + "." + (className.Replace("Request","Response"));  Type typeInput = Type.GetType(nameTypeInput); Type typeOutput = Type.GetType(nameTypeOutput);   I have to do something like this:  var rsp = (object)request as DaDaDocsActivityBase<typeInput, typeOutput>;   But I have the following error:     'typeOutput' is a variable but is used like a type   What am I doing wrong?


If a function is odd/even, then its best polynomial approximation is also odd/even.

If $f$ ∈ $C([a,b])$ is an even/odd function, then show that the best approximation among the polynomials of degree n is also even/odd.  I'm almost certain that to show this directly, you should use the Chebyshev Equioscillation Theorem.  I start by assuming that for some function $f$ ∈ $C([a,b])$, the best polynomial approximation of degree n is $P$. Then, by the theorem, $f$(xi) - $P$(xi) = (-1)i||$f$ - $P$||∞ for at least n+2 many points in [a,b].   If $f$ is even, then $f$(xi) = $f$(-xi), and if $f$ is an odd function, then $f$(xi) = - $f$(-xi)  I just can't piece this stuff together though  EDIT: It was pointed out that the problem doesn't make much sense unless the interval [a,b] is actually [a,-a]. The problem, however, doesn't address this, sadly.


Install from live USB on new Intel NUC errors out

I've just got a brand new Intel  NUC (along with 32GB RAM and a 1TB Intel SSD NVMe) and would like to install ubuntu on it. Since the disk is completely new it does not have anything installed.  From another Ubuntu PC I downloaded the Ubuntu 18.04 LTS iso (and validated the checksum) and created a live Ubuntu USB stick using the "Startup Disk Creator" utility, plugged in the USB in the NUC, and booted it. I could select the language, the keyboard, minimum installation, and third-party drivers with secure boot.  When the partitions were going to be created I got an error (don't remember which one). I went back and tried several times selecting or deselecting secure boot, but still got an error and could not continue. It kept coming back to the manual partitions creation.  Then I decided to reboot and see if I'd have better luck. But I've never managed to boot the live usb again! Instead I always get:  Failed to open \EFI\BOOT\mmx64.efi -Not Found Failed to load image \EFI\BOOT\mmx64.efi -Not Found Failed to start MokManage: Not Found Something has gone serious wrong:import_mok_state() failed : Not Found   When I boot the NUC without USB I simply get A bootable device has not been detected.  I've tried going into the BIOS and disabling Secure Boot (as suggested in one of the answers to ), but it still didn't help. I've also tried to reformat the USB stick and recreate it, but no change. So it seems that something has changed on the NUC that prevents it from booting the live usb.  What else should I try?  Update:  The linked question (that is also referred when marking this question as duplicate) covers the case when one has dual-boot and ubuntu already installed. The accepted answer suggests to copy on of the .efi files when booting with a live USB. My problem is that I can't event boot the live USB! And I can't change the live usb as it's read only. So my question is what I should do next?


Different implementation of downvoting: require comments

OK, I know this has been discussed before ,   but I'd like to make a new suggestion.  Problem: drive-by downvoting - people downvote without explaining why. And when you downvote, legitimately, you lose rep, as does the questioner / answerer. This strikes me as being a lose / lose situation.  Previous solutions: e.g.  and  have required forcing comments.  Solution: How about this instead: keep the current system (downvoter loses rep) unless the downvoter adds a comment in which case no rep is lost. I think this is win/win. The downvoter can choose to enter comments but is encouraged to do so, which increases the feedback to the original questioner / answerer.


I try with dd command and Disks & USB Image Writer, when the process is finished, still USB is empty.  :~$ sudo dd if=/home/user/Downloads/linux.iso of=/dev/sdb bs=4M conv=sync status=progress


Problem: Let $(x_i)$ be a sequence in (0,1) such that $\lim_{n \to \infty} (1/n)\sum_{i=1}^n x_i^k$ exists for every $k=0,1,2,...$ and $f\in C[0,1]$. Show that $\lim_{n \to \infty} (1/n)\sum_{i=1}^n f(x_i)$ exists.  I've used the fact that $B_n(f)$ converges uniformly to $f$ to get   $\lim_{n \to \infty} (1/n)\sum_{i=1}^n f(x_i) = \lim_{n \to \infty} (1/n)\sum_{i=1}^n \sum_{k=0}^n f(\frac{k}{n}) {n \choose_k }x_i^k (1-x_i)^{n-k}$  And then you can arrange to get   $\lim_{n \to \infty} (1/n) \sum_{k=0}^n \left[ f(\frac{k}{n}) {n \choose_k }\sum_{i=1}^nx_i^k (1-x_i)^{n-k}\right]$  I want to use the fact that $(1-x_i) < 1$ to consolidate some of the equation but I get nowhere.


When I was in school, I learned what a circle was. Later, I learned what an ellipsis was. I also discovered that a circle is a particular case of ellipse (both foci at the same location).  Now, I'm pretty sure mathematicians have already studied "generalized ellipsis". I mean ellipses with more than two foci.  What's the name of these mathematical objects?  Some links to studies of these objects will be much appreciated.


A band of 9 pirates have just finished their latest conquest - looting, killing and sinking a ship. The loot amounts to 1000 gold coins.  Arriving on a deserted island, they now have to split up the loot. You, as the captain of the band, have to propose a distribution plan (who gets what). What's your proposal?  Consider that this bunch is a democratic lot. If your proposal is accepted by half of the group, then everybody adheres to it. However, if folks feel you are getting greedy, and less than half of the band agrees to your proposal, then they kill you, and then your First Mate gets to make a proposal. And so it goes in decreasing order of hierarchy/seniority.


Absolute and Conditional Convergence of the integral $\frac{\sin(x)}{x^p}$ for real values of $p$

I need to determine the values of p for which this integral converges conditionally and absolutely.  $$\int_{0}^{\infty} \dfrac{\sin(x)}{x^p} dx $$  I think the interval for conditional convergence is $0 < x < 2$ and for absolute convergence the interval is probably $0 < x < 1$. I'm guessing that I need to somehow compare it with the $\dfrac{1}{x^p}$ integral, but I am not sure exactly where to begin and how to logically proceed. I first thought about dividing the integral into two separate improper integrals, with one of them integrating from $0$ to $1$ and the other from $1$ to infinity, but I do not know how to continue from that point on.


What's the difference between installing packages and software from the main server and from the local country server?


How i can use variable inside javascript match function

I'm trying to use variable inside regex match function but it's not working.  Here is my code:  var text = "jon"; Persons.match('/
(.*?)'+ text +'(.*?)<\/tr>/g');   I have also try it:  Persons.match(/
(.*?)text(.*?)<\/tr>/g);   it's consider text as a string not a variable.


What is the generalization of $\Pr[ x_1 < X \leq x_2, y_1 < Y \leq y_2]$ to three random variables? To n random variables?

Given two random variables $X,Y$, it is well known that   $\Pr[ x_1 < X \leq x_2, y_1 < Y \leq y_2]  = F_{X,Y}(x_2,y_2) - F_{X,Y}(x_1, y_2) - F_{X,Y}(x_2, x_1) + F_{X,Y}(x_1, y_1)$  Where $F_{XY}$ is the joint CDF of $X,Y$.  Is there a generalization of the above to three random variables $X,Y,Z$?  To $n$ variables $X_1, \ldots, X_n$?  I have looked at a few probability references but I couldn't find any.


Reducing the degrees of freedom of a Lagrangian in a spherical potential by using integrals of motion

I'm sure I've made a silly mistake here, so I would be very grateful if someone could help me clear it up! Here is my reasoning:  The Lagrangian in a spherical potential is  $$ \mathcal{L}=\frac{m\mathbf{v}^2}{2}-U(r) = \frac{m}{2}(\dot{r}^2 +r^2\dot{\theta}^2+r^2\sin^2(\theta)\dot{\phi}^2)-U(r). $$ Now $\frac{\partial\mathcal{L}}{\partial\phi}=0$, so the corresponding momentum $p_\phi=\frac{\partial\mathcal{L}}{\partial\dot{\phi}}=mr^2\sin^2(\theta)\dot{\phi}$ is constant in time. This means that the Lagrangian can instead be written  $$ \mathcal{L} =\frac{m}{2}(\dot{r}^2 +r^2\dot{\theta}^2+\underbrace{[r^2\sin^2(\theta)\dot{\phi}]}_{p_\phi}\dot{\phi})-U(r) =\frac{m}{2}(\dot{r}^2 +r^2\dot{\theta}^2)-U(r)+\frac{d}{dt}(\frac{m}{2}p_\phi \phi). $$ Since $p_\phi$ is constant the last term is a total derivative and so can be omitted completely, and the Lagrangian may be written as  $$ \mathcal{L}’= \frac{m}{2}(\dot{r}^2 +r^2\dot{\theta}^2)-U(r) $$ The Lagrangian now has $\frac{\partial\mathcal{L}’}{\partial\theta}=0$ which was not true for the original one. Something has clearly gone wrong, but where?  Also, following the same logic for $\theta$ gives that  $$  \mathcal{L}’’= \frac{m\dot{r}^2}{2}-U(r) $$  Which is also wrong - the effective potential energy has the wrong form.


Prove that $\sum\limits_{cyc} a^7 \geq \sum\limits_{cyc}a^4b^3$

Prove that $a^7+b^7+c^7\ge a^4b^3+b^4c^3+c^4a^3$ SOURCE :   It was one of the practice problems. Equality case is easy. I tried AM-GM and Muirhead, but could not seem to find a suitable proof for the inequality. Any hint would be really helpful. Thanks in advance ! ^__^


Which is correct and are there any differences in meaning or nuance?  I have the data on my iPad  I have the data in my iPad   I searched data on my iPad and data in my iPad on google, and got many results on both sentences.


String s1 = "String"; String s2 = "String" + ""; String s3 = "" + s2; System.out.println (s1 == s2); System.out.println (s2 == s3); System.out.println (s1 == s3);  true  false  false   Why do I get false values ? Shouldn't be s3 variable in String pool ? It's the same. It seems I don't understand String pool fully.


Double free or corruption when using destructor

In the following code when I add the the line which is specified with an arrow gives error:      Error in `./a.out': double free or corruption (fasttop):   0x00000000007a7030 * Aborted (core dumped)   The code works if I do not use destructor. Any idea?  #include<iostream> #include<vector>  struct Element {     int *vtx;      ~Element ()     {         delete [] vtx;     } };  int main () {     Element *elm = new Element [2];     elm[0].vtx = new int [2]; // <----- adding this gives error      std::vector <Element> vec;     vec.push_back (elm[0]);     vec.push_back (elm[0]);      return 0; }


"Temporary failure resolving us.archive.ubuntu.com" Live USB rescue

I'm trying to rescue my Ubuntu 16.10 server installation, since I have accidentally removed the kernel...  Now that I've booted to a usb, and run a shell with the mounted file-systems, DNS does not seem to want to work, ping google.com returns "unknown host" and if I ping 192.168.1.1 (gateway) it works fine, and if I ping 8.8.8.8 it also works fine, however I cannot do much without DNS.    There is an image of the errors.  So, my question is: how can I restore my DNS so I can ultamately restore my server?  Thanks.


Does there exist an isomorphism between the semigroups $S(4)$ and $\mathbf Z_{256}$.    $S(4)$ is the set of all maps from the set $X$ to itself and $X = \{1, 2, 3, 4\}$. $S(4)$ is a semigroup under the composition of mappings and $\mathbf Z_{256} = {0, 1, 2, … , 255}$ is the semigroup under multiplication of integers modulo 256.


Immersion of $\mathbb{R}$ to $\mathbb{R}^2$

I have no idea how to prove that the set $\{(x, |x|): x\in\mathbb{R}\}$ is not the image of an immersion of $\mathbb{R}$ into $\mathbb{R}^2$  For example   If $f(t)=(t^3, |t|^3)$ then $f'(0)=(0, 0)$.


I got my Samsung Galaxy Y rooted a month ago. Will a Factory Reset harm the phone? Will it still have root?


Two reflections generating the Dihedral group $D_n$

Let $l_1$ and $l_2$ be two lines intersecting at an angle of $\pi/n$ on $\mathbb{R}^2$. Let $r_1$ and $r_2$ denote the reflection by $l_1$ and $l_2$ respectively. I am to show that $r_1$ and $r_2$ generate a Dihedral group $D_n$.  First I claim that $D_n$ can be generated by a reflection $r$ about a line and rotation by angle $2\pi/n$, $\rho_{2\pi/n}$, because reflection by any other line intersecting at an angle of $2\pi m/n$ can be obtained by first applying $\rho_{2\pi/n}$ $m$ times, followed by $r$, and then followed by $\rho_{2\pi/n}^{-1}$ $m$ times.  Then I deduce from drawing and basic geometry that $$r_1 r_2 = \rho_{2\pi/n}$$  Therefore $r_1$ and $r_2$ generates a Dihedral group $D_n$.  I am not sure if my answer is correct or rigorous enough.


Is the "snow" effect on the Winter Bash page open source?

I don't know if it's the right place to ask this, please correct me if that's the case.  The "snow" effect on the Winter Bash page is pretty cool, is that an open source plugin? I was looking at the code, but it's (obviously) minified/obfuscated. Is it something we can use ourselves?


How to convert multiple duplicate columns as single row with appreciated values

how to convert multiple duplicate columns as single row with appreciated values see the image my actually table and expected result.


Do not disturb mode - but allow certain apps

I want to turn on do not disturb mode on my iPhone. But we use a pager application for work, and I want that application to still be able to notify me and make noises.  How do I do that? I can only figure out how to allow contacts to not be in do not disturb mode.


Should I enabled or disable xHCI hand-off in BIOS setup, when running Windows 7?

I have a Jetway NF9E-Q77 motherboard which supports USB 3.0.  An Intel driver is available to enabled USB 3.0 support in Windows 7.  Assuming the driver is installed, should xHCI hand-off be enabled or disabled in BIOS setup?    The BIOS manual says this:    I know Windows 7 doesn't natively support USB 3.0. That being the case, it seems the setting should be enabled.  On the other hand, the Intel driver enables USB 3.0 support in Windows 7. That being the case, it seems the setting should actually be disabled.  Which one is correct?


How to prove that derivatives have the Intermediate Value Property

I'm reading a book which gives this theorem without proof:     If a and b are any two points in an interval on which ƒ is differentiable, then ƒ'   takes on every value between ƒ'(a) and ƒ'(b).   As far as I can say, the theorem means that the fact ƒ' is the derivative of another function ƒ on [a, b] implies that ƒ' is continuous on [a, b].  Is my understanding correct? Is there a name of this theorem that I can use to find a proof of it?


Panasonic FZ200 SD Card - does Class 10 UHS-I improve performance in the camera over a standard Class 10?

I was wondering if anyone has tried multiple cards in the FZ200 to find out just how fast it needs to be to make the camera as fast as possible? I bought a kit that looks like it includes a generic class 10 32GB card and I am considering buying a new one that is rated at 600x class 10 UHS-I made by transcend for about $29 USD. But if it won't make any difference besides reading it into the computer faster using a usb 3.0 card reader, I won't worry about it.   I read that some people using the high speed video modes, like 720p at 120fps had problems with it getting a write error on slower cards after about 15 seconds since the card couldn't keep up with the writing of the video, but I believe this was with a class 6 card they were trying to use. The camera users manual says it is compatible with Class 10 UHS-I, but a lot of times that just means it will work, not that it is necessarily better. It says it requires a class 4 or higher when recording motion pictures, but then I read about someone with a class 6 not being fast enough in some cases. I hope someone out there has tested some different cards and that you can help enlighten me on the subject. Maybe someone knows a place that tested different cards in the FZ200 and you could point me in that direction.   I have found reviews on various new UHS-I cards, but that doesn't really matter since I know it doesn't need the fastest class 10 UHS-I card there is, since it says it should work with a class 4. I really just want to feel confident that I can get all of the performance out of the camera that I can without slower burst speed or getting video errors unlike people with a faster card.  Thanks


Do I need a Transit Visa if i change my flight at Dubai

Suppose I am going to Delhi from Bahrain and by diffrent airlines , and at Dubai airport I collect my luggage and again went to immigration for boarding my next flight . Do i required transit visa in this scenerio


injective ring homomorphism inducing a non-injective homomorphism?

I am looking for an example of an injective ring homomorphism $\phi\colon A\to B$ such that the following holds: there exists a prime ideal $\frak q$ of $B$ such that $\phi^{-1}(\frak q) = \frak p$, and the induced map $A_{\frak p} \to B_{\frak q}$ is not injective.  The algebro-geometric picture should be clear: if we put $X = \mathrm{Spec\, A}$ and $Y = \mathrm{Spec\, B}$, then $\phi$ induces a morphism $(\psi,\theta)\colon Y\to X$ of affine schemes with $\psi(\frak q) = \frak p$. The map $A_{\frak p} \to B_{\frak q}$ corresponds to the induced map on the level of stalks at $\frak q$ of the morphism of sheaves $\theta^\sharp \colon \psi^* \mathcal O_X \to \mathcal O_Y$ [I have used the notation from EGA I].


Problem programming ATTiny85 "Invalid device signature."

I am trying to program ATTin85 using Arduino I used the hardware support file from "High-Low Tech" here   With this schematic:    After downloading the ArduinoISP sketch to the board, I tried uploading the blink sketch and tried burning the bootloader.  The IDE keeps responding with :  avrdude.exe: please define PAGEL and BS2 signals in the configuration file for part ATtiny85avrdude.exe: Yikes!  Invalid device signature.               Double check connections and try again, or use -F to override this check.   I also tried to using avrdude from CMD  avrdude -P COM5 -b 19200 -c avrisp -p t85 -v -e -U flash:w:sketch.cpp.hex   and it gave:  avrdude: please define PAGEL and BS2 signals in the configuration file for part ATtiny85 avrdude: AVR device initialized and ready to accept instructions  Reading | ################################################## | 100% 0.07s  avrdude: Device signature = 0xffffff avrdude: Yikes!  Invalid device signature.       Double check connections and try again, or use -F to override      this check.   avrdude done.  Thank you.     I tried choosing the three settings 1Mhz/8Mhz/20Mhz (without adding any oscillators) and tried the three options with a 16Mhz crystal with two 22pF capacitors (I read somewhere online that this may work)  and still nothing changed!  I tried another ATTiny85 Chip, another Arduino Uno, and tested the continuity every single wire. but still I am getting the same error.


Problem with Textmaker 4.5 + bibtex + Windows 10 + MiKTeX 2.9 "print References"?

Running the minimal example  \documentclass[12pt,twoside]{report}  \usepackage{biblatex} \addbibresource{References.bib}  \begin{document}  simple example \cite{Rn123} \addcontentsline{toc}{section}{References} \nocite{*} \printbibliography   \end{document}   where References.bib is   @article{Rn123,    author = {Rosenthal, Arnie},    title = {Computing the reliability of complex networks},    journal = {SIAM Journal on Applied Mathematics},    volume = {32},    number = {2},    pages = {384-393},    ISSN = {0036-1399},    year = {1977},    type = {Journal Article} }   I do not get any result and do not print the bibliography as in the picture   When I run the Bibtex show these errors  Note I'm using Textmaker 4.5  with MiKTeX 2.9 on Windows 10 ,   I saw a lot of lessons on Youtube and did not work with me ways to solve the problem and I saw a lot of questions here and did not find a solution.  Please help me with many thanks  this pictures of example  and textmaker option    When I use  get


I'm building a long tunnel straight down. I've hit water plenty of times, which has proven easy to redirect by simply tunneling to the sides when under the water.  But alas, I had to hit a pond of lava at some point. I had planned to make a tunnel under the lava, then place some TNT and RUN for it.  Any better suggestions?


Prove $C_m \times C_n$ is cyclic and is isomorphic to $C_{mn}$

Let $C_k$ denote a cyclic group of order $k$. Show that if $m$ and $n$ are coprime, then $C_m \times C_n$ is cyclic and is isomorphic to $C_{mn}$. Show, however, that $C_3 \times C_3$ is not isomorphic to $C_9$.   So my questions are:   What is meant by the product of two groups $C_m \times C_n$ ? How to solve this problem?


How do I access The Elder Scrolls V: Skyrim save files on Windows 8?

How can I access the Skyrim save data on Windows 8? I need to delete some saves.  I've read this question: "" - but there are no specified directories for Windows 8. (I couldn't find the save files at the mentioned directories in the current answer.)


Is every $\sigma$-algebra a Borel $\sigma$-algebra?

Let $\mathscr B$ be a $\sigma$-algebra on a set $X$. Does there always exist a topology $\tau$ on $X$ such that $\mathscr B$ is the Borel $\sigma$-algebra with respect to $\tau$, that is, $\mathscr B$ is the smallest $\sigma$-algebra containing $\tau$?  For example, let $X$ be an uncountable set and let $\mathscr B$ be the family of all sets $B\subseteq X$ such that either $B$ or $X\setminus B$ is countable. Then $\mathscr B$ is generated by a topology $\tau=\{\emptyset\}\cup\{B\subseteq X\!:\left|X\setminus B\right|\le\omega\}$.    Added: This question is actually a duplicate of the following questions:    [MSE]  [MO]    to the MO question provides references to two papers, where the problem is solved negatively. For the convenience of a reader, I try to present here a simple argument from the paper of R. Lang.  Given sets $X,Y$, let ${}^XY$ denote the family of all functions from $X$ to $Y$. Let $X={}^{\mathbb R}\{0,1\}$. For $a\in\mathbb R$, let $W_a=\{\mathbf 1_A\!:A\subseteq\mathbb R,\ a\in A\}$, where $\mathbf 1_A\in X$ denotes the characteristic function of a set $A$. Let $\mathscr B$ be the $\sigma$-algebra on $X$ generated by $\{W_a\!:a\in\mathbb R\}$. We prove that $\mathscr B$ cannot be generated by a topology on $X$.  For every $V\in\mathscr B$ there exists a countable set $C\subseteq\mathbb R$ and a set $Z\subseteq{}^C\{0,1\}$ such that $V=\{v\in X\!:v\upharpoonright C\in Z\}$. It follows that $\left|\mathscr B\right|\le 2^{\aleph_0}$. Since the family $\{W_a\!:a\in\mathbb R\}$ separates points of $X$ (that is, for every distinct $u,v\in X$ there exists $a\in\mathbb R$ such that $W_a$ contains exactly one of $u,v$), any family of sets that generates $\mathscr B$ must separate points of $X$. Hence, every topology $\tau$ that generates $\mathscr B$ must be $T_0$. But this would imply $\overline{\{u\}}\neq\overline{\{v\}}$ for all distinct $u,v\in X$, hence $\left|\tau\right|\ge\left|X\right|=2^{2^{\aleph_0}}$. That is impossible.


I have an stored procedure in MySQL Database that execute a query like "SELECT * FROM table" and return this rows.  I want to create a JSON with this information, how can i do that? This is my code: Main <?php   include "config.php";  include "utils.php";   $dbConn =  connect($db);   if ($_SERVER['REQUEST_METHOD'] == 'GET'){     $sth = $dbConn->prepare("CALL consulta_administrador()");    $sth->execute();     $result = $sth->fetchAll();    var_dump($result);    echo json_encode($result); }  ?>  config.php <?php    $db = [   'host' => 'myDBHost',   'username' => 'myUsername',   'password' => 'myPassword',   'db' => 'myDB'    ];  ?>  utils.php <?php  function connect($db) {   try {       $conn = new PDO("mysql:host={$db['host']};dbname={$db['db']}", $db['username'], $db['password']);       $conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);              return $conn;   } catch (PDOException $exception) {       echo "Error:" , $exception->getMessage(), '<br>';       die();   } } ?>


Should an image carousel on a mobile site automatically rotate?

Or should the user have complete control? The intention is to have a slider/carousel that shows 6 or 7 images which the user can look through by clicking arrow buttons left or right. But the question has also come up if the user has not started looking through the images, should the carousel start automatically rotating the images. Since this is for a mobile site, I'm uncertain...


How can I increase FPS in games (Minecraft, various Steam games) on my low-mid end computer? Specs below

Specs:     Intel Core i7-6500U @ 2.50GHz x 4     HP ENVY Notebook     16384MB RAM     Display: Intel HD Graphics 520     Render: NVIDIA GeForce GTX 940M     Windows 10 Pro version 1909  (I typed that out from dxdiag without using the save all info button) It seems that my computer has sufficient hardware, but I need to clean up files that slow down my computer and I don't know which ones. I have already run Disk Cleanup and Optimize Drives. Let me know if you need any more specs. I normally get 20-30 fps. This question has been flagged as a possible duplicate of , so here's why not:  OptiFine (Minecraft Forum Link) reworks a number of rendering details to improve Minecraft performance (+20fps). Many people go crazy about it on the forum, others say that it just doesn't work so YMMV.  I have already installed OptiFine and tried other mods such as Sodium.  Within the options menu (Esc -> Options), set Graphics to Fast and set Render Distance to Tiny.  I have done this and saw a small performance increase. (~10 fps)  Close any programs you can spare to lose (ie internet browser, messenger, music). If you're really desperate, you can open your task manager (Ctrl + Alt + Delete -> Start Task Manager) and select the "Processes" tab. Order by "Memory" and have a look at what's taking up so much processing power on your computer (Minecraft will be listed as javaw.exe). Use the End Process button to stop a selected process.  I use Razer Cortex for this and it does a pretty good job.  Change Minecraft's processing priority.  This actually doesn't affect my FPS in any way.  If all else fails, you might have to upgrade your computer. You can get plenty of cheap, new choices at Amazon.com.  Yes, thinking of trying this. All other answers to the question were out of date. I would like to get some new answers to this issue on Arqade! Could you also extend help to software like Unity or Blender? Thanks in advance.


I want to insert a figure into a column, which means a figure uses 0.5*paper width.And the paper are written in two columns. At the same time, I need to use \bicaption{}{},which is in bicaption package, to create two captions for one figure.  \usepackage{caption} \usepackage{multicol} \usepackage{bicaption} \begin{document} xxxx...... \begin{multicols}{2} \begin{figure} \includegraphics{figure A} \end{figure} \end{multicols} \end{document}  The problem is,in this case, the figure can not display in a pdf document.  Note, I want to write a paper in one column at the title, and in two column at the text. The text begins at the title page. For example, Thank you very much!


If $a\operatorname{Re}(f(z))+b\operatorname{Im}(f(z))=c$ then f is constant

Let $A$ be an open connected subset of $\mathbb C$ and $f:A\to B$ analytic. Suppose there exist reals constants $a$, $b$ and $c$ such that $a^2+b^2\neq 0$ and $a\operatorname{Re}\bigl(f(z)\bigr)+b\operatorname{Im}\bigl(f(z)\bigr)=c$ for all $z \in \mathbb C$. Prove $f$ is constant.  Proof: as f is analytic then cauchy-riemann equations holds.  I computed the partial derivatives of $a\operatorname{Re}\bigl(f(z)\bigr)+b\operatorname{Im}\bigl(f(z)\bigr)=c$ with respect to $x$ and $y$ and tried to make a relation with the cauchy equations but things become complicated, because I got this:  $a\frac{\partial u}{\partial x}=a\frac{\partial v}{\partial y}=-b\frac{\partial v}{\partial x}=b\frac{\partial u}{\partial y}$ and I don't know how to get the result.


What is the purpose of using a very dark color for text instead of a pure black?

I have seen that some web designs implement an almost black font color (hex #001c00) in their designs instead of a pure black color (hex #000).   Does the design actually benefit from this or is this practically the same as using a black color?   I am a hobbyist web designer and developer and can't seem to grasp the difference.


Is the phrase 'one pair of' considered a singular noun or a plural noun?

Which is correct, "One pair of eagles build a nest." or, "One pair of eagles builds a nest."?


Does Stack Exchange report on the numbers of requests and orders it receives from law enforcement agencies?

Does Stack Exchange report on the numbers of requests and orders it receives from law enforcement agencies, as , , ,  and  do?


How to assign class method to class attribute?

I'm trying to assign class methods to class attribute, so I can call the methods from string. When using the class I want to call it from string like:  A.MAP['add'](x, y) A.MAP['subtract'](x, y)   This is my current code:  class A:     MAP = {         'add' : A.add(x, y),         'subtract' : A.subtract(x, y),     }      @classmethod     def add(cls, x, y)         return x + y      @classmethod     def subtract(cls, x, y)         return x - y   However the result shown error that A is not defined at the line of assigning A.add to MAP['add']. For short functions I can use lambda. However, in case of a longer function, how can I achieve this design?


Tor browser setup fails on Lubuntu 17.0.1

I've downloaded Tor Browser Bundle from  and extracted it to /home.  When I cd to tor-browser_en-US$ start-tor-browser and run start-tor-browser I get   command not found   I can see the file start-tor-browser.desktop is in the directory. If I double-click the file in File Manager I get a spinning tooltip for a few seconds and then nothing.  I've tried changing the Permissions property Execute to Anyone. I've deleted and re-downloaded the TBB. I also tried sudo chmod +x start-tor-browser, but this also gave me   No such file or directory   I've noticed tab autocomplete also doesn't pick up the file. It's as if my system can't see it.


How are the definitions of a coherent state equivalent?

I am trying to understand . As far as I could find there are three equivalent definitions and in general many sources start from a different one, still I fail to see their equivalence. I restate the definitions and their equivalences given in the Wikipedia page:   Eigenstate of annihilation operator: $$a|\alpha \rangle =\alpha|\alpha \rangle$$ Displacement operator of the vacuum: $$ |\alpha \rangle =e^{\alpha a^{\dagger}-\alpha^{*} a}|0 \rangle $$ State of minimal Uncertainty: $$ \Delta X= \Delta P = \frac{1}{\sqrt{2}} $$   I fail to see how they are the same! Can someone please explain how to derive these from one another?


The number of ways of writing an integer as a sum of two squares

Given an integer $m=pq$, where $p,q$ are both primes such that $p\equiv 1 \pmod{4}, q\equiv 1 \pmod{4}$. It is known that $p$ can be written as a sum of two squares (of positive integers) in a unique way, and the same for $q$. Prove that $m$ can be written as a sum of two squares (of positive integers) in exactly two distinct ways.  Attempt  Notice that for positive integers $u,v,A,B$, we have \begin{align*}(u^2+v^2)(A^2+B^2)&=(uA+vB)^2+(vA-uB)^2=(vA+uB)^2+(uA-vB)^2\end{align*} Therefore if $p=a^2+b^2,q=c^2+d^2$, then \begin{align*}m&=(a^2+b^2)(c^2+d^2)=(ac+bd)^2+(bc-ad)^2=(bc+ad)^2+(ac-bd)^2\end{align*} meaning that $m$ can be written as a sum of two squares (of positive integers) in at least two distinct ways.  How do I prove that there doesn't exist a third way of writing $m$ as a sum of two squares (of positive integers)?


Can it be proved that all mathematical statements can be proved true or false?

Given a mathematical statement, can it be always be proven to be correct or incorrect, or is it possible that a proof can not be created?  Could all cases that could not be proven, be proven that no proof exists also? For example, with the Beal Conjecture, is it guaranteed that a proof exists, or could no such proof exist? I am thinking that some proofs could not exist such as problems that could take longer than the life of the universe to solve.  For example, proving that a hashed value equals a given number.


What are the pros and cons between an aluminium and carbon frame?

I'm after a mountain bike and I've narrowed it down to the  (based on reviews, plus I like the look of the bike).  My question is, should I go for the  or the alloy bike?  I'm 6'4" and weigh about 125kg; I know carbon is very strong but I've heard when it goes, it just snaps (rather than alloy that bends).    Do you think this is a valid concern?    What are the pros and cons of each?


How to draw a pie chart open in the middle?

I am wondering, how I can draw the Pie diagram as is shown on page 50 of the TikZ manual here ? It's a 2D pie chart that is opened in the middle. Here is a snapshot of it:


Are static class variables possible in Python?

Is it possible to have static class variables or methods in Python? What syntax is required to do this?


Currently, if content is disputed on a per-site Meta, the message is.     This post has been locked while disputes about its content are being resolved. For more info visit meta.   ...with a link to that site's Meta.  Well, I'm already on Meta. Can this be changed? Or is this ?


How would I carry out the following integration? $$\int_0^12\arctan x^2$$  I tried to substitute $x^2 = \tan\theta$ From there I wrote the integral as: $$\int_0^{\pi/4}\theta\cdot \frac{\sec^2\theta}{\sqrt{\tan\theta}}\ d\theta$$  Now, is my only option to use integration by parts? Or is there a better method to solve this integral?


Why am I getting "No such file or directory" when I try to execute a binary?

I'm trying to execute the firefox binary:   root@454316a1a89a:/tmp/firefox-portable# ls -la total 220 drwxr-xr-x  4 jenkins jenkins   4096 Mar 18 21:15 . drwxrwxrwt  1 root    root      4096 Mar 18 21:48 .. -rwxr-xr-x  1 jenkins jenkins 202720 Feb 21 17:47 firefox   but when I try to execute it, I get the following error message:   root@454316a1a89a:/tmp/firefox-portable# ./firefox bash: ./firefox: No such file or directory


I have a query that runs fine, when I try to add one more column to where clouses it cannot find the column and gives an error.  SELECT '1' AS `row_count`, (     SELECT          COUNT(*)      FROM          `attendances`      WHERE `program_sessions`.`id` = `attendances`.`program_session_id`      AND `attendances`.`deleted_at` IS NULL ) AS `attendances_count` FROM     `program_sessions` LEFT JOIN `programs` ON `programs`.`id` = `program_sessions`.`program_id` LEFT JOIN `program_categories` ON `program_categories`.`id` = `programs`.`program_category_id` LEFT JOIN `service_areas` ON `service_areas`.`id` = `program_categories`.`service_area_id` LEFT JOIN `locations` ON `locations`.`id` = `programs`.`location_id` WHERE (     LOWER(`program_categories`.`name`) LIKE "%3%" OR      LOWER(`programs`.`name`) LIKE "%3%" OR      LOWER(`locations`.`name`) LIKE "%3%" OR     (attendances_count = 3) OR      LOWER(`service_areas`.`name`) LIKE "%3%" )  AND `program_sessions`.`deleted_at` IS NULL   MySQL said: #1054 - Unknown column 'attendances_count' in 'where clause'  The query somehow cannot reach the attendances_count. What is it that I am doing wrong?


If 2 people are concentrating on different crusader's mantle and standing within the radius does the effect stack with another crusader's mantle causing 2d4 instead 1d4?


My 3D Cursor follows my selection cursor everywhere I click. How do I stop this?

This happens to me every now and then in different projects and I never know what causes it. Anywhere I click, my 3D Cursor and Selection Cursor both move to that point and I cannot separate the two. How do I fix this?


i am asking if i can install .exe (GTA IV) on my ubuntu from 2  DVD ( using wine ), does it require any other programs ? Thanks.


Prove convergence of the sequence $(z_1+z_2+\cdots + z_n)/n$ of Cesaro means

Prove that if $\lim_{n \to \infty}z_{n}=A$ then:  $$\lim_{n \to \infty}\frac{z_{1}+z_{2}+\cdots + z_{n}}{n}=A$$ I was thinking spliting it in: $$(z_{1}+z_{2}+\cdots+z_{N-1})+(z_{N}+z_{N+1}+\cdots+z_{n})$$ where $N$ is value of $n$ for which $|A-z_{n}|<\epsilon$ then taking the limit of this sum devided by $n$ , and noting that the second sum is as close as you wish to $nA$ while the first is as close as you wish to $0$. Not sure if this helps....


How to Convert content in Web browser control to pdf file in windows forms using vb.net

I need help from you guys I will explain briefly where I am struggling. I am developing a windows application using VB.Net. So, I have a windows form called - "XT" in that "XT" form I have a web browser control and a button. While loading the form is navigating to a website. Let us assume the site is STACK OVERFLOW. Now web browser is navigated to the given site and displayed in the web browser control. When I click on a button in XT form, The content displayed in the web browser control should be exactly converted to a pdf file and should save in our local disk. ADVANCE VERY VERY THANKS... this will be a breakthrough if I get a solution to make my application move forward


Why does the RTX IO in the Nvidia GeForce RTX 30 Series use any CPU at all even though the information flow from the storage to the GPU?

I saw in the  that the RTX IO in the  allows the GPU to directly access the storage (SSD) without having to go through the CPU, as shown in the flowcharts below. In the Nvidia GeForce RTX 20 Series and before, the information from the storage goes through the CPU before reaching the GPU (flowchart from the Official Launch Event linked above):  In the Nvidia GeForce RTX 30 Series, the information goes straight from the storage to the GPU:  How ever I see on the same slide "20x lower CPU utilization":  Why does the RTX IO in the Nvidia GeForce RTX 30 Series use any CPU at all when information flow from the storage to the GPU, since according to the flowchart the information goes straight from the storage to the GPU?


What does sudo apt-get install curl command do? Why does it require the password?

I tried installing PlayOnLinux by using the steps according to a YouTube video, , and used the command  sudo apt-get install curl   Then it requested my password which I entered.   Can anyone please explain what this command line does?


How can one link directly to a specific page of a PDF in Google Drive?

I'd like to provide a link to a PDF document in Google Drive like [documenturl]?page=4 and have that link jump to the specified page.  With a quick search, I was only able to find this unresolved forum question:


Apex: Setting Properties with the Indexing Notation

Is it possible to set a property on an instance of a class like so;  MyCls item = new MyCls();  item['propName'] = propValue;


Click function for generated element in JQuery

I have a delete button. When clicking on the button, I want to generate a second button to confirm that the user really wants to delete something. BUT: When clicking on the second button, the $('.deleteConfirmed').click(function() { does not trigger.  I'm not exactly sure how JQuery works, but my guess is that this happens because the click listener was created before the second button existed, correct? If that is true, what would be a solution to make clicking the second button call deleteEntityConfirmed(id)?  I guess you could probably do it with HTML's onclick attribute on the second button, but does JQuery offer a more elegant solution for this scenario?  Here is some code showing my scenario, I tried to keep only relevant parts in.  HTML:  <button class="delete" data-id="5">   Delete </button>

   JS:  $(function() {   $('.delete').click(function() {     var id = $(this).data('id');     $('#somewhere').empty().append('<button class="deleteConfirmed" data-id="' + id + '">I\'m sure I want to delete</button>');   });     $('.deleteConfirmed').click(function() {     alert("debug message"); // we don't get here when clicking the second button. It seems to not be listening to it     var id = $(this).data('id');     deleteEntityConfirmed(id);   });  });  function deleteEntityConfirmed(id){     // If we'd get here after clicking the second button, this would be full success     alert("Deleting id " + id); }


Is it possible to add disc brakes to a bike with caliper brakes?

I have a Felt Z80 road bike like the one pictured below. Would it be possible to add disc brakes instead of the caliper brakes it came with? I don't plan on getting a new bike for awhile so I thought this would be a beneficial upgrade because I ride in the rain from time to time.    I suppose my other question would be, if it is possible, would it be worth it?


I have wondered several times about this and now seeing this question  I decided to ask:  In general in our mind we think of flights number as something unique (at least I did). An ID. Often journalists mention the flight number when they want to refer to a particular event (a crash, a forced landing, whatever) which reinforces the idea of uniqueness.  From what I read a flight number:   clearly does not represent a plane does not represent a unique flight in particular (since the same flight number is commonly reused several times to represent the same flight at the same time in different days) does not represent a route (since the flight number can be used on several routes)   What is its use than and does it represent? What makes it unique and usable? can there be, for instance, the same flight number at the same time in different routes?


KDM Login Will Not Accept Username & Password

I have just installed KDE , set up my preferred environment (with desktop cube effects color scheme, set the splash screen to "minimalist" and also installed ksnapshot.) Installation was done with the terminal,  sudo apt-get install kde-desktop   Everything seemed to be working fine (actually pretty stellar.) Then I did a reboot to make sure all my changes could settle-in properly. When I got back to the login screen, which is the KDM login screen I selected in the setup process, however, there seems to be no user account for me (or anyone else for that matter.) If I click "switch user," my only option is something that says, "Unused (:0, vt8)" which is already selected. If I type in my previous username and password, it won't recognize it and acts as though I've typed in error.  While I cannot login, I do seem to have other options. The blue down-arrow gives me options of which desktop to use.      options are    "Defualt,"  "KDE Plasma Workspace,"  "KDE Plasma Workspace (failsafe session),"  "Ubuntu," and  "Failsafe."   The red "shutdown" button on the screen gives me the options,    "Switch User,"  "Restart X Server,"  "remote Login,"  "Console Login," and  "Shutdown."    Would someone please help me get it functioning again?It seems this has happened before.    This person closed their thread before there were any responses, so I wasn't able to post that I'm having the same issue. The "long-story short" version of this is, KDM won't accept (or seem to recognize the existence of) my username or password, or any other, and I cannot switch to another login manager to try that because that would require that it accept my credentials first. If it helps to know, before my reboot and subsequently getting stuck at KDM, LightDM logged me into KDE just fine.


primitives int not accepted in Generic types java

Im trying to defined a generic LinkedList of type int but it throws me a compile errror  List<int> I = new LinkedList<int>();


How to remotely find out a linux hostname without the use of DNS?

If I want to find out how the hostname of a remote linux machine on my LAN is, how can I achieve this given I don't have access via SSH etc.?  Probably depends if linux is part of a WINS domain I suppose.


Are there any micro-controllers which support writing data to large sized SATA disks?


How to export Environment variables to a text file

I want to have a look into my Environment variables as a text file into XP Professional. Is there any way?


Why does this line of code in Python 3 prints False of 1 is an int??? Tanks

Why does this print False in Python 3  >>> 1 == int False   Thanks for your help!!!!


What "and \\" is doing in this code snippet

Can someone please tell me what "and \" is doing for v in range(n):     if matrix[min_dis_v][v] > 0 and \         not done[v] and \         distance[v] > distance[min_dis_v] + matrix[min_dis_v][v]:     distance[v] = distance[min_dis_v] + matrix[min_dis_v][v]


How to return results of SQL query to Excel sheet with VBA function

I'm trying to create a VBA function in Excel to affect dynamic value from Access to Excel sheet. This is my code.  Public Function SQL(DB As String, Query As String)     Dim conn As ADODB.Connection     Set conn = New ADODB.Connection     conn.Open "Provider=Microsoft.ACE.OLEDB.12.0; Data Source=" & DB     SQL = conn.Execute Query End Function   Then I should write on my cell  =SQL("file.accdb", "SELECT Count(*) FROM Table")   The value returned is #VALUE!, but if I change the code to SQL = 1 + 2, then the value is 3.  I believe this means the issue is with conn.Execute Query.


i will start a new hosting company but i dont know what hardware will be the best for this. I'm looking for something cheap and can carry about 200-300 hosting accounts. The server will be using for web, mail and hosting server.   QUAD CORE AMD BULLDOZER FX-4130 3.9GHZ 1TB HDD 8GB DDR3 RAM USB 3.0 HDMI, VGA,DVI  Is this hardware is good for about 300 pounds and can this work for me?  Thanks!


Where should imports be in Django's views.py?

With respect to least runtime on web app, what is the ideal place to keep my imports in views.py  Say I want to validate and process some form entries with external modules. My current code:  from django.shortcuts import render  from .forms import *  import re import module1 import module2  def index(request):     form = MyForm()     if request.method == 'POST':         form = MyForm(request.POST)          if form.is_valid():             #             #Process my stuff here using re, module1, module2             #  return render(request, 'index.html', context)   But what good is it doing by importing module re, module1, module 2 before hand if condition if form.is_valid(): failed? Or condition if request.method == 'POST': fails? That is when the form was never submitted.  Would importing these modules after these conditions are passed (because thats when they are actually needed) cause any less runtime overhead on program or webapp when these conditions fail? avoiding unnecessary imports when they are not needed?  Psuedo code of my idea:  if form.is_valid():     import re     #Perform some regex matches and stuff     if (above re matches succeed):         import module1         #Process my stuff here using module1 here         #and so on importing modules only when they are required   Which one of these is recommended and would have best performance on the website?


Unable to access my other partition (volume)

Initially I was running Windows OS which had three partitions: C, D and E. I then installed Ubuntu 16.04 in 'C' (formatting it and wiping out windows). Now in my Ubuntu when I try to access my E drive I get this error:  Error mounting /dev/sda3 at /media/cyan/F428D28228D24372: Command-line `mount -t "ntfs" -o "uhelper=udisks2,nodev,nosuid,uid=1000,gid=1000" "/dev/sda3" "/media/cyan/F428D28228D24372"' exited with non-zero exit status 14: The disk contains an unclean file system (0, 0). Metadata kept in Windows cache, refused to mount. Failed to mount '/dev/sda3': Operation not permitted The NTFS partition is in an unsafe state. Please resume and shutdown Windows fully (no hibernation or fast restarting), or mount the volume read-only with the 'ro' mount option.   Please help me to retrieve my files. I have valuable information which I don't want to lose. 'c' 'D' and 'E' are partition of internal drive not external  i have no dual boot i am left with only one 'OS' that is ubuntu in 'C' drive.


How to rename files in a directory such as the following file: PMC21375.pdf.txt, I need to be renamed to  21375.txt. i.e, I need to remove both PMC and pdf from each file name.


Which of these sentences is correct?     It is he I relate to most of all.   Or,     It is him I relate to most of all.   I believe that in neither of the two sentences do the words "him" or "he" act as a relative pronoun, for the simple reason that they are not relative pronouns. Instead, both sentences have an implicit relative pronoun. The case of he/him should depend on other considerations, such as, the proper case after the linking verb, "is".  It should be simply a matter of which is more correct,     It is he   Or,     It is him   My Latin education would have me pick the former. But my knowledge of colloquial English tells me that the phrase, "it was him", is commonly used. Thus, I do not know. I hope these words help explain my reasoning, without making my reader more confused. I would be interested to know what you grammar gurus think of my first two sentences. Which is correct?


Please, if I say four-wheel-drive, can I say two-third share? Thank you


Using Windows OEM License key on another Laptop

I have an older Toshiba R-800 laptop that's dying. Before I dispose the laptop, I want to recover the Windows License key. This laptop was given to me at my previous workplace and at some point, they might have replaced the OEM windows installation with an installation of Windows Enterprise (I think?). I'm not entirely sure.  I now have a refurbished laptop (Lenovo Thinkpad) that I purchased 2nd hand. This has Windows 7 Pro. The copy of Windows on the Lenovo was a "trial" version (I'm not entirely sure) and that trial has expired. I keep receiving the error that  this copy of Windows might not be genuine and needs activation. I'd like to activate it using the license key of the Toshiba. I tried entering the serial number that's on the back of the laptop on a sticker but that does not work.  I'm not sure if I'm doing something wrong, or this is not allowed or perhaps I'm entering the license key incorrectly (The sticker is slightly worn out).  Any idea on how I can use the earlier license on the lenovo laptop?  Edit: I've updated the title to add clarity to my question and also make it clearer on what I'm trying to achieve. The request never has been merely to retrieve the Windows License Key


What is the meaning of the " 's " in this sentence?

I'm currently studying to pass the TOEFL test with a high score, but I have encountered a sentence in an app that I fail to see why it is correct: "The committee members resented the president's not informing them of the meeting." Can someone explain to me how the mentioned sentence works?


I am looking to buy either of the following two laptops but wanted to ensure they were compatible with Ubuntu. Both seem to match laptop names as 'okay' but the details of the specs seem to be slightly different, which leaves me confused!   HPM6-1205SO/i5/8GB (HP Envy M6 ??)  HP15-J028EO/i5/12G (HP Envy 15 ??)   Your help much appreciated.  Many thanks, Melanie


Does this series converge absolutely: $\sum\limits_{n=1}^{\infty} \frac{\cos n}{n}$?

$$\sum_{n=1}^{\infty} \frac{\cos n}{n}$$ I know that this series converges (from Dirichlet test) but I can't figure if it converges absolutely or not, obviously ratio and root test won't work, limit comparison test seems to fail as well.


In Apex, how can I format Datetime for Europe/Berlin without assuming the input value is GMT?

I currently have the following function: public String formatForGermany(Datetime targetTime) {     return this.format(targetTime, 'Europe/Berlin'); }  private String format(Datetime targetTime, String zone) {     Integer offset = TimeZone.getTimeZone(zone)             .getOffset(targetTime);     return targetTime.addSeconds(offset / 1000)             .format('HH:mm'); }  This works fine the input value is GMT. However, it seems in some contexts (TBD), Salesforce seems to anticipate this transformation is wanted and does it for me, in which case the offset gets applied twice, with the result that I display (for example) 14:00 instead of 12:00. Is there some way I can check whether the time has already been offset and either not apply it or adjust the offset accordingly?


How to use Windows 8.1 RTM with 8.0 key?

Is it possible to use the Windows 8.1 RTM Build from MSDN with an existing Windows 8.0 key?  I updated my laptop using one of our MSDN keys, and thought it would be possible to change back to the 8.0 key in the system control. But when I tried to change the key back to Windows 8.0, Windows rejected the key.  The Windows 8.0 key is an upgrade key, maybe this is relevant.


Can you write and solve the EM field Lagrangian density without reference to the EM potential?

Is it possible to write the Lagrangian density for the EM field and charges $$L=-\frac{1}{4\mu_0}F^{\mu \nu}F_{\mu \nu}+j^{\mu}A_{\mu}$$ only in terms of the Electromagnetic Tensor and current vector? Can you also solve the Euler-Lagrange equation without reference to the potential? For example, witht the Lagrangian density for empty space: $$L=-\frac{1}{4\mu_0}F^{\mu \nu}F_{\mu \nu}$$ There are no derivatives of $F^{\mu \nu}$, so I don't see how you could derive the field equations from it.


Color panel in the properties section is changed

I was using blender and might've accidently pressed some keys and so when I go to my section to add color it is not at the original perspective that I want it to be. I need this back because it gives me like 3 options for color and none of them add nodes to my node editor. please help.   How do I change it from this perspective    Back to this?


Electrical flow in a simple parallel circuit

I'm having trouble understanding something in one of my text books:     Let’s have a look at the implications of each circuit configuration.   Figure 3.13 shows the Conventional representation of a parallel   circuit. If you assume that the resistance of the wires can be   neglected, then the voltage drop across each bulb is equal to the   e.m.f. of the source, the dynamo. The Current flowing from the source   is divided between each bulb depending on its resistance (remember I =   E/R), Removing one of the bulbs would not affect the voltage drop   across the other bulb and would therefore not affect the Current in   it, although the overall Current from the dynamo would drop as the   demand has been reduced.   Specifically, the line about removing one of the bulbs not affecting the voltage drop. My understanding is that the sum of voltage drops in a circuit must be equal to the output of the emf, but the way I'm reading the text suggests that if you have three bulbs in a parallel circuit and you remove one of them, the voltage drop remains the same - this is what I don't understand, though. If you a lamp is removed, then that's one less lamp consuming emf. Does it not get redistributed to the other two lamps?  Likewise, the text mentions the overall current from the dynamo dropping because demand has been reduced.  My initial understanding was that current from an emf is only affected by the emf - not the demands of components further along the circuit, as in this case. What have I misunderstood?


This question has been  before in 2010, but I am sure many of us would like to see an official app to use Stack Overflow, which allows interaction (votes, reviews, etc) instead of just reading questions.   Are there any plans to build an official app, or is the intent to use the mobile versions of the sites?


I'm trying to run a exe file that is located on my Vista partition, when I browse to the file and try to change the file to run as executable the tick box unticks itself right after i tick it, i tried running gksu nautilus but it does the same thing


Everything after a Greek letter is empty in my database

I'm encountering what I'm sure is an encoding error but I can't seem to find the weak link in my logic.  In particular, when trying to insert a Greek lambda into my database, the cell is blank after the lambda.  The process:  Before any html is printed, I'm doing:  header('Content-Type: text/html; charset=utf-8');   Next, I'm connecting using PDO:  $dsn = 'mysql:host=' . $config['host'] . ';dbname=' . $config['dbname'] . ';charset=utf8';  $options = array(             PDO::ATTR_EMULATE_PREPARES => false,              PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION         );         try {             $dbh = new PDO($dsn, $config['username'], $config['password'], $options);             $dbh->exec("SET NAMES utf8");             $dbh->exec("SET FOREIGN_KEY_CHECKS = 1");   When I do      SHOW FULL COLUMNS FROM my_table   I can see that the collation is utf8_general_ci. When I do:     echo mb_detect_encoding($data_to_be_entered);   I get UTF-8  When I echo out $data_to_be_entered into the console right before I insert it into the database, I see: (𝜆=23)  However, in my database, I just see ( as the entry.


Construct a closed, uncountable, perfect, nowhere dense subset of $[0,1]$ which has Lebesgue measure $\frac{1}{2}$.  (Hint: Find the Cantor subset of $[0, 1]$ with Lebesgue measure $\frac{1}{2}$)


OLS estimator for regression without intercept

Consider a linear regression model: $Y_i = \beta_1 A_i + \beta_2 B_i + u_i$ where all variables are assumed to have mean 0, and $A_{i}$ is distributed independently of both $B_{i}$ and $u_{i}$, but $B_{i}$ and $u_{i}$ might be correlated.   I want to show that the OLS estimator $\widehat{\beta}_1$ is consistent but $\widehat{\beta}_2$ might not be due to the correlation. So I'm deducing the formula for the OLS estimators and this is what I got: $$\widehat{\beta}_1 = \left(\sum A_i A_i'\right)^{-1} \left(\sum A_iY_i\right)$$ and $$\widehat{\beta}_2 = \left(\sum B_i B_i'\right)^{-1} \left(\sum B_i Y_i \right).$$ Is this formula correct? Can any one give me some hint on the problem?  Any help is appreciated, thanks in advance!


which apps are these!! we stay in brazil

I want to know the name of these apps .. i want to track my sister.. she doesnt let me touch her phone.. i just want to know the name of these apps....   i want to know the name of the apps.. the 3 notifications indicates the app..   i searched it but i couldnt find.. i hope if anybody can tell me.. we stay in brazil.. so the app might be common to brazilian


Calculate the number $o(\mathbb{R})$ of open subsets of the real line.  I know that the answer is $\mathfrak{c}$ but I don't know how my lecturer got this.  I am doing an introductory topology course, so I know a few topological concepts. Such as that the set of all open intervals forms a base for the real numbers. Is this somehow relevant in showing that  $o(\mathbb{R}) = \mathfrak{c}$?


How can I limit the days returned in the date module to today's and future dates only?

I have the Date module installed on Drupal 7 (version 7.x-2.5) and I am attempting to disable the selection of past dates within the date popup.  $form['ratesDateSelect'] = array(     '#title' => 'Arrival Date',     '#type' => 'date_popup',     '#default_value' => '',     '#size' => 21,     '#maxlength' => 100,     '#date_flexible' => 0,     '#date_year_range' => (date('Y')) . ':+5',     '#attributes' => array('autocomplete' =>'off','readonly' => 'readonly'),     '#description' => '',     '#value' => array('date' => $date),     '#date_format' => 'D d M Y',     '#required' => FALSE, );   I have limited the popup to return this year and five years into the future, but I also need to restrict it so that people cannot select past days.  I have managed to do this in another project using pure javascript, using the datepicker param: minDate: 0


How to decode a hex byte defined as string?

I read a printed byte in a file, as a string:  a = "b'\xa0-\xfc\xa3\xf8\xd9'"    type(a) is str.  How should I decode it?  The decoded value should be a02dfca3f8d9.  A part the file is uploaded here:   [PICA8-P3297] dl-dst output #1 OFPFlowMod(actions=[OFPActionOutput(max_len=65509,port=45)],buffer_id=4294967295,command=0,cookie=16895774056056650001,flags=0,hard_timeout=0,idle_timeout=0,match=OFPMatch(dl_dst=b'\xa0-\xfc\xa3\xf8\xd9',dl_src=b'\x00\x00\x00\x00\x00\x00',dl_type=0,dl_vlan=0,dl_vlan_pcp=0,in_port=0,nw_dst=0,nw_proto=0,nw_src=0,nw_tos=0,tp_dst=0,tp_src=0,wildcards=4194295),out_port=65535,priority=1)   I open and get the dl_dst value in the file by this line:  dl_dst = fm_line.split('OFPMatch')[1].split(',')[0].split('=')[1]   dl_dst is supposed to be a Mac Address. My question is how to convert it?  As suggested, I tried:  print(''.join(["{0:x}".format(ord(char)) for char in dl_dst[2:-1]]))   But the printed resuls is 275c5c7861302d5c5c7866635c5c7861335c5c7866385c5c78643927, which is not what I expected.


forgot to turn on crock pot for less than 2 hours

I left a pork roast in my crock pot for a little less than 2 hours, but forgot to turn crock pot on.  It still felt cool to the touch.  Is it safe to eat?


Hyperlinks are not visible in the generated PDF CV

Don't know if it's intentional or not, but hyperlinks are colored like a normal text in the generated PDF on careers.stackoverflow.com, which makes them indistinguishable.


why does loop-cut-and-slide ignore some faces but not others?

why does the loop-cut-and-slide operation ignore certain faces but happily cut others?the model is symmetrical so it is a bit strange to pick 3 faces that won't get cut. I tried applying it to see if it was just a graphics glitch causing the purple line to not display over everything, but it did end up cutting only what the line was selecting, instead of the whole mesh.    as requested,here's a paste of the blend:


Protect Jar file source code with exe file (Java)

How would I make a .JAR file open up when I make another file as .EXE?  I have tried many things, but they don't work.  I want this for another way to protect my source code. Kind of like what Minecraft does. You open a .EXE, and somehow the .EXE opens up the .JAR file.  Anyone have any ideas?


The following packages have unmet dependencies:  gstreamer1.0-libav: Depends: libavcodec-extra-54 (>= 6:9.13) but 6:9.18-0ubuntu0.14.04.1 is to be installed                     Depends: libavformat54 (>= 6:9.1-1) but 6:9.18-0ubuntu0.14.04.1 is to be installed                     Depends: libavutil52 (>= 6:9.1-1) but 6:9.18-0ubuntu0.14.04.1 is to be installed                     Depends: libc6 (>= 2.14) but 2.19-0ubuntu6.9 is to be installed                     Depends: libglib2.0-0 (>= 2.37.3) but 2.40.2-0ubuntu1 is to be installed


The initial default version of the tag wiki excerpt is not shown on the tags page

When looking at the tags on , I've noticed that many tags do not have the tag-excerpt. To my surprise, after I clicked on some of them I found out that they have a tag-info. (In fact, it is also displayed in the tooltip also on the tag-page.) When hovering over "history" link in the tag-info, I get a tooltip saying "This is the default initial version."  It seems that for some tags the tag-info is automatically created when a new meta site is created. (The only ones I found were the mandatory tags and moderator-only tags - see also: .)   Is this behavior intentional? I think tag-excerpt for these tags should be displayed in the same way as the tag-excerpts for other tags are.  Here is a screenshot of what I see on :    Here is what I see when I check :    And here is :


Why do professors take on service duties?

Why do professors take on service duties, such as reviewing papers for a journal, or sitting on university committees?  What benefit does this have to their careers?  I can't imagine they enjoy reviewing papers, at least not more than all the other things they need to fit into their busy schedule.


I have Debian. I want to run Windows on the same hard drive, but in separate partitions. I don't want to start my computer "DualBoot" (DualBoot is causing problems for the computer). what should I do? Can I press a button (choose Windows partition) at boot and enter Windows?


I am designing a dashboard that contains a number of modules bubbling up information from different parts of the product. One section is showcasing different people. I want to provide a tab-based way of viewing different types of people (e.g. Highly Ranked, Bookmarked, Most Recent, Dormant) with a particular module but realize that at certain points there won't be any data for that particular tab.  Is it a best practice to hide the entire tab until data exists? Or should it be visible but greyed out? Or should it be clickable but have a message saying something like 'No content avaialble'?  Below is a screenshot of the wireframe (with the tabs disabled)


Are Taylor series and power series the same "thing"?

I was just wondering in the lingo of Mathematics, are these two "ideas" the same? I know we have Taylor series, and their specialisation the Maclaurin series, but are power series a more general concept? How does either/all of these ideas relate to generating functions?


How can I open my Downloads folder in one click? Downloads are my most important folder because that's where the new files go. Yet, it is the only folder I can't make an alias for, meaning I can open it in a single click from my dock or home screen. What success looks like: Opening the Downloads folder in one click (A keyboard shortcut would be fine too). Here's what hasn't been working:  Using spotlight to search for my Downloads (slow) -right clicking Downloads in my dock and then opening the folder from there (2 clicks)  Since I open my Downloads folder so many times per day, I really want a way to open it in one click. Note: Somebody already came up with a neat solution , but it unfortunately brings ALL finder windows that might be open to the front, which is not really wanted behavior.


What is another word for a person who likes to talk too much. I was thinking bigmouth, but bigmouth could mean "somebody who likes carrying messages voluntarily".


The composition of non-linear entire functions with no fixed points has infinitely many fixed points.

The entire [non-linear] functions $f$ and $g$ do not have fixed points. Show that $f \circ g$ has infinitely many fixed points.   How do you prove this statement? Or if it is not true as stated, what additional hypothesis do we need to add to make it appropriate to call proving this statement an exercise?    This is from Problems in Mathematical Analysis by Biler and Witkowski, Exercise 7.73 on page 86 (). As stated, the exercise did not require $f$ and $g$ to be non-linear, but we clearly need that. And seeing the statement of a similar conjecture , I'm hoping that non-linearity is the only other necessary hypothesis.


I have a question on Super User that was closed as an exact duplicate. In my opinion this is in error, the other question is similar in that they both revolve around the presence or lack of the same feature however the two questions approach the feature from distinct use cases. At present the answer to the two questions IS the same, however in time, because their purposes differ, a third party solution could arrive to one or the other which does not solve both use cases. Having one question closed prevents it being (potentially) answered.  Admittedly, in the initial versions of the question was not worded so the differences were apparent, so it was valid to close it. Now it has been revised so the differences are clear. Adding a comment or editing and old question doesn't get fresh eyes on it, no front page exposure. So what does one do? Ask a question like this here on meta? Ask the question anew with the better phrasing?  There is another meta question asking about this, , but the theme is quite different, being about appealing a closure in the milieu of flame wars and off-topic debates.


How to generate all possible permutations of two numbers with value n in python?

I want to get permutations for two numbers upto n repetitions in python code.  Example:  a = 10, b = 100 and given n = 3  Now I want output like:  (10, 10, 10), (10, 10, 100), (10, 100, 10), (10, 100, 100), (100, 10, 10), (100, 10, 100), (100, 100, 10), (100, 100, 100)   I tried itertools permutations but wont helpful. Anyone please give me a solution.


Why aren't bounties refunded if they are not awarded?

I have  with a bounty that will expire in a few days. It looks like nobody will get the bounty; only one answer was posted during the bounty period, and it has no upvotes.  In cases like this, the bounty is thrown away.  Why isn't it refunded instead, if no answerer has earned it?


Unable to log into a rsyslog filter using logger

Ubuntu 64 14.04 comes with rsyslog (7) built-in.  I've added test.conf to /etc/rsyslog.d with the following line:  :syslogtag,isequal,"test"       /var/log/test.log   I then restart rsyslog and log using logger:  echo "hi there" | logger -t test   I expect that line to reach /var/log/test.log, but instead it reaches syslog.log.  What am I doing wrong?


what is the value of .01 python addition

I'm trying to add two floating number and I cannot get to work. I need to be the output to be 100.0 What I'm doing wrong here. Thank you for any advise.  mystring = 'Value:   99.9      Date:    20130215' tot = float(mystring[8:13]) print (float(tot) + .01)   I need to be the tot = 100.0 if any one can help Thank you  I'm getting 99.91


Android NullPointerException on button click

I am experimenting with shared preferences and I get a NullPointerException error when I click the button bAddList.  Here is my MainActivity Class (The only class in the project)  package com.teamvdb.checklist;  import android.app.Activity; import android.content.SharedPreferences; import android.os.Bundle; import android.view.View; import android.widget.Button; import android.widget.EditText; import android.widget.TextView;  public class MainActivity extends Activity{ static String filename; SharedPreferences.Editor editor; SharedPreferences someData;  @Override protected void onCreate(Bundle savedInstanceState) {     // TODO Auto-generated method stub     super.onCreate(savedInstanceState);     setContentView(R.layout.main);     filename ="checkLists";     Button bAddList = (Button) findViewById(R.id.bAddList);     final EditText etNewListName = (EditText) findViewById(R.id.etListName);     final TextView tvResults = (TextView) findViewById(R.id.result);      bAddList.setOnClickListener(new View.OnClickListener() {          @Override         public void onClick(View v) {             // TODO Auto-generated method stub             String stringData = etNewListName.getText().toString();             SharedPreferences.Editor editor = someData.edit();             editor.putString("sharedString", stringData);             editor.commit();              someData = getSharedPreferences(filename,0);             String dataReturned = someData.getString("SharedString", "Unable to Load Data");             tvResults.setText(dataReturned);         }     });   }  }   Logcat  12-12 20:50:37.818: W/dalvikvm(32683): threadid=1: thread exiting with uncaught exception (group=0x41812da0) 12-12 20:50:37.818: E/AndroidRuntime(32683): FATAL EXCEPTION: main 12-12 20:50:37.818: E/AndroidRuntime(32683): Process: com.teamvdb.checklist, PID: 32683 12-12 20:50:37.818: E/AndroidRuntime(32683): java.lang.NullPointerException 12-12 20:50:37.818: E/AndroidRuntime(32683):    at com.teamvdb.checklist.MainActivity$1.onClick(MainActivity.java:32) 12-12 20:50:37.818: E/AndroidRuntime(32683):    at android.view.View.performClick(View.java:4637) 12-12 20:50:37.818: E/AndroidRuntime(32683):    at android.view.View$PerformClick.run(View.java:19422) 12-12 20:50:37.818: E/AndroidRuntime(32683):    at android.os.Handler.handleCallback(Handler.java:733) 12-12 20:50:37.818: E/AndroidRuntime(32683):    at android.os.Handler.dispatchMessage(Handler.java:95) 12-12 20:50:37.818: E/AndroidRuntime(32683):    at android.os.Looper.loop(Looper.java:136) 12-12 20:50:37.818: E/AndroidRuntime(32683):    at android.app.ActivityThread.main(ActivityThread.java:5586) 12-12 20:50:37.818: E/AndroidRuntime(32683):    at java.lang.reflect.Method.invokeNative(Native Method) 12-12 20:50:37.818: E/AndroidRuntime(32683):    at java.lang.reflect.Method.invoke(Method.java:515) 12-12 20:50:37.818: E/AndroidRuntime(32683):    at com.android.internal.os.ZygoteInit$MethodAndArgsC


I am trying to replicate the style of the following pseudocode.   The following minimal working example almost produces what I want except the extra vertical space between lines 7 and 8. How can I resolve this issue? Is there an easier way to format pseudocodes this way?  \documentclass[12pt]{article}  \usepackage[noend]{algpseudocode}  \setlength\parindent{0pt} \newcommand{\Def}[3]{\textbf{#1}\ \textsc{#2}\ifthenelse{\equal{#3}{}}{}{(#3)}} \algrenewcommand{\alglinenumber}[1]{\footnotesize#1\hspace{1em}}% <- This line  \begin{document}      \Def{procedure}{Euclidian}{$a,b$}     \begin{algorithmic}[1]         \State $x \gets a$         \State $y \gets b$         \While{$x \not= y$}             \If{$x < y$}                 \State $x \gets x - y$             \Else                 \State $y \gets y - x$             \EndIf         \EndWhile         \State \textbf{return} $x$     \end{algorithmic}  \end{document}   Edit I have tried clrscode3e this time. It worked, but required me to hack the package code. I still wonder if there is an easier solution.  \documentclass[12pt]{article}  \usepackage{clrscode3e}  \setlength\parindent{0pt}  % Restore \gets \let\gets=\leftarrow  % Print 'do' and 'then' \renewcommand{\Do}{\textbf{do}\addtocounter{indent}{1}} \renewcommand{\Then}{\textbf{then}\addtocounter{indent}{1}}  % Indent recursively (\hspace is used instead of \>) \renewcommand{\putindents}{\ifnum\value{thisindent}>0%     \hspace{1.5em}\addtocounter{thisindent}{-1}\putindents% \fi}  % Line number separation (hspace is added) \makeatletter \renewcommand{\liprint}{\protected@xdef\@lilabel{\thecodelinenumber}%     \ifnumberedline\thecodelinenumber\fi\'\hspace{0.25em}\Indent% } \makeatother  \begin{document}      \begin{codebox}     \Procname{\textbf{procedure} $\proc{Euclidian}(a,b)$}     \li $x \gets a$     \li $y \gets b$     \li \While $x \not= y$ \Do     \li     \If $x < y$ \Then     \li         $x \gets x - y$     \li     \Else     \li         $y \gets y - x$             \End         \End     \li \Return $x$     \end{codebox}     \end{document}   Edit 2 The patch proposed by @egreg fixes vertical alignment, but I have one more issue. In the first MWE, the marked line left-aligns the line numbers by increasing the separation. However, it cannot handle multidigit line numbers. What are your suggestions?


then the value of $ \frac{1-\vert a \vert^2}{\pi} \int_{\gamma} \frac{\vert dz \vert}{\vert z+a \vert^2} $.

If $a\in  \mathbb{C}$ with $\vert a \vert <1$ , then the value of  $$ \frac{1-\vert a \vert^2}{\pi} \int_{\gamma} \frac{\vert dz \vert}{\vert z+a \vert^2} $$  where $\gamma$ is the simple closed curve with $\vert z \vert=1$, taken with the positive orientation.  I tried but I cant manipulate the denominator, I used $z \bar z =\vert z \vert^2$, Please help.


Ubuntu 18.04, Arduino 1.8.5, NodeMCU v1 will not flash even with all requirements met. Why?

Before you mark as duplicate I have read everything I can find, and done the following.  1) I have added myself to dialout group, then logged out, then back in, chmod 0666, even 0777 /dev/ttyUSB0.  2) I have done this, as suggested in :  ~$ esptool.py --port /dev/ttyUSB0 chip_id esptool.py v2.5.1 Serial port /dev/ttyUSB0 Connecting.... Detecting chip type... ESP8266 Chip is ESP8266EX Features: WiFi MAC: 60:01:94:5d:4d:9d Uploading stub... Running stub... Stub running... Chip ID: 0x005d4d9d Hard resetting via RTS pin...   Passing grade there!  3) I have tried 7 different boards that were pulled from new packages.  4) I have tried every baud rate in settings.  5) I have tried every possible combination of settings for NodeMCU v1 and v0.9, just in case.  6) Board temps and wiring pass all checks, this is not a duplicate issue because all the steps in your linked issue have been tested, yet the error persists.  I still get the following error every time I try to upload via Arduino 1.8.5  error: cannot access /dev/ttyUSB0 An error occurred while uploading the sketch  error: espcomm_open failed error: espcomm_upload_mem failed   Why? Is Arduino app 1.8.5 buggy in Ubuntu 18.04?  Frustration level is at smash with hammer. Please tell me there is something I missed.  Oh the kicker, these boards will flash on a Mac Pro perfectly, so I know it's isolated to the Arduino app on Ubuntu only.


Is there good software for recovering photos from an iphone data

My iPhone is in recovery mode and I want to recover some photos. Does anyone know if dr.fone works? I don't want to pay for something that doesn't do the job.


Get parent of the script tag from inside it

From inside a javascript file, how can we detect the parent of this script tag without any id and class by jquery.  (function() {     $(this).parent('div').attr('id'); })();


How to prove that $(P \supset Q) \equiv (\neg Q \supset \neg P)$is disallowed in intuitionistic logic?

I have tried defining the following kripke model:  $K = ({0,1}, \leq , \models)$   then I define the followings for $A$ and $B$   $0 \nvDash A$ $1 \vDash A$  $ 1 \nvDash B$ $0 \vDash B $  then I say that   $ 1 \nvDash (\neg B \to \neg A) \to A\to B$  Can somebody say how to do it correctly?


I am getting Linux Training and came across one question that I am unable to find answer of:  What does the . mean in chmod command? Eg: chmod 777 .


Removing bottom material slot for all objects in a collection

I need help removing the second material from all objects in a collection. All the objects have two slots with the second one being of no apparent use. I'm not well versed in python, but I've managed to achieve this for singular objects using this: o.active_material_index = 1 bpy.ops.object.material_slot_remove()  All I need now is a way to apply this to all objects inside a particular collection.


How to set signal strength threshold for switching WiFi on and off?

When the WiFi signal strength is low, the phone switches to a 4G network. When the WiFi signal strength is high, the phone switches to that WiFi network.   This is normal behavior for any Android device and all too familiar to Android users, or to users of any WiFi enabled device in fact. But the problem I often run into is that the WiFi signal is too low to be usable, and too high to switch to 4G automatically.   WiFi signal strength 0 < x < 0.5 marks (bars), the phone switches to a 4G network. WiFi signal strength x > 0.5 marks, the phone switches to that WiFi network.   These values are not real measurements. They are merely my own perceived points at which the phone switches between the two.  TL;DR: Is there a way for me to optimize the auto-switching between WiFi and 4G to my own liking? Is it possible to set that threshold point manually? What I would like is to switch over to 4G as soon as the WiFi signal is below the 2 mark point.    What I am often forced to do, in order to get (usable) Internet access, is to enter the Settings menu on the phone and disable WiFi altogether in order to force my "smart" phone to switch over to 4G!  Would it not be better if the user could control the threshold at which the phone switches between WiFi and 4G? I think the default threshold is too conservative. It's set up to conserve 4G bandwidth by free-riding on available WiFi networks for as long as possible and whenever possible (available).  Devices are optimize to make use of WiFi as much as possible, due to associated data costs on 4G networks. But this is a nuisance! My Internet access is almost completely crippled for many of the WiFi networks I have access to, whenever the signal strength is below the 2 mark point. On the other hand, I have over 4 GB unused bandwidth on my carrier network, for which I have a much stronger signal, but I have to disable WiFi first in order to connect to 4G. That's not convenient when you're on the move a lot.  I have recently started using the 4G network almost exclusively. I have stopped using WiFi because I have had enough with enabling and disabling it back and forth, and having to remember to do it when I'm on the move. So I am looking for a more permanent solution to this.


Why does this method for differentiating work?

Consider the function  $$f(x)=x^x.$$ If I differentiate with respect to $x$ treating the exponent as a constant and then sum the derivative treating the base as a constant, I get \begin{align} f'(x)&= xx^{x-1}+x^x\ln x\\ f'(x)&= x^x(1+\ln x). \end{align}


Accessing file geodatabase (.gdb) rasters with GDAL?

I'm working on a tool that converts raster layers to arrays for processing with NumPy, and ideally I would like to be able to work with rasters that come packaged in a .gdb without exporting them all (especially if this requires engaging ArcGIS or ArcPy).  Is this possible with the OpenFileGDB driver?   From what I can tell this driver seems to treat raster layers the same as vector layers, which gives you access to some data about the layer but doesn't give you the ReadAsArray functionality.


If this was your website, what will be the URLs for each car on sale?  http://www.autoscout24.eu/Details.aspx?id=247572735&asrc=ha   I'm working on a car dealership website. What should be the best URL? Consider also that the company can have more models of the same car.  I'm not asking for a url scheme, there are a lot of similar questions. My question is: in a car dealership website what is the best url for a car? What are by you the best variables I've to put on the url.  Brand, model, year, location, color, miles/km, etc.  This website, that url, this particulary case: what will you choose for urls? (even not in the following list)  audi_q5_2009.html audi_q5_2009_used.html audi_q5_2009_used.html audi_q5_2009_used_in_alcobendas.html audi_q5_2009_used/247572735.html


Find $F'(x)$ if $F(x) = \displaystyle \int_{0}^x xf(t)dt$.  I tried performing integration by parts to get $\displaystyle F(x) = xtf(t)-\int f'(t)f(x)xt dt$, but I am not sure how that helps. Also, are we assuming $x(f(t))$ to be integrable because otherwise the integral doesn't exist? (This problem appears in Calculus by Michael Spivak, 3rd Ed., Chapter 14, Problem 11.)


Checking Logical Correctness of a TeX Document

Is there a way to check the logical correctness of my TeX document?  Suppose in the proof of Theorem 2.1 I refer to Theorem 3.5. I would call this logical incorrectness.  This may happen when we reorganize our document. Is there a way to avoid this?   Thanks.


How do I find out whether a message in CBC has padding?

When a program is decrypting a message encrypted by CBC mode, what does it find out, whether the last bytes of the last block is part of the padding or part of the plaintext?  Example: Use CBC mode with 4 Byte blocksize and encrypt the following two messages:  m1 = ABCDEF m2 = ABCDEF22   M1 gets padding and will be "ABCDEF22". How do I find out, whether the original plaintext was ABCDEF, or ABCDEF22?


How do I disable the Java updater on OS X?

I've disabled automatic checking for Java updates the Java Control Panel, but my changes are always ignored, as I can confirm by checking the control panel after making and saving my changes:    How do I really disable automatic checking for Java updates?


Merging a column of sequential numbers in multiple .csv files into single .csv file

I am on Linux/Centos7. I have multiple csv files I want to merge, I am using this command to merge.  cat *csv > all.csv   But the first column contain a sequential number that needs to be merged and renumbered in sequential order.   ==> 1.csv <== 1,bob,date,body 2,joe,date,body 3,ann,date,body  ==> 2.csv <== 1,lisa,date,body 2,paul,date,body 3,mike,date,body   I would like the result to renumber the first column to be like this  ==> output.csv <== 1,bob,date,body 2,joe,date,body 3,ann,date,body 4,lisa,date,body 5,paul,date,body 6,mike,date,body   When I do a regular merge I have this, And if I can renumber this merged file that would work too.  1,bob,date,body 2,joe,date,body 3,ann,date,body 1,lisa,date,body 2,paul,date,body 3,mike,date,body