| Author | Comment | ||
|---|---|---|---|
Crawl and 1OOO |
|||
|
Making some progress. I transferred this post to the SD card. In the process I decided that was too
complicated, so I simplified it to
"Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon |
|||
Crawl and 1OOO |
|||
|
I played around with that factorial form a little more. I haven't really found anything new.
But anyway, if you plug n=-1 into it, you get 1/1+1/2+1/3+..., the harmonic series, so it does demonstrate -1!=infinity. (Though I haven't really demonstrated the domain of applicability of that formula; I don't think it applies for n<-1) If you take the derivative at n=0, it gives logx - 1/1-1/2-...-1/x, so it pretty explicitly gives that the derivative is negative gamma. At n=1, the derivative is (xlogx - (x-1)log(x-1)+1/(1-x) - (1/1 + 1/2 + 1/3 + 1/4 +...+1/(x-2)) Just to look at it, without having really worked through it, it looks like that might have applied the Euler Maclauren formula to get the remainder of 1-gamma. It converges a bit faster than the n=0 case. "Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon |
|||
Crawl and 1OOO |
|||
Crawl and 1OOO wrote:It can't possibly converge for n=1.5, because in that case all the terms are positive while 1.5! is negative. It might be possible that the "sum" is correct if you apply some method of summing a divergent series; I'd have to look into that. EDIT: Negative 1.5. I don't know if that was a yuku formatting thing or what. "Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon
Last Edited By: Flying Omelette
10/09/09 6:15 PM.
Edited 1 times.
|
|||
Crawl and 1OOO |
|||
|
I was thinking that a better way of having the quartic equation on a calculator could be to program it (and the cubic, and the quadratic) as a series of stack
commands (keystrokes) that give the answer, rather than trying to save the final result, or use variables.
The advantage is that the HP50g usually does not simplify or evaluate calculations done through the stack. Like, if you have X times X, it just shows X*X; it doesn't even simplify to X^2. So I thought maybe that would put less stress on the CPU. I did notice, though, just with the quadratic equation that it somehow does automatically try to simplify square roots. If you have b^2-4ac and take a square root, it for some reason rewrites it as the squareroot of b^2-4ca. It only seems to do that with squareroots, though, not cube or fourth roots. |
|||
Crawl and 1OOO |
|||
|
Here's a quirk with the HP50g CAS:
I was playing with the cubic equation solution. First you divide ax^3+bx^2+cx+d=0 by a. Then you substitute x=y+t. If you'd expand it as a taylor series in y, the y^2 term has coefficient (3at+b)/a. So if t=-b/(3a), you can cancel it. The thing is, if you try to expand the taylor series, it just hangs and hangs... for more than 15 minutes. But if you don't have the a, it does it pretty much instantly. "Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon |
|||
Crawl and 1OOO |
|||
Crawl and 1OOO wrote: I think I have a plan around this. It's weird, but what the hell. The idea is to first take a fourth root, then square it. The CAS will not evaluate this. It must be done in that order. If you square it first, then take the fourth root, it will figure out that that is a square root and try to evaluate it. Since there are no actual fourth roots in the formulas for up to the fourth degree equation, you could figure out it's really a square root. I'm finding lots of quirks with the CAS with this stuff (some of which might have been mentioned before). It leaves 0^(1/3) like that -- even in numeric mode without an explicit EVAL. So, if you divide 0/0^(1/3), it gives 0 rather than ?. Sometimes, I don't even know why, it can't evaluate complex expressions. If you try to solve certain cubic equations (with number, not symbolic, coefficients) in numeric mode the whole way through, it works. But if you enter it in symbolic mode, then try to evaluate the final answer numerically, it claims the data is of the wrong type. I'll try to get an example of that. |
|||
Crawl and 1OOO |
|||
|
Wow! I think I got the quartic solution to work! I've tried several numerical examples, and it always has given the correct answer, even when the answer
would be a decimal complex number.
AND ... this is the really important point ... it also works with purely symbolic input. It does, however, take a couple of minutes to get the answer. Not TOO bad, though; it's not like it takes 15 minutes. BUT it also can NOT, apparently, display the entire answer in "pretty print". It's just too big. Trying just results in a garbled mess. I ended up using a different trick to make it run in reasonable time with symbolic input. Instead of taking a squareroot, I pasted in, from the equation writer, the squareroot of the variable "squareroot". Then I set the squareroot variable= what I wanted to take the root of, and then substituted. This symbolically takes the squareroot, but also prevents the CAS from trying to evaluate it. Oh, for the example (from the previous post), for some reason it cannot evaluate the cube root of i numerically if you enter it first symbolically. Nor can it take (0,1.) [ie, the numerical i] to the 1/3 power. But it can take (0,1.) to the 0.33333333333333.... power. "Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon
Last Edited By: Crawl and 1OOO
10/21/09 10:07 PM.
Edited 1 times.
|
|||
Crawl and 1OOO |
|||
|
Here's the quadratic solution. Name it QUAD3.
%%HP: T(3)A(R)F(.); \<< ROT DUP ROT * 4 SWAP * ROT DUP 2 ^ ROT - '\v/SQUAREROOT' SWAP 'SQUAREROOT' SWAP = SUBST SWAP NEG SWAP - SWAP 2 SWAP * / \>> The cubic solution is named CUBIC %%HP: T(3)A(R)F(.); \<< 27 5 PICK 2 ^ * SWAP * 9 5 PICK * 4 PICK * 3 PICK * - 2 4 PICK 3 ^ * + 27 5 PICK 3 ^ * / 3 5 PICK * 3 PICK * 4 PICK 2 ^ - 3 6 PICK 2 ^ * / DUP UNROT 3 ^ 27 / NEG 1 UNROT QUAD3 3 INV ^ DUP UNROT 3 SWAP * / - 4 ROLLD DROP SWAP 3 SWAP * / - \>> And the Quartic solution %%HP: T(3)A(R)F(.); \<< 8 6 PICK * 4 PICK * 3 6 PICK 2 ^ * - 8 7 PICK 2 ^ * / 8 7 PICK 2 ^ * 4 PICK * 4 8 PICK * 7 PICK * 6 PICK * - 6 PICK 3 ^ + 8 8 PICK 3 ^ * / 256 8 PICK 3 ^ * 4 PICK * 64 9 PICK 2 ^ * 8 PICK * 6 PICK * - 16 9 PICK * 8 PICK 2 ^ * 7 PICK * + 3 8 PICK 4 ^ * - 256 9 PICK 4 ^ * / 2 4 PICK * 4 PICK 2 ^ 4 4 PICK * - 4 PICK 2 ^ NEG 1 4 ROLLD CUBIC DUP '\v/SQUAREROOT' SWAP 'SQUAREROOT' SWAP = SUBST 5 PICK 3 PICK + 5 PICK 3 PICK / - 2 / 1 UNROT QUAD3 10 ROLLD 7 DROPN SWAP 4 SWAP * / - \>> This is what you get if you run the quartic program, solving ax^4+...+e=0 %%HP: T(3)A(R)F(.); '(-\v/(XROOT(3,(-((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)-\v/(((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)^2+4*(((3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3)^3/27)))/2)-(3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3/(3*XROOT(3,(-((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)-\v/(((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)^2+4*(((3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3)^3/27)))/2))-2*((8*A*C-3*B^2)/(8*A^2))/3)-\v/(\v/(XROOT(3,(-((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)-\v/(((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)^2+4*(((3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3)^3/27)))/2)-(3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3/(3*XROOT(3,(-((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)-\v/(((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)^2+4*(((3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3)^3/27)))/2))-2*((8*A*C-3*B^2)/(8*A^2))/3)^2-4*(((8*A*C-3*B^2)/(8*A^2)+(XROOT(3,(-((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)-\v/(((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)^2+4*(((3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3)^3/27)))/2)-(3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3/(3*XROOT(3,(-((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)-\v/(((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)^2+4*(((3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3)^3/27)))/2))-2*((8*A*C-3*B^2)/(8*A^2))/3)-(8*A^2*D-4*A*B*C+B^3)/(8*A^3)/\v/(XROOT(3,(-((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)-\v/(((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)^2+4*(((3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3)^3/27)))/2)-(3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3/(3*XROOT(3,(-((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)-\v/(((-(27*((8*A^2*D-4*A*B*C+B^3)/(8*A^3))^2)-9*(2*((8*A*C-3*B^2)/(8*A^2)))*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))+2*(2*((8*A*C-3*B^2)/(8*A^2)))^3)/27)^2+4*(((3*(((8*A*C-3*B^2)/(8*A^2))^2-4*((256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)))-(2*((8*A*C-3*B^2)/(8*A^2)))^2)/3)^3/27)))/2))-2*((8*A*C-3*B^2)/(8*A^2))/3))/2)))/2-B/(4*A)' I also didn't want to just have the solutions. I decided to show the steps of the solution in Matrix form. I wanted to put some explanatory notes in, too, but it didn't let me put strings in a matrix. So, it's more of a refresher if you kind of know the solution. This is the cubic method. %%HP: T(3)A(R)F(.); [[ 'A*X^3+B*X^2+C*X+D' ] [ 'X=Y+T' ] [ 'Y^3+(3*A*T+B)/A*Y^2+((3*(A*T^2)+2*(B*T)+C)/A*Y+(A*T^3+B*T^2+C*T+D)/A)' ] [ 'T=-(B/(3*A))' ] [ 'Y^3+P*Y+Q' ] [ 'P=(3*A*C-B^2)/(3*A^2)' ] [ 'Q=(27*A^2*D-9*(A*B*C)+2*B^3)/(27*A^3)' ] [ 'Y=Z-M/Z' ] [ '(Z^6-(3*M-P)*Z^4+Q*Z^3+M*(3*M-P)*Z^2-M^3)/Z^3' ] [ 'M=P/3' ] [ 'Z^6+Q*Z^3-P^3/27' ]] And this is the quartic method. %%HP: T(3)A(R)F(.); [[ 'A*X^4+B*X^3+C*X^2+D*X+E' ] [ 'X=Y+T' ] [ 'Y^4+(4*A*T+B)/A*Y^3+(6*A*T^2+3*B*T+C)/A*Y^2+(4*A*T^3+3*B*T^2+2*C*T+D)/A*Y+(A*T^4+B*T^3+C*T^2+D*T+E)/A' ] [ 'T=-(B/(4*A))' ] [ 'Y^4+P*Y^2+Q*Y+R' ] [ 'P=(8*A*C-3*B^2)/(8*A^2)' ] [ 'Q=(8*A^2*D-4*A*B*C+B^3)/(8*A^3)' ] [ 'R=(256*A^3*E-64*A^2*B*D+16*A*B^2*C-3*B^4)/(256*A^4)' ] [ 'Y^4+P*Y^2+Q*Y+R=(Y^2+J*Y+K)*(Y^2+M*Y+N)' ] [ 'J+M=0' ] [ 'J=-M' ] [ 'P=KM^2' ] [ 'Q=M*(K-N)' ] [ 'R=K*N' ] [ 'K^2+N^2+2*K*N=(P+M^2)^2' ] [ 'K^2+N^2-2*K*N=(Q/M)^2' ] [ '4*K*N=(4*R=(P+M^2)^2-(Q/M)^2)' ] [ 'M^6+2*P*M^4+(P^2-4*R)*M^2-Q^2=0' ] [ 'N=(P+M^2-Q/M)/2' ]] "Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon |
|||
Crawl and 1OOO |
|||
|
One thing that seems to be becoming common is calculator applications for the iPhone.
There is an HP48 emulator for the iPod touch that is available for free. It looks kind of neat.
To me, the awesome thing about the HP49/50 is the CAS, and I don't think the 48's is as advanced, but then again the 49/50's was based on fan-written software for the 48 (I think HP later officially hired those fans). I don't know if that 48 software is available for this emulator or not. On the other hand, this CAS that is available for the iPhone is, as far as I can tell, based on the HP CAS. However, I think all you get is the CAS; you may not get other nice HP features like RPN or the equation writer. HP themselves have released some calculator software. There's the 12C and 15C for the iPhone. That has gotten some people's hopes up for a real physical 15C rerelease (which might not be quite as pie-in-the-sky as it would seem, since they still have factories making real physical 12C's, and the hardware is mostly identical). They also have a 35s emulator for Windows. Not quite sure about the point of that, since it's just a little more to get a real 35s. I like emulators for calculators that let you transfer data, since you can write a program on a calculator and execute it much faster on a PC. But a 35s doesn't let you do that. |
|||
Crawl and 1OOO |
|||
|
My brother just called me at work to solve a right triangle problem. That was surreal.
"Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon |
|||
Crawl and 1OOO |
|||
Crawl and 1OOO wrote: This can be a terrible random number routine. For instance, if you seed it with 0.1, then the random numbers are 0.1, 0.3, 0.9, 0.7, 0.1.... It repeats with a period of only 4 numbers. But I tried utilizing this routine with Excel and Qbasic. There are numeric errors that turn it to 0.1, 0.3, 0.9, 0.8333, 0.0534, 0.1943, 0.122, 0.771, 0.851, 0.583... So, errors improve the routine. "Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon |
|||
Crawl and 1OOO |
|||
|
You can simulate the calculator's routine with Qbasic by using LONG integers rather than floating point. With a seed of 0.001, you can see that the random
numbers fail the two dimensional spectral test (that is, if you plot ordered pairs of random numbers, (rand1, rand2), the data eventually fills in a series of
parallel lines). On the other hand, with errors, even the 0.1 seed passes the 2D spectral test (the ordered pairs fill the unit square uniformly)
Back to the quartic equation. Due to Yuku formatting, there was at least one error in the stuff I posted earlier. Therefore, I uploaded all the files to a directory. For the sake of comparison, I also uploaded someone else's quadratic and cubic routines (equa2, equa3), which were supposed to be (and, well, are) more transparent than mine. The reason was to make a point, which was that I sacrificed transparency for the ability to solve the quartic -- at all, sort of, but also in reasonable time. Equa4 uses my quartic program, but calls equa2 and equa3 rather than my cubic and quadratic routines. Some timed tests... The general quartic: 3 minutes, 21 seconds. I think this could be a reasonable time for a pocket calculator. On an emulator, the speed probably depends on the PC running it, but with one test with EMU48, it finished in about 9 seconds. The depressed quartic (ie., x^4+p.x^2+q.x+r=0): 11 seconds. I think that's quite fast! And it can be viewed in pretty print through the equation editor. The general cubic: Almost instantly (at least less than 2 seconds). For the other programs: The general cubic with Equa3: About 23 seconds. The depressed quartic with Equa4: Over 15 minutes on a real calculator, at which point I aborted. I confirmed with EMU48 that it can be solved. The general quartic with Equa4: On EMU48, it eventually stopped with message "INSUFFICIENT MEMORY". What about Mathematica? Here's the output for the general quartic.
And the plain text output (assuming no Yuku bugs) \!\(x \[Rule] \(-\(b\/\(4\ a\)\)\) - 1\/2\ \[Sqrt]\((b\^2\/\(4\ a\^2\) - \(2\ c\)\/\(3\ a\) + \((2\^\(1/3\)\ \ \((c\^2 - 3\ b\ d + 12\ a\ e)\))\)/\((3\ a\ \((2\ c\^3 - 9\ b\ c\ d + 27\ \ a\ d\^2 + 27\ b\^2\ e - 72\ a\ c\ e + \[Sqrt]\((\(-4\)\ \((c\^2 - 3\ b\ d + \ 12\ a\ e)\)\^3 + \((2\ c\^3 - 9\ b\ c\ d + 27\ a\ d\^2 + 27\ b\^2\ e - 72\ a\ \ c\ e)\)\^2)\))\)\^\(1/3\))\) + \(\(1\/\(3\ 2\^\(1/3\)\ a\)\)\((\((2\ c\^3 - 9\ \ b\ c\ d + 27\ a\ d\^2 + 27\ b\^2\ e - 72\ a\ c\ e + \[Sqrt]\((\(-4\)\ \ \((c\^2 - 3\ b\ d + 12\ a\ e)\)\^3 + \((2\ c\^3 - 9\ b\ c\ d + 27\ a\ d\^2 + \ 27\ b\^2\ e - 72\ a\ c\ e)\)\^2)\))\)\^\(1/3\))\)\))\) - 1\/2\ \[Sqrt]\((b\^2\/\(2\ a\^2\) - \(4\ c\)\/\(3\ a\) - \((2\^\(1/3\)\ \ \((c\^2 - 3\ b\ d + 12\ a\ e)\))\)/\((3\ a\ \((2\ c\^3 - 9\ b\ c\ d + 27\ \ a\ d\^2 + 27\ b\^2\ e - 72\ a\ c\ e + \[Sqrt]\((\(-4\)\ \((c\^2 - 3\ b\ d + \ 12\ a\ e)\)\^3 + \((2\ c\^3 - 9\ b\ c\ d + 27\ a\ d\^2 + 27\ b\^2\ e - 72\ a\ \ c\ e)\)\^2)\))\)\^\(1/3\))\) - \(\(1\/\(3\ 2\^\(1/3\)\ a\)\)\((\((2\ c\^3 - 9\ \ b\ c\ d + 27\ a\ d\^2 + 27\ b\^2\ e - 72\ a\ c\ e + \[Sqrt]\((\(-4\)\ \ \((c\^2 - 3\ b\ d + 12\ a\ e)\)\^3 + \((2\ c\^3 - 9\ b\ c\ d + 27\ a\ d\^2 + \ 27\ b\^2\ e - 72\ a\ c\ e)\)\^2)\))\)\^\(1/3\))\)\) - \((\(-\(b\^3\/a\^3\)\) \ + \(4\ b\ c\)\/a\^2 - \(8\ d\)\/a)\)/\((4\ \[Sqrt]\((b\^2\/\(4\ a\^2\) - \(2\ \ c\)\/\(3\ a\) + \((2\^\(1/3\)\ \((c\^2 - 3\ b\ d + 12\ a\ e)\))\)/\((3\ a\ \((2\ c\^3 - 9\ b\ \ c\ d + 27\ a\ d\^2 + 27\ b\^2\ e - 72\ a\ c\ e + \[Sqrt]\((\(-4\)\ \((c\^2 \ - 3\ b\ d + 12\ a\ e)\)\^3 + \((2\ c\^3 - 9\ b\ c\ d + 27\ a\ d\^2 + 27\ b\^2\ \ e - 72\ a\ c\ e)\)\^2)\))\)\^\(1/3\))\) + \(\(1\/\(3\ 2\^\(1/3\)\ \ a\)\)\((\((2\ c\^3 - 9\ b\ c\ d + 27\ a\ d\^2 + 27\ b\^2\ e - 72\ a\ c\ e + \ \[Sqrt]\((\(-4\)\ \((c\^2 - 3\ b\ d + 12\ a\ e)\)\^3 + \((2\ c\^3 - 9\ b\ c\ \ d + 27\ a\ d\^2 + 27\ b\^2\ e - 72\ a\ c\ \ e)\)\^2)\))\)\^\(1/3\))\)\))\))\))\)\) And the depressed solution
and plain text output. \!\(x \[Rule] 1\/2\ \[Sqrt]\((\(-\(\(2\ p\)\/3\)\) + \(2\^\(1/3\)\ \((p\^2 + 12\ r)\)\)\ \/\(3\ \((2\ p\^3 + 27\ q\^2 - 72\ p\ r + \@\(\(-4\)\ \((p\^2 + 12\ r)\)\^3 + \ \((2\ p\^3 + 27\ q\^2 - 72\ p\ r)\)\^2\))\)\^\(1/3\)\) + \((2\ p\^3 + 27\ \ q\^2 - 72\ p\ r + \@\(\(-4\)\ \((p\^2 + 12\ r)\)\^3 + \((2\ p\^3 + 27\ q\^2 - \ 72\ p\ r)\)\^2\))\)\^\(1/3\)\/\(3\ 2\^\(1/3\)\))\) - 1\/2\ \[Sqrt]\((\(-\(\(4\ p\)\/3\)\) - \(2\^\(1/3\)\ \((p\^2 + 12\ r)\)\ \)\/\(3\ \((2\ p\^3 + 27\ q\^2 - 72\ p\ r + \@\(\(-4\)\ \((p\^2 + 12\ r)\)\^3 \ + \((2\ p\^3 + 27\ q\^2 - 72\ p\ r)\)\^2\))\)\^\(1/3\)\) - \((2\ p\^3 + 27\ q\ \^2 - 72\ p\ r + \@\(\(-4\)\ \((p\^2 + 12\ r)\)\^3 + \((2\ p\^3 + 27\ q\^2 - \ 72\ p\ r)\)\^2\))\)\^\(1/3\)\/\(3\ 2\^\(1/3\)\) - \((2\ q)\)/\((\[Sqrt]\((\(-\ \(\(2\ p\)\/3\)\) + \(2\^\(1/3\)\ \((p\^2 + 12\ r)\)\)\/\(3\ \((2\ p\^3 + 27\ \ q\^2 - 72\ p\ r + \@\(\(-4\)\ \((p\^2 + 12\ r)\)\^3 + \((2\ p\^3 + 27\ q\^2 - \ 72\ p\ r)\)\^2\))\)\^\(1/3\)\) + \((2\ p\^3 + 27\ q\^2 - 72\ p\ r + \ \@\(\(-4\)\ \((p\^2 + 12\ r)\)\^3 + \((2\ p\^3 + 27\ q\^2 - 72\ p\ r)\)\^2\))\ \)\^\(1/3\)\/\(3\ 2\^\(1/3\)\))\))\))\)\) The main thing I notice here is that the Mathematica output is shorter. It managed to find a simplification to write it with fewer characters. |
|||
Crawl and 1OOO |
|||
|
Wow, you can do that online now.
"Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon |
|||
Crawl and 1OOO |
|||
|
Going back to this
post, I was thinking about sums on the 506w. It seemed like it should be possible ... and it kind of is.
That's sort of complicated, but if the difference between a and b is large enough, then it can save time to do it that rather than summing manually. It's based on knowing that the 506w uses Simpson's rule to integrate (as opposed to, say, using the Euler Machlaurin formula or something). Oh, I guess I should explain the integral notation. (b-a)/2 is the third argument you give the calculator for the integral after the two limits. For a product, like the linked post, you just sum logs. |
|||
Crawl and 1OOO |
|||
|
Going back, it looks like there is a problem with the adding routine. Adding "+10000E+000" to "-99950E-001" gives "+50E-004".
It should be "+50000A-004"; ie., some zeros need to be appended.
"Of the three ways in which men think that they acquire a knowledge of things--authority, reasoning, and experience--only the last is effective and able to bring peace to the intellect." -Roger Bacon |
|||
| Affiliates Websites & Yuku/Ezboards
YUKU & EZBOARDS
WEBSITES
|