How to write a template function where its parameter type is required to be inheriting certain class
Template specialization based on inherit class
Matrix Group induction proof and order of elements question $H$ is the set of the matrices $A$ of the form $$A= \begin{pmatrix} \cos(\theta) &amp; \sin (\theta) \\ -\sin (\theta) &amp; \cos (\theta)\end{pmatrix}$$  where $0\leq \theta &lt; 2\pi$  is a group with respect to matrix multiplication.  Question part (1) Prove by induction that  for any $\theta$ and any positive integer $n$,  $$\begin{pmatrix} \cos(\theta) &amp; \sin (\theta) \\ -\sin (\theta) &amp; \cos (\theta)\end{pmatrix}^{n} = \begin{pmatrix} \cos(n\theta) &amp; \sin (n\theta) \\ -\sin (n\theta) &amp; \cos (n\theta)\end{pmatrix}$$   When $n =1$ we have $$\begin{pmatrix} \cos(\theta) &amp; \sin (\theta) \\ -\sin (\theta) &amp; \cos (\theta)\end{pmatrix}^{1} = \begin{pmatrix} \cos(\theta) &amp; \sin (\theta) \\ -\sin (\theta) &amp; \cos (\theta)\end{pmatrix}$$   and clearly this holds for the base case.   Now I'm going to assume true when $n=k$ and try and prove for $k+1$. So we have   $$\begin{pmatrix} \cos(\theta) &amp; \sin (\theta) \\ -\sin (\theta) &amp; \cos (\theta)\end{pmatrix}^{k}\begin{pmatrix} \cos(\theta) &amp; \sin (\theta) \\ -\sin (\theta) &amp; \cos (\theta)\end{pmatrix}^{1} = \begin{pmatrix} \cos(k\theta + \theta) &amp; \sin (k\theta + \theta) \\ -\sin (k\theta + \theta) &amp; \cos (k\theta + \theta)\end{pmatrix}$$   Now I'm sure I can cheese this, but is there some clever way to pull this apart? I want to just be able to say something like the determinant of the left side is $1^{k+1}$ and its the same on the right ...  Question part (2) Find an element of $H$ of order 5.  Here I'm totally lost, I seem to think that every element is of order 1 cause the determinant is 1.  Question part (3) Find an element of $H$ of infinite order.  Again I'm lost; I want to somehow make the determinant 0 for this but it can never be 0 for any $\theta$. How did Thanos know about the power of "The Snap"? In the scene on Titan with Doctor Strange in Avengers: Infinity War, Thanos said,     With all six Infinity Stones, I will simply snap my fingers and it would all cease to exist.   Then again, in the very first scene with Thor and Loki, when Maw gave Thanos the Space Stone, he said that no one has ever worn two Infinity Stones together.   So how come Thanos knew about the power of the Snap? Because as Wong puts it to Tony, the Big Bang hurled the six Infinity Stones across the universe.   So if no one had collected all the six stones before Thanos, then how did he know about the ability to "Snap"? Currently my spouse and I rent a small apartment.  Eventually we'd like to expand the family, and a one bedroom rental won't cut it forever - even if we continue renting we'll be expanding to a detached single family home eventually.  In our area the rent ratios work out to about 16, which is under the cut for buying being a better financial decision over the long haul - i. e. I don't think it'd be economically an awful decision to buy (NYT calculator shows 10 years at the current prices and rents for buying to make sense).  I've also read enough of the rental propagandists to know that home ownership isn't the best way to grow my money.  My reasons for wanting to own are the intangibles: knowing we aren't going to have to move due to a landlord, being able to modify the place to our own liking, and that intangible sense of "this is mine" (even when it's the bank's for a while).  The things we do have:   Around (at or over) a 30% down payment depending on purchase price, and we won't be under 30% Closing costs separate from that fund Around 1% of the home value in reserve for emergency repairs separate from those funds A six month emergency fund separate A fund to replace an ailing car that will probably die before we can save up after this expense   At some point in the year or so after the purchase we plan to have enough saved up to pay down the principal and change our monthly payment somewhat, but not significantly.  So it seems like we've got the financial ducks in a row.  We can continue to fully fund our retirement accounts and make the monthly payments (PITI).  The only hesitation we have is that we can't make our payments comfortably on one income alone - it'd be over 30% of one income to do so, by just a bit.  So neither of us can completely stop working, although the second income does not need to be large.  Are we missing any important financial data about this step?  Should we be concerned about job loss (even though no signs of it are imminent for either of us)? multiplication equivalent of the summation symbol I was curious (even though this is a very amateur question)... what would the multiplication equivalent of sigma (the summation symbol) be? $$\sum$$ I want to do a series of multiplication of terms.... instead of addition... Transferring Money from India I was speaking to an English learner and said, “All you have to do is read a lot.” And they thought that sentence wasn’t grammatically correct because I dropped the word to between is and read.  They thought it should be “All you have to do is to read a lot.” That sounds weird to me.   How do I explain to them the reason you drop the to? Or am I incorrect and it really should have a to? Add table row in jQuery What is the best method in jQuery to add an additional row to a table as the last row?  Is this acceptable?  $('#myTable').append('&lt;tr&gt;&lt;td&gt;my data&lt;/td&gt;&lt;td&gt;more data&lt;/td&gt;&lt;/tr&gt;');   Are there limitations to what you can add to a table like this (such as inputs, selects, number of rows)? How to change the list of file types which Safari will open immediately after download? I would like to change Safari Safe List of type files which open immediately after download. Any ideas how? Getting error message when trying to start a virtual machine I have been using VMWare on Windows for a long time. But after a long wait, I moved to VirtualBox on Ubuntu 11.10. I installed Ubuntu, 32 Bit, installed all available updates and installed Virtual Box. When I try to create a new Windows installation inside VirtualBox, I got the following error messages.  VirtualBox - Error  Failed to open a session for the virtual machine Windows XP. The virtual machine '**Windows XP**' has terminated unexpectedly during startup with exit code 1. Details  Result Code: NS_ERROR_FAILURE (0x80004005) Component: Machine Interface: IMachine {5eaa9319-62fc-4b0a-843c-0cb1940f8a91}   2nd error dialogue  Virtualbox - Error in suplibOsinit Kernal driver not installed (rc--1908) Please install the virtualbox-dkmbs package and execute 'modprobe vboxdrv' as root.    I have already tried reinstalling VirtualBox. Google result seem to indicate the the problem happens due to Kernel updates.   Is there anyway I can get this working? I need this for malware analysis and if VirtualBox is going to crash on me all the time, then I won't be able to use Ubuntu for work.  Output to dpkg -l | grep virtual   server rc  virtualbox                             4.1.2-dfsg-1ubuntu1                     x86 virtualization solution - base binaries rc  virtualbox-qt                          4.1.2-dfsg-1ubuntu1                     x86 virtualization solution - Qt based user interface  cute 'modprobe vboxdrv' as root.&lt;p&gt; I asked about it on  and they told me to post it here.  Probably need to add the :active to the :hover meta class or something like that.  Example:      Hammer Time Is there a test to determine whether solder is leaded or lead-free? Perhaps conductivity/resistance? set only lower bound of a limit for ggplot Is "coachee" even a word? If I am Rita's coach, is Rita my *coachee? (yikes) Is that even a word? Would it be correct instead to say she is my ward? What about terms for people at the other end of a mentor, sponsor relationship? Is $\mathbb{R}^\omega$ endowed with the box topology completely normal (or hereditarily normal)? My Ubuntu laptop which was working fine until recently. My desktop disappeared and all the desktop icons are gone. All I have access to is the terminal. In an attempt to fix the problem, I installed GNOME but it made the computer give the error:     Warning! Failed to connect to lvmetad. No such file or directory Falling back to internal scanning.    I can press Ctrl+Alt+F1 to start tty1 but I can't get to a graphical user interface. What did I do wrong and how do I fix it?.  The operating system is ubuntu Linux How do I boot to a command line interface instead of a GUI? Hi I have ubuntu server 10.04 installed and I also installed the following:  su aptitude install xorg xfce4 aptitude install &lt;name of GUI browser, I use firefox&gt; aptitude install gedit aptitude install gnome-terminal   Now when I restart the system it goes to the GUI login, what I am really after is a system that loads the CLI by default and then I can use startx to load the GUI when really necessary. I am trying to learn CLI but I would like to retain access to the GUI for now. And, how can I switch between CLI and GUI anytime? FIELD_INTEGRITY_EXCEPTION: field integrity exception: unknown (invalid user or group: 005XXXXXXXXXXXX) I've a object called myobject__c. This object is private in OWD Setting.  Now when admin create a new record of this object then I want to share this record with a user(community user). For this I've written a code in trigger to create a sharing record of this object (myobject__Share).  But I am getting a problem of :-      FIELD_INTEGRITY_EXCEPTION: field integrity exception: unknown (invalid   user or group: 005XXXXXXXXXXXXX).   how can I solve this problem and second doubt is can we create share record for community user or not. I'm creating a beamer presentation, in which I use TikZ.  I am making a figure, on which I would like to highlight something (using \only&lt;&gt; command). My figure contains an ellipse that is decorated with random steps:  ... \node[ellipse,minimum width=1cm,black!30,decorate,decoration={random steps,segment length=0.2cm,amplitude=.1cm}] {};  \only&lt;1&gt;{ \node (n) at (0,0) {A}; } \only&lt;2&gt;{ \node (n) at (0,0) {B}; }   The ellipse is rendered in differenlty. How can I make it to render the same? or what other decoration can I use to get a similar effect to random steps? Continuous weighted random distribution, biased toward one end I am currently contributing to a particle system for our game and developing some emitter shapes.  My uniform random distribution along a line or along a rectangular area works fine - no problem.  But now I would like to have something like a 1 dimensional gradient in this distribution. This would mean for example lower values are more common than higher values.  I don't know what would be appropriate mathematical terms for this problem, so my search skills are rather useless with this one. I need something that is computationally simple, as the particle system needs to be efficient. How can I recursively clear the "Hidden" file flag on Windows Vista? A friend's computer was recently infected with a virus.  I hope the virus has been removed successfully. But, it appears that the virus set the "Hidden" flag on most directories and files on the system.   What's the most convenient way to clear this flag from selected directories and their contents?