hp-prime solver and variable name



#24

About the hp-prime solver in APPS,

If i write this formulla : X = 2*3.14*F*C

i can deal with the capacitive impedance (XC)

but

the correct formulla is not X = but XC.

the problem is :

i can't write in the hp prime solver XC = because the prime understand X*C =.

is there a solution ?


#25

Hi,

You could try lowercase c in Home view. Works on my calculator

Cheers,

Terje


#26

It doesn't work, but i have understood this :

If in the solver i try to write xc =, even in lowercase, i have an error message

but

if, before to go to the solver, i create/declare an variable(real) named xc, it works.

in the same way, i can create a real name Vout and write on the solver this formulla :

Vout = 1.25*(1+R/220)

this is for an LM317 regulator

SO !!!!! strangelly first i have to create a variable with the wished name to be allowed to use it in the solver in a second time

is this the HP-PRIME reality ??


#27

It's a bit frustrating.

To get around it, start up the SOLVE app and then press Program, and then Edit. Delete the APP program template there, and then add the line
EXPORT XC, X_C, x_C, X_c, X_L;
including those variables you wish to use.

Go back to the APPS screen and SAVE the SOLVE app under a new name - Reactance, perhaps.

Start your new app. You will find that the variables can now all be used - XC won't be X*C any more.

I don't know whether there's another way to do this, but it's worked for me with a set of projectile equations (u_x, u_y, v_x, v_y, and so on).

It all actually works rather well, but it is a nuisance setting it up. On the other hand, I end up with an App that I can keep and use without cluttering up the main SOLVE app. Then again, where am I going to keep all of these different solver apps? There aren't any folders available ....

Hope this helps.

Nigel (UK)

Note: these EXPORTED variables can be accessed from the Home screen as app variables (Reactance.XC, etc)

Edited: 9 Dec 2013, 7:56 a.m.


#28

Thanks Nigel. I'll add that to my knowledge base of undocumented/poorly documented features of the Prime. I've been playing with my old 50g alongside the new Prime, and continue to be amazed at how hp has managed to make things that used to be relatively simple and intuitive into an obscure and illogical mess. The plain fact is that the 50g can do everything that I need and that the Prime adds nothing more than a nicer front and back end interface with modern processing speed. About the only feature that the Prime brings that is a real improvement is the Spreadsheet App, and even then it is plagued with bugs and missing critical features.


#29

There is nothing to add.

#30

Yes, sorry you have to define the variable first (in my trial uppercase X, lowercase c).

What tricked me was, if you have already entered the function you can delete the variable later (which I did). If you then open the Num view it will ask you if you want to define the new variable. However if you try to edit in Symb view you get an error message. I can find no way of entering the function without declaring the variable first.

Something apparently learned :-)


#31

thank's for your help, but, once more, the hp-prime is for me a deception, too complicate to use it.
i imagine the young student in the classroom


#32

But HP don't realize this. Like i said: The Prime is (in this manner) unsuitable for students/education.

Edited: 9 Dec 2013, 9:18 a.m.

#33

In HP's defence if you check the user manual it says
<<<

In addition to the built-in variables, you can use one or more variables you created yourself (either in Home view or in the CAS). For example, if you've created a variable called ME, you could include it in an equation such as this: Y 2 = G2 + ME.

>>>

I.e. you need to pre define additional variables to the built-in ones.
New users of the calculator might pay more attention to the manual than us who has tried all before :-) so they may not be as confused?

Cheers,

Terje


#34

But why not be able to create new variables on the fly within the Solver or Function Apps as they are needed. Instead, you have this convoluted methodology that makes all this far more complex that it needs to be. If you inadvertently attempt to define a reserved name as a variable, you just get a error message like "cannot use reserved name as user defined variable name."


#35

Michael, many high-level structured programming languages require the programmer to explicitly define every variable prior to use. This is really a good thing, because it prevents you from coding something like NUM_RECS = NUM_RECS + 1 and later in your code, PRINT NM_RECS and you wonder why NM_RECS is always zero when you know you processed 1000 records. Most languages I used when programming mainframes were like that.

I agree, though. On a hobbyist calculator, it's more of a hindrance than a help.


#36

Hi Don,

I've done tons of FORTRAN programming in the distant past on mainframes and understand all that, but this is not the issue here. We have these Apps which should be smart enough to automate all this stuff. I didn't have these kinds of problems with my 50g.

#37

On the HP-50g my working folder quickly gets cluttered up with the variables from my most recent use of the Solver. (Financial calculations are particularly bad in this respect.) I know that these variables can be purged, but somehow I never get around to it.

On the Prime, if I want to use anything other than A-Z as a variable I have to create it as an app variable in the Solver, either in the main app or in a renamed copy of the Solver. This avoids the "variable clutter" problem of the HP-50g but at the cost of some inconvenience.

Perhaps, by default, the Solver could create undefined variables as Solver app variables? The clutter problem would be restricted to the Solver, while ease of use would be greatly improved.

Nigel (UK)


#38

On the 50g you can create subdirectories for each problem to avoid this clutter. The main VAR home directory simply contains the names of the subdirectories, and the first key in each subdirectory is named BACK, which contains the program <<HOME>>, that returns you to the Home main directory.

Edited: 9 Dec 2013, 10:47 a.m.


#39

'BACK' <<HOME>>: a nice trick. Thanks for that!

#40

Quote:
On the 50g you can create subdirectories for each problem to avoid this clutter. The main VAR home directory simply contains the names of the subdirectories, and the first key in each subdirectory is named BACK, which contains the program <<HOME>>, that returns you to the Home main directory.

Or, create a custom menu at the top directory. Just save:

{ UPDIR HOME } 'CST' STO

Now you don't have to recreate 'BACK' in each subdirectory. Just go to the custom menu and use the shortcuts there.


#41

Quote:
Or, create a custom menu at the top directory. Just save:

{ UPDIR HOME } 'CST' STO

Now you don't have to recreate 'BACK' in each subdirectory. Just go to the custom menu and use the shortcuts there.


Why not just use the built-in HOME key? Just press and hold down the left-shift key, then press VAR. Voilà: HOME. No programming or custom menus or key assignments needed.

#42

Quote:

.....No programming or custom menus or key assignments needed.




Well where's the fun in that :)
#43

Hi Michael,

I do not disagree with you, all I am saying is that newcomers to the HP world may have less expectations of how it is "supposed" to work and look more for guidance in the manual. Being able to create variables on the fly would be far better than my understanding of the current system suggests.

Cheers,

Terje

#44

Capacitive Reactance is the reciprocal of (2*pi*f*C)


#45

thomas !!!!!!!

it's EXACTLY what i've written

i CHOOSE to use 3.14 instead of PI to be more clear in my details problems because of PI ....P*I.

just because of this

Edited: 9 Dec 2013, 1:23 p.m.


#46

OHHHH YESSSSS you are right,

let me explain, on the hp48gx we can deal easyly with our own formulla.

on a previons thread CYRILLE xeplain me in prime i can't deal with more than 10 equation at a time.

the solution was to copy the APPS solver each time i need a new formulla group.

In my actual group i write equation for inductor and capacitor, and you are right i do in my example a big mix, a big soup
excuse me.
fab


Possibly Related Threads...
Thread Author Replies Views Last Post
  Solver issue with HP 17BII - different from 19BII Jeff Kearns 13 496 11-28-2013, 02:36 AM
Last Post: Don Shepherd
  HP Prime Triangle solver BruceH 29 1,159 11-28-2013, 12:03 AM
Last Post: Dale Reed
  HP prime: linear solver app Alberto Candel 1 197 11-21-2013, 01:57 AM
Last Post: Michael Carey
  Prime: Scope of Variable and functions within programs Thomas Chrapkiewicz 9 419 11-18-2013, 03:39 PM
Last Post: Thomas Chrapkiewicz
  HP Prime: Linear Solver app bug BruceH 0 130 11-15-2013, 06:36 PM
Last Post: BruceH
  HP Prime - Variable problem bluesun08 12 569 11-07-2013, 11:34 AM
Last Post: bluesun08
  HP Prime Solver Variables Issue Anibal Morones Ruelas 8 487 10-19-2013, 09:45 AM
Last Post: Harold A Climer
  PRIME Lockup after pressing Enter key in Solver. Harold A Climer 13 570 10-14-2013, 12:05 PM
Last Post: Tim Wessman
  HP Prime triangle solver oddity BruceH 0 129 10-13-2013, 09:08 PM
Last Post: BruceH
  Using units in Numeric Solver Harold A Climer 1 170 10-13-2013, 10:44 AM
Last Post: Tim Wessman

Forum Jump: