miloszmaki
Reputation
Top tag
Next privilege 250 Rep.
 May 24 comment Finding inverse of polynomial in a field Oh, sorry. You're right. I haven't noticed that. May 22 comment Finding inverse of polynomial in a field I think 3rd line is wrong: (x+1) = (2x)*2 + 1. Did you mean (x+1) = (x/2)*2 + 1? Of course, the following solution is wrong too. The correct solution is (x^2-x+1)/2. May 15 awarded Caucus Jun 19 awarded Teacher Jun 19 revised What is the usefulness of matrices? added 25 characters in body Jun 19 answered What is the usefulness of matrices? May 31 awarded Scholar May 31 accepted Refraction equation, quartic equation May 31 comment Refraction equation, quartic equation I've tested it and it works great! Only 10-20 iterations of bisection search is enough. I could also improve the solution using Newton's method. May 30 comment Refraction equation, quartic equation Right, converting the original equation into a polynomial introduces unwanted ambiguity. The polynomial can have as many as four roots while there's only one correct solution to the original problem. I just hoped that I could find a descent analytic solution but it turns out that a numerical method is the only way to solve the problem efficiently. May 29 awarded Commentator May 29 comment Refraction equation, quartic equation Yes, but deriving $x$ from Snell's Law gives the same result - quartic equation. In fact, my problem is to find the point of refraction of light according to Snell's Law. May 29 comment Refraction equation, quartic equation That's a good idea. Finding a root for $00$ and $f$ is continous. May 29 revised Refraction equation, quartic equation added 5 characters in body; edited tags May 29 comment Refraction equation, quartic equation Edit to my previous comment: when starting with $x=0$, it converges to $-5.7$ (which means $n=-1.33$). The correct result can be obtained starting for example with $x=1$ or $x=12.5$. Do you have any idea how to choose the starting point which guarantees the convergence and the correct result? May 29 comment Refraction equation, quartic equation Although it generally works well for $x=dh/(h+w)$, there is a problem for this. Starting with $x=25$ the result is getting close to $x=30$ while $x=30$ is not a root. The correct result can be obtained starting with $x=0$ which gives approx. $5.7$. Also I'm not sure if starting with $x=0$ always gives the correct result. May 29 comment Refraction equation, quartic equation Thank you! I will check this method if it's accurate enough. May 29 comment Refraction equation, quartic equation @joriki: Right, thanks for fixing it ;) May 28 comment Refraction equation, quartic equation @Valentin: I need a solution for $n>1$ (or at least for $n=1.33$). I'd prefer to find an exact solution. May 28 revised Refraction equation, quartic equation edited tags