Getter method must return a double - how to implement DecimalFormat?
How to round a number to n decimal places in Java
Can I send in for repair a lens that has a shattered front element?     UPDATE: The front element was not shattered, it was the UV filter. Factory diagnosis: Lens assembly had been impacted; cleaned and checked.  Helpful notes by Crowley, David Richerby (x2), Michael Clark (x2), and   mattdm (on element price vs UV filter).      Canon cleaned and checked my lens back to like new quality for $179 labor, no parts, not including shipping.      Jim Garrison answered my question, but Crazy Dino has the best info all around for a lens element shatter.   Original Question:  I recently opened my camera bag to find a shattered front element on a Canon EF 16-35mm f/2.8 L II USM lens.   There are a lot of micro glass shards on the second element.  Does anyone have experience with this sort of thing?  Some of the following are questions I have:   Can I get it repaired? What will the cost be roughly? Will the lens ever work the same and have a good image quality? Should I ship it as is, or attempt cleaning it with air? Where is the best place to cry a little?   Thanks, any good info on this would be appreciated.  I will never rest a lens on another lens, I nearly lost a 24-70mm L that shattered a UV filter also.   Good reason to have a UV always, never thought it could happen to me.  Update: Looking at it more it looks like maybe just the front ring came undone and the UV filter broke?  I can't remember what it looked like exactly before.  I threw away the glass shards (polished sand) in the Nevada desert.      UPDATE: Primary reason for thinking more than just the UV was broken,   UV filter split into two rings, depositing the locking collar into the   lens barrel. Traces of all positive powers of a matrix are zero implies it is nilpotent Let $A$ be an $n\times n$ complex nilpotent matrix. Then we know that because all eigenvalues of $A$ must be $0$, it follows that $\text{tr}(A^n)=0$ for all positive integers $n$.  What I would like to show is the converse, that is,      if $\text{tr}(A^n)=0$ for all positive integers $n$, then $A$ is nilpotent.   I tried to show that $0$ must be an eigenvalue of $A$, then try to show that all other eigenvalues must be equal to 0. However, I am stuck at the point where I need to show that $\det(A)=0$.  May I know of the approach to show that $A$ is nilpotent? I have a web application that's branded according to the user that's currently logged in. I'd like to change the favicon of the page to be the logo of the private label, but I'm unable to find any code or any examples of how to do this. Has anybody successfully done this before?  I'm picturing having a dozen icons in a folder, and the reference to which favicon.ico file to use is just generated dynamically along with the HTML page. Thoughts? Maybe this is an easy question, maybe not.  I have a select box where I hardcode with width. Say 120px.    &lt;select style="width: 120px"&gt;   &lt;option&gt;REALLY LONG TEXT, REALLY LONG TEXT, REALLY LONG TEXT&lt;/option&gt;   &lt;option&gt;ABC&lt;/option&gt; &lt;/select&gt;     I want to be able to show the second option so that the user can see the full length of the text.  Like everything else.  This works fine in Firefox, but doesn't work with Internet Explorer6. Defragmenting an SSD drive is a bad idea and Windows 7 is (should be?) smart enough not to schedule defragmentation on such drives.  However, I've opened up Disk Defragmenter on my system and found, to my surprise, that my SSD has indeed been defragmented... recently!  Then I checked the disks selected for the scheduled defrag (I have one SSD and one normal disk), and there the list correctly shows only the non-SSD drive.   MSDN forum post seems to suggest that, at least on Windows 8, defragmenting an SSD drive will just cause the TRIM command to be sent to the drive, but there's no word on what actually happens if you try to defrag an SSD drive on Windows 7 (aside from the fact that it shouldn't happen automatically).  What happens in Windows 7 if one chooses to defrag and SSD? What could possibly have been the reason my SSD drive got been defragmented?  EDIT:  I just remembered - I've moved some folders (Users and ProgramData) from my SSD drive to my normal drive using junctions.  question suggests that this shouldn't have any effects at all on the defragmentation process, but could it have an effect on the "last run" in Disk Defragmenter? I'm just going to throw this out there, but Google indexes Stack Overflow really quickly When does $\lim_{n\to\infty}f(x+\frac{1}{n})=f(x)$ a.e. fail What is the best way to call a script from another script? Making 3 points stick on a plane / flag with wind I have a flag I want to waft in the wind. I imported the shape as an SVG from Adobe Illustrator.  I converted the mesh to a curve.  It wouldn't let me make some subdivisons but it still seems to work with the cloth property.    When I press play, you can see the structure of the flag stops.  How can I make those last 3 points intact? Also the fill colour seems to have disappeared, do you know why and how I can bring it back?    Thanks  Steve  File here: Every subsequence of $x_n$ has a further subsequence which converges to $x$. Then the sequence $x_n$ converges to $x$. Proving convergence of sums: If $\sum_{n=1}^{\infty}a^2_n$ and $\sum_{n=1}^{\infty}b^2_n$ converge then $\sum_{n=1}^{\infty}a_nb_n$ converges At the end of every day you will be required to write a review.   At the end of each day you will be required to write a review.   Which one of those sentences is better if this action will repeat itself every day for longer period of time, several weeks for example, maybe even months? One Time Pad Key Distribution For multiple OTP keys, why not do this:  Key = Hash[(EC)DH Shared Secret + Counter]  The counter will increase per message, and the output of the hash will be random for each new unique input into it. What are the problems or weaknesses with this design??  EDIT: For clarification: both parties will have the shared secret from an ECDH exchange, random numbers from Pythons os.urandom for generating the ECC key Adverb between conjugated verb and infinitive? Facebook message notification showing blank message Since I updated the system to 10.11.5, the Facebook message notification is not showing message text.   Is this a bug in this software upgrade of OSX? iPhone: Detecting user inactivity/idle time since last screen touch Unary intersection of the empty set "Failed to create user" due to regular expression error I'm running Ubuntu 12.10 desktop 32 bit. Currently I have only a user, type administrator. I'd like to create another administrator user but I keep getting the following error:  Failed to create user GDBus.Error:org.freedesktop.Accounts.Error.Failed: running '/usr/sbin/adduser' failed: /usr/sbin/adduser returned an error (1): adduser: Please enter a username matching the regular expression configured via the NAME_REGEX[_SYSTEM] configuration variable.  Use the `--force-badname' option to relax this check or reconfigure NAME_REGEX.  Any suggestion is appreciated. Equation System with 3 variables "Find all the possible solutions $(x,y,z) \in$  $\Bbb R$ that satisfies the following equation system".  My teacher gave me this problem and i got some clues in how to solve it. I evaluated $1$ and $-1$ and i got these solutions $(1,-1,1)$ and $(-1,-1,-1)$. I think these are the only ones but i can't prove it.  Am i wrong?, are there more solutions?.   Thanks  $$ \left\{  \begin{array}{c} x+y-z=-1 \\  x^2-y^2+z^2=1\\  -x^3+y^3+z^3=-1 \end{array} \right.  $$ How do I create an invisible character? I cannot remember how to create an invisible character in LaTeX, i.e. I want to put a space that has the width of a particular character, say `M'. I know there is a command for this, and this is a really dumb question, but my Google-fu has failed me.