If A is an invertible complex matrix with minimal polynomial $(t-\lambda_1)^{c_1}...(t-\lambda_k)^{c_k}$, is it true that the min poly of A^n is $(t-\lambda_1^n)^{c_1}...(t-\lambda_k^n)^{c_k}$? I think this is true by considering Jordan blocks, but is there a less high-tech way to see this (e.g. just by considering generalised eigenspace decomposition)?
I am wondering, given the minimal polynomial of $A$, what can we say about the minimal polynomial of $A^n$?  I know that if we were looking at the roots of the characteristic polynomial ie eigenvalues then the roots of the characteristic polynomial of $A^n$ would be $nth$ powers of the eigenvalues so again these are roots of the minimal polynomial also.
UIDatePicker show only month and day I'd like to have a UIDatePicker where the user can pick a month and a day but not the year. I'm aware that leap years have an extra day, so for simplicity, let's throw that day away.  Is there any way to remove the year column or have 2 reels with month/day that act like the UIDatePicker (grey out days that don't exist in the selected month)? Full Wi-fi/ethernet signal but no internet I'm really hoping someone here can help me, as I'm getting pretty frustrated with my macbook now. I have a late 2011 model 15" macbook pro running OSX 10.9.5 that refuses to connect to Internet on my home network. I have the same problem whether it's WiFi or through ethernet cable, I have full signal but not getting online. Every other device connects fine; android phones and tablets,xbox one, iPhone and other macbooks, all online and browsing the net. I have had no problems connecting to other networks with my macbook pro before and I just tried at a friend's house to check, with no problems. A little something, that may be a clue to someone: when I open network diagnostic tool, my macbook pro connects for something that seems like a microsecond and it tells me I'm connected to Internet and everything seems fine. My IP is 192.168.0.5 subnet mask 255.255.255.0 and IPv6 is set to automatic. None of the options are checked under the proxies tab. Now I've tried the following, in different order and a number of times, to no avail:   Renewing/turning off&amp;on/inputting manually DHCP.  Restarting/resetting the router and the macbook.  Turning WiFi on/off. Remove &amp; add services (WiFi &amp; ethernet). Checked and copied all network settings from another macbook pro that's connected and online on my network. Ran network diagnostic and assistant tools Duplicated/removed/added location Removed the /Library/Preferences/SystemConfiguration folder. Removed network password from keychain.      I've tried other things too, but can't remember what else right now.  Response from ifconfig en1:  en1: flags=8863&lt;UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST&gt; mtu 1500              ether 28:cf:da:e6:95:0a              inet6 fe80::2acf:daff:fee6:950a%en1 prefixlen 64 scopeid 0x5               inet 192.168.0.5 netmask 0xffffff00 broadcast 192.168.0.255              nd6 options=1&lt;PERFORMNUD&gt;              media: autoselect               status: active    I'm praying that someone out there has the magic words or the 2-click solution for me, but I would be grateful for a long thorough guidelines to solve it too! &lt;3        Regards Trond Do you want to come with? Can I come with?  I seem to hear this construction more often in recent years, but it still grates on my ear. I know it's often said that one shouldn't , but I class that rule along with  (i.e. — pedantic tosh). Is it always informal/casual speech to end a sentence with &quot;with&quot;? Was it ever thus? What is the purpose of -e in sed command? I can't find any documentation about the sed -e switch, for simple replace, do I need it?  e.g.  sed 's/foo/bar/'   VS  sed -e 's/foo/bar/' How can I recover a deleted file on Android? Can you get a Windows (AD) username in PHP? I have a PHP web application on an intranet that can extract the IP and host name of the current user on that page, but I was wondering if there is a way to get/extract their Active Directory/Windows username as well. Is this possible? Unable to load DLL (Module could not be found HRESULT: 0x8007007E) This is a  about Hosting multiple SSL websites on the same IP.   I was under the impression that each SSL Certificate required it's own unique IP Address/Port combination. But the  is at odds with this claim.  Using information from that Question, I was able to get multiple SSL certificates to work on the same IP address and on port 443. I am very confused as to why this works given the assumption above and reinforced by others that each SSL domain website on the same server requires its own IP/Port.  I am suspicious that I did something wrong.  Can multiple SSL Certificates be used this way? Removing leading zeroes from a field in a SQL statement I am working on a SQL query that reads from a SQLServer database to produce an extract file. One of the  requirements to remove the leading zeroes from a particular field, which is a simple VARCHAR(10) field. So, for example, if the field contains '00001A', the SELECT statement needs to return the data as '1A'.  Is there a way in SQL to easily remove the leading zeroes in this way? I know there is an RTRIM function, but this seems only to remove spaces. How do I turn off some formats in GeoServer's WMS? I have published a couple of layers on my Geoserver.  To be complaint with the T&amp;C of my data provider, I need to block the access of some of those layers as Vector data. Hence I have already blocked the WFS services on these Layers.  I came to know that even on the WMS service, you can get Vector Data, if you use GeoRSS and some of the .   How do I block GeoRSS, SVG &amp; UTFGrid as formats in the WMS Service? Match-3 algorithm to fill empty space left from removing matches I am currently creating a match 3 game.   I am at the point where I have objects dropping down in the column when only one item is removed. So if an item is removed, the above item moves into its old position etc.  The problem I am having now is that when more than one item is removed from a column, the items in that column only drop down to the first item that was removed. Instead of filling in both items that were removed it just drops down to fill in the first one.   So basically, if two(or more) items are removed from a column the second, third, fourth, etc positions are left blank.  The way I am designing my game is I am using units of 1. So each item takes up 1 unit by x and 1 unit by y. This means that I can position the items like in a grid, at 0x1, 0x2, etc.   What kind of algorithm could I use to move multiple items down to fill the empty space? I'm not quite sure how this happened, but somehow a completely empty hierarchy of directories has ended up in my repository:  com/ com/companyname/ com/companyname/blah/ com/sun/ com/sun/java/ com/sun/java/jax_rpc_ri/   I think what happened was that these directories did have files in them, but then a developer realized he/she shouldn't have checked them in in the first place since these are by-products of the build process, so he/she removed the files but somehow the empty directories are left in the repository as ancient relics.  How can I remove this from CVS? The only results I seem to be able to find on google say that there shouldn't be a need to remove empty directories as CVS won't keep them around in the first place, and that the -P (prune) options to cvs update should remove them from the working directory  - which is zero help if you actually have empty directories in your repository.  A cvs remove and cvs commit doesn't seem to take care of this situation:  $ cvs remove -Rf com cvs remove: Removing com cvs remove: Removing com/companyname cvs remove: Removing com/companyname/blah cvs remove: Removing com/sun cvs remove: Removing com/sun/java cvs remove: Removing com/sun/java/jax_rpc_ri $ cvs commit com cvs commit: Examining com cvs commit: Examining com/companyname cvs commit: Examining com/companyname/blah cvs commit: Examining com/sun cvs commit: Examining com/sun/java cvs commit: Examining com/sun/java/jax_rpc_ri $ ls -l com total 24 drwxrwxr-x  2 matt matt 4096 Oct 15 14:38 CVS drwxrwxr-x  9 matt matt 4096 Oct 15 14:38 companyname drwxrwxr-x  4 matt matt 4096 Oct 15 14:38 sun   It's still there!  Does SVN have this weird behavior too? Why is the network configuration I set in /etc/network/interfaces ignored on Ubuntu 17.10? Why is the change in Hamiltonian for an active infinitesimal canonical transformation defined the way it is? I'm trying to understand infinitesimal canonical transformations and conservation theorems (section 9.6 Goldstein ed3). My specific problem is with understanding eq 9.104,         $\partial H = H(B) - K(A^{'}) $, where $\partial H$ represents the change in the hamiltonian under an infinitesimal canonical transformation (from the active view point ofc). The issue only arises for generating functions that explicitly depend on time.  Here's what I've thought of so far. I understand what $K$ is from the passive viewpoint (or so I think), its the hamiltonian that would furnish Hamilton's equations for the transformed variables $Q=q+ \delta q$ and $P = p + \delta p$. In the specific case of the generating function being a time dependent hamiltonian, $K = H + \delta t \frac{\partial H}{\partial t} = H + \delta t\dot H$, which makes sense because once you transform the variables to what they'll be in time $\delta t$, you'll also need to add on a term that comes from the Hamiltonian being at a later time $t+ \delta t$.   In the book, this is explained as a transformation depending on time changes the hamiltonian, so $H(A) \rightarrow K(A^{'}) $. Which I sorta get. But why not for $H(B)$? And what about the case when the Hamiltonian is time dependent and it is the generating function? Is $H(B)$ at a later time then?   Note: $A$ represents the original variables, $B$ is the transformed variables in the active sense, so in the same phase space as $A$, and $A^{'}$ is the same point as A but in the transformed phase space (passive). I see an equation like this:  $$y\frac{\textrm{d}y}{\textrm{d}x} = e^x$$  and solve it by "separating variables" like this:  $$y\textrm{d}y = e^x\textrm{d}x$$ $$\int y\textrm{d}y = \int e^x\textrm{d}x$$ $$y^2/2  = e^x + c$$  What am I doing when I solve an equation this way?  Because $\textrm{d}y/\textrm{d}x$ actually means  $$\lim_{\Delta x \to 0} \frac{\Delta y}{\Delta x}$$  they are not really separate entities I can multiply around algebraically.    I can check the solution when I'm done this procedure, and I've never run into problems with it.  Nonetheless, what is the justification behind it?  What I thought of to do in this particular case is write  $$\int y \frac{\textrm{d}y}{\textrm{d}x}\textrm{d}x = \int e^x\textrm{d}x$$ $$\int \frac{\textrm{d}}{\textrm{d}x}(y^2/2)\textrm{d}x = e^x + c$$  then by the fundamental theorem of calculus  $$y^2/2 = e^x + c$$  Is this correct?  Will such a procedure work every time I can find a way to separate variables? Change \textwidth and \textheight in mid-document I set my \textwidth and \textheight in the preamble and would like to change both for some pages. How can this be done? E.g., the following example for \textwidth appears to work for the page number, but not for the text:  \documentclass{article}  \textwidth=5cm \textheight=5cm \begin{document} A \hfill B \eject \textwidth=10cm A \hfill B \end{document}   Output (true to scale): Does a subsequent charm effect override a previous one? In a recent session, I was confused about how multiple charm effects would interact with each other:  A vampire used its 'Charm' ability to charm a PC. It reads (paraphrased):     The target must succeed on a saving throw or be charmed by the vampire. It takes the vampire's requests in the most favourable way it can. It can repeat the saving throw if the vampire or its companions harm it. Otherwise, the effect last 24 hours or until the vampire is destroyed, is on another plane of existence, or takes a bonus action to end the effect.   Another PC then decided to attempt to wrest control back from the vampire by casting crown of madness on their friend. it reads (paraphrased):     The creature must succeed on a saving throw or be charmed. The charmed target must use its action before moving on each of its turn to make a melee attack against a creature other than itself that you mentally choose. The target can act normally on its turn if you choose no creature, or none are within its reach.   At the time, I ruled that both effects would take place simultaneously. This meant that Crown of Madness took effect first, and the vampire's charm afterwards.  Was this the correct ruling? Can a creature be charmed twice? Or does one charm effect override the other? How to drive multiple LEDs from a Li-ion battery (with varying voltage)? I want to supply constant voltage to my LED's but the supply varies from 3.7V to 4.2V (Li-ion battery). I cannot use 3.3V voltage regulator as it will need at least 4.3V voltage at the input but my battery can supply only 4.2V max. so is there any other way I can supply regulated 3.3V to my LED.   RGB LED = 3.3V, 60mA Battery = 3.7V - 4.2V, 3000mA Number of LEDs = 24 The LED's are connected in parallel Can the Force be used to fly? In The Empire Strikes Back Yoda uses the Force to lift Luke's X-Wing out of the water and put it on land.  In Attack of the Clones and in many instances in the second series of The Clone Wars, Anakin (and others) use the Force to jump higher than they could otherwise, or to jump from very high locations, but I don't think I've ever seen the Force used for outright self-levitation.  But if Yoda could lift the X-Wing, shouldn't a strong Jedi be able to lift himself and, essentially, fly with the help of the Force? Monitoring contents of files/directories?