Can I use long(er) variable names?
06-02-2020, 08:47 PM
Post: #1
 davidjackson0513 Junior Member Posts: 11 Joined: May 2020
Can I use long(er) variable names?
Howdy,

How do I use variable names like "FOCAL" or "RATIO"? When I tried this I get F*O*C*A*L?
06-02-2020, 09:43 PM (This post was last modified: 06-02-2020 09:44 PM by victorvbc.)
Post: #2
 victorvbc Member Posts: 70 Joined: Jun 2019
RE: Can I use long(er) variable names?
Hi.

I assume you want to create user variables in HOME mode. Use something like this:

Code:
3.14â–¶RATIO

Then there will be a message box asking if you want to create said variable.

If you try to use these all caps var names without declaring first, the Prime interprets it as implied multiplication.
06-02-2020, 10:09 PM
Post: #3
 davidjackson0513 Junior Member Posts: 11 Joined: May 2020
RE: Can I use long(er) variable names?
Thanks for you reply. That cleans things up a little.
Can I do this: RATIO = FOCAL/DIAMETER

David
06-02-2020, 11:05 PM
Post: #4
 pinkman Senior Member Posts: 387 Joined: Mar 2018
RE: Can I use long(er) variable names?
Once you created you variables FOCAL and DIAMETER:

RATIO:=FOCAL/DIAMETER will define a variable and assign a value for it, without being updated each time you change FOCAL or DIAMETER.
You can create a function (shift Define) named RATIO and give the expression FOCAL/DIAMETER in the function field. Then uncheck the two checkboxes and now in home you can use RATIO, it will be updated each time you modify FOCAL or DIAMETER.

If you need to solve one of the three values knowing two of them, delete your previous RATIO function, create a variable named RATIO, then use the Solver App with the expression RATIO=FOCAL/DIAMETER
06-24-2020, 11:16 PM
Post: #5
 davidjackson0513 Junior Member Posts: 11 Joined: May 2020
RE: Can I use long(er) variable names?
Thanks to both of you. Both replies are helpful.
 « Next Oldest | Next Newest »

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