Directory Structure,if any, on the Prime - 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: Directory Structure,if any, on the Prime (/thread-252457.html) |
Directory Structure,if any, on the Prime - Harold A Climer - 10-07-2013 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. Re: Directory Structure,if any, on the Prime - Han - 10-07-2013 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.
Re: Directory Structure,if any, on the Prime - Helge Gabert - 10-07-2013 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.
Re: Directory Structure,if any, on the Prime - Joe Horn - 10-08-2013 Quote: 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-
Re: Directory Structure,if any, on the Prime - Harold A Climer - 10-08-2013 Quote:
Questions: Re: Directory Structure,if any, on the Prime - Han - 10-08-2013 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.
Re: Directory Structure,if any, on the Prime - cyrille de Brébisson - 10-08-2013 Hello,
You can create new app variables for a saved app. 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
Re: Directory Structure,if any, on the Prime - Harold A Climer - 10-08-2013 Quote:
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. Re: Directory Structure,if any, on the Prime - Tim Wessman - 10-08-2013 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
Re: Directory Structure,if any, on the Prime - Harold A Climer - 10-08-2013 Quote: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! |