To run return ratio (RR) for single-ended feedback ckts: First, on an ECE Linux computer, copy (use the command 'cp') to a directory of yours the files: /home/hurst/212/rr_se/run_rr.sh , /home/hurst/212/rr_se/rrv_se.in , /home/hurst/212/rr_se/rri_se.in , and /home/hurst/212/rr_se/rr_se.sh . Do 'chmod 0755 *.sh' to make the '.sh' shell scripts executable. For a test run, also copy /home/hurst/212/rr_se/ckt_for_rr and /home/hurst/212/rr_se/MOS_models_0.4um_approx . As a test, run the command 'run_rr.sh' and you should get plots of RR (mag and phase) versus frequency for the circuit in ckt_for_rr (a 2-stage op amp). The low frequency RR of about 75 dB and RR = 0 dB at about 10^7 Hertz. To run a RR sim on your circuit: 1 - Find a break point that breaks all fb loops. Break the fb there. 2 - In your circuit file 'ckt_for_rr', name the nodes at the the breaks as 'drive' and 'measure' (either by modifying the netlist, or by using 0V voltage sources). The 'drive' node should be on the side of the break where you would connect an independent test source for a return-ratio analysis. Don't include any independent sources in your file; they are included in the HSPICE files rri_se.in and rrv_se.in that will '.include' your 'ckt_for_rr' file. 3 - The HSPICE input files are called rri_se.in and rrv_se.in for single-ended (SE) return-ratio simulations. Your ckt netlist is assumed to be named 'ckt_for_rr', which is called by these HSPICE input files. 4 - The command for running the return-ratio simulation is: run_rr.sh which runs the commands: hspice rrv_se.in > rrv_se.out (computes RR'v) hspice rri_se.in > rri_se.out (computes RR'i) rr_se.sh (combines RR'v and RR'i to give RR, plots result and writes result to a file called "rr_se.out.rr") (Note: The rri_se.in and rrv_se.in files may be somewhat confusing, as I'm using files for simulating common-mode return ratio in fully differential circuits here to simulate the RR of a single-ended circuit. Prof. Lewis' RR simulation files on the ECE 112 web page may be easier to understand. But either approach should give the same result.)