L I N E A Linear INteractive Electronic Analysis and W A V E S P E C WAVEform SPECification Release of 1 July 1993 ============================================== Programs, Documentation and Instructions by Leonard H. Anderson Copyright (c) 1993, all rights reserved ============================================== Standard/Math Coprocessor document release date 7 August 1993 TABLE OF CONTENTS GENERAL............................................................4 Consent and Disclaimer.......................................4 Conventions in this Document.................................5 DESCRIPTION/OPERATION OF LINEA.....................................7 Introduction.................................................7 INPUT..........................................................10 General Keyboard Input in LINEA.............................10 Numeric Value Entry.........................................10 Y/N Queries.................................................11 Main Commands (Listing).....................................11 Output Command Combinations.................................14 Output Printer Margins and Pagination.......................15 ASCII-Character Plot Equivalents............................15 Output Plot Scale Choices...................................16 Rotating Twiddle Characters.................................16 Off-Line Use of Solution Files..............................16 GENERAL INPUT-OUTPUT SOLUTION COMMANDS.........................17 Setting Frequency Limits....................................17 Time Limits.................................................17 Node of Solution............................................18 Zero-Decibel Reference Voltage..............................18 Opening or Closing a Branch.................................18 CIRCUIT LIST COMMANDS..........................................19 Starting or Continuing a Circuit List.......................19 Branch Description and Designation..........................19 Modifying a Branch Value....................................19 Deleting a Branch...........................................20 Inserting a New Branch......................................20 General Branch-Node Circuit Building in LINEA...............20 CIRCUIT COMPONENTS AVAILABLE IN LINEA..........................22 Type Descriptions...........................................22 Passive Single Branches.....................................22 Independent Current Sources.................................23 Current Direction in Sources................................23 Dependent Current Sources...................................23 Macromodels.................................................25 Transformer Macromodel Details..............................26 Unbalanced Transmission Line Macromodel Details.............26 Bipolar Transistor Macromodel Details.......................27 Operational Amplifier Macromodel Details....................28 ENTERING CIRCUIT COMPONENTS....................................29 Branch Entry, Single-Value Branches.........................29 Branch Entry, Double-Value Branches.........................30 Quicker Entry, Single-Value and Double-Value Branches.......30 Dependent Current Source Value Entry........................31 Signal (Generator) Value Entry..............................31 Macromodel Entries..........................................32 Required-Listed Macromodel Values...........................32 Seeing the Full Circuit List................................33 Circuit List Hardcopy.......................................34 CIRCUIT LIST EDITING...........................................34 Special Note on Insert Command..............................34 Special Notes on All Macromodels............................34 DISK DATA FILES................................................35 Setting the Data Storage Drive:\Directory Path..............35 Reading/Writing Circuit Files...............................36 LINEA - Page 1 of 71 Circuit Creation Dates and Remarks..........................36 Solution Storage and Retrieval..............................37 Waveform Files..............................................37 SOLUTIONS AND OUTPUT...........................................38 General Solution Organization of LINEA......................38 Scale Limit Selection on Plot...............................38 Two Forms of Impedance Plot.................................39 Time-Waveform Plot Reconstructs.............................39 Syntax on Solution Type and Form............................39 Time-Related Output.........................................39 Generating Waveforms........................................40 Generating Plot Artwork.....................................40 Single DC Output............................................41 CONVERTING FROM SCHEMATIC TO LISTING...........................41 In the Beginning............................................41 Node Numbers Must be Contiguous.............................41 Commons, "Ground" and Supply Lines..........................42 Parasitic Reactance, Resistance.............................42 Current Through Dependent Branches..........................43 Voltage Across Dependent Branches...........................43 Creating "Stiff" Voltage Sources............................43 Negative Resistance or Reactance............................44 Operational Amplifier Circuits..............................44 Field-Effect Transistor Models..............................44 Bandwidth-Alterable Networks with Transformer Macromodel....44 Creating "Black Box" Sub-Circuits...........................45 Reconstructing Schematics from Circuit Lists................45 DESCRIPTION/USE OF WAVESPEC.......................................46 General.....................................................46 WAVESPEC Input Conventions.....................................46 Waveform Description Modes..................................46 Conversion from Video to R.F. and Reverse Conversion........47 Reconstruction of Any Waveform..............................47 Disk Storage and Retrieval of Waveform Data.................47 Operation from LINEA........................................47 WAVESPEC MAIN COMMAND SET (Listing)............................48 ENTERING WAVEFORM DATA.........................................50 Single Pulse................................................50 Waveform Amplitude at Equal Time Increments.................50 Entering Amplitude at Individual Time Positions.............51 Converting a Video Waveform to Modulation of an RF Carrier..51 Observing a Created WAveform................................52 Writing and Reading Data To/From Disk.......................52 Hardcopy....................................................52 Hints on Various Waveform Descriptions......................53 INSTALLING LINEA AND WAVESPEC.....................................55 LINEA Program Set Files.....................................55 Configuration...............................................55 Registry....................................................56 CPU Versions and Copies.....................................56 FIRST-USE LINEA PRIMER/TUTORIAL...................................57 On-Line Help................................................57 Getting Acquainted With Circuit Listings....................57 Trying Out a Macromodel.....................................58 Trying Out Circuit Edit Functions...........................59 Saving a Circuit File, Trying out DOS Functions.............60 HISTORY...........................................................62 LINEA - Page 2 of 71 APPENDIX A - LINEA/WAVESPEC DATA FILE ORGANIZATION................64 General Format..............................................64 CIRCUIT DATA FILES.............................................65 SOLUTION DATA FILES............................................66 WAVEFORM DATA FILES............................................67 APPENDIX B - EXAMPLE CIRCUIT......................................68 APPENDIX C - LINEA CONFIGURATION..................................70 ======================================================= Important: See page 55 (Installation) and page 70 (Configuration) to set up a Standard (no coprocessor) or Math coprocessor version in your system. ======================================================= LINEA - Page 3 of 71 GENERAL ======= LINEA is a Linear INteractive Electronic Analysis program set for determining the frequency response of an electronic circuit having a maximum of 200 components and 40 connection points. Components may be resistors, capacitors, inductors, series and parallel resistor-reactances, reactances with specified Q, stimuli, and dependent current sources. Macromodels of transformers, transmission lines, transistors and operational amplifiers are included. Frequency range may be anything from DC to Terahertz in linear or logarithmic increments. Repetitive waveforms may be used for stimuli. Numerical input is free-form, scaling letter suffixes from femto to Tera at user's option. Analysis solutions may be printed or plotted on common dot-matrix printers. Circuit lists and solutions may be stored on or retrieved from disk. WAVESPEC is an auxilliary program used with LINEA that may be run stand- alone to create a repetitive waveform and do a time-to-frequency Fourier transform to the first 200 frequency coefficients. LINEA (acronym pronounced "lin-EY-ah") and WAVESPEC will each work in any MS-DOS computer having a minimum of 192 kilobyte free main memory (RAM) space; 384K free RAM is minimum for both being memory-resident. There is no restriction or requirement on special display devices. Any ASCII character printer may be used for hard copy output. The Standard Program Set is for personal computers using 80286 to 80486 CPUs. The Math version makes full use of numeric coprocessor to speed up solutions by a factor of three to seven. LINEA and WAVESPEC are analysis _tools_, useful to engineers, technicians, educators, and advanced electronics hobbyists alike. It is not intended as a teaching aid but it can lend insight into frequency-domain response of complex circuits. The LINEA program set is Shareware. Anyone may try out the LINEA set on one computer for a period of 15 days; beyond that time every user is obligated to obtain a registration for continued use, including commercial, educational, or governmental associations. CONSENT AND DISCLAIMER LINEA, WAVESPEC, associated files and documentation are the exclusive property of Leonard H. Anderson and are copyrighted 1993. No part of the LINEA program set (programs plus documentation) may be reproduced, transmitted, transcribed, stored in a retrieval system, or translated into any other language or computer language in whole or in part, in any form or by any means, except for distribution without fee as a program collection or for individual single-user archive purposes, without prior written consent of the author. The author disclaims all warranties as to this software, whether express or implied, including, without limitation, any implied warranties of merchantability, fitness for a particular purpose, functionality, accuracy, data integrity or protection. LINEA - Page 4 of 71 Distribution of the LINEA program collection by Bulletin Board Systems is encouraged. Companies and organizations engaged in the collection and sale of shareware shall require permission from the author before distributing all or part of the LINEA program set. CONVENTIONS IN THIS DOCUMENT This Manual is an explanation of the LINEA and WAVESPEC programs' operation. Users are expected to know the basics of electronics and be familiar with electronic terms. There is very little esoteric material found in comprehensive textbooks for college courses, yet the program operates with such esoterica and solves node-branch circuit arrangements accurately and quickly for frequency-domain analysis. The LINEA program set is useful to working electronics engineers, electronic technicians, hobbyists with a desire to create the difficult, students and educators alike. The LINEA programs were written by an engineer who is also an electronics hobbyist. LINEA, WAVESPEC, and accompanying documentation were written with a prime rule that the American Standard Code for Information Interchange (ASCII) characters are to be used for ALL input-output. This makes it possible to display everything, regardless of display type, and to be printed on nearly every page-size printer in use in North America. As a result of restrictions to ASCII characters, the few "schematics" in here are somewhat lacking in quality and appearance. Given those limitations, diagrams are as simple and understandable as possible. Also, many of the terms common to electronics notations use subscripts and superscripts and italics, features missing in ASCII. To bridge the gap between common use and LINEA, the following is a short list of not-quite- standard notation: Hfe = Hybrid forward current gain, common-emitter transistor; common term is all-lower-case italics. Hoe = Hybrid output conductance, common-emitter transistor; common term is all-lower-case italics. Ic = Transistor DC collector current, commonly written "I-sub-c." Ft = Transistor cut-off frequency; commonly written "f-sub-t." Zo = Characteristic impedance, as applied to transmission lines; commonly written all-caps as "Z-sub-O." Fc = "Corner frequency" in operational amplifiers, point of frequency intersection between open-loop gain and slope of gain falling at a rate of 20 db per decade. Av = Voltage gain, commonly written "A-sub-V", used in here denoting open-loop gain of operational amplifiers. gm = transconductance, values in mhos. = Any number not having a specific value name, as opposed to Ohms, Farads, Henries, Hertz, etc. = General designation for entry, "" explained in text. Main Commands and Branch Type Designations have no rule regarding case. They can be entered as capitals, 'small' letters, or mixed-case...the only requirement is that the letters be correct and contiguous as shown. All- capitals notation in text here is an emphasis device. LINEA - Page 5 of 71 Where keyboard inputs are described within text, they are shown capitalized within single- or double-quotes. Single- or double-quotes themselves are NOT keyboard entries. All documents in the LINEA program set are formatted for 8.5 x 11 inch page sizes, 10 characters per inch horizontally, 6 lines per inch vertically. Printer Form-Feed control characters are not used. Documents are limited to 75 characters per line and assume a printer can be set to give a half- inch (5 character) left margin. For better illustration of single-branch components and their formulae, the user is directed to Byte Books' publication "Simulation; Programming Techniques Volume 2," edited by Blaise W. Liffick, pp 87-97, article entitled "Linear Circuit Analysis" by Leonard H. Anderson. Byte Publications is now owned by McGraw-Hill and the "Simulation" book, copyrighted 1979, was out of print a few years ago. Among several texts on computer-aided design/engineering, the author has found the following to be useful: "IBM Electronic Circuit Analysis Program," by Randall W. Jensen and Mark D. Lieberman (Prentice-Hall, 1968). ECAP is the grand-daddy of all CAE programs and the frequency-domain modelling techniques are applicable to LINEA. "Computer Methods for Circuit Analysis and Design," by Jiri Vlach and Kishore Singhal (Van Nostrand Reinhold, 1983). A very detailed overview and theory of all CAE programs, although a bit "academic" for working circuit designers. "Basic Circuit Theory with Digital Computations," by Lawrence P. Huelsman (Prentice-Hall, 1972). Gets down to basics on individual components and presents many FORTRAN routines to analyze components and networks. LINEA - Page 6 of 71 DESCRIPTION/OPERATION OF LINEA ============================== INTRODUCTION LINEA analyzes the response of an electronic circuit modelled from passive and active 'branches' connected by contiguous 'nodes.' Stimuli, from a series of frequencies or repetitive-waveform coefficients, results in a frequency-domain solution at any one selected node. Each branch may be a resistor, a capacitor, an inductor, combinations thereof, independent or dependent current sources, or a mathematically-derived equivalent branch(s) (as in some circuit macromodels). Macromodels include an isolated two- winding transformer, unbalanced transmission line, bipolar transistor and operational amplifier. All circuit solutions are in the frequency domain, resulting in voltage magnitude, phase-angle, and group delay at one selected node for each frequency. Impedance may be solved in lieu of voltage; impedance is shown in both polar and rectangular form. In the case of a repetitive waveform stimulus, a solution waveform is reconstructed using an internal frequency- to-time transform. Discrete frequency selection may be DC-only, in linear- increment sweep, or in logarithmic-increment sweep. The total number of frequencies is limited to 200. Repetitive waveforms may be fully described as to shape, and may be either video or amplitude-modulated RF. The maximum number of branches-plus-macromodels is 200. Maximum number of nodes is 40. Node Zero is _always_ common, or 'ground.' Non-zero nodes must be contiguous. LINEA checks for maxima and contiguity, displaying specific warnings for violations. Node of solution is selectable to any circuit node. All non-integer numeric entries may use mantissa/decimal-point/fraction format, 'E format' common to BASIC or FORTRAN languages, or Scaling Letter suffixes ranging from femto to Tera, or any mixture thereof. LINEA accepts all of them for any non-integer numeric input. ALL non-integer calculation is done in 'double precision' using 15 significant digits and having a power-of-ten range from -308 to +308, a range well beyond today's physical components. Except for Scaling Letters and circuit list Remarks, there is NO distinction on entry case. No PC function keys, Control or Alternate key combinations are used at any time. All LINEA program commands are done at a 'Main Command' level, using clear English words or accepted abbreviations. Most commands are one word. Command words may be abbreviated to the first 3 letters, first 2 letters, or, sometimes, as a single letter or symbol. A few use two words separated by a space. Where some numeric value should be entered following the first command word, a "data word," that numeric may be entered following a space separator as a 'second word.' If a first command word requiring data input is given, but data inadvertently omitted, LINEA displays a prompt for the type and kind of data. If that data should consist of two or three numerics and only one is entered, LINEA will re-prompt for all of them. LINEA - Page 7 of 71 Command word entry may be the following, depending on command: <-- space separator <1stWORD> <2ndWORD> <-- space separator Data words have contiguous characters, individual data items separated by a comma, semicolon, or forward-slant delimiter. Data words may be entered as: (single item) , or ; or / ^ ^ ^ (any of the three delimiter characters accepted) ,, Circuit entry is handled much the same as Main Commands. Component descriptions recognize, in order, first letter, first two letters, or first three letters of a component name. All other letters or numbers, including a few symbols, may be added for reference designation. The Node number entries (integer) describe the location of the branch in the circuit. Entering type but no node numbers results in a prompt for node numbers. Numeric value entry for a branch is prompted next, some branches requiring two values; omitting one value of a two-value entry will result in a "re- entry" prompt. It is possible to enter everything for a single branch on one line...see Circuit Entry section for details. Throughout LINEA, the organization is aimed at being interactive, clear- language, communicating with the user. There is a minimum of 'programese' spoken, no "command line shorthand." The only jargon used is that of electronics. LINEA's output is directed to the screen or the printer port. All Main Commands, Circuit Entries, prompts and warnings go to the screen display. Listings, tabulations, and graphics equivalents are to the screen or printer port at the choice of the user, switchable at any time. Printer port is that set up for MS-DOS itself. LINEA does pagination of each hardcopy output, using a 66-line, 85-column format (10 characters per inch horizontally, 6 lines per inch vertically, page size 8.5 by 11 inches). The associated Configuration program sets the top and bottom margins, left margin, for that standard. All printout uses ASCII characters, allowing any 'standard page' size printer in North America to be used for hardcopy. A total circuit list may be written to, or read from disk. A solution may also be written to, or read from disk. Each has separate file extensions for identification. LINEA allows selection of another drive and directory (other than the program) if desired. Repetitive waveform coefficients are generated by an auxilliary program, WAVESPEC; these coefficients may be read from disk in the same manner as circuit lists or solutions. Circuit, solution, or waveform files are ASCII in structure and may be read by any other program as the equivalent of a text file. File structure, fields, LINEA - Page 8 of 71 field descriptions are given in the Appendix. Repetitive waveforms are described by invoking another program, WAVESPEC, from within LINEA. When so done, LINEA goes into the "background" and will return automatically when WAVESPEC exits. WAVESPEC requires another 192K of free memory when used coincident with LINEA. WAVESPEC is not required on disk for frequency-domain-only solutions. WAVESPEC may run stand-alone. Solution 'plots' are made solely with ASCII characters. The reason for this apparent limitation is the universality of character-only printers and their generally-faster output. Typical circuit analysis sessions will have considerable interaction by the user's "tweaking" of values and checking response with those new values. Each plot parameter is scanned for minimum and maximum value, then displayed to the user; the user may choose those extremes as plot scale limits or enter other plot scale limits. LINEA "time and date stamps" every output as well as every circuit list or solution file; solution files include the circuit filename and circuit creation date for later reference. Circuit files include a one-line remark for quick notations, changeable at any time from Main Command level. Every output or circuit list is headed by the circuit name, its creation date, one-line remark, node-of-solution, current time-and-date, and any branches switched 'open.' Circuit branches may be Opened or Closed at any time. 'Opening' a branch disconnects it from analysis but allows it to remain in the list; identical to opening a connection. 'Closing' an Open branch re-connects it for analysis. The action is the same as unsoldering and lifting just one end of a physical circuit component, then later re-soldering it. Circuit lists may be edited at any time. Users may Add to the circuit, Insert or Delete branches, or just Modify a branch value leaving the branch type and node connections intact. Open, Close, Insert, Delete, or Modify are all done from the Main Command level and users have the choice of calling out the branch order number or the entered type designation. Throughout LINEA's program structure there are a number of checks for impossible-calculation conditions plus associated, specific warning messages. LINEA should not crash in normal operation. LINEA - Page 9 of 71 INPUT ----- GENERAL KEYBOARD INPUT IN LINEA All keyboard input is free-form in nature. No PC Function keys or Ctrl- or Alt- combinations are used for any purpose. The program is controlled from a 'Main Command' level having the following screen prompt: MAIN*> (printer port inactive) -or- Main-> (printer port active) Main Command expects an all-alphabetic 'command word' to be entered. The 'word' itself may be an abbreviation of, in order, the first three letters, the first two letters, or the first letter or a symbol. Some commands may require two words; two words must be separated by at least one space. More than one contiguous space is considered to be the same as one space. Command words may be entered in all-capitals, all-lower-case, or even mixed-case; only the letters themselves matter. Exception to this overall rule occurs only with Scaling Letters or textual input for Circuit List Remarks. NUMERIC VALUE ENTRY Some commands require data as the second word. A 'data word' in LINEA consists of alphanumeric data of one to five items. Each data item is separated (delimited) from the following data item by a comma, semicolon, or forward-slant ('/'). No entry for an item is considered a space for alphabetic data or zero for numeric data. ALL numeric data items in LINEA have flexible input format. Each data item may have any one or a mixture of any of the following formats: * Mantissa-decimal-point-fraction. * 'E-format' style common to BASIC and FORTRAN * Scaling letter suffixes from femto to Tera. Scaling letter multipliers are as follows: T = Tera = 1E+12 f = femto = 1E-15 G = Giga = 1E+9 p = pico = 1E-12 M = Mega = 1E+6 n = nano = 1E-9 K = Kilo = 1E+3 u = micro = 1E-6 = 1 m = milli = 1E-3 Scaling letter case MUST be observed. All below unity require lower-case, all above unity require upper-case. The lower-case 'u' has been substituted for the Greek 'mu' to permit direct compatibility with ASCII- character printers. LINEA - Page 10 of 71 The following keyboard-entry combinations all denote the same numerical quantity: 12345.678 12.345678E+3 12.345678K 0.012345678E+6 .012345678e+6 12345678m 12.345678KE-6 .012345678M Scaling letter suffixes take precedence over any 'E-format' power of ten; in the 7th example (12.345678KE-6), the "E-6" would be ignored. 'E-format' allows either case for the "E." The maximum number of digits in the mantissa is limited to 9. The exponent range is limited to E+290 and E-289. Polarity is considered positive by default (signs are ignored) and a minus sign must precede a number to indicate it is negative. Except for Scaling Letters and the "E", all other characters are ignored. Where data required is expected to be integer- only, any fractional part of an entry is ignored. Data item delimiters within a numeric data word are a comma, semicolon, or forward-slant. Two contiguous separators indicate a zero value between the delimiters. In the case of a delimiter character being the first character in a data word, the first data item would be zero (null entry). Depressing an key without entering anything else in response to a prompt will make ALL requested data items zero. Y/N QUERIES In several LINEA functions there are Yes-No queries having "[Y/n]" or "[y/N]" entry prompts, each having only one letter capitalized. Pressing key without entering anything else is the same as entering the capitalized key. MAIN COMMANDS All of LINEA's Main Command words are listed following. All-capitals form is used here to emphasize required _letters_; user may enter either case or even mixed-case. These are all "first words"; if a second word is required, LINEA will prompt for it. This list, in abbreviated form, is duplicated in the HELP display on-line. QUIt QUI QU Q -or- Quit LINEA and return to DOS level. EXIt EXI EX X HELp HEL HE ? Display 1 to 6 screens of on-line Help information. DOS DO \ Temporary drop to DOS level. One DOS request will return to LINEA afterwards unless word 'COMMAND' is entered...will not leave DOS level until 'EXIT' is entered. LINEA - Page 11 of 71 NEW NE Begin entry of a new circuit list. Old circuit data is discarded. ADD AD A Add to an existing circuit list. LISt LIS LI L List entire circuit to screen or printer. ON ( Enable printer port to accept outputs or circuit listing. Main Command prompt changes to "Main->" when printer port is on/enabled. All PRInts or PLOts or LISts are directed to the printer. Active printer port is that set by Operating System. Printer port remains on until turned off. OFF OF ) Disable printer port. All outputs are directed back to screen and Main Command prompt returns to "MAIN*>" to show printer port is off. Default state when LINEA is first run. DRIve DRI DR & Select another Drive:\Directory path for reading or -or- writing Circuit, Solution, or Waveform data files. DIRectory DIR DI Default on LINEA start is same Drive:\Directory as LINEA program drive and directory. REAd REA RE R Read a Circuit file from disk. Requires only the 8-character-maximum filename. File extension of .LIN is automatically appended. 'LIN' file extension is LINEA's identification for Circuit list files. WRIte WRI WR W Write an existing Ciruit file to disk. Same filename and extension conditions as REAd. SAVe SAV SA / Save a solution to disk, including frequency limits and circuit filename (but not circuit itself). Requires only the 8-character-maximum filename. File extension of .LNA is automatically appended. 'LNA' is LINEA's identification for Solution data files. BRIng BRI BR B Bring (back) a previously-SAVed solution. Same file- name and extension conditions as SAVe. Displays file- name of circuit that was solved but does not read it in. Used for viewing previous solutions. There are conditions with this command which may result in an error; please see later text on this command. GET GE G Get (read in) repetitive waveform data in the form of coefficients generated by program WAVESPEC. Requires only the 8-character-maximum filename. Automatically appends file extension of .LWC, LINEA and WAVESPEC's identification for waveform data files. OPEn OPE OP O Open the connection of a designated circuit branch. Branch remains in circuit list but is not part of circuit solution. Opening a previously-opened branch has no effect. If an OPEn designates any branch in a macromodel, the entire macromodel is Opened. LINEA - Page 12 of 71 CLOse CLO CL C Close, or reconnect a designated circuit branch. Opposite of OPEn. Closing an already-closed branch has no effect. If a CLOse command designates any branch in an opened macromodel, the entire macromodel is closed. MODify MOD MO M Modify only the values of a designated circuit branch. Type and nodes remain intact. Inoperative with macro- models. DELete DEL DE | Delete a designated circuit branch from a circuit list. All higher-listed branches move down to fill in list. If a DELete command designates one branch of a macromodel, the entire macromodel is Deleted. INSert INS IN ^ Insert a new branch at the designated branch position in a list. Branch type, nodes, value prompts and entries are the same as for one component under NEW or ADD. Designated branch and all higher branches move move up to make room for INSertion. NAMe NAM NA $ Change existing circuit list filename. Circuit file REAds and WRItes assume the existing filename or allow choice of another filename; this command is primarily for hardcopy outputs so as to show the new filename prior to any WRIte to disk. REMark REM RE * Change 47-character Remark line accompanying each circuit list or output title. Remark line is written to or read from disk with other circuit list data. NODe NOD NO N Select NODe of solution. Every NEW circuit or ADDition to a circuit, MODification of branch value, INSert of a new branch, DELetion of an old branch, REAd-in of a circuit from disk will always make the highest node in a circuit as the node of solution. DBR DB D Change reference voltage for 0 db on all outputs. Default at LINEA start is 1 Volt. Does not affect solution voltage, only decibel value equivalent to solution voltage. FREquency -or- First Command Word to select frequency limits, first FRE FR F or second word to select frequency-voltage output type. At LINEA start there are no frequency limits. IMPedance -or- First or second word to select frequency-impedance IMP IM Z output. TIMe TIM TI T First word to select time limits of a time-voltage waveform reconstruct, first or second word to select waveform output type. At LINEA start there are no time limits. SPEctrum -or- First or second word to select output type of a SPE SP S repetitive waveform coefficient spectrum. LINEA - Page 13 of 71 ENVelope -or- First or second word to select output type of ENV EN E envelope of an RF waveform reconstruct. Envelope is equivalent to output of a linear, full-wave detector having a positive-going output. WAVeform WAV WA ~ 'Shell' command to invoke WAVESPEC, an auxilliary program used to describe a repetitive waveform. PRInt PRI PR P First or second word of an output to select printed, tabulated solution values. PLOt PLO PL = First or second word of an output to select ASCII- character plot equivalents. MARgin MAR Select margins for hardcopy; 1 to 7 characters left margin (5 is default), 1 to 6 lines top and bottom equally (3 is default). Margins do not appear on screen displays. SETtings SET SE Convenience screen display to show user the current circuit filename, circuit creation time/date, circuit Remarks, current time, node of solution, open circuit branches (if any), frequency sweep limits, 0 db reference voltage, time reconstruct limits, and Drive:\Directory for circuit or solution reads or writes. DATe DAT Current computer time and date. Convenience only; computer time and date are resettable only from DOS level. OUTPUT COMMAND COMBINATIONS PRInt or PLOt must be combined with FREquency, IMPedance, TIMe, SPEctrum or ENVelope to achieve a solution output. Each group may be in either order as long as the two words are separated by at least one space. To obtain an IMPedance PLOt, any of the following two-word combinations can be used: PLOT IMPEDANCE IMPEDANCE PLOT PLO IMP IMP PLO PL Z Z = For user convenience, the following three-letter acronyms may also be used for an output, requiring only one Command word: PRF - Print tabulation of voltage over frequency. PRZ - Print tabulation of impedance over frequency. PRT - Print tabulation of time-reconstruct voltage. PRS - Print tabulation of waveform coefficient spectrum. PRE - Print tabulation of time-reconstruct envelope. PLF - Plot voltage over frequency, ASCII-character plot. PLZ - Plot impedance over frequency, ASCII-characters. PLT - Plot time-reconstruct voltage, ASCII-characters. LINEA - Page 14 of 71 PLS - Plot waveform spectrum, ASCII-characters. PLE - Plot time-reconstruct envelope, ASCII-characters. OUTPUT PRINTER MARGINS AND PAGINATION Printer-directed output is formatted for the 8.5 x 11 inch North American standard page size, expecting 85 columns per page horizontal ("10 Pitch" or ten characters per inch) and 66 lines per page vertical (6 lines per inch). Top and bottom page margins, left margin are selected via the "MAR" main command. Top and bottom margins (equal) are selectable from 1 to 6 lines, 3 line margin (half inch) being default at LINEA start. Left margin is selectable 1 to 7 characters/columns, 5 characters (half inch) being default at LINEA start. Pagination of "Page nn of mm" is done at the bottom right of each page and "...continued from Page nn" at the top left of each page after the first page. The first page always begins with a title bearing circuit filename, when circuit was created (or last changed), remarks, current time and date, any circuit branches which are set open. Margins and the "...continued" identification are omitted from screen displays and "Page nn of mm" only appears on screen if an output or circuit list goes beyond a single page. Top and bottom margins (always equal) allow the following number of solution data lines per page: Margin Lines 1st Page Data Lines 2nd, subsequent Pages' Lines 1 52 55 2 50 53 3 48 51 <- default 4 46 49 5 44 47 6 42 45 ASCII-CHARACTER PLOT EQUIVALENTS The "character plot" technique is an old method of making a graph equivalent using only printer characters as data and graph marks. It is also the fastest and most equipment-versatile, requiring only that a printer support ASCII characters. LINEA outputs plot graphs having 6 major divisions, 60 minor divisions, 'rotated' a quarter turn so that the lowest frequency or shortest time is at page top, amplitude increasing from left to right. Every line is identified by frequency or time. Major graph divisions are identified by a plus sign. Any data plot character will override a graph division character. The prime data character is an asterisk, secondary a colon, tertiary is an up-arrow. If, for one plot point, characters are at the same plot location, the prime character predominates. If the prime character location is calculated to be beyond the scale extremes, a left or right arrow mark at appropriate left or right limit lines indicates overscale. LINEA - Page 15 of 71 Data location is very close to the physical center of a character. The center of a colon character is mid-way between the two marks. Group Delay is shown by an up-arrow and the _point_ of the up-arrow is significant. Group Delay is the derivative of phase divided by derivative of radian frequency; the point of the arrow is approximately mid-way between each frequency, thus corresponding to approximate frequency of delay. OUTPUT PLOT SCALE CHOICES Every solution's plot output is scanned for minimum and maximum, those minima and maxima shown as a screen prompt. Users have a choice to accept those extremes as the scale limits or to enter desired limits. Pressing _only_ the key after the prompt accepts the solution's extremes as scale limits. Phase-angle scale limits are slightly different. Default values of phase- angle plot extremes are -180 and +180 degrees for Frequency-voltage and Time-related output. A user may select any other phase-angle limits or accept those as shown. Selected phase angle limits will remain until reset. Impedance plots are selectable polar (default) or rectangular. Polar form impedance plot has the prime data mark signifying impedance magnitude, secondary data mark signifying impedance phase-angle. Entered impedance phase-angle plot limits remain only for that particular impedance plot. Rectangular form impedance plot has prime mark indicating Real/Resistive part, secondary mark indicating Imaginary/Reactive part. All plot outputs have the scale limit values at the header of each page. Limits can be reversed left-for-right by reversing the order of limit entry. If a re-plot of the same solution is desired with different scale limits of some parameter, it may be done without delay. Solutions are stored internally and re-plotting/re-printing may be done immediately without waiting for a new solution. ROTATING TWIDDLE CHARACTERS Every circuit solution requires all circuit branches to be mathematically analyzed at each solution frequency. With large circuits, this may take many seconds. To indicate this is in process, "Working!" is displayed on the screen, preceded by a 'rotating twiddle character' that appears to turn in 45-degree increments for every frequency. After the last frequency's circuit analysis is completed, both of these indicators disappear. Both indicators are also shown for time solution-reconstruction. OFF-LINE USE OF SOLUTION FILES All solutions may be stored on disk. All files generated by LINEA are the functional equivalent of ASCII files. Other programs may be used to parse the characters for any other tabulation or plot format. A full description of disk file data fields is given in the Appendix. LINEA - Page 16 of 71 GENERAL INPUT-OUTPUT SOLUTION COMMANDS -------------------------------------- SETTING FREQUENCY LIMITS Entering F, FR, or FRE at the Main Command prompt without a second word will invoke a prompt of: Frequency Limits [Hz] (min,max,delta): "min" and "max" are self-explanatory, but "delta" has two possibilities: A positive delta entry is the linear frequency increment while a negative delta entry refers to the _total_ number of logarithmic-increment frequencies. Entering "99K,101K,-17" would mean a log-sweep of 17 total frequencies starting at 99 KHz and ending at 101 KHz. An entry of "99K,101K,100" would mean a total of 21 linear-increment frequencies starting at 99 KHz and ending at 101 KHz. Maximum number of frequencies is 200, regardless of linear or logarithmic increment. LINEA checks for that and prompts if entry is incorrect. LINEA will accept a 0 minimum frequency (DC) if the delta is positive/linear, but will not accept a 0 minimum frequency if the delta is negative/logarithmic. If the delta entry is 0, regardless of whatever else is entered for minimum and maximum, the "frequency" is DC. For all other conditions of delta, minimum and maximum frequencies must be positive. Frequency limits may be set at the Main Command level by entering "F " where is the min-max-delta. This single-line short form of command requires only that one or more spaces are between the "F" and the first character of ";" also, the three data items of are separated by commas, semicolons, or forward-slants, not spaces. It is also possible to select a DC solution from the Main Command prompt by entering "FREquency DC" or just "F DC". TIME LIMITS A repetitive waveform stimulus is a set of 200 Fourier coefficients representing the time-to-frequency transform of a described waveform. The waveform at any selected node is done by a frequency-to-time transform, a Time Limits entry setting the start, stop, and incremental times of that reverse transform. Either start or stop parameter may be a negative or positive value, provided that stop is always more positive than start. A zero or negative increment is not allowed. The number of total time increments is limited to 800, a value imposed by the internal variable arrays used in reconstructing the waveform. 800 increments require 16 print pages at default margin setting. Time limits may also be entered as two words at the Main Command level with the entry "T ", same entry rules as with frequency limits. LINEA - Page 17 of 71 NODE OF SOLUTION Any node in a circuit may be selected as the "measuring point" for a solution. Selection of a new node of solution will cause it to remain; however, after every ADD or NEW circuit completion, INSert new branch, DELete old branch, or REAd in of another circuit, the node of solution is reset to the highest node in the circuit. If in doubt of the node of solution, a user can use the SET command to see which node is the current node of solution. Node of solution may be set as a single-line command at Main Command level by entering "N ". ZERO-DECIBEL REFERENCE VOLTAGE Frequency-voltage outputs give both node voltage directly and in decibels relative to a zero-db reference voltage. At LINEA start, this reference voltage is 1. It may be reset at any time and will remain at that voltage reference until changed again. A zero or negative reference voltage is not allowed. Zero-db reference voltage may be given at Main Command by the single entry of "D ". OPENING OR CLOSING A BRANCH Every single branch or an entire macromodel may be "switched" open or closed, functionally the same as disconnecting and reconnecting a physical component. An OPEned branch remains in the circuit list but is not solved. CLOsing an open branch will restore it to solution with the rest of the circuit. As an example, consider a circuit having a load resistor. It may be desireable to solve for the impedance looking into the load end, without the load resistor. An easy way to do that is to OPEn the load resistor branch, then request an impedance solution at that node. The load resistor may be reconnected with a simple CLOse command for that branch. OPEns and CLOses do not affect the circuit list order, type, nodes, or values. Single-line Main Commands may be "O " for OPEn, or "C " for CLOse. "" is either the branch order number or the full type description (see circuit entry for differentiation, explanation). OPEning an open branch or CLOsing a closed branch have no effect. A reminder: 'Open' and 'close' of branch components has NO relation to computer files. LINEA - Page 18 of 71 CIRCUIT LIST COMMANDS --------------------- STARTING OR CONTINUING A CIRCUIT LIST The single command word, "NEW," at Main Command will begin a new circuit list, starting at branch 1. All old circuit list data (if any) will be lost. The single command word, "ADD," or "AD," or just "A" at Main Command will allow new branches to be added to an existing circuit list, beginning with the next higher branch order following the last branch. If there is no circuit data, the command ADD will also begin a new circuit list, starting at branch 1. Every branch entry begins with a type description. This is followed by node connection data, finally by branch component values. Once branch data has been fully entered, branch entry begins again with the next branch. Branch entry continues until "END," "EN," "E," "ND," or "N" is entered for a branch type, signifying completion of a circuit list. BRANCH DESCRIPTION AND DESIGNATION Branch type descriptions allow up to 8 characters per branch. The minimum _first_ letters for electrical type identification are shown in the comprehensive branch descriptions following. Those minimums are from 1 to 3 alphabetic characters. The remaining characters may be used for reference designations or whatever the user wishes. As an example, a single resistor branch will be identified as to type by just the single first letter "R." Entering "RESISTOR," "R-123," "R_LOAD," or just "R" would all signify a single resistor branch for the purposes of completing a branch entry. The _entire_ type description may be used for designating a branch for some action. Main Commands OPEn, CLOse, MODify, DELete, and INSert require designation of a particular branch. Designator "" for those commands may be either the branch number or the full type description. LINEA parses the first character of a "" designator entry. If that character is alphabetic, the entire circuit list is searched for a match between "" and the type description; if there is a match, then the circuit branch number has been reached. If that character is numeric, the designator is assumed to call out the circuit branch number directly. Since most circuit analyses concentrate on only a few components of a circuit, it is probably easier to enter "OPEN R_LOAD" to open that branch rather than entering "OPEN 109" (assuming R_LOAD was branch number 109). MODIFY A BRANCH VALUE A single-line Main Command "MOD " allows changing just the values of that branch. Type description and nodes remain intact. MODify command will not work with macromodels. The finish of a MODify will reset the circuit creation time and date to that when the MODify took place. LINEA - Page 19 of 71 DELETING A BRANCH A single-line Main Command "DEL " will remove the branch at designator "." This may present some slight difficulty if the DELeted branch is the dependent branch of a dependent current source. LINEA does a circuit check of each circuit after an Edit command. If LINEA finds an improper dependent branch relation, the dependent branch is automatically switched open, and a warning message to that effect displayed on the screen. Such an automatic Open cannot be CLOsed until the dependent branch exists in proper form. If a DELeted branch is the only link between two parts of circuit, one part having a stimulus and the node of solution being in the other part, solution analysis will stop and a warning message shown, citing that probability. DELeting any branch number within a macromodel will cause the _entire_ macromodel to be deleted. After a DELetion, all higher-order branches will move down to fill in the empty branch space. If any of the moved-down branches contain a dependent branch, the dependent branch number of a dependent current source will be automatically changed to the new number. The finish of a DELetion will also reset the node of solution to the highest node in the remaining circuit and reset the circuit creation time to the time of DELetion. INSERTING A NEW BRANCH The Main Command single-line command is "INS ". The designated branch and all higher branches will be moved up in the circuit list to make room for the INSertion. LINEA will issue a prompt for the inserted branch type and nodes. Once the branch type is known (it may be a macromodel with many branches), the list movement will take place. If one of the moved branches is the dependent branch of a dependent current source, the dependent branch number of that dependent source will be automatically adjusted to be the new branch number. The finish of an INSertion will reset the node of solution to the highest node in the new circuit and reset the circuit creation time to the time of INSertion. GENERAL BRANCH-NODE CIRCUIT BUILDING IN LINEA Every single component is called a "branch." Every connection point is called a "node." Every branch is connected between two nodes. Node zero is common-ground-earth to the entire circuit. Non-zero nodes must be contiguous. A branch may not have each end connected to the same node. There is no limit to the number of branches connected between the same two nodes. There is no restriction to the ordering of branches in any circuit; branches may be located anywhere in a listing. Node location makes no difference to the final solution although it may have some effect on speed of solution execution; more of that in explanation of the sample circuits distributed with the LINEA program set. LINEA - Page 20 of 71 As a practical matter, node ordering is best when following the general flow of a schematic diagram; that makes for easier interpretation of a circuit list at a later date. Branch and node arrangement closely follows conventional theoretical analysis techniques. LINEA expands single component per branch theoretical concept to include parallel R-L and parallel R-C, series R-L and series R-C branches. While this is more for user convenience, in the physical world every component contains combinations of resistance, capacitance, and inductance. In LINEA, each resistance is a pure resistance, each capacitance is a pure capacitance, and each inductance is a pure inductance. Current flow in LINEA is provided by current sources. Every current source is assumed to be the theoretical type having an infinite source impedance. There are no voltage sources in LINEA. A theoretical voltage source has zero source impedance. A voltage source may be approximated by a current source in parallel with a very low resistance. This is no problem with the large magnitude range of LINEA's numeric calculation...a MegaAmpere current source in parallel with a microOhm resistor would create a very 'stiff' one-volt source...such would be numerically and theoretically correct despite the impractical-seeming combination. Current sources come in two varieties, "independent" and "dependent." Independent current sources are the stimuli or the fixed sources. Note: ALL stimuli are _always_ at the same frequency in LINEA. Dependent current sources are dependent on the voltage across a branch or the current through a branch. More on those in the later section on dependent current sources. In this version of LINEA, there are four macromodels. These are always made up of contiguous branches, are always handled by commands as if they were a single branch. LINEA - Page 21 of 71 CIRCUIT COMPONENTS AVAILABLE IN LINEA ------------------------------------- TYPE DESCRIPTIONS All of the following branch type descriptions may be found in short form in the Appendix and included in the HELP display within LINEA. All TYPE letter combinations are shown in all-capitals to emphasize the _letters_ required; users may enter letters of either case or even mixed case, provided they are the correct letters. Circuit Lists will always show branch types in all-capitals. PASSIVE SINGLE BRANCHES TYPE Description ---------- -------------------------------------------- R RE RES = Single pure resistance C CA CAP = Single pure capacitance L IN IND = Single pure inductance LQ = Single inductance with specified Q; Q is constant over frequency. Q is modelled as a loss resistance in series with inductance. Loss resistance is magnitude of inductive reactance divided by Q. CQ = Single capacitance with specified Q; Q is constant over frequency. Q is modelled as a loss resistance in parallel with capacitance. Loss resistance is the magnitude of capacitive reactance divided by Q. SRL = Series R and L. SRC = Series R and C. PRC = Parallel R and C. PRL = Parallel R and L. E EN END = Non-branch. Signifies end of circuit listing. -or- N ND B BA BAK = Non-branch. Entered by itself (no nodes), causes listing to back up to the previous branch for re-entry. Used for correcting errors made in previous branch entry. At DC all inductors assume a resistance of 1 microOhm and all capacitors assume an infinite resistance. All passive branch values are normally entered as _positive_ quantities. A negative value may be entered at the user's discretion. Negative entries of inductance or capacitance will result in the same magnitude of reactance LINEA - Page 22 of 71 over frequency but the signs of those reactances are reversed. This is useful in modelling certain theoretical circuit equivalents. INDEPENDENT CURRENT SOURCES TYPE Description --------- ----------------------------------------------- SI SIG = "Signal generator" stimulus, specified by current in Amperes and phase-angle in degrees (optional) for frequency solutions. For time solutions with repetitive waveforms, phase-angle is ignored and the entered current is the peak value of the described waveform. DC IDC = Direct current source. Active _only_ when the frequency is zero (DC). Independent current sources are automatically ignored during an impedance solution. All current sources have infinite source impedance. Voltage across the nodes of any current source depends on the voltage drop through all other branches connected across the current source nodes. A "stiff" voltage source may be created by a high-current source in parallel with a low-value resistance; source impedance of this "stiff" voltage source is that of the low-value resistance. CURRENT DIRECTION IN SOURCES Current flow in LINEA is assumed equal to _electron_flow_. Current flow _within_ all current sources is from "plus node" to "minus node" if the entered current value is positive. Entering a negative value of current or current gain reverses the current flow. Node entry order of all passive branches is irrelevant...except for dependent branches of a dependent current sources. DEPENDENT CURRENT SOURCES LINEA has two types: GMS or transconductance-specified ('gm') dependent current source, and HFS or current-gain-specified ('hfe') dependent current source. Current is dependent on the voltage across a dependent branch (type GMS) or the current through a dependent branch (type HFS). Dependent branches may be any passive branch type located anywhere in the circuit; they may not be a current source. TYPE Description ---------- ----------------------------------------------- G GM GMS = Transconductance-specified current source. Current depends on the specified transconductance ('gm') times the voltage across the nodes of a specified dependent branch. Transconductance is specified in mhos, transconductance being the derivative of current divided by derivative of voltage. Current is then proportional to the voltage across a dependent branch. LINEA - Page 23 of 71 H HF HFS = Current-gain-specified ('hfe') current source. Current depends on the specified current gain times the current through the dependent branch. Note: "hfe" is not conventional notation for current gain, being the hybrid parameter of collector current versus base current gain of a common-emitter transistor; it is used due to limitations of ASCII not allowing subscripts. "hfe" to most circuit designers is fairly well synonymous with current gain. Current flow in circuits with dependent current sources is illustrated following: Plus node Plus nodes o +e o ------------------o | | | /|\ | | | Current | | Rd -> GMS | Within Rm | | | \|/ GMS | Current | | | through o -e o ------------------o Rm Minus node Minus nodes Dependent Type GMS Dependent Current Source Branch with connected resistor Rm Voltage drop across Rm is in-phase with voltage across Rd. Exchanging Plus and Minus nodes of the GMS or dependent branch Rd will reverse current through the GMS and through Rm. Exchanging Plus and Minus nodes of _both_ GMS and the dependent branch, Rd, will have current through the GMS and through Rm as shown. Entering a negative transconductance value for the GMS will also reverse current flow of the GMS. If there are several branches connected to the same nodes as the dependent branch, GMS current magnitude is dependent on the total impedance magnitude across the dependent branch nodes...but GMS current direction is still dependent on the Plus and Minus node entry of the dependent branch. Plus node Plus nodes o o-------------------o | | | /|\ | /|\ | | Current | | Rd | -> HFS | Within Rm | | | | \|/ HFS | Current | Current thru | | through o dependent o-------------------o Rm Minus branch Minus nodes node Dependent Type HFS Dependent Current Source Branch with connected resistor Rm LINEA - Page 24 of 71 Current through Rm is in-phase with current through Rd. Exchanging Plus and Minus nodes of the HFS or dependent branch Rd will reverse current through the GMS and through Rm. Exchanging Plus and Minus nodes of _both_ HFS and the dependent branch, Rd, will have the current through HFS and Rm as shown. Current flow in the HFS may also be reversed by entering a negative value of current gain. If several branches are connected to the same nodes of the dependent branch, HFS current magnitude is dependent _only_ on the current through the dependent branch...but HFS current direction is dependent on the node entry order for the dependent branch. MACROMODELS Macromodels use 3 to 5 branches, branches _always_ being contiguous in any list. TYPE Description ---------- --------------------------------------------- Z ZL ZLN = Unbalanced transmission line equivalent macromodel; uses 3 branch spaces, requires 3 nodes (input, output, common). Specified by characteristic impedance, velocity of propagation, length in inches, and decibels of loss per 100 feet. T TR TRF = Two-winding ideal transformer having specified coefficient of coupling between 0.01 and 0.99, DC isolation between windings. Uses 4 branch spaces, requires 4 nodes maximum (2 each for primary, secondary). Specified by primary winding inductance, turns ratio of primary winding to secondary winding, and coefficient of coupling. One node of primary, one node of secondary may be common, if desired. Q QT QTR = Bipolar transistor, hybrid-pi model. Creates 4 branches, requires 3 nodes (base, emitter, collector). Specified by: hfe or base-to-collector current gain; Ft, cutoff frequency; Ic, average value of collector current; Hoe, collector conductance in mhos. Model does not include base spreading resistance, Rbb. Model makes no distinction between PNP or NPN. O OP OPA = Operational Amplifier. Creates 5 branches, requires 4 nodes (non-inverting input, inverting input, output, common). Specified by: DC open-loop voltage gain in db; Fc, or "corner frequency", the break-point of open-loop gain where gain begins to decrease at a rate of 20 db per decade; R-input, equivalent resistance of each input, both assumed to have equal resistance; R-output, source resistance of output. Common node is common to both inputs as well as output. LINEA - Page 25 of 71 TRANSFORMER MACROMODEL DETAILS Two-winding isolated transformer macromodel is modelled as: Primary o----o-----o o----o-----o Secondary + node | | | | - node Lp HFSp < Ls HFSs | | | | Primary o----o-----o o----o-----o Seconday - node \ + node - - - - > - - - -^ where: Lp' = Calculated primary inductance. Ls' = Calculated secondary inductance. HFSp = Current-gain dependent current source dependent on current through Ls. HFSs = Current-gain dependent current source dependent on current through Lp. with internal values: Lp = Entered primary inductance. N = Entered turns ratio, primary to secondary. Ls = Secondary inductance calculated from primary inductance divided by square of N. K = Coefficient of coupling (entered) Lp' = Lp x (1 - (Ký)) Ls' = Ls x (1 - (Ký)) Hfe of HFSp = -(K / N) <- [dependent branch is Ls] Hfe of HFSs = -(K x N) <- [dependent branch is Lp] DC isolation is a relative term here. Inductors have a 1 microOhm resistance at DC to avoid an error-crash in the analysis-solution routine. While that is a very low impedance, it will show up as a small, small "leakage" of signal from primary to secondary and vice versa at DC. One primary node may be common to one secondary node in the circuit list. The orientation of secondary nodes is purposely chosen to yield a voltage polarity of the same sign as voltage across the primary. UNBALANCED TRANSMISSION LINE MACROMODEL DETAILS Unbalanced transmission line macromodel is a pi-form having the same attenuation at every frequency. Macromodel attenuation is internally computed from the ratio of specified length to the loss per 100 feet. Loss per 100 feet is a common specification for transmission lines and may be taken directly from manufacturer's data. User must compensate for loss varying over frequency. Lengths in meters must be converted to inches; legal USA conversion is 2.54 centimeters = inch. LINEA - Page 26 of 71 Open-line sections ('half-wave' resonant lines) may be created by having the "output" node isolated from all other branches; in effect, that would create the equivalent of an open end. 'Quarter-wave shorted stubs' are simulated by connecting a very low resistance branch to the output node. BIPOLAR TRANSISTOR MACROMODEL DETAILS The created bipolar transistor hybrid-pi model is as follows: Base node Collector node o------*------- --------*------o | | | | | | | | Cb'e Rb'e -> HFS (1/Hoe) | | | | | | | | -------*-----*-----*-------- | o Emitter node where: Hfe = base-to-collector current gain at Ic Ft = cutoff frequency Ic = average collector current Hoe = collector-emitter output conductance HFS is dependent on Rb'e branch current with current gain equal to Hfe such that collector voltage is at opposite phase relative to base voltage. then: Rb'e = (Hfe x 0.027) / Ic Cb'e = 1 / (Ft x 2pi x Rb'e) Hybrid-pi models usually have an additional resistance, Rbb, "base spreading resistance," in series with the Rb'e-Cb'e junction and external base node. Rbb is not readily calculated since it is subject to variations in design and type of the base junction rather than operating parameters. If no Rbb value is known, a suggestion is to use a value equal to or slightly larger than Rb'e. An added Rbb external to the macromodel can also include an independent DC current source (IDC) to create the Vbe diode junction voltage. However, the IDC current must be chosen to fit a PNP or NPN transistor; the bipolar transistor macromodel is neither PNP nor NPN type. An IDC branch is active _only_ at DC, ignored otherwise. LINEA - Page 27 of 71 OPERATIONAL AMPLIFIER MACROMODEL DETAILS The equivalent operational amplifier macromodel is as follows: +Input node Output node o--- ------*-----*----- -----*----o | | | | | | | | | | | | | | Rin -> GMS+ GMS- Cfc Rfc -> GMSo Rout | | | | | | | | | | | | | | *--------*-----*-----*----*--------*----* | _ | | /| | Rin -> o | Common node | o--- GMS+ dependent on Rin at +Input; -Input node GMS- dependent on Rin at -Input with gm negative; GMSo dependent on Rfc Where: Av = open-loop voltage gain Fc = 'corner frequency' or 'breakpoint' where Av magnitude begins to decrease 20 db per decade. Rfc = 1 Ohm gm+ = transconductance of GMS+ = 1 gm- = transconductance of GMS- = -1 gmo = transconductance of GMSo = Av / Rout Then: Cfc = 1 / (Fc x 2pi) The center of this op-amp macromodel is a summing point for the current analogue to the non-inverting and inverting voltage inputs. It also modifies the DC open-loop gain over frequency. Output is a current analogue of the voltage at this center, summing 'node', multiplied by Av and divided by output source resistance. LINEA simplifies this model by reducing 8 branches to only 5, using mathematical equivalents to the center summing node and output GMS. Each input node still 'sees' only R-input and the output node still has Rout. The break-point frequency is found in manufacturer's data sheets. Most op- amp ICs have more than one breakpoint frequency, the first somewhere around or below 1 KHz, others about a decade or two higher. Any higher than the first can be simulated by creating an external GMS-R-C cluster. Modelling additional breakpoints are explained in Model Tips and Hints later in this manual. "Input resistances" are seldom specified for op-amp ICs. Their existance in the macromodel is required for internal mathematical analysis-solution of dependent current sources. An approximation can be done by entering a very high resistance value. Since the exponent range of non-integer numbers in LINEA is very large, a high, seemingly-impractical value will not disturb analysis-solution calculation. LINEA - Page 28 of 71 ENTERING CIRCUIT COMPONENTS --------------------------- This is a step-by-step procedure on entering circuit components in LINEA. The process begins after entering "NEW" at the Main Command level. Note that ALL input to any one prompt is considered a "data word;" that is, one or more data items within the word must be separated by commas, semicolons, or forward-slants, no spaces. There is no need to memorize any special order of data entry; prompts for all items are self-explanatory. BRANCH ENTRY, SINGLE-VALUE BRANCHES The first prompt will be: Branch 1, Type, Plus-node, Minus-node: The user has a choice on input, Type description alone or Type description with the Plus and Minus nodes. Assume that RESISTOR was entered by itself, no node numbers. This results in another prompt: Branch 1, Type "RESISTOR" Plus-node, Minus-node: With the second prompt, the user gets verification that RESISTOR was indeed the Type description (LINEA supplies the double quotes around RESISTOR). LINEA requires _some_ kind of numerical data in response and will keep requesting until it gets something. Let's say that the Plus node was 2 and the Minus node was 3. Response to the prompt would be simply "2,3". Supplying all three data items would have an entry to the first prompt of "RESISTOR,2,3". If a mistake was made in entry and it became "RESISTOR,2,2", then LINEA would recognize that both nodes were equal and the screen would show: Nodes may not be equal, please re-enter. Branch 1, Type, Plus-node, Minus-node: Let's assume that entry was good, that the Type description is RESISTOR, the Plus node is 2, and the Minus node is 3. The next prompt would be for the Value: Resistor value [Ohms]: Let's say the value is 4700 Ohms. Scaling letters can be used and an entry can be "4.7K". Or, E-format can be used for an entry of "47E2" or "4.7E3". Or simply "4700". Whichever format is easiest for the user is fine with LINEA. Completion of Value entry results in a prompt for the next branch: Branch 2, Type, Plus-node, Minus-node: Note that the branch number has been incremented in the prompt. This incrementation will repeat until the list is terminated or after it has LINEA - Page 29 of 71 completed Branch 200. Maximum number of branches in LINEA is 200. To end the circuit list entry at any time, just enter END or EN or E or ND or N for the Type description, no node numbers. List entry will terminate with a prompt showing the total number of branches and the node of solution being the highest node in the circuit list...then return to Main Command level. Suppose that the resistor value should have been 47 KOhms instead of 4.7 KOhms and this mistake is seen. To correct it quickly, just enter "BAK" or "BA" or "B" and the list entry 'backs up' to the previous branch's prompt for Type and Nodes. Re-entering everything is required. A mistake in Value entry could be corrected later by the MODify command... but that requires a note to oneself to do so. Going back one branch is easy enough to do now and corrects the entry immediately, allowing concentration on entering all the other branches in the list. BRANCH ENTRY, DOUBLE-VALUE BRANCHES The same Type and Nodes prompt is issued for every branch; LINEA doesn't know what Values are required until the Type Description is entered. For example, suppose the branch was type LQ, a single inductor with specified Quality factor. After completion of Type and Nodes entry, the Value prompt would be: Inductance value [Henries], Q [Units]: Suppose the inductance was 56 microhenries with a Q of 70. The data word entry would be "56u,70". Note the _lower_case_ "u" for 'micro'. Scaling Letters in entry must use lower case for multipliers less than unity, upper case for greater than unity. If there was a mistake made and one Value was not entered, LINEA would detect that and issue the error message: Caution: One or both values zero, please re-enter ...and then return to the Value entry prompt for that branch. That same "zero" caution would appear with single-value branches if the single Value entry was zero. LINEA expects _something_ in the Value and keeps prompting until it is entered. QUICKER ENTRY, SINGLE-VALUE AND DOUBLE-VALUE BRANCHES LINEA has a built-in 'shortcut' to allow entry of everything about simple branches on one line. Once the user becomes acquainted with Value entry order, Values can be entered as part of the data word following the Type and Nodes data items. For illustration, suppose the two previous examples were connected to the same nodes; the screen display would look like: Branch 1, Type, Plus-node, Minus-node: RESISTOR,2,3,4700 LINEA - Page 30 of 71 Branch 2, Type, Plus-node, Minus-node: LQ,2,3,56u,70 It should be emphasized that users should not try this until they are familiar with the Value entry order. It is easy to mix up two values...but the Type description and Value entry order match...L is first, Q is second in an LQ. In both kinds of R-L and R-C combinations, Resistance Value is always first. DEPENDENT CURRENT SOURCE VALUE ENTRY Whether the Type description is GMS or HFS, the second Value data item is _always_ the dependent branch identification. This identification can be done either by dependent branch's Branch Number or by its entered Type Description. If the Type Description is used for identification, then it is required that the dependent branch should have additional characters to make it distinctive; the minimum Type Description entry might be repeated the same way in several circuit list locations. For example, suppose an HFS has a current gain of 1 and it is dependent on a resistor in Branch 6 which has the Type Description of "R-78". The screen display of Value prompt and subsequent keyboard entry would like: Current Gain [Units], Dependent Branch No.: 1,R-78 -or- Current Gain [Units], Dependent Branch No.: 1,6 Either form of entry is correct. LINEA checks the data of every branch after Circuit Entry termination. Dependent branches must be passive types and they must exist in the circuit list; if incorrect, an error message is made and the dependent current source is switched open. Should that error happen, the MODify command can be used to correct the dependent branch identification. SIGNAL (GENERATOR) VALUE ENTRY Value prompt for a SIG Branch Type is: Signal-source cur.[Amps], phase-angle [Deg]: Phase angle does not have to be entered. Omitting it will make the phase angle zero. A circuit list may have more than one SIG and each one may have a different current magnitude and phase angle; all stimuli are "locked" frequency-phase, so phase angles are relative to one another. Current magnitude _and_ phase angle applies only to frequency-voltage solutions. For time solutions, current magnitude entry is equal to the peak current of a waveform. Any phase angle entry is ignored for time solutions. On output of a circuit list, the display will be as if the circuit had a frequency-voltage solution; i.e., magnitude and phase-angle. A zero phase- angle will not be displayed, only assumed. LINEA - Page 31 of 71 MACROMODEL ENTRIES Only the Type Description of a macromodel is required at the Type and Nodes prompt. Once the Type Description is entered, a second prompt for specific nodes for that macromodel is given. For illustration, let's assume a Bipolar Transistor called "Q67" is to be entered beginning at Branch number 5 with Base node at 8, Emitter node at 9, and Collector node at 10. The screen display of prompts and entries might look like: Branch 5, Type, Plus-node, Minus-node: Q67 Base, Emitter, Collector nodes: 8,9,10 If the LINEA user is familiar with node entry order, the one-line 'shortcut' method can be used. The screen display of prompt and entry might look like: Branch 5, Type, Plus-node, Minus-node: Q67,8,9,10 Either form is correct for LINEA. Once all the nodes have been entered, the first set of Values is prompted. There is no further 'shortcut' entry method for Values of macromodels. Users have to follow the prompts. Node entry order for other macromodels is as follows: Transformer > Primary, Secondary, Primary Return, Sec. Return nodes Transmission Line > Input, Output, Common nodes Op-Amp > Non-inverting Input, Inverting Input, Output, Common nodes Note that while the transformer macromodel is designed for DC isolation, one node of the primary and one node of the secondary may be the same node. The Transmission Line macromodel is entirely passive. "Input" and "Output" labels only serve as identification. REQUIRED-LISTED MACROMODEL VALUES Individual macromodel branch data is not immediately available. Macromodels are described and listed in parameters which apply to the entire macromodel. These parameters are: Transmission Line * Characteristic Impedance in Ohms. * Velocity of Propagation (if entered zero, defaults to 0.75) * Length in inches (If length is Metric, users must convert convert prior to entry, using legal conversion of one inch equals 2.54 centimeters) * Attenuation per 100 foot length (obtained from cable tables or handbooks) If the attenuation of the entered line length is known, user should enter Attenuation-per-100-feet as known-attenuation LINEA - Page 32 of 71 multiplied by 1200. There is no compensation of attenuation variation with frequency; users must limit frequency-sweep range for accurate attenuation effects. Ideal Transformer * Primary Inductance * Turns ratio, primary to secondary * Coefficient of coupling Coefficient of coupling is limited to a range of 0.01 to 0.99. Bipolar Transistor * Hfe, forward current gain, common-emitter (at Ic) * Ft, cutoff frequency (at Ic) * Ic, average DC collector current * Hoe, collector conductance, mhos, common-emitter (at Ic) Collector current DC value must be entered even if the Base bias network is described in the circuit. LINEA does not "set" the DC collector current from any DC bias network. Operational Amplifier * Open-loop Voltage Gain in Decibels * "Corner" frequency where 20 db slope per decade voltage reduction intersects open-loop voltage gain. * Input resistance, assumed identical for both inputs. * Output source resistance. SEEING THE FULL CIRCUIT LIST Enter "LIS" or "LI" or "L" at the Main Command level. The Circuit List will appear headed by a title display. For long lists, the Pause key may have to be pressed to stop scrolling. Branch information is reasonably easy to understand without further explanation. Note: Although all non-integers are stored internally to the equivalent of 15 decimal digits, Value display is rounded-off to no more than 6 decimal digits. Any OPEned branches will be indicated by the * asterisks * in the spaces between that branch's data. The last line of the title block also displays branch numbers of opened branches; if none are switched open, the last line indicates so. Dependent branches in a dependent current source List-line are identified by both list branch number and Type Description, in that order. LINEA - Page 33 of 71 CIRCUIT LIST HARDCOPY Make sure the printer is powered on, then enter ON at the Main Command. The Main prompt changes from "MAIN*>" to "Main->" indicating the output is directed to the printer. When output is directed to the printer, there is no screen display for that output. All prompts, messages, entries will still appear on the screen but circuit lists, print tabulations and plot graphics are directed to the printer port. A reminder: LINEA takes care of full printer page formatting. Before sending anything to the printer, position the paper so that it begins on the top edge of the paper. The end of a printout will stop at the bottom of the last page, ready for the next page. If a printout has been completed and output is to be directed back to the screen, enter OFF at the "Main->" command prompt. The prompt changes back to "MAIN*>" and the printer 'pops' one line feed, positioning itself at the top of the next print page. That 'pop' is a peculiarity in I/O handling of the MS-FORTRAN runtime package; the last character, usually a line-feed, is stored internally and will not be sent out until another output is started, the printer port is closed (OFF command), or LINEA is exited. CIRCUIT LIST EDITING -------------------- The Edit commands are ADD, MODify, DELete, INSert, OPEn, and CLOse. They are all done from Main Command level. Except for ADD, which re-starts Circuit Entry immediately after the highest branch in the current list, all will return to Main Command level when completed. All Edit commands have been described prior to this section. Except for ADD, they will require a branch identification. That identification may be either Branch Number or full Type Description. If the identification is incorrect, a warning message will be displayed and no further action taken except a return to Main Command level. A reminder: Except for OPEns and CLOsures, alterations in the Circuit List are _final_. Old values and deleted branches cannot be restored. If versions of a circuit are desired to be kept for comparison, they can be sent to disk. See Disk Operations for storage and retrieval. SPECIAL NOTE ON INSERT COMMAND On the "INS ", the refers to where the new, INSerted branch will be located. The current will be moved up in the circuit list to INSert the new branch. From there, everything is as it was with Circuit Entry, except that completion of a single branch or macromodel INSert will return to Main Command level. SPECIAL NOTES ON ALL MACROMODELS When an Edit command identifies a macromodel by Branch Number, it is possible to call out _any_ of the 3 to 5 branch numbers of that macromodel or just the Type Designation of the macromodel. LINEA takes care of LINEA - Page 34 of 71 identification/ordering of a macromodel. A MODify will not operate with macromodels. INSert, DELete, OPEn, CLOse will all operate on the _entire_ macromodel. It may not be desireable to OPEn and CLOse an _entire_ macro-model; it may be preferred to disconnect/connect just one node. In that case, sacrifice a branch and node such that a single branch connects that macromodel node to the rest of the circuit. The single branch could be switched OPEn or CLOsed to achieve the disconnect/connect of one node. DISK DATA FILES --------------- LINEA has three types of data files, identified by file extension: .LIN = Circuit Lists .LNA = Solutions .LWC = Waveform coefficients. The file extensions are appended automatically for both reads and writes. Users need only specify the filename. Filename follows DOS syntax: 8 characters maximum, first letter alphabetic, underline and dash allowed as symbols, no spaces within filename. DOS itself does error-checking on filenames; LINEA interprets some DOS error codes to present clear-language error messages. All data files have values written in ASCII characters, and are otherwise indistinguishable from text files. For data field specifications on all data files, see the Appendix. SETTING THE DATA STORAGE DRIVE:\DIRECTORY PATH At LINEA start, the Drive and Directory for all data files is, by default, the same Drive and Directory where LINEA itself is located. The user may specify another location from the Main Command level by entering DRI or DIR. LINEA will display a prompt for the Drive:\Directory entry showing the entry length for the Drive:\Directory string between vertical bars. Use conventional DOS syntax with the Drive:\Directory string; i.e., alphanumeric characters, no punctuation, limiting symbols to dashes and underlines, 8 characters per directory name. The following entry would be acceptible: C:\IN1492\COLUMBUS\SAILED\OCEAN\BLUE\ ^ The trailing back-slant delimiter symbol need not be entered...LINEA will include it if missing. Drive C: and all five directories should already exist. LINEA will reject all read/write commands to non-existant drives or directories. Note: To check the disk(s) or to inspect the available directories, enter "DOS" from Main Command level, then enter "COMMAND" (7 letters) to stay in the DOS shell. Conventional DOS commands can be used for inspection or directory creation. When DOS operations are completed, enter "EXIT" (4 letters) at DOS level to return to LINEA. LINEA has LINEA - Page 35 of 71 remained in memory, all data intact. For short Drive:\Directory strings, it is possible to enter everything in one line at the Main Command level. The preceding example could have been entered as: DIR C:\IN1492\COLUMBUS\sailed\ocean\BLUE Alphabetic character case is not important on entry. Each Drive:\Directory entry completion has a confirmation prompt repeating the entry in all- capitals. READING/WRITING CIRCUIT FILES To read in a Circuit file, enter "R " at Main Command. If no filename is entered and no circuit list exists, LINEA will prompt for the filename, the prompt including an 8-character space for the filename. If a circuit list exists, or did exist, the circuit _filename_ is in storage and LINEA will display the name, then query whether or not to use it. The prompt ends with "[Y/n]" and the capitalized "Y" indicates that depressing the key alone will signify a Y for yes. Entering N (no) to the query displays a prompt for a new filename entry. When the entry is completed, the Circuit read is done and a prompt is shown, indicating "New circuit read in, old circuit discarded." This is followed by a display of the node of solution, the highest node number in the circuit. To write an existing Circuit to a disk file, enter "W " at the Main Command level. If the filename is omitted, LINEA will prompt for one in the same manner as a Read. Caution: Using the same filename as an existing file will cause the existing file to be over-written. The only way to save an existing file is to vary the filename of the Circuit to be written. When a Circuit Write is completed, control returns to Main Command level without further reminders or prompts. CIRCUIT CREATION DATES AND REMARKS Any time a Circuit Value is MODified, or any time a branch is DELeted or INSerted, that time will be set into the "creation date" of the Circuit. Creation Date is Read from, and Written to, disk. That is separate from DOS' own file Write time-stamp; alteration may take place some time before a new file is written. Creation Date is a convenience for keeping track of several Circuit versions. It is also useful to include short notes about a Circuit. The "REM" (also "*") entry at Main Command level allows writing a 47-character Remarks string for such notes. The Remarks string can be entered between vertical bar symbols or directly, using "REM ". Depressing the key without entering anything will result in a blank Remarks string. LINEA - Page 36 of 71 A Remarks string will remain as-is until changed manually or a new Circuit is read in from disk. A Circuit Read will displace any old Remarks string with that stored in the file, including any file-stored string which is all-blanks. SOLUTION STORAGE AND RETRIEVAL Any completed Solution may be SAVed by entering "SAV " at the Main Command level. If is omitted, its entry will be prompted. Data stored consists of the magnitudes and phase angles over all frequencies of solution, frequency limits, type of solution (frequency- voltage, impedance, etc.), time-and-date of solution, and the filename of the Circuit solved. Solution filenames may be the same as Circuit filenames; file extensions identify which is which. A Solution may be retrieved by entering "BRI " at the Main Command level. ('BRI' for BRIng back) This restores the solution data and displays the filename of the Circuit solved (stored by a SAVe). Solutions may be viewed directly but _conditions_ of analysis-solution may not be changed; i.e., if a frequency-amplitude solution is brought back, you cannot request an impedance solution since the circuit itself may be missing or the circuit does not have the same node maximum. Similarly, you cannot change the Node of Solution other than what was originally SAVed. Some care should be exercised with BRIng. You may BRIng back a PLOtted solution, change scale limits to whatever you want, print out a new PLOt, even do a PRInt-tabulation. This can be very useful in recording analysis data or visually comparing solutions, but there is no greater capability of the function. Note: A great number of combinations of conditions were tried for deliberately setting up a program crash situation. None were found but it might happen if BRIng is used improperly. The principal reason for Solution storage is to permit external program data formatting/presentation. Viewing or hardcopying previous solutions is only the secondary reason. WAVEFORM FILES LINEA does not create repetitive waveforms itself. Creation of waveforms and writing the resulting Fourier coefficients on disk is done with the WAVESPEC program, a stand-alone program in the LINEA program set (MWAVSPEC for Math coprocessor version). Please see the separate section on WAVESPEC for details of waveform creation. To begin a waveform description, enter the single command word "WAVe", "WAV," "WA", or "~" at Main Command. The result is a prompt of "Please enter WAVESPEC" (or "MWAVSPEC") with the cursor dropping to the next line with no further prompts. Keying in WAVESPEC will run that program with LINEA (and all LINEA memory) intact in memory. An exit of WAVESPEC will automatically return you to LINEA. Note: Insufficient free RAM in your system will not allow simultaneous program retention. 384K minimum free RAM space is recommended; if less than that, WAVESPEC can be run separately. LINEA - Page 37 of 71 Entering "GET " at Main Command will read in an existing waveform file. If is omitted, a prompt will be issued for the filename. If is not in the current drive and directory(s), LINEA will inform you of that and return to Main Command level, cancelling any disk operation. Waveform data is stored in LINEA memory separate from other data. Reading in a waveform will not disturb any frequency-voltage or impedance solutions, nor any frequency-sweep or time reconstruction interval settings. LINEA does not alter waveform files in any way; there is no corresponding command to write a waveform file. Only WAVESPEC can write a waveform data file. SOLUTIONS AND OUTPUT -------------------- GENERAL SOLUTION ORGANIZATION OF LINEA LINEA has three major solution forms: Frequency-voltage ('Frequency'), Impedance, and Repetitive-waveform-Time-related. Frequency-voltage solutions yield voltage magnitude and phase angle at one selected Circuit node at each frequency of a specified frequency sweep. Impedance solutions find the impedance at one selected node at each frequency of a specified frequency sweep. Frequency sweep is selectable up to a maximum of 200 discrete frequencies. Repetitive waveforms exist within LINEA as Fourier coefficients, frequency spectra with each harmonic amplitude and phase being derived by a time-to- frequency transform. Waveform coefficients become the stimuli for all time-related solutions. Time-related output is selectable as the spectrum of coefficients ('Spectra') or through a frequency-to-time transform to yield the direct waveform ('Time') or envelope of an amplitude-modulated waveform ('Envelope'). Each waveform will normally have 200 coefficients. AM-modulated RF waveforms will have +/- 99 sidebands to a carrier frequency. Two forms/format of output are selectable: Tabulation ('Print') of written values or Graphical ('Plot') equivalent using characters in a simulated plot. Either output form is available from one solution. LINEA compares all requested solution-output combinations requested with previous solution-output combinations, calling the time-consuming mathematical analysis-solution calculation routine only when required. Users need only request output and form. SCALE LIMIT SELECTION ON PLOT Every parameter kind in a PLOt is scanned for minimum and maximum value, then displayed with a query as to whether those extremes are to be used as scale limits. Pressing the key without entering anything else will set solution extremes as scale limits. Entering specific numerical values will make those values the scale limits. LINEA - Page 38 of 71 If desired, all PLOt scales can be 'flopped' left-for-right by specifying scale limits in reverse order. Specific scale value entries follow the 'data word' rules of LINEA. Omitting a data item, entering only the separator character (comma, semicolon, forward-slant), will make that data item zero. Degree limits for phase angles in Voltage and Time-related PLOts are fixed, _not_ set by the solution. At LINEA start, those degree limits are -180 and +180 degrees. Degree limits may be set to anything else and will remain at those settings until changed again. TWO FORMS OF IMPEDANCE PLOT Either Polar or Rectangular form may be selected for Impedance PLOts (both forms are tabulated together in PRInts). At the query, pressing key without entering anything else will select Polar form; an "N" for 'no' must be entered to select Rectangular form. Polar form _phase_angle_ scale limits are default-set by solution values or reset by user entry, an exception to the Frequency-Voltage or Time-related PLOt degree setting rule. TIME WAVEFORM PLOT RECONSTRUCTS Waveform reconstruction (frequency-to-time transform) is another time- consuming routine. When that is in process, the screen displays the Rotatating Twiddle Character and "Working!" as when the analysis-solution routine is in process. The two are separate routines. Waveform reconstruction requires only that all coefficients be analyzed- solved once for any selected node. The frequency-to-time transform depends on TIMe Limit settings for final output. TIMe Limit setting changes, without changing the node, will only invoke the transform, not another analysis-solution. It is possible to set TIMe Limits for as many as 800 reconstructed waveform voltages at any node. That would be 16 pages on the printer, either PRInt or PLOt. SYNTAX ON SOLUTION TYPE AND FORM Only two Main Command words are required, one to select Type, the other to select Form. They may be in either order. "PRInt FREquency" will yield the same solution and tabulation as "FREquency PRInt." Or, to simplify entry, "P F" or "F P." Or a three-letter acronym can substitute for either double word. "PRF" would be equal to "P F" or "F P", itself being an acronym for PRint Frequency. TIME-RELATED OUTPUT "T
" will yield a waveform reconstruct. "S " will output the frequency coefficients of the waveform as they appear at the selected node. LINEA - Page 39 of 71 For video waveforms, the first coefficient is always at DC, all subsequent coefficients at multiples of the repetition frequency. For amplitude-modulated RF waveform stimulus, "T " yields the _RF_ waveform over time while "E " yields the _modulation_envelope_ over time. "S " will have coefficients represented by lower and upper sidebands with RF carrier at mid-point. Modulation ENVelope is equivalent to monitoring with an infinite-impedance, linear full-wave detector with positive-going output. This is more convenient when the RF carrier is much higher than the repetition frequency. For video waveforms, both "T " and "E " yield identical results. All time-related outputs have time-zero as the beginning of the repetition period. GENERATING WAVEFORMS If there is a minimum of 384K free RAM in your computer, you can begin waveform description via WAVESPEC by entering "WAV" at Main Command. The screen will appear to have the cursor at the next blank line under the "Enter WAVESPEC to begin description" prompt. Enter "WAVESPEC" (8 letters) to invoke it; LINEA has moved to protected memory, data intact, and the keyboard input will be to DOS. WAVESPEC program commands and operation are given in a separate section of this documentation. Waveform data is, so far, only transferrable via waveform data files on disk. Manual recording of waveform filenames must be done at present. Waveform data involves considerable information, moreso than simple frequency sweeps. WAVESPEC has identical PRInt and PLOt functions to ease some of the recordskeeping. Quitting WAVESPEC will do an automatic transfer to LINEA, program memory intact. There is no intermediate step to DOS before transfer. If free RAM space is limited, WAVESPEC can be run as a stand-alone program, waveform data files used as the link between WAVESPEC and LINEA. GENERATING PLOT ARTWORK ASCII-character "plotting" is rather coarse. Quick, yes, but still too coarse for smooth graphic output. The character plot outputs can made in sections so that a 2X to 10X larger master can be generated for tracing finished art. The only requirement is that frequency spacing is continuous and the scale extremes set to allow amplitude-phase-delay to be continuous. All scale extremes may be set manually, including reverse, left-for-right direction. Solution files may be read by an auxilliary program (not included) which can format data to whatever output device is available. Solution file data is composed of ASCII characters in generally-decimal format. Records and data fields are described in the Appendix. LINEA - Page 40 of 71 SINGLE DC OUTPUT It is possible to PRInt and PLOt zero-frequency (DC) output but hardly necessary to send such output to the printer. A DC-only PRInt or PLOt will have only one line; manual notation at each node will be as easy as printing one page for each node. To set DC-only from Main Command, enter "F DC" or "F 0,0,0". There are no provisions yet to analyze-solve all nodes at one output. It is possible to examine the DC stability of transistor bias networks and the like, but somewhat cumbersome to perform with LINEA. A branch(s) for base-emitter diode voltage drop must be added and, possibly, an IDC branch to simulate varying supply voltage to the bias network. MODify edit functions can vary those values, plus the bias network values to see the effect of change. It may be that conventional, manual techniques, using a pocket calculator are quicker and easier. CONVERTING FROM SCHEMATIC TO LISTING ------------------------------------ LINEA doesn't have any way to convert from a symbolic schematic drawing to a Circuit List. To fully analyze and solve frequency response of a circuit, you need to convert the components into the nodes and branches which LINEA will recognize. Most of those branches are simply duplicates of schematic symbols. IN THE BEGINNING... ...there was scratch paper. As a suggestion based on others' experiences, enough paper should be available so that you can redraw schematics, make notes, and tabulate all the branches before keying a circuit into LINEA> A few things will not appear the same as either schematic or actual actual circuit or may require different components. Redrawing the schematic saves the original diagram. Node numbering can follow signal flow, low node numbers toward input, high numbers toward output. That also results, generally, in quicker solution execution times. LINEA produces the same solution results regardless of node ordering. One method is to mark redrawn schematics with node numbers enclosed in a circle, a distinctive marking not usually used as a symbol except in "Sams Photofact" (tm) schematics. Passive components can convert readily to single branches. Since LINEA allows up to 8 characters for type descriptions, you can use conventional reference designations such as "R-12," "C-5A," and so forth. Follow the signal flow again, branches beginning at signal input, generally ending at signal output. NODE NUMBERS MUST BE CONTIGUOUS LINEA will check for missing node numbers and display a prompt indicating LINEA - Page 41 of 71 each one. LINEA won't "crash" but it will stop analysis of the circuit (error message shown) or result in zero node voltage or impedance. It is better to organize the node ordering in the beginning to avoid missing node numbers. During the course of analyzing-solving a circuit, a connecting branch may be manually OPEned. If such an OPEn results in the equivalent of a missing branch number, analysis may stop with an error message or produce a zero solution. Again, non-fatal, but it can cause some confusion until the user understands what was done. It is better to plan ahead and anticipate which branch openings might result in breaking signal flow. COMMONS, "GROUND" AND SUPPLY LINES Overall circuit 'ground' (or 'earth' common) is ALWAYS node 0. Always. Power supply lines can _also_ be node 0...provided they are well bypassed to ground in the actual circuit. This is a startling departure from usual circuit thinking but, considering LINEA does the equivalent of "small- signal" analysis-solution in frequency domain _only_, quite acceptible. LINEA doesn't normally set bias, enabling DC control of collector current, or the like. In "small-signal," frequency-domain analysis, all voltages are presumed to be linear. There are no provisions for simulating transistor or diode saturation or cut-off. As far as AC and RF are concerned, power supply lines are just another common; if well bypassed to ground, they can BE ground to LINEA. If there is some doubt as to a supply line's bypassing, use a separate node or nodes for that line and simulate the bypassing, using series R-C branches for electrolytics (resistance approximately calculated from an electrolytic's ESR), possibly even small inductances in series with capacitors. It is possible to model a very-high-gain amplifier circuit in LINEA. [over 200 db gain is possible] High-gain amplifiers might have destructive feedback via inadequate supply line decoupling. LINEA can show such feedback without simulating the oscillation that would happen with a real- world circuit. PARASITIC REACTANCE, RESISTANCE LINEA branch types LQ and CQ are good for simulating lossy reactances at RF. For practical programming and memory reasons, Q is the same at every frequency except DC. A quick look at Q tables from manufacturer's data sheets indicates Q does vary at least 2:1 over a wide frequency range. Accurate simulation might require limiting analysis bandwidth, modifying Q for the next limited analysis bandwidth, and so on. LQ branches are simulated internally by a series R-L equivalent, resistive part equal to inductive reactance magnitude divided by Q. CQ branches are simulated internally by a parallel R-C equivalent, conductive part equal to capacitive susceptance magnitude divided by Q. Together, an LQ branch and a CQ branch can accurately portray an L-C resonant circuit. LINEA - Page 42 of 71 Resistors have some parasitic capacity in parallel with resistance, varying from 100 femtofarads (SMTs) to 1 picofarad (axial-lead types). At frequencies where that capacity becomes significant, a PRC branch should be used. If a circuit has very long leads on a resistor, lead inductance can have an effect on total component impedance but can be simulated with an SRL branch. A capacitor with lead inductance or an inductor with lots of winding capacity must each use two branches. The most difficult part about modelling parasitics is _knowing_ what the parasitics are. LINEA can't help you there, but, once known, LINEA can simulate parasitics exactly. CURRENT THROUGH DEPENDENT BRANCHES Using a type HFS dependent current source to monitor current through a branch is an excellent _non-intrusive_ technique of analysis. There is absolutely no 'probe capacity' or change in any measured branch due to the real-world measuring equipment. However, some of us 'schematic oriented' analysts may fall into a trap with certain branches. LINEA's double-component branches LQ, CQ, SRL, SRC, PRL, and PRC are analyzed as complex quantities at each frequency. If you want to measure the current through an LQ, you will get the current through the _entire_ series R-L equivalent branch, not just the inductor. With a type CQ, current is the total to the parallel R-C, not just the capacitor. Measuring separate resistive or reactive currents requires a circuit having only resistance or reactance. VOLTAGE ACROSS DEPENDENT BRANCHES The voltage across a dependent branch for a type GMS dependent current source is straightforward. It should be kept in mind that voltage polarity depends on the ordering of Plus and Minus nodes for a dependent branch. You can visualize a GMS's dependent branch as having a differential voltmeter connection to the GMS...reversing the 'voltmeter' leads will reverse the 'reading' polarity. CREATING "STIFF" VOLTAGE SOURCES Ideal current sources have infinite source resistance. Voltage across such a source is the voltage drop across _everything_ connected to that source. While that will correctly model a transistor collector or drain, or a vacuum tube plate, you may want a very _low_ impedance voltage source or one with a specified source impedance. LINEA allows real-world-impractical voltage sources. A 1000 Ampere current source across a 1 milliohm resistance will produce a 1 Volt voltage source having a source impedance of 1 milliohm. Add a series resistance of, say, 50 Ohms, and you have a voltage source with a 50 Ohm source resistance. A Mega-Ampere current source across a micro-Ohm resistance makes an even 'stiffer' voltage source. Such is quite within the magnitude range of LINEA. LINEA - Page 43 of 71 NEGATIVE RESISTANCE OR REACTANCE There are a few _theoretical_ equivalents to real-world circuits that require 'negative' value components. LINEA allows this; just enter a negative resistance, capacitance, or inductance. Negative values do not change the magnitude of single-component branches, only the phase-angle/polarity. A negative inductor has inductive reactance magnitude proportional to frequency, a negative capacitor has capacitive reactance magnitude inversely proportional to frequency. OPERATIONAL AMPLIFIER CIRCUITS All 'Op-Amp' Integrated Circuits have a built-in "breakpoint" frequency where the open-loop gain begins to fall at a rate of 20 db per decade of frequency...and also produces a definite phase-shift at higher frequencies. This _will_ affect overall response of ideal voltage-frequency-selective circuits which don't have compensation for that Op-Amp phase shift. If you are analyzing a circuit which is questionable as to such phase-shift compensation, I would advise setting all Op-Amp macromodels to high Megahertz breakpoint frequencies at first. Get a hardcopy response printout, then replace all the Op-Amp macromodels with those having a lower breakpoint frequency, re-analyze and compare the responses. Note: At least two hardcover textbooks have circuit examples and tables of values, all of which assume _ideal_, no-breakpoint Op-Amps. Such circuits will only work as advertised over a frequency range _below_ real-world Op-Amp breakpoint frequencies. FIELD-EFFECT TRANSISTOR MODELS These were not included in LINEA because they are simple enough to model with four conventional branches: Three single capacitors representing the three junction capacities and a GMS across the Source-Drain junction dependent on Source-Gate capacitance voltage. BANDWIDTH-ALTERABLE NETWORKS WITH THE TRANSFORMER MACROMODEL Double-tuned transformers with specific coupling coefficients are a simple way to set the passband of an amplifier. Coupling coefficient k is one of the critical items. The transformer macromodel can be used quite effectively in the analysis-solution of such circuits since coupling coefficient is one of the parameters of the macromodel. There is one word of caution on such use: The macromodel does not include quality factor Q and Q is often the other critical parameter. Q of a tuned transformer can be modelled with parallel resistances across each winding. Resistance value is Q times the resonance-frequency inductive reactance. An alternate can be a series resistance with each winding, resistance equal to resonance-frequency inductive reactance divided by Q. The alternate requires at least one extra circuit node, which may not be practical in large circuits. LINEA - Page 44 of 71 Another possibility is to not use the macromodel at all and to manually calculate the four branch values illustrated under TRANSFORMER MACROMODEL DETAILS. The difference here is that each winding can use an LQ branch type instead of a pure inductance. CREATING "BLACK BOX" SUB-CIRCUITS If you have a component with _known_ characteristics over frequency, some creativity will allow a combination of branches to simulate that component. LINEA will allow tailoring that "black box" simulation to fit the known characteristics. That may take several nodes. To apply such a simulation to the entire circuit, it can be re-created there...but the nodes needed _within_ the simulation cannot be connected to other parts of the entire circuit. RECONSTRUCTING SCHEMATICS FROM CIRCUIT LISTS This is another manual task, probably taking more scratch paper than the original circuit list construction. Contiguous node ordering helps. Other than that, the task is strictly manual and time-consuming; keeping the original worksheets is a good idea. For those who would like to try a 'reconstruction' program to make a list- to-diagram conversion, circuit file data fields are explained in the appendix. LINEA - Page 45 of 71 DESCRIPTION/USE OF WAVESPEC =========================== GENERAL The WAVEform SPECification program is a stand-alone program used to generate repetitive waveform data files for use by LINEA. It takes manual data input as time-amplitude information and converts this, through a Fourier transform, into a set of 200 complex frequency coefficients. Waveform data input may be a simple, single pulse or a segmented waveform described by amplitude at equal time increments or by amplitude at individual time positions within the period. Waveforms may be converted to 100% amplitude modulation of a specified carrier frequency. WAVESPEC is applicable to independent study of frequency spectra of a time-amplitude specified repetitive waveform. WAVESPEC INPUT CONVENTIONS All functions in WAVESPEC (MWAVSPEC for Math coprocessor version) are controlled from a Main Command level, using 3-, 2-, or 1-letter command words. Command words have the same case indifference as LINEA. Where numerical data input is required, WAVESPEC allows the same Scaling Letter suffix option as LINEA; Scaling Letters are the only exception to case indifference. The Main Command prompt is "WAVE*>" with printer port off, "Wave->" with printer port on. When the printer port is on, all listings and graphical equivalents are sent to the printer port instead of the screen. Prompts and requests, warning messages go to the screen regardless of printer port status. Main Command words are one or two. One or more spaces separate the two. Data item words are always the second word and may consist of one to five data items separated by a comma, semicolon, or forward-slant (/). WAVEFORM DESCRIPTION MODES There are three ways to describe a repetitive waveform in WAVESPEC: 1. A single positive pulse having independent risetime, top-width, and fall-time. 2. Any positive waveform described by amplitude at equal increments of time within the period. 3. Any positive waveform described by _both_ amplitude and time position within the period. Maximum amplitude is always 1 Ampere peak positive, any description. Negative amplitudes are 'task-controls' and will not describe waveform amplitude by themselves. LINEA - Page 46 of 71 CONVERSION FROM VIDEO TO R.F. AND REVERSE CONVERSION All waveforms begin as video-mode waveforms; i.e., they have a DC value and 199 harmonics of the repetition frequency. These may be converted to 100% amplitude modulation of a carrier frequency, spectrum having symmetrical sidebands containing the _first_half_ of the waveform repetition harmonics. An "RF" waveform spectrum may be re-converted to Video by specifying a zero carrier frequency. This effectively halves the number of coefficients originally generated from input description; sidebands are "unfolded" and frequency-translated back to video. Conversion to RF, re-conversion to Video may be done repetitively to study the effects of limiting the number of harmonics or sidebands. RECONSTRUCTION OF ANY WAVEFORM WAVESPEC has the same Print/Tabulation and Plot/Graphical-equivalent output as LINEA. Any waveform may be reconstructed from frequency-domain coefficients to time-amplitude, including individual RF cycles of a modulated carrier frequency. Carrier modulation waveform may be output in envelope form, envelope reconstruction done by a frequency-to-time transform of the RF spectrum. Output of waveform reconstruction is commanded by a word pair having an output Type (Time-amplitude, Spectrum, or Modulated-Carrier Envelope) and an output Format (Print or Plot), Type and Format being in any order. A single word (3-letter acronym) may be used in lieu of the word pair. DISK STORAGE AND RETRIEVAL OF WAVEFORM DATA Any described waveform may be saved to disk in spectrum form, or read in from disk to reconstruct the waveform for viewing. The Drive:\Directory path may be changed as desired; default is the same drive and directory as WAVESPEC itself. Users may temporarily access DOS from within WAVESPEC. OPERATION FROM LINEA WAVESPEC may be invoked from within the LINEA program by the WAVeform command word. Once that is done, LINEA will appear to display the cursor at a new line, no command-level prompt shown. This is actually at DOS level, LINEA having been moved to Background. The user must enter WAVESPEC to run that program. Once the WAVESPEC screen appears, LINEA and its data memory is intact in your system and nothing in that part of RAM is accessed by WAVESPEC. Quitting WAVESPEC will automatically return you to LINEA. Note: Your computer must have a minimum of 384K of free RAM for WAVESPEC to be run from within LINEA. If this is not available, WAVESPEC must be run as a separate, stand-alone program. There is no RAM data transfer between programs, data transfer is by disk. LINEA - Page 47 of 71 WAVESPEC MAIN COMMAND SET ------------------------- Command word minimum letters are denoted by capitals following. Command word entry may be of either case or mixed-case, CAPITALS shown here only for emphasis. EXIt EXI EX X - Exit/Quit WAVESPEC, return to LINEA (if invoked from QUIt QUI QU Q there) or to DOS (if run from DOS level). HELp HEL HE ? - Display up to 4 screens of brief descriptions of functions and commands. At Main Command only. TIMe TIM TI T - Output word. Used with a following numerical data word, enters time limits (minimum, maximum, delta) of reconstruction time. As one of an output Type- Format pair, commands reconstructed waveform output. SPEctrum SPE - Output word, used as Type in output Type-Format pair, SP S commands output of all frequency coefficients. ENVelope ENV - Output word, used as Type in output Type-Format pair, EN E commands output of modulation envelope of a waveform- modulated carrier. Note: If waveform is Video, will be the same as TIMe. PRInt PRI PR P - Output word, used as Format in output Type-Format pair, commands Print/Tabulation. PLOt PLO PL = - Output word, used as Format in output Type-Format pair, commands Plot/Graphical-equivalent using ASCII characters. PULse PUL PU ! - Describe single pulse waveform. EQUal EQU EQ U - Describe waveform by amplitude along equal time increments within period. INDividual IND - Describe waveform by both amplitude and individual IN I time position within period. RFCarrier RFC - Specify a carrier frequency which will be amplitude RF modulated by the described waveform. Note: Sidebands are symmetric about the carrier but are limited to half the Video coefficients minus one. CLEar CLE CL # - Clear coefficients, reset coefficient maximum to 200, reset to Video mode. ON ( - Turn on (enable) printer port for outputs. Main Command prompt changes to "Wave->". OFF OF ) - Turn off (disable) printer port for outputs. Main Command prompt changes to "WAVE*>". WRIte WRI WR W - Write waveform data to disk. 8-character maximum filename may be given as second command word or in LINEA - Page 48 of 71 response to following prompt for it. File extension of .LWC is automatically appended to filename. GET GE G - Get (read) waveform data from disk. Filename conventions are the same as WRIte. Primarily for viewing already-created and stored waveforms or for changing carrier frequency of an RF waveform. NAMe NAM NA N - Create or change filename of waveform currently in WAVESPEC. Note: If filename exists in WAVESPEC, a WRIte or REAd will query if that filename is to be used for the waveform data file. REMarks REM - Add 47-character maximum remark line to waveform RE * output and to waveform data file. MARgin MAR - Select left, top and bottom margins of hardcopy formatting. Identical to LINEA, margins are not transferred between programs, must be set individually. Default is 5 characters left margin, 3 lines at both top and bottom. DRIve DRI DR & - Set Drive:\Directory path of all waveform data files. DIRectory DIR DI Default is same path as that of WAVESPEC. DOS DO \ - Temporarily shell to DOS for any DOS function, returns to WAVESPEC on entering "EXIT" at DOS level. PRT - Single 3-letter acronym output command equal to PRInt TIMe word pair. PLT - Single 3-letter acronym output command equal to PLOt TIMe word pair. PRS - Single 3-letter acronym output command equal to PRInt SPEctrum word pair. PLS - Single 3-letter acronym output command equal to PLOt SPEctrum word pair. PRE - Single 3-letter acronym output command equal to PRInt ENVelope word pair. PLE - Single 3-letter acronym output command equal to PLOt ENVelope word pair. LINEA - Page 49 of 71 ENTERING WAVEFORM DATA ---------------------- SINGLE PULSE Enter "PUL", "PU", or "!" at the Main Command. A prompt will be made for the repetition period. Enter the _time_ of one period. A second prompt will appear for "risetime, top-width, falltime." Enter those, separating the numeric values by a comma, semicolon, or forward-slant. You must enter three values. The total time of risetime, top-width, and falltime must be equal to, or less than period duration. One or two values may be entered as zero. A triangle wave description of 200 microseconds total base length is entered as "100u,,100u" with the two successive delimiter commas indicating that top-width is zero. There is no input for peak amplitude. Peak amplitude with a single pulse is, by default, a maximum value of Unity. Amplitude at beginning and end of a single pulse is zero. On entry completion, there is a short pause while WAVESPEC computes the Fourier transform, followed by a screen prompt indicating "description completed." WAVEFORM AMPLITUDE AT EQUAL TIME INCREMENTS Enter "EQU", "EQ", or "U" at the Main Command. A prompt will be made for the repetition period. Enter the _time_ of one period. A second prompt will appear for the time increment. Enter the time increment. Time increment must be less than the period but may be an odd fraction of the period. There is a sequence of prompts for "amplitude at