HP Prime  CAS functions in Spreadsheet App  Printable Version + HP Forums (https://archived.hpcalc.org/museumforum) + Forum: HP Museum Forums (https://archived.hpcalc.org/museumforum/forum1.html) + Forum: Old HP Forum Archives (https://archived.hpcalc.org/museumforum/forum2.html) + Thread: HP Prime  CAS functions in Spreadsheet App (/thread255406.html) 
HP Prime  CAS functions in Spreadsheet App  CR Haeger  11102013 Hello, As I posted in an earlier post, I think the Spreadsheet App may be the most powerful/useful on on the Prime. It certainly seems to be able to do some things that traditional ones cannot. I spent some time in a new spreadsheet which takes an expression entered in a cell  say =x^33*x1 (in cell C3 which I named Expr1) then other cells contain CAS functions which use/refer to Expr1. Some worked and some did not. I was in Textbook, Minimum, Exact mode. These WORKED: =(Expr)', =Integral(Expr1)dx using math template/integral, =Integral(Expr1)dx using math template AND referring to named Lower/Upper limits of integration =CAS.zeros(Expr1) These had PROBLEMS: = diff(Expr1) using math template, diff() and/or toolbox/cas/calculus/differentiate = CAS.int(Expr1) using toolbox/cas/calculus/integrate = CAS.solve(Expr1,x) and =CAS.nsolve(Expr1,x)
Best,
Re: HP Prime  CAS functions in Spreadsheet App  Michael de Estrada  11102013 Tim provided a better explanation, so I've deleted my post.
Edited: 10 Nov 2013, 12:26 p.m.
Re: HP Prime  CAS functions in Spreadsheet App  Tim Wessman  11102013 When you are entering a forumula you'd like the CAS to evaluate, click the CAS menu key while editing the formula. The CAS parser/evaluator will then evaluate those cells completely. Edited: 10 Nov 2013, 11:34 a.m.
Re: HP Prime  CAS functions in Spreadsheet App  CR Haeger  11102013 Thanks for the quick response Tim. Unfortunately, I have already tried enabling the CAS* key when entering  gives the RED CAS indicator, but some functions still not working. In all the cases below, the cell result looked similar to the cell function but without any evaluation (or incorrectly) executed. These had PROBLEMS: = diff(Expr1) using math template, diff() and/or toolbox/cas/calculus/differentiate ==> gives diff(Expr1,x) or 0 = CAS.int(Expr1) using toolbox/cas/calculus/integrate ==> gives int(Expr1,x) = CAS.solve(Expr1,x) and =CAS.nsolve(Expr1,x) ==> give solve(Expr1,x), nsolve(Expr1,x) respectively. However, CAS.zeros(Expr1) gives accurate roots. This is still a really cool application.
Best,
Edited: 10 Nov 2013, 3:30 p.m.
Re: HP Prime  CAS functions in Spreadsheet App  Michael de Estrada  11102013 Enter =solve(Expr1) with the CAS toggle set.
Re: HP Prime  CAS functions in Spreadsheet App  CR Haeger  11112013 THANKS! Works great now. I didn't know you often need to delete the "CAS." in =CAS.solve() or for other CAS functions. The Toolbox/CAS menu puts the "CAS." in automatically I guess.
Best, Edited: 11 Nov 2013, 12:05 a.m.
Re: HP Prime  CAS functions in Spreadsheet App  Michael de Estrada  11112013 You use the CAS. prefix in a nonCAS environment such as Home, but just use the function name such as solve or zeros w/o the CAS. prefix in CAS. Go to CAS and insert a CAS function such as solve or zeros from the CAS menu in the Toolbox, and you won't see the CAS. prefix, but you will in Home. The CAS. prefix indicates that you are treating the function as if it were in CAS, and when you toggle the CAS button in the Spreadsheet App, you are treating the function as if it were already in CAS, so there is no need for the CAS. prefix. The easiest way to debug a CAS expression is to first enter it in CAS before inserting it in a Spreadsheet. Also, if a CAS function is being used in a program, the easiest way to make it work is to insert it in the CAS() command, which creates a CAS environment just as the toggle button does in the Spreadsheet. For example, CAS("solve(Expr1)"). Edited: 11 Nov 2013, 12:38 a.m.
