HP 50g Takes hours to compute a convergent series - Printable Version +- HP Forums ( https://archived.hpcalc.org/museumforum)+-- Forum: HP Museum Forums ( https://archived.hpcalc.org/museumforum/forum-1.html)+--- Forum: Old HP Forum Archives ( https://archived.hpcalc.org/museumforum/forum-2.html)+--- Thread: HP 50g Takes hours to compute a convergent series ( /thread-243283.html) |

HP 50g Takes hours to compute a convergent series - Matthew Richards - 05-09-2013
I almost called HP support thinking my 50g was broken. I was following the tutorials in the manual and when I tried to find the sum of 1/k^2 from 1 to infinity, the calculator took over 15 min, so I stopped it and rebooted it. I tried again and let it go for an hour before I canceled it. I then let it run all night and today it rebooted and complained that the batteries were low. Today I tried it attached to my USB with new batteries. After 2 hours I canceled it and started to call HP, but I paused and thought about the modes that could cause this problem. I had it set to approximate mode. It hit me... This thing was trying to approximate the area under the curve using some type of Riemann's sum within who knows what error bound. I changed it to exact mode and it solved it in about 1 second. Would this thing have ever found an approximate answer? I also had the number format set to standard. If I change the format to fixed and some smaller precision, will the 50g increase the error to reduce the number of terms and reduce the computation time? I'm going to try it, but I was curious if anyone knew how this thing worked when approximating.
Re: HP 50g Takes hours to compute a convergent series - Joe Horn - 05-10-2013
Integration, not summation, is controlled by the display mode. Setting FIX to something small will not change how fast a In other words, Don't Do That. If you want the 50g to do any kind of symbolic simplification, you must be in exact mode. Otherwise it'll just crank it numerically by brute force looping, which is great for summations that exact mode doesn't know how to simplify. Need an approximate summation to infinity that can't be simplified? Then instead of using infinity, just use a number that's large enough to get a useful answer but not so large that it takes too long. Infinity never makes sense in approximate mode.
Hope that helps!
Re: HP 50g Takes hours to compute a convergent series - Eddie W. Shore - 05-11-2013
For calculations involving infinite sums, I use an upper limit of 250-500 to get a reasonable estimation - the time takes a few seconds instead of forever.
Re: HP 50g Takes hours to compute a convergent series - Thomas Klemm - 05-11-2013
Quote: That might not be enough in this case:
Kind regards Re: HP 50g Takes hours to compute a convergent series - C.Ret - 05-12-2013
Are you sure that summing 100, 500 or 600 terms makes a difference compare to an infinity ?
Looking at this graph, I am not sure ? It is looking really similar. But of course this is only my point of view (or a scaling problem).
Re: HP 50g Takes hours to compute a convergent series - Thomas Klemm - 05-13-2013
We can estimate the error by integrating 1/x
The estimated error for your examples is: 100: 0.0100You might not notice a difference by just looking at a graph.
Kind regards Re: HP 50g Takes hours to compute a convergent series - Gjermund Skailand - 05-13-2013
I suggest you try my hpgcc2 library at hpcalc.org. http://www.hpcalc.org/hp49/graphics/plotting/int1d.zip
Best regards Re: HP 50g Takes hours to compute a convergent series - Thomas Klemm - 05-13-2013
You might as well be interested in this recent thread about
Cheers
Re: HP 50g Takes hours to compute a convergent series - Thomas Klemm - 05-13-2013
From the readme.txt: Quote:
That's still ~115 days just to calculate the sum from 1 to 10
s | Zeta(s) | time(s) | exact value Sometimes it's worth to think a little on how to compute a result.
Cheers
Re: HP 50g Takes hours to compute a convergent series - Matthew Richards - 05-14-2013
This is great information, thank you. I'm sure it's very obvious to everyone that I'm very new to the calculus and advanced math world. I've been programming professionally for over 20 years and never had an opportunity to finish my undergrad. I work for a research lab and they asked me to continue my education and start working on a graduate degree. Now I'm back in school (Engineering Physics) and I'm starting from the ground up (The U of I only accepted a few of my liberal arts classes, which is probably a good thing). Most of my coworkers are engineers and they praise the HP calculators. One coworker gave me an HP-67 that I restored. I bought a 35s and a 50g and I'm slowly learning these amazing machines. I'm taking Calc 3 this summer and I've started studying vector calculus in preparation. I'm trying to augment my studies, and make it more interesting, by learning how to do the operations on the 50g and 35s and figure out how the calculator is doing what it does. I realized after I posted that the calculator probably was just doing a sum out to some number of partial sums. At first I thought it might be using an integral and then calculating the integral using a Riemann's sum, but it probably makes more sense that it's just summing the partial sums. It seems like an impossible task to have the calculator determine if the series is geometric or something else and find the radius of convergence to sum with a/(1-r). I suppose it could divide the sums to find the ratio, but that doesn't always work. Also thinking about it, I would imagine the calculator has to be doing some type of convergence tests and then finding the sum, but I'm surprised that it would just start calculating the sums to infinity without giving some error or stopping when it reaches a number that is correct within certain error. What if the series diverges (1/n) or it's an alternating series [(-1)^n/n]? Realize, I'm using a very limited amount of knowledge to figure out a black box (literally) that was designed by geniuses (like the people in this forum) with intelligence far greater than my own. Someday I hope to understand some portion of this math.
Re: HP 50g Takes hours to compute a convergent series - Thomas Klemm - 05-14-2013
Hi Matthew Good luck with your studies and I hope you enjoy them together with your multiple HP calculators. To me they were always a good help in understanding mathematical problems: writing a program to solve a problem still makes me understand it better.
You brought up a problem which obviously isn't easy to solve. While WolframAlpha provides a list of convergence tests: - The ratio test is inconclusive.
- The root test is inconclusive.
- By the comparison test, the series converges.
Kind regards |