Post Reply 
NEW 2 or 3 NODES CIRCUIT ANALYSIS HP-41C
12-24-2023, 03:20 AM (This post was last modified: 12-28-2023 09:25 PM by plore90.)
Post: #1
NEW 2 or 3 NODES CIRCUIT ANALYSIS HP-41C
Hello everyone,
here I am again to present my new program, "ACC" for Circuit Analysis in both DC and AC, for the HP-41C (with an added memory module), CV and CX. The program is composed of two program modules, ACC and COMP which must be loaded into 41 after executing SIZE 074. The program is executed with XEQ ALPHA ACC ALPHA. The program is limited to 2 and 3 NODES, 0,1,2,3. This is because I didn't want to use any application module, but by writing the code by hand, and limiting the data memory used to the maximum (1 memory MODULE to be added to the 41C). I have not carried out many data consistency checks, always to limit the required memory as much as possible. The COMP program module was adapted from the Complex Functions for the HP-41 program, published on this site by Jean-Marc Baillard. The program requires the use of the printer connected to the HP-41C but by modifying the printing instructions, it can also be used without a printer. The program listing is also provided for improvements and error checking.
The use is very simple and intuitive. The steps to follow are as follows: Number the nodes from 0 (GROUND), 1 INPUT, 2(OUTPUT), 3(OUTPUT)
1) XEQ SIZE 074, Load ACC.RAW and COMP.RAW;
2) XEQ ACC;
3) Prompt N.NODES? key-in 2 or 3 R/S
4) Prompt F0 <HZ> ? (0 for Program END) R/S
4a) key-in 1E-18 For DC Analysis with Inductors in the Circuit.
5) Prompt DF<HZ>? STEP Sweep 0 For single Frequency Analysis R/S
6) Prompt No. Step? (No. of DF) 1,2,...
7)Prompt for type of component R/C/L/G/E/x?
Key-in R for Resistor, C for Capacitor, L for Inductor, G for voltage-controlled current source and press R/S
8) Prompt for key-in component value:
R (OHM), C(Farad) L(Henry) G (gm in Siemens) and press R/S
9) Prompt for Node From Enter Node To?
Key-in Node From (for component connected from a node to node 0,
Key-in NodeFrom press ENTER, Key-in 0, and R/S)
For all other cases, Key-in From Node, press Enter, Key-in To node and press R/S
ATTENTION!!!! NODE NO. TO must be GREATER THAN NODE NO. FROM !!!! e.g. 1 ENTER 2 , for network with 2 nodes, 1 ENTER 2, 1 ENTER 3, 2 ENTER 3 for 3 nodes network. To correct a component inserted by mistake, re-enter the data of that component with a negative value and the component will be deleted. Then, if necessary, re-enter it with the correct value.
To insert the nodes of the Voltage Controlled Current Source, Enter in sequence as shown in the PROMPT: Key-In Node of the incoming current press ENTER Key-In No. of the current outgoing Node, press ENTER Key-In No. of the current node V+ press ENTER Key-In n. of the V-press R/S node. Prompt Confirm Y/N key-in Y or N and press R/S.
E.G. 0 ENTER 3 ENTER 2 ENTER 0 R/S.
For the first component, insert the RS, i.e. the internal resistance in series with the 1V voltage generator which is always considered to be applied to the input of the circuit between Node 1 and Node 0. The internal resistance of the 1 Volt voltage generator must be inserted between NODE 1 and NODE 0; That is, E.G. RS= value 1E-15OHM, Nodes FR/TO => 1 ENTER 0 and press R/S. After inserting all the components with their respective nodes, press E and press R/S to start processing. After that, the program returns to the PROMPT for requesting a frequency followed by the delta F and the number of increments and finally back to the component insertion menu, here if desired you can insert or modify the components and then press new E for a new processing or PRESS x To exit the program. All the input data plus the data resulting from the processing are printed on the output printer, which are: Magnitude V2/V1 or V3/V1 (consider that V1 is always considered = a 1), the Magnitude in DB and the Phase in GRAD. I tested the program with various example circuits and the results were excellent, but there may be some hidden BUGS. I would be very grateful if, upon discovering this, you would let me know so that I can intervene. The program is very basic but in the small amount of memory it uses there remains only one free program register. Changes and improvements are welcome by all.
Thanks
Plore90
UPDATE!!! Corrected Print "A<F>V3/V1"= with "A<F>VO/Vi"


Attached File(s)
.zip  CIRCUIT ANALYSIS PRG.zip (Size: 7.06 KB / Downloads: 4)
Find all posts by this user
Quote this message in a reply
Post Reply 




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