Problem with zeros and solve in HP Prime.

01202014, 10:01 PM
(This post was last modified: 01202014 11:27 PM by Han.)
Post: #4




RE: Problem with zeros and solve in HP Prime.
zeros() works fine when used as follows:
Code: zeros("(x1)*(x2)*(x+1)*e^(1/2*x^2)","x") as does the case when e^() is replaced with exp(). You were correct to cast fd as a string. I wonder if there is an issue with your use of collect()  it too is a CAS command and requires its arguments to be cast as strings. So if d(1) is not a string, you might get nonsensical results since it will be evaluated via the Home view. Also you do not need to add two null strings when forming temp, if the goal is simply to cast fd as a string. Use one of the two shown below: Code: temp:=""+fd; // or Be aware that STRING() and string() behave slightly differently depending on Home vs CAS view. This is not an issue in a program since everything executes as if in the Home view. An easy way to track down the problem debug it. Here's an example of how to implement it. Usage: EXTREMA("x^33*x","x") Note that only minimal error checking is in place. Your actual program should check to see if complex mode is on (this may affect the results of zeros()), and other details I have left out. Code:
Graph 3D  QPI  SolveSys 

« Next Oldest  Next Newest »

Messages In This Thread 
Problem with zeros and solve in HP Prime.  John P  01202014, 11:08 AM
RE: Problem with zeros and solve in HP Prime.  Han  01202014, 03:11 PM
RE: Problem with zeros and solve in HP Prime.  John P  01202014, 04:08 PM
RE: Problem with zeros and solve in HP Prime.  Han  01202014 10:01 PM
RE: Problem with zeros and solve in HP Prime.  Michael de Estrada  01212014, 01:19 AM
RE: Problem with zeros and solve in HP Prime.  Han  01212014, 01:31 AM
RE: Problem with zeros and solve in HP Prime.  John P  01212014, 10:18 AM

User(s) browsing this thread: 1 Guest(s)