▼
Posts: 14
Threads: 8
Joined: Oct 2013
Personal:
I have two problems so far at HP Prime: the first is programmatically. So far I have not received a solution to the problem of using more than 12 external variables in program, easily held by HP 50 g. If anyone has a simple program that uses more than 12 external variables and can make it, I thank you in advance.
The second problem is that now the machine turns off when I touch the key Apps. I reset the machine, restart playing simultaneously On keys and Symb and the problem continues.
I await help.
Thank You
David
▼
Posts: 709
Threads: 104
Joined: Nov 2005
Try running your program from the command line.
Example: MYPROG(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16)
If you want to run the program by pressing RUN from the program catalog then it will complain about invalid input. I think that this may very well be a bug.
As for the Apps key issue, try to reset calculator.
Edit: fixed a iPhone mistranslation
Edited: 5 Nov 2013, 10:44 a.m.
Posts: 1,665
Threads: 142
Joined: Jan 2009
Quote:
The second problem is that now the machine turns off when I touch the key Apps.
This also happened to mine, and your only solution is to re-format the flash drive to recover the operating system. If you haven't already done so, do a full backup of the calculator to your pc using the connectivity kit, because re-formatting will erase all your programs and data. Reset your calculator first with the button at the back to see if this fixes the problem, although it didn't on mine. Shut the calculator off, then simultaneously push C F O then ON, then release ON, and this should boot the calculator into its internal utility mode, where you can find the format command in one of the sub-menus.
You can read more about this
here.
Edited: 5 Nov 2013, 10:02 a.m.
▼
Posts: 14
Threads: 8
Joined: Oct 2013
Ok Michael.
Solved the problem of the Apps key. Thank you very much, the machine is functioning normally.
More help: how to enter a program at the command line and then run it? Typed as guidance and did not work. Can indicate where has this guidance in the guide or give me the complete command line?
Thank You
David
▼
Posts: 709
Threads: 104
Joined: Nov 2005
Quote:
Ok Michael.
Solved the problem of the Apps key. Thank you very much, the machine is functioning normally.
More help: how to enter a program at the command line and then run it? Typed as guidance and did not work. Can indicate where has this guidance in the guide or give me the complete command line?
Thank You
David
Type this code in using the program editor
EXPORT MYPROG(x1,x2,x3,x4,x5,x6,x7,x8,x9,x10,x11,x12,x13,x14,x15,x16)
BEGIN
RETURN(x1+x2+x3+x4+x5+x6+x7+x8+x9+x10+x11+x12+x13+x14+x15+x16)
END;
Exit the program editor (press the [Home] key). Now type:
MYPROG(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16)
and the display should show 136. Avoid using capital letters like A, B, C, D, ... , Y, Z as local variables because these may conflict with the built-in global variables.
Edited: 5 Nov 2013, 12:19 p.m.
▼
Posts: 14
Threads: 8
Joined: Oct 2013
Guys,
Good night:
Thanks for the info. I will try to adapt my programs in this way, gradually, while HP Prime is not on the same level, in terms of programming, compared the HP 50 g. Until then, I will continue to use my "old" HP 50 g.
Once again thank you.
David
▼
Posts: 1,278
Threads: 44
Joined: Jul 2007
The limit is 16, which is actually very, ridiculously large. If you are regularly finding yourself wanting to take 16+ arguments for a single function you might want to think about reworking your programs. That is usually a really bad idea to have so many parameters for a single function.
TW
Edited: 5 Nov 2013, 5:44 p.m.
▼
Posts: 14
Threads: 8
Joined: Oct 2013
Dear Tim Wessman:
In my field work with my HP 50 g, in visit to industries, I analyze a water sample with more than 25 elements. These elements are inserted in a program in HP that I developed and already separates the cations of the anions. This information is sent to another program that, if trigger it, it makes the ion balance and calculates the Langelier index, the Total hardness and alkalinity of the water. I can, in the field, in another program that I developed at HP, the volume size of cationic and anionic resins needed for deionization of water.
Thus, it's not ridiculously large number of variables of the program and Yes, the soft machine HP Prime that needs to be improved to at least behave the same programs that run on HP50g.
Thanks for externalize your opinion, hoping that continue to assist clearing out our doubts about HP Prime.
David
▼
Posts: 193
Threads: 10
Joined: Mar 2008
hello,
Cool work!
Here is something that you could do to solve the problem. Use lists.
ie, enter your input as a { list of numbers } or even an [array of numbers] if some math functions make sense on your inputs.
You can then use list/array manipulation to do stuff on your input and simplify your program.
look also at the EXECON function which allows to perform stuff on lists.
Cyrille
Posts: 275
Threads: 38
Joined: Jul 2007
Quote:
So far I have not received a solution to the problem of using more than 12 external variables in program, easily held by HP 50 g.
The only thing I can suggest as a work around is that you receive a list as a single parameter and then take values from there.For example:
EXPORT MYPROG(x1)
BEGIN
LOCAL y1;
y1 := x1(1)+ x1(2)+ x1(3)+ x1(4)+ x1(5)+ x1(6)+ x1(7)+ x1(8)+ x1(9)+ x1(10)+ x1(11)+ x1(12)+ x1(13)+ x1(14)+ x1(15)+ x1(16);
RETURN(y1);
END;
and call it using:
MYPROG({1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16})
Edited: 5 Nov 2013, 1:14 p.m.
▼
Posts: 709
Threads: 104
Joined: Nov 2005
The problem is that running a program from the program catalog automatically creates an input screen for programs which require inputs. However, there are caveats.
The first is apparently the issue of having a limit of only 10 input values even if the program specifically requires more than 10 inputs.
The second issue is that the inputs must necessarily be real numbers (again, this is only if you run the program from the catalog) because the local variables are initialized to real values, and the input form expects the same type.
There are no issues that I see when I run this from the command line. The bug is in the way the "Run" menu option handles the execution of programs that require arguments.
|