hp - Land Surveyor Forum - Land Surveyors United - Global Surveying Community2024-03-29T11:15:08Zhttps://landsurveyorsunited.com/forum/topics/feed/tag/hpHP PRIME: step 2,In to the Time Machine,Part 2https://landsurveyorsunited.com/forum/topics/hp-prime-step-2-in-to-the-time-machine-part-22017-07-30T04:08:17.000Z2017-07-30T04:08:17.000ZBilly Brookshttps://landsurveyorsunited.com/surveyors/BillyBrooks<div><p> </p><p><a href="{{#staticFileLink}}1200708580,original{{/staticFileLink}}" target="_self"><img class="align-left" src="{{#staticFileLink}}1200708580,original{{/staticFileLink}}" width="88"/></a>Hi Everyone,<br/> HP started a revolution with calculators with it's first pocket scientific calculator the HP 35.<br/> It had only 35 keys and thats how it became, the HP 35. It cost almost $400.00 dollars. A lot of money even today.and that was in the early 1970's. For many years the calculators that came next influence how some of us worked in the field or office.</p><p>Because even though they were scientific, they were also programmable. At first they did not have the capability to store or save their programs. This meant you had to reprogram them every time you wanted to run a program after it had been turned off.It was not long the C versions came out, the C stood for constance memory (CMOS).This meant your programs as in keystroke RPN were available when you needed them. With the coming out of the HP 41C models you did not have to key in all these programs yourself, because they came on a chip that could be inserted into a slot, and these were called MOD. The HP 41CX may contain more available program software then any other calculator made today. These were also used as memory extension to increase the memory of the calculator. You could also get them in Quad modes to make one port turn into 4 for memory leaving you three more free to use.As such, an HP-41 could in fact be tailored to the personal needs of the user. Hardware extensions included a <a class="mw-redirect" title="Thermal printer" href="https://en.wikipedia.org/wiki/Thermal_printer" rel="nofollow">thermal printer</a>, a magnetic card reader (HP-67 compatible via converter software), and a barcode "wand" (reader). The Hp 41C models were used by NASA in the Shuttle programs.</p><p>Then came the HP 48 G, and by the SX, GX models,surveyors, could not wait to get their hands on them. They changed Data Collection as we know it today. No longer did you just have a data collector, you had a calculator ,it play a dual role as we worked every day. For Ten years the HP 48 GX serve as a data collector and a calculator. Now there is only one pocket programmable scientific RPN calculator made today. Name after the one who started it all, on it 35th anniversary in 2007 the HP 35s. And it has a lot more keys. And now only cost $60 dollars. After the 48 ,several more models lead up to the HP 50G that used the same programming as the 48 ,which is RPL. and system RPL. It would run in RPN,but could not be program in RPN,only RPL. Today you will find a all new program language on the HP Prime.</p><p>Totally different than RPN in fact, this calculator programming is not compatible with RPL or RPL system or with programming in Saturn or ARMv4T assembly languages that includes RPN. It will run in RPN. The HP Prime's non-CAS home-screen supports textbook, algebraic and 128-level RPN (aka Advanced RPN) entry logic. However, it uses a new operating system unrelated to HP's legacy Saturn and Saturn-emulated systems, which were used on HP's previous RPN/RPL graphing calculators. It also has a CAS side, It contains features common in smart phones, with a touchscreen and apps available to put onto it. There are two sides to the calculator, a numeric home screen and a computer algebra system (CAS) home screen. The calculator can quickly switch between the two, unlike its competitors, which either have a CAS model or a non-CAS model. The CAS is based on the free and open-source Xcas/Giac 1.1.2 engine by Bernard Parisse, who was also the main developer of the CAS system integrated into the HP 49G and successors. It language is not new. The calculator supports programming in a new, Pascal-like programming language now named HP PPL (for Prime Programming Language, but originally also referred to as HP Basic) that also supports creating apps. This is based on a language introduced on the HP 38G and built in on subsequent models. It also draws form C,C++ and Java, but is more like Pascal's The next question could this be your next calculator. First lets look at what a Inverse program may look like. This is written in HP PPL.</p><p> </p><p>EXPORT AZIMUTE3(E1,N1,E2,N2,ELEV1,ELEV2)<br/> BEGIN</p><p> </p><p>LOCAL ΔN:=(N2-N1);<br/> LOCAL ΔE:=(E2-E1);</p><p> </p><p>LOCAL D:=√((ΔE)^2+(ΔN)²);</p><p> </p><p>LOCAL DN:=(ELEV1-ELEV2);</p><p> </p><p>LOCAL Bears2:=ABS(ATAN(ΔE/ΔN));</p><p> </p><p>LOCAL BEARNE:=(Bears2);<br/> LOCAL BEARSE:=(Bears2);<br/> LOCAL BEARSW:=(Bears2);<br/> LOCAL BEARNW:=(Bears2);</p><p> </p><p>PRINT();<br/> PRINT("DISTANCE (FT)");<br/> PRINT(D);</p><p> </p><p>LOCAL R1:="NE";<br/> LOCAL R2:="SE";<br/> LOCAL R3:="SW";<br/> LOCAL R4:="NW";</p><p>LOCAL RM1:=→HMS(BEARNE);<br/> LOCAL RM2:=→HMS(BEARSE);<br/> LOCAL RM3:=→HMS(BEARSW);<br/> LOCAL RM4:=→HMS(BEARNW);</p><p> </p><p>PRINT("BEAR FORWARD");<br/> IF ΔN>0 AND ΔE>0 THEN PRINT(RM1);PRINT(R1);END;<br/> IF ΔN<0 AND ΔE>0 THEN PRINT(RM2);PRINT(R2);END;<br/> IF ΔN<0 AND ΔE<0 THEN PRINT(RM3);PRINT(R3);END;<br/> IF ΔN>0 AND ΔE<0 THEN PRINT(RM4);PRINT(R4);END;</p><p> </p><p>PRINT("BEARING REV");<br/> IF ΔN>0 AND ΔE>0 THEN PRINT(RM1);PRINT(R3);END;<br/> IF ΔN<0 AND ΔE>0 THEN PRINT(RM2);PRINT(R4);END;<br/> IF ΔN<0 AND ΔE<0 THEN PRINT(RM3);PRINT(R1);END;<br/> IF ΔN>0 AND ΔE<0 THEN PRINT(RM4);PRINT(R2);END;</p><p> </p><p>LOCAL Bears1:=ABS(ATAN(ΔE/ΔN));</p><p> </p><p>LOCAL AZprov1:=(Bears1);</p><p>LOCAL AZprov2:=(180-Bears1);<br/> LOCAL AZprov3:=(180+Bears1);<br/> LOCAL AZprov4:=(360-Bears1);</p><p> </p><p>LOCAL AZ1:=→HMS(AZprov1);<br/> LOCAL AZ2:=→HMS(AZprov2);<br/> LOCAL AZ3:=→HMS(AZprov3);<br/> LOCAL AZ4:=→HMS(AZprov4);</p><p> </p><p>LOCAL CAZ1:=(AZprov1+180);<br/> LOCAL CAZ2:=(AZprov2+180);<br/> LOCAL CAZ3:=(AZprov3-180);<br/> LOCAL CAZ4:=(AZprov4-180);</p><p> </p><p>LOCAL CZ1:=→HMS(CAZ1);<br/> LOCAL CZ2:=→HMS(CAZ2);<br/> LOCAL CZ3:=→HMS(CAZ3);<br/> LOCAL CZ4:=→HMS(CAZ4);</p><p><br/> PRINT("AZIMUTE FOWARD");<br/> IF ΔN>0 AND ΔE>0 THEN PRINT(AZ1);END;<br/> IF ΔN<0 AND ΔE>0 THEN PRINT(AZ2);END;<br/> IF ΔN<0 AND ΔE<0 THEN PRINT(AZ3);END;<br/> IF ΔN>0 AND ΔE<0 THEN PRINT(AZ4);END;</p><p> </p><p>PRINT("AZIMUTE REV");<br/> IF ΔN>0 AND ΔE>0 THEN PRINT(CZ1);END;<br/> IF ΔN<0 AND ΔE>0 THEN PRINT(CZ2);END;<br/> IF ΔN<0 AND ΔE<0 THEN PRINT(CZ3);END;<br/> IF ΔN>0 AND ΔE<0 THEN PRINT(CZ4);END;</p><p> </p><p>PRINT("Difference in elev (FT)");<br/> PRINT(DN);</p><p> </p><p>END;</p><p> </p><p>that concludes the program. with END;</p><p> </p><p>Running the program.</p><p> High Light the program in the program list, then press Run, you will have six program Parameters.</p><p> </p><p>NI: 0..............E1: 0</p><p>N2: 0.............E2: 0</p><p>ELEV:2 0.......ELEV:1 0</p><p> </p><p>Next enter the coords. and elev. press ok after each to enter.</p><p> </p><p>N1:5000.0000.....E1:5000.0000</p><p>N2:5208.7103.....E2:5208.7103</p><p>ELEV:2 500.00...ELEV1:505.00</p><p> </p><p> Then after all Parameters have been entered, press ok.</p><p>Program Runs with all the variables, exe. Halt </p><p> SCREEN you will see</p><p> </p><p>DISTANCE (FT)</p><p>295.160936867</p><p>BEARING FORWARD</p><p>45.00' 00"</p><p>NE</p><p>BEARING REV</p><p>45.00' 00"</p><p>SW</p><p>AZIMUTH FORWARD</p><p>45.00" 00"</p><p>AZIMUTH REV</p><p>225.00' 00"</p><p>Difference in elev (FT)</p><p>-5.0000</p><p> </p><p> And this is my Inverse program written for the HP Prime before this date July 29,2017</p><p> And for those of you, who I hope it helps you in your programming . It can be shorten to use only </p><p>bearings or only Azimuth what ever you like. It can also be changed from ( FT) to (M) in the program lines. Next I will go over again how to write a Inverse Program using the new macro RPN programming on this same calculator. And how this is possible. </p><p> </p><p><a href="{{#staticFileLink}}1200708691,original{{/staticFileLink}}" target="_self"><img class="align-right" src="{{#staticFileLink}}1200708691,original{{/staticFileLink}}" width="293"/></a></p></div>