Directory Structure,if any, on the Prime
#1

I have found out from several helpful people in the HP forum,that variables can not be created "on the fly" when needed on the PRIME. I was wondering what the directory structure is on the PRIME is like.
Is the directory structure similar to the 50G.
Are variables created in a lower level directory, hidden from directories above it and closer to the HOME directory as in the 48-the 50 series.
For example:
I might use V as a variable for the volume of a cylinder in one equation and V as velocity in another equation. Can one equation be saved in a different directory so that the Solver will not confuse the two Vs?
IMHO I think the way variables are created is a step backwards.
There might be a reason for creating variables this way, but for the life of me, I can not see why. It certainly slows things down.

#2

Quote:
I have found out from several helpful people in the HP forum,that variables can not be created "on the fly" when needed on the PRIME. I was wondering what the directory structure is on the PRIME is like.
Is the directory structure similar to the 50G.
Are variables created in a lower level directory, hidden from directories above it and closer to the HOME directory as in the 48-the 50 series.
For example:
I might use V as a variable for the volume of a cylinder in one equation and V as velocity in another equation. Can one equation be saved in a different directory so that the Solver will not confuse the two Vs?
IMHO I think the way variables are created is a step backwards.
There might be a reason for creating variables this way, but for the life of me, I can not see why. It certainly slows things down.

The hope is that this will be updated so that for applications such as the solver, variables are created "on the fly." Outside of applications, however, and even back in the HP48 days, one had to create a global variable by something like:

'MYVAR' 1 STO

at some point (whether by command line or within a program) before MYVAR ever becomes a variable. The only difference was within applications such as the HP48 solver -- variables were created as needed.

As for directories... the Prime uses a different paradigm. In the current firmware, one no longer works in a given directory. Instead, the analogue to a directory is an app. And one can, of course, create custom apps by simply creating copies of existing apps and renaming them. Variables within an app live within that app's "namespace." That is, if I am running App1 and create a variable named 'myvar' then the full name of that variable is actually App1.myvar

While using App2, I can still access myvar from App1 using App1.myvar and at the same time have a "different" myvar for use within App2 -- except its full name would of course be App2.myvar instead. Within App2, though, I may leave off the prefix and just type myvar and the calculator knows to use the myvar from within App2.

This is an incomplete description, but is hopefully enough to give an decent overview of how apps are the new "containers" for user-created variables.

#3

I have not seen a directory structure. Everything seems to be stored on the same level (except for the Home view/CAS view divide), but someone else on this forum may have a better understanding.

#4

Quote:
Variables within an app live within that app's "namespace." That is, if I am running App1 and create a variable named 'myvar' then the full name of that variable is actually App1.myvar

While using App2, I can still access myvar from App1 using App1.myvar and at the same time have a "different" myvar for use within App2 -- except its full name would of course be App2.myvar instead. Within App2, though, I may leave off the prefix and just type myvar and the calculator knows to use the myvar from within App2.


Not really. Each app does have its own built-in "app vars", which work as you describe, but user-created variables do not work that way at all. They are global, and cannot use app prefixes.

Example: In the Function app, do VAR1:=1 in Home, and var2:=2 in CAS. Then go into the Advanced Graphing app, Home view. VAR1 still brings up 1, and var2 still brings up 2. In fact they return those values in all apps. Furthermore, Function.VAR1 and Function.var2 give Syntax Error, no matter what app you're in. Finally, changing their values in any app changes it for all apps; they can't have different values in different apps.

Therefore "user variables" (created in Home, and listed in Vars, User; and in Shift Mem, User Variables, up-cursor) and "CAS variables" (created in CAS, and listed in Vars, CAS; and in Shift Mem, CAS Vars) are both global, and not limited in scope to the app in which they were created.

Note: In the example above, VAR1 was spelled using uppercase letters, and var2 using lowercase letters, only because that's the default ALPHA case in Home and CAS respectively. However, both environments allow their vars to be named with letters in upper- and/or lowercase; they don't care. Using upper- and lowercase for Home and CAS respectively is only a helpful convention, not a requirement.

-Joe-

#5

Quote:


The hope is that this will be updated so that for applications such as the solver, variables are created "on the fly." Outside of applications, however, and even back in the HP48 days, one had to create a global variable by something like:

'MYVAR' 1 STO

at some point (whether by command line or within a program) before MYVAR ever becomes a variable. The only difference was within applications such as the HP48 solver -- variables were created as needed.

As for directories... the Prime uses a different paradigm. In the current firmware, one no longer works in a given directory. Instead, the analogue to a directory is an app. And one can, of course, create custom apps by simply creating copies of existing apps and renaming them. Variables within an app live within that app's "namespace." That is, if I am running App1 and create a variable named 'myvar' then the full name of that variable is actually App1.myvar

While using App2, I can still access myvar from App1 using App1.myvar and at the same time have a "different" myvar for use within App2 -- except its full name would of course be App2.myvar instead. Within App2, though, I may leave off the prefix and just type myvar and the calculator knows to use the myvar from within App2.

This is an incomplete description, but is hopefully enough to give an decent overview of how apps are the new "containers" for user-created variables.


Questions:
1.Now since new APPS can be created, are the new apps based on only existing apps with a name change or can they be created from scratch?
2.Also in the numeric Solver app as it comes with the calculator one can create equations 0-9 to solve.
If for example I create a new app Celestial Mechanics Numeric Solver app am I able to save and solve only 10 equations in that app or is the number of equations limited as a Global amount of 10?
3. Is there any overhead in the new app because an existing app or apps were used to create the new app. Does any stuff from the original app get dragged along to the newly created app?

#6

Quote:


Questions:
1.Now since new APPS can be created, are the new apps based on only existing apps with a name change or can they be created from scratch?
2.Also in the numeric Solver app as it comes with the calculator one can create equations 0-9 to solve.
If for example I create a new app Celestial Mechanics Numeric Solver app am I able to save and solve only 10 equations in that app or is the number of equations limited as a Global amount of 10?
3. Is there any overhead in the new app because an existing app or apps were used to create the new app. Does any stuff from the original app get dragged along to the newly created app?


1. As far as I know, the current firmware only allows the creation of a new app based on an existing app. In a similar way that C/C++ classes may be inherit variables and functions from previously created classes, the new app inherits everything from which it is based. As to whether we will be able to create our own apps from scratch... only time will tell.

2. I believe you currently can only solve up to 10 equations simultaneously. You may redefine the set of 10 equations without having to create a new app, though.

3. See #1; the overhead is quite minimal if not negligible.

#7

Hello,

You can create new app variables for a saved app.
They need to be created within the app program.

Copy the app that you are interested in (if you want to make a copy), make sure that this app is the current one, go int he program caalog, select the app program (the one on top normally) and enter:

EXPORT MyNewAppVariable;

back to home and you now have a new variable called MyNewAppVariable.

change the current app, and the variable "disapears" (as if you had changed directory).

You can always use the variable by fully qualifying it : MyApp.MyNewAppVariable or by going back in your app.

Cyrille

#8

Quote:


1. As far as I know, the current firmware only allows the creation of a new app based on an existing app. In a similar way that C/C++ classes may be inherit variables and functions from previously created classes, the new app inherits everything from which it is based. As to whether we will be able to create our own apps from scratch... only time will tell.

2. I believe you currently can only solve up to 10 equations simultaneously. You may redefine the set of 10 equations without having to create a new app, though.

3. See #1; the overhead is quite minimal if not negligible.


At present I do not think I will need to solve 10 equations simultaneously (YET!) I was thinking more of a set of equations related to a Chapter in a Physics text,say Kinematics or Circular Motion, that students might be able to use for homework problems or instead of a paper formula sheet for exams.
(With the capability for teacher to turn off certain apps on the calculator ,this is an interesting possibility).
I have quite a few more than 10 formulas on my 50G to check students calculations during the work up of data during the lab sessions.
It sometime amazes me that two or more students can be using the same equation to solve a probable can come up with 4 different answers at the same time. Of course they are using TI calculators and algebraic entry.They seem to have a lot of problems using parenthesis among other things.
If only 10 equations can be stored globally this severely limits this
idea.
Of course one does not worry about parenthesis when using the 50G in the RPN Mode.
Having useful equations stored on the 50G makes for fewer mistake on my part.
I have even tried to teach my students with TI calculators, with list processing capabilities, to use that feature to make many fewer mistakes when doing repetitive calculations.
It is like pulling teeth. A few minutes up front to learn this method makes for fewer moments of confusion and frustration.
Oh well!

#9

Quote:
If only 10 equations can be stored globally this severely limits this idea.

This is one thing that people don't seem to realize about the whole concept of the "aplet" or "app" or whatever the name happens to be is that they are complete self contained things that take along all data and objects important to the operation. That includes things like the formulas.

You can save an application and have a whole complete new set of formulas. Currently, this means of course only 10 per "solve", but there really is no limit to the number that can be saved in the calculator. The idea is that there is a solve for "optics", "projectile motion", and so on that each has some descriptive text in the info view, saved formulas and variables, and anything else.

TW

#10

Quote:


This is one thing that people don't seem to realize about the whole concept of the "aplet" or "app" or whatever the name happens to be is that they are complete self contained things that take along all data and objects important to the operation. That includes things like the formulas.

You can save an application and have a whole complete new set of formulas. Currently, this means of course only 10 per "solve", but there really is no limit to the number that can be saved in the calculator. The idea is that there is a solve for "optics", "projectile motion", and so on that each has some descriptive text in the info view, saved formulas and variables, and anything else.

TW


Thanks, this helps a lot in my understanding things (so far). Now I will have to try making a new app so I can see if I really do understand.
With a teacher being able to turn off different apps for an exam, he or she could turn off the solver, for say, the formulas on a previous section on Waves,that students should already know, and only let them have access to formulas, etc. used in the current chapter exam; neat!


Possibly Related Threads…
Thread Author Replies Views Last Post
  HP49G+. How to erase a directory that contains lots of stuff? J.C.Boco 6 1,736 12-16-2007, 08:43 PM
Last Post: James M. Prange (Michigan)
  HP-50g. Cant' create directory on SD-card? Bent Rosnes 3 1,297 11-17-2006, 04:47 PM
Last Post: Gene
  Data Structure on a 12C/CP -- sorting, median Katie Wasserman 2 1,107 06-17-2006, 05:53 PM
Last Post: tony(nz)
  HP17BII memory structure Tizedes Csaba ICQ#347034200 2 982 01-19-2004, 11:49 PM
Last Post: Les Bell [Sydney]
  HP49G IF-structure bug? Juergen Rodenkirchen 13 4,144 04-13-2003, 03:52 PM
Last Post: Juergen Rodenkirchen (GER)
  Re: TDS structure analysis card manual Frank Travis 0 710 12-10-2001, 12:05 PM
Last Post: Frank Travis
  Re: How to convert a library to a directory in HP48SX. paul w 0 658 01-08-2000, 04:50 AM
Last Post: paul w
  How to create a library from a directory. (USRLIB) Tod 0 696 11-17-1999, 02:40 AM
Last Post: Tod
  How to convert a library to a directory in HP48SX. tal 0 764 11-04-1999, 01:55 AM
Last Post: Tal

Forum Jump: