Post Reply 
(48) Closest Standard-Resistor Values
06-26-2019, 11:00 PM
Post: #2
RE: (48) Closest Standard-Resistor Values
I saw that article years ago and thought the programs were very useful. I did not think that highly of the programming style of Listing 1 however and I took the liberty of rewriting it. I will now take the further liberty of posting my revision here. For HP-48G and later.

Code:

\<< DUP MANT { 1. 1.1 1.2 1.3 1.5 1.6 1.8 2. 2.2 2.4 2.7 3. 3.3 3.6 3.9 4.3 4.7 5.1 5.6 6.2 6.8 7.5 8.2 9.1 10. } \-> r m L1
  \<< L1 1.
    \<< m >
    \>> DOLIST 1. POS DUP 'L1' SWAP GET m / SWAP 1. - 'L1' SWAP GET m / INV DUP2 < { DROP r * } { SWAP DROP r SWAP / } 
IFTE -2. RND
  \>>
\>>
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: (48) Closest Standard-Resistor Values - John Keith - 06-26-2019 11:00 PM



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