Post Reply 
PPL INPUT function
04-12-2014, 01:23 PM
Post: #7
RE: PPL INPUT function
Thank you Tim for the help and tips. The following version does what I need. I now think there's definitely a bug in the INPUT function when used with global variables. I also figured out how to copy the program from the emulator to here:

Code:

LOCAL e0,i0,l0;
EXPORT BUCKLE3()
BEGIN
e0:=E;
i0:=I;
l0:=L;
K:=1;
INPUT({e0,i0,l0});
E:=e0;
I:=i0;
L:=l0;
F:=E*I*π²/(K*L)²;
RETURN F;
END;

It seems that maybe the INPUT function isn't updating values (in or out?) properly outside the program, perhaps until something else happens, and it's resulting in the wrong values being used at times....?

I need the global variables coming in and out because I'm using this program at work to design some beams and make sure they don't buckle and destroy our machine or injure (kill?) someone. I often run the program several times with some or all of the same values while I'm checking loads or converging on a size of a beam. So as you can see, I just forced the global to local variable copying to be done outside the INPUT function and then I use only local variables inside the INPUT function.

I also noticed you didn't need the LOCAL command. I didn't know you could leave that out. Thanks again for your help, and I presume the INPUT function will be repaired in the next Firmware update (unless I still don't understand what's up).

-Jeff
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
PPL INPUT function - orcinus - 04-04-2014, 01:35 AM
RE: PPL INPUT function - Karl-Ludwig Butte - 04-04-2014, 06:33 AM
RE: PPL INPUT function - DrD - 04-04-2014, 09:39 AM
RE: PPL INPUT function - orcinus - 04-04-2014, 01:48 PM
RE: PPL INPUT function - jlastofka - 04-12-2014, 04:48 AM
RE: PPL INPUT function - Tim Wessman - 04-12-2014, 05:51 AM
RE: PPL INPUT function - jlastofka - 04-12-2014 01:23 PM
RE: PPL INPUT function - Han - 04-13-2014, 02:17 AM
RE: PPL INPUT function - jlastofka - 04-13-2014, 03:04 AM
RE: PPL INPUT function - Han - 04-13-2014, 03:41 AM
RE: PPL INPUT function - jlastofka - 04-13-2014, 04:51 AM
RE: PPL INPUT function - Joe Horn - 04-13-2014, 06:37 AM



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