I N T R O D U C T I O N

ALLTED is a CAE (Computer Aided Engineering) system for the simulation, analysis and design of such diverse devices as drives, control systems and dynamic systems composed of electronic, hydraulic, pneumatic, mechanical, electrical, electromagnetic, and other physical phenomena elements. This can be done considering each technology individually or in mixed combinations. Complex drives and systems of this type are widely used in modern aerospace, robotics, NC machine tools, test equipment, highway engineering, agricultural and other applications.

This book deals with the designing of electronic circuits using ALLTED.

The correspondence between the results of the analyses and the real circuit's responses depend on the level and accuracy of the active components models used in the electronic circuit. At the present time there are many semiconductor device models that can be used for computer design. The principal differences between each of the models are based on the initial assumptions made for the device's physical model and the number of physical effects that are taken into account.

The question of choosing a model often is resolved by compromising between accuracy and simplicity of the selected model. Choosing a very complex model for all tasks is not always a good decision. In a simple task it will take a great deal of computer time per one analysis while not enhancing the accuracy. Conversely, using too simple a model will sometimes lead to wrong results.

There is a set of models for active circuit components that can be considered as a standard basic set. These components are modeled by the equivalent macro circuit of nonlinear functions of sources, passive R, L, C elements, etc.

Presented herein is also a set of basic nonlinear functions commonly used for electronic circuit design. In the last section there are some practical examples of how to use such functions for equivalent circuit descriptions.

A significant part of the guide is devoted to the question of using digital integrated circuit macromodels. This approach is based on the assumption of correspondence between modeled and real time of delay and impulse front time for input and output signals. A basic set of macromodel functions and macromodels of standard digital circuit elements (OR, AND, counters, flip-flop trigger, register, etc.) are presented here.

ALLTED is "open" for the User both in terms of developing new models and modification of the models and nonlinear functions now available. Therefore, the ALLTED package, based on the user's insight concerning the systems under investigation and requirements for accuracy/ quality of results, can always be conveniently modified.

|| Next ||


Chapter 1

Integrated environment of ALLTED Studio

ALLTED is an acronym for ALL TEchnology Designer. It was developed not only for simulation and analysis, but equally for the optimization and design of Nonlinear Dynamic Systems composed of either/and electronic, hydraulic, pneumatic, mechanical, electromagnetic, and other elements. It can also be used for a single technology only, such as analysis and designing of electrical or electronic circuits.

This user's guide deals with the electrical engineering applications. In this field the SPICE application developed by the University of California is usually considered to be the de facto world standard. Since then many commercial derivatives have been marketed using the computing engine developed at Berkeley. In most cases these derivitives have been identified with a new letter prefix: P-, I-, H-, Z-, etc.

ALLTED, in contrary, is an independent proprietary design software system developed in the former Soviet Union concurrently with SPICE's on-going development. It uses more sophisticated algorithms to compensate for the then local computer scarcities/capabilities and to provide possibilities for analyzing and solving the same and even more sophisticated tasks in comparison with Western programs.

ALLTED is now available on the IBM personal computer where its speed and powerful features can readily demonstrate its superiority over other simulation programs.

ALLTED is capable of carrying out practically all design operations from the sketching of the schematic of an initial version of the circuit right on up to its final configuration. The values of all parameters, meeting the most stringent specification requirements, can be found through optimization, worst case design, statistical, Fourier, and other analyses. During the design process, steady-state, transient, frequency, statistical, and/or spectral (Fourier) analysis are performed followed by high-level design operations such as worst-case and sensitivity analysis, optimization, optimal tolerance assignment, etc.

ALLTED is easily adapted to the user environment. A large number of nonlinear functions, models, and macromodels have been developed and stored in the libraries to match the needs of a designer at all stages of the design process. And at the same time, new functions and models can be easily developed by means of the ALLTED input language, including the ability to describe an element by mathematical equations.

ALLTED determines a wide range of output characteristics. These can be used as arguments in objective functions and constraints to determine the optimal solution. The list of objective functions and constraints can be easily extended as well.

It allows the modelling and simulation of virtually any semiconductor device or nonconventional element. The program is easily adaptable to changes and advances in electronic and other technologies.

The electronic portion of ALLTED has a SPICE-like interface and functionality with the usual list of circuit simulation features: DC analysis and transient analysis of nonlinear analog and/or digital circuits of a complexity limited only by the memory and speed of your computer, and with AC analysis of linear or nonlinear circuits automatically linearized at their DC operating points. It has convenient subcircuit definition capability and device model definition capability. A large, expandable library of electronic models such as diode, BJT, FET and MOS devices, macromodels of digital and logical elements is included. In addition, ALLTED goes beyond other simulation programs due to such advanced features as Fourier analysis of transient solution, Monte Carlo statistical analysis or calculation of sensitivity coefficients for designated specified variables in the circuit.

General information about ALLTED Studio

ALLTED Studio is an integrating environment (further - environment or shell), which represents toolkit for organization of access to the solver (the calculating kernel) of the program All Technology Designer (further - ALLTED).

With help of ALLTED Studio you can work with ALLTED documents without leaving this environment, create new files of scheme (circuit) and task descriptions, look through result files: tables, plots and histograms, control tasks performance and run the editors of other files, which are registered in Windows Explorer (e.g., to edit document you can run Microsoft Word directly from ALLTED Studio). In ALLTED Studio environment you can also create and edit documents (ActiveX documents) associated with any installed ActiveX components, such as word-processors, editors of the diagrams and presentations. For example, your project can contain the following ActiveX documents:

* ALLTED Studio documents
* Project documents (Microsoft Word)

You can create, look through and edit these and other documents without leaving the ALLTED Studio environment.

You can add other files to your project. If the file is not connected with ALLTED Studio documents or ActiveX component, you can open this file from working area of the project in ALLTED Studio and start the application, connected with it in the other window.

ALLTED Studio includes the text editor, task forming facilities for the solver and output file viewing facilities ( for plots and diagrams).

Basically, your work will occur within the working area of the project (Workspace). This requires knowledge of the basic methods and principles of work both with working area of the project and basic elements of the user interface. The working area of the project can include various projects (or versions of the same project).


Chapter 1

Files, projects and Workspace

Using working area of ALLTED Studio projects you can easily organize your projects and files, contained in these projects. Namely:

  • add, delete and create new projects,
  • open files for editing or run editors, connected to them,
  • create and delete files.

On your desktop the working area (Workspace) is presented as a window with the treelike list of the projects and files, included in them, which are grouped according to their destination:

  1. Task Files – all ALLTED task files (*.atd)
  2. Scheme Files – ALLTED (*.ats) and Spice (*.sps) scheme files
  3. Result Files – files of calculation results for Diagrams (*.atr) and Histograms (*.ath)
  4. Output Files – text results files, protocol files (*.ato)
  5. Other Files - files of other types

Double click of the mouse will open the selected file for editing (viewing). If the file is an input or output file of the calculating part of ALLTED or ActiveX document , the appropriate editor of this file will be opened in integrating environment, otherwise the external editor, connected to this file type, will be opened in the other window.

ALLTED Studio contains dialogue boxes for creating working area, projects, files and other documents. When creating new working area you should specify (besides the file’s name) the path to the file of working area configuration (list of the projects included, etc.). After creating or opening of existing working area you can add the existing project (by specifying only the name of the project configuration file) or create new project. In the last case you shoul specify both name of the project and the name of the file containing the project configuration. You should also note, that all files of the project will be in the same directory as the project configuration file. Having created the project you can create new files within it, work with existing files, already included in the project, or add already existing files from other folders or projects to your project.

File types

Various file types can be included to your project, including not required for the ALLTED solver but connected to the project documents: specifications, documentation, presentations etc. The categories of documents you can work with without leaving ALLTED Studio are as follows:

  • ALLTED Studio documents: ALLTED Task, ALLTED Scheme, Spice Scheme, ALLTED Plot, ALLTED Histogram
  • ActiveX documents: Microsoft Word 97, Excel 97, Power Point 97, etc.
  • Other documents: Corel Draw, etc.

Work with ALLTED Studio documents is described in this manual. To work with the editors of other document types see documentation for these editors.

Within your working area you can create and edit ActiveX documents, which are connected to installed ActiveX components, such as Microsoft Word, Excel, etc. You can create, look through, and edit ActiveX documents without leaving ALLTED Studio environment.

If you want to work with ActiveX documents in ALLTED Studio environment, the proper extensions of their files names should be attached to the appropriate components. For example, if you work in ALLTED Studio environment and open file with expansion *.doc, this file will be opened by the ActiveX component which connected to extension .doc, say, with the help of Microsoft Word.

When working with an ActiveX document in ALLTED Studio environment, toolbars and some of ALLTED Studio menus will not be accessible, but the toolbars and menus of the appropriate ActiveX editor will be visible, for example , Microsoft Word toolbars and menus. The ALLTED Studio toolbars and menus are accessible when such document is deactivated, for example, by switching to ALLTED Studio document or by closing ActiveX document

You can add to the project files, created by other software applications. If the file of your project is not bound with ALLTED Studio or ActiveX components, you can also open this file from working area of the ALLTED Studio project and run application connected to this type of file, but in a separate window. This file name extension should correspond to the application ensuring its editing in Windows Explorer environment. To open such document, choose this file in Workspace window and double-clickclick on it by left mouse button, or press Enter. If the type of this file is bound with any editor it will be opened and file will be accessible for editing.

User Interface

User interface is the part of integrating environment, providing cooperation, carrying-out and control of certain processes.

Review of user interface

ALLTED Studio user interface consists of integrated set of windows, tools, menus, toolbars and other elements allowing to create, check and analyze your projects.

ALLTED Studio users interface uses standard Windows interface with additional capabilities facilitating its usage. Basic elements used most frequently are windows, toolbars, menus and hot keys.

You can modify user interface by moving and managing its windows (Workspace, Output) and toolbars.

Windows and representation of the documents

Working with ALLTED Studio you can change window positioning and way of its displaying as you wish. These adjustments will be kept for each Windows user. There are two types of windows: windows for the documents and docking windows. Size and position of the document window will be changing along with the Main window of ALLTED Studio environment (Fig.1.1). They can be opened or turned in a icon.

Docking windows can be docked to the border of the Main window of the environment (docked), or in to any location within the screen (undocked). For example, to open window of the document you should create new document such as ALLTED Text Scheme. Workspace and Output windows are the examples of docking windows.

You can place docking windows and toolbars as it is convenient for you (or close them). All your preferences (adjustments) will be saved after exiting ALLTED Studio and restored at the following start. All ALLTED Studio document windows are document windows, their state, position and size are not saved when exiting the system. They will be closed when restarting ALLTED Studio.


Chapter 1

ALLTED Studio opens necessary windows as required. For instance, the Output window will be automatically opened when performing an ALLTED task. Docking windows can be in two states: floating and docked to the border of the Main ALLTED Studio window. In the floating state window has its heading and can be located in any part of the screen. The floating window is always displayed over of all other windows. It can be joined with any of four borders of the basic ALLTED Studio window.

(a)

(b)
Fig.1.1. Main Window of ALLTED Studio with the docking Output window (a) and floating Output window (b)

The majority of dialog windows contain menus whose contents depend upon the current state of window and chosen element of this window. The contextual menus provide quick access to the most common commands for dealing with particular window. For example, such commands as Cut, Copy, Paste in ALLTED Scheme window menu are used for editing the scheme description text, the Open, Delete, Properties commands in Workspace window menu are used for file selection, etc.

The content menu is always accessible through right mouse button click, or by pressing Shift+F10 from the keyboard. The contextual menu is also connected to the docking window. Right mouse button click on the border of this window will make accessible the corresponding menu with commands used to manage viewing of this window.


Chapter 1

Toolbars

When launching ALLTED Studio for the first time toolbars will have the default configuration. Later on you can change their position and state, or hide some of them.

Adjustment of directories

In ALLTED Studio you can install file directories which further will be used when working with ALLTED. Installation program will determine initial settings of the following directories: Engine File Location (the path to the ALLTED solver) and Library Files Location (the path to ALLTED standard libraries, necessary for solver operation)

Hot keys

Hot keys are the keyboard keys and their combinations used to perform various commands without switching between the mouse and keyboard that speed up certain actions. The function keys (F1-F10), their combinations, and Ctrl+Alt+Shift combination with functional and alphanumeric keys of the keyboard are considered to be hot keys.

Work with windows and representation of the documents

Basic operations

  • Displaying context-sensitive menu.Click the mouse right button on the window or its element you need. Press the Tab key to move the mark to the window or its element and press Shift+F10.
  • Moving window.Press the left button of the mouse on the heading of a window, move the window on the necessary position and release the left button.
  • Changing the size of window.Click on the border of the window and move it so as to receive the desirable size of the window.
  • Displaying and hiding toolbars.In the Main menu choose View, Toolbar and choose in the list the name of the toolbar you want to display or hide.
  • Displaying and hiding both docking windows and status bar.In the Main menu choose View and choose in the window the name of the window you want to display or hide.

Note: the panel of states displays a lot of useful information about chosen command and its operation. The panel of condition also displays the line and position of the cursor in the text editor.

Work with windows of the documents

  • Allocation of windows of the documents. Choose and use Tile Horizontally or Tile Vertically option from the menu Window
  • Allocation of windows of the documents with overlapping.Choose and use the Cascade option from the Window menu.
  • Dividing the window of the active document.Choose the Split option in the Window menu and move the separator of the window to the position, convenient for viewing the document, and click the mouse for installation of the window separator.
  • Displaying and hiding toolbars.Choose the Toolbar option in the View menu and select the name of necessary toolbar from the list box.

Work with docking and floating windows

  • Displaying or hiding the docking window.Choose the name of a window in the View menu.
  • Hiding the docking window. Press the Hide button in the corner of the window. This button should be in left or right upper corner of the window, depending on the location of the window.
  • Docking or undocking docking window to the border of the Main window.Choose the Expand button in the corner of the window. This button should be in the left upper (under the Hide button) or in the right upper (more to the left from the Hide button) corner of the window, depending on the location of the window. To undock the window, click twice the mouse on the border of the window you want to separate.
  • Undocking the window.Click twice the mouse on the border of the window you want to separate.
  • Docking the floating window to the border of the Main window.Click twice the mouse on its heading or take the window for its heading and pull it to the border of the Main window.
  • Changing the position of the window without docking it with the Main window. Keep the CTRL key pressed while moving the window.

Toolbars

  • To display or hide the toolbars, choose the item in the View menu and choose the name of the toolbar you want to display or hide in the list box.
  • To move the toolbar, place the mark between the toolbar buttons or on the heading of the toolbar, if the panel is in the floating state. Press the mouse button and pull the toolbar to the position, convenient for you. Docking and undocking toolbar to/from the border of the Main window will occur automatically during moving the panel to/from the border of the window. You should press and to keep the CTRL key during this moving for keeping the toolbar in undocked state. After placing the window in the necessary position you should release the CTRL key.
  • To change the size of floating (undocked) toolbar you should move one of its borders.

Note: you can not change the size of docked toolbar.

Docked and floating windows

  1. Standard toolbar (Standard) is docked to the top border of the Main window
  2. The ALLTED and Plot toolbars are docked to the top border of the Main window but located under the standard toolbar.
  3. Workspace window is docked to the left border of the Main window.
  4. Output window is docked to the bottom border of the Main window.

You can change state of docking windows and toolbars as you wish: change the position, hide some of them, or undock them. You can also change the state of the Main window of the system: change its position, size, etc. All these adjustments will be saved after exiting ALLTED Studio and restored at restart.

Note: All docking windows and toolbars set to the floating mode, will be located over all other windows.


Chapter 1

Working area of the project

In ALLTED Studio you can create your project files and their configurations in the working area of the project (Workspace) where you can use both adjustments for particular projects and general adjustments for many projects (for example, the list of common libraries or task files for all projects).

You can also use Workspace window to view the structure of the project, and to access to various elements of the project such as files of tasks, circuit descriptions, documentation.

The working area of the project consists of the projects containing files. The set of files defines the project, and the set of one or several projects defines the working area of the project.

When creating working area you should define the catalogue and the disk where the working area description file is to be stored. You should also define catalogue for each of the projects included to the working area.

The catalogue containing the project description file and project working area description file is the basic catalogue of project working area. Each of the projects included to working area is located in the separate directory .

Directories of the projects added to the working area by you should have the relative path from the basic directory of working area (i.e., they should be placed on the same logic disk). It is not recommended to locate the project directories and project working area on different logic disks.

To store the project working area, it is recommended to use the following catalogue structure:

The catalogue, files … description | Description the basic catalogue of working area
\ My Workspace | Basic catalogue of the working area
\My Workspace\mw.atw file of the description of working area | Description file of the working area
\ My Workspace\First Project\ | Basic catalogue for the First project files
\My Workspace\First Project\fp.atp files of the description (adjustments) of the ' First Project ' project | Description files of the First project
\My Workspace\First Project\* | All other files of the First project
\My Workspace\My Project\ the basic catalogue for files of ' My Project ' the project | Basic catalogue for the My Project files
\My Workspace\My Project\mp.atp | Description files of My Project
\My Workspace\My Project\* | All other files of My Project

You can also store some descriptions of the projects in one catalogue. Working area will consider them as different projects.

The management of working area is carried out through the basic File menu, and management its adjustments are managed through the Project menu.

  • To create new project, choose New Workspace option in the basic File menu of the Main window. In dialog window specify the name of working area, the name and catalogue of the file containing adjustments of working area.

Note: it is impossible to create working area within another working area. To create new working area, close the current working area beforehand.

  • To close working area choose Close Workspace item in the File menu. To save working area, choose Save Workspace item in the File menu.
  • To open working area choose Open Workspace item in the File menu. Then specify the name of the file containing adjustments of the working area in the dialog window. The list of last used working areas Recent Workspaces is in the File menu. You can open any working area of this list by choosing it from the list.
  • To define properties (adjustments) of project working area, in the Workspace window choose the Properties item of the Project menu for already chosen working area.

Basic Project menu allows you to:

  • create new projects in working area – Add New Project to Workspace;
  • add projects created earlier to working area – Insert Project into Workspace;
  • delete projects from working area – Remove Project;
  • change adjustments of the project – Properties;
  • update files of project working area– Refresh.

Some of these operations can be executed through the context-sensitive menu of Workspace window.

To update delete or change adjustments of the project in working area you should choose project in Workspace window and choose the menu item, corresponding to this action by using the context-sensitive menu or basic Project menu.

Let consider the situation when you have copied through Windows Explorer some files for the particular project to the catalogue where is ALLTED Studio project is opened. When the project is opened , you will not see any changes in the lists of files of the project. For synchronization of this list of files with contents of the catalogue it is necessary to choose the necessary project and choose command Refresh in the context-sensitive menu or in the basic menu Project. After its execution the list of files in the working area, the project, the folder will be synchronized with the contents of the catalogue where is the project (projects) is stored. Now you can edit or remove these files.

Projects

Every ALLTED Studio project is presented by the list of files situated in one catalogue - directory of the project - and by the file of a configuration and adjustments of the project, which have to be in the directory of the project where all files of the project are stored (you can store several files of adjustments and configuration of the project in the same directory of the project).

The list of files in the Workspace window is grouped according to the assignment of files:

  1. Task Files - all files of ALLTED task (*.atd)
  2. Scheme Files - circuit description files in two forms: ALLTED (*.ats) and Spice (*.sps)
  3. Result Files - the Diagrams (*.atr) and Histograms (*.ath) calculation result files
  4. Output Files – text result files, report files (*.ato)
  5. Other Files - files of other types.

To open existing document of any type in working environment of the application, choose this file in Workspace window and double-click the left mouse button on it, or press Enter. If the type of this file is different from types of files accepted in ALLTED Studio, but it is bound with some editor in Windows Explorer environment, this editor will be opened and the file will be accessible for editing.

To add a new file in the project:

  • Choose corresponding folder in the project, and choose the Add Files option in the context-sensitive File menu. After specifying the name of the file to be added it will be copied to the directory of the project.

To create a new file in the project:

  • In the File menu choose New command and in the dialog window choose the file type. Save this file on the disk by choosing the Save option from the File menu. In dialog window specify the path to the file and its name. If the file was added to one of the opened projects directories, the lists of files in Workspace will be automatically synchronized.
  • Choose the appropriate folder in Workspace window, and save created file on a disk by choosing the New File option in the context-sensitive menu.

To remove a file from the project:

  • Choose this file in Workspace window and the Delete option in the context-sensitive menu File.

Adjustments

In project working area you can control both adjustments of project - at the Project level - and general adjustments for them at the Workspace level. Currently, there are following global ALLTED Studio adjustments:

Level | Description
global, ALLTED Studio | List of used libraries
Working area, Workspace | List of used libraries from all libraries included in the projects working area, opportunity of a cancellation of the list accepted on the previous level
project, Project | List of used libraries from all libraries included in the projects working area, opportunity of a cancellation of the list accepted on the previous level
Files of the project, Project Files | List of used libraries from all libraries included in the projects working area, opportunity of a cancellation of the list accepted on the previous level

Text editor

ALLTED Studio integrating environment comprises the built - in text editor with illumination of syntax for viewing, editing and printing of files written in ALLTED Input language.

Basic possibilities

One of the basic advantages of this editor is the illumination of speeding up navigation in the document text and facilitating viewing and editing of files written in entrance ALLTED language.

Such documents (files) are:

  • ALLTED task files prepared manually
  • ALLTED circuit description files (ALLTED Scheme)
  • Spice circuit description files ( Spice Scheme).

To form these documents, see Chapter 2.


Chapter 1

ALLTED Model Library

The Library Editor is intended for editing models libraries used by the ALLTED solver during calculation.The model libraries consist of models described in ALLTED Input language and include the functional description of components and their parameters (Fig.1.2).

The window of the Library Editor is divided into two parts. In the left part of a window there is the list of all models described in library, in the right part – the textual description of the model, chosen in the left list, in ALLTED Input language (fig.1.3).

To add a new model you should click the left mouse button on the left list in the library editor window and choose the Add Model item in the basic Library menu.

  • To rename model you should choose its name from the list , choose the Rename Model item in the basic Library menu (or double click mouse on the name of model) and enter new name of model. To change the type of model you should enter the model type after the name of model.

Example: To rename "Model1.mop" model to "MyModel.kkt" you should specify new name - "MyModel.kkt". To change the model name (without changing of its type), you should specify new name (not specifying the type). I.e., to rename "Model1.mop" to "MyModel.mop" , specify a new name - "MyModel".

  • To remove a model, choose it from the list and use the Delete Model item in the basic Library menu.
  • To edit the model description, choose model from list and enter or change the description of model in the editor window (the right part of the window).

Fig.1.2. Dialog window of Library Editor

Fig.1.3. Selection and presentation of the model parameters


Chapter 1

ALLTED Studio documents

All ALLTED Studio documents can be divided into two groups. These are documents which are the part of input data for the ALLTED solver (task definitions, circuit and library descriptions), output solver documents (protocol of operations, drawings, histograms) and other documents (documentation files, reports, etc):

Type | Group in Workspace | Extension | Document Type | Definition
Input | Task Files | atd | ALLTED Task | Task definition
 | Scheme Files | ats | ALLTED Scheme | Circuit description on the ALLTED input language
 |  | sps | Spice Scheme | Circuit description on the SPICE input language
 | Library Files | alb | ALLTED Library | Circuit models library
Output | Result Files | atr | ALLTED Plot | Result graphics.
 |  | ath | ALLTED Histogram | Task execution results – histograms.
 | Output Files | ato | ALLTED Protocol | Task execution protocol
Other | Other Files | * | Other | Files which not supported by ALLTED Studio (documentation, reports, etc).


Chapter 1

ALLTED Task definition

The document in hand contains the task definition for the ALLTED solver. The task definition can be done in several ways, which are supported by the ALLTED Task documents:

  • Through dialog windows (the task definition in the ALLTED input language will be automatically composed)
  • In the ALLTED input language
  • Through dialog windows with the subsequent editing of the obtained task in the ALLTED input language.

The document ALLTED Task window can has two modes:

  1. The mode of automatic task formatting text - choosing options in dialog window menus (in further “automode”), Fig.1.4.
  2. The mode of the task definition in the ALLTED input language (in further “hand-held mode”), Fig.1.5.

To switch between hand-held and auto-modes of the task definition you should select the Manual option in the Task menu of the Main window. The state of the Manual option determines the current mode.

In the hand-held mode of the task definition the one-sided synchronization with an automode (from automatic to hand-held) can be carried out. For this purpose, it is necessary to set proper parameters in the dialog boxes, then switch to the hand-held mode and select the Refresh command in the menu Task of the Main Window. Then the text of the task of the hand-held mode will be replaced by the text corresponding to the settings of the automode. The further changes of the automode options will result in automatic change of the task definition text in the ALLTED input language (for the hand-held mode). This will happen until all the errors are eliminated from the text of the task. To repeat the synchronization of the hand-held mode with the automode of the task definition, select the Refresh command in the Task menu again.

  • Fig.1.4. The task definition in the “automode”

    •

  • Fig.1.5. The task definition in the “hand-held mode”

    •


Chapter 1

The state of the Refresh button on the toolbar of the Task window (or state of the Refresh option in the Task menu of the Main Window) identifies synchronization of the automode with the hand-held mode. If this button is dimmed, the modes are clocked: the task text in the ALLTED input language in the hand-held mode corresponds to selected options in the automode. The Refresh command will be automatically unlocked during any modification of the task text in the hand-held mode.

When saving the document both the automode options and the task text of the hand-held mode will be saved.

For task execution by the ALLTED solver ,beside the task text, it is necessary to point out the scheme description file and the list of additional libraries used (if this list differs from the one already accepted at the top-level - Project, Workspace, ALLTED Studio). All this information is shown in options of the General bookmark and in the task properties. The task properties are accessible through an Properties option of the Task menu mentioned above.

In the Analisys option of the Task menu and in the toolbar of the Task window, there are options, whose states show types of the analysis selected in the automode:

Ab briviation | Option
DC | DC
AC | AC
TR | TR
MV | MVA
FR | FOUR
SA | SA
WC | WCD
OP | OPTIM
TS | TOLAS
ST | STA

In the hand-held mode the ALLTED Studio editor is used as a text editor. In the automode of task definition the task file is accessible for you, it can be selected and copied to the clipboard for further inserting to the reports and the documentation written in other text editors (for example, in the editor Microsoft Word or Word Perfect).

Scheme description file

The ALLTED solver needs the circuit description. ALLTED Studio supports two types of the circuit definition files:

  • Text (in the format of the ALLTED or SPICE input languages)
  • Schematic capture ( in ALLTED format )

For each mentioned type there is a particular editor.

ALLTED Text Scheme Description

This is the text description of the circuit in the ALLTED input language with help the ALLTED Studio text editor described in 1.4. The ALLTED input language is presented in the Chapter2.

ALLTED Graphic Scheme Description

The Graphic Editor is used to draw the schematic diagram, to assign the values of two-terminal components, to select the type and parameter lists for multi-terminal components and, if necessary, to modify them without leaving the editor, to specify the element's connections and to form the task. The output of the graphic editor is an input file with circuit description and the design task in ALLTED input language as well as schematic representation of the object. This file can printed or plotted to the hard copy. In the given version of the ALLTED Studio this mode is not supported although there is the external Graphic Editor from MyCAD System related to the ALLTED Studio environment.

Spice Text Scheme Description

This is the text description of the circuit in the Spice input language which is converted to ALLTED Text Scheme description by the special SPICE in ALLTED language statement compiler.

Diagram Plot

The developed Diagram Viewer is intended for review of calculation results of the ALLTED solver in the graphical form as diagrams and drawings (fig.1.6).

Fig.1.6. General view of the constructed drawings

As the Fig. 1.6 shows, the viewer of the drawings consists of two areas:

  • The constructed drawing
  • Legend

To choose the following or the previous drawing select the Next option from the Draft menu of the Main Window (to go to the following drawing) or the Previous option (to go to the previous drawing).


Chapter 1

Moving the draft

Select the Move option from the Draft menu:

  • Move the mouse cursor to the point on the drawing, which would be graphics center, and click the right mouse button
  • Push the left mouse button and move the diagram as you want, then release the button.

Scaling the draft

Select the Zoom option in the Draft menu of the Main window:

  • To decrease the drawing in 1.5 times, move the mouse cursor to that point on the draft, which would be the center of the drawing and push the right mouse button. As a result, the selected point moves to the draft center and the whole drawing will be decreased in 1.5 times.
  • To increase the drawing in 1.5 times, move the mouse cursor to that point on the draft, which would be the center of the drawing and push the left mouse button. As a result the selected point moves to the draft center and the whole drawing will be increased in 1.5 times.
  • To increase the selected draft area move the mouse cursor to the upper left corner of necessary area and push the left mouse button. Then not releasing this button move the cursor to the right lower corner of necessary area (resulting the selection of the rectangular area on the drawing) and release the mouse button. The selected area will be increased to the whole document sizes.
  • To restore the scale of the draft (when all curves are visible), select the Zoom to Page option in the Draft menu.

Formatting a grid

The drawings can be presented in two modes, when their values on the axis OY are shown:

  • In one scale
  • In different scales with curves normalization made on their maximum values.

When drawing ordinates are shown in different scales, the particular numerical values of the selected curve are given in the field of the legend (the selected curve is marked by rectangle). To choose a curve you should move the mouse cursor to the curve name and click the left button, or choose Next, Previous options in the Draft menu of the Main Window.

The formatting of the grid can be made in two modes:

  • Hand-held - the user sets formatting
  • Automatic - formatting is made automatically

Select the Autogrid option in the Draft menu for switching between these modes. In the hand-held mode the user should point the initial value, the grid step and grid value accuracy. These adjustments are made using the Properties option in the Draft menu and the dialog box. Using this box and its panel you can adjust:

  1. Axis - limits of visibility of the drawing, the scale of the axis OY.
  2. Grid – the visibility of the grid and its elements, grid parameters in case of hand-held formatting.
  3. Legend – colour, width, style and visibility of selected curves.

Histogtam Draft

The Visualisator of histograms (spectrograms) is destined for representing the ALLTED solver results shown as output files of the histograms (spectrograms), fig.1.7.

Fig.1.7. Visualisator of the histograms (spectrograms)

Through the Draft menu the following options are accessible:

  • Next, Previous - for switching between the drafts
  • Next Item, Previous Item - for the cursor placing on the histogram (spectrograms) intervals.

To choose the histogram points, you can also use the mouse to move the cursor to the selected curve point (in scale X limits) and click the left mouse button. As a result, the corresponding information appears in the lower part the draft. This information consists of:

Type of draft | Value information
Histogram | interval number, frequency, lower limit, upper limit
Spectrogram | harmonic number, frequency, magnitude, phase


Chapter 1

Text Output

This document is formed by the usual text editor with the minimum function menu and is intended for representing the calculation result in text form (Fig.1.8).

Fig.1.8. Text Output file


Chapter 1

ALLTED advanced features

It is important to realize that the automatic analysis capability of ALLTED is not reduced to just computing such primary response quantities as voltage, current, and power. It also provides design control options. With the design control options the user can command the calculation of a wide variety of defined secondary response quantities such as rise time, peak value and bandwidth, along with the t-value or w-value where such points occur, as well as arbitrary mathematical functions of such quantities. Also the Monte Carlo and sensitivity analyses are not restricted to primary responses but can equally well reference any user defined secondary response.

Another set of features which puts ALLTED in a class is very general and powerful circuit optimization capabilities. The aim of this operation (which is the most important and labor-consuming) is an automated parameter value search to satisfy specifications completely. ALLTED consists of effective methods allowing easy obtaining of object requirements in the form of objective functions and constraints. The User can determine any output parameters to evaluate object quality. With ALLTED one can get transient, frequency and spectral output parameters simultaneously. It is also possible to use constrained and/or unconstrained problems evaluating extremes with mono or multi-criteron formulation.

And finally, ALLTED provides optimal tolerance assignment for steady-state, frequency and transient analysis. The aim of this operation is the computation of extreme deviation (tolerances) of object parameters with respect to the given feasible deviation of output characteristics. The operation makes it possible to take into account the production technology effect and exploitation conditions at the early design stage.

Table 1.1. contains the list of feature comparison for ALLTED and PSPICE

Table 1.1.

Comparison of ALLTED with PSPICE

N | ALLTED | PSPICE
1. | Schematic capture | Based on Windows 3.0/3.1
2. | Basic Analysis (DC, TR, AC, Four) | PSPICE
3. | Output graphics, postprocessor | PROBE (a separate add on program)
4. | Device parameters indentification Subsystem | PARTS (a separate add on program)
5. | User-defined Models and Functions (247 functions!) | Device equations (only for Analog Behavioral Modeling)
6. | Mixed-mode simulation | Digital files
7. | Advanced Analysis (statistical design, SA, WC) | Monte Carlo (MC) (SA,WC for DC only)
8. | Libraries | Libraries
9. | Secondary parameter evaluation (trise, tfall, delays, frequency band, etc) | Indirect with help of PROBE
10. | Multicriterion Optimization for DC, AC and TR | Not Available
11. | Optimal tolerance assignment | Not Available
12. | Mixed-Technologies Simulation (Hydraulic, Mechanical, Pneumatic and Control System Simulation) | Not Available

Describing an Object for ALLTED

The chief cornerstone of any CAE design system is the way it represents the structure and physics of an object. The way this can be done lies within two limits:1. The object is considered as a combination of elements. For each kind of element one or more models are developed and stored in the system library. The object representation is then built of these models using the graphical capture facility or a text editor. The elements may vary as widely as operational amplifiers, digital-to-analog transducers, electrohydraulic valves, actuators, transistors, hydraulic cylinders, etc., and are taken from the library wherein one or several model variations are provided for each element type.

. The object is described mathematically and its model is constructed in standard form compatible with software systems designed to solve mathematical equations regardless of the kind of system they represent.

This second way allows the user to control the entire extent and complexity of models. However, this is an extremely time-consuming approach.

Most of modern CAE design systems use the first way. However, this method has its own disadvantages:

- Very often a model is to be chosen from the library without fully knowing what factors are being taken into account. The model is described "somewhere in the manual", but do engineers looks into the manual when the result must be obtained urgently?

- Each type of element could be represented by at least 15 to 25 models, differing in extent and complexity. Those models, in turn, may have an infinite number of parameter value combinations. For example, for each design of a hydraulic cylinder the library could contain models for various versions of frictional forces in sealing, liquid compressibility, etc. An attempt to make up one common ("universal") model of an element to cover all practical applications is unrealistic. For many applications, using the "all parameters" model would result in an excessively great number of computing operations, causing an ever-growing risk of computation failure. The libraries become very difficult to search. And, in all likelihood no library would contain the model of an element needed to meet exactly the particular requirement.

- Of course, new models can be added to the library or existing ones can be updated. This process, however, is often very complex because the element should be described mathematically first, then its model must be arranged in some standard form, programmed using algorithmic language, inserted in the software structure, and checked in a real environment, and so forth.

Practical experience has proven that the ideal object representation should allow the user to manipulate the library models as in the first approach, and provide easy model checking, updating, or replacing it with new one as in the second approach. And these innovations must be performed without writing differential or algebraic equations, or without writing subprograms in algorithmic languages, etc.

In ALLTED this problem is solved by representing an object under design by an equivalent circuit. This method is widely used in electrical engineering and has become so popular with engineers, that it is applied spontaneously, with very few difficulties. There is a wealth of textbooks about equivalent circuits for mixed-technology systems (see, for example, H.E.Koenig, Y.Tocad, H.K.Kesavan, H.G.Hedges Analysis of Discrete Physical Systems, New York, McGraw-Hill, 1967; D'Azzo J.J., Houpis C.H., Feedback Control System Analysis and Synthesis, 2nd Edition, McGraw Hill, 1966. and others). However, up until this time this approach has not been widely used, mainly because it was restricted to linear systems. With ALLTED this restriction is removed.


Chapter 1

Circuit Representation of Complex Systems

Any physical system that can be described in lumped parameters can be presented as an equivalent circuit, i.e. in the form of components combined with one another through their terminals/interconnections. The component properties can be described regardless of the way they are inserted to the system, and relative to the variables measured on the terminals. The components are divided into groups according to the number of terminals (two- and multi-terminals) and to the type of mathematical equations between the variables. If the variables are chosen according to particular rules, common for all the system, the total number of different components within the various systems can be minimized. In ALLTED only 6 generic components can represent any system despite its complexity.

The rules of choosing the variables are as follows: Depending on the measuring method, divide all the variables used for analyzing the systems into flow and across ones. The flow variables are measured by means of an instrument connected in series (current, electrical charge, flow rate, force, moment, etc) and the across one, parallel with the component or between the component's terminal and an external point (voltage, potential, pressure, speed, motion, angular velocity, etc.).

Then, derived for each type are basic, integral and differential variables. The integral and differential variables are obtained from the basic one by integrating or differentiating respectively. For example, if the basic variable is speed, position is an integral variable, and acceleration is a differential one. The integral variable of current is a charge, etc. Table 1.2 presents the variables chosen both as basic flow and across for the systems designed by means of ALLTED.

Table 1.2.

Basic Variables of Physical Systems

System | Basic variables
 | flow | across
Mechanical translational | force | speed
Mechanical rotational | torque | angular velocity
Hydraulic | flow rate | pressure
Pneumatic | mass flow rate | pressure
Heat | heat flow | temperature
Electrical | current | voltage


Chapter 1

A very important consideration in the CAE system is the choice of tags or designators for the variables. The desire of keeping each technology's commonly used designations is not practical because of the great number of coinciding designations (e.g., torque and temperature are both denoted by the letter T, velocity and voltage both by the letter V, etc.). Such a labeling requirement uses practically the entire alphabet for denoting only the variables (with due regard to integral and differential ones). Therefore, the basic flow variable (further on referred to simply as flow variable) is denoted by the letter i and the across variable by the letter u for all the systems.

All physical systems can be described and analyzed in these generalized variables. To simplify description, across and flow variables will be replaced with conventional names when no ambiguity arises.

Table 1.3.

Two-terminal components of circuits

Table 1.3 presents the equations, names and diagrammatic representation of the components derived in the mixed-technology systems relative to the variables given in Table 1.2. The validity of Table 1.3 can be readily proved by substituting i and u for the symbols usually accepted for denoting the variables in a particular type of the system and replacing the component type letter G, R, C or L by the technology's commonly used symbol. For example, a C component of a mechanical rotational system is an inertia moment with the equation:

where T is a torque, J is a moment of body inertia, w is an angular velocity, t is a time. Similarly, an L component of a hydraulic system represents inertia head loss

where p is a pressure differential; q is a flow rate; l is a pipeline length; A is an area of a pipeline cross-section.

Compared with commonly used form, the elasticity equation of mechanical circuits

seems somewhat unusualvelocity of , where Lm is a mechanical compliance (quantity opposite to stiffness), F is a force acting upon the component, v is a relative the ends. That is because here the basic across variable chosen is speed, not position.

J source and E source simulate ideal power sources in which either the output flow variable is independent of across one (J source) or the output across variable does not depend on the flow variable (E source).

For electrical systems, the designation of components and variables remain in their most commonly used form, thus paying a tribute to the electrical engineers who were the first to represent the system under design as an equivalent circuit. It should be noted here that the components of Table 1.3 are the consequence of common general principles in conversion of different forms of energy. They are not the result of primitive electrohydraulic, hydro-mechanical or any other analogy description, nor are they an attempt to reduce the investigation of mechanical or hydraulic systems to the analysis of electrical ones.

Table 1.3 represents linear components only. In real systems the linear approximation is very rare and much more complicated components described by nonlinear equations must be handled. ALLTED does it by linearizing nonlinear equations, but to preserve accuracy and efficiency, the linearization is performed at a component level in accordance with the algorithm applied to solve the equations. In other words, the numerical method is applied before the component equations are mixed in the entire system model to obtain the linear equation ready to be used at a particular step of computation. In transferring to a successive step, the components are transferred in compliance with accepted procedures of linearization.

In this way nonlinear systems can be made up from components similar to those presented in Table 1.3 after providing the CAE system with data indicating that the component is nonlinear and its equation complies with one of the types determined in advance.

The equivalent circuit is built using the following rules:

1. Each component represents a particular physical process: mechanical inertia in translational motion, mechanical friction, hydraulic compressibility, electrical resistance, etc. Thus, the components that are entered in the circuit reflect the processes that are to be taken into account.

2. The mathematical model of the circuit is formed using the component equations (refer to Table 1.3) and constraint equations derived from two basic circuit laws: node law and loop law. The node law simply states that the algebraic sum of flow variables of the components combined into a node equals zero. In electrical circuits the node law is known as Kirchhoff's current law; in hydraulic circuits, as a flow continuity condition; and in mechanical systems, as an equilibrium condition. The loop law sets up a relationship among across variables; the algebraic sum of across variables taken on any closed loop is equal to zero. The loop law in electrical circuits complies with Kirchhoff's voltage law; in hydraulic circuits, with the condition that the sum of pressure-drops of the system elements taken on a closed loop must be zero.

Fig.1.9.Two-terminal component.

3. Each two-terminal component of the circuit represents two variables: flow and across ones taken as shown in Fig.1.9. The component is given a unique name in which the first character (G,R,C,L,J,E) establishes its type in compliance with Table 1.3. Other characters of the name are chosen arbitrarily, e.g., the components names could be G15, EINPUT, ROUT, C12S3, etc. The names of the component's variables are formed from key prefix I (flow variable) or U (across variable) attached to the component name. For example, IG15, UG15, UEINPUT, UC12S3, etc.

For clarity, the names of components in text documents can be recorded as subscripts: G15, EINPUT, G12S3, ROUT, and the names of variables for these components as: UG15, IEINPUT, IG12S3, UROUT, etc. Thus, if I or U are to be used in text descriptions models, other symbols need to be designated to denote these particular variables.

We shall refer to such models of physical devices, presented as combinations of these components, as equivalent circuits.


Chapter 1

Electrical and Electronic Systems as Circuits

Electrical and electronic systems are commonly presented as circuits in computer-aided engineering. The terminology, symbol convention and basic layout procedures are well established and have been in use for some time (refer to, e.g., Fidler J.K., Nightingale C., Computer Aided Circuit Design, John Wiley & Sons, NY, 1978; Babanian N., Bickart T.A., Linear Network Theory, Matrix Publishers, Inc., Beaverton, Oregon, 1981).

Fig 1.10. Electrical network (a) and its equivalent circuit (b).

Accepted as basic variables are voltage and current, and as components - conductance, resistance, capacity, inductance, current and voltage sources.

Fig.1.10 shows a simple electrical network schematic diagram (a) and its presentation as an equivalent circuit (b). The original circuit provides an accurate component count and is adequate for building and trouble-shooting the network. In practice, the signal source may actually be external to the circuit board, being only a set of connecting points on the device itself. However, to properly evaluate the circuit some additional component parameters need to be considered. After building the circuit, it is recognized that resistor R1 needs to be represented by the resistance RS and parasitic capacitance CR1; inductance coil L1 is to be replaced by inductance L1S and resistance RL1, etc. As a result, the equivalent circuit reflects, unlike the schematic diagram, all factors that need to be considered and is, in fact, a graphical representation of its mathematical model.

It should be noted that the network and its equivalent circuit are essentially different in topology; even less external resemblance exists between the circuit and solid-state electronic device. For electronic engineers this has become so customary that no one thinks of an alternative.

Fig.1.10,b shows the simplest presentation using only two-terminal components. Further on we will use dependent sources and multi-terminal components to take into account mutual inductances, temperature, radiation and other effects.

Block Representation of Systems. Models of Complex Systems

Any system that can be analyzed in lumped parameters can be represented as a circuit of two-terminal components. However, the description of a complex system that is represented as a continuous sequence of such components would be lengthy and insufficiently vivid. Therefore ALLTED input language allows to treat an object as an hierarchal structure consisting of a great variety of subsubordinate blocks. Blocks are formed with two-terminal components and other blocks.

The object is treated as a main model consisting of a number of nested models. Any of the nested models can, in turn, contain models of the second level of nesting, etc.

The configuration of the nested model is selected in such a way that it complies with one of the physical elements of the system (with a transistor, diode, valve, motor, etc.) or with the functional unit (amplifier, chip, electrohydraulic amplifier, pneumatic drive, etc.). As a result, the set of models in the library is in compliance with the set of actual elements and the model of an object is made naturally, using customary units.

ALLTED has a special library where any model once developed can be stored or retrieved. This library has already been filled with a vast variety of models. The models were developed in the most "applicable" form and cover the entire range of technologies and systems under design. The library of models is intended to significantly simplify formulating the description, especially in the initial period of operation. The library of models is open and can be easily extended.

ALLTED input language admits two types of nested models: symbolic and conventional. The conventional model is included in the main circuit by the operator type

VAL ( G, EX, 7, 0 ) = RELVALVE;

where VAL is the name of the element in the main model. The first character (prefix) of the name must be different from G, R, C, L, J, E. It indicates that inserted (nested) between nodes G, EX, 7, 0 is the element which is described by the model with name RELVALVE. The description of the conventional model contains numerical values of all the parameters.

The symbolic model differs from the conventional one in applying symbolic names to all or some of the parameters in the description, their numerical value being given in a separate data set referred to as the LIST. In other words, the symbolic model describes all the varieties of elements with the same circuit and the LIST derives one element from this set. The right-hand part of the symbolic model operator makes use of the composite name, the second part of the name sets the model name and together they set the list name. For example, the operator

SHAB ( 1, 3, 0 ) = GA162T.SHOCKABS

indicates that included between circuit nodes 1,3,0 is model SHOCKABS, the numerical values of its parameters are described in list GA162.SHOCKABS.
The symbolic model cannot contain nested models inside, i.e., its nesting level should be as high as possible in the circuit.
The detailed rules for describing the nested models are contained in Section 2. Only the basic knowledge required for constructing the model is given here.


Chapter 2

ALLTED Input Language

The fundamental step in building a model of the object under design is constructing the equivalent circuit as described in Section 1. Once the equivalent circuit is developed, it must then be presented to the computer-aided engineering system in either text or graphic format. Graphics is the easiest and most convenient way to handle large-scale models, and to define/visualize the relationships between object elements. However this is only true if each component is associated with a specific mathematical description (mathematical model) as, for example, in a block diagram of a control system. If this is not the case, the components must be supplied with text descriptions and the graphical image begins to lose many of its advantages. For the scope of objects and types of design operations covered by ALLTED, text presentation is of primary importance. This is also true because much of the information dealt with at this design stage is inherently textual. For, example, text specification of nonlinear processes is straight-forward and convenient and takes much less effort than attempting to represent these mathematical relationships graphically.

In ALLTED the equivalent circuit description can be entered in both graphical and text mode. In graphic mode the circuit schematic is drawn directly. The schematic image is then in a dialog mode transformed into a text description to be further processed by ALLTED. Using text mode, the same description can be developed or read in from an external text file. For the actual analysis ALLTED uses only text description files. Therefore, text presentation is of primary importance. There is an additional benefit: The better one knows the problem-oriented ALLTED input language, the more extensively he can use the graphics entry system.

The ALLTED input language consists of three parts: Object Description Language (ODL), Library Operation Language (LOL) and Task Control Language (TCL).

ODL is used for description of equivalent circuits to cover all the variety of mixed-technology systems and objects and to meet demands of Engineers - electronic, mechanical, hydraulic, control, etc. The ALLTED input language is domain-invariant. This means that any model the user can develop in the form of an equivalent circuit can be represented with the ALLTED Object Description Language.

The Library Operation Language serves the special ALLTED library system where models, model data and functions can be stored and retrieved.

The Task Control Language sets the design operation type, specifies the output variables and characteristics and the form of their representation, adjusts design procedures, and so forth.

General Conventions

The following definitions are used to describe the input language constructions:

<...> indicates that the appropriate name or value should be substituted;
[...] optional elements are placed in brackets;
{...} elements which may be repeated zero or more times.

Character Set

The set of symbols of the ALLTED input language includes:

- 52 upper and lower case alphabetic characters;
- the underscore (_);
- 10 decimal digits;
- the space character;

- 17 special symbols:
, (comma)
; (semicolon)
( (left parenthesis)
) (right parenthesis)
+ (plus)
- (minus)
= (equality)
* (asterisk)
/ (forward slash)
[ (left bracket)
] (right bracket)
< (less than, left angle bracket)
> (greater than, right angle bracket)
% (percent)
& (ampersand)
^ (circumflex, exponential notation)
. (dot, decimal point)

Note:
1. Underscore is treated as a letter and can be used in any place where letters are used.
2. ALLTED Input Language is not case sensitive, it makes no distinction between upper/lower case: "CIRCUIT" and "circuit" are equivalent.

Lexem Constructions

Any text in the ALLTED input language is considered as a sequence of primitive linguistic elements, for which we coin the term "lexems". All the identifiers, names, keywords, numbers, and delimiters are referred to as lexems. Two adjacent numbers, identifiers, names, and/or keywords must be separated by at least one space character. Spaces are not allowed inside lexems but between lexems they are readily used. Anywhere one space can be used, several spaces or blank lines are allowed.

Any special symbol or the space character is considered to be the delimiter.

The end of a line is treated as the space. Thus, each lexem should reside in a line.

Complex syntactical constructions (such as ODL operators, TCL directives) may occupy several lines. And vice versa, according to the space character usage rules, several operators or directives can reside in one line. The maximum line length is 127 characters.

Note: The ALLTED listing is formatted for text clarity.

Identifiers and Keywords

Identifiers and keywords are lexems that are designed to identify an equivalent circuit component, variable, parameter, argument of a function, etc. An identifier is constructed of characters (lower or upper case) and decimals, but it must start with a letter. The identifier's length is arbitrary, but only the first 8 characters are valid.

From syntactical point of view, the keywords of the input language are subset of identifiers. But they are introduced to mark specific functions only and can't be used for other purposes. Keywords usage rules will be discussed later.

Example:

Identifiers: R17, UR1, LAMBDA, POWERSUPPLY1.

In the last identifier only the letters POWERSUP are recognized.

Keywords: MODEL, LIST, TIME, RE.

Names

Along with the identifiers, the input language makes use of "name" type lexems. They are used to identify models, nodes, etc. and constructed of letters and decimals, but in this case, with the digit allowed to be the first character.

Example:

Names: 2N2217 BETA UA741

Note: a set of characters consisting only of digits is a lexem of another type - an integer number - and can't be a name.

Values/Measurement Units

Values are written in standard floating-point notation with an optional scale suffix. Here are some legal values with no suffixes:

5 5. 5.0 -5.0 5E-7 1.0E+9

The ALLTED input language doesn't allow values notation starting with a decimal point. For instance, the following are not allowed:

.5 -.25E-7 +.001

These must be changed to:

0.5 -0.25E-7 +0.001

The scale suffixes follow standard scientific conventions and multiply the number which they follow.
These are the scale suffixes recognized by ALLTED (in upper or lower case):

F = 10-15
K = 10+3
P = 10-12
MEG = 10+6
N = 10-9
G = 10+9
U = 10-6
T = 10+12
M = 10-3

Thus, these values are all equivalent:

3.14 3140.M 0.00314 K

Note: an integer number followed by a scale suffix is treated by the translator as a lexem of "name" type. In these cases it is necessary to separate the number and scale suffix with a decimal point or a space. For example:

10 K 10.K but not 10K


Chapter 2

Comments

A comment begins with the "#" symbol, located any place in a line and is continued to the end of the text line. A comment can be placed in any line following any lexem or can occupy a separate line. The comment text may contain any character. Comments do not affect the input description.

Examples of comments:

# A separate comment

# continued here

R1(1,2) = 10; # Comment at the end of the line

CONST LFREQ=0.0025, # Comment inside the directive

UFREQ=0.005, # Upper frequency boundary

phaseang=-360; # Bode plot phase angle scaling

Input File Structure

The structure of the input file depends on whether the ALLTED Postprocessor is used or not. In the case with the ALLTED Postprocessor the file is organized as follows:

TASK
pproc;# Postprocessor is initiated. This option must be
# set in the task before the description of the circuit is processed
&
OBJECT
<circuit_description>
&
TASK
<task1_description>
&
TASK
<task2_description>
&
.
.
END

When the Postprocessor is not used, the task part before the object description is omitted and the file starts with the description as it is shown below

OBJECT
<circuit_description>
&
TASK
<task1_description>
&
TASK
<task2_description>
&
.
.
END

Interaction with the ALLTED Library is usually organized with the separate input file
.
LIBRARY
<library_directives>
&
END

but it can be specified in the same file with the other kinds of tasks

OBJECT
<circuit_description>
&
TASK
<task1_description>
&
TASK
<task2_description>
&
.
LIBRARY
<library_directives>
&
.
END

The object description, the descriptions of one or more tasks and, if necessary, a specification of ALLTED library operations are considered to be the separate parts of the input file. These are the description part, the task part and the library part respectively. The type of each part of the input file is defined by the header-directive, which is to be written as a separate line at the beginning of the part: OBJECT, TASK, LIBRARY, END. The OBJECT, END, and TASK directives do not have any parameters. The header-directive LIBRARY may be followed by a parameter, specifying the library file name. Any number of blank lines may precede and follow the header-directive.

Each part of the file is terminated by a "&", which may stand in a separate line or at the end of the last line.

Only one description part is allowed in the input file. The analysis type and the way the output results are represented are specified in the task part, which must follow the description part. One description part may be followed by several task parts. The library part may be situated any place relative to the description and task parts.

The task part with only PPROC and OPTION directives may precede the description part.

The END directive is a special type of a header-directive; it marks the end of the input data flow. After it is processed, ALLTED terminates operation.

Circuit Description

Circuit Hierarchical Structure

The circuit is described with the ALLTED input language. In general, the circuit is considered as a hierarchical structure comprising a variety of subsubordinate blocks. Any part of the circuit (operational amplifier, transistor, diode, etc.) can be categorized as a separate subsystem or nested model. This model in turn can be further reticulated into models of the second nesting level and so on (8 levels are allowed). The model covering all others models is called the main model (main circuit).

As a result, the circuit is considered as the main model and could comprise nested models and basic two-terminal components. The models (nested and main) can be stored in or retrieved from the ALLTED library. Even for rather simple circuits it is good practice to form a hierarchical structure because the nested models can be accumulated in the library of models and can at some later time simplify new system description process considerably.

There are two model types according to their description mode: conventional and symbolic. The conventional model description consists of all numerical values for its parameters and elements.

In the symbolic model's description the value of at least one parameter or element is specified with a symbolic name instead of a numerical value. Parameters of other elements could be still specified numerically. As a limit, all parameters of symbolic model can be assigned symbolic names. The special data block named LIST of parameters was designed in the ALLTED input language to supply symbolic models with values of their parameters.

Any model may be used at any level of nesting. For instance, a transistor model, registered as a symbolic or conventional one, may be included in the main circuit and/or in any conventional model. However, symbolic models can not incorporate any nested model.

The circuit description consists of the main model text, nested models descriptions and parameters' lists. Except for having the main model first, the description parts order is arbitrary.

If the description of a nested model is not included in the input file, a search is made in the ALLTED library.

Note: A symbolic model can only contain two-terminal components. A conventional model may contain both two-terminal and multi-terminal components.

CIRCUIT, Title-operator

The circuit description should begin with the title-operator CIRCUIT:

CIRCUIT <circuit_name>;

Example:

CIRCUIT VA741;
Circuit Amplifier;

The circuit name can be any lexem of the "name" type. The title-operator CIRCUIT is followed by the two- and/or multi-terminal component operators of the main circuit.


Chapter 2

Two-terminal Component Description

The name of a two-terminal element is an identifier, the first letter of which uniquely defines the type of the component. In Table 2.1 the symbols used in ALLTED to identify the component type are listed with comparison to SPICE.

Type of Components | ALLTED | SPICE
Capacitance | C | C
Resistance | R | R
Conductance | G | ABSENT
Inductance | L | L
Independent Voltage Source | E | V
Voltage Controlled Voltage Source, VCVS | E | E
Current Controlled Voltage Source, CCVS | E | H
Independent Current Source | J | I
Voltage Controlled Current Source, VCCS | J | G
Current Controlled Current Source, VCCS | J | F

A two-terminal component can be specified with value, function, or table. Below the syntax for this kind of components is shown

<component_name> (<+node>, <-node>) = <value>;
<component_name> (<+node>, <-node>) = <function>;
<component_name> (<+node>, <-node>) = <table>;

Examples:

R1(1,2) = 4.5 k;
Ein(In,0) = FPULSE(0,5,0.1,0.5,0.2,5,10);
J5(4,5) = TAB1(time);

The first operator is the description of a resistor, named R1, inserted between nodes 1 and 2 and having a value of 4.5x10E3. The second operator is voltage source Ein connected to nodes In and 0 and is described by the function FPULSE. The numbers within the (...) in the right part of the operator that follow, are the values for that function, a fixed field format defined by the function, FPULSE. The third is the example of a table defined current source J5, connected to nodes 4 and 5, the table's name is "TAB1" with time as an argument.


Chapter 2

A node name can be any lexem of the "name" type or an integer.

system for current and voltage the Definitions <+node> and <-node> are stated the reference of the component<- node>
(Fig. 2.1). The voltage is . The assigned positive direction for current is from the <+node> to the read out as

U = V <+ node> - V<- node>

Fig.2-1. Basic two-terminal components.

where U - voltage;
V - node potential.

Suppose that we want to find the voltage between nodes a and b, between which there isn't any circuit component to probe. To get the voltage in question, include an ideal zero current source between node name1 and node name2, a and b in this case. The ideal source has zero current and it behaves like an open circuit. The voltage U across this dead current source can then be probed to find the voltage between the two nodes.

Then in the description file we write:

JD(a,b)=0;

Uab=UJD;

One of the nodes of the main circuit must be denoted as the reference node( base node). Any node of the main circuit can be denoted as the reference one, but it is recommended to choose the node with the maximum number of connected elements as a reference. As a rule this is the ground or zero node.

Note: If a node with the name "0" is used in the model description, it is treated as a regular but not a reference node.

Controlled Sources and Components

All four controlled sources are available with linear or nonlinear functions of their controls. The same applies to any type of components (resistors, capacitors, inductors) controlled by voltage and current (Table 2.2).

Table 2.2

Type of dependent source

ALLTED Description

SPICE Description

VCVS
ED=mUR,
ED=ED0+p1UR+p2UR2+...

 ED(c,d)=FL(M/UR);
ED(c,d)=FPOLY(ED0,p1,p2,.../UR); 		ED c d POLY(1)* a b ED0p1p2* may be omitted for the one dimensional case

VCCS
JD=gUR,
JD=ID0++p1UR+p2UR2+...

 JD(c,d)=FL(g/UR);
JD(c,d)=FPOLY(ID0,p1,p2,.../UR); 		GD c d a b g
GD c d POLY(1) a b ID0p1p2

CCVS
ED=rIR,
ED=ED0++p1IR+p2IR2+...

 ED(c,d)=FL(r/IR);
ED(c,d)=FPOLY(ED0,p1,p2,.../IR) 		HD c d VR r
HD c d POLY(1) VR ED0p1p2

CCCS
JD=nIR,
JD=JD0++p1IR+p2IR2+...

 JD(c,d)=FL(n/IR);
JD(c,d)=FPOLY(JD0,p1,p2,.../IR) 		FD c d VR n
FD c d POLY(1) VR JD0p1p2

Temperature controlled resistor
R1=R0.R.(1+TC1.(T-T0)+TC2.(T-T0)2) if TCE=0,

 R1(a,b)=FRES(R0,TC1,TC2, TCE/IR1);
CONST TEMP=27 		R1 a b R0 TC=TC1,TC2,TCE

Nonlinear capacitor
C2=C0C(1+VC1UC2+VC2UC22) °
(1+TC1(T-T0)+TC2(T-T0)2)

C2(a,b)=FCAP(C0,,C,VC1,VC2, TC1,TC2/VC2);
CONST TEMP=27 		C2 a b CAP25
.MODEL CAP25 CAP(C0, C VC1 VC2, TC1 TC2)

Nonlinear inductor
L3=L0L(1+IC1IL3+IC2IL32) °
(1+TC1(T-T0)+TC2(T-T0)2)

L3(a,b)=FIND(L0,,L,IL1,IL2, TC1,
TC2/IL3); 		L3 a b IND28
.MODEL IND28 IND(L0, L IL1 IL2, TC1 TC2)

Mutual inductors

Here: K=0.9

K - coefficient of coupling

 UL1(a,b)=FL(L1,,M/IL1,IL2);
UL2(c,d)=FL(M,L2/IL1,IL2);
L1(a,b)=FMUT(L1,,M/IL1,IL2);
L2(c,d)=FMUT(L2M/IL2,IL1);

where M is coupling O L1L2
with 0 < coupling <=1 		K L1 L2 0.9
L1 a b L1
L2 c d L2


Chapter 2

Polynomial Function:

FPOLY function defines all types of E or J controlled sources. This function is in the form of a polynomial of user defined degree and dimension. The dimension of polynomial is defined by number of controlling arguments.

General form:

<Ename>(<+node>,<-node>)=FPOLY(<P1>, ... ,<Pn>/<U1>, ... ,<Um>,<I1>, ... ,<Ik>};
<Jname>(<+node>,<-node>)=FPOLY(<P1>, ... ,<Pn>/<U1>, ... ,<Um>,<I1>, ... ,<Ik>);

where n = m + k

P1, ... ,Pn = parameter values
U1, ... ,Um, I1,...,Ik = controlling voltages and/or currents.

The coefficients are associated with the polynomial by the following convention:

Uvalue=P0 + P1 + P2*U2 + ... + Pm*Um + Pm+1*I1 + Pm+2*I2 + ... + Pm+k*Ik +
+ Pm+k+1*U 1 2 + Pm+k+2*U1*U2 + ... + Pm+k+m*U1*Um +
+ P2m+k+1*U1*I 1 + P2m+k+2*U1*I2 + ... + P2m+2k*U1*Ik +
+ P2m+2k+1*U 2 2 + P2m+2k+2*U2*U3 + ... + P2m+2k+(m - 1)*U2*Um +
+ P 3m+2k*U2*I 1 + P3m+2k+1*U2*I2 + ... + P3m+2k+k*U2*Ik + ...

Example:

e1(1,0) = 5;
r1(1,2) = 1.k;
r2(2,0) = 2.k;
e3(3,0) = FPOLY(0,0,0,1,-2,1/ur1,ur2);
r3(3,0) = 1.meg;

In the example, function FPOLY describes the relationship
E = UR12 - 2 * UR1 * UR2 + UR22

Tabular Function

FTABX function defines one-dimensional E or J controlled sources in tabular form. FTABX function describes a piece-wise linear relation between the source and argument value. Each pair of argument-function values specifies a corner of relation. The source value at argument between corners is the linear interpolation of values at the corners.

General form:

VCVS- voltage-controlled E source:
<Ename>(<+node>,<-node>)=FTABX(<A1>,<U1>,...,<Am>,<Um>/<Ux>);

CCVS- current-controlled E source:
<Ename>(<+node>,<-node>)=FTABX(<A1>,<U1>,...,<Am>,<Um>/<Ix>);

VCCS- voltage-controlled J source:
<Jname>(<+node>,<-node>)=FTABX(<A1>,<U1>,...,<Am>,<Im>/<Ux>);

CCCS- current-controlled J source:
<Jname>(<+node>,<-node>)=FTABX(<A1>,<U1>,...,<Am>,<Im>/<Ix>);

Ai = corner argument value;
Ui = corner voltage value;
Ii = corner current value;
Ux = controlling voltage;
Ix = controlling current;

Example:

Ein(1,0) = 3;
Rin(1,2) = 0.5k;
R2(2,0) = 1.k;
Jout(3,0) = FTABX(0,0,1,0.5m,3,0.8m,9,1.m/UR2);
Rout(3,0) = 150;


Chapter 2

Two-terminal Component. Description by Value

Examples:

J5(9,OUTLET) = 400;
R1(1,2) = 4.5.k;
L2(A,B) = 0.1.m;
Cin(In, Out) = 9.u;

The number in the right part of the operator determines the numerical value of an element. A numerical value is dependent on a system of measurement units that is chosen to describe this particular object. ALLTED is invariant to the system of units and can operate with any of them - SI, SGS, MKSA, USCS (United States Customary system), etc. The only condition is that all the parameters values must be measured in the same system.

The user is advised to be cautious about the system of units. The set of basic units in any measurement system have to be chosen in such a way that spread of numbers throughout the description must be as small as possible and all numerical values must be about of the order of one. Otherwise numeric problems could occur due to truncation error. Generally no problem arises and computational efficiency is good enough if the difference of orders is less than say 10...15 and numbers are distributed on both sides near zero. If the spread is shifted to negative or positive orders or its magnitude exceeds this value the default values of some parameters in the directive CONST are not good enough and need to be set explicitly. Parameters DCLC, XMAX, and SXMAX are especially influential in this situation. If some computation problems occur try to decrease these parameters up to 5...6 orders.

If the number in the right part of the operator is not accompanied by a scale suffix (see Section 2.1.5), it directly specifies the parameter value as the first operator in the example. Otherwise its value is scaled in accordance with the convention described in Section 2.1.5. Thus the value of resistor R1 in the second operator is 4500 (4.5 x 103), the value of inductor L2 (third operator in the above example) is 0.0001 (0.1 x 10-3), and Cin is assigned the value of 9 x 10-6.

If all the numeric values of components are expressed in the SI system basic units and a measurement unit for a particular quantity has been assigned its own name (volt, ampere, ohm, etc), then the suffix can be conveniently used in creating names such as KiloOhm, milliHenry, etc. If this is not the case, the suffix must be treated as merely the scale multiplier. For example, resistor R1 could be of 4.5 kiloOhm, inductor L2 - 0.1 milliHenry and capacitor Cin - 9 microFarads. But from computational viewpoint numbers 4.5k, 0.1m and 9u mean that in internal data storage the values 4500, 0.1E-3 and 9.E-6 will be sent respectively.

All the output results are represented in basic units only.

For correct measurement units system selection, other than SI, the following relationships of units should be taken into consideration:

[U]=[I]*[R] [G]=1/[R] [T]=[C]*[U]/[I] [T]=[L]*[I]/[U] [F]=1/[T]

Some of the applicable unit systems for electronic device design are listed in the following table:

[U] | [I] | [R] | [G] | [C] | [L] | [T] | [F]
V V V | mA mA mA | KOhm KOhm KOhm | mS mS mS | uF uF uF | H uH mH | msec nsec usec | KHz GHz MegHz

Two-terminal Component. Description by Function

If a component constituent equation is exactly one of the generic equations listed in Table 2.2 the component mathematical description is set implicitly by the first symbol of its name and the number in the right part of the operator. This number specifies the parameter of the equation in question. If it is not the case, a specific function must be specified in the right part of the two-terminal component description and a component is referred to as functionally-specified.

The syntax of the description of a functionally-specified two-terminal component is

<component_name> (<+node>,<-node>) = <function_name> ([<param> {,<param>}]/<arg>{,<arg>});

The <function name> is an identifier, starting with an "F", for instance, FPULSE, FPOLY, F501. The number of parameters and their numeric values depend on the function. The arguments can be:

- current of an element. Key prefix "I" begins the name of these variables. For instance, IR1, IG8, IE2, IJF;
- voltage across an element. Key prefix "U" begins the name of these variables. For instance, UC2, UR1, UG8, UJF;
- independent variables: time (keyword TIME) and frequency (keyword FREQ).

Example:

EOUTP(1,0)=F574(0., 4.678, 35./UEINPUT);
JE(I,K)=F3(IOE,TETAE,UMAX,TAUE,CBARE,GPNE/UJE);

Function F574 describes the component EOUTP. Numbers 0., 4.678, and 35. are the parameters for the function and UEINPUT is the argument. In symbolic models parameters can be assigned with symbolic names as illustrated in the second operator.

All the functions are divided into four groups:

1. Input stimuli functions. Six functions are available:

FPULSE - Pulse function
 FEXP - Exponential function
 FSIN - Sinusoidal
 FSFFM - Single frequency modulated
 FPWL - Piece-wise linear
 FTAB - Periodic piece-wise linear.

An abbreviated form of the description was developed for stimuli functions:
<component_name> (<+node>,<-node>) = <function_name> (<param>{,<param>});

Example:
Einput(1,0) = FPULSE(0,5,2,0.05,0.1,7,15);

The intrinsic function FPULSE is used here, its argument (TIME) being implicit in a fixed sequence.

2. ALLTED intrinsic device functions. They names are agreed to be from F1 to F799. Only three functions are specified by different names, they are:

FLIN or FL - linear function
 FPOLY - polynomial function
 FTABX - table-specified sources.

These three functions due to their frequent use are described it this Section. The rest are described in Sections 3 and 4.

3. User's functions defined by the ODL operator FUNCTION in the circuit description. The names of these functions are to be from F1000 to F1999 (for transient analysis) and from 3000 to 3999 for frequency-dependent elements;

4. User's functions developed and stored in the ALLTED function library by the specific user while adapting the system to specific environment and (if necessary). The names F800 ... F999 are reserved for this kind of functions.

There are more then 500 nonlinear intrinsic functions for electronic, mechanical, hydraulic, pneumatic and other element description. These functions are stored in the ALLTED libraries and readily available at the moment of ALLTED installation. They are all described in separate manuals for particular technology and in the on-line reference system. In this manual, only functions specific for electronic circuit modeling are described.


Chapter 2

Transient/Fourier Analysis Stimulus Functions

Pulse:

FPULSE function defines independent E or J sources for transient analysis. It generates a sequence of trapezoidal pulses. The behavior of the function is shown in Fig.2.2.

Fig.2.2. FPULSE stimulus function.

General form:

<Ename>(<+node>,<-node>=FPULSE(<U1>,<U2>,<TD>,<TR>,<TF>,<PW>,<PER>);
<Jname>(<+node>,<-node>=FPULSE(<I1>,<I2>,<TD>,<TR>,<TF>,<PW>,<PER>);

U1 = dc component of the output voltage
U2 = peak value of the output voltage
I1 = dc component of the output current
I2 = peak value of the output current
TD = delay
TR = rise time
TF = fall time
PW = pulse width
PER = period

Examples:

Einput(1,0) = FPULSE(0,5,1,0.05,0.1,1,2)
Jinput(N1,N2) = FPULSE(-1.m,3.m,1.u,0.1u,0.2u,5.u,20.u);

Exponential:

FEXP function defines the stimulus independent E or J sources for transient analysis. It generates the exponential pulse.
The behavior of the function is shown in Fig.2.3.

Fig.2.3. FEXP stimulus function.

General form:

<Ename>(<+node>,<-node>)=FEXP(<U1>,<U2>,<TD1>,<TC1>,<TD2>,<TC2>);
<Jname>(<+node>,<-node>)=FEXP(<I1>,<I2>,<TD1>,<TC1>,<TD2>,<TC2>);

U1 = dc component of the output voltage
U2 = peak value of the output voltage
I1 = dc component of the output current
I2 = peak value of the output current
TD1 = rise delay
TC1 = rise time constant
TD2 = fall delay
TC2 = fall time constant

The waveform could be described by the following formulas:
Time interval Value

For current sources change U1, U2 to I1, I2 in the equations.

Example:

Eexp(1,0) = FEXP(0,5,1,4,2,3.75);
E1(Pnode,Mnode) = FEXP(0.5,5,1,0.3,3,0.5);


Chapter 2

Sinusoidal:

FSIN function defines the stimulus independent E or J sources for transient analysis. The FSIN form causes the source to start at offset value and stay there for delay time. Then, the source value becomes an exponentially damped sine wave. The behavior of the function is shown in Fig.2.4.

Fig.2.4. FSIN stimulus function.

General form:

<Ename>(<+node>,<-node>)=FSIN(<Uoff>,<Uampl>,<Freq>,<TD>,<DF>,<Phase>);
<Jname>(<+node>,<-node>)=FSIN(<Ioff>,<Iampl>,<Freq>,<TD>,<DF>,<Phase>);

Uoff = offset value of the output voltage;
Uampl = peak amplitude of the output voltage;
Ioff = offset value of the output current;
Iampl = peak amplitude of the output current;
Freq = frequency;
TD = delay;
DF = damping factor;
Phase = phase.

The waveform could be described by the following formulas

Time interval Value

For J sources switch Uoff, Uampl to Ioff, Iampl in the above equations.

Example:

Egen (1,0) = FSIN(3,1.2,6,1,0.4,60);
Esin(1,3) = FSIN(0,2,5,0.5,1,45);

Single Frequency Modulated:

FSFFM (Single-Frequency Modulated) function defines the stimulus independent E or J sources for transient analysis. The behavior of the function is shown in Fig.2.5.

Fig.2.5. FSFFM stimulus function.

General form:

<Ename>(<+node>,<-node>)=FSFFM(<Uoff>,<Uampl>,<FC>,<MOD>,<FM>);
<Jname>(<+node>,<-node>)=FSFFM(<Ioff>,<Iampl>,<FC>,<MOD>,<FM>);

Uoff = offset value of E source;
Uampl = peak amplitude of E source output value;
Ioff = offset value of J source;
Iampl = peak amplitude of J source output value;
FC = carrier frequency;
MOD = modulated index;
FM = modulation frequency.

The FSSFM form causes the source value to follow formula:

Example:

Jin(1,2) = FSFFM(1.m,1.m,10,2,2);


Chapter 2

Piece-Wise Linear:

FPWL function defines the stimulus independent E or J sources for transient analysis. The FPWL form describes a piece-wise linear aperiodic waveform. Each pair of time-function values specifies a corner of the waveform. The source value at time between corners is the linear interpolation of the values at the corner. The behavior of function is shown in Fig.2.6.

Fig.2.6.FPWL stimulus function.

General form:

<Ename>(<+node>,<-node>)
= FPWL(<T1>,<U1>,
... ,<Tn>,<Un>);
<Jname>(<+node>,<-node>)
= FPWL(<T1>,<I1>,
... ,<Tn>,<In>);

Ti = time corner value;
Ui = voltage corner value;
Ii = current corner value;
i = 1, ..., n .

Example:

Ein(1,2) = FPWL(0,0,1,0.01,2,5,3,1,4,2);

Periodic Piece-Wise Linear:

FTAB function defines stimulus an independent E or J sources for transient analysis. The FTAB form describes a piece-wise linear periodic waveform. Each pair of time-function values specifies a corner of the waveform. The source value at time between corners is the linear interpolation of the values at the corner. The behavior of function is shown in Fig.2.7.

Fig.2.7. FTAB stimulus function.

General form:

<Ename>(<+node>,<-node>) = FTAB(<T1>,<U1>, ... ,<Tn>,<Un>);
<Jname>(<+node>,<-node>) = FTAB(<T1>,<I1>, ... ,<Tn>,<In>);

Ti = time corner value;
Ui = voltage corner value;
Ii = current corner value;
i = 1, ..., n .
Example:
J5(10,3) = FTAB(0,0,1.u,0,1.5u,3,2.u,2,3.u,2,4.u,1);

Device common functions

Linear Function:

FLIN (FL) function defines all types of E or J controlled sources. The value of function is linear combination of its arguments. The number of arguments must be equal to the number of parameters.

General form for:

<Ename>(<+node>,<-node>)=FLIN(<P1>, ... ,<Pn>/<U1>, ... ,<Um>,<I1>, ... ,<Ik>};
<Jname>(<+node>,<-node>)=FLIN(<P1>, ... ,<Pn>/<U1>, ... ,<Um>,<I1>, ... ,<Ik>);

where n = m + k

P1, ... ,Pn = parameter values;
U1, ... ,Um = controlling voltages;
I1, ..., Ik = controlling currents.

The value of controlled source could be evaluated by the following formula

Example:

r1(1,2) = 1.k;
r2(2,0) = 2.k;
e3(3,0) = FLIN(0.5,2/ur1,ur2);

The output of the voltage source e3 is determined as

Ue3 = 0.5*Ur1 + 2*Ur2,

where Ur1, Ur2 are the voltages read out across resistors r1 and r2.


Chapter 2

Mathematical Functions for Behavioral Modeling

ODL allows nonlinear functions to be defined in the input file. Such a definition is made in a separate section of the description part and must begin with the title-operator FUNCTION. This operator is followed by the function description. The syntax is:

FUNCTION <func_name>([<formal_par>{,<formal_par>}]/<formal_arg>{,<formal_arg>});

The function name <func_name> should begin with the key prefix "F", followed by an integer, defining the function number. For instance: F1001, F1520.
The numbers of functions for transient analysis must be from 1000 to 1999. For frequency-dependent elements the numbers are from 3000 to 3999.
Any identifiers can serve as formal parameters <formal_par> and formal arguments <formal_arg> in the function operator.
The function text in a general case is an expression, consisting of arithmetic and logic operations, standard mathematical functions, constants and names of formal parameters and arguments.

Example:

FUNCTION F1002(A,B,C/X1,X2);
A+B*X1+C*X2;

This function, now defined, may be used to describe, for instance, a controlled current source:

Jout(1,7) = F1002(1.2,2.4,4.3/UR1,UR2);

The formal parameters A, B, C are assigned the values 1.2,2.4,4.3 respectively, and the formal arguments are the voltages across resistors R1 and R2.
The above is an example of a very simple function description using arithmetic expressions. Such expressions are formed according to standard rules and may include arithmetic operations symbols, parenthesis and references to standard mathematical functions. The following arithmetic operations are legal:

+ addition;
- subtraction or a unitary minus;
/ division;
* multiplication;
^ raising to a power (see also EXP).
The following single variable mathematical functions can be
used in expressions:
LN - logarithm;
LG - base 10 logarithm;
SIN - sine;
COS - cosine;
TG - tangent;
CTG - cotangent;
ARCSIN - arsine;
ARCCOS - arccosine;
ARCTG - arctangent;
EXP - exponent;
SQRT - square root;
ABS - modules;
SIGN - sign;
SINH - hyperbolic sine;
COSH - hyperbolic cosine;
TANH - hyperbolic tangent.

Along with the above listed mathematical expressions the
function description can include numeric constants according to
the rules of ODL.
The function can use conditional expressions of the type:

IF <logical expression> THEN
<expression>;
ELSE
<expression>;

Example:
FUNCTION F1011(Ampl,Per,TD,Phase / X);
IF X >= TD THEN
Ampl * SIN(6.2832 * X / Per + Phase);
ELSE
0.0;
Conditional expressions may be nested:
FUNCTION F1001 (V0, T1, T2, A, B, W / X);
IF X < T1 THEN
V0;
ELSE
IF X > T2 THEN
0;
ELSE
A * COS(B * X + W);

Note: The ELSE branch is compulsory in a conditional expression.
The keyword "IF" is followed by a logical expression, which basically is the comparison of two arithmetic expressions. These comparison types are allowed:

> greater than;
>= greater or equal;
< less than;
<= less or equal;
<> unequal.

Complex logic expressions are formed, using logic operations OR and AND, for instance:

FUNCTION F1006 (A / X1, X2, X3);
IF X1 <= ABS(X2) AND X1 >= -ABS(X3) THEN
A*X1;
ELSE
IF X1 >= ABS(X2) THEN
A*X2;
ELSE
A*X3;

The AND operation has higher priority than OR. The order of logic computations can be changed using brackets [...]. For instance, in expression

A>0 OR B>0 AND C>0
the first operation to be performed is AND, and the second is OR. If OR must be evaluated in the first place, the expression should be written as:

[ A>0 OR B>0 ] AND C>0

With the above language constructions the user may describe complex arbitrary nonlinear functions. Frequently used functions may be put into the ALLTED library and called many times without additional description.

More information on user functions is given in Chapter 11 on Behavioral Modeling in the "Main Manual".


Chapter 2

Two-terminal Component. Description by Table

The ALLTED input language supports table-defined two-terminal component description in two ways. The first one is to use a special input language operator:

<TABname> = <arg_value>,<func_value> {,<arg_value>,<func_value>};

The table name <TABname> should always begin with the key prefix "TAB". The equal sign is followed by pairs <arg_value>, <func_value>, defining corner points. The argument values must be listed in ascending order.
The table once defined, can be used to specify one or more two-terminal components in the model where it was defined. The table description may be placed anywhere in the model. No such operator is allowed in symbolic models although the FPWL, FTAB and FTABX functions described below can be used.

Example:

J5(10,3) = TABIN(TIME);
TABIN = 0,0, 1.u,0, 1.5u,3, 2u,2, 3u,2, 4u,1;
These two ODL operators describe a table-defined J-source. The argument of the table is TIME.
E2(1,0) = TAB3(UCINP);
TAB3 = 0,0, 1.,12.0, 1.5,14, 20,20, 30,25, 40,28;
The argument of the table TAB3 is UCINP.
If an argument of the table exceeds its maximum specified value the table will re-start at the beginning.

The second way is to use the FPWL, FTAB, FTABX functions, developed to describe table-defined components:

FPWL describes a time-dependent piece-wise linear aperiodic waveform. Each pair of time-output values specifies a corner of the waveform. An output between corners is the linear interpolation of values at corners.
Example:
J5(10,3)=FPWL(0,0, 1.u,0, 1.5u,3, 2u,2, 4u,1);

FTAB describes a time-dependent, piece-wise linear periodic waveform.
Example:
J5(10,3)=FTAB(0,0, 1.u,0, 1.5u,3, 2u,2, 4u,1);

FTABX describes a piece-wise linear relation between the output and input values. Each pair of argument-function values specifies a corner of relation. An output between corners is the linear interpolation of values at corners.
Example:
E2(1,0) = FTABX(0,0, 1.,12.0, 1.5,14, 20,20,30,25,40,28/UCINP);

Two-terminal Component Description in Symbolic Models

A symbolic description of two-terminal components is used when these components are parts of a symbolic model. The symbolic names are used instead of numeric values or function parameters, while the parameter values are given in the list of symbolic model parameters. The model is considered to be symbolic if at least one of it's parameters is assigned with a symbolic name.

Examples of symbolic descriptions are:

RB(B,INB) = RB;
JK(INB,K) = F3(IOK,TETA,UMAX/UJK);
JK(INB,K) = F3(IOK,TETA,0.9/UJK);

The first operator describes resistor RB inserted between nodes B and INB. The value of the component is defined symbolically - by the name RB. The second one describes nonlinear current source JK, connected between nodes INB and K. The function type is given by the F3 identifier, and all the parameters are in symbolic form. The third operator describes the same source JK, but its third parameter is numeric. All of the symbolic names are to be assigned with numeric values in the object description.

Multi-terminal component description

A multi-terminal component can be described with one of two forms:

<component_name>(<node>,<node>{,<node>}) = <model_name>;
<component_name>(<node>,<node>{,<node>}) = <list_name>.<model_name>[(<substitution list>)];

From a syntactic point of view the name of a multi-terminal element can be any identifier, i.e., a sequence of letters and digits, beginning with a letter. However, the first letter can not be any of the letters reserved for the basic two terminal components: R, G, C, L, J, E. The name is followed by node_names separated by a coma and enclosed in parenthesis. The node_names must be strictly in a particular order, defined by the title-operator of the model.The name of the model that describes this multiterminal component is specified in the right part of the operator, after the '=' sign: D1(4,8) = 1N747;T3(3,4,11,0) = 2N2217.NPN;

Two types of models are available. If the model is a conventional one, i.e. does not contain any symbolic parameter, then only it's name is mentioned in the operator (1N747). If a symbolic model is used to simulate this particular multi-terminals, then the name of the parameter list of the symbolic model (2N2217 in the example) and the name of the model itself (NPN) should be specified. These names are separated by a point and jointly form the compound name of the parameter list. The parameter list with this name should be described in a description part or be available in a library.


Chapter 2

MODEL Title-operator

The model description must begin with the title-operator MODEL, which has the syntax:
MODEL <model_name> (<terminal_name>,<terminal_name>{,<terminal_name>});

The MODEL operator defines the name of the model and the names and order of its terminals, for instance:

MODEL NPN(C,B,E,S);MODEL AMPL(INPUT, CONTR, INVERT, OUTPUT, BASE);The MODEL operator is followed by the two- and multi-terminal component operators which constitute the model. The end of the model description is specified by the next title-operators such as MODEL, LIST, FUNCTION or by the "&" character, which terminates the object description.

LIST of Model Parameters

The parameter list of a symbolic model assigns the values to its symbolic parameters. It begins with the title-operator LIST which defines the compound name of the list.

Example:
LIST 1N747.D;
LIST D631HR. SVALVE;

The compound name of the parameter list includes the list name itself (1N747. D631HR) and the name of the symbolic model (D, SVALVE) whose parameters are assigned in the list. After the title-operator the list of symbolic parameters with their numeric values follows:

LIST <list_name>.<model_name>;<param_name> = <value>;{<param_name> = <value>;}

The parameter list is restricted by the next title-operator MODEL, LIST, FUNCTION or by the end of a description sign "&". All the model symbolic parameters must be assigned in the list. The parameter names and their number must precisely correspond to the symbolic model description.Example:List 1N747.DIOD;

Area = 1;
M = 0.5; Is = 5.u;
Rs = 12;
N = 1; Tt = 0;
Cjo = 0;
Vj = 1;
Eg = 1.11;
Xti = 3;
FC = 0.5;
Bv = 3.15;
Ibv = 5.u;
IOFF = 0;

Symbolic Model Parameters Modification

A symbolic model being used to specify some multi-terminal component can be modified for this specific case. To do this, the list of new absolute or relative values of the model parameters enclosed in parenthesis has to be inserted in the operator. Relative values must be followed with "%" sign.

Example:
T1(2,3,7,0) = 2N2222.NPN (ALPHA=4.E-3);
T2(5,8,6,0) = 2N2222.NPN (RB=105%, RC=1.2);

Coefficient ALPHA of element T1 will be assigned a value of 4.E-3 overriding the value specified in the LIST 2N2222.NPN. The new value of parameter RB of element T2 will be relative, 1.05 times the value specified in the list 2N2222.NPN. In the last example parameter, RC is also assigned new value for element T2.

Circuit Description Example

The invertor with the Ebers-Moll transistor model (Fig.2.8) is considered as the example.
The example is stored in the ALLTED\EXAMPLE\MAIN directory as inv_tr.atd file and can be readily run.

Fig. 2.8. Invertor.

1 OBJECT
2 CIRCUIT INV;
3 E1(0,3) = 10;
4 E2(5,0) = 10;
5 EIN(1,0) = TAB1(TIME);
6 RIN(1,2) = 1;
7 RCM(2,3) = 100;
8 RP(5,4) = 0.97;
9 C1(0,2) = 0.1;
10 JIL(0,2) = 0.1;
11 L3(2,3) = 10;
12 G4(3,5) = 0.2;
13 Q1(0,2,4) = M1.NPNEM (RBASE=20);
14 TAB1 = 0,0, 5,0, 10,25, 60,25, 65,0, 100,0;
15 MODEL NPNEM(E,B,C);
16 RB(B,INB) = RBASE;
17 REM(E,INC) = REMIT;
18 RC(C,INA) = RCOLL;
19 JE(INB,INC)= F3(ISE,TETAE,UMAX,TAUE,CBARE,GPNE/UJE);
20 J1(INA,INB) = FL(ALPHAN/IJE);
21 JC(INB,INA)= F3(ISC,TETAC,UMAX,TAUC,CBARC,GPNC/UJC);
22 J2(INC,INA) = FL(ALPHAI/IJC);
23 LIST M1.NPNEM;
24 RBASE = 1.8E-3;
25 REMIT = 0.2E-3;
26 RCOLL = 0.27E-3;
27 ISE = 4.29E-11;
28 ISC = 5.78E-11;
29 TETAE = 38.3;
30 TETAC = 38.3;
31 UMAX = 0.9;
32 TAUE = 0.62E-3;
33 TAUC = 0.55E-3;
34 CBARE = 18.66E-3;
35 CBARC = 0.997E-2;
36 GPNE = 10E-6;
37 GPNC = 10E-6;
38 ALPHAN = 0.99;
39 ALPHAI = 0.899;
40 &

All the description lines are numbered for clarity, and the meaning of some statements is commented lower:

-line 1: header-directive, defining the description to follow;
-line 2: title-operator of the main circuit, starting the description proper and identifying the name of the object: INV
-lines 3, 4: the description of constant voltage sources with names E1, E2 and nominal values of 10 Volts;
-line 5: the description of a time dependent table defined input voltage source EIN, the corresponding description table should be named TAB1;
-lines 6-12: the description of resistors, a capacitor, a current source and an inductance;
-line 13: the description of transistor Q1, the emitter of which is connected to the base node of the main circuit,
the base - to node 2, and the collector - to node 4. For models translated from SPICE files, a fourth node is used, the substrate, usually connected to grounds. The connection to the circuit nodes are done here, the node sequence of the model is established by the model description. In the right part of the statement there is a reference to a symbolic model of a n-p-n transistor (NPNEM) in which the RBASE parameter value will be changed to 20. The parameter list is described by the name M1.NPNEM;

-line 14: the description of table TAB1;
-line 15: model NPNEM title-operator with external nodes E, B, C;
-lines 16-22: symbolic descriptions of two-terminal elements - all the parameters are defined by symbols; the symbols are then specified in the LIST below.
-line 23: the title-operator of the parameter list;
-lines 24-39: the description of the parameter list;
-line 40: the end of the description.


Chapter 2

ALLTED - SPICE Circuit Comparative Description

Let us consider the description of a standard TTL gate.

Fig. 2.9. TTL gate.

PSpice | ALLTED
Vcc 4 0 | Ecc(4,0)=5;
Vb 1 0 3 | Eb (1,0)=3;
Vin 2 0 PULSE(3 0 0 2ns 2ns 50ns 80ns) | Ein(2,0)=FPULSE(3,0,0,2.n,2.n,50.n,80.n);
Rb 4 5 4K | Rb (4,5)=4.K;
R1 4 6 1.6K | R1 (4,6)=1.6K;
R2 8 0 1K | R2 (8,0)=1.K;
C1 3 0 1p | C1 (3,0)=1.p;
* | #
D1 0 1 DEF | D1 (0,1)=DEF.D;
D2 0 2 DEF | D2 (0,2)=DEF.D;
D3 10 3 DEF | D3(10,3)=DEF.D;
* | #
Q1 9 5 1 MOD1 | Q1(9,5,1,0)=DEF.NPN
 | (Bf=100,Rb=100,Tf=1ns,Cjc=3pF);
Q3 6 9 8 MOD1 | Q3 (6,9, 8,0)=DEF.NPN
 | (Bf=100,Rb=100,Tf=1ns,Cjc=3pF);
Q4 7 6 10 MOD1 | Q4 (7,6,10,0)=DEF.NPN
 | (Bf=100,Rb=100,Tf=1ns,Cjc=3pF);
Q5 3 8 0 MOD1 | Q5 (3,8, 0,0)=DEF.NPN
 | (Bf=100,Rb=100,Tf=1ns,Cjc=3pF);
.MODEL DEF D() |
.MODEL MOD1 NPN(Bf=100 Rb=100 Tf=1ns Cjc=3pF) |

In this example, ALLTED uses as the transistor model: NPN with default parameter list DEF, which are modified for parameters BF, RB, TF and CJC. For all diodes we use a model D with default parameter list DEF. Both model descriptions and parameter lists are in the ALLTED library.

Another example of both descriptions comparison is a passive filter.

Fig. 2.10.

PSpice | ALLTED
Vin 1 0 PWL(0 0 2 0 2.1 1 38 0 38.1 0 0 50) ; | Ein(1,0)=FPWL(0,0,2,0,2.1,1,38,0,38.1,0,0,50);
R1 1 2 10K | R1 (1,2)=10.K;
R2 2 0 1Meg | R2 (2,0)=1.Meg;
L1 2 0 1.5E-3 | L1 (2,0)=1.5E-3;


Chapter 2

Names of Elements, Parameters and Nodes

In many directives it is necessary to specify the names of two-terminal components, parameters or nodes, and, possibly, of a complex, hierarchical elements. Such names in terms of the ALLTED input language are called "full names" and are formed with the name of a corresponding two-terminal components, node or parameter of the model and of the names of multi-terminal components, including the model. The names of multi-terminal components in the full name are delimited by a point "." and ordered according to the decrease of their hierarchy level.

The following is an example of full names forming for two-terminal components, parameters and nodes in circuit description (unessential description fragments are omitted):

CIRCUIT PULSEFORM;
R1(16,0) = 100;
F2(0,5,6,10) = FORM2;
F3(0,6,7,9) = FORM2;
. . .
MODEL FORM2(0,1,12,10);
T1(7,9,0) = TR.NPNEM;
T2(8,10,0) = TR.NPNEM;
EPI(13,0) = 5;
. . .
MODEL NPNEM(B,E,C);
RB(B,IN) = RBASE;
JE(IN,E) = F3(I0E,TETAE,UMAX,TAUE,CBE,GPNE/UJE);
. . .
LIST TR.NPNEM;
RBASE = 0.01;
I0E = 0.2E-9;
. . .
&

In the main circuit PULSEFORM two multi-terminal components F2 and F3 are inserted, the models of which, in turn, also contain multi-terminal components - transistors T1 and T2. The transistors are described by a symbolic model NPNEM and a parameters list TR.NPNEM.

The following full names are legal for the previous description:

a) R1 - the name of resistor R1 in the main circuit;
b) EPI.F2 - the name of the voltage source in model FORM2, which describes the F2 multi-terminal component;
c) EPI.F3 - the name of the same voltage source EPI, but in multi-terminal component F3;
d) 7.F2 - the name of the internal node 7 in the multi-terminal component F2 (model FORM2);
e) RB.T1.F2 - the name of resistor RB, described in the symbolic model NPNEM of transistor T1;
transistor T1 is nested into multi-terminal component F2 (the model of the latter is a joint one and has the name FORM2);
f) RB.T1.F3 - the name of the same resistor RB in transistor T1, when the latter is nested into multi-terminal component F3;
g) IN.T1.F3 - the name of the internal node IN of transistor T1 in multi-terminal component F3;
h) RBASE.T1.F3 - the name of parameter RBASE of the NPNEM model of transistor T1 in multi-terminal component F3.

Note: The name 12.F2 is incorrect, as node 12 is an external node of model FORM2 and is actually presented in the circuit by node 6 of the main circuit. Due to this, the node name E.T2.F2 is also incorrect as it is the node 10 of the main circuit.

Models, Lists and Functions Library

Once developed, any model, parameter list or user-defined function can be stored in the ALLTED models, lists, and functions library (referred to as a library in the following). In case the input file lacks some model, parameter list or user-defined function referred to in an object description, the translator will automatically try to retrieve them from the library. The library may be accessed many times as newly retrieved modules may refer to other models, lists, and functions, and so on.

To handle the library, ALLTED Library Service module was developed which can operate either in a dialogue or command mode. The dialogue mode is initiated through the item 'Library' in the ALLTED main menu. The development of this section is concerned with the text commands that can be entered through a text input file with the directive-heading LIBRARY.

Information about library elements are kept in files that are created by the ALLTED Library Service module. An extension ".ALB" is assigned to these files. Each file is treated as a separate library. The file with the name ALLTED.ALB is accessed by default.

ALLTED can interact simultaneously with up to 10 libraries, but the overall number of libraries not restricted. For user convenience, any type of element (transistors of same specific type, opamps, valves, mechanisms, etc.) can be grouped in a separate library.

Library. Command mode

The ALLTED Library Service module accessed through the main menu item operates in a dialogue mode. The dialogue dealing with in this section is activated by the input language translator when an object description is being processed.

The dialogue is initiated if a model, list, or function used in an object description does not have its description included in the file, and the SEARCH directive is not included in the object part of the input file.

Switching to dialogue mode during a description translation is accompanied by a prompt on the screen:

Library file [ALLTED[.ALB]][;]:

The user must type the file name of the library to be used and press <ENTER>. Several options are acceptable:

1. Entering the "*" (asterisk) character instead of the name rejects library usage. In this case the search for models, parameter lists and functions will be prohibited, notwithstanding the availability of corresponding library sections.
2. Pressing <ENTER> leads to the use of the standard ALLTED.ALB library in the current directory.
3. When a library file name is entered, the system assumes the default "ALB" extension. For instance, name USER is an acceptable short form of the full name of library USER.ALB in the current directory. If necessary, the path to the library may be specified:
C:\ALLTED\LIB\USER

where
C:\ALLTED\LIB\ is the path, and USER is the library file name with the standard "ALB" extension. In a path specification to a standard library ALLTED.ALB name ALLTED must be explicit:..\..\ALLTED\LIB\ALLTED
4. A different from "ALB" library file name extension must be explicit, for instance USER.LBS. If the library file does not have an extension, the delimiting period should be specified.
5. A library file name may be terminated by a semicolon ";" before the <ENTER> key is pressed. In this case the input language translator changes to a mode of forming a chain of libraries, i.e. the ";" symbol is regarded as a sign of further library file names specification. In response to the next request of a library file name, the user can type the name of another library and a terminating ";" symbol if necessary. Thus a library chain may be formed, regarded by the translator as one library. Information search in a library chain is performed sequentially in the order the library file names were entered and terminates when the necessary description section is first found without searching other libraries in the chain.

A chain may consist of no more than 10 libraries. The standard library name ALLTED.ALB can be included to the chain by specifying only the ";" symbol. The library chain forming process is terminated by not typing a semicolon after the library file name, or by entering the "*" symbol. The dialogue query of library names is issued once before the library is accessed for the first time.


Chapter 2

SEARCH Library Directive

An alternative way of library usage is the application of the SEARCH directive which allows the inclusion of information about the libraries directly into the object part of the input file. No dialogue is initiated in this case.

The syntax of the directive is:

SEARCH [<library>{,<library>}];

The SEARCH directive is positioned directly before the CIRCUIT title-operator in the object part of the input file. Only one SEARCH directive is allowed in the description part. In the simplest case the directive has the form (the ";" is important):

SEARCH;

In this case the search is performed in the standard ALLTED.ALB library in the current user catalog.

Example:
OBJECT;
SEARCH HVALVE;
CIRCUIT AMPLIFIER;

The library file HVALVE.ALB is assigned in the directive SEARCH. Only the models, lists and functions (if missed in the circuit AMPLIFIER description) in this library will be searched to complete the object description.

In a more general case, the SEARCH directive can combine several libraries in the library chain (3.3.1.1). The file names in the chain are separated by a "," (coma):

SEARCH DIODE, TRANS, USER;

A chain of three libraries has been developed in the example: DIODE.ALB, TRANS.ALB and USER.ALB. The input language translator treats the chain of libraries as one library and the search is performed in the order the files are listed in the SEARCH directive.

The SEARCH directive syntax does not allow extension specification in the library file name, so only library files with default "ALB" extension can be used. Another peculiarity of the SEARCH directive is that all enumerated library files must reside in the current user directory.

Libraries file names must satisfy regular MS-DOS conventions for file names. However, if library names use symbols, which are not decimals or letters, these names should be specified in quotation marks:

SEARCH "NPN-1", "NPN-2";

The chain of two libraries: NPN-1.ALB and NPN-2.ALB is developed in the example.
Names, consisting only of decimal numbers are also allowed as notation marks: "1234".
To include the standard library ALLTED.ALB in the chain, its name must be specified explicitly.

SEARCH USER, ALLTED;

The priority of libraries can be manipulated in this way. If two or more libraries contain sections with the same names, information will be retrieved from the library listed earlier in the library specification chain.

To conclude, note that the line:
SEARCH;
is completely equivalent to the line

SEARCH ALLTED;
The input language translator diagnoses syntax errors, the lack of libraries in the current directory, and other errors.

Library Controlling Directives

Library Controlling Directives are a separate part of the input file. They are set off with a header-directive LIBRARY and terminated with the "&" symbol. These directives are used to create or delete a library, print out its catalog, add new sections to the library, etc. All of these operations can be performed in dialogue mode by interacting with ALLTED Library Service module through the main menu.

All operations, described in each separate library portion of the input file are performed with only one library. The corresponding library file name may be assigned directly in the LIBRARY directive:

LIBRARY C:\ALLTED\LIB\ALLTED.ALB

The library_file_name must obey DOS conventions and be separated from the LIBRARY keyword by one or several spaces. The "ALB" extension can be omitted. Several library parts may be inserted into an input file, each for its own library.

If the library name is not assigned in the LIBRARY directive, the ALLTED Library System issues a query, asking for the library name. In response to:

Library file [ALLTED[.ALB]]:

the library file name must be entered followed by <ENTER>. The "ALB" extension may also be omitted. Pressing <ENTER> without typing in the library name is equivalent to entering the standard name ALLTED.ALB. The query is issued before the processing of each library part of the input file, for any LIBRARY directive that doesn't explicitly assign the library_file_name.

CREATE Library

The directive CREATE is used to create a new library. Its syntax is:

CREATE <lib_size>,<catal_size>;

where
lib_size = integer, defining the maximum library size;
catal_size = integer, defining the catalog size.

The library and catalog sizes are measured in blocks. The block is a library information unit and is equal to 82 bytes. The maximum possible library size is 32767 blocks. A block may contain one line of text (data block) or data on four library sections (catalog block). The library has the following structure: the first block of a library always contains service information (statistics block) which is followed by catalog blocks and data blocks. Thus the second parameter of the CREATE directive defines the number of blocks from the total library size, which is for the catalog. The maximum catalog size depends on the library size: at least one data block must correspond to a catalog entry. This should be taken into account to correctly evaluate the sizes of the library and its catalog.

Example:

CREATE 1000,10;

Here a library is created, the maximum size of which is 1000 blocks (82000 bytes). The catalog size is 10 blocks, so it may hold data on 40 library sections. The available space for library data is 989 blocks (as the catalog blocks and the statistics block are included into the total number of library blocks).

The CREATE directive must go first in the library part.

LIST Library Sections

The LIST directive writes the list of library sections to the ALLTED.OUT file. Section names in the list are ordered alphabetically. This directive has no parameters and is written in the syntax:

LIST;

PRINT Library Section

The PRINT directive writes the assigned library sections to the ALLTED.OUT file. Its syntax is:

PRINT <section_name>{,<section_name>};

The section_name is the name of the output sections:

PRINT NPN, 2N2222.NPN, F1001;

DELETE Section from Library

The DELETE directive deletes sections from the library:

DELETE <section_name>{,<section_name>};

For example:

DELETE 1N747.D, 2N2217.NPN;


Chapter 2

PUT Section into Library

The directive PUT stores sections into the library. Its syntax is:

PUT <section_name>{,<section_name>};

The parameters of the directive are the names of the new sections, which will be put into the library.

The PUT directive writes the descriptions, directly following the library part into the library. These may be the descriptions of models, parameter lists or user's functions. Each description must be terminated by a "&" symbol and should not contain lines longer than 80 symbols. The order of the sections to be put into the library in the input file is defined by the order of their names in the PUT directive. The names of sections, specified in the PUT directive must coincide with the names of corresponding models, lists and functions.

Example:

LIBRARY;
PUT NPN, 2N2222.NPN;
&
MODEL NPN(E,B,C);
.
.
&
LIST 2N2222.NPN;
.
.
&
END

A syntax check is performed prior to writing a section to the library. If errors are found in a section, it is not stored in the library. Syntax check results are routed to the output file ALLTED.OUT.

SQUEEZE Library

Some library operations (for instance, deleting and rewriting sections) leave blank spaces in the library, which can not be used for other sections. In the course of intensive library operations it is necessary to squeeze the library from time to time, using the SQUEEZE directive:

SQUEEZE;

This directive has no parameters.

Library Part, Example

Consider the following description:

LIBRARY ALLTED
LIST;
DELETE NPN, 2N2222.NPN;
PUT 1N747.D;
SQUEEZE;
LIST;
&
List 1N747.D;
Area=1; Is=5.u; Rs=12; N=1;
Tt=0; Cjo=0; Vj=1; M=0.5;
Eg=1.11; Xti=3; FC=0.5;
Bv=3.15; Ibv=5.u; OFF=0;
&
END

The above example consists of only one library part. The name "ALLTED" is specified in the LIBRARY directive so all library operations will be performed with the ALLTED.ALB library in the current user's directory. The first operation is the output of a list of library sections to the ALLTED.OUT file. Then the NPN and 2N2222.NPN sections are deleted from the library and a new section, 1N747.D, is stored. The text of this section starts after the "&" sign, terminating library operation descriptions, and is also terminated by a "&". After the above operations are completed, the library is squeezed and the list of the updated library is printed again. The header-directive END defines the end of the input data flow.

A more powerful means to handle the libraries is available in the ALS - ALLTED Library Service subsystem. It offers a complete set of library operations and functions with the convenience of a user-friendly interface.

Task Control Language

The Task Control Language (TCL) is used to define the analysis type, to adjust the procedures, to set the form and content of output results, etc.

The task portion is written as a separate part of the input file, is named the task part and is located after the description of the circuit. In general an input file can contain several task parts, each of which defines a different kind of analysis. The task part begins with the header-directive TASK and ends with the "&" symbol.

The main language item of TCL is the directive. The order of directives in the task part is arbitrary, as very often the simulation mode is defined by directives combinations.

Names of Elements, Parameters, and Nodes

Generally, the name of an element, parameter or node is either a compound one or "full name" in terms of the ALLTED input language. It is formed with the name of an element, node or parameter assigned to it within its own model and of the names of multi-terminal elements in which this model can be enclosed (nested). The names of multi-terminal elements in the full name are delimited by a point "." and ordered according to the decrease of their nesting level.

Example:

Consider the fragment of a description (unessential details are omitted):

CIRCUIT PULSEFORM;
R1(16,0) = 100;
F2(0,5,6,10) = FORM2;
F3(0,6,7,9) = FORM2;
. . .
MODEL FORM2(0,1,12,10);
T1(7,9,0) = TR.NPNEM;
T2(8,10,0) = TR.NPNEM;
EPI(13,0) = 5;
. . .
MODEL NPNEM(B,E,C);
RB(B,IN) = RBASE;
JE(IN,E) = F3(I0E,TETAE,UMAX,TAUE,CBE,GPNE/UJE);
. . .
LIST TR.NPNEM;
RBASE = 0.01;
I0E = 0.2E-9;
. . .
&

In the main circuit PULSEFORM two multi-terminal elements, namely F2 and F3, are inserted. The models of these, in turn, also contain multi-terminal elements T1 and T2 described by a symbolic model NPNEM and a parameter list TR.NPNEM.

The following names are legal for the previous description:

a) R1 - the name of resistor R1 in the main circuit;
b) EPI.F2 - the name of source EPI of the F2 multi-terminal element. The element F2 is described with the model FORM;
c) EPI.F3 - the name of source EPI of the F3 element. This element is described with the same model FORM;
d) 7.F2 - the name of node 7 in the multi-terminal element F2 (model FORM2);
e) RB.T1.F2 - the name of component RB of the element T1 (symbolic model NPNEM describes the structure of the element) nested into multi-terminal element F2 (the latter is simulated by the model FORM2);
f) RB.T1.F3 - the name of the component RB of the element T1 nested into multi-terminal element F3;
g) IN.T1.F3 - the name of the internal node IN of the element T1 nested into multi-terminal element F3;
h) RBASE.T1.F3 - the name of a parameter RBASE of the element T1 in multi-terminal element F3.

Note: The name 12.F2 is illegal because node 12 is an external node (terminal) of model FORM2 and actually is node 6 of the main circuit. For the same reason, the node name E.T2.F2 is also illegal as it is the node 10 of the main circuit.


Chapter 2

Analysis Directives

These types of directives define the kind of analysis to be performed with the object under design. Several directives of this group can be used in one task part if they are the parts of one procedure. No parameters accompany these directives:

DC - steady-state analysis;
 AC - frequency response determination;
 TR - transient analysis;
 SA - sensitivity analysis;
 WCD - worst case design;
 OPTIM - optimization;
 TOLAS - optimal tolerance assignment;
 STA - Monte-Carlo (statistical) analysis;
 FOUR - Fourier analysis;
 MVA - multivariant analyses.

Each type of analysis directive must be terminated by a semicolon, for instance:
OPTIM;
A detailed description of each directive's usage is given in the sections that deal with that particular analysis.

Output Directives

The output directives define the scope of output variables and characteristics to be computed in the task and the format of their presentation (table or graphic).

TABLE - display results in tabular format;
 PLOT - display results in graphic format;
LPLOT - plot graph using logarithmic scale;
TPLOT - print variables being plotted first;
 LTPLOT - same as TPLOT but with logarithmic scaling along X-axes;
 FIX - set output characteristics (secondary variables);
 INT - define difference between FIX's characteristics;
 FUNC - set complex output characteristics;
 HISTO - plot statistical data as histogram;
 SPECTR - plot linear spectrum.

TABLE, Put Results in Table Format

The TABLE directive output results in a table format and has the syntax:

TABLE <out_var>[=<alias>]{,<out_var>[=<alias>]};

In time-domain transient analysis (TR-analysis) the following variables <out_var> can be output:

V<node> - node potential (voltage, absolute velocity, pressure,displacement, etc);
I<name> - flow variable (current, force, torque, flow rate, heat flow, etc) through a two-terminal component;
U<name> - across variable (voltage, relative velocity, pressure drop, temperature differential, etc) across a two-terminal component;
P<name> - power dissipated by a two-terminal component;
ALLV - potentials of all circuit's nodes;
ALLI - flow variables of all two-terminal elements;
ALLU - across variables across all circuit's two-terminals;
ALLP - power, dissipated by each two-terminal element;
<name> - value of any two-terminal component in the circuit (<name> isa full name of the element).

For example:

TABLE UR1, V7.F2, IJE.T2.F3;
TABLE ALLI, ALLU;

The first TABLE directive specifies the variable UR1 (voltage across resistor R1 of the main circuit), node potential of node 7 of multi-terminal element F2, and variable JE.T2.F3 (current of source IJE of element T2 nested into element F3) to be printed in tabular format. The second TABLE directive sets all the flow and across variables to be output.

An alias name <alias> may be assigned to make the results more vivid.
TABLE UR1 = VOLTAGE, V5=PRESSURE;

The name "UR1" in the table will be substituted with "VOLTAGE" and the name V5 - with "PRESSURE". Any identifier may be used as the alias after the equal sign, but only its first 8 characters are valid.

One task part may contain several TABLE directives. One variable can be specified in several directives. The directive TABLE can be used only in time-domain analyses.

To set the time interval between table portions a keyparameter, DITAB, of the directive CONST was designed. Keyparameter STTAB sets the instant of time to start TABLE printing. (See Appendix B).


Chapter 2

PLOT, Output Results in Graphic Format

The directive PLOT sets the results to be output in graphic format:

PLOT <out_var> [=<alias>] {,<out_var>[=alias]} [([<np>,] [<arg>,] [<from>,<to>])];

wher:

<out_var> = output variable name that for time-domain analyses can be:
V<node> = node potential (voltage, absolute velocity, pressure, displacement, etc);
I<name> = flow variable (current, force, torque, flow rate, heat flow, etc) through a two-terminal component;
U<name> = across variable (voltage, relative velocity, pressure drop, temperature differential, etc) across a two-terminal component;
P<name> = power dissipated by a two-terminal component;
<name> = value of any two-terminal component in the circuit (<name> is a full name of the component).
<alias> = alias name of the variable which can be used to substitute a full name in the plots or tables.
<np> = length of the plot in printer lines (100 lines is assigned by default).
If <np> is given with a negative sign all the specified variables are plotted in the same scale.
<arg> = argument name. Any variable can be distributed against X-axes.
By default, TIME for transient analysis (TR) and FREQ for frequency analysis (AC) is set.
<from> = lower argument value. By default, the directive CONST key parameters STPLOT (for TR) or LFREQ (for AC) are set.
<to> = upper argument value. By default, the directive CONST key parameters TMAX (for TR) or UFREQ (for AC) are set.

Examples:

PLOT UR1, V7.F2=NODE7POT;
PLOT IJFORCE, UGDEMP=LOADVEL (-50,10,100);
PLOT VSUPL.VALVE, IJFORCE(UCD);

The dependencies of the variable UR1 (voltage across resistor R1) and of the node 7 potential (node 7 voltage) of element F2 are set to be plotted in the first exemplified directive. The argument (TIME), its variation range (0 -TMAX), plot length (100), and the scaling mode (individual scaling for each variable) are all set by their default values. An alias name, NODE7POT, will appear in the plot instead of the basic name V7.F2.

The second directive specifies the plot with two curves (IJFORCE and LOADVEL) depicted in common scaling (minus sign before 50) along Y-axes. The variables are plotted against time by default and the time range from 10 to 100 is specified explicitly. The size of a plot along X-axes is set to be 50 printer lines.

The third PLOT directive illustrates how an argument of a plot can be specified explicitly. The variable VSUPL.VALVE (pressure supply) and force IJFORCE are set to be plotted against displacement UCD.

For frequency-domain analyses one or more transfer functions are to be defined by the directive TF (Transfer Function) which assigns the name of a particular transfer function and points out which variables are to be used to determine the function. Output results of the frequency-domain analysis are the frequency characteristics of these transfer functions. The type of a characteristic that is to be output in the plot <out_var> is specified by the keyword, which is written in front of the transfer function name and is delimited from it by a period ".". These keywords are:

RE = real component of the
    transfer function
IM = imaginary component
MA = amplitude modules
DB = amplitude in decibels
PH = phase angle in degrees
RAD = phase angle in radians

Any characteristic of the transfer function may be the argument of the plot.

Example:

PLOT RE.TF1, MA.TF1;
PLOT IM.K5(RE.K5);

The first directive sets two variables that are to be output. These are the real (RE.TF1) and imaginary (IM.TF1) parts of the transfer function TF1. The name TF1 is assumed to be specified in some TF directive in the task.

The second directive illustrates the case when the real part (RE.K5) of the transfer function K5 is decided to be distributed along X-axes.

Note: In the PLOT directive the range of argument variation must always be set along with the length of the plot.

For instance, in the directive

PLOT UR1 (20,200);

the TCL translator will find a syntax error, because 20 will be treated as the length of the plot and 200 - as the lower boundary of the argument variation range. The upper boundary in this case is undefined. To avoid an ambiguity, the length of the plot has to be specified explicitly in such a circumstances:

PLOT UR1 (100,20,200);

To set the plots in the task, the following directive CONST parameters can be used:

DIPLOT - storage interval for plots.
STPLOT - the point in time to start the results storage.

Three modifications of the directive PLOT are available. All of them have the same syntax as the main option. These modifications are:

LPLOT - the argument of the table is distributed along X-axes in logarithmic scale.
TPLOT - the coordinates of curves being plotted are printed .
LTPLOT - the coordinates of curves being plotted with logarithmic scaling along X-axes are printed.

Note: The task part may contain several PLOT directives or its modifications. The same variable can be output in different plots. But directives PLOT and LPLOT (so as TPLOT and LTPLOT) are incompatible in the same task.


Chapter 2

FIX. Output Characteristic Computation

The main objective of any analysis is to compute the performance values of the object to judge whether it meets the specification requirements or not. These indices are computed by processing the behavior of primary variables during time or frequency-domain analysis. That is why they are often referred to as secondary variables. In this manual they are mainly called output characteristics to distinguish them from output variables. Three directives are designed in ALLTED to determine output characteristics such as maximum or minimum value of a variable, value of the variable at the prescribed point in time, response time, overshoot, stability criterion, pulse duration, bandwidth, etc. These directives are FIX, INT, and FUNC.

The syntax of the directive FIX is:

FIX <fix_name>=<fix_func>(<arg>[,<par>[,<par>[,<par>]]]) {,<fix_name>=<fix_func>(<arg>[,<par>[,<par>[,<par>]]])};

where

<fix_name> = name of the output characteristic which can be any identifier. The name is used to specify the characteristic in printouts or to refer to the characteristic when it is used as argument in other directives.
<arg> = primary variable name that is to be processed by an intrinsic FIX function. For time-domain analyses it can be:
V<node> = node potential (voltage, absolute velocity, pressure, displacement, etc);
I<name> = flow variable (current, force, torque, flow rate, heat flow, etc) through a two-terminal component;
U<name> = across variable (voltage, relative velocity, pressure drop, temperature differential, etc) across a two-terminal component;
P<name> = power dissipated by a two-terminal component;
<par> = parameter value.
<fix_func> = name of the ALLTED intrinsic function used to compute the characteristic. Two types of functions are available. The first type functions are specified by names RISE, FALL, MAXF, MINF, MAXA, MINA, and FIXA. The second type function name is F1, F2, F3, etc.

For frequency-domain analysis primary variables are the names of frequency characteristics consisting of the name of transfer function and the identifier MA, DB, RE, IM, PH, or RAD.

The list of ALLTED FIX functions now available are described below.

Intrinsic FIX functions

Syntax | Determines
RISE(<arg>, <lev>) | TIME or FREQ when the variable <arg> intersects the level <lev> for the first time while increasing.
RISE(<arg>, <lev>, <Tb>, <Te>) | TIME or FREQ when the variable <arg> intersects the level <lev> in time or frequency interval from <Tb> to <Te> while increasing for the first time.
FALL(<arg>, <lev>) | TIME or FREQ when the variable <arg> intersects the level <lev> for the first time while decreasing.
FALL(<arg>, <Tb>, <Te>) | TIME or FREQ when the variable <arg> intersects the level <lev> for the first time while decreasing in the time/frequency interval from <Tb> to <Te>.
MINA(<arg>) | TIME or FREQ when <arg> reaches its minimum value.
MINA(<arg>, <lev>, <Tb>, <Te> | TIME or FREQ when <arg> reaches its minimum value in the time/frequency interval from <Tb> to <Te>.
MAXA(<arg>) | TIME or FREQ when <arg> reaches its maximum value.
MAXA(<arg>,<Tb>, <Te>) | TIME or FREQ when <arg> reaches its maximum value in the time/frequency interval from <Tb> to <Te>.
MINF(<arg>) | Minimum global value of the variable <arg>.
MINF(<arg>, <Tb>, <Te> | <arg> minimum value in the time/frequency interval from <Tb> to <Te>.
MAXF(<arg>) | Maximum global value of the variable <arg>.
MAXF(<arg>, <Tb>, <Te> | <arg> global maximum value in the time/ frequency interval from <Tb> to <Te>
FIXA(<arg>, <T>) | <arg> when time/frequency equal to <T>.

The name of the user-defined FIX functions consists of the symbol F and a number. The special module USFIX.FOR has been developed to introduce new functions.

In the table below readily available user-defined functions are listed. These functions are designed for time-domain analysis only.

<arg> = argument of the function. Any variable whose name starts with I, U, or P can be the argument of the function. Denoted as x in the right column,
<ts> = time at which an input signal is applied,
<te> = time at which the transient response is considered over,
<tmax> = time span set in the CONST directive,
<xss> = steady-state value of the variable x,
= time constant of the first order lag that the transient response brings a minimum to the criterion considered,
t = time.


Chapter 2

Syntax | Purpose
F1 (<arg>, <ts>, <te>, <xss>) | Integral quality criterion to estimate transient response of the variable x
F2 (<arg>, <ts>, <te>, <xss>) | Integral criterion for the quality of transient response estimation
F3 (<arg>, <ts>, <te>) | Integral of the variable <arg>
F4 (<arg>, <b>, <ts>, <te>) | Response time. The response time is determined as the time interval between the moment <ts> when an input signal is applied and the moment when an monitored variable x differs from its steady-state value not more then on <b> %. The value of x at <te> is taken as its steady-state value. 100 intermediate <arg> values from <ts> to <te> are stored during analysis to determine response time.
F5 (<arg>, <ts>, <xss>,< [image] >) | Integral criterion for transient response quality estimation
Five functions, namely F6, F7, F8, F9, and F10 are designed to determine frequency response characteristics during the time-domain analysis. To do this, the specified output variable is stored in a time series, starting at <ts> moment of time and ending at tmax. The number of elements in a time series is set to 2048. After the series is completed, it is processed with discrete Fourier transform to determine the specified characteristic. Note that if a pulse response is processed with Fourier Transform the output is a frequency response. The pulse response can be easily found if an output velocity is considered as the output variable with the step input. Below the purpose and the syntax are described. Any number of functions can be used in the task, but only the same variable can be used as the argument. Parameter <ts> must be the same in all of the functions.
F6 (<arg>, <ts>) | Function F6 determines the maximum amplitude of the frequency response related to the amplitude at zero frequency
F7 (<arg>, <ts>, <f>) | Function F7 determines the amplitude at frequency <f>. The amplitude is related to that of zero frequency
F8 (<arg>, <ts>, <f>) | Function F8 determines the phase angle in degrees at frequency <f>
F9 (<arg>, <ts>, <i>) | Determines the i-th peak of a linear spectrum. The peak is measured in absolute units. Up to 10 peaks can be evaluated. With i=0,the amplitude at zero frequency is determined
F10 (<arg>, <ts>, <i>) | Determines the frequency at which i-th peak of linear spectrum occurs. If <i> is set negative the number of harmonic will be used instead of frequency in cycles per unit time. Remember that harmonic frequency is determined as
F11(<arg>,<ts>,<te>) | Integral quality criterion
F12(<arg>,<ts>,<te>,<xss>) | Integral quality criterion
F13(<arg>,<ts>,<xss>, [image] ) | Integral quality criterion where xfol(t)= transient response coordinates of the first order lag, = time constant of the lag
F14 (<arg>,k,<ts>,<te>) | Overshoot evaluation of variable x. The variable x is stored in memory from <ts> to <te>. Then this array is processed to determine maximum value xmax and steady-state value xss at t = <te>. With K = 100 the overshoot is calculated in %.
F15 (<arg>,<ts>,<te>,<xss) | Integral quality criterion
F16(<arg>,<ts>,<xss>,< [image] >) | Integral quality criterion

Examples:
FIX T1 = FALL(UR1,0.5), T2 = RISE(UR1,0.5);
FIX M1 = MAXF(UR1), M2 = MINF(UR1);
FIX FREQ1 = MAXA(RE.TF1), FREQ2 = MINA(RE.TF1);

The first FIX directive computes an instant T1 of time when variable UR1 for the first time intersects the level of 0.5 while decreasing and an instant T2 of time when UR1 first intersects 0.5 while increasing.
In the second directive the maximum (M1) and minimum (M2) values of variable UR1 are found.
The third directive defines the frequency value, at which the real part of transfer function TF1 reaches its maximum (FREQ1) and minimum (FREQ2).
The task part may contain several FIX directives.


Chapter 2

INT, Interval Definition Directive

The INT directive computes a characteristic that is the difference between two characteristics defined by the FIX directive:

INT<int_name>=<fix_name>-<fix_name> {,<int_name>=<fix_name>-<fix_name>};

where

<int_name> = name of the characteristic computed in the directive. Any identifier can be used for this purpose.
<fix_name> = name of the characteristic computed in some FIX directive in the task.
The FIX and INT directives may be used to define such characteristics as response time, pulse duration, transparency bandwidth etc.

Example:
Suppose the duration of a pulse front edge of the variable UR1 is to be determined. Two FIX directive functions are used to compute a point in time when UR1 intersects the level of 0.4 (T1) while increasing (the beginning of the pulse) and characteristic T2 corresponding to the point in time when UR1 reaches the level 4.5 (the end of the front edge). The directive INT defines the difference of the fixed values and assigns the value to the characteristic FRONT:

FIX T1 = RISE(UR1,0.4), T2 = RISE(UR1,4.5);
INT FRONT = T2 - T1;

After the computation is completed the value of FRONT will be output to the file ALLTED.OUT.
One task part may contain several INT directives.

FUNC, Compute Complex Output Characteristic

The FUNC directive is designed to compute output characteristics that are the function of other output characteristics determined by FIX and INT directives and the values of elements and parameters of the object. Its syntax is:

FUNC <func_char>=<func_name>(<par>{,<par>}/<arg>{,<arg>}){,<func_char>= <func_name>(<par>{,<par>}/<arg>{,<arg>})};
where

<func_char> = name of output characteristic computed in the directive. The name is used to identify the characteristic in printouts and to refer to the characteristic when it is used as argument in objective functions, constraints, etc. Any identifier may be used as the name of the characteristic.
<func_name> = directive FUNC function name that is formed as F1, F2, ... The list of functions now available is described below.
<par> = function parameters that can be any numbers, satisfying the input language conventions.
<arg> = arguments of the function that can be:
- output characteristic determined by FIX and INT directives;
- any circuit component or parameter;
- transfer function characteristic: MA, DB, RE, IM, PH, RAD.

Function names <func_name>, their formats and descriptions are given in table below.

Syntax | Description
F1( a / x ) | z = a * x
F2( a1,a2/ x ) | z = a1*(a2-x)/x
F3( a / x ) | z = x/a
F4(a1,a2,a3, ... / x1,x2,x3,...) |
F5( a1/ x1, x2 ) | z = a * x1/x2
F6( a / x1,x2 | z= a1 * x1*x2
F7( a1 / x1 ) | z = a1 / x1
F8( a1,a2/x1) | z = a1 * x1 / a2
F9( a1/ x1, x2) | z = a1 / (x1 * x2)
F10(K/xmax, xss) | Overshoot evaluation. When xss = 0 When K=100, then in %
F11(density of liquid, number of pipes (N), density of pipe wall material / pipe 1 length, pipe 1 diameter, pipe 1 wall thickness,... pipe N length, pipe N diameter, pipe N wall thickness) | Pipelines weight
F12(liquid density, specific weight of the booster material, coefficient, booster material stress allowable, stroke, control valve weight(kgf), hydraulic loss coefficient/ pressure supply, effective area) | Airplane electrohydraulic steering booster weight. Weight of control valve is taken into account. Nonsymmetrical cylinder.
F13(density of liquid, number of pipes(N) / diameter1, pipe_length1, ..., diameterN, pipe_lengthN); | Weight of the liquid in the pipeline system
F14(body_mass/ body_velocity) | Kinetic energy of the body
F15(initial area / pressure supply, clearance, throttle diameter) | The rigidity of the working member placed between the cone throttles
F16(a0,a1,a2,a3, ... / x1,x2,x3, ...) |

Example:

FIX T = MINA(UC1);
FUNC F = F1(5/T);

In frequency domain the FUNC function can use characteristics of a transfer function as its arguments. The characteristics are determined at frequencies specified in the SWEEP directive (see 2.4.11). The desired characteristic value is referenced according to the relative number of the frequency value in the given list of frequencies:

SWEEP FREQ (5,10,100,1000);
TF K = UR1/UR2;
FUNC F = F1(0.5/RE.K(3));

Here the argument of function F1 is the real component of transfer function K, computed for frequency value 100 (the third value in the frequency list of the SWEEP directive). The number of the frequency value is specified in parenthesis after the description of the frequency response (after RE.K in question).

One task part may contain several FUNC directives.


Chapter 2

HISTO, Plot Statistical Data as Histogram

The results of statistical (Monte Carlo) analysis are output with the directive HISTO. The syntax of the directive is:

HISTO <control_char> [(<numb>[,<low_boundary>,<upper_boundary>])];

where

<control_char> = name of the output characteristic monitored during statistical analysis and set by the CONTROL directive(see Section 2.4.8)
<numb> = optional parameter to specify the number of intervals into which the range of monitored output characteristic is divided. 50 is assigned by default
<low_boundary> = lower boundary of the monitored characteristic to output in histogram. A minimum value of the characteristic is set by default.
<upper_boundary> = upper boundary of the characteristic to output. A maximum value is assigned by default.

Example:

HISTO RESPONSE (30, 0.007, 0.12);
HISTO BANDWIDTH;

SPECTR, Plot Linear Spectrum

The SPECTR directive is designed to output Fourier analysis results in a form of a spectrogram. The syntax of the directive is:

SPECTR <var>{=<alias>}{,<var>{=<alias>}}[(<low_boundary>,<upper_boundary>)];

where

<var> = name of the output variable linear spectrum or Fourier series coefficients which is set to plot.
<alias> = alias name of the output variable.
<low_boundary> and <upper_boundary> are optional parameters to set the boundaries of frequency range for all spectrograms mentioned in the directive. If boundaries are omitted the frequency range is determined by the directive CONST parameters UFREQ, LFREQ.

Example:
SPECTR UC1, IJ5.TL4.F5 = OUTPUT (2.6,28.6);

Two spectrograms will be plotted in the example both within 2.6 - 28.6 frequency range. The name of the output variable in the second histogram will be substituted with alias name OUTPUT.

TF, Define Transfer Function

The TF directive defines transfer functions as a ratio of two variables. The syntax of the directive is:

TF <tf_name>=<var>/<var>{,<tf_name>=<var>/<var>};

where

<tf_name> = name assigned to the transfer function. Any identifier may be used as the transfer function name.
<var> = name of the variable that is chosen to form the transfer function. The following variables can be used as the numerator and denominator of the transfer function:
I<name> = flow variable (current, flow rate, heat flow, force, etc) through any two-terminal component;
U<name> = across variable (voltage, relative velocity, relative displacement, pressure differential, etc) across any two-terminal component.
V<name> = node potential (node voltage, absolute velocity, pressure, etc).

Note: Node potential can only be used as a numerator of the transfer function.

Example:

TF KU = UROUT/UEIN, KI = IROUT/IRS
TF TRGAIN = UCD.AMP1.HT6/UEINPUT;

Transfer functions KU and KI are specified in the first directive. UROUT, UEIN, IROUT, IRS are all the variables of a main circuit. The ratio of the variable UCD.AMP1.HT6 to UEINPUT is decided to be the transfer function TRGAIN in accordance with the second directive.

VARPAR, Define Variable Parameters

The VARPAR directive specifies parameters the values of which are assigned to be variable in optimization process, tolerance assignment, multivariant, sensitivity, and worst case analyses; it also defines characteristics of the variable parameters. To simplify the description, the syntax of the directive is considered for each kind of analysis separately:

- Sensitivity analysis (SA):
VARPAR <var_par>{=<var_par>} {,<var_par>{=<var_par>}};

- Worst case design (WCD)
VARPAR <var_par>{=<var_par>}(tol){,<var_par>{=<var_par>}(tol)};

- Multivariant analysis (MVA)
VARPAR<var_par>(<law_boundary>,<upper_boundary>) {,<var_par>(<low_boundary>,<upper boundary>)};

- Optimal tolerance assignment
VARPAR <var_par>(<init_tol>) {,<var_par>(<init_tol>)};

- Optimization (OPTIM)
VARPAR <var_par> {=<var_par>} (<low_boundary>, <upper_boundary>
[,<list_number>]){,<var_par>{ = <var_par>}(<law_boundary>, <upper_boundary>[,<list_number>])};

where

<var_par> = full name of the variable parameter. Depending upon the type of analysis, it can be the name of a linear two-terminal component or name of any symbolic parameter.
<tol> = tolerance in percentage assigned to the variable parameter.
<law_boundary>, <upper_boundary>= lower and upper boundaries of the variable parameter variation range.
<init_tol> = initial tolerance value in percentage.
<list_numb> = number of list in the DISCOPT.EXE module.

Parameters or components whose names are grouped together in the directive VARPAR by an equality sign "=" are set to be varied synchronously. Mathematically, only one component will be inserted in the vector of variable parameters for all the items delimited by an equality sign "=".

Examples:

VARPAR RIN, ROUT, RBASE.T1;

Three parameters are stated in the directive as variable ones.

VARPAR R1=R2, RBASE1.T1=RBASE1.T2=RBASE.T3;

Five parameters in the directive will be combined into two groups and described by two components in the vector of variable parameters: the first one stands for R1 and R2, the second one, for another three parameters.

VARPAR R1(5), R2(5), R3.T4.FILT3(5), R8(10), R7(20);

Five variable parameters with their tolerances are stated in the directive.

VARPAR ALPHA.T1(0.04,0.16), LENGTH.MECH1(1.5,6.7),
EINP(6,9),GDEMP.SUSPEN4(0.2,0.85);

Lower and upper boundaries of each variable parameters are specified in the parenthesis.

VARPAR PIPEDIAM.P1(1.4,2.6,3),
PIPEDIAM.P2(1.4,2.6,3),
PIPERETD.P1(2.0,3.6,7), EPRSUP(180,210,0);

The third parameter in the parenthesis will force an optimization method to choose the value of the parameter only from the list of parameters stored in the module DISCOPT.EXE and specified by the number referred to by the parameter. No constraints are imposed (within variation range) on the variable parameter value if its list number is 0 (zero). All variable parameters have to be specified by three values in parenthesis for this kind of optimization.

If some variable parameters have the same value(s) in parenthesis, the directive may be written in a reduced form. The following lines are equivalent:

VARPAR R1,R2,R3(5), R8(10), R7(20);
VARPAR R1(5),R2(5),R3(5), R8(10), R7(20);
VARPAR RIN(3.0,9.5), R1=R2, TIMECON.SUM(1,2.2),
GAIN.QLAG(6,12);

Four groups of variable parameters are specified in the directive: the first group comprises component RIN, the second - R1 and R2, the third - TIMECON.SUM, and the fourth - GAIN.QLAG. The value of RIN can vary from 3 to 9.5, and that of R1, R2, TIMECON.SUM - from 0.01 to 0.22. The variation limits of parameter GAIN are constrained to 6 ... 12.

Several VARPAR directives may be used in the task.


Chapter 2

STAPAR, Define Statistically Variable Parameters

The STAPAR directive is designed to specify statistically variable parameters during statistical analysis and yield maximization (STA)

STAPAR<sta_par> {=<sta_par>} (<distrlaw_numb>, <low_boundary>, <upper_boundary>)
{,<sta_par>{=<sta_par>}(<distrlaw_numb>,<low_boundary>, <upper_boundary>)};

where

<sta_par> = full name of the variable parameter. It can be the name of a linear two-terminal component or the name of any symbolic parameter.
<distrlaw_numb> = number to specify the distribution law:
1 = uniform distribution;
2 = normal distribution;
3 = logarithmical normal distribution.
<low_boundary>, <upper_boundary>= lower and upper boundaries of the variable parameter variation range.

The directive STAPAR specifies synchronously varied parameters and groups of parameters with the same boundaries similar to VARPAR directive. Parameters or components whose names are grouped together in the directive STAPAR by an equal sign "=" are set to be varied synchronously.

Examples:

STAPAR RIN=ROUT, R1(1,0.5,1.0), GAIN.QLAG(2,6,12)

Three groups of statistically variable parameters are defined in this directive: the first includes components RIN and ROUT that are set to be varied synchronously; the second comprises component R1; and the third, symbolic parameter GAIN.QLAG. RIN, ROUT and R1 are set to be varied in the same range within 0.5 ... 1.0 in accordance with uniform distribution low, and GAIN.QLAG, in the range from 6 to 12 in accordance with normal distribution low.

Several STAPAR directives can be used in the task.

OF, Objective Function

The OF directive is designed to specify objective functions. The syntax of the directive is:

OF <of_name>=<of_func>(<par>{,<par>}/<arg>{,<arg>}){,<of_name>=<of_func>(<par>{,<par>}/<arg>{,<arg>})};

where

<of_name> = name of the objective function.
<of_func> = name of the intrinsic function to compute the value of the objective function.
The name starts with the key prefix "F", followed by an integer - the number of the intrinsic function.

<par> = numeric parameters for a particular intrinsic function.
<arg> = arguments.

The following quantities can be taken as arguments to compute objective function:
- linear two-terminal component;
- symbolic parameter;
- output characteristic defined by the FIX directive;
- output characteristic defined by the INT directive;
- output characteristic defined by FUNC directive;
- transfer function's characteristics;
- transfer function's characteristics with a specified frequency number of the SWEEP directive.

Example:

OF RESPONSE = F5(10./DURATION);

An output characteristic DURATION is computed by either FIX, INT, or FUNC directive. The function F5 takes DURATION as its argument and evaluates the value of objective function using a parameter value of 10. The result of the evaluation will be assigned to the objective function named RESPONSE.

Several directives OF can be used in the task.

The detailed description of the OF directive is given in Chapter 10.

LIMIT, Set Constraints

The LIMIT directive is intended to specify constraints during optimization. The syntax of the directive is:

LIMIT <constr_name>=<constr_func>(<par>{,<par>}/<arg>{,<arg>}){,<constr_name>=<constr_func>(<par>{,<par>}/<arg>{,<arg>})};

where:
<constr_name> = name of the constraint computed in the directive.
<constr_func> = name of the intrinsic function to compute the value of the constraint. The name starts with the key prefix of the intrinsic function. All the functions now available are listed in Section 6."F", followed by an integer - the number
<par> = numeric parameters for a particular intrinsic function.
<arg> = arguments.
The following quantities can be taken as arguments to compute a constraint:
- linear two-terminal component;
- symbolic parameter;
- output characteristic defined by the FIX directive;
- output characteristic defined by the INT directive;
- output characteristic defined by the FUNC directive;
- transfer function's characteristics;
- transfer function's characteristics with a specified frequency number of the SWEEP directive.

Example:

LIMIT ERROR = F251(0.03/DISTURB);

An output characteristic DISTURB is computed by either FIX, INT, or FUNC directive. The function F251 takes DISTURB as its argument and evaluates the value of the constraint using a parameter of value 10. The result of evaluation will be assigned to the name ERROR.
Several directives LIMIT can be used in the task.
The detailed description of the LIMIT directive is given in the Chapter10.

CONTROL, Set Controllable Characteristics

The CONTROL directive defines a set of monitored output characteristics and specifies their upper and lower boundaries during optimal tolerance assignment, statistical or multivariant analyses. Its syntax is:

CONTROL <control_name>[(<low_limit>,<up_limit>)]{,<control_name>[(<low_limit>,<up_limit>)]};

where
<control_name> = name of monitored output characteristic. It is one of the names computed by FIX, INT, or FUNC directives in the task.
<low_limit>, <up_limit> = lower and upper limits of the characteristic in percentage.

Example:

CONTROL STABILITY, ENERGY, DELAY;

Three output characteristics are assigned to be monitored during multivariant analysis. No limits are to be specified for this kind of analysis. All characteristics are computed in some FIX, INT, or FUNC directives in the task.

CONTROL BANDWIDTH(10,10), PEAK(8,8);

The feasible deviations for both characteristics are specified in the directive.
Several CONTROL directives can be used in a task.


Chapter 2

MODIFY, Values/Parameters

The MODIFY directive is designed to change the values of elements and/or parameters while multiple runs of the same object in either time or frequency domain is performed. The syntax of the directive is:

MODIFY <name>[(<par_numb>)]=<value>[%] {,<name>[(<par_numb>)]=<value>[%]};

where
<name> = name of the component/parameter whose value is to be modified. Any two-terminal component or symbolic parameter can be modified.
<par_numb> = number of the parameter in the nonlinear function description when some of the parameters in an operator such as

JK(1,0)=F537(0.006, 1.4, 0.8e-6, 10., -0.004 / UCD,UJK)
have to be modified. Parameter No.1 is 0.006, parameter No.2 is 1.4, etc.

<value> = modified value of the component/parameter.
A percentage sign "%" means that the modified value will be determined relative to the previous parameter value.

Example:

MODIFY R1=200, ALFA.M5=0.24, JE.T1(3)=90%;

Resistor R1 of the main circuit, symbolic parameter ALFA.M5 and the source JE in multi-terminals T1 are modified. New values of the first two parameters are specified to the right of the equal sign. A controlled source JE.T1 will be modified by changing its third parameter in the operator. The new value of the parameter will be computed as

new_value = previous_value x 90/100.

As far as a symbolic model is concerned, some components can be specified either by name or by value. For instance, if an element is described as

C2 (9,10) = PARCAP;
then it can be modified as

MODIFY C2.AMP = 8.E-4;
or

MODIFY PARCAP.AMP = 8.E-4;
The second way is preferable.

Several MODIFY directives can be used in a task.

INSTALL, Set Initial Conditions

The INSTALL directive is intended to specify initial values of the mathematical model variables. The syntax of the directive is:

INSTALL <var_name>=<value> {,<var_name>=<value>};
where
<var_name> = name of the mathematical model's variable.
<value> = value of the initial condition. By default, all initial conditions are set to be zero.

Example:

INSTALL V5=3, V2=6, IL1=0.5;

The node potential of node 5 will be assigned an initial value of 3, node potential of node 2 begins with 6 and variable IL1 will be assigned an initial value of 0.5.
To acquire the list of mathematical model variables, the mode OPTION 47 has to be set before the translator starts to analyze the description:

TASK;
OPTION 47;
&
OBJECT
<operators>

SWEEP Frequency Values

The SWEEP directive sets a list of frequencies at which an object status will be assessed during frequency analysis. Its syntax is:

SWEEP FREQ (<value> {,<value>});

Example:

SWEEP FREQ (5,10,100,1000);

Frequency analysis will be performed at four frequencies only.

CONST, Set Constants

The CONST directive sets the values of ALLTED program constants to adjust the system to object features and simulation modes. Its syntax is:

CONST <const_name>=<value> {,<const_name>=<value>};

The constant value, set by the CONST directive, is valid only for the current task. After the task is completed, the default value of the constant is restored. The list of constant names and their default values are described in relevant manual sections and grouped together in Appendix B.

Example:

CONST TMAX = 150, ORDER = 2;

Here TMAX and ORDER define the time span and the maximum order of the integration method.

OPTION, Set Run Mode

The OPTION directive is intended to set and cancel ALLTED run modes. Its syntax is:

OPTION <mode>{,<mode>};

where

<mode> = integer denoting one of the ALLTED modes:
47 - information about an object mathematical model, vector of unknown variables, nonzero matrix structure, etc. will be output into ALLTED.OUT file;
48 - statistics about numerical integration, optimization, or other kind of analysis involved will be output.
The mode setting is valid till the end of the simulation session.

Note: Optional mode 47 must be set in a task part prior to the object description; it must be at the very beginning of the input file.

Example:

TASK
OPTION 47,48; # Information about mathematical model and computational statistics are requested
&

SAVE

The SAVE directive saves data and programs after the current task is completed. With the saved information the directive MODIFY can be used next.

The SAVE directive has no parameters and is written in the form:

SAVE;

PPROC, Set Postprocessor

The PPROC directive sets the ALLTED postprocessor. The Postprocesssor must be set before the ALLTED compiler starts to analize a description. That's why the task with the directive PPROC must precede the description.

The SAVE directive has no parameters and is written in the form:

TASK
PPROC; # ALLTED Postprocessor is set
&
OBJECT
<Description operators>


Chapter 3

Semiconductors and Nonlinear Elements

A set of models for semiconductors widely used in most circuit simulators is considered in the chapter. These models are incorporated in ALLTED too. These basic, frequently-used nonlinear functions for electronic circuit design allow a user to cover a very wide range in accuracy and complexity.

The accuracy of the analysis largely depends on the level of extent and accuracy of active components models. There are many semiconductor device models that are used for computer-aided design. The principal differences between them are based on the initial assumptions and amount of the physical effects that are taken into account.

The question of choosing the model is often solved by trading the accuracy for the speed of computation. Unnecessarily complex models could cause convergence problems and take a great deal of computation. Conversely, the oversimplified models may lead to wrong results.

A wide spectrum of models is available in ALLTED to build an optimal model in each particular case. At the same time, special means were developed to extend a function library (see Section 10 in Master Manual) if ALLTED lacks some function.

The chapter concludes with some practical examples showing how to use these functions for electronic circuit simulation.

FCAP Function. Temperature-dependent Voltage-controlled Capacitor

FCAP function is used to define a temperature-dependent voltage-controlled capacitor.

General form
<Cname>(<+node>,<-node>)=FCAP(<Cnom>,<C>,<VC1>,<VC2>,<TC1>,<TC2>/UC<name>);

Cnom = capacitor value [Farad]
C = capacitance multiplier
VC1 = linear voltage coefficient [volt-1]
VC2 = quadratic voltage coefficient [volt-2]
TC1 = linear temperature coefficient [oC-1]
TC2 = quadratic temperature coefficient [oC-2]
UC<name> = voltage across capacitor

Capacitance value is evaluated by the following formula

where
U = voltage across capacitor.
Tnom is the nominal temperature which equals 300oK.

Example:
Cin(1,2) = FCAP(10.p, 1, 0, 1, 2, 0/UCin);

Diode model

General form

<Dname>(<+node>,<-node>) =<list_name>.D[(<substitution_list>)];

where D in the right hand is the name of intrinsic ALLTED diode model. The diode model has structure shown in Fig. 3.1 and is defined with the ALLTED input language as following:

MODEL D(P,N);
JD(PIN,N)=FD1(IS,RS,N,TT,CJO,VJ,M,EG,XTI,FC,BV,IBV,AREA,OFF/UJD);
RD(P,PIN)=FD2(/IRD);

Model parameter |  | Units | Default
IS | Saturation current | [amp] | 1.E-14
RS | Parasitic resistance | [ohm] | 0
N | Emission coefficient |  | 1
TT | Transit time | [sec] | 0
CJO | zero-bias p-n capacitance | [farad] | 0
VJ | p-n potential | [volt] | 1
M | p-n grading coefficient |  | 0.5
EG | Bandgap voltage (barrier height) | [eV] | 1.11
XTI | IS temperature exponent |  | 3
FC | Forward-bias depletion capacitance coefficient |  | 0.5
BV | Reverse breakdown "knee" voltage | [volt] | infinite
IBV | Reverse breakdown "knee" current | [amp] | 1E-10
AREA | scale factor for IS,RS,CJO,IBV |  | 1
OFF | "ON"/"OFF" sign for initial point in DC analysis |  | 0("ON")

The description of the model (name "D") and list of default parameters (name "DEF.D") are stored in the ALLTED library.


Chapter 3

The following nomenclature are used in the equations describing the diode model:

Fig.3.1.Diode model.

Vd = voltage across the intrinsic current
    source
Vt = kT/q (thermal voltage)
K = Boltzman's constant
q = electron charge
T = analysis temperature (oK)
Tnom = nominal temperature (300oK)

Other variables coincide with the names in the parameter list.

The diode is described by the following equations:

DC Current

/forward current/
/reverse (breakdown) current/

Capacitance

Ct = TT·Gd /transit time capacitance/
/DC conductance/
Cj =: /junction capacitance/

Temperature effects

/silicon bandgap energy/

RS has no temperature dependence.

References

A detailed discussion of p-n junction physics is given in [1] P. Antognetti and G. Massobrio, Semiconductor Device Modeling with SPICE, McGraw-Hill, 1988.

JFET (Junction Field Effect Transistor)

General form

- n - channel transistor
<Fname>(<drain node>,<gate node>,<source node>)=<listname>.NJF[(<substitution list>)];

- p - channel transistor
<Fname>(<drain node>,<gate node>,<source node>)=<listname>.PJF[(<substitution list>)];

where NJF and PJF in the right hand are names of intrinsic ALLTED JFET models for n-channel and p-channel transistors. Model structure for n-channel case is shown in Fig. 3.2. A current is considered to be positive if it flows into a terminal. The NJF model is defined as following:

MODEL NJF (D,G,S);
JDRAJN(DIN,SIN)=FJF1(VTO,BETA,LAMBDA,RD,RS,CGS,CGD,PB,IS,FC,AREA,OFF/UJGS,UJGD,UJDRAJN);
JGS(G,SIN)=FJF2(/UJGS);
JGD(G,DIN)=FJF3(/UJGD);
RSOURC(S,SIN)=RS;
RDRAIN(D,DIN)=RD;

Model parameter | Meaning | Units | Default
VTO | Threshold voltage | [volt] | -0.2
BETA | Transconductance coefficient | [amp/volt2] | 3.E-4
LAMBDA | Channel-length modulation | [volt-1] | 0
RD | Drain ohmic resistance | [ohm] | 0
RS | Source ohmic resistance | [ohm] | 0
CGS | Zero-bias gate-source p-n capacitance | [farad] | 0
CGD | Zero-bias gate-drain p-n capacitance | [farad] | 0
PB | Gate p-n potential | [volt] | 1.0
IS | Gate p-n saturation current | [amp] | 1.E-14
FC | Forward bias depletion capacitance coefficient |  | 0.5
AREA | Relative device area |  | 1
OFF | "ON"/"OFF" sign for initial point in DC analysis |  | 0("ON")


Chapter 3

Both the model description (names "NJF" and "PJF") and list of default parameters (names "DEF.NJF" and "DEF.PJF") are stored in the ALLTED library.

Fig.3.2.JFET model.

The following equations describe the n-channel JFET. For p-channel devices, reverse the sign of all voltages and currents.

Igs = AREA·IS·(eUgs/Vt-1) /gate-source leakage current/
Igd = AREA·IS·(eUgd/Vt-1) /gate-drain leakage current/
Idrain =:for Uds >= 0 /normal mode/
and Ugs - VTO < 0 /cutoff region/ Idrain = 0
and Uds < Ugs - VTO /linear region/
Idrain = BETA·(1+LAMBDA·Uds)·Uds·(2·(Ugs-VTO)-Uds)
and 0 <= Ugs - VTO <= Uds /saturation region/
Idrain = BETA·(1+LAMBDA·Uds)·(Ugs-VTO)2
for Uds < 0 /inverted mode/

Switch the source and drain in equations (above)

Capacitance

Cgs =: /gate-source depletion capacitance/
for Ugs <= FC·PB
Cgs = AREA·CGS·(1-Ugs/PB)-M
for Ugs < FC·PB
Cgs = AREA·CGS(1-FC)-(1+M)(1-FC·(1+M)+M·Ugs/PB)

where M=0.5

Cgs =: /gate-drain depletion capacitance/
for Ugd <= FC·PB
Cgd = AREA·CGS·(1-Ugd/PB)-M
for Ugd > FC·PB
Cgd = AREA·CGD·(1-FC)-(1+M)·(1-FC·(1+M)+M·Ugd/PB)

where M=0.5

Temperature effects

PB(T)=PB·T/Tnom-3·VTln(T/Tnom)+Eg(Tnom)·T/Tnom+Eg(T)
Eg(T)=1.16-0.000702·T2/(T+1108) /silicon bandgap energy/
CGS(T)=CGS·(1+M·(0.0004·(T-Tnom)+1-PB(T)/PB))
CGD(T)=CGD·(1+M·(0.0004·(T-Tnom)+1-PB(T)/PB))
M=0.5

where

UGS = intrinsic gate-intrinsic source voltage
UGD = intrinsic gate-intrinsic drain voltage
UDS = intrinsic drain-intrinsic source voltage
Vt = kT/q (thermal voltage)
Tnom = nominal temperature (300oK)
q = electron charge
k = Boltzman's constant

To set the temperature, the key parameter TEMP is designed in the directive CONST

CONST TEMP = <value>;

The default value for the parameter TEMP is set to be 27oC. The drain and source ohmic resistances have no temperature dependence.

FIND function. Temperature-dependent Current-controlled Inductor

FIND function is used to define a temperature-dependent current-controlled inductor.

General form

<Lname>(<+node>,<-node>=FIND(<Lnom>,<L>,<IL1>,<IL2>,<TC1>,<TC>/IL<name>);

Lnom = inductor value [Henry]
L = inductance multiplier
IL1 = linear voltage coefficient [amp-1]
IL2 = quadratic current coefficient [amp-2]
TC1 = linear temperature coefficient [oC-1]
TC2 = quadratic temperature coefficient [oC-2]
Inductance value is evaluated by the formula

where I is a current through the inductor. Tnom is the nominal temperature 300oK.

Example
L1(2,3)=FIND(10.u,1,0,1,0.5,0.8/IL1);

FMUT Function. Coupled Inductors

The function is developed to define coupled inductors.

General form

<Lname>(<+node>,<-node>)=FMUT(<Lnom>,<M1>,...,<Mn>/IL<name>,<IL1>,...,ILn);

Lnom = value of <Lname>inductor [Henry]
Mi = mutual inductance between <Lname> and Li [Henry]
IL<name> = current through <Lname> inductor
ILi = current through i-th coupled inductor
I = 1,...,n.
The linear relation for transient analysis is taken as

The current through <Lname> must be in the opposite direction as the current through Li. The polarity is determined by the order of the nodes in the L devices.
To establish coupling between the Li and Lj inductors, the following operators should be inserted in the description:
Li<name>(<+inode>,<-inode>)=FMUT(<Li>,Mij/ILi<name>,ILj<name>);
Lj<name>(<+jnode>,<-jnode>)=FMUT(<Lj>,Mij/ILj<name>,ILi<name>);

where <Li>,<Lj> are the value of coupled inductors.
The order of operators is optional. The value of a mutual inductance is defined as:

where <Coupling value> is the "coefficient of mutual coupling" which must be between 0 and 1.

Example

J1(1,0)=1.m;
L1(1,0)=FMUT(10.u,9.999u/IL1,IL2);
L2(2,0)=FMUT(10.u,9.999u/IL2,IL1);
R2(2,0)=0.1;


Chapter 3

MOSFET (Metal Oxide Semiconductor FET)

Shichman-Hodges model

General form

<Mname>(<drain_node>,<gate_node>,<source_node>,<bulk_node>)=<list_name>.MOST[(<substitution_list>)];

where MOST in the right hand part of the operator is the name of the intrinsic ALLTED MOSFET model for n-channel and p-channel transistors. The model for n-channel case transistor is shown in Fig. 3.3(a). The MOSFET is simulated as an intrinsic MOSFET device with ohmic resistances in series with the drain, source, gate and bulk (substrate). Current source JD defines I-V characteristic. Other model components are parasitic. They affect the dynamic characteristic of the device. Current is considered to be positive if it flows into a terminal.

MOST model in the ALLTED input language is defined as following

MODEL MOST (D,G,S,B);
Rd(D,Din)=RD;
Rs(S,Sin)=RS;
Rg(G,Gin)=RG;
Rb(B,Bin)=RB;
Rds(Din,Sin)=RDS;
Jdrain(Din,Sin)=Fmos1(TYPE, L, W,
TOX, VTO, PHI, KP,LAMBDA, GAMMA,TPG,IS, JS, JSSW, NSUB, UO, LD,
WD,AD, AS, PD, PS, CBD, CBS, CJ, MJ, PB, CJSW, MJSW,PBSW, CGDO,
CGSO, CGBO, TT, FC, OFF/ UJdrain, UJCgs, UJCbs);
JCbs(Bin,Sin)=Fmos2(/UJCbs);
JCbd(Bin,Din)=Fmos3(/UJCbd);
JCgs(Gin,Sin)=Fmos4(/UJCgs);
JCgd(Gin,Din)=Fmos5(/UJCgd);
JCgb(Gin,Bin)=Fmos6(/UJCgb);

Model parameter | Meaning | Units | Default
TYPE | type of transistor |  | 1-n-ch., -1-p-ch.
W | channel width | [micrometer] | 100
L | channel length | [micrometer] | 100
AD | drain diffusion area | [meter2] | 0
AS | source diffusion area | [meter2] | 0
PD | drain diffusion perimeter | [meter] | 0
PS | source diffusion perimeter | [meter] | 0
KP | Transconductance coefficient | [amp/volt2] | 2E-5
LAMBDA | channel-length modulation | [volt-1] | 0
VT0 | zero-bias threshold voltage | [volt] | 1
GAMMA | bulk threshold parameter | [volt1/2] | 0
PHI | surface potential | [volt] | 0.6
TOX | oxide thickness | [meter] | 1E-7
IS | bulk p-n saturation current | [amp] | 1E-14
JS | bulk p-n saturation current/area | [amp/meter2] | 1E-8
JSSW | bulk p-n saturation sidewall current/length | [amp/meter] | 0
CJ | bulk p-n zero-bias bottom capacitance/area | [farad/meter2] | 2E-4
CJSW | bulk p-n zero-bias sidewall capacitance/length | [farad/meter] | 1E-9
TT | bulk p-n transit time | [sec] | 0
PB | bulk p-n bottom potential | [volt] | 0.8
PBSW | bulk p-n sidewall potential | [volt] | 0.8
FC | bulk p-n forward-bias capacitance coefficient |  | 0.5
MJ | bulk p-n bottom qrading coefficient |  | 0.5
MJSW | bulk p-n sidewall qrading coefficient |  | 0.33
LD | lateral diffusion (length) | [meter] | 0
CGDO | gate-drain overlap capacitance/channel width | [farad/meter] | 4E-11
CGSO | gate-source overlap capacitance/channel width | [farad/meter] | 4E-11
CGBO | gate-bulk overlap capacitance/channel width | [farad/meter] | 2E-10
CBS | bulk-source zero-bias p-n capacitance | [farad] | 0
CBD | bulk-drain zero-bias p-n capacitance | [farad] | 0
TPG | gate material type |  | 1
NSUB | Substrate doping density | [1/cm3] | 0
UO | (u-oh, not u-zero) surface mobility | [cm2/vol*sec] | 600
WD | lateral diffusion (width) | [meter] | 0
RD | drain ohmic resistance | [ohm] | 1
RS | source ohmic resistance | [ohm] | 1
RG | gate ohmic resistance | [ohm] | 0
RB | bulk ohmic resistance | [ohm] | 0
RDS | drain-source shunt resistance | [ohm] | 1.T
OFF | Function mode |  | 0

DC characteristics of the MOSFET model are defined by the parameters VT0, KP, LAMBDA, PHI, and GAMMA.


Chapter 3

Both model description ("MOST") and lists of default parameters ("nDEF.MOST" and "pDEF.MOST" for n- and p-channel transistors respectively) are stored in the ALLTED library.

The equations below describe the n-channel MOSFET. For p-channel devices, reverse the signs of all voltages and currents.
Positive current is current flowing into a terminal (for example, positive drain current flows from the drain through the channel to the source).

Fig. 3.3(a). Shichman-Hodges MOSFET model (level 1)

DC Currents

Equations for JD:
For: Vds >= 0 /normal mode/and: Vgs - Vto < 0 /cutoff region/JD = 0 and: Vds < Vgs - Vto /linear region/
JD = (W/L)·(KP/2)·(1 + LAMBDA·Vds)·Vds·(2·(Vgs-Vto)-Vds) and: 0 <= Vgs - Vto <= Vds /saturation region/
JD = (W/L)·(KP/2)·(1 + LAMBDA·Vds)·(Vgs - Vto)2

where Vto = VT0 + GAMMA·( sqrt(PHI - Vbs) - sqrt(PHI))
For: Vds < 0 /inverted mode/

Switch the source and drain in equations (above).

Equations for JJBS, JJBD:

JJBS = Iss · (exp(Vbs/(N·Vt)) - 1) /bulk-source leakage current/
JJBD = Ids · (exp(Vbd/(N·Vt)) - 1) /bulk-drain leakage current/

where

if: JS = 0, or AS = 0, or AD = 0
Iss = IS
Ids = IS

otherwise:

Iss = AS·JS + PS·JSSW
Ids = AD·JS + PD·JSSW
N - bulk p-n emission coefficient (N = 1).

Capacitance

Note: All capacitances are between terminals of the intrinsic MOSFET. That is, to the inside of the ohmic drain and source resistances.

CBS = area cap.+sidewall cap.+transit time cap. /bulk-source capacitance/
CBD = area cap.+sidewall cap.+transit time cap. /bulk-drain capacitance/
For: CBS = 0 and CBD = 0
Cbs = AS·CJ·Cbsj + PS·CJSW·Cbss + TT·Gbs
Cbd = AD·CJ·Cbdj + PD·CJSW·Cbds + TT·Gbd

where

Gbs = dJBS/dVbs /DC bulk-source conductance/
Gbd = dJBD/dVbs /DC bulk-drain conductance/
For: Vbs <= FC·PB
Cbsj = (1-Vbs/PB)(-MJ)
Cbss = (1-Vbs/PBSW)(-MJSW)
For: Vbs > FC·PB
Cbsj = (1-FC)(-1-MJ)·(1-FC·(1+MJ)+MJ·Vbs/PB)
Cbss = (1-FC)(-1-MJSW)·(1-FC·(1+MJSW)+MJ·Vbs/PBSW)
For: Vbd <= FC·PB
Cbdj = (1-Vbd/PB)(-MJ)
Cbds = (1-Vbd/PBSW)(-MJSW)
For: Vbd > FC·PB
Cbdj = (1-FC)(-1-MJ)·(1-FC·(1+MJ)+MJ·Vbd/PB)
Cbds = (1-FC)(-1-MJSW)·(1-FC·(1+MJSW)+MJ·Vbd/PBSW)

There are two levels for Cgs, Cgd, Cgb models.

For level 1:

Cgs= CGSO · W /gate-source overlap capacitance/
Cgd= CGDO · W /gate-drain overlap capacitance/
Cgb= CGBO · L /gate-bulk overlap capacitance/

For level 2: see reference [1] for the nonlinear equations
describing the capacitances due to the channel charge.

Temperature Effects

IS(T) = IS·exp(Eg(Tnom)·T/Tnom - Eg(T))/VT
JS(T) = JS·exp(Eg(Tnom)·T/Tnom - Eg(T))/VT
JSSW(T) = JSSW·exp(Eg(Tnom)·T/Tnom - Eg(T))/VT
PB(T) = PB·T/Tnom - 3·Vt·ln(T/Tnom)-Eg(Tnom)·T/Tnom + Eg(T)
PBSW(T) = PBSW·T/Tnom - 3·Vt·ln(T/Tnom)-Eg(Tnom)·T/Tnom + Eg(T)
PHI(T) = PHI·T/Tnom - 3·Vt·ln(T/Tnom)-Eg(Tnom)·T/Tnom + Eg(T)

where

Eg(T) = 1.16 - .000702·T·T/(T+1108) /silicon bandgap energy/
CBD(T) = CBD·(1+MJ·(.0004·(T-Tnom) + (1-PB(T)/PB)))
CBS(T) = CBS·(1+MJ·(.0004·(T-Tnom) + (1-PB(T)/PB)))
CJ(T) = CJ·(1+MJ·(.0004·(T-Tnom) + (1-PB(T)/PB)))
CJSW(T) = CJSW·(1+MJSW·(.0004·(T-Tnom) + (1-PB(T)/PB)))
KP(T) = KP·(T/Tnom)(-3/2)
UO(T) = UO·(T/Tnom)(-3/2)

where

Vgs = intrinsic gate-intrinsic source voltage
Vgd = intrinsic gate-intrinsic drain voltage
Vds = intrinsic drain-intrinsic source voltage
Vbs = intrinsic substrate-intrinsic source voltage
Vbd = intrinsic substrate-intrinsic drain voltage
Vt = kT/q (thermal voltage)
k = Boltzmann's constant
q = electron charge
T = analysis temperature (oK)
Tnom = nominal temperature (300oK)
Other variables coincide with the names specified in the
parameter list.
The temperature in the analysis is defined by the parameter
TEMP in the directive CONST

CONST TEMP = <value>;

Default value for TEMP is 27oC.
The ohmic (parasitic) resistances have no temperature
dependence.

References

For a more complete description of MOSFET models, see:
Antognetti and G. Massobrio, Semiconductor Device Modeling with SPICE, McGraw-Hill, 1988.


Chapter 3

BSIM model

General form

<Mname>(<drain_node>,<gate_node>,<source_node>,<bulk_node>)=<list_name>.BSIM[(<substitution_list>)];

where BSIM in the right hand part of the operator is the name of the intrinsic ALLTED MOSFET model (Berkly Short-channel IGFET Model) for n-channel and p-channel transistors. The model for n-channel case transistor is shown in Fig. 3.3(b).

BSIM model in the ALLTED input language is defined as following

MODEL BSIM (D,G,S,B);
Rd(D,Din)=RSH;
Rs(S,Sin)=RSH;
Jdrain(Din,Sin)=F281(TYPE, L, W, Wmult, TOX,
VFB, PHI, K1, K2, ETA, X2E, X3E, MUZ, X2MZ, UO, X2UO, U1, X2U1, X3U1, MUS,
X2MS, X3MS, N0, NB, ND, VDD, XPART, DL, DW, CJ, MJ, PB, CJSW, MJSW, PBSW,
CGDO, CGSO, CGBO, FC / UJdrain, UJCgs, UJCbs);
JCbs(Bin,Sin)=F282(/UJCbs);
JCbd(Bin,Din)=F283(/UJCbd);
JCgs(Gin,Sin)=F284(/UJCgs);
JCgd(Gin,Din)=F285(/UJCgd);
JCgb(Gin,Bin)=F286(/UJCgb);

Model parameter | Meaning | Units | Default
 |  |  | n-channel | p-channel
TYPE | type of transistor |  | 1 | -1
L | channel width | [micrometer] | 2 | 5
W | channel length | [micrometer] | 18 | 18
DL | channel length diminution | [micrometer] | 8.04021E-1 | 5.65022E-1
DW | channel width diminution | [micrometer] | -4.3493E-1 | -4.8688E-1
PHI* | surface potential | [volt] | 0.75428 | 0.666766
TOX | oxide thickness | [micrometer] | 3.65E-2 | 3.65E-2
CJ | bulk p-n zero-bias bottom capacitance/area | [farad/meter2] | 3.774E-4 | 2.2524E-4
CJSW | bulk p-n zero-bias sidewall capacitance/length | [farad/meter] | 5.136E-10 | 2.3825E-10
PB | bulk p-n bottom potential | [volt] | 0.8 | 0.7
PBSW | bulk p-n sidewall potential | [volt] | 0.8 | 0.7
FC | bulk p-n forward-bias capacitance coefficient |  | 0.5 | 0.5
MJ | bulk p-n bottom grading coefficient |  | 0.4589 | 0.4665
MJSW | bulk p-n sidewall grading coefficient |  | 0.3662 | 0.2466
CGDO | gate-drain overlap capacitance/channel width | [farad/meter] | 5.70493E-10 | 4.00911E-10
CGSO | gate-source overlap capacitance/channel width | [farad/meter] | 5.70493E-10 | 4.00911E-10
CGBO | gate-bulk overlap capacitance/channel width | [farad/meter] | 5.66386E-10 | 5.53317E-10
UO* | (u-oh, not u-zero) surface mobility | [cm2/volt*sec] | 5.19694E-2 | 1.28427E-1
VFB* | flat band voltage | [volt] | -0.75862 | -0.3132
RSH | specific resistance | [ohm/mkm2] | 0.2273 | 0.8692
K1* | bulk influence factor | [volt1/2] | 0.971787 | 0.561236
K2* | depletion region separation factor |  | 4.59847E-3 | 2.2501E-2
ETA* | drain-induced potential barrier fall |  | -4.7274E-3 | -1.202E-2
X2E* | ETA sensitivity on Vbs changing | [volt-1] | -9.6755E-5 | -1.4031E-3
X3E* | ETA sensitivity on Vds-Vdd changing | [volt-1] | 4.349E-4 | 7.88399E-4
MUZ* | zero-bias mobility | [cm2/volt*sec] | 5.59946E2 | 2.15601E2
X2MZ* | MUZ sensitivity on Vbs changing | [cm2/volt2*sec] | 12.7018 | 8.90424
X2UO* | UO sensitivity on Vbs changing | [volt-2] | 2.10646E-3 | 6.24794E-3
U1* | drift velocity satiation factor | [mkm/volt] | 2.71167E-2 | 1.04033E-2
X2U1* | U1 sensitivity on Vbs changing | [mkm/volt2] | -3.7373E-3 | -1.0724E-3
X3U1* | U1 sensitivity on Vds-Vdd changing | [mkm/volt2] | 4.93859E-3 | -1.7457E-2
MUS* | bulk zero-bias mobility at Vds=Vdd | [cm2/volt*sec] | 565.144 | 236.386
X2MS* | MUS sensitivity on Vbs changing | [cm2/volt2*sec] | 4.83491 | 8.31455
X3MS* | MUS sensitivity on Vds-Vdd changing | [cm2/volt2*sec] | -1.3896 | -1.0472
N0* | under-threshold region steepness |  | 1.5 | 1.5
NB* | N0 sensitivity on Vbs changing |  | 0 | 0
ND* | N0 sensitivity on Vds changing |  | 0 | 0
VDD | supply voltage | [volt] | 5 | 5
Wmult | multiplicity factor |  | 1 | 1
Besides the parameters listed in the table, the parameters, which specify sensitivity of each parameter marked in the table by (*) sign to the change of channel length DL and width DW, could be in the list of BSIM model parameters. An abbreviation of such parameters is forming by addition DL or DW letters respectively from the left of the parameters’ name, for instance, DLK1 or DWK2.
Both model description ("BSIM") and lists of default parameters ("NTR.BSIM" and "PTR.BSIM" for n- and p-channel transistors respectively) are stored in the ALLTED library.
The equations below describe the n-channel MOSFET. For p-channel devices, reverse the signs of all voltages and currents.
Positive current is current flowing into a terminal (for example, positive drain current flows from the drain through the channel to the source).

Fig. 3.3(b). BSIM MOSFET model (level 4)

DC Currents

Equations for JD:

For: Vds >= 0 /normal mode/

where

( [image])
( [image])
( [image])

if [image] /cutoff region/

if [image] and [image] /linear region/
,
where

if [image] and [image] /saturation region/
,
where

For: Vds < 0 /inverted mode/
Switch the source and drain in equations (above).

Capacitance

Note: All capacitances are between terminals of the intrinsic MOSFET. That is, to the inside of the ohmic drain and source resistances.

CBS = area cap.+sidewall cap. /bulk-source capacitance/
CBD = area cap.+sidewall cap. /bulk-drain capacitance/
Cbs = AS·CJ·Cbsj + PS·CJSW·Cbss
Cbd = AD·CJ·Cbdj + PD·CJSW·Cbds
For: Vbs <= FC·PB
Cbsj = (1-Vbs/PB)(-MJ)
Cbss = (1-Vbs/PBSW)(-MJSW)
For: Vbs > FC·PB
Cbsj = (1-FC)(-1-MJ)·(1-FC·(1+MJ)+MJ·Vbs/PB)
Cbss = (1-FC)(-1-MJSW)·(1-FC·(1+MJSW)+MJSW·Vbs/PBSW)
For: Vbd <= FC·PB
Cbdj = (1-Vbd/PB)(-MJ)
Cbds = (1-Vbd/PBSW)(-MJSW)
For: Vbd > FC·PB
Cbdj = (1-FC)(-1-MJ)·(1-FC·(1+MJ)+MJ·Vbd/PB)
Cbds = (1-FC)(-1-MJSW)·(1-FC·(1+MJSW)+MJSW·Vbd/PBSW)
Cgs = CGSO · W /gate-source overlap capacitance/
Cgd = CGDO · W /gate-drain overlap capacitance/
Cgb = CGBO · L /gate-bulk overlap capacitance/

where
Vgs = intrinsic gate-intrinsic source voltage
Vgd = intrinsic gate-intrinsic drain voltage
Vds = intrinsic drain-intrinsic source voltage
Vbs = intrinsic substrate-intrinsic source voltage
Vbd = intrinsic substrate-intrinsic drain voltage
Vto = threshold voltage
Vsat = saturation voltage
k = Boltzmann's constant
q = electron charge
T = analysis temperature (oK)
Other variables coincide with the names specified in the parameter
list.


Chapter 3

BJT (Bipolar Junction Transistor)

General forms

NPN transistor
<Qname>(<collectornode>,<basenode>,<emitternode>,<substratenode>)=<list_node>.NPN[(<substitution_list>)];

-PNP transistor
<Qname>(<collectornode>,<basenode>,<emitternode>,<substratenode>)=<list_node>.PNP[(<substitution_list>)];

-LPNP transistor
<Qname>(<collectornode>,<basenode>,<emitternode>,<substratenode>)=<list_node>.LPNP[(<substitution_list>)];

where NPN, PNP, LPNP in the right hand part of the operator are the names of intrinsic ALLTED BJT models for NPN, PNP and lateral PNP transistor. The structure of BJT model for NPN transistor is shown in Fig. 3.4. The current is considered to be positive if it flows into a terminal. NPN model is defined in the ALLTED input language as following:

MODEL NPN (C,B,E,S);
JCE(Cin,Ein)=FBJT1(IS,BF,NF,VAF,IKT,ISE,NE,RB,NR,VAR,IKR,ISC,NC,RB,IRB,RBM,RE,RC,CJE,VJE,MJE,TF,XTF,VTF,ITF,PTF,
CJC,VJC,MJC,XCJC,TR,CJS,VJS,MJS,XTB,EG,XTI,FC,AREA,OFF/UJBE,UJBC);
JVE(Bin,Ein)=FBJT2(/UJBE,UJBC);
JBC(Bin,Cin)=FBJT3(/UJBC);
RBB(B,Bin)=FBJT4(/IRBB);
JCBX(B,Cin)=FBJT5(/UJCBX);
JCJS(S,Cin)=FBJT6(/UJCJS);
REM(E,Ein)=RE;
RCOL(C,Cin)=RC;

Model parameter | Meaning | Units | Default
IS | transport saturation current | [amp] | 1E-16
BF | ideal maximum forward beta |  | 100
NF | forward current emission coefficient |  | 1
VAF | forward Early voltage | [volt] | infinite
IKF | corner for forward beta high-current roll-off | [amp] | infinite
ISE | base-emitter leakage saturation current | [amp] | 0
NE | base-emitter leakage emission coefficient |  | 1.5
BR | ideal maximum reverse beta |  | 1
NR | reverse current emission coefficient |  | 1
VAR | reverse Early voltage | [volt] | infinite
IKR | corner for reverse beta high-current roll-off | [amp] | infinite
ISC | base-collector leakage saturation current | [amp] | 0
NC | base-collector leakage emission current |  | 2
RB | zero-bias (maximum) base resistance | [ohm] | 0
IRB | current at which RB falls halfway to RBM | [amp] | infinite
RBM | minimum base resistance | [amp] | RB
RE | emitter ohmic resistance | [ohm] | 0
RC | collector ohmic resistance | [ohm] | 0
CJE | base-emitter zero-bias p-n capacitance | [farad] | 0
VJE | base-emitter built-in potential | [volt] | 0.75
MJE | base-emitter p-n grading factor |  | 0.33
TF | ideal forward transit time | [sec] | 0
XTF | transit time bias dependence coefficient |  | 0
VTF | transit time dependency on Ubc | [volt] | infinite
ITF | transit time dependency on Ic | [amp] | 0
PTF | excess phase at frequency | [degree] | 0
CJC | base-collector zero-bias p-n capacitance | [farad] | 0
VJC | base-collector built-in potential | [volt] | 0.75
MJC | base-collector p-n grading factor |  | 0.33
XCJC | fraction of Cbc connected internal to Rb |  | 1
TR | ideal reverse transit time | [sec] | 0
CJS | substrate zoro-bias p-n capacitance | [farad] | 0
VJS | substrate p-n built-in potential | [volt] | 0.75
MJS | substrate p-n grading factor |  | 0
XTB | forward and reverse beta temperature coefficient |  | 0
EG | bandgap vantage (barrier height) | [eV] | 1.11
XTI | IS temperature effect exponent |  | 3
FC | forward-bias depletion capacitor coefficient |  | 0.5
AREA | relative device area |  | 1
OFF | "ON"/"OFF" sign for initial point in DC analysis |  | 0("ON")


Chapter 3

As shown in Fig. 3.4, for models of the type NPN and PNP the isolation junction capacitance is connected between the intrinsic-collector and substrate nodes. For lateral IC transistor structure there is a third model, LPNP, where the isolation junction capacitance is connected between the intrinsic-base and substrate nodes.

Fig.3.4.Bipolar transistor model.

The parameters ISF and ISC may be set to be greater than 1. In this case, they are interpreted as multipliers of IS instead of absolute currents: That is, if ISE > 1 then it is replaced by ISE·IS. Likewise for ISC.

Both model description (names "NPN", "PNP" and "LPNP") and list of default parameters (names "DEF.NPN", "DEF.PNP" and "DEF.LPNP") are stored in the ALLTED library.

The equations below describe the NPN transistor. For the PNP and LPNP devices the signs of all voltages and currents must be reversed.

DC Currents

Ib = AREA·(Ibef/BF+Iben+Iber/BR+Iben)
Ibef=AREA·IS·(exp(Ube¤ (NF·Vt))
- 1) /forward diffusion current/
Iben=AREA·ISE·(exp(Ube¤ (NE·Vt))
- 1) /non-ideal base-emitter current/
Ibcr=AREA·IS·(exp(Ube¤ (NR·Vt))
- 1) /reverse diffusion current/
Ibcn=AREA·ISC·(exp(Ube¤ (NC·Vt))
- 1) /non-ideal base-collector current/
Ice = Ibef/qb-Ibcr/qb
qb=q1·(1 + (1 + 4·q2)1¤ 2 )¤ 2 /base charge factor/
q1 = 1/(1-Ubc/VAF-Ube/VAR)
q2 = Ibef/(AREA·IKF)+Ibcr/(AREA·IKR)
Rb =:for IRB =
infinite
Rb = (RBM+(RB-RBM)/qb)/AREA
for IRB > 0

Capacitances

Cbe = Cbet+AREA·Cbej
/base-emitter capacitance/
Cbet = tf·Gbe
/transit time capacitance/
tf=TF·(1 + XTF·(3x2 - 2x3 )
·exp(Vbc¤
(1.44·VTF)) /effective TF/
where x = Ibef/(Ibef+AREA·ITF)
Gbc = dIbef /dUbe
/DC base-emitter conductance/
Cbej =: /depletion capacitance/
for Ube <= FC·VJE
Cbej = CJE·(1-Ube/VJE)-MJE
for Ube > FC·VJE
Cbej = CJE·(1-FC)-(1+MJE)·(1-FC·(1+MJE)+MJE·Ube/VJE)
Cbc = Cbct+AREA·XCJC·Cbcj /base-collector capacitance/
Cbct = TR·Gbc /transit time capacitance/
Gbc = dIbcr / dUbc /DC base-collector
conductance/
Cbcj =: /depletion capacitance/
for Ubc <= FC·VJC
Cbcj = CJC·(1-Ubc/VJC)-MJC
for Ubc > FC·VJC
Cbcj = CJC·(1-FC)-(1+MJC)·(1-FC·(1+MJC)+MJC·Ubc/VJC)
Cbx = AREA·(1-XCJC)·Cbxj /extrinsic base-intrinsic collector
capacitance/
Cbxj =:for Ubx <= FC·VJC
Cbxj = CJC·(1-Ubx/VJC)-MJC
for Ubx > FC·VJC
Cbxj = CJC·(1-FC)-(1+MJC)·(1-FC·(1+MJC)+MJC·Ubx/VJC)
Cjs = AREA·Cjjs /substrate junction capacitance/
Cjjs =:for Ujs <= 0
Cjjs = CJS·(1-Ujs/VJS)-MJS (assumes FC = 0)
for Ujs > 0
Cjjs = CJS·(1+MJS·Ujs/VJS)

Temperature effect

where bfact = (T/Tnom)XTB

VJE(T) = VJE·T/Tnom - 3·Vt·ln(T/Tnom) - Eg(Tnom) ·T/Tnom + Eg(T)
VJC(T) = VJC·T/Tnom - 3·Vt·ln(T/Tnom) - Eg(Tnom) ·T/Tnom + Eg(T)
VJS(T) = VJS·T/Tnom - 3·Vt·ln(T/Tnom) - Eg(Tnom) ·T/Tnom + Eg(T)

where Eg - silicon bandgap energy
CJE(T) = CJE·(1 + MJE·(0.0004·(T - Tnom ) + 1 - VJE(T)/VJE))
CJC(T) = CJC·(1 + MJC·(0.0004·(T - Tnom ) + 1 - VJC(T)/VJC))
CJS(T) = CJS·(1 + MJE·(0.0004·(T - Tnom ) + 1 - VJS(T)/VJS))

where

Ube = intrinsic base-intrinsic emitter voltage
Ubc = intrinsic base-intrinsic collector voltage
Ubx = extrinsic base-intrinsic collector voltage
Ujs = intrinsic collector-substrate voltage (NPN)
= intrinsic collector-substrate voltage (PNP) = intrinsic
collector-substrate voltage (LPNP)
Vt = kT/q (termal voltage)
Tnom = nominal temperature (300oK)
q = electron charge
k = Boltzman's constant

Default value of T equals Tnom. The collector,
base and emitter parasitic resistances have no temperature
dependence.


Chapter 3

FRES function. Temperature-dependent Resistor

General form

<Rname>(<+node>,<-node>)=FRES(<Rnom>,<R>,<TC1>,<TC2>,<TCE>/IR<name>);

Rnom = resistor value [ohm]
R = resistance multiplier
TC1 = linear temperature coefficient [oC-1]
TC2 = quadratic temperature coefficient [oC-2]
TCE = exponential temperature coefficient [%/oC]
If TCE equals zero, then resistance is given by the formula
Value = Rnom·R·(1+TC1(T-Tnom)+TC2·(T-Tnom)2).
In the case of nonzero TCE specification, the resistance is
given by the formula
Value = Rnom·R·1·01·TCE· (T-Tnom).
Tnom is the nominal temperature (300oK).

Example:
Rout(5,0) = FRES(10.K,1,2,1.5,0/IRout);

FVSWIT Function. Voltage-controlled Switch

FVSWIT function defines voltage-controlled switch that is a special kind of a voltage-controlled resistor.

General form

<Rname>(<+node>,<-node>)=FVSWIT(<RON>,<ROFF>,<VON>,<VOFF>/IR<name>,U<control>);

RON = "on" resistance [ohm]
ROFF = "off" resistance [ohm]
VON = control voltage for "on" state [volt]
VOFF = control voltage for "off" state [volt]
IR<name> = current through R<name> resistor
U<control> = controlling voltage

The resistance between <+node> and <-node> depends on the voltage across controlling two-terminal component. The resistance varies continuously between RON and ROFF. RON and ROFF must be greater than zero.

The equations below describe the switch:

Switch resistance

If VON > VOFF
for Uc >= VON Rs = RON,
for Uc <= VOFF Rs = ROFF,
for VOFF < Uc < VON
Rs = exp(Lm+3·Lr(Uc-Um)/(2·Ud)-2·Lr·(Uc-Um)3/Ud3),
If VON < VOFF
for Uc <= VON Rs = RON
for Uc >= VOFF Rs = ROFF
for VON < Uc < VOFF
Rs = exp(Lm-3·Lr(Uc-Um)/(2·Ud)+2Lr(Uc-Um)3/Ud3),

where

Uc = voltage across control two-terminal component
Lm = ln(RON·ROFF)1/2 /log-mean of resistor values/
Lr = ln(RON·ROFF) /log-ratio of resistor values/
Um = (VON + VOFF)/2 /mean of control voltage/
Ud = VON - VOF /difference of control voltage/
Rs = switch resistance.

FISWIT Function. Current-controlled Switch

FISWIT function defines a current-controlled switch as a special kind of a current-controlled resistor.

General form

(<Rname>)(<+node>,<-node>)=FISWIT(<RON>,<ROFF>,<ION>,<IOFF>/IR<name>,I<control>);

RON = "on" resistance [ohm]
ROFF = "off" resistance [ohm]
ION = control current for "on" state [ohm]
IOF = control current for "off" state [ohm]
IR<name> = current through R<name> resistorI<control>
= controlling current

The resistance between <+node> and <-node> depends on the current through controlling two-terminal component. The resistance varies continuously between RON and ROFF. RON and ROFF must be greater than zero. The equations below represent the switch:

If ION > IOF
for Ic >= ION
Rs = RON
for Ic <= IOFF
Rs = ROFF
for IOFF < Ic < ION
Rs= exp(Lm+3Lr(Ic-Im)/(2Id)-2Lr(Ic-Im)3/Id3)
If ION<IOFF
for Ic <= ION
Rs = RONN
for Ic >= IOFF
Rs = ROFF
for ION < Ic < IOFF
Rs = exp(Lm-3Lr(Ic-Im)/(2Id)+2Lr(Ic-Im)3/Id3),

where

Ic = controlling current
Lm = ln(RON·ROF)1/2
/log-mean of resistor values/
Lr = ln(RON/ROF) /log-ratio of resistor values/
Im = (ION + IOFF)/2 /mean of control currents/
Id = ION - IOFF /difference of control currents/
Rs = switch resistance.


Chapter 3

Auxiliary Functions

F1 Function. Diode Exponential VCCS

The F1 function defines a diode's exponential voltage-controlled current source.

General form:

<Jname>(<+node>,<-node>)=F1(<IS>,<TETA>,<UMAX>/UJ<name>);

IS = saturation current [amp]
TETA = factor inversely proportional to thermal voltage [volt-1]
UMAX = critical voltage [volt]
UJ<name> = controlling voltage

The value of the function is given by the formula:

U = controlling voltage;
for -UMAX<=U<=UMAX
F1=IS·(exp(TETA·U)-1
for U<-UMAX
F1 = a·(U+UMAX)+b

where a = IS·TETA·exp(-TETA·UMAX)
b = IS·(exp(-TETA·UMAX)-1)
for U>UMAX
F1 = a·(U-UMAX)+b

where a = IS·TETA·exp(TETA·UMAX)
b = IS·(exp(-TETA·UMAX)-1)

F2 Function. p-n Junction Capacitance

The F2 function defines a p-n junction capacitance with variable transit time capacitance and constant deletion capacitance.

General form

<Cname>(<+node>,<-node>)=F2(<IS>,<TETA>,<UMAX>,<TT>,<CJO>/UC<name>);

IS = saturation current [amp]
TETA = factor inversely proportional to thermal voltage [volt-1]
UMAX = critical voltage [volt]
TT = transit time [sec]
CJO = zero-bias p-n capacitance [farad]
UJ<name> = controlling voltage
The value of the function is given by the formula:
U = controlling voltage;
for -UMAX <= U <= UMAX
F2 = (TT·IS·TETA·exp(TETA·U)+CJO)·dU/dt
for U<-UMAX
F2 = (TT·IS·TETA·exp(-TETA·U)+CJO)·dU/dt
for U>UMAX
F2 = (TT·IS·TETA·exp(TETA·U)+CJO)·dU/dt

F3 Function. p-n Junction Current Source

The F3 function defines a p-n junction current source which includes F1 and F2 function.

General form

<Jname>(<+node>,<-node>)=F3(<IS>,<TETA>,<UMAX>,<TT>,<CJO>,<GPN>/UJ<name>);

IS = saturation current [amp]
TETA = factor inversely proportional to thermal voltage [volt-1]
UMAX = critical voltage [volt]
TT = transit time [sec]
CJO = zero-bias p-n capacitance [amp/volt]
GPN = p-n junction conductance [amp/volt]
UJ<name> = controlling voltage
The value of the function is given by the formula:
U=controlling voltage;
for -UMAX<=U<=UMAX
F3 = IS·(exp(TETA·U)-1)+(TT·IS·TETA·exp(TETA·U)+CJO)·dU/dt
+ GPN·U
for U < -UMAX
F3 = a·(U+UMAX)+b+(TT·a+CJO)·dU/dt+GPN·U

where a = IS·TETA·exp(-TETA·UMAX)
b = IS·(exp(-TETA·UMAX)-1)
for U>UMAX
F3 = a·(U-UMAX)+b+(TT·a+CJO)·dU/dt+GPN·U

where
a = IS·TETA·exp(TETA·UMAX)
b = IS·(exp(TETA·UMAX)-1)

F4 Function. Transform CCCS to VCCS

The F4 function is a subsidiary function that allows the transformation of a current-controlled current source into a voltage-controlled current source as:

I<name>= ?·I<control> to I<name>= ?·func(U<control>)

General form

<Jname>(<+node>,<-node>)=F4(<M>/U<control>);

M = multiplier
U<control> = controlling voltage

When using the function, the controlling voltage (argument of the function) must be read out on a dependent current source which precedes the operator with the F4 function.

Example

Jem(Bin,Ein)=F1(1E-14,38.6,0.6/UJem);
Jrev(Cin,Bin)=F4(0.98/UJem);

In the example the value of Jrev current is equal to the value of Jem multiplied by 0.98 factor.

F7 Function. Depletion Capacitance of p-n Junction

General form

<Cname>(<+node>,<-node>)=F7(<CJO>,<M>,<VJ>/UC<name>);

CJO = zero-bias p-n capacitance [farad]
M = p-n grading coefficient
VJ = p-n potential [volt]
UC<name> = voltage across C<name> capacitance
The function is given by the following formulas:
U = controlling voltage across capacitance;
for U<=FC·VJ
F7 = (CJO·(1-U/VJ)-M)·dU/dt
for U>FC·VJ
F7 = (CJO·FC-(1+M)·(1-FC·(1+M)+M·U/VJ))·dU/dt
where FC = 0.5

F8 Function. JFET Idrain VCCS

This function is a subsidiary function used in a simple model of Junction FET transistor. It defines the Idrain voltage-controlled current source.

General form

<Jname>(<+node>,<-node>)=F8(<BETA>,<VMIN>,<VMAX>,<TYPE>/U<control>);

BETA = transcondance coefficient [amp/volt2]
VMIN = minimum threshold voltage [volt]
VMAX = maximum threshold voltage [volt]
TYPE = transistor type:
= 0 for n-channel
= 1 for p-channel
U<control> = controlling voltage
The current for n-channel transistor is given by the formulas:
U = controlling voltage;
for U <= VMIN
F8 = 0
for U >= VMAX
F8 = BETA·(VMAX-VMIN)·(2·U-VMAX-VMIN)
for VMIN < U < VMAX
F8 = BETA·(U-VMIN)·2

F9 Function. p-n Junction Current Source

The function defines a p-n junction current source analogous to the F3 function but with depletion capacitance described by the F7 function.

General form<Jname>(<+node>,<-node>)=F9(<IS>,<TETA>,<UMAX>,<TT>,<CJO>, <GPN>,<M>,<VJ>/UJ<name>);

IS = saturation current [amp]
TETA = factor inversely proportional to thermal voltage [volt-1]
UMAX = critical voltage [volt]
TT = transit time [sec]
CJO = zero-bias p-n capacitance [farad]
GPN = p-n junction conductance [amp/volt]
M = p-n grading coefficient
VJ = p-n potential [volt]

The current defined by F9 function is given by the formulas:
U = controlling voltage;
for -UMAX <= U <= UMAX
F9 = IS·(exp(TETA·U)-1)+(TT·IS·TETA·exp(TETA·U)+Cd)·dU/dt
+GPN·U
for U< -UMAX
F9 = a·(U+UMAX)+b+(TT·a+Cd)·dU/dt +GPN·U

where a=IS·TETA·exp(-TETA·UMAX)

b=IS·(exp(-TETA·UMAX)-1)
for U>UMAX
F9= a·(U-UMAX)+b+(TT·a+Cd)·dU/dt +GPN·U

where a=IS·TETA·exp(TETA·UMAX)

b=IS·(exp(TETA·UMAX)-1)
Cd =: /depletion capacitance/
for U<=FC·VJ Cd = CJO·(1-U/VJ)-M
for U>FC·VJ Cd = CJO·FC-(1+M)·(1-FC·(1+M)+M·U/VJ)

where FC=0.5


Chapter 3

Operational Amplifier (OPAMP)

OPAMPL (Linear Macromodel of Operational Amplifier)

General form

<Qname>(N,I,B,0)=<device_name>.OPAMPL[(<substitution_list>)];

where:

N = noninverted input node name;
I = inverted input node name;
B = output node name;
0 = ground node;
OPAMPL = name of the intrinsic ALLTED operational
    amplifier linear macromodel (Fig. 3.5).

Fig. 3.5. Operational amplifier. Linear macromodel.

The description of the OPAMPL model in the ALLTED input language is as following:

MODEL OpAmpL(N,I,B,O);
RIN(N,I)=RIN;
R(A,0)=R;
R0(B,0)=R0;
C(A,0)=C;
J1(0,A)=FL(G1/URIN);
J2(0,B)=FL(G2/UC);

where

Component | Meaning | Units | Default parameters
RIN | input differential resistance | [ohm] | nondefinite
R0 | output resistance | [ohm] | nondefinite
R | low-frequency AFC pole modeling devices | [ohm] | nondefinite
C | low-frequency AFC pole modeling devices | [farad] | nondefinite
G1 | controlled parameters by J1 | [sim] | nondefinite
G2 | controlled parameters by J2 | [sim] | nondefinite

Input and output resistances, as well as the frequency dependence of a voltage gain are considered in the model.


Chapter 3

OPAMPN (NonLinear Macromodel of Operational Amplifier)

General form

<Qname>(N,I,P1,P2,B,0)=<device_name>.OPAMPN[(<substitution_list>)];

where:

N = noninverted input node name;
I = inverted input node name;
P1 = positive voltage source node name;
P2 = negative voltage source node name;
B = output node name;
0 = ground node;
OPAMPN = name of the intrinsic ALLTED operational amplifier
nonlinear macromodel (Fig. 3.6).

Fig. 3.6. Operational amplifier. Nonolinear macromodel.

The description of the model in the ALLTED input language is as follows:

MODEL OpAmpN(N,I,P1,P2,B,0);
Rin(A1,A)=Rin;
R1(I,A)=0.01;
RC1(A1,0)=RC1;
RC2(A,0)=RC2;
R2(N,A1)=0;
Rs1(P1,0)=100;
Rs2(0,P2)=100;
R(C,0)=R;
C(C,0)=C;
R0(B,D)=R0;
G0(B,0)=0;
Jcmp(A1,0)=Jcmp;
Jcmm(A,0)=Jcmm;
JC(A,I)=FL(GC/URC2);
J(0,C)=F504(G1,IM1,IM2,UM1,UM2/URin);
E(D,0)=F505(1/UC,URs1,URs2);

Component | Meaning | Units | Default
Rin | input differential resistance | [ohm] | nondefinite
R1 | internal resistance |  | 0.01
Rc1,Rc2 | common mode input resistances | [ohm] | nondefinite
R2 | internal resistance |  | 0
R0 | output resistance | [ohm] | nondefinite
Rs1,Rs2 | power source lines resistances |  | 100
R | low-frequency AFC pole modeling devices | [ohm] | nondefinite
C | low-frequency AFC pole modeling devices | [farad] | nondefinite
Gc | controlled parameter of current source Jc | [sim] | nondefinite
Im1 | limited parameter of output voltage's variation speed | [amp] | nondefinite
Im2 | limited parameter of output voltage's variation speed | [amp] | nondefinite
Um1 | limited parameter of output voltage's variation speed | [volt] | nondefinite
Um2 | limited parameter of output voltage's variation speed | [volt] | nondefinite
Jcmp, Jcmm | input bias currents | [amp] | nondefinite

Input bias currents, common mode input signal, limited output voltage's variation speed, output voltage limitations, frequency dependence of voltage gain are considered in this model.

The following equations describe nonlinear elements in the OPAMPN model of the operational amplifier.


Chapter 3

ALLTED Library with Analog Electronic Elements

Models analog electronic devices available in ALLTED are listed in the table below

Model name | Description | Identification subsystem
D | Diode nonlinear model. PSPICE analog |
DIOD | Bipolar diode | Yes
LPNP | Nonlinear model of LPNP bipolar junction transistor |
MOST | MOSFET with n- or p-channel |
NFET | JFET with n-channel | Yes
NJF | JFET with n-channel. PSPICE analog |
NPN | NPN bipolar junction transistor. PSPICE analog |
NPNEM | Ebers-Moll model of a bipolar junction PNP transistor | Yes
OPAMPL | Operational amplifier. Linear model | Yes
OPAMPN | Operational amplifier. Nonlinear model | Yes
PFET | JFET with p-channel | Yes
PJF | JFET with p-channel. PSPICE analog |
PNP | PNP bipolar junction transistor. PSPICE analog |
PNPEM | Ebers-Moll model of a bipolar junction transistor | Yes
ST | Zener diode model | Yes
UA741 |  |

ALLTED uses the same models for active elements as SPICE. Therefore SPICE model libraries can be successfully used in ALLTED to specify the parameters list of an element.

Compare parameters list for Q2N3904 NPN bipolar junction transistor in these software systems.

ALLTED:
List Q2N3904.NPN;
Is=6.734f; Bf=416.4; NF=1; Vaf=74.03; Ikf=66.78m;
Ise=6.734f; Ne=1.259; Br=0.7371; NR=1; Var=0;
Ikr=0; Isc=0; Nc=2; Rb=10; IRb=0;
Rbm=0; Re=0; Rc=0.0; Cje=4.493p; Vje=0.75;
Mje=0.2593; Tf=301.2p; Xtf=2; Vtf=4; Itf=0.4;
PTf=0; Cjc=3.638p; Vjc=0.75; Mjc=0.3085; XCjc=1;
Tr=239.5n; Cjs=0; Vjs=0.75; Mjs=0; Xtb=1.5;
Eg=1.11; Xti=3; Fc=0.5; Area=1;
&

SPICE:
.model Q2N3904 NPN(Is=6.734f Xti=3 Eg=1.11 Vaf=74.03 Bf=416.4
+ Ne=1.259 Ise=6.734f Ikf=66.78m Xtb=1.5 Br=.7371 Nc=2 Isc=0
+ Ikr=0 Rc=1 Cjc=3.638p Mjc=.3085 Vjc=.75 Fc=.5 Cje=4.493p
+ Mje=.2593 Tr=239.5n Tf=301.2p Itf=.4 Vtf=4 Xtf=2 Rb=10
+ Vje=.75)

In ALLTED, all parameters must be listed in the parameters list including default ones. Therefore, to develop a parameters list of some element on a basis of SPICE library, the default parameters are to be added to the SPICE list according to the general form of the device in ALLTED.

To simplify the determination of model parameters, ALLTED identification subsystem can be used. Elements available in the subsystem are marked in the above table.

Appendix of the manual contains the list of model and parameters lists now available in ALLTED.


Chapter 4

Digital/Mixed Mode Devices and Device Functions

The macromodeling approach is used in ALLTED to simulate digital devices. In other words, the digital device is represented as a two-cascade element consisting of input and output cascades. The first cascade consists of voltage-controlled current sources and second one consists of voltage and/or current-controlled voltage sources. A generic structure of such a macromodel is shown in Fig. 4.1.

Fig.4.1. Macromodel structure

N - number of inputs
M - number of outputs

A set of intrinsic functions of a form F<number> where <number> is an integer from 300 to 499 is developed to describe both input and output sources. Functions for input sources are assigned numbers from 300 to 309. These sources are designed to simulate I-U characteristics and to transform analog voltages into digital logic levels. Output functions which are assigned numbers from 310 to 499 generate voltage levels taking into account output impedance, latency properties of digital devices and logical levels developed by input sources.

F300 Input Function

General form

<Jname>(<+node>,<-node>)=F300(<UT>,<RIN>/UJ<name>);

UT = threshold voltage [volt]
RIN = input resistance [ohm]
UJ<name> = voltage across input current source.

The value of F300 function is evaluated by the equation

F300 = U/RIN

where U is the controlling input voltage.

F301 Input Function

General form
<Jname>(<+node>,<-node>)=F301(<UT>,<I1>,<I0>/UJ<name>);

UT = threshold voltage [volt]
I1 = logic "1" current [amp]
I0 = logic "0" current [amp]
UJ<name> = voltage across input current source.

The input I-V characteristic defined by F301 function is shown in Fig. 4.2.

Fig.4.2.Input |-V characteristic (F101).

The value of F301 function is evaluated by the following formulas:

U = controlling input voltage
UT0 = UT - 0.05 /"0" threshold voltage/
UT1 = UT + 0.05 /"1" threshold voltage/
for U<=UT0
F301 = I0
for U>=UT1
F301 = I1
for UT0<U<UT1

F302 Input function, ECL like

General form
<Jname>(<+node>,<-node>)=F302(<UT>,<U1>,<I1>,<I0>/UJ<name>);

UT = threshold voltage [volt]
U1 =logic "1" voltage [volt]
I1 = logic "1" current [amp]
I0 = logic "0" current [amp]
UJ<name> = voltage across input current source.

The F302 function is usually used to simulate ECL digital devices. Its input I-V characteristic is shown in Fig. 4.3.

Fig.4.3.Input |-V characteristic (F302)

The value of F302 function is evaluated by the following formulas:

U = controlling input voltage
UT0 = UT - 0.05 ("0" threshold voltage);
UT1 = UT + 0.05 ("1" threshold voltage);
("1" threshold current)
for U <= UT0 F302 = I0
for U >= UT1 F302 = I1
for UT0<U<UT1 F302 = (IP-I0).(U-UT0)/(UT1-UT0) + I0

F303 Input function, TTL like

General form
<Jname>(<+node>,<-node>)=F303(<UT>,<U0>,<I1>,<I0>/UJ<name>);

UT = threshold voltage [volt]
U0 = logic "0" voltage [volt]
I1 = logic "1" current [amp]
I0 = logic "0" current [amp]
UJ<name> = voltage across input current source
The F303 function is usually applied to simulate TTL digital devices.
The input I-V characteristic defined by F303 function is shown in Fig 4.4.

Fig.4.4.Input I-V characteristic (F303).

The value of F303 function is evaluated by the following formulas:

U = controlling input voltage
UT0 = UT - 0.05 ("0" threshold voltage)
UT1 = UT + 0.05 ("1" threshold voltage)
("0" threshold current)
for U<=UT0 F303 = I0
for U>=UT1 F303 = I1
for UT0<U<UT1 F303 = (I1-IP).(U-UT1)/(UT1-UT0) + I1

F310 Output Function, Logic

The function is developed to simulate digital devices like AND, OR, XOR, AND-OR, OR-AND gates.

General form
<Ename>(<+node>,<-node>)=F310(<U1>,<U0>,<F1>,<D1>,<F0>,<D0>,<R1>,<R0><T>,<NG>,<N1>,...,<NNG>/UE<name>,IE<name>);

U1 = logic "1" voltage [volt]
U0 = logic "0" voltage [volt]
F1 = rise time [sec]
D1 = "0"® 1"1"
switching delay [sec]
F0 = fall time [sec]
D0 = "1"®1"0"
switching delay [sec]
R1 = logic "1" resistance [ohm]
R0 = logic "0" resistance [ohm]
T = type of digital device:

1 - AND gate
2 - OR gate
3 - XOR gate
4 - AND-OR gate
5 - OR-AND gate

NG = number of gates at the first level
N1 = number of inputs of the first gate at the first level
NNG = number of inputs of the NG-gate at the first level
UE<name> = voltage across output source
IE<name> = current through output source

Note:
1. If parameter D1(D0) is assigned to positive value the rise (fall) voltage is evaluated by formulas:

or

else it can be given as solution of ordinary differential equation

where U(tc) = U0 or U(tc) = U1.
2. If parameter F1(F0) is assigned to negative value only switching delay taken into consideration.
3. To simulate the inverted logic gate parameter T is assigned to negative value.

Example:

Fig. 4.5. R-NOT:
a - schematic diagram; b - macDevice 3-3AND-2Oromodel.

The device is described as

MODEL GATE(In1,In2,In3,In4,In5,In6,Out1,0);
J1(In1,0) = F302(UT,U1,I1,I0/UJ1);
J2(In2,0) = F302(UT,U1,I1,I0/UJ2);
J3(In3,0) = F302(UT,U1,I1,I0/UJ3);
J4(In4,0) = F302(UT,U1,I1,I0/UJ4);
J5(In5,0) = F302(UT,U1,I1,I0/UJ5);
J6(In6,0) = F302(UT,U1,I1,I0/UJ6);
E1(Out1,0) = F310(U1,U0,F1,D1,F0,D0,
R1,R0,5,2,3,3/UE1,IE1);


Chapter 4

F311 Output function, JKFF like

The purpose of F311 function is to simulate the output of a synchronous JK - trigger. The schematic diagram and macromodel of trigger are shown in Fig. 4.6.

Fig. 4.6. JK - trigger:
a - schematic diagram;
b - macromodel.

Truth table

1 | 0 | - | - | 1 | 0
0 | 1 | - | - | 0 | 1
0 | 0 | 0 | 0 |  |
0 | 0 | 0 | 1 | 0 | 1
0 | 0 | 1 | 0 | 1 | 0
0 | 0 | 1 | 1 |  |

General form

<Ename>(<+node>,<-node>)=F311(<U1>,<U0>,<F1>,<D1>,<F0>,<D0>,<R1>,<R0><T>/UE<name>,IE<name>);

U1 = logic "1" voltage [volt]
U0 = logic "0" voltage [volt]
F1 = rise time [sec]
D1 = "0"® "1"
switching delay [sec]
F0 = fall time [sec]
D0 = "1"® "0"
switching delay [sec]
R1 = logic "1" resistance [ohm]
R0 = logic "0" resistance [ohm]
T = type of output:

0 = noninverting output
1 = inverting output

UE<name> = voltage across output source
IE<name> = current through output source
Example:

The description of JK - trigger by ODL is following

MODEL
JK-trigger(S,Inj1,Inj2,Inj3,C,Ink1,Ink2,Ink3,R,OutN,OutI,0);
J1(S,0) = F302(UT,U1,I1,I0/UJ1);
J2(Inj1,0) = F302(UT,U1,I1,I0/UJ2);
:
J9(R,0) = F302(UT,U1,I1,I0/UJ9);
E1(OutN,0) = F311(U1,U0,F1,D1,F0,D0,R1,R0,0/UE1,IE1);
E2(OutI,0) = F311(U1,U0,F1,D1,F0,D0,R1,R0,1/UE2,IE2);


Chapter 4

Output function F344. TTF - Toggle Flip Flop

Function F344 is intended to simulate the output of TTF - Toggle Flip Flop. The schematic diagram and macromodel of TFF are shown in Fig. 4.7.

Fig. 4.7. TFF: a - schematic diagram; b - macromodel

Truth table

Input |  | Output
Enable | CLK | Prior Q | Q
L | X | X | Prior Q
H | L - H | L | H
H | L - H | H | L
H | H - L | X | Prior Q

This table is true for positive-edge-triggered flip flop.
For negative-edge-triggered (TFF) exchenge L-H to H-L in the truth table.

General form
<Ename>(<+node>,<node>)=F344(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<F>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
F = type of TFF
1 = positive-edge-triggered (TFF);
2 = negative-edge-triggered (_TFF);
UE<name> = voltage across output source
IE<name> = current through output source

Example:

The description of TFF by ODL is following

Model TFF(1,2,3,0);
JE(1,0) = F303(VT,VIL,IIH,IIL/UYE);
JC(2,0) = F303(VT,VIL,IIH,IIL/UYC);
EQ(3,0) = F344(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,1/UEQ,IEQ);

Note: If the technical specification is absent F1 = -1 and F0 = -1. In this case default front edge duration is set.

Output function F345. Dto04, 08, 016 Decoders

Function F345 is developed to simulate the outputs of the decoder D2t04, D3t08, or D4t016. The schematic diagram and macromodel of D2t04 are shown in Fig. 4.8.

Fig. 4.8. Decoder: a - schematic diagram; b - macromodel

Truth table

Inputs |  |  | Outputs |  |
A1 | A0 | Q0 | Q1 | Q2 | Q3
L | L | H | L | L | L
L | H | L | H | L | L
H | L | L | L | H | L
H | H | L | L | L | H

General form

<Ename>(<+node>,<node>)=F345(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]

Example:

The description of decoder D2t04.
Model D2t04(1,2,3,4,5,6,0);
JA0(1,0) = F303(VT,VIL,IIH,IIL/UJA0);
JA1(2,0) = F303(VT,VIL,IIH,IIL/UJA1);
E0(3,0)=F345(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UE0,IE0);
E0(4,0)=F345(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UE1,IE1);
E0(5,0)=F345(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UE2,IE2);
E0(6,0)=F345(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UE3,IE3);


Chapter 4

Output Function F346. 7 Segment Decoder

The function F346 is developed to simulate the outputs 4 to 7 of segment Decoder (D4t07).The schematic diargam and macromodel of D4t07 are shown is Fig. 4.9.

Fig. 4.9. Decoder D4t07: a - schematic diagram; b - macromodel

General form
<Ename>(<+node>,<node>)=F346(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
UE<name> = voltage across output source
IE<name> = current through output source

Truth table

INPUT OUTPUT

 | D | C | B | A | a | b | c | d | e | f | g
0 | L | L | L | L | H | H | H | H | H | H | L
1 | L | L | L | H | L | H | H | L | L | L | L
2 | L | L | H | L | H | H | L | H | H | L | H
3 | L | L | H | H | H | H | H | H | L | L | H
4 | L | H | L | L | L | H | H | L | L | H | H
5 | L | H | L | H | H | L | H | H | L | H | H
6 | L | H | H | L | H | L | H | H | H | H | H
7 | L | H | H | H | H | H | H | L | L | L | L
8 | H | L | L | L | H | H | H | H | H | H | H
9 | H | L | L | H | H | H | H | H | L | H | H
10 | H | L | H | L | L | L | L | H | H | L | H
11 | H | L | H | H | L | L | H | H | L | L | H
12 | H | H | L | L | L | H | L | L | L | H | H
13 | H | H | L | H | H | L | L | H | L | H | H
14 | H | H | H | L | L | L | L | H | H | H | H
15 | H | H | H | H | L | L | L | L | L | L | L

Example:

The description of 4 to 7 segment decoder.

Model D4t07(1,2,3,4,5,6,7,8,9,10,11,12,13,0);
JA(1,0) = F303(VT,VIL,IIH,IIL/UJA);
JB(2,0) = F303(VT,VIL,IIH,IIL/UJB);
JC(3,0) = F303(VT,VIL,IIH,IIL/UJC);
JD(4,0) = F303(VT,VIL,IIH,IIL/UJD);
JR(5,0) = F303(VT,VIL,IIH,IIL/UJR);
JS(6,0) = F303(VT,VIL,IIH,IIL/UJS);
EA(7,0) = F346(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UEA,IEA);
EB(8,0) = F346(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UEB,IEB);
EC(9,0) = F346(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UEC,IEC);
ED(10,0) = F346(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED,IED);
EE(11,0) = F346(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UEE,IEE);
EF(12,0) = F346(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UEF,IEF);
EG(13,0) = F346(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UEG,IEG);


Chapter 4

Output Function F347. 2 Input Multiplexer

The function F347 simulates the outputs of the 2 Input Multiplexer (MUX2). The schematic diagram and macromodel of MUX2 are shown in Fig. 4.10.

Fig. 4.10. MUX2: a - schematic diagram; b - macromodel

Truth table

In 1 | In 2 | Select | Set | Reset | Q
X | X | X | H | L | H
X | X | X | L | H | L
X | X | X | H | H | ?
H | X | L | L | L | H
L | X | L | L | L | L
X | H | H | L | L | H
X | L | H | L | L | L

General form
<Ename>(<+node>,<node>)=F346(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
UE<name> = voltage across output source
IE<name> = current through output source

Example:

The description of multiplexer MUX2.

Model MUX2(1,2,3,4,5,6,0);
JS(1,0) = F303(VT,VIL,IIH,IIL/UJS);
JIN1(2,0) = F303(VT,VIL,IIH,IIL/UJIN1);
JIN2(3,0) = F303(VT,VIL,IIH,IIL/UJIN2);
JSel(4,0) = F303(VT,VIL,IIH,IIL/UJS);
JR(5,0) = F303(VT,VIL,IIH,IIL/UJR);
EQ(6,0) = F347(VOH,VOL,-1,TPHL,-1,TPLH,RH,RL/UEQ,IEQ);


Chapter 4

Output Function F348. Gray to Decimal Decoder

The function F348 simulates the outputs of Gray to Decimal Decoder (DGto10). The schematic diagram and macromodel of DGto10 are shown in Fig. 4.11.

Fig. 4.11. DGt010: a - schematic diagram; b - macromodel

General form

<Ename>(<+node>,<node>)
= F348(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
UE<name> = voltage across output source
IE<name> = current through output source

Truth table

B3 | B2 | B1 | B0 | D0 | D1 | D2 | D3 | D4 | D5 | D6 | D7 | D8 | D9
L | H | L | L | H | L | L | L | L | L | L | L | L | L
L | H | H | L | L | H | L | L | L | L | L | L | L | L
H | H | H | L | L | L | H | L | L | L | L | L | L | L
H | L | H | L | L | L | L | H | L | L | L | L | L | L
L | L | H | L | L | L | L | L | H | L | L | L | L | L
L | L | H | H | L | L | L | L | L | H | L | L | L | L
H | L | H | H | L | L | L | L | L | L | H | L | L | L
H | H | H | H | L | L | L | L | L | L | L | H | L | L
L | H | H | H | L | L | L | L | L | L | L | L | H | L
L | H | L | H | L | L | L | L | L | L | L | L | L | H
H | H | L | H | L | L | L | L | L | L | L | L | L | L
H | L | L | H | L | L | L | L | L | L | L | L | L | L
L | L | L | H | L | L | L | L | L | L | L | L | L | L
L | L | L | L | L | L | L | L | L | L | L | L | L | L
H | L | L | L | L | L | L | L | L | L | L | L | L | L
H | H | L | L | L | L | L | L | L | L | L | L | L | L

Example:

The description of Gray to Decimal Decoder

Model DGto10(1,2,3,4,5,6,7,8,9,10,11,12,13,14,0);
JB0(1,0) = F303(VT,VIL,IIH,IIL/UJB0);
JB1(2,0) = F303(VT,VIL,IIH,IIL/UJB1);
JB2(3,0) = F303(VT,VIL,IIH,IIL/UJB2);
JB3(4,0) = F303(VT,VIL,IIH,IIL/UJB3);
ED0(5,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED0,IED0);
ED1(6,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED1,IED1);
ED2(7,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED2,IED2);
ED3(8,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED3,IED3);
ED4(9,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED4,IED4);
ED5(10,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED5,IED5);
ED6(11,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED6,IED6);
ED7(12,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED7,IED7);
ED8(13,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED8,IED8);
ED9(14,0) = F348(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED9,IED9);


Chapter 4

Output function F349. Excess 3 to Decimal Decoder

The function F349 simulates the outputs of Excess 3 to Decimal Decoder (DX3to10). The schematic diagram and macromodel of DXto10 are shown in Fig 4.12.

Fig. 4.12. DX3to10: a - schematic diagram; b - macromodel

General form
<Ename>(<+node>,<node>)=F349(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
UE<name> = voltage across output source
IE<name> = current through output source

Truth table

B3 | B2 | B1 | B0 | D0 | D1 | D2 | D3 | D4 | D5 | D6 | D7 | D8 | D9
H | H | L | L | H | L | L | L | L | L | L | L | L | L
L | L | H | L | L | H | L | L | L | L | L | L | L | L
H | L | H | L | L | L | H | L | L | L | L | L | L | L
L | H | H | L | L | L | L | H | L | L | L | L | L | L
H | H | H | L | L | L | L | L | H | L | L | L | L | L
L | L | L | H | L | L | L | L | L | H | L | L | L | L
H | L | L | H | L | L | L | L | L | L | H | L | L | L
L | H | L | H | L | L | L | L | L | L | L | H | L | L
H | H | L | H | L | L | L | L | L | L | L | L | H | L
L | L | H | H | L | L | L | L | L | L | L | L | L | H
H | L | H | H | L | L | L | L | L | L | L | L | L | L
L | H | H | H | L | L | L | L | L | L | L | L | L | L
H | H | H | H | L | L | L | L | L | L | L | L | L | L
L | L | L | L | L | L | L | L | L | L | L | L | L | L
H | L | L | L | L | L | L | L | L | L | L | L | L | L
L | H | L | L | L | L | L | L | L | L | L | L | L | L

Example:
The description of Gray to Decimal Decoder
Model DX3to10(1,2,3,4,5,6,7,8,9,10,11,12,13,14,0);
JB0(1,0) = F303(VT,VIL,IIH,IIL/UJB0);
JB1(2,0) = F303(VT,VIL,IIH,IIL/UJB1);
JB2(3,0) = F303(VT,VIL,IIH,IIL/UJB2);
JB3(4,0) = F303(VT,VIL,IIH,IIL/UJB3);
ED0(5,0) = F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED0,IED0);
ED1(6,0) = F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED1,IED1);
ED2(7,0) = F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED2,IED2);
ED3(8,0) = F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED3,IED3);
ED4(9,0) = F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED4,IED4);
ED5(10,0)= F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED5,IED5);
ED6(11,0)= F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED6,IED6);
ED7(12,0)= F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED7,IED7);
ED8(13,0)= F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED8,IED8);
ED9(14,0)= F349(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED9,IED9);


Chapter 4

Output function F350. Full Adder/Half Adder

Full Adder/Half Adder (Add) is simulated by the function F350.(ADD). The schematic diagram and macromodel of MUX2 adder are shown in Fig. 4.13.

Fig. 4.13. ADD: a - schematic diagram; b - macromodel

Truth table

Inputs |  |  | Outputs |
A | B | C | SUM | CARRY
L | L | L | L | L
H | L | L | H | L
L | H | L | H | L
H | H | L | L | H
L | L | H | H | L
H | L | H | L | H
L | H | H | L | H
H | H | H | H | H

General form
<Ename>(<+node>,<node>)=F350(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
UE<name> = voltage across output source
IE<name> = current through output source

Example:

The description of Full Adder/Half Adder:

Model ADD(1,2,3,4,5,0);
JA(1,0) = F303(VT,VIL,IIH,IIL/UJA);
JB(2,0) = F303(VT,VIL,IIH,IIL/UJB);
JC(3,0) = F303(VT,VIL,IIH,IIL/UJC);
ES(4,0) = F350(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UES,IES);
EC(5,0) = F350(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UEC,IEC);

Output function F351. Data Latch

The function F351 simulates the outputs of Data Latch (DL). The number of inputs and outputs are equal (n = 1 ... 16). The schematic diagram and macromodel of DL for n = 2 are shown in Fig. 4.14.

Fig. 4.14. Data Latch: a - schematic diagram; b - macromodel

Truth table

Input | (tn) | Outputs(tn+1)
Dn | Clock | Qn
H | H | H
L | H | L
X | L | Qn

General form

<Ename>(<+node>,<node>)=F351(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]F1 = rise
time [sec]
TPLH = "0" -> "1" switching delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
UE<name> = voltage across output source
IE<name> = current through output source

Example:

The description of Data Latch (n = 2):
Model 2DL(1,2,3,4,5,0);
JD1(1,0) = F303(VT,VIL,IIH,IIL/UJ1);
JD2(2,0) = F303(VT,VIL,IIH,IIL/UJ2);
JC(3,0) = F303(VT,VIL,IIH,IIL/UJC);
E1(4,0)=F351(VOH,VOL,-1,TPHL,-1,TPLH,RH,RL/UE1,IE1);
E2(5,0)= F351(VOH,VOL,-1,TPHL,-1,TPLH,RH,RL/UE2,IE2);


Chapter 4

Output Function F352. Parallel Load Shift Registar PLSR

The outputs of n-bit (n can vary from 1 to 32) PLSR can be simulated with the function F352. The schematic diagram and macromodel of PLSR for n = 2 are shown in Fig. 4.15.

Fig. 4.15. PLSR: a - shematic model; b - macromodel

General form
<Ename>(<+node>,<node>) = F352(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>,<F>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
F = type of PLSR
1 = positive-edge-triggered (PLSR);
2 = negative-edge-triggered (_PLSR);
UE<name> = voltage across output source;
IE<name> = current through output source;
Par = for positive-edge-triggered equals 1;
for negative-edge-triggered equals 2;

Truth table (for positive-edge-triggered)

Dser | Load | Reset | Clock | D1 | Q1 | Qn
X | X | H | X | X | L | L
X | H | L | X | H | H | Dn
X | H | L | X | L | L | Dn
L | L | L | L-H | X | L | Qn-1
H | L | L | L-H | X | H | Qn-1

Example:

The description of Parallel load shift register (n = 2,
positive-edge-triggered):
Model 2PLSR(1,2,3,4,5,6,7,8,0);
JD1(1,0) = F303(VT,VIL,IIH,IIL/UJD1);
JD2(2,0) = F303(VT,VIL,IIH,IIL/UJD2);
JD3(3,0) = F303(VT,VIL,IIH,IIL/UJD3);
JD4(4,0) = F303(VT,VIL,IIH,IIL/UJD4);
JD5(5,0) = F303(VT,VIL,IIH,IIL/UJD5);
JC(6,0) = F303(VT,VIL,IIH,IIL/UJC);
E1(7,0)=F352(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,1/UE1,IE1);
E2(8,0)=F352(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,1/UE2,IE2);


Chapter 4

Output function F353. Shift Register SREG

The function F353 can simulate outputs of n-bit (n = 1 ... 32) Shift Register (SREG). The schematic diagram and macromodel of SREG for n = 2 are shown in Fig. 4.16.

Fig. 4.16. SREG: a - schematic model; b - macromodel

Truth table (for positive-edge-triggered)

Dser | Load | Reset | Clock | Q1 | Qn
L | L | L | L-H | L | Qn-1
H | L | L | L-H | H | Qn-1
X | L | L | H-L | Q1 | Qn
X | H | L | X | H | H
X | L | H | X | L | L

General form
<Ename>(<+node>,<node>) = F353(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>,<L>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
F = type of SREG
1 = positive-edge-triggered (SREG);
2 = negative-edge-triggered (_SREG);
UE<name> = voltage across output source;
IE<name> = current through output source;

Example:

The description of 2-bit Shift register (negative-edge-triggered):

Model _2SREG(1,2,3,4,5,6,0);

JR(1,0) = F303(VT,VIL,IIH,IIL/UJR);
JDS(2,0) = F303(VT,VIL,IIH,IIL/UJDS);
JC(3,0) = F303(VT,VIL,IIH,IIL/UJC);
JS(4,0) = F303(VT,VIL,IIH,IIL/UJS);
E1(5,0) = F353(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,2/UE1,IE1);
E2(6,0) = F353(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,2/UE2,IE2);


Chapter 4

Output function F354. Up Down Counter CNTR

The function F354 is developed to simulate the outputs of an n-bit (n = 2 ... 16) Up Down Counter (CNTR). The schematic diagram and macromodel of CNTR for n = 2 are shown in Fig. 4.17.

Fig. 4.17. CNTR: a - schematic model; b - macromodel

Truth table (for positive-edge-triggered)

Enable | Clock | Load | Reset | Q1 | Qn
X | X | X | H | L | L
X | X | H | L | D1 | Dn
H | L-H | L | L | (Count+ 1) | (Count+ 1)
X | H-L | L | L | No change | No change
L | X | L | L | No change | No change

General form

<Ename>(<+node>,<node>) = F354(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>,<F>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
F = type of CNTR
1 = positive-edge-triggered (CNTR);
2 = negative-edge-triggered (_CNTR);
UE<name> = voltage across output source;
IE<name> = current through output source;

Example:

The description of the 2-bit Up Down Counter (negative-edge-triggered):

Model _2CNTR(1,2,3,4,5,6,7,8,0);
JD1(1,0) = F303(VT,VIL,IIH,IIL/UJD1);
JD2(2,0) = F303(VT,VIL,IIH,IIL/UJD2);
JD3(3,0) = F303(VT,VIL,IIH,IIL/UJD3);
JD4(4,0) = F303(VT,VIL,IIH,IIL/UJD4);
JD5(5,0) = F303(VT,VIL,IIH,IIL/UJD5);
JC(6,0) = F303(VT,VIL,IIH,IIL/UJC);
E1(7,0) = F354(VOH,VOL,-1,TPHL,-1,TPLH,RH,RL,2/UE1,IE1);
E2(8,0) = F354(VOH,VOL,-1,TPHL,-1,TPLH,RH,RL,2/UE2,IE2);


Chapter 4

Output Function F355. D Flip Flop DFF

The function F355 simulates the noninverting outputs of the D Flip Flop (DFF). The schematic diagram and macromodel of DFF are shown in Fig. 4.18.

Fig. 4.18. DFF: a - schematic model; b - macromodel

Truth table (for positive-edge-triggered)

D | Clock | Reset | Set | Q | Q-
X | X | H | H | ? | ?
X | X | L | H | H | L
X | X | H | L | L | H
L | L-H | L | L | L | H
H | L-H | L | L | H | L
X | H-L | L | L | Q | Q-

General form
<Ename>(<+node>,<node>) = F355(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>,<F>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
F = type of DFF
1 = positive-edge-triggered (DFF);
2 = negative-edge-triggered (_DFF);
UE<name> = voltage across output source;
IE<name> = current through output source;

Example:

The description of the D Flip Flop (positive-edge-triggered):

Model DFF(1,2,3,4,5,6,0);
JS(1,0) = F303(VT,VIL,IIH,IIL/UJS);
JD(2,0) = F303(VT,VIL,IIH,IIL/UJD);
JC(3,0) = F303(VT,VIL,IIH,IIL/UJC);
JR(4,0) = F303(VT,VIL,IIH,IIL/UJR);
E1(5,0) = F355(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,1/UE1,IE1);
E2(6,0) = F313(RH,RL,/IE2);

Output Function F356. Trigger JK Flip Flop JKFF

The Function F356 simulates the noninverting outputs of trigger JK Flip Flop (JKFF). The schematic diagram and macromodel of JKFF are shown in Fig. 4.19.

Fig. 4.19. JKFF: a - schematic model; b - macromodel

General form
<Ename>(<+node>,<node>) = F356(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>,<F>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
F = type of JKFF
1 = positive-edge-triggered (JKFF);
2 = negative-edge-triggered (_JKFF);
UE<name> = voltage across output source;
IE<name> = current through output source;

Truth table (for the positive-edge-triggered)

J | K | Reset | Set | Clock | Q | Q-
X | X | H | H | X | ? | ?
X | X | L | H | X | H | L
X | X | H | L | X | L | H
X | X | L | L | H-L | No change | No change
L | L | L | L | L-H | No change | No change
L | H | L | L | L-H | L | H
H | L | L | L | L-H | H | L
H | H | L | L | L-H | Toggle | Toggle

Example:

The description of the JK Flip Flop (negative-edge-triggered):

Model _JKFF(1,2,3,4,5,6,7,0);
JR(1,0) = F303(VT,VIL,IIH,IIL/UJS);
JJ(2,0) = F303(VT,VIL,IIH,IIL/UJJ);
JK(3,0) = F303(VT,VIL,IIH,IIL/UJK);
JC(4,0) = F303(VT,VIL,IIH,IIL/UJC);
JS(5,0) = F303(VT,VIL,IIH,IIL/UJS);
E1(6,0) = F356(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,2/UE1,IE1);
E2(7,0) = F313(RH,RL,/IE2);


Chapter 4

Output Function F357. BCD to Decimal Decoder

The outputs of a binary to decimal decoder like D4to10 can be simulated by the function F357. The schematic diagram and macromodel of DXto10 are shown in Fig. 4.20.

Fig. 4.20. D4to10: a - schematic diagram; b - macromodel

General form
<Ename>(<+node>,<node>)= F357(<VOH>,<VOL>,<F1>,<TPLH>,<F0>,<TPHL>,<RH>,<RL>/UE<name>,IE<name>);

VOH = logic "1" voltage [volt]
VOL = logic "0" voltage [volt]
F1 = rise time [sec]
TPLH = "0" -> "1" switching
delay [sec]
F0 = fall time [sec]
TPHL = "1" -> "0" switching
delay [sec]
RH = logic "1" resistance [ohm]
RL = logic "0" resistance [ohm]
UE<name> = voltage across output source
IE<name> = current through output source

Truth table

B3 | B2 | B1 | B0 | D0 | D1 | D2 | D3 | D4 | D5 | D6 | D7 | D8 | D9
L | L | L | L | H | L | L | L | L | L | L | L | L | L
H | L | L | L | L | H | L | L | L | L | L | L | L | L
L | H | L | L | L | L | H | L | L | L | L | L | L | L
H | H | L | L | L | L | L | H | L | L | L | L | L | L
L | L | H | L | L | L | L | L | H | L | L | L | L | L
H | L | H | L | L | L | L | L | L | H | L | L | L | L
L | H | H | L | L | L | L | L | L | L | H | L | L | L
H | H | H | L | L | L | L | L | L | L | L | H | L | L
L | L | L | H | L | L | L | L | L | L | L | L | H | L
H | L | L | H | L | L | L | L | L | L | L | L | L | H
L | H | L | H | L | L | L | L | L | L | L | L | L | L
H | H | L | H | L | L | L | L | L | L | L | L | L | L
L | L | H | H | L | L | L | L | L | L | L | L | L | L
H | L | H | H | L | L | L | L | L | L | L | L | L | L
L | H | H | H | L | L | L | L | L | L | L | L | L | L
H | H | H | H | L | L | L | L | L | L | L | L | L | L

Example:

The description of BCD to Decimal Decoder

Model DXto10(1,2,3,4,5,6,7,8,9,10,11,12,13,14,0);
JB0(1,0) = F303(VT,VIL,IIH,IIL/UJB0);
JB1(2,0) = F303(VT,VIL,IIH,IIL/UJB1);
JB2(3,0) = F303(VT,VIL,IIH,IIL/UJB2);
JB3(4,0) = F303(VT,VIL,IIH,IIL/UJB3);
ED0(5,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED0,IED0);
ED1(6,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED1,IED1);
ED2(7,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED2,IED2);
ED3(8,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED3,IED3);
ED4(9,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED4,IED4);
ED5(10,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED5,IED5);
ED6(11,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED6,IED6);
ED7(12,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED7,IED7);
ED8(13,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED8,IED8);
ED9(14,0) = F357(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL/UED9,IED9);


Chapter 4

Output Function F506. Transmission Gate TG

The outputs of the Transmission Gate (TG) (Fig.4.21) can be simulated by this function.

Fig. 4.21. Transmission gate: a- schematic diagram; b- macromodel.

Truth table (normally open)

In | Gate | Out
L | L | Z
H | L | Z
L | H | L
H | H | H

General form
<Jname>(<+node>,<node>)
= F506(<VT>,<F>/<UJG,UJG1>);

VT = threshold voltage;
F = type of output
1 = normally open (TG);
2 = normally closed (_TG);

Example:

The description of a normally open transmission gate:

Model TG(1,2,3,0);
JIN(1,0) = F303(VT,VIL,IIH,IIL/UJIN);
E1(5,0) = F310(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,2/UE1,IE1);
JG(2,0) = F303(VT,VIL,IIH,IIL/UJG);
JG1(A,3) = F506(VT,1/UJG,UJG1);
R1(A,0) = 1000;


Chapter 5

Basic Analyses (DC, TR, AC)

This Section is a brief summary of basic algorithms involved in a mathematical model construction and numerical integration process. The program constants of these algorithms and how they influence the simulation process are outlined in the first part of the Section.

Time-domain transient analysis (TR), frequency-domain analysis (AC), and steady-state analysis (DC) are considered as "basic" analyses in ALLTED. How they are implemented greatly affects the efficiency, robustness, and power of the entire software system. They are widely used in such high-level design operations as optimization, optimal tolerance assignment, Monte Carlo analysis, etc. There they can be run recurrently several hundreds of times contributing largely to overall computation time investment. All these analyses are described in the Sections to follow. The presentation sequence used throughout the manual is as follows:

- Set of directives to accomplish the analysis,
- Set of the directive CONST parameters to adjust the analysis,
- Set of the problems developed to illustrate the analysis.
- Finally, the way to determine output characteristics such as the response time, bandwidth, pulse duration, overshoot, etc. is described.

The ALLTED algorithms are robust, mainly self-adjusting, and are effective in realizing answers to given design problems. The algorithms use program constants that are statistically averaged over the entire scope of mixed-technology objects. Sometimes these need to be changed from their default values to improve computation efficiency. To do this, the directive CONST is used in the parameters of the program constants.

General Computation Scheme

Generally, an equivalent circuit component is nonlinear and can be described as:

(5.1)
(5.2)
where
i,u = generalized flow and across variables respectively,
k,l,m,n = indices that may contain any component name from the set of component names.
In other words, the output variable (controlled variable) of the component is the function of the controlling component variables. Controlled variables are shown in the left part of Eqs (5.1), (5.2) while controlling ones are to the right. Up to 10 of any circuit variable or their derivatives are allowed in ALLTED nonlinear equations.
As far as numeric solution methods are concerned, the mathematical model of an object is analyzed only at a finite number of discrete intervals in either time, or some other domain. To speed up the mathematical model construction and solution of a set of nonlinear algebraic and differential equations, all the component equations are transformed into their discrete form before they are melted into an overall mathematical model. The structure of the now discrete component equation is readily available from the scheme involved in solution of the model, while its coefficients are dependent on each step of the solution. Generally they have to be updated at each discrete interval. Having these structures, an object's mathematical model structure is developed and is then filled with updated parameter values at each discrete interval.


Chapter 5

In accordance with the ALLTED solution scheme, each component equation of the type (5.1), (5.2) has to be converted first into an algebraic one (generally nonlinear) and then into a linear algebraic equation. The first process is governed by a numerical integration method involved, often referred to as algebraization, while the latter is largely determined by an algorithm involved in the solution of nonlinear algebraic equations, referred to as linearization.

The algebraization is done according to an implicit multistep numeric integration method:
(5.3)
where
= approximating polynom coefficients,
= integration method order,
= higher order backward differences computation operator,
= integration step,
= time iteration index.
Eq. (5.3) reduces a differential equation of a type
(where M is the component parameter and [image]) to an algebraic difference equation
(5.4)
the parameter [image] and the backward differences sum of which are updated at each step.
Nonlinear algebraic equations are solved according to the Newton scheme. The component equation y=f(x) is expanded to a limited members linear Tailor series in the vicinity of the solution

where m is the Newton iteration index. Considering the time iteration index the equation can be transformed to
 (5.5)
Eq.(5.5) is linear, ready to be used at the solution step, and its coefficients are defined by the results of previous iterations and component equation parameters. The derivatives in a component equation are regarded as independent variables. Generally, a component equation of the type [image] is transformed into the a linear algebraic form:
 (5.6)
which doesn't have derivatives as controlling arguments.
Eq.(5.6) is the scheme adopted in ALLTED to process component equations.
The mathematical model of an object is developed in the form:
(5.7)

where
= mathematical model matrix,
= right part vector,
= vector of model variables. All node potentials and flow variables of E,
R, and L components are regarded as model variables and inserted in the vector.
The elements of matrix A and vector b are updated at each step.

The set of now discrete linear algebraic equations is solved with the LU-factorization method which is used many times in the process of solution. To improve the efficiency of a solution, a mathematical model is ordered prior to processing to the form most suitable for this method.

The ALLTED numeric integration algorithm is based on a highly effective implicit method with automatic step-size and order selection. The algorithm default parameters are set to tackle the worst possible case. However, for some particular problem the parameter set may be far from optimal, resulting in computation time increase or even in erroneous results or computation failure. This is especially important when solving optimization problems, evaluating tolerances, etc., because for these tasks the model has to be solved hundreds and sometimes even thousands of times. That is why it is beneficial to understand the meaning of adjustable parameters and know the properties of the solution that can be influenced with a parameter. This section points out the role of each parameter in the solution and recommendations as to their usage.

Fig. 5.1. The flowchart of ALLTED numerical integration algorithm.


Chapter 5

A block diagram of the ALLTED model solving algorithm is shown in Fig.5.1. The main adjustable parameters are shown (highlighted with bold capital letters).
The default values of initial conditions [image] are set to be zero. But in practice this is rarely the case and this initial point is far from real conditions. That is why the computation convergence may occur or erroneous results may appear. To avoid such a situation, specifying initial conditions with the directive INSTALL is recommended even if only approximate data is available.

The directive CONST parameter that has no default value and must be set in the task is TMAX, the time span on which the behavior of an object is observed. Parameters STEP, MINSTEP and MAXSTEP denote initial, minimum and maximum integration steps respectively, and their default values are proportional to TMAX:

MINSTEP = TMAX x 1.e-6, MAXSTEP = TMAX x 0.05, STEP = MINSTEP.

The value of MINSTEP is highly dependent on the smallest time constants that are to be observed in the solution. Relatively often, this parameter allows high frequency computational disturbances to be filtered out. An increase in MINSTEP could disturb the integration process stability while a decrease could result in considerable slowing down because an algorithm would trace very small amplitude high frequency components. An initial step STEP is assigned if other than MINSTEP step value is desirable to handle the first iterations. Correct choice of initial step value could result in reducing the overall number of steps. Maximum integration step MAXSTEP should be chosen proceeding from desirable discretness of analysis results.

The real integration step falls within limits MINSTEP < h <MAXSTEP depending upon the computational environment.
Parameter XMAX is designed to set the maximum value of the variable (xmax) to control the relative error
(5.8)
at the beginning of computation when all the variables are usually very small that could cause an erroneous assessment. The XMAX value depends on the span between the vector x components and, consequently, on the measurement units system. If XMAX is set to 1 the absolute error is computed.

The Newton iterations convergence can be controlled in accordance with Eq.(5.8) by parameter ERR. Its value largely depends on the output results and input data accuracy. For initial runs a value of 1.E-4...1.E-3 is recommended, while the standard value is 1.E-6.

The stability of computation is controlled with local error estimation at each solution step. Stability loss is always preceded by its growth, so a LERR parameter is introduced to control the local error value at each time step. A value 10-2, ... , 10-3 is reliable for a variety of problems. Further LERR decrease inhibits the time step growth and slows down the computation.

As can be seen in Fig.5.1, two cycles are organized in the algorithm: time iterations (marked with index n) and Newton ones (marked with index m). After the coefficients of now discrete component equations are computed, the initial vector value [image] is predicted and the contributions to the A matrix and b vector are computed. The system of linear algebraic equations are solved by the LU- factorization method and vector [image] at moment [image] is found. Then the maximum relative error [image] (5.8) among the vector components is evaluated.
If [image] (5.9) where e is the specified local error (LERR), the results of the time step are accepted and they will be checked whether they satisfy the overall accuracy setting or not.

If the local accuracy requirements are not satisfied, the time step is shortened

until condition (5.9) holds or the step becomes shorter than MINSTEP.

The Newton iterations may not converge, if the initial values are far from the real point and the convergence direction, defined by the Jacoby matrix is badly defined. As a result, the trajectory of vector x variables encounters zigzag changes in a parametric space, resulting in the error sign variations. The convergence is enhanced by shortening a Newton step to damp the oscillations of variables:
(5.10)
where [image] is the vector i-th component value, [image] - is the damping factor depending upon the signs of the maximum error component at the m-th iteration and that at the m-1 iteration. The default value of [image] was set to 0.75 in ALLTED on an empirical basis. The parameter is assigned the name DAMP in the directive CONST.

If condition (5.8) is not satisfied after a MAXIT number of iterations is performed, the message "Maxit overflow" (Fig.5.2,a) is printed out, the step is categorized as rejected and attempt is made to proceed with the computation. If 12 rejected steps occur during 35 consecutive time steps the computation will be terminated. The user can make corrections based on the information in the message (Fig.5.2,a):

Step number - step number on which computation divergence occurred;
Iter number - maximum number of iterations allowable (specified by the MAXIT parameter);
Rejected steps - number of rejected steps;
Order - integration method order;
Damp.number - number of damping performed in accordance with Eq.(5.10) to enhance the convergence;
DM number - number of performed diagonal modifications;
Worst variable position - position of the variable in the vector in which the error is a maximum one. The position is counted from left to right, from top to bottom. In the example shown in Fig.5.2,a 15-th position corresponds to the variable x(8).
Maximum error - relative error of the variable considered as the worst one.
Step value - step size when divergence occurred. It is the value set by MINSTEP parameter;
Time - time.

To determine what physical quantity is represented by the variable, the task part with the directive OPTION 48 has to be inserted in front of the description, as it shown in Fig.5.2,c. The description of the variables (Fig.5.2,b) and a mathematical model characterization will be directed in ALLTED.OUT file.


Chapter 5

As a rule, computation divergence occurs because the circuit numerically is ill-conditioned. This may be caused by incorrect circuit description, by abrupt element characteristic change, by discontinuity of element characteristic (components of a type "dry friction", relay etc). Stability increase is achieved by simultaneously changing the component parameters/characteristics and the integration algorithm constants.

a) MAXIT OVERFLOW !!!

Step number | Iter number | Rejected step | Order | Damp. number | DM number | Worst variable position | Maximum error | Step value | Time
0 | 12 | 0 | 0 | 7 | 0 | 15 | -10.795 | 0.1E-04 | 0.1E-04

Vector of variables

X(15)=0.000000000E+00 X(16)=0.000000000E+00
X(2)=1278.00000 X(14)=-1278.00000
X(4)=0.199990500 X( 6)=0.100000000
X( 13)=-0.446597E-04 X(12)=-4.46597988
X(5)=26.2251878 X(3)=26.1752139 X(
11)=-0.139328E-05 X(9)=-0.139326621
X(7)=27.6294853 X(1)=27.6078764 X(8)=-0.140875E-02
X(10)=-0.140871E-07

b)
Mathematical model variables vector
X( 1) - node voltage 1
X( 2) - node voltage 4
X( 3) - node voltage 2
X( 4) - node voltage 6
X( 5) - node voltage 3
X( 6) - node voltage 5
X( 7) - node voltage N1.PRV
X( 8) - node voltage N2.PRV
X( 9) - node voltage N3.PRV
X( 10) - node voltage N4.PRV
X( 11) - node voltage N5.PRV
X( 12) - node voltage 1.HA
X( 13) - node voltage 2.HA
X( 14) - element current ECNTR
X( 15) - element current EFL
X( 16) - element current EAC

c)
TASK
OPTION 47,48;
&
Object <object_name);
<description operators>

Fig.5.2. MAXIT overflow message (a), mathematical model
variables (b), and input file organization (c).


Chapter 5

Stability and computation speed can be always be increased by "smoothing" the characteristics, provided this operation does not lead to higher than estimated accuracy losses. The algorithm stability and computation speed are most affected by the constants:

MINSTEP, ERR, ORDER, DAMP, XMAX, LERR

The ORDER parameter defines the maximum order k of the method. The lower the order the higher the stability, but error probability is also increased. The default value is k = 6. The method is A-stable when k=2 and is [image] - stable when k>2 with angle [image] diminishing along with order increase.

The DAMP parameter is equivalent to the [image] coefficient in Eq. (5.10). This parameter should be decreased if a large number of damping (5-7) and a sing-changing occurrence are reported in the MAXIT OVERFLOW message. The DAMP parameter can be as small as 0.2...0.4.

Before adopting a new time interval (Fig.5.1) the optimal order and time step-size are computed. If the ORDER value is not set explicitly, it is chosen from a range of 1 <=k <=6. The order value is restricted by the growth of local error among all vector x components.

Mathematical model constructing and ordering is performed prior to the solution and nonlinear components numeric values evaluation. This may lead to zero or small values on the main matrix diagonal resulting in a "divide by zero" (overflow) interrupt, which can be eliminated by increasing the number of diagonal modifications (MAXDM) or by altering the equivalent circuit in such a way as to get rid of nodes and contours with same type nonlinear components. The default value of MAXDM is 4.

ALLTED steady-state, time and frequency domain analyses are based on the same algorithms and the same equivalent circuit can represent an object for any of these analyses. It is also possible to combine analysis for linearization (DC + AC), initial condition determination (DC + TR) and to compute the entire scope of object performance (transient, frequency, and steady-state ones) in one computation run.

Component equations are automatically modified for each analysis type. In steady-state domain all the C and L components are substituted with fictitious G and R components respectively:
(5.11)
The parameters of these components are very small, but proportional to the real component value (the default EPS value is 1.E-7). Practically the fictitious resistors and conductances of values 1.E-8...1.E-10 do not noticeably effect the accuracy of the results. Parameter DCLC of the directive CONST sets the value of EPS.
In frequency domain all the component parameters are converted into complex ones whose values depend on the frequency [image] :

Nonlinear components
are considered in the form
where [image] = result of previous iterations.
The coefficients in the discretized equation can be frequency dependent
 (5.12)


Chapter 5

DC (Steady-state) analysis

During DC analysis, the steady-state response of an object is computed. The analysis can be used alone or in conjunction with either time-domain transient analysis (TR) or frequency analysis (AC). In the first case it determines the initial conditions while in the second, the linearization is its purpose.
To run DC analysis, the task should contain the directives shown in the table below

Purpose | Directive
Steady-state analysis setting | DC
Adjust the computation | CONST
Specify output variables | TABLE

Directive CONST parameters that are used to set DC analysis are summarized in the next table. The default values are shown in parenthesis ( ).

Parameter | Purpose | Description
DCMAXIT (300) | Maximum number of iterations per step of steady-state analysis |
DCERR (1.E-6) | Maximum error of divergence of Newton iterations | To control the accuracy. Its value significantly affects the number of iterations. Its value must not be more than 1.E-3.
DCLC (1.E-6) | Parameter to replace C and L components with dummy G and R components. | Value should be small enough so as to cause no effects on static accuracy. It can be as small as 1.E-9.
DAMP (0.75) | The parameter to control Newton step length | See Eq. (4.10)
MAXDM (3) | Maximum number of diagonal modification |
DCMET (0) | Used to select DC analysis method | Three methods are available: METHOD=0, METHOD=1, METHOD=2.

Three algorithms based on different approaches to solving the nonlinear algebraic circuit equations are used in the DC analysis module:
- the first approach (METHOD= 0) is based on the Newton-Raphson scheme with a linear step length search along the chosen solution trajectory.
- the second algorithm (METHOD= 1) implements a continuation approach based on a source-stepping procedure where intermediate DC solutions are obtained by the modified Newton method (Davidenko's continuing solution).
- the third algorithm (METHOD = 2) is a novel scheme based on the search of a hypercurve connecting the current guess and the solution points. In some cases this algorithm could be more costly than the others but it always offers a better convergence performance.

For details, see: Petrenko A.I., Omer-Imerely A. Curve-search algorithm for DC analysis of nonlinear electronic circuits, International journal of circuit theory and applications, v.18,401-409 (1990).

The availability of different strategies helps to overcome non-convergence whenever it occurs.
If the solution is not reached with DCMET=0 during DCMAXIT iterations, the method is automatically changed to DCMET=1. The nonlinear search method is selected by the user a priori by setting DCMET=2 in the CONST directive.

The assignment of initial conditions for DC analysis is advisable using INSTALL directive:
INSTALL <model_variable_name> =<value> [,<model_variable_name> = <value>...];

The model variables are all node potentials and flow variables of E, R, or L components:
INSTALL V1 = 0.5, IE1.T1 = 1.0E-4;

Results of DC analysis are output to the file ALLTED.OUT by the TABLE directive:
TABLE <variable_name>{,...<variable_ name>...};

TABLE ALLU{,ALLI,ALLV,ALLP};

The variable_name is any flow variable (current, flow rate, force, torque, etc.), across variable (voltage, velocity, displacement, pressure, etc.), node potential, or power dissipated in two-terminal elements.


Chapter 5

Frequency-domain analysis (AC)

ALLTED has two methods for frequency-domain analysis. The first is based on the direct computation of the small-signal frequency response. The second is based on the Fourier transform of the pulse transient response. The development of this section is concerned with the first method only. The second method will be described in Chapter 6.

To run frequency analysis, the following directives should be defined in the task:

Purpose | Directive
Frequency-domain analysis setting | AC
Steady-state analysis for object linearization | DC
Adjust the computation | CONST
Define transfer functions | TF
Specify output characteristics in plot format | PLOT LPLOT LTPLOT
Specify frequencies at which the analysis is performed | SWEEP
Specify output characteristics | FIX INT FUNC

Frequency-domain analysis is determined for linear systems only. Therefore the directive DC should always precede the AC analysis to linearize the object. The computation scheme is such that this directive can be used for both nonlinear and linear systems.

The directive TF defines the transfer function as a ratio of two variables and assigns a name to the function. For example:
TF GAIN = UCD/UEINPUT, K5 = IL4/UEINPUT;

Two transfer functions are specified in the example: the first with the name GAIN and the second named K5.
The type of frequency characteristic is specified with the key words:

RE = real component of the transfer function,
IM = imaginary component,
MA = amplitude modules,
DB = amplitude in decibels,
PH = phase angle in degrees,
RAD = phase angle in radian.

The name of a particular characteristic is composed of the transfer function name and one of the identifiers. For instance:
DB.GAIN, PH.K5, RE.GAIN, etc.
Using these names, a characteristic can be output in plot format with the directives PLOT, LPLOT, LTPLOT or can be referred to as an argument in the directives FIX, INT, FUNC to compute output characteristics (secondary variables) such as bandwidth, min/max gain, etc.

For example:

LPLOT DB.GAIN, PH.K5;
FIX PEAK=MAXF(DB.GAIN), BANDWIDTH=FALL(-90,PH.GAIN);
The list of intrinsic ALLTED functions to compute secondary variables is described in Section 2.4.3.3.
Directive CONST parameters that are used to set AC analysis are summarized in the next table. The parameter default values are shown in parenthesis ( )

Parameter | Purpose | Description
LFREQ (0) | Lower boundary of the frequency range | When computing a logarithmic frequency characteristics, LFREQ must be greater than zero.
UFREQ | Upper boundary of the frequency range | A required setting.
PHASEANG (180) | Parameter to control phase-frequency characteristic scaling. The range +/-180 degrees is set by default. | With PHASEANG equal 360 the phase-frequency characteristic will be plotted within the range 0 ... 360 degrees. The value of the parameter -360 changes the limits to 0 ... -360.
NUMBAC (100) | Number of points within frequency range to compute characteristics' values | With PLOT/LPLOT and/or SWEEP directives not used, this parameter sets the number of points at which the analysis is to be performed

The parameters LFREQ and UPFREQ set the frequency range within which frequency characteristics are to be evaluated. The number of frequencies at which the characteristics will be computed is specified by the parameter "plot length in printer lines" of the directive PLOT or LPLOT. The default value of this parameter is 100 so all the frequency characteristics will be computed at 100 frequencies, if not otherwise specified.

Usually, during optimization, statistical analysis, etc. the characteristics only at specific frequencies are of interest. To save computation time, the directive SWEEP specifies the exact values of frequencies at which, and only at which, an analysis will be performed. For instance, the directive:

SWEEP FREQ (w1,w2,w3,...);
sets that only at these selected frequencies w1, w2, w3, etc. all the computations take place.

If an intrinsic function FIXA occurs in the directive FIX, then analysis will be carried out at all the frequencies mentioned in these functions whether the directive SWEEP is used or not.

A linear interpolation is used to compute FIX function: MAXF, MINF, FALL, RISE, MAXA, MINA. To set a number of uniformly distributed points within a specified frequency range when both the directives SWEEP and PLOT are not used, the directive CONST parameter NUMBAC with the default value of 100 is to be used.

Examples for AC analysis problems see in section 12.


Chapter 5

Transient analysis (TR)

The transient analysis module computes the behavior of an object for any combination of input signals. Any node potential, flow and across variables, and power on any two-terminal component can be output in either table or plot format. Further processing to compute output characteristics such as pulse width, rise/fall time, switching time, delay time, min/max response value, fixed time-point value, response time, overshoot, stability criteria, etc., is also available with the directives FIX, INT, and FUNC (see Section 2.4).

Generally, an object is described by a set of stiff nonlinear algebraic/ differential equations. ALLTED streamlines the time-domain analysis by a novel variable order and variable step-size implicit numerical iteration algorithm, which is able to adapt to ill-conditional tasks.

To run transient analysis, the following directives should be defined in the task:

Purpose | Directive
Time-domain transient analysis setting | TR
Steady-state analysis for initial conditions determination (optional) | DC
Adjust the computation | CONST
Specify output variables in table format | TABLE
Specify output variables in plot format | PLOT TPLOT LPLOT LTPLOT
Specify output characteristics | FIX INT FUNC

Directive CONST parameters that are used to set TR analysis are summarized in the next table. The parameter default values are shown in parenthesis ( ).

Parameter | Purpose | Description
TMAX | Integration interval. | Sets the time span to be observed.
MINSTEP (1.E-6 x TMAX) | Minimum step of integrating procedure | An increase in MINSTEP can disturb the integration process stability. A decrease can cause "mark time" due to very small amplitude high frequency components tracing.
STEP (MINSTEP) | Initial step of integrating procedure | An individual choice of initial step can help to put through the beginning of the system motion.
MAXSTEP (0.05 x x TMAX) | Maximum integration step-size value | Should be decreased if the plot becomes too coarse.
ORDER (6) | Maximum order of integrating method | With ORDER < 0, order of integrating method is fixed and is equal to ORDER value magnitude.
ERR (1.E-6) | Relative error of convergence of Newton iteration | ERR affects total number of iterations. A value of less than 1.0E-3 is recommended.
ITER (4) | Number of iterations on the time step | If number of iteration exceeds ITER time step will decrease.
MAXDM (4) | Maximum number of diagonal modifications | With MAXDM = 0 diagonal modifications are not performed.
LERR (1E-3) | Permissible value of local error of integrating method | The parameter LERR greatly effects number of time steps. Depending on class of objects, it is recommended to set its value within (1E-2 ... 1E-3)
MAXIT (12) | Maximum number of Newton iterations per step |
DAMP (0.75) | Damping parameter at Newton iterations | See Eq.(4.10). With DAMP = 1 damping is not performed.
NSTEP (5E3) | Maximum number of time steps | If number of time steps exceeds NSTEP, analysis terminates and output results are plotted.
TPRINT (0) | Periodicity of intermediate diagnostic results in time domain | With TPRINT = n, where n > 0 through each n steps the detailed information of integration process is output (values of constants, running values of mathematical model variables, current values of nonlinear and reactive components).
REVAL (1) | Revaluation periodicity of Jacobian matrix in solution of a set of nonlinear algebraic equation | Maximum value of REVAL should not exceed three. If REVAL=1, model matrix renewed in each step.
COMPL | Set of constants | 0 - (LERR=0.01, ERR=0.001) 1 - (REVAL=3, LERR=0.04, ERR=0.001) 2 - (XMAX=1,REVAL=3, LERR=0.01,ERR=0.001) 3 - (all default values) 4 - (XMAX=0.1, REVAL=3, LERR=0.01, ERR=0.001) 5 - (REVAL=3,LERR=0.01, ERR=0.001) 6 - (REVAL=1, LERR=0.01, ERR=0.001)
STPLOT (0) | Instant of time to start plot data storage |
STTAB (0) | Instant of time to start outputting the table |
XMAX (0.01) | Initial value of maximum component to control the relative error (See Eq.(4.8)) | Used at initial steps to compute the relative error

Examples for TR analysis problems see in section 12.


Chapter 5

Modify Parameters

Multiple reruns of TR, DC, or AC analyses can be made with specified parameters modified for each run. The MODIFY directive defines the action:

MODIFY <parameter_name>= <new_value> {,<parameter_name>=<new_value>};

The parameter NVAR of the directive CONST sets the number of runs after which the variables specified in the PLOT/LPLOT directive are output into one superimposed plot.
To preserve ALLTED modules for the next rerun, the directive SAVE has to be inserted in the task.

Example:

TASK;
DC; # DC, TR, AC analyses individually or in any combination can be used with the MODIFY directive
TR;
CONST TMAX=3000,
NVAR=2; # After each two consecutive runs the variables V1 and V21 will be output to the plot
PLOT V1,V21;
SAVE;
&
TASK; # Three parameters are modified
MODIFY RIN=6.3, ALPHA.T2.TR5=106%, EINP(3)=7.1;
&
TASK;
MODIFY RIN=12.5;
SAVE;
&
TASK;
MODIFY RIN=18.3;
&
END


Chapter 6

Fourier Analysis (FR)

Fourier analysis is based on discrete Fourier transform of the time series of values being accumulated in the process of the time domain analysis. Therefore it starts with time-domain analysis to complete the time series. Then this series is subjected to the discrete Fourier transform in accordance with the formulas:

where
A,B = Fourier coefficients,
N = number of elements in the time series,
n = harmonic number,
h = time series element value.
The Fast Fourier Transform (FFT) Algorithm is used for the transformation.
This design operation obtains a line spectrum of any variable, finds the Fourier expansion coefficients, and computes the frequency characteristics.
To run Fourier analysis, the task should contain the directives shown in the table below.

Purpose | Directive
Steady-state analysis to determine initial conditions followed by time-domain transient analysis to complete the time series | DC TR
Time-domain analysis alone starting with zero initial conditions (if directive INSTALL is not used) to complete the time series | TR
Fourier analysis setting | FOUR
Adjust the computation | CONST
Specify output variables that may be output during time-domain analysis. Due to large memory requirements, the list of variables output in plot format must be as short as possible. The parameter DIPLOT is highly recommended to be used in the case. | TABLE PLOT TPLOT LPLOT LTPLOT
Specify output characteristics that may be output during time-domain analysis. | FIX INT FUNC
Specify output characteristics to be plotted in spectrogram format. | SPECTR

The directive SPECTR has the format
SPECTR <var_name>[=<alias>] {,<var_name>[=<alias>]}[(<lower_frequency>,<upper_frequency>)];

where <var_name> = any node potential, flow or across variable, that is any variable whose name starts with V, I, or U prefixes,

<lower_frequency> = lower frequency range boundary,
<upper_frequency> = upper frequency range boundary,
<alias> = alias name that may replace the variable name.

The directive specifies the variables processed with the FFT algorithm and frequency range in which their spectrum performances are outputted. By default, lower frequency is set to zero while upper frequency takes its maximum value resulting from the directive CONST parameters.

Example:

SPECTR, IL4;
SPECTR UCD=DISP1, V7.T3.AMPL1=OUTVOLT(2,23);

Directive CONST parameters that are used to set the Fourier analysis are summarized in the next table. Note that a time-domain transient analysis, which is run first to complete the time series, is adjusted with parameters listed in Section 5.4. Only parameters specific to Fourier analysis are listed in the table:

Parameter | Purpose | Description
LFREQ (0) | Lower boundary of the frequency range. | Sets the frequency range lower boundary if this parameter is not specified in the directive SPECTR.
UFREQ | Upper boundary of the frequency range. | Sets the frequency range upper boundary if this parameter is not specified in the directive SPECTR. The upper frequency limit should be specified in either CONST or SPECTR directives to avoid an output of the spectrum at high frequencies.
NUMB (1024) | Number of time series elements. | Determines the number of the time series elements and must be chosen among 2k integers, where k=1,2,3,...,11.
BEGT (0) | Instant of time to start the time series accumulation. |
ENDT (TMAX) | Instant of time to stop the time series accumulation. |
METHOD (10) | Parameter to set the type of Fourier analysis (with the first digit) and to specify the strategy (with the second digit) of step-size determination. |


Chapter 6

Parameter METHOD of the directive CONST determines the Fourier analysis type mode and the way of how the time series elements are obtained. The first digit in the value of the parameter METHOD specifies:

1 = line spectrum calculation,
2 = Fourier series coefficients calculation,
3 = frequency response calculation.

The second digit in the value of METHOD can be either 0 or 1. If METHOD ends at 0 no restrictions are imposed on the step-changing strategy of the integration method and the time series elements will be obtained by a linear interpolation. If the second digit is 1, a time-domain analysis will be preformed precisely at the instant of time when a time series element occurs.

Parameters BEGT and ENDT determine the initial and end time within which the information concerning the characteristics indicated in directive SPECTR are accumulated.

Parameter NUMB determines the number of the time series elements and must be chosen among 2k integers where k=1,2,3,...,11.

To set the parameters, the following relationships should be kept in mind. Number N=NUMB of time series elements permits N/2 Fourier expansion harmonics with the step 1/(ENDT-BEGT). The upper harmonic available is of the frequency (N/2-1)/(ENDT-BEGT). The more elements accumulated in the time series the higher the final precision will be. Methods 11,21,31 are always superior from accuracy point of view, but they are much more time consuming as well.

LFREQ and UFREQ set the frequency range to be observed if these parameters are not assigned in the directive SPECTR. The upper frequency limit must always be specified in either SPECTR or CONST directives to avoid an output spectrum at high frequencies which is highly susceptable to disturbances.

Frequency response determination is based on the relationship

where hk = pulse transient response k-th value,
W(n) = transfer function complex amplitudes.

The relationship is derived for linear systems and can handle nonlinear systems with a certain amount of error. The value of the error can only be estimated experimentally. For slightly nonlinear systems this error is negligibly small, while for highly nonlinear systems this approach has no option.

A step-input signal can often be used instead of pulse input, but in this case the first derivative of the output variable must be accumulated in the time series. This derivative can be easily obtained in all type of drives because as a rule, a displacement of an output member is an output variable, while a velocity of the member in a lot of real systems is readily available.

The magnitude ratio of frequency characteristics are computed relatively to those at null frequency. If methods 30 or 31 are set, the output variable specified by the directive SPECTR can be seen with ALLTED Plotter (not with Spectrogram viewer).

If METHOD=32 is used the characteristic will be plotted in logarithmic scale.

Example:

TASK
DC;
TR;
CONST TMAX=0.2, DCMET=1;
FOUR;
SPECTR UOUT, IRIN(10,150);

The spectrum of UOUT and IRIN are calculated over the range 0-512 units because NUMB is set to 1024 by default. The frequency of the main harmonic (fundamental frequency) is equal to 1/TMAX=5 units. The time series of the output variables is completed by linear interpolation (METHOD=10 by default).

The spectrum of UOUT and IRIN is output in range 10-150 units.

Example:

TASK
DC;
TR;
CONST TMAX=1.6,BEGT=0.1,ENDT=1.1,METHOD=31,NUMB=2048;
FOUR;
SPECTR UR8(5,650);

The frequency characteristic is specified with METHOD=31. The variable UR8 is supposed to be a pulse transient response determined in 0.1-1.1 time interval. Input signal in a form of step or pulse function is activated at 0.1 sec.

Example:

The following problems were developed to illustrate Fourier analysis in ALLTED.

The task of the problem inv_four.atd is illustrated and commented below. The invertor illustrated in the example is described in Section 2.2.5.

task;
DC; # DC analysisTR Transient analysis
FOUR; # Fourier analysis# Directive CONST sets the parameters to adjust computation

CONST TMAX=100, # Time span
ERR=1E-2, # Acceptable error level
DIPLOT=0.5, # Storage interval for plots
UFREQ=0.5, # Upper frequency boundary for linear spectrum
METHOD=10, # Sets the option of Fourier analysis(linear spectrum computation,linear interpolation is allowed to fill in time series)
NUMB=128; # Time series size Three output characteristics are specified in FIX and INT directives
FIX T1=RISE(V2,0.5), # T1 is the time when V2 intersects 0.5 level while increasing
T2=FALL(V2,0.5); # T2 is the time when V2 intersects 0.5 level while decreasing
INT PD=T2-T1; # PD is the pulse duration
SPECTR V1; # The variable V1 is subjected to Fourier analysis.
#The results are plotted in a linear spectrum form
PLOT V4(40); # The history of node 4 voltage vs. time is plotted
&&
end;

When the task is completed, the spectrogram of the form shown in Fig.6.1 will be outputted in both printout and graphic format. Fig.6.1 shows the plot that can be seen with ALLTED Plotter.

Fig 6.1. Linear spectrum example.

If directives PLOT or TABLE are used in the task, then the values of the variables computed during
time domain analysis will be printed out in the ALLTED.OUT file.


Chapter 7

Multivariant Analysis (MV)

Multivariant Analysis is carried out as a series of frequency (AC), transient (TR), or steady-state (DC) analyses. In each new run one of the variable parameters is assigned a new value computed as uniformly distributed in the range from its lower boundary to its upper boundary as specified in VARPAR directive. After the first variable parameter passes its range in NUMB steps, the second parameter will be changed while the rest are kept nominal and so on.

The output characteristics are specified with CONTROL, OF (Objective function), and/or LIMIT (Constraint) directives. The results of the multivariant analysis are plotted as the dependence of the output characteristics (response time, overshoot, steady-state error, resonance peak height, etc.), objective function/constraint value against the value of the parameter varied.

MVA analysis is widely used in the initial stages of a design to evaluate the influence of specified parameters on output characteristics. It can be applied before optimization to visualize the impact of objective functions and constraints.

To run multivariant analysis, the task should contain the directives shown in the table below

Purpose |  | Directive
To set the basic analysis type (Domain Type) | Steady-state characteristics | DC
 | Time-domain characteristics | TR
 | Time-domain characteristics with steady-state analysis run first to determine initial conditions | DC TR
 | Frequency-domain characteristics with steady-state analysis run first to linearize object in the vicinity of operating point | DC AC
Adjust the computation |  | CONST
Multivariant analysis setting |  | MVA
Specify variable parameters |  | VARPAR
Specify monitored characteristics |  | CONTROL OF LIMIT
Specify output characteristics |  | FIX INT FUNC

Variable parameters are derived with the VARPAR directive:

VARPAR<par_name>(<lower_bound>,<upper_bound>){,<par_name>(<lower_bound>,<upper_bound>)};

where
<par_name> = variable parameter that can be any linear two-terminal component or any symbolic parameter,
<lower_bound> = lower boundary of the parameter's variation range,
<upper_bound> = upper boundary of the parameter's variation range.
The output characteristics are assigned with the CONTROL directive:

CONTROL <characteristic_name>{,(<characteristic_name>)};

Output characteristic are supposed to be determined with FIX, INT and/or FUNC directives.

In MVA analysis the number of plots and the characteristics that are to be outputted are set implicitly. With the task completed, you will get as many plots as there are variable parameters specified in the directive VARPAR, and each plot will contain of as many curves as many characteristics as listed in the directives CONTROL, OF, LIMIT.

Directive CONST parameters that are used to set multivariant analysis are summarized in the next table. Note, that a time-domain transient analysis, steady-state analysis, and frequency analysis are set with parameters listed in Sections 4.2, 4.3, 4.4. Only two parameters are needed to set the MVA analysis:

Parameter

Purpose

Description
REL (0) To control the value of an argument distributed along X-axes REL = 0 - argument plotted as it is,
REL = 1 - the value of the argument is related to its nominal value,
REL = 100 - in percentage.
NUMB (64) Number of runs to be performed for each variable parameter. The values of variable parameter are distributed uniformly within the range specified by VARPAR directive

Example:

TASK;
DC;
TR;
MVA;
FIX F1=FIXA(VR1,1.0), F2=FIXA(VR1,2.0);
FIX F3=MAXF(VC1);
INT F4=F2-F1;
VARPAR C1(0.001, 0.04), R4(23.6, 345),
ALFA.Q1(0.16,1.23);
CONTROL F3,F4;
CONST NUMB=20, TMAX=100;

Here NUMB defines the number of runs for each of three variable
parameters. The results are outputted in three plots (according
to the number of variable parameters), each of which contains 2
curves (the number of output characteristics listed in the
CONTROL directive), i.e. the following dependencies will be
plotted:

F3(C1) and F4(C1), F3(R4) and F4(R4), F3(ALFA.Q1) and F4(ALFA.Q2).

The MVA operation is very helpful when used before optimization. In fact, without the analysis being thoroughly performed in advance of optimization, the entire success of optimization is doubtful. Without MVA analysis an optimization usually takes much more time and effort. For this reason, ALLTED allows the task prepared for optimization to run as an MVA task simply by replacing the OPTIM directive with the MVA directive. In this case output characteristics are defined with directives OF (Objective function) and LIMIT (Constraint).

Example:

TASK;
DC;
TR;
CONST, TMAX=2.6;
FIX T1=MAXA(IR9.AMP), T2=MINA(IR9.AMP);
INT DELAY=T1-T2;
MVA # used instead of OPTIM
VARPAR C1(0.5,3), GAIN.AMP(6.2,85);
OF RESP=F1(0.14/DELAY);
LIMIT STAB=F1(0.6/T1);
CONST NUMB=25;...;

With the task completed, two graphs will be plotted: in the first
the RESP and STAB will be plotted against C1, in the second one
the same characteristics will be plotted against parameter GAIN.AMP.


Chapter 8

Sensitivity and Worst Case Design

During sensitivity analysis, sensitivity of output variables and/or output characteristics with respect to a given set of the object's parameters in either time (transient or steady-state) or frequency domain can be evaluated.

The most influential parameters are revealed making it possible to substantially simplify the schematic structure design and parameter values search. It is also very helpful to have the results of sensitivity analysis before optimization, optimal tolerance assignment, statistical analysis, and other high-level design operations.

The worst case design takes into account the tolerances of given parameters and after the sensitivities and the most unfavorable combination of tolerances have been determined, computes the nominal, maximum, and minimum values of output variables and characteristics in either the time or frequency domain.

An added advantage of ALLTED is that the sensitivities of output characteristics are computed in addition to the sensitivities of output variables. Output characteristics such as delay time, pulse edge duration, response time, etc are assigned with FIX and INT directives.

A mathematical model of special form is constructed allowing both of these analyses to be performed in one computation run. To adjust the computation, the directive CONST parameters, similar to those described in Sections 5.1 to 5.3 for conventional time and frequency domain analyses, are used.

Directive CONST parameter | Purpose | Default value
SLERR | Acceptable local error level for sensitivity model. Must be equal or greater than LERR | LERR
SXMAX | Maximum variable value in accuracy control | XMAX
SORD | Maximum order of the integration method | ORDER

Only linear one-parameter-defined components are allowed to be variable ones. They are the constant sources ( J and E ) and the constant components ( G, R, C, and L ). The parameters of linear and nonlinear functions cannot be used in the VARPAR directive in either SA or WCD modes.

Sensitivity Analysis (SA)

To run sensitivity analysis, the task should contain the directives shown in the table below.

Purpose |  | Directive
To set the basic analysis type (Domain Type) | Steady-state characteristics | DC
 | Time-domain characteristics | TR
 | Time-domain characteristics with steady-state analysis run first to determine initial conditions | DC TR
 | Frequency-domain characteristics with steady-state analysis run first to linearize object in the vicinity of operating point | DC AC
Adjust the computation |  | CONST
Sensitivity analysis setting |  | SA
Sensitivity is evaluated with respect to the variable parameters specified |  | VARPAR
Specify output variables for which sensitivity is to be evaluated |  | TABLE PLOT TPLOT LPLOT LTPLOT
Specify output characteristics for which sensitivity is to be evaluated |  | FIX INT

Example:

TASK
DC; # Steady-state analysis, used to determine initial conditions
TR; # Time-domain transient analysis
SA; # Sensitivity analysis setting
CONST TMAX=700;#Time span of 700 units is set
#Two output characteristics are set in the directive FIX:
FIX VOLTR1=FIXA(UR1,100), # Voltage on resistor R1 at 100 units of time
VOLTC1=MAXA(UC1); # Maximum voltage on capacitor C1
# Three output variables are specified in the directive TABLE
# (they, with all their sensitivities, will be outputted in table format)
TABLE V1,IR1,UR1;
# Another two variables are set in the directive PLOT to be output in plot format
PLOT V1,IR2;
VARPAR C3,R10; # Capacitor C3 and resistor R10 are set to be variable ones
&
END


Chapter 8

The results of the task can be divided into three parts. In the first part, steady-state values of output variables listed in the directives TABLE and their sensitivities to the variable parameters are printed. If no directive TABLE is used in the task, all the directive PLOT variables with their sensitivities will be printed in this part.

The second part contains transient response results. Directive TABLE output variables and their sensitivities are printed there in table format with the discreteness specified by the directive CONST parameter DITAB. Sensitivities of output characteristics specified in the directives FIX and INT are printed after the output variables.

All the plots are placed in the third part. Each PLOT directive sets n+1 plots in sensitivity analysis, where n is a number of variable parameters. The first one is similar to the plot in conventional TR or AC analysis because it represents nominal values of output characteristics vs. time or frequency. Then the plot with sensitivities of the variables (characteristics) specified in the particular directive PLOT are output as many times as there are variable parameters listed in the directive VARPAR. To avoid ambiguity, each sensitivity is assigned the name:

S<characteristic_name>.<variable_parameter_name>.

Three plots are outputted in the example above. Values of output variables V1 and IR2 vs. time are plotted in the first one. The second plot will contain sensitivities [image] named as S.V1.C3, S.IR2.C3 and plotted vs. time, and the third - [image] named as S.V1.R10, S.IR2.R10.

Sensitivity evaluation of the directive FIX output characteristics of the type MAXA, MAXF, MINA and MINF is performed if extreme points do exist on the specified time interval. The sensitivity values are related to the first local minimum (maximum). If there is no extreme point on the interval, the value of sensitivity will be set to 0.

With large number of output variables and characteristics, a computation failure due to memory limitation may occur. To avoid such a situation, parameters DIPLOT and DITAB, setting storage intervals for plots and tables, are to be set to about 0.01*TMAX.

Example:

The following problem was developed to illustrate Sensitivity Analysis. Electronic active filter RAD1_AC.ATD is described in Section 11.1. Below the task from RAD_AC.ATD is shown to illustrate the text in Section 8.1.

TASK;
DC; # DC analysis is always carried out before AC
AC; # Frequency analysis
SA; # Sensitivity analysis

# Parameters to adjust computation are set in the
# directive
# CONST

CONST LFREQ=0.0025, # Lower frequency boundary
UFREQ=0.005, # Upper frequency boundary
phaseang=-360; # Bode plot phase angle scaling
VARPAR C2,C1; # These parameters are set to be variable
TF KU=V6/UE1; # Transfer function definition
# Output characteristics are listed in the directives FIX and INT
FIX MAXAMP=MAXF(MA.KU),
MAXAMPR=MAXA(MA.KU),
MAXAMP1=MAXF(MA.KU,0.0025,0.0045),
MAXAMPR1=MAXA(MA.KU,0.0025,0.0045),
FMA0_75F=FALL(MA.KU,0.75),
FMA0_75R=RISE(MA.KU,0.75),
FM0_75F1=FALL(MA.KU,5.43,0.0033,0.0044),
FM0_75R1=RISE(MA.KU,5.43,0.0033,0.0044),
FPH0_75F=FALL(PH.KU,-75);
FIX FMA1_55F=FALL(MA.KU,1.55),
FMA1_55R=RISE(MA.KU,1.55);
FIX FMA0_003=FIXA(MA.KU,0.003);
INT WIDTH_55 = FMA1_55F-FMA1_55R,
WIDTH_54=FM0_75F1-FM0_75R1;
# These variables are output in plot format
LPLOT MA.KU,PH.KU(50); # Logarithmic scaling along
# X-axis, amplitude in natural
# scaling, phase in degrees
LPLOT DB.KU,RAD.KU(50);# Amplitude in dB, phase in radians
&
end

With the task completed, the nominal values of output characteristics specified in the directives FIX and INT are printed first. Then output characteristics' sensitivity with respect to each variable parameter is output next. Here the part of the printout of the task shown above is reproduced.


Chapter 8

S E N S I T I V I T Y A N A L Y S I S
(f r e q u e n c y d o m a i n)
********************************
N o m i n a l v a l u e s o f o u t p u t c h a r a c t e r i s t i c s
********************************************************

Directive FIX characteristics:

MAXAM = 9.90489483
MAXAMPR = 0.372304092E-02
MAXAMP1 = 9.90489483
MAXAMPR1 = 0.372304092E-02
FMA0_75F = 0.429366995E-02
FMA0_75R = 0.323725468E-02
FM0_75F1 = 0.379852112E-02
FM0_75R1 = 0.366547192E-02
FPH0_75F = 0.383856473E-02
FMA1_55F = 0.399085227E-02
FMA1_55R = 0.348180067E-02
FMA0_003 = 0.485252053

Directive INT characteristics:

WIDTH_55 = 0.509051606E-03
WIDTH_54 = 0.133049209E-03

O U T P U T C H A R A C T E R I S T I C S S E N S I T I V I T Y
***************************************************************

1. To the variable parameter....C2

Directive FIX characteristics:

S.MAXAMP = 104.587402
S.MAXAMPR = -4081.34286
S.MAXAMP1 = 104.587402
S.MAXAMPR1 = -4081.34286
S.FMA0_75F = -0.171514444E-02
S.FMA0_75R = -0.154213298E-02
S.FM0_75F1 = -0.175108635E-02
S.FM0_75R1 = -0.103452845E-02
S.FPH0_75F = -0.149971584E-02
S.FMA1_55F = -0.195313756E-02
S.FMA1_55R = -0.158098016E-02
S.FMA0_003 = 1.19684971

Directive INT characteristics:

S.WIDTH_55 = -0.372157400E-03
S.WIDTH_54 = -0.716557901E-03

2. To the variable parameter....C1

Directive FIX characteristics:

S.MAXAMP = 138.361191
S.MAXAMPR = -6442.69203
S.MAXAMP1 = 138.361191
S..MAXAMPR1 = -6442.69203
S.FMA0_75F = -0.225732156E-02
S.FMA0_75R = -0.116663477E-02
S.FM0_75F1 = -0.168012398E-02
S.FM0_75R1 = -0.106879573E-02
S.FPH0_75F = -0.211985280E-02
S.FMA1_55F = -0.220299383E-02
S.FMA1_55R = -0.139751630E-02
S.FMA0_003 = 0.774224948

Directive INT characteristics:

S.WIDTH_55 = -0.622013665E-03
S.WIDTH_54 = -0.645595528E-03

Six plots are assigned in the task in question. After the task is completed they can be seen with either ALLTED Plotter or a text editor. The first two contain nominal values of characteristics specified in the directives. Then sensitivity of the first plot characteristics with respect to the first variable parameter (S.MA.KU.C2, S.PH.KU.C2) will be output on the third plot, S.DB.KU.C2, S.RAD.KU.C2 - on the forth, and so on. Below all of them are shown.

Fig 8.1. Nominal characteristics.

Fig 8.2. Nominal characteristics.

Fig. 8.3. Sensitivity of the first characteristics to the first parameter.

Fig. 8.4. Sensitivity of the first characteristics to the second parameter.

Fig. 8.5. Sensitivity of the second characteristics to the first parameter.

Fig. 8.6. Sensitivity of the second characteristics to the second parameter.


Chapter 8

Worst Case Design (WCD)

The Worst Case Design finds the minimum and the maximum values of the output variables and characteristics for the most unfavorable combination of tolerances of given parameters.

These limits are defined by the formula:

where [image] is the vector of variable parameters, [image] is the vector of output variables and characteristics, [image] are the maximum and minimum values of the characteristic, [image] is the tolerances vector (in %), [image] is the sensitivity of the j-th characteristic to the variation of the i-th variable parameter at point [image].
To compute the worst case, the task should contain the directives shown in the table below

Purpose |  | Directive
To set the basic analysis type (Domain Type) | Steady-state characteristics | DC
 | Time-domain characteristics | TR
 | Time-domain characteristics with steady-state analysis run first to determine initial conditions | DC TR
 | Frequency-domain characteristics with steady- state analysis run first to linearize object in the vicinity of operating point | DC AC
Adjust the computation |  | CONST
Worst case design setting |  | WCD
Specify variable parameters whose tolerances are to be considered in the worst case determination |  | VARPAR
Specify output variables whose limits are to be evaluated |  | TABLE, PLOT, TPLOT, LPLOT, LTPLOT
Specify output characteristics whose limits are to be evaluated |  | FIX, INT

The TABLE, PLOT, TPLOT, LPLOT, LTPLOT, FIX, and INT directives list the output variables and characteristics whose limit values are to be determined during WCD analysis.

Each variable mentioned in the TABLE directive will be classified as output one and its nominal, maximum, and minimum values will be determined and printed in output printouts. Prefix 'H.' will be added to the variable name to identify its high boundary value, and prefix 'L.' - its low boundary value. Below the example of the printout is shown where two variables (UR11 and UR5) were specified in the directive TABLE.


Chapter 8

W O R S T C A S E D E S I G N
*********************************

S T E A D Y - S T A T E R E S P O N S E
(D C O P E R A T I N G P O I N T)
*************************************

Iterations 25
Maximum error 0.533051441E-14
Nominal values of variables
UR11 11.2858858
UR5 7.83221102
Variables' upper boundary values
H.UR11 11.2869797
H.UR5 8.25409794
Variables' lower boundary values
L.UR11 11.2847919
L.UR5 7.41032410

T R A N S I E N T R E S P O N S E
*************************************

Tim e 0.1000000E-03 5.099160 10.14483 16.89214 20.74738
Step value 0.1000000E-03 0.3249013 0.2438507 2.0360330.9758575
Number of time steps 0 16 29 38 40
H.UR11 11.28698 11.28730 11.30524 10.64761 10.39963
UR11 11.28589 11.28621 11.22851 10.28949 9.960120
L.UR11 11.28479 11.28513 11.15179 9.931361 9.520613
H.UR5 8.254098 8.254837 8.261002 8.254139 8.254674
UR5 7.832211 7.832919 7.836903 7.832131 7.832142
L.UR5 7.410324 7.411000 7.412805 7.410123 7.409610

The directive FIX and INT output characteristics are printed in table format like this:

W O R S T C A S E D E S I G N R E S U L T S
***************************************************
Directive F I X output characteristics
****************************************

 | Nominal | Minimum | Maximum
VOLTUR11 | 9.56236362 | 9.02994156 | 10.0947857
VOLTUR5 | 7.83221149 | 7.41032219 | 8.25410080
VOLTUR2 | -0.2268E-01 | -0.2454E-01 | -0.2082E-01
VOLTUR4 | 11.0950670 | 10.5083971 | 11.6817369

Each output variable specified in the PLOT directive(s) will be accompanied on the plot by two curves representing its maximum and minimum value change. Prefix 'HB-' is added to the variable name to identify its high boundary value and prefix 'LB-' its low boundary value. To avoid overcrowding, it is suggested that not more then two variables be plotted on one plot. The example below shows one variable (VOLT) specified in the directive PLOT.

Fig. 8.7. Worst Case Design output characteristic example.

The structure of the VARPAR directive is different than that used in the SA analysis. In WCD not only names, but tolerances of each variable parameter must be specified. It takes the form shown below:

VARPAR C1(5), R2(10);
VARPAR R2,R4,R7(3),R12(10);
As specified in the second directive, the resistors R2, R4, R7 have the same tolerances (+3%).


Chapter 9

Optimization

The purpose of optimization in a CAE system is to find the parameter values which meet the demands of the designed object in the best possible way. This purpose is actually the final goal of the entire design process. The rest of the design operations (object description, mathematical model developing and ordering, solution of equations, evaluation and identification of output characteristics during numerous analyses, etc.) are performed primarily to develop the basis for initiating optimization. Optimization's further challenge is to find a satisfactory solution from among competing objectives. This emphasizes the importance of optimization in the CAE system.

Extensive CAD experience has proven that the effectiveness of optimization is much greater if the following options are available to the designer:

- on-line modification of the extent and complexity of the object's mathematical description in order to switch from a less to a more accurate model and vice versa. This should be done by simple means, without writing, developing or rearranging systems of differential or algebraic equations;

- the ability to define the whole variety of output characteristics to evaluate the object: response time, rise time, pulse duration, maximum deviations from the predefined movement trajectory, overshoot, resonance frequencies, phase angles at different frequencies, frequencies at which amplitudes or phases reach their predefined values, etc. It should be noted that during one computation run of a nonlinear object both the time and frequency performances have to be defined many times;

- the ability to present any of the output characteristics or their combinations in the form of an objective function or functional constraints, as well as any system parameter which must be taken as a variable parameter if necessary;

- the ability to easily change the optimization method according to the particular task. The set of methods must cover the entire scope of practical important problems.

In analyzing the previously discussed ALLTED operations, it becomes obvious that all of them are designed to achieve the maximum performance in optimization. Some complexity and redundancy of transient, frequency and steady-state analyses is justified and must be tolerated.

ALLTED is unique in the variety of optimization methods, and in the simplicity of forming of objective functions and constraints.

Although ALLTED can successfully solve a very wide range of problems, experience has shown that the more the user knows about the peculiarities of the object under design and optimization methods, the greater is his probability of success. These methods of optimal design lie in an area of knowledge/experience that are unlikely to be fully automated in the near future.

We recommend that the user browse through the following works:

1. Reklaitis G.V., Ravindran A., Ragsdell K.M. Engineering optimization. Methods and applications, Wiley, N.Y., 1983.
2. Petrenko A.I., Ladogubets V.V., Chkalov V.V. Optimal circuit design in machinery. - Kiev: Vischa shkola, 1989.-164 p.(Russian).
3. Lightner M.R., Director S.W. Multiple criteria optimization for the design of electronic circuit// Trans.IEEE.-1981.- Vol.CAS-28, No.3.-P.169-179.

where the main terminology, optimization methods and results identification ideas are presented.

The methods described in this manual explain only the main ideas and emphasizes the adjustment parameters. For clarification purposes, the terminology here is not always strict in a mathematical sense.

The general optimization process is subdivided into several stages:

- preliminary system study;
- forming of objective (goal) functions and constraints;
- definition of the variation range of parameters;
- optimization method selection,
- task formulation;
- results analysis and method adaptation.

The manual material is presented in the same sequence. Some directives have been already described in other chapters; they are repeated here relative to parametric optimization procedures.

In general the optimization problem may be regarded as a constrained multiple criteria extremes problem
(9.1)
subject to:

where
= variable (or designable) parameters vector;
= the objective functions vector;
= the domain of operability and physical realizability of the system.
The operability domain Ra1 is defined by functional constraints, i.e.

where
= constraints-inequalities vector;
= constraints-equalities vector.
The domain of physical realizability Ra2 is defined by parametric constraints set in most cases as double constraints - inequalities [image] . Strictly speaking, the parametric constraints are a subset similar to functional ones and their usage as a separate group is caused by task formulating convenience and traditions.


Chapter 9

The optimization problem in the form (9.1) is a general multiple criteria nonlinear optimization problem, and its solution requires maximum resources. Depending on the number of objective functions and their type, on the presence or lack of constraints and their type, etc., the problem may be reduced to some specific form and solved more effectively. The ALLTED optimization module can handle problems in the form (9.1) as well as in the all reduced forms:

- constrained single criteria nonlinear programming problem
(9.2)
subject to

where

f(x) = scalar objective function which can be either one of the functions from (9.1) set (while the rest are converted in a constraint form) or so called a weighted sum objective function

yielded from objective functions vector and a weight vector:

to reduce problem (9.1);

- constrained nonlinear minimax problem
(9.3)
subject to

- unconstrained single objective optimization
(9.4)

- unconstrained minimax problem
(9.5)

The simpler the problem the less effort is needed to reach the optimal solution. The most popular approach for problem simplification is to convert constrained problems (9.1)...(9.3) to unconstrained ones with the aid of penalty function. Penalty function can convert both functional and parametric constrains into objective function form.

Parametric constraints are inevitable in an object design. They are due to physical and technological limitations imposed on system parameters and can be easily defined at the task formulation stage. Moreover, after the first runs the user acquires information as to the remoteness of the optimum from the Ra2 region boundaries. And if one or several of the variable parameters is in the vicinity or on the border, it is advisable to check the border's validity once more.

It is a rather rare case when the optimum is in the vicinity of Ra2 border. That is why ALLTED parametric constraints are always dealt with as a penalty function
(9.6)

where Kp is the penalty coefficient in the range of 103...104. Function (9.6) equals zero in the feasible region of parameters and for all practical purposes doesn't affect the search strategy.

Functional constraints can be taken into account with penalty function as well
(9.7)
where Kp is a penalty coefficient. However this approach can slow down the process considerably and in ALLTED is used for a random search only.
As a rule there is no need to use functional constraints in multiple criterion problem formulation. Any of the constraints can be converted easily in the objective function form

where
Bo, Ao = predetermined values for constraints-equalities and inequalities.
The following steps should be taken to define the optimization task and to formulate it in terms of the ALLTED input language:

1. Define the design objectives of the object and transform them into the objective functions form.
2. Select the variable parameters and set the parametric constraints.
3. Set (if necessary) the functional constraints.
4. Set the task solution method and adjust it for a specific problem.
To run optimization problems, the following directives can be used:

Purpose |  | Directive
To set the basic analysis type (Domain Type) | Steady-state characteristics | DC
 | Time-domain characteristics | TR
 | Time-domain characteristics with steady-state analysis run first to determine initial conditions | DC TR
 | Frequency-domain characteristics with steady-state analysis run first to linearize object in the vicinity of operating point | DC AC
Adjust the computation |  | CONST INSTALL
Optimization setting |  | OPTIM
Specify output characteristics |  | FIX INT FUNC
Specify objective functions |  | OF
Specify constraints |  | LIMIT
Specify variable parameters |  | VARPAR
Specify output characteristics in plot format |  | PLOT LPLOT

The directives OF, LIMIT, and VARPAR are considered below.


Chapter 9

Directive OF (Objective Function)

OF <obj_name> = <func_name>(<parameter_list> / <argument_list>) {,<obj_name> = <func_name>(<parameter_list> / <argument_list>)};

where
<obj_name> = name of the objective function,
<func_name> = name of the ALLTED intrinsic function used to compute an objective function,
<parameter_list> = parameter list in accordance with the syntax of a particular intrinsic function,
<argument_list> = list of arguments in accordance with the syntax of aparticular intrinsic function.
Any outputcharacteristic determined in the directives FIX, INT, FUNC, any symbolic parameter and linear
two-terminal component can be the argument of the objective function.

Objective functions are quite different as to their meaning yet similar as to their form. These forms (patterns) are gathered together in a special library and can be used to simplify the task preparation. This set of intrinsic functions covers the overwhelming majority of cases. If not, the special subprogram, USOBJ.FOR, has been developed to extend the library (Section 12.4).

In the table below the functions now available are listed. All of them (except F6, F7, F9, F13 and F14) can form an additive objective function and can be used when a weighted sum method to solve multicriterion problem is employed. The patterns F6, F7, F9, F13 and F14 are designed to form so-called maximum objective functions to match conventional and minimax optimization methods. The pattern F10 is designed to be used with the multicriterion LP -search.

In the table x1, x2,...,xn stand for arguments that can be any output characteristic determined in FIX, INT, FUNC directives, any symbolic parameter or any linear component. The symbols PV1, PV2,... denote preset values of the characteristics (arguments) x1, x2,... which must be reached as a result of optimization.

Symbol D stands for the tolerance; K1, K2,...,Kn - weight factors; Zmin, Zmax - lower and upper values of the objective function to mark feasible region in LP? - search.

Functions F1, F2, F3, F4, F5, F8, F11, F12, F15 and F16 can form an additive objective function in itself if number of arguments is greater than 1. An additive function can be formed as a combination of any functions listed in Table 9.1 if two or more objective functions are inserted in the task and a optimization method for single criterion problem is employed.

If only F6, F7, F9, F13 or F14 function is used alone and the method for minimax optimization is defined, then each pair of PV and argument forms a separate criterion. Otherwise these functions contribute only one element each to the overall criterion.

Example:

Write an objective function to evaluate the quality of the transient response of the variable U1 if its desirable form is given in the table:

time | 0.1 | 0.3 | 0.5 | 0.7 | 1
U1 | 0.4 | 1.6 | 2.8 | 3.9 | 4.3


Chapter 9

Intrinsic functions to compute objective functions
Table9.1

No | Description | Syntax
1 |  | F1(PV1,...,PVn/x1,...,xn)
2 |  | F2(PV1,...,PVn/x1,...,xn)
3 |  | F3(D,PV1,...,PVn/x1,...,xn)
4 |  | F4(PV1,...,PVn/x1,...,xn)
5 |  | F5(K1,...,Kn/x1,...,xn)
6 |  | F6(PV1,...,PVn/x1,...,xn)
7 |  | F7(PV1,...,PVn/x1,...,xn)
8 |  | F8(PV1,...,PVn/x1,...,xn)
9 |  | F9(PV1,...,PVn/x1,...,xn)
10 |  | F10(Zmin,Zmax,K1,...,Kn / x1,...,xn)
11 |  | F11(K1,PV1,...,Kn,PVn/ x1,...,xn)
12 |  | F12(K1,PV1,...,Kn,PVn/ x1,...,xn)
13 |  | F13(K1,PV1,...,Kn,PVn/ x1,...,xn)
14 |  | F14(K1,PV1,...,Kn,PVn/ x1,...,xn)
15 |  | F15(K,PV1,...,PVn/ x1,...,xn)
16 |  | F16(K,PV1,...,PVn/ x1,...,xn)
17 |  | F17(PV1, D 1,...,PVn, D n / x1,...,xn)


Chapter 9

With the aid of the FIX directive the values of U1 must be determined at the given time instant.

FIX X1 = fixa (U1, 0.1), X2 = fixa (U1, 0.2),...,
X5 = fixa(U1,1.0);

Then objective function can be written in several ways:
a) OF QUALITY = F2 (0.4,1.6,2.8,3.9,4.3/X1,X2,X3,X4,X5);
b) OF Q1 = F1 (0.4/X1), Q2 = F1 (1.6/X2), Q3 = F1 (2.8/X3)
Q4 = F1 (3.9/X4), Q5 = F1 (4.3/X5);

If single criterion optimization method is used, the objective function will be calculated as Q1 + Q2 + Q3 + Q4 + Q5 and the result will be marked with the name of the first objective function (Q1 in question). If multiple criterion method is set all the functions are treated separately.

c) OF QUALITY = F6 (0.4,1.6,2.8,3.9,4.3/X1,X2,X3,X4,X5);

If minimax method is used, the objective functions named QUALITY(1),...,QUALITY(5) are formed. Otherwise scalar criterion is determined:

QUALITY = : max [(0.4-X1), (1.6-X2), (2.8-X3), (3.9-X4), (4.3-X5)].

Example:

Write an objective function for the task with three design criteria:
Delay Ј 0.1 (us)
Power Ј 200 (mW)
0.95 Ј Resonant frequency Ј 1(MHz)

It can be done by:
OF, GF1=F4(0.1/DELAY);
OF, GF2=F4(200/POWER);
OF, GF3=F3(0.025,0.975/FRES);

where DELAY, POWER, FRES are to be determined by the directives FIX, INT and FUNC.


Chapter 9

Directive LIMIT. Constraints Definition

Constraints are used in addition to the objective functions to set requirements to the object which are expressed by equalities and/or inequalities
where

f(x,y) = function of the variable parameters and secondary variables;
C, D, B = the predetermined values which must be satisfied.
Here are some examples when constraints are necessary:
1. When we wish to improve the object stability by changing the parameters set in the VARPAR directive but keep the overshoot less than a predefined value.
2. To define circuit component parameters providing a minimum time delay, but power consumption must be equal to a predefined value.

The ALLTED methods of optimization need the constraints to be arranged in the form:
equalities

inequalities

Example:

The demand to keep an output characteristic (in our example, PRESS) equal to some preset value (for example, 25) must be presented by the constraint- equality (for example, G1) in the form

G1 =¦ PRESS - 25 ¦.

The constraint is considered to be satisfied if G1 is less than CONERR - the directive CONST parameter arranged to control the accuracy of optimization. The demand to keep an output characteristic (for example, DECAY) less then preset level (for example, 0.0025) must be presented by the constraint-inequality (named for example, RESPONSE) in the form

RESPONSE = DECAY - 0.0025.

The constraint is considered to be satisfied if RESPONSE is negative or less than parameter CONERR. The demand to keep an output characteristic (in this example, EFFICIENCY) greater then preset value (assume 0.75) must be presented by the constraint-inequality (here named, ENERGY) in the form

ENERGY = 0.75 - EFFICIENCY.

The constraint is considered to be satisfied if ENERGY is negative or less than parameter CONERR.

The syntax of the directive LIMIT is:

LIMIT <con_name> = <func_name>(<parameter_list> / <argument_list>){,<con_name> = <func_name>(<parameter_list> / <argument_list>)};

where

<con_name> = name of the constraint,
<func_name> = name of the ALLTED intrinsic function used to compute a constraint,
<parameter_list> = parameter list in accordance with the syntax of a particular intrinsic function,
<argument_list> = list of arguments in accordance with the syntax of a particular intrinsic function. Any output characteristic determined in the directives FIX, INT, FUNC, any symbolic parameter and linear two-terminal component can be the argument of the function.

In the Table 9.2 the intrinsic functions developed to compute constraints are listed. Numbers from 1 to 249 are reserved for constraints-equalities, and from 250 to 499, for constraints-inequalities. In the table, PV stands for "Predetermined Value", x - argument of the constraint (any output characteristic determined by the FIX, INT, FUNC directive, any symbolic parameter or name of the linear component), K - coefficient, D - tolerance.

Example:

LIMIT GF = F252 (0.1 / DELAY);
The constraint-inequality (the number is more than 249) is calculated as GF = DELAY - 0.1.
The constraint is satisfied when GF < 0 or DELAY < 0.1.


Chapter 9

User-defined Objective and Constraint Functions

In the extended version of ALLTED the subprograms USOBJ.FOR and USGRAN.FOR are available to extend libraries of objective functions and constraints.

Table 9.2

Functions to compute constraints

Constraint | ALLTED representation | Syntax
x = PV | g = PV - x, | F2 (PV / x)
x / PV = 1 | g = (PV - x) / PV | F3 (PV / x)
(PV-x)/(1+PV)=0 | g = (PV - x)/(1 + PV) | F4 (PV / x)
1/K x = 1/K PV | g = K (PV - x) | F5 (K, PV / x)
1/K x1= 1/K x2 | g = K (x1 - x2) | F6 (K /x1, x2)
x [image] PV | g = PV - x | F251 (PV / x)
x Ј PV | g = x - PV | F252 (PV / x)
x/PV Ј 1 | g = (x - PV) / PV | F253 (PV / x)
x/PV [image] 1 | g = (PV - x) / PV | F254 (PV / x)
K x [image] K PV | g = K (PV - x) | F255 (PV, K / x)
K PV [image] K x | g = K (x - PV) | F256 (PV, K / x)
K (x1 + x2 - x3 - x4) Ј 0 | g = K (x1 + x2 - x3 - x4) | F257 (K / x1, x2, x3, x4)
(D+x)/PV=1 |  | F258 (D, PV / x)
D+x [image] PV |  | F259 (D, PV / x)


Chapter 9

Variable Parameters. The VARPAR Directive

Any parameter of the designed object can be taken as variable: resistances, conductances, source values, parameters of nonlinear components in electronic, hydraulic, mechanical, etc. circuits. The VARPAR directive states the variable parameters list and their variation limits (parametric constraints):

VARPAR <var_par> {=<var_par>} (<low_b>, <upper_b>[,<list_number>]){,<var_par>{=<var_par>}(<law_b>, <upper_b>[,<list_number>])};

where

<var_par> = variable parameter name,
<low_b ><upper_b> = lower and upper boundaries of the variable parameter variation range,
<list_numb> = number of list in the DISCOPT.EXE module.

The following parameters can be used as variable ones:

- any symbolic parameter mentioned in a list of parameters;
- any linear component in the main or nested models except linear dependent sources.

Example:

VARPAR GAIN.AMP.H5(16.7,34.2),BETA.TR3(0.06,0.17),...;

Two variable parameters are specified in the directive: symbolic parameter GAIN of the model AMP nested in the model H5 and symbolic parameter BETA of the model TR3.

Example:

VARPAR R1 (1.E-3, 6.E-3), EIN.OPAMP2.H5 (4.0,16,5),
GEM (7.3E-3,15.6E-3);

Components R1 (resistor of the main model), EIN (constant voltage source of the model OPAMP nested in the model H5, and CEM (capacitance of the main model) are stated as variable parameters in the directive.

If the parameters of a nonlinear component or a linear dependent source of a main or conventional nested models must be taken as variable, the equivalent circuit has to be changed to convert the parameters in question into symbolic ones.

The directive VARPAR is designed to handle synchronous variable parameters, the parameters with the same boundaries, the parameters which can take discrete values, etc. (for details see Section 2).

Example:

VARPAR m.Q6=CM(8.2,16.4);

The parameter m.Q6 varies synchronously with parameter CM. Only one of these parameters is inserted in the vector and its variation during the optimization procedure will cause the variation of the related parameters.

Due to technological and other restrictions, variable parameters must often be rounded to the next higher or to the next lower tabulated values. To avoid an intuitive decision as to which one is the better choice, two methods of discontinuous, discrete optimization have been designed in ALLTED (see Section 9.6.1). For these methods the directive VARPAR specifies the list of tabulated values for each variable parameter by means of the third figure in parentheses

VARPAR DIAM1.PIPES1 (0.5, 2.26, 1),
DIAM.PIPEEX2 (0.7, 2,40, 2),
MASS.DR3 (0.12, 0.6, 0).

The first two variable parameters mentioned in the directive are supposed to be discrete because there are three figures in the parentheses. The third figure specifies the number of a parameter list in which a set of predetermined values for a given variable parameter is stored. If some parameter(s) is to be continuous, the number of list must be set equal to zero. The parameter DIAM1 of the model PIPES1 can take any value out of set 1, and parameter DIAM of the model PIPEEX2 out of set 2. The figure 0 in parenthesis after parameter MASS specifies continuous range of variation.

Such a form of variable parameters specification must only be used with appropriate methods of optimization and vice versa.

To maintain the file with predetermined values lists, the module DISCOPT.EXE has been developed where up to 15 tabulated lists can be stored, edited and/or retrieved. The module operates in dialogue mode and is supplied together with the optimization block.

Example:

VARPAR PIPEDIAM.P1(1.4,2.6,3), PIPEDIAM.P2(1.4,2.6,3),PIPERETD.P1(2.0,3.6,7), EPRSUP(180,210,0);

The third parameter in the parenthesis will force an optimization method to choose the value of the parameter only from the list of parameters stored in the module DISCOPT.EXE and specified by the number referred to by the parameter. No constraints are imposed (within variation range) on the variable parameter value if its list number is marked with 0 (zero). All variable parameters have to be specified by three values in parenthesis for this kind of optimization.

Example:

VARPAR RIN(3.0,9.5), R1=R2,
TIMECON.SUM(1,2.2), GAIN.QLAG(6,12);

Four groups of variable parameters are specified in the directive: the first group comprises component RIN; the second, R1 and R2; the third, TIMECON.SUM; and the fourth, GAIN.QLAG. The value of RIN can vary from 3 to 9.5, and that of R1, R2, TIMECON.SUM, from 0.01 to 0.22. The variation limits of parameter GAIN are constrained to 6 ... 12.


Chapter 9

Search Termination Criteria

The optimization problem formulation also comprises the formulation of the termination criterion. The process is terminated if:

1. The specified solution accuracy is reached.
2. A good solution is not reached yet, but the convergence velocity decreases, so that further calculations are useless.
3. The method diverges or is in infinite cycle.

The stop criteria are specific for each type of optimization problem and depend on the properties of the objective function, the constraints and the method of optimization. ALLTED uses unified criteria for all methods, simplifying their definition and making method interchange easier.

There are two common types of optimization problems dealt with by ALLTED. These are approximation and minimization. The purpose of the approximation is to reach a predefined characteristic. The objective function F(x) is derived to evaluate the proximity between given and current values of characteristic. With F(x) = 0 the characteristic matches its predetermined value perfectly. The termination criterion for the approximation problems are selected as follows:
21 (9.8)

where
= parameter to control the accuracy of the solution (OPERR),
k = step number,
= parameter used to evaluate the speed of the OF change, [image] =100 [image] ,
= parameter used to control constraints satisfaction accuracy (CONERR),
= parameter used to control the velocity of the variable parameters change
= maximum constraints violation on the k-th step

N = number of constraints equalities,
M = number of constraints inequality.

The problem is assumed to be solved successfully if the first and forth conditions in (9.8) are satisfied. If not, the second and the third conditions are checked and a decision is made whether to continue or to terminate the process.

Minimization is used to improve stability, response time, power consumption and other similar objectives the desired value of which can not be predicted beforehand. Solution accuracy in this case is judged by the objective function increment in two consecutive steps:

(9.9)

The optimal solution is assumed to be found if the first and the third conditions in (9.9) are fulfilled. If not, the second condition is checked to decide whether to proceed or stop the search. If the main conditions in (9.8) or (9.9) are satisfied the solution is marked as "OPTIMAL" in output results. Otherwise the results of optimization are named as "Object status at last point".

Parameter [image] in (9.8) and (9.9) corresponds to the key parameter OPERR (1.E-6) in the directive CONST, and parameter [image] - to the parameter CONERR (0.01). The default values of the parameters are given in parentheses.


Chapter 9

Methods of Optimization

In this section ALLTED optimization methods are discussed briefly. Main features of the algorithms and their controlling parameters are emphasized to simplify the solution of the specific problems.

The selection of an optimization method is done with the METHOD parameter of the CONST directive. In the Table 9.3 which concludes the section, the appropriate values of the parameter are listed.

Random Search Optimization Method

The strategy of the random search method with step-by-step search interval shrinkage (RSIS) is based on a series of N tests in each of which the variable parameters acquire some values out of a uniformly distributed set in a predefined region:

where

= random multiplier, generated by a uniformly distributed values generator [image];
k = number of the test (search step).

The variable parameters can take some discrete value out of the special parameters list stored in the file DISKOPT.DAT. In this case the generated variable parameter value is rounded to the nearest value out of the specified list of parameters.

Two versions of uniform distribution are available: the conventional one and more sophisticated so called LP-tau distribution (see Sobol I.M., Statnikov K.B. Optimal parameters search in multiple criterion optimization. - Moscow: Nauka, 1981. - 107 p. (Russian)).

The quality of distribution of the last one is much higher but the number of tests must be restricted to N=2z integers only i.e. 8,16,32,64,128,256,... It could cause some excessive computations because the optimal number of tests usually lies in the range of 64...125.

At each test the result of the OF evaluation is compared to some specific threshold value [image], if [image] the test is considered to be successful and the boundaries of a new search region are found to shrink the intervals:

where z - is the number of successful tests.

At the first step the search region is set by parametric constraints. When the number of successful tests is greater than 5 the termination conditions are checked. The minimum OF value at the k-th step is taken as the threshold value at the (k+1) step.

For constrained optimization problems the objective function is formed in accordance with the equation (9.7).

Four RSIS modifications are available:

METHOD=40 (RSIS) conventional uniform distribution, no
restrictions are imposed on the variable parameter values;
METHOD=50 (RSIS-D) conventional uniform distribution, the values
of the variables parameters are taken from the special lists
(discrete values of the variable parameters);
METHOD=60 (RSIS-LP) LP-tau distribution, variable
parameters values are continuous in the interval;
METHOD=70 (RSIS-LP-D) LP-tau distribution, discrete values
of the variable parameters.
For METHOD=50 and METHOD=70 the directive VARPAR is
slightly different. In parentheses the boundaries values must be
followed by the third figure specifying the number of the list of
the parameters in the file DISKOPT.EXE (see Section 9.4).

Example:

VARPAR D1.PIPE (1.8, 6.37, 6), DIAM.PIPE2 (0.3, 1.84, 8);

The parameter D1 of the model PIPE can take values specified in the sixth list of parameters while DIAM.PIPE2 - in the eighth.

If some variable parameter must be continuous when METHOD=50 or METHOD=70 is used the number of the parameter list is set equal to zero. Note that the all variable parameters must be followed by parentheses with three parameters if discrete optimization is initialized.

A notable difference between the random search method and deterministic ones are its robustness and capability to detect a global optimal solution. But this kind of methods are extremely time consuming. In average it takes 350...400 computational runs to find a proper solution.

An efficiency of the RSIS is greatly dependent on the remoteness of the optimal point. The closer to the optimal point the trajectory the less the efficiency becomes. That's why the search in ALLTED is terminated when number of steps exceeds 5 regardless the values of the termination criteria. As a rule a thorough analysis must be undertaken at this stage in order to decide on the method of optimization, values of the boundaries parameters of the directive CONST, etc.

The parameters NUMB and OPERR are most influential for RSIS adjustment. The default value of the NUMB is 64, good results were obtained for N=32 and even for N=16 apparently. It isn't recommended to set the value of OPERR less than 0.01, as the efficiency in the vicinity of the optimum is very low and more effective composite methods are available.


Chapter 9

Variable order optimization method (VOM)

This class of methods is based on the idea of using the high order derivatives (up to forth) to form the search trajectory. The order of the derivatives is changed automatically at each step according to the tendency to reach the maximum descent. Thus the methods can be adapted to the particular conditions in order to obtain the maximum rate of convergence and robustness.

The single criterion nonlinear constrained minimization problem (9.2) is slightly changed to be handled with variable order methods

25 (9.10)
subject to

where
is an auxiliary variables vector arranged to convert constraints - inequalities to equalities.

The coordinates of the optimal point x* are determined by a straightforward solution of the Kuhn-Tacker problem, without creating and solving auxiliary subproblems:
(9.11)
where [image] is the Lagrange's function derivatives with respect to x vector (Lagrangian):

= Lagrange multipliers vector.

The methods are a generalization of quasi-Newton optimization methods, in which the solution of (9.10) is sought for as:
(9.12)

where
hS ( [image] ,dS-1 ) = vector polynomial of a scalar parameter [image] ,
s = maximum order of the Lagrangian derivatives used;
d = parameter used for derivatives estimation.

Second order derivatives are calculated according to the formula of Broyden-Fletcher-Goldfarb-Shanno (BFGS), and the third and fourth order ones- according to the relationship:

where H is the Hessian matrix estimation.

The first Lagrangian derivatives is estimated using the increment method.
The starting step is performed with the first order method for which H(0)=I (unity matrix) and equation (9.12) acquires a form:
corresponding to the steepest descent method for constrained problems. Beginning from the second step, the values dsk(s=2,3,4..) are estimated step-by-step until for some s=p the following condition is satisfied:

Then hp-1( [image],d) is taken as hs( [image],d). If p-1 [image] 2,then p-1=2 is assumed.

If the condition is not satisfied for p=4 h4( [image],d) is used instead of hs( [image],d).

If, using the selected type hs( [image], d) the Lagrange function can not be decreased, the step is made in the h1( [image] ,d) direction. If this attempt is not successful either, the optimization process is stopped and it is necessary to change the initial point or the optimization method.

The value of the [image] set on the basis of current situation analysis and the search history. It is set equal to 1 if h3( [image],d) is used to estimate x(k+1). It is also taken equal to 1 if hs(,d)=h2(,d) and the following condition is valid:

33

In the rest of cases the one- dimensional line search based on "golden section" method is used to find [image] .
The accuracy of the line search is controlled by the [image] parameter (LSERR) which is the relative decrement of two successive Lagrangian values:
(9.13)
where k is the number of the line search step.
A considerable reduction of the number of the line search steps is a major advantage of the VOM methods as compared to, for example, conventional quasi-Newton ones. The variable order methods combines advantages of both the steepest descent and quasi-Newton methods.

Three modifications of VOM are available in ALLTED differing by the formula for the Hessian matrix estimation:

METHOD = 100 (VOM - DFP) - Davidon-Fletcher-Powell formula;
METHOD = 110 (VOM - B) - Broyden formula;
METHOD = 120 (VOM - BFGS) - formula of Broyden-Fletcher-Goldfarb-Shanno is used.
The MAXORD parameter of the CONST directive sets the maximum order of the method, and setting MAXORD=2 results in a quasi-Newton method application instead of a corresponding VOM.

To control optimization process with VOM the parameters LSERR, CLEAR, MAXORD and INCR of the directive CONST are designed (see Table 9.4).


Chapter 9

The LSERR (the acceptable error to terminate the line search) is highly influential on the number of steps. For constrained problems the error is calculated in accordance with (9.13), for unconstrained ones - with the relationship

where
j = line search step number,
= parameter LSERR.

The parameter should be chosen in the range 0.01...0.0001. Small values suit problems with many variable parameters (n ? 5) and METHOD = 100, 110. The method = 120 is the least sensitive to line search accuracy. This is why even 0.05...0.01 could be the best choice. The more the number of variable parameters the less the value of LSERR must be.

With VOM and conventional quasi-Newton methods the situation could occur when the rate of convergence is decreased drastically despite the feeling that the process can go on. As a rule, this situation is caused by the error accumulated during the Hessian estimation. ALLTED deals with the problem by starting the iteration process again after

N = n CLEAR

steps and setting Hessian estimating matrix to unity ( n - number of variable parameters, CLEAR -parameter of the directive CONST). The default value of CLEAR is 10, although for some problems with complex responses optimal value of the parameter CLEAR is in the range 2...5. When CLEAR is set to 0 the steepest descent method is kept constantly.

The gradient components are estimated numerically according to the formula

where [image] is the increment of the i-th variable parameter, calculated as [image] is a constant coefficient. The empirical value is 0.0001, which can be changed by the INCR parameter of the directive CONST. This parameter [image] is arranged to moderate the influence of numerical errors during gradient estimation. It is highly desirable to run the MVA analysis first, before the optimization, in order to acquire information about the objective function/variable parameter relationship. For smooth surfaces the parameter INCR should be of 0.0001...0.001 value. Otherwise the value 0.001...0.008 is recommended. The INCR default valve is set to 0.0001.

Generally the METHOD = 120 is the most efficient, but if it fails or the rate of a convergence is thought to be higher try METHOD = 110 and METHOD = 100. Practically 10...15% attempts will be successful.

The termination criteria for approximation with VOM are analogous to (9.8). If at some step the first condition of (9.8) is violated while all other conditions are satisfied, a switch to the steepest descent method is made. If after this procedure the desired accuracy can not be reached, the operating point is automatically shifted away from x(k):

36

and the message is generated in the optimization results printout.

The same automatic resetting of the operating point is performed in minimization if VOM can not find the feasible VARPAR values satisfying the functional constraints.

And finally, even if METHOD = 120 or METHOD = 220 is specified, an optimization starts with RSIS because it is possible that the secondary variables computed by the directive FIX functions FRISE or FFALL do not exist. Then the value of 1.E25 will be assigned to the objective function in which this variable is used as argument. The situation could be very critical for deterministic methods like VOM or MAFS. This is why RSIS is initiated first no matter which method is specified. If the objective function is less than 1.E25 the control will be passed to VOM or MAFS after the first iteration. If not, RSIS will be kept running until the acceptable combination of parameters are encountered.


Chapter 9

Composite Optimization Methods

The efficiency of the RSIS and VOM methods is largely dependent on the distance of the operating point from the optimal one. The larger the distance the more effective RSIS becomes while VOM loses its advantages considerably. To moderate disadvantages of both, the composite methods have been developed. They are designed to combine the robustness and ability to detect a global minimum of RSIS and high efficiency of VOM in a vicinity of the optimal point.

Three composite methods are available in ALLTED:

METHOD = 130 (RSIS + VOM-DFP);
METHOD = 140 (RSIS + VOM-B);
METHOD = 150 (RSIS + VOM-BFGS).

All the composite methods comprise the random search as the first stage and one of the VOM methods as the second stage. RSIS at the initial optimization steps increases the reliability of the global minimum detection, cancels the smoothness of surfaces limitations in a wide parameter range, and increases the general reliability of obtaining the optimal solution.

RSIS passes the control to VOM when the following condition is satisfied
37 (9.15)
with parameter [image] assigned the name SWERR in the CONST directive to control the error at which the switch over occurs.

The SWERR default value is 0.01. As a rule, an attempt to reach a more accurate solution at the first stage of composite methods is extremely time consuming. On the contrary, with SWERR greater than 0.1...0.15 the VOM could start at a great distance from an optimal point and the number of iterations increases rapidly again.

On the statistical basis, not more than three steps of RSIS is necessary to reach an optimal value of the switching over error. This is why the control is passed to VOM after three RSIS steps regardless the value of SWERR.

The most efficient method among the composite ones is METHOD = 150, which, in practice, always converges to the optimal solution of a correctly stated optimization problem. The default CONST directive METHOD parameter is 150.


Chapter 9

Multiple Criterion Optimization

Generally an object is estimated by a few objectives. An attempt to find optimal parameters as a solution of the single criterion optimization problem needs distribution of objectives between constraints and the only objective function. As a rule this distribution is performed intuitively due to the lack of information about the attainable limits of constraints, the influence of constraints on a feasible region, the most influential variable parameters, the correlation coefficients between objectives, etc.

To collect more information, the optimization must be carried out repeatedly, varying limits of the constraints, initial points, objective functions, etc. It does need time and resources. To solve the problem, the exhaustive multiple criterion method is installed in ALLTED.

The method is based on the results of Sobol I.M., Statnikov R.B. and is literally the straightforward exhaustive method. To moderate the main disadvantage of this type of method (the necessity of very large number of computational runs), the authors proposed a new type of uniform distribution and proved that the quality of the distribution was superior to the conventional one. The distribution was called "LP-tau distribution" and the method, "LP -search".

The LP-search starts with the performing of a series of N tests at each of which the variable parameters take some values out of the feasible parameters space in accordance with the LP-tau distribution. The values of the objective functions and constraints (if any) are generated as a result of the tests and the objective function values together with numbers of test are arranged and printed in ascending order (Fig.9.1). Because of space limitations, Tables 2...4 are abbreviated. For a typical engineering practice an actual table would be many times greater this length. With the first stage completed, the user is asked to input the filename in order to store the results on the disk.

TABLE 2. Objective functions and test numbersarranged in ascending order

Accuracy | Test | ZONE | Test | LEAKAGE | Test
2.26951E-01 | 14 | 3.24139E-01 | 10 | 1.94739E+00 | 51
3.48541E-01 | 41 | 3.24329E-01 | 24 | 1.95474E+00 | 17
3.92776E-01 | 1 | 3.27123E-01 | 29 | 1.95524E+00 | 34
. . . . . . | . . | . . . . . . | . . . | . . . . . . | . .
2.91124E+00 | 60 | 4.73012E-01 | 32 | 2.02166E+00 | 1

Correlation Coefficients

ObjectIve functIon numbers
№ | Name | 2 | 3 | 4 | 5 | 6
1 | ACCURACY | 0.86994 | 0.89246 |  |  |
2 | ZONE | ---- | 0.97879 |  |  |
3 | LEAKAGE | ---- | ---- |  |  |

TABLE 3. Acceptable Solutions

№ | Test | 14 | 41 | 1
1 | ACCURACY | 2.26951E-01 | 3.48541E-01 | 3.92776E-01
2 | ZONE | 4.10240E-01 | 4.75956E-01 | 4.31668E-01
3 | LEAKAGE | 2.02692E+00 | 2.05953E+00 | 2.02166E+00

Table 3A. Acceptable Solutions. Variable Parameters Set

Test№ | S1.QC | B.SV | OTKP.SV
14 | 7.6500E+01 | 1.6175E+00 | -9.3687E-05
41 | 7.7625E+01 | 1.6381E+00 | -2.2672E-05
. . . | . . . . . | . . . . . | . . . . . .
13 | 7.8500E+01 | 1.6475E+00 | -1.7937E-05

TABLE 4. Noninferior solutions.
Objectivefunctions and constraints

№ | Test | 14 | 1 | 58
1 | ACCURACY | 2.26951E-01 | 3.92776E-01 | 4.35673E-01
2 | ZONE | 4.10240E-01 | 4.31668E-01 | 5.34531E-01
3 | LEAKAGE | 2.02692E+00 | 2.02166E+00 | 2.01386E+00

Fig. 9.1. Example of LP-search output results.


Chapter 9

Data stored in the output tables (Fig.9.1) allow the object to be analyzed thoroughly. The user can find out resources and limit values of any objective function or constraint. For instance the objective ACCURACY takes minimal value of 2.27 E-1 at the conditions of the test 14, ZONE can reach 3.24 E-1 (test 10), LEAKAGE has minimal value of 1.947 at test 51, etc. (the values are taken from the output results of the example BPHD_OPT.ATD).

As the result of the analysis, the criterion constraints should be assigned to each objective function and the acceptable error for constraints violation (parameter CONERR) has to be specified. For instance, the solution is supposed to be good if (see Fig.9.1):

0 Ј ACCURACY Ј 0.44;
0 Ј ZONE Ј 0.055;
0 Ј LEAKAGE Ј 2.02.

The criteria constraints are specified with the aid of the function F10 (Table 9.1). For the example in question the objective functions must be written as

# Function F508 similar to F10. It computes the maximum error
# between output characteristics and their specified values
# and assigns its value to ACCURACY
OF ACCURACY = F508(0.0, 0.44, 1, 21.66, 17.20, 11.20, 42.37,
33.36,21.26/ VEL1, VEL2, VEL3, VEL4, VEL5, VEL6),
ZONE = F10(0, 5.5, 100/DEADZONE),
LEAKAGE = F10(0, 2.02, 1/LOSSES);

With LP-search, any first two parameters in the objective function description are considered to be criterion constraints.

Having specified the constraints, the second stage of the LP-search can be carried out. At this stage the acceptable solutions are chosen first among the values stored in the file. The region [image] in the feasible parameters space is considered acceptable if

where Cmin, Cmax are the criterion constraints, i.e. the acceptable region is formed of tests all objective functions of which satisfy the criterion constraints. If there are some functional constraints in the task, the demand

gmax Ј CONERR

will be imposed additionally, where gmax is the maximum violation of the constraints.

If criterion constraints are assigned too stringent, the acceptable region could be empty and the user will be asked to change some of the limits.

As the acceptable region is formed, the noninferior points are detected among them. The noninferior points x* (Pareto points) are the points at which [image] does not exist, such that:

The image of a noninferior point in a objective function space is a noninferior solution (Pareto solution).

The results of the second stage is shown in the TABLE 3, TABLE 3A, TABLE 4 (Fig. 9.1). Each of the solutions shown in TABLE 4 can be taken as optimum because an attempt to improve any objective causes a degradation in at least one of the other objectives. Of course, all the objectives must be competing. To find linearly dependent objectives the correlation coefficients are determined at the first stage (Fig.9.1).

Three LP-search modifications are available in ALLTED:

METHOD = 300 only the first stage of LP-search is performed. The results are stored on a disk.
METHOD = 310 the second stage of LP-search is carried out. The user is asked to specify the filename where the results of the first stage are stored.
METHOD = 320 the first and the second stages of LP-search are initiated consequently. The user is asked to input filename to store the results of the first stage and second stage is started immediately.

LP-search being a straightforward exhaustive method is a very robust one. In multiple criterion optimization it serves the same purposes the RSIS does in a conventional optimization. Due to the restricted value N of the sample each of the solutions should be treated as quasi-acceptable, quasi-noninferior one. To find real acceptable non-inferior solutions, the weighted sum or minimax method should be used. However, for both of them the detailed information is necessary to find weight factors, initial points, etc. Without such information a good solution can be detected only by chance. LP-search supplies enough information to take justified steps.

The only parameter in ALLTED to control LP-search with is the number of tests specified by the directive CONST key parameter NUMB. Due to the features of the LP-tau distribution, its value must be chosen as 2*m m = 3,4,5...10. The greater the parameter the more reliable results are. Its value is highly influenced by the complexity of an object and power of a computer. On a statistical basis NUMB = 256 or NUMB = 512 is quite enough for the overwhelming majority of cases.


Chapter 9

Weighted Sum Method for Multiple Criterion Optimization

There are an infinite number of noninferior points for a given multiple criterion optimization problem. The set of noninferior points yields the set of noninferior solutions or the noninferior or trade-off surface in objective function space. Using LP-search, the set of quasi-Pareto or quasi-noninferior solutions is generated. To find an exact value of one of the Pareto-points out of the set, the weighted sum or minimax methods should be applied.

The weighted sum method deals with the scalar objective function problem

f(x) = a1F1(x) + a2F2(x) + ... + amFm(x), (9.14)

where a1,...,am are weight factors which must be chosen to convert the problem (9.1) into the

single criterion optimization problem with an additive function (9.14).

The problem of determining of weights is rather complex and there are some heuristics of how to do it. It is recommended to apply the approach of Lightner M.R. and Director S.W. described in "IEEE Transactions on Circuits and Systems", Vol.CAS-28, No.3, March 1981.

With the weights determined, any method for a single criterion optimization can be applied.

Minimax Method of Multiple Criterion Optimization

The minimax method is based on converting the problem (9.1) into

(9.15)

The scalar objective function is introduced similar to weighted sum method but instead of additive function the so-called maximum objective function

is used. To solve problems type (9.15), the minimax algorithm with step-by-step active function selection (MAFS) has been designed. The MAFS is a linearization type method based on a determination at each step of vector of the variable parameters increment [image] that decreases the maximum objective function by a some specific for each step value ?(k). To intensify the process, only a dominant, so called active function, is taken into consideration at each particular step. The high-order approximation, similar to the approximation in variable-order methods, is used in MAFS when the set of active functions consists of only one objective function.

Generally the problem (9.15) is used in more convenient form

where weights a1, a2,...,am can align heterogeneous objectives and scale them if necessary. At the noninferior point the following condition is true
43
and weight optimal values are

a1 = 1/F1*(x), a2 = 1/F2*(x),..., am = 1/Fm*(x),

where F1*(x),...,Fm*(x) - noninferior solutions. Of course, the set of noninferior solutions is not known apriori, but after the LP-search a lot of quasi-noninferior solutions are available and any of them can be used for weight determination.

To initiate MAFS, the parameter METHOD must be set to 220 or 222. The method is adjusted with OPERR and INCR parameters the values of which are selected similarly to the other methods.


Chapter 9

Methods of Optimization. Summary Table

Each method can be used for approximation or minimization problems. If the number specified with the parameter METHOD ends with zero the problem is supposed to be the approximation one. To initiate the minimization, the last digit in the number must be 2.

Table 9.3.

Methods of optimization

METHOD code | Description
METHOD=40 RSIS | Random search with step-to-step search interval shrinkage. Conventional random number generator with uniform distribution is used.
METHOD=50 RSIS(D) | Random search with step-to-step search interval shrinkage. Random number generator with uniform discrete distribution is used. The variable parameter value generated is rounded to the nearest value listed in special file DISKOPT.DAT.
METHOD=60 RSIS(LP) | Random search with step-to-step search interval shrinkage and modified uniform distribution named LP-tau - distribution. This distribution is more effective than conventional one, but the sample number (set by NUMB parameter) must be chosen among integers 2m, m = 1,2,... It could cause some inconveniences when NUMB is more than 64.
METHOD=70 RSIS(LP-D) | Similar to METHOD=60, but variable parameters are chosen among special parameter list like in METHOD=50.
METHOD=100 VOM(DFP) | Variable-order method designed as the expansion of the quasi-Newton algorithm based on Davidon-Fletcher-Powell approximation formula.
METHOD=110 VOM(B) | Variable-order method designed as the expansion of the quasi-Newton algorithm based on Broyden approximation formula.
METHOD=120 VOM(BFGS) | Variable-order method designed as the expansion of the quasi-Newton algorithm based on Broyden-Fletcher-Goldfarb-Shanno approximation formula.
METHOD=130 RSIS + VOM (DFP) | Composite two-stage method combining METHOD=40 and METHOD=100.
METHOD=140 RSIS + VOM (B) | Composite two-stage method combining METHOD=40 and METHOD=110.
METHOD=150 RSIS + VOM (BFGS) | Composite two-stage method combining METHOD=40 and METHOD=120.
METHOD=220 MAFS | Minimax method designed as the expansion of the algorithm with step-by-step choice of the active functions (Agnew algorithm).
METHOD=300 LP-search | Method for solution of the multiple criterion optimization problems based on LP-tau-search. The method provides the two-stage problem solution. The first stage is arranged as test series performed on the nonuniform grid (LP-tau-distribution). The obtained values of variable parameters, objective functions and constraints (if any) are ordered and printed as output results. At the second stage the noninferior solution set (in the sense of Pareto) are searched. The first stage results can be stored and retrieved if necessary in dialogue mode. METHOD=300 sets up execution of the first stage only.
METHOD=310 LP-search | Second stage of LP-search. It operates with the results accumulated in METHOD=300 preliminarily.
METHOD=320 LP-search | The method incorporating both the first and second stages of LP-search.


Chapter 9

Parameters of the Directive CONST to Adjust Optimization

To simplify the problem of adjusting the optimization methods, all the directive CONST parameters mentioned in Section 9 are listed in the Table below. Note that transient response, frequency, and steady-state analysis are adjusted with their own parameters.

Table 9.4.

Parameters of the directive CONST to adjust optimization

Parameter | Purpose | Remarks
METHOD (150) | The parameter through which the method for solving the optimization problem is set. | METHOD value in the optimization block can vary from 40 to 320. If METHOD value ends by the digit 2, the problem is to be solved as the minimization problem, if by the digit 0 - as the approximazation one. They differ in the form of criterion of termination. The description of the optimization methods and METHOD value are listed in the Table 9.3.
LSERR (1E-4) | An acceptable error to terminate one-dimensional line search. | The duration of the line search can be highly influenced with this parameter.
NUMB (64) | Number of tests in the sample completed on one step of the random search. | For METHOD = 50 and METHOD = 70 the parameter must be set equal to 2**K, where K = 2,3,4,5...
CLEAR (10) | To control the periodicity of the unitarization of the inverse Hess matrix approximation. | After n * CLEAR steps, where n - number of variable parameters, the approximating matrix is taken as a unitary matrix again to avoid the instability of quasi-Newton methods.
OPERR (1E-6) | An acceptable error to terminate the optimization process. | The optimization time is highly influenced by this parameter. It's good practice to set the parameter after MVA analysis.
SWERR (0.05) | An acceptable error of the random search method to start a deterministic one at when two-stage methods are used. | The less the parameter value the more steps will be performed by the time consuming random search method.
OPRINT (1) | Periodicity of intermediate optimization results output. | Output results such as objective functions value, constraints, variable parameters, etc. are displayed in every OPRNT optimization steps.
INCR (1.E-4) | Relative increment value of the variable parameters in numeric assessment of the gradient components. | The INCR value can be increased by up to 0.05 when linear dependance between objective functions and variable parameters can be assumed.
MAXORD (4) | Maximum permissible order of the optimization method. | Can be decreased down to 2 to start conventional quasi-Newton methods.
CONERR (0.01) | An acceptable error of the dominating constraint. | To control the moment when dominating constraint is satisfied.


Chapter 9

Optimization. Examples

Electronic Active Filter. Frequency Response Design RAD_OPT.ATD

The design task below is a rough example.

task
DC; # DC analysis to determine the operating point conditions
AC; # Frequency response evaluation
# Directive CONST sets adjustable parameters
CONST UFREQ=0.005, # Upper frequency boundary
LFREQ=0.0025; # Lower frequency boundary
TF KU=V6/UE1; # Transfer function definition
# Directive FIX determines the coordinates of a current
# frequency response
FIX T1=FIXA(MA.KU,0.0025), T2=FIXA(MA.KU,0.0030),
T3=FIXA(MA.KU,0.0035), T4=FIXA(MA.KU,0.00375),
T5=FIXA(MA.KU,0.0050);
OPTIM; # Optimization
# Directive OF specifies the objective function as sum of
# 5 squared differencies between desirable values (they are
# listed in parenthesis) and actual values (they are determined
# by the FIX directive)
OF ERROR=F1(0.26,0.44,1.14,1.9,0.36/T1,T2,T3,T4,T5);
# Variable parameters and parametric
# constraints are stated below
VARPAR R2(10,100),R3(50,1000),R5(20,500),C1(0.5,2.0),C2(0.5,2.0);
# Directive CONST set the parameters to adjust optimization
CONST METHOD=120, # Optimization method (120 = variable order
# method)
OPERR=1.0E-3, # Acceptable error to end the optimization
LSERR=0.01, # Linear search error level
INCR=0.01; # Increment value for gradient computation
PLOT MA.KU(50); # Transfer function KU amplitude is plotted
# in natural scale
OPTION 48; # This mode setting will get statistics
&
end

In process of AC analysis five frequency response coordinates T1, T2,...,T5 are determined with the FIX directive. The transfer function KU is defined as V6/UE1 and its desirable frequency response coordinates are specified:

MA.KU

FREQ(MHz)

 0.26

0.0025

 0.44

0.003

 1.14

0.0035

 1.9

0.00375

 0.36

0.005

The variable parameters and their limits are:

10K Ј R2 Ј 100K
50K Ј R3 Ј 1M
20K Ј R5 Ј 500K
0.5 nF Ј C1 Ј 2nF
0.5 nF Ј C2 Ј 2nF

Then values T1,...,T5 are used as arguments in the directive OF where the function F1 is used to evaluate a proximity between the desired and actual frequency responses.

In the first directive CONST parameters for AC analysis are set (normally upper and low boundaries of a frequency range). The second CONST directive specifies the method of optimization, criterion OPERR and LSERR to terminate at, and the value of a variable parameters increment for a gradient component numerical estimation. In fact, all the parameters could be set in one directive but the structure of the design tack with separated analysis and optimization parts is advisable for reasons of clarity.

Parameter 48 in the directive OPTION sets the output of statistics.

Results of optimization comprise the object status at the initial point, then status after each optimization step, statistics (if an option 48 is set in the directive OPTION), and plots where all the curves specified in the directive(s) before and after optimization are depicted. Here are the results of an electronic filter design. Intermediate results after steps 2 to 6 are omitted.


Chapter 9

R E S U L T S O F O P T I M I Z A T I O N
******************************************

Object status at starting point

Objective function

ERROR = 0.5345342955D+02

Variable parameters

Name Initial value Low boundary Upper boundary

R2 0.35700E+02 0.10000E+02 0.10000E+03
R3 0.30000E+03 0.50000E+02 0.10000E+04
R5 0.10680E+03 0.20000E+02 0.50000E+03
C1 0.11350E+01 0.50000E+00 0.20000E+01
C2 0.11350E+01 0.50000E+00 0.20000E+01

R E S U L T S O F O P T I M I Z A T I O N
***********************************************

Object status after step 1

Objective function

ERROR = 0.1739219379D+01

Variable parameters

R2 = 0.3563566673D+02
R3 = 0.2317627378D+03
R5 = 0.8366251789D+02
C1 = 0.1135019067D+01
C2 = 0.1135020042D+01

R E S U L T S O F O P T I M I Z A T I O N
***********************************************

Object status after step 7

Objective function

ERROR = 0.2227644041D-01

Variable parameters

R2 = 0.1667743639D+02
R3 = 0.9842373763D+02
R5 = 0.1287449978D+03
C1 = 0.1532585595D+01
C2 = 0.9312262791D+00

R E S U L T S O F O P T I M I Z A T I O N
***********************************************

Object status after step 8

Objective function

ERROR = 0.2035066386D-01

Variable parameters

R2 = 0.1718964623D+02
R3 = 0.1012859144D+03
R5 = 0.1229509702D+03
C1 = 0.1553978120D+01
C2 = 0.8820701816D+00

R E S U L T S O F O P T I M I Z A T I O N
***********************************************

Object status at optimal point

Objective function

ERROR = 0.9758418479D-03

Variable parameters

R2 = 0.1901677034D+02
R3 = 0.1131038796D+03
R5 = 0.1066086844D+03
C1 = 0.1533562063D+01
C2 = 0.8191581882D+00

*****************************************

S T A T I S T I C S

Number of OF evaluations = 121
Number of steps = 8
Number of line search = 8
Number of OF evaluationsfor Hessian and gradient numerical determination = 50
OF evaluations inline search = 58
Number of steps (by order)
order - 1 = 0
order - 2 = 8
order - 3 = 0
order - 4 = 0
Number of var.parameters = 5


Chapter 9

If more than five coordinates were used the task would be rather long due to a plethora of FIX directives. To avoid such a situation, the directive SWEEP can be used to shorten the task (the modified problem is called RAD_OP1.ATD):

task
DC; # DC analysis to determine the operating point # conditions
AC; # Frequency response evaluation
# Directive CONST sets adjustable parameters
CONST UFREQ=0.005, # Upper frequency boundary
LFREQ=0.0025; # Lower frequency boundary
# Directive SWEEP lists the frequencies at which the analysis # is performed
SWEEP FREQ(0.0025, 0.003, 0.0035, 0.00375, 0.005);
TF KU=V6/UE1; # Transfer function definition
OPTIM; # Optimization
# Directive OF specifies objective function as sum of 5
# values (they aresquared differences between desirable
# listed in parenthesis) and actual values (they will be
# computed at SWEEP directive frequencies)
OF ERROR=F1(0.26,0.44,1.14,1.9,0.36/MA.KU);
# Variable parameters and parametric constraints are stated
# below
VARPAR R2(10,100),R3(50,1000),R5(20,500),C1(0.5,2.0),C2(0.5,2.0);
# Directive CONST set the parameters to adjust optimization
CONST METHOD=120, # Optimization method (120 = variable
# order method)
OPERR=1.0E-3, # Acceptable error to end the optimization
LSERR=0.01, # Linear search error levelINCR=0.01; # Increment value for gradient computation
PLOT MA.KU(50); # Transfer function KU amplitude is
# plotted in natural scale
OPTION 48; # This mode setting will get statistics
&
end

The result of the modified task will be the same, but the frequency response is assessed at only six frequencies, saving some computation time. The configuration of frequency response can be different as well, because of a linear interpolation involved to compute the coordinates between these six frequency points.

Fig. 9.2. Frequency response before and after electronic filter optimization.

Fig. 9.3. Operatonal amplifier optimization results.


Chapter 9

Operational Amplifier Optimization, RCA_OPT1.ATD

For the RCA 3040 operational amplifier (see Section 12.9) it is necessary to find such values of variable parameters R1, R3, and R4, that the durations of the front (DURS) and back (DURF) edges of the output signal UR11 would be equal to 25± 441uS and 20± 451us correspondingly, and the minimum value of UR11 in the time interval 0 - 4690 uS would be less than 1v.

The following boundaries for variable parameters should be obeyed:

10 Ј R1 Ј 100
1K Ј R3 Ј 10K
1K Ј R4 Ј 10K

The initial values are:

R1=1.0, R3=1.0, R4=1.0

The optimization method is selected to be METHOD=120 (VOM with BFGS formula).
The task for this problem is as follows:

task
DC; # DC analysis
TR; # Time-domain analysis
# Directive CONST sets the parameters to adjust computation
CONST TMAX=90, # Time span
MINSTEP=1E-4, # Minimum step for integration procedure
REVAL=3, # Only after each third step the matrix
# is reevaluated
ERR=0.01, # Error level
LERR=0.1, # Local error level
DCERR=1.e-6, # DC analysis error
XMAX=0.01; # Threshold value for variables vector
# Output characteristics are determined with FIX and INT
# directives
FIX T1=FALL(UR11,1.4),# Instant when UR11 intersects 1.4 level
# while decreasing
T2=FALL(UR11,9.0),# Instant when UR11 intersects 9.0 level
# while decreasing
T3=RISE(UR11,9.0),# Instant when UR11 intersects 9.0 level
# while increasing
T4=RISE(UR11,1.4);# Instant when UR11 intersects 1.4 level
# while increasing
FIX UR11MIN=MINF(UR11);# Voltage UR11 minimum value
INT DURF=T3-T4,DURS=T1-T2; # Pulse durations computation
OPTIM; # Optimization
VARPAR R1(0.01,0.1),R3(1.00,10),R4(1.00,10);# Variable
# parameter statement
OF DIF1=F3(1,25,20/DURS,DURF); # The duration of DURS should
# be 25 units of time,
# DURF - 20 units.
# The difference in 1 unit is set to be acceptable
LIMIT LIM=F252(1.0/UR11MIN); # UR11MIN must be more than 1
# Directive CONST sets the parameters to adjust optimization
CONST OPERR=0.1, # Acceptable error
METHOD=120; # Optimization method (variable
# order method)
OPTION 48; # This mode is set to get statistics
PLOT UR11(40); # Voltage UR11 is plotted before and after
# optimization
&
end

The optimal solution was found after 16 OF evaluations:

R E S U L T S O F O P T I M I Z A T I O N
***********************************************

Object status at starting point

Objective function

DIF1 = 0.1000000000D+26

Variable parameters

Name Initial value Low boundary Upper boundary

R1 0.10000E+01 0.10000E-01 0.10000E+00
R3 0.10000E+01 0.10000E+01 0.10000E+02
R4 0.10000E+01 0.10000E+01 0.10000E+02
Constraints
LIM = 0.8558745384D+01
**************************************************************

R E S U L T S O F O P T I M I Z A T I O N

***********************************************

Object status at optimal point

Objective function

DIF1 = 0.7723274417D-01

Variable parameters

R1 = 0.9718738040D-01
R3 = 0.7344889037D+01
R4 = 0.7858770846D+01

Constraints

LIM = 0.6128823757D-01
**************************************************************

S T A T I S T I C S

Number of OF evaluations = 16
Number of steps = 0
Number of line search = 1
Number of OF evaluations
for Hessian and gradient
numerical determination = 3
OF evaluations in line search = 0
Number of steps (by order)
order - 1 = 0
order - 2 = 1
order - 3 = 0
order - 4 = 0
Number of var.parameters = 3
Number of constraints = 1

**************************************************************

Directive F I X output characteristics

****************************************

T1 = 30.3450642
T2 = 6.60152388
T3 = 79.2463074
T4 = 58.1392517
UR11MIN = 1.06128824
Directive I N T output
characteristics

****************************************

DURF = 21.1070557
DURS = 23.7435398


Chapter 10

Statistical Analysis and Yield Maximization

The ALLTED statistical analysis block is designed to compute statistical parameters of any output characteristic with the statistical variations of given object's parameters.
Two operation modes are available:

- statistical analysis mode;
- yield maximization mode.

Statistical Analysis (ST)

The following parameters of the monitored output characteristics can be defined in the statistical analysis mode:
- the mathematical expectation

where

N = dimension of the sample (number of runs to be repeated),
Yk = value of the k-th monitored characteristic,
m = number of output characteristics.
- the standard deviation or dispersion

- the correlation coefficient

The values Yik, k=1,...,N, i=1,...,m are accumulated during multiple runs of TR, AC, and/or DC analysis while given variable parameters are statistically varied within specified tolerances. The following random numbers generators are available in ALLTED:

- The uniform probability density function

where

a = lower boundary of the statistically variable parameter,
b = upper boundary.
- Normal

where

Logarithmic

where

The number of generators can easily be extended with module USRAND.FOR.
To run statistical analysis, the task should contain the directives shown in the table below

Purpose |  | Directive
To set the basic analysis type (Domain Type) | Steady-state characteristics | DC
 | Time-domain characteristics | TR
 | Time-domain characteristics with steady-state analysis run first to determine initial conditions | DC TR
 | Frequency-domain characteristics with steady-state analysis run first to linearize object in the vicinity of operating point | DC AC
Adjust the computation |  | CONST
Statistical analysis setting |  | STA
Specify statistically variable parameters |  | STAPAR
Specify output characteristics that are to be monitored during analysis |  | CONTROL
Specify output characteristics that are to be plotted in histogram format |  | HISTO


Chapter 10

The variable parameters are set with the directive STAPAR:

STAPAR

<par_name>(<number_low>,<lower_bound>,<upper_bound>){,<par_name>(<number_low>,<lower_bound>,<upper_bound>)};

where

<par_name> = variable parameter that can be any symbolic parameter or any linear two-terminal component,
<number_law> = distribution law of the parameter specified by an integer:
1 - Uniform distribution,
2 - Normal distribution,
3 - Logarithmic Normal distribution.
<lower_bound> = lower boundary of the parameter variation range (in absolute value),
<upper_bound> = upper boundary of the parameter variation range (in absolute values).

Output characteristics that are to be monitored during statistical analysis are set with the CONTROL directive:

CONTROL

<char_name>(<lower_tb>,<upper_tb>){<char_name>(<lower_tb>, <upper_tb>)};

where

<char_name> =output characteristic that can be any characteristic defined in the FIX, INT, or FUNC directives,
<lower_tb> = lower boundary of the characteristic's tolerance (in percentage %),
<upper_tb> = upper boundary of the characteristic's tolerance (in percentage %).

As a result of statistical analysis, the mathematical mean and dispersion are printed for each of the characteristics, assigned in the CONTROL directive.
Moreover, all or some characteristics, assigned by the CONTROL directive may be presented in the form of histograms. This is specified by the HISTO directive, having the following syntax:

HISTO

<characteristic_name>[(<number_of_intervals> [,<lower_boundary>,<upper_boundary>]];

where

<characteristic_name> = name of the output characteristic that is specified in the directive CONTROL and set to be output in the histogram,
<number_of_intervals> = number of intervals that X-axes of the histogram is to be divided into. By default, the range of the characteristic's variation will be divided into 50 intervals,
<lower_boundary> = lower boundary to start the characteristic presentation in the histogram. By default, the minimum value of the characteristic
occurred during multiple runs is taken as its lower boundary,
<upper_boundary> = maximum value of the characteristic to be depicted in the histogram.
By default, maximum characteristic value is taken as its upper boundary.

For example:

HISTO T1(6,0.8,1.2);
HISTO T1(10);

Directive CONST parameters that are used to set statistical analysis are summarized in the next table.

Note that a time-domain transient analysis, steady-state analysis, and frequency analysis are set with parameters listed in Sections 4.2, 4.3, 4.4. Only two parameters are designed to set STA analysis:

Parameter | Purpose | Description
METHOD(0) | To control the mode of the analysis | 0 - statistical analysis, 1 - yield maximization.
NUMB(64) | Number of runs to be performed (sample size) |


Chapter 10

Statistical Maximization Yield Mode

The yield in statistical testing may be estimated as:
(10.1)
where

NG = number of "successful" tests from the total number of tests N. The test is considered to be successful if all output characteristics are within their tolerances.

To design an object with preset reliability, the nominal values of the variable parameters and their tolerances have to be determined for which Y і Ymax, where the desired value Ymax of the yield is specified by the user in the range Ymax Ј 100%. In other words, the problem of the yield maximization has to be solved:
(10.2)
where
is the vector of the object's nominal parameters, [image] is the vector of tolerances.

The problem (10.2) is solved in ALLTED in two stages.

At the first stage, which is merely an attempt to solve centering problem, where N tests are performed and the value of the yield is estimated, the following condition is checked:
(10.3)
where k is the number of test series. If condition (10.3) is satisfied, the coordinates x(k) of the nominal point are shifted according to: (10.4)
or [image] (10.5)

where
coordinates of the center of masses of m "successful" tests,
coordinates of the center of masses of n "unsuccessful" tests (m + n = N).

And then the next test series is conducted. If, after the l-th series of tests, condition (10.3) is not satisfied, the second stage is performed, which is based on the tolerances correction:

and then the first stage is repeated.

This is continued until either Y(k) becomes equal or greater than Ymax (the desired value of the yield) or no positive results occur at stage 1 repetition.

Directive CONST parameters that are used to set statistical yield maximization are shown in the table below:

Parameter | Purpose | Description
METHOD(0) | To control the mode of the analysis | 0 = statistical analysis, 1 = yield maximization with formula (8.5), 2 = yield maximization with formula (8.4).
YMAX(100) | Desired yield value |
NUMB(64) | Number of runs to be performed (sample size) |


10

Statistical Analysis. Examples

The following problems were developed to illustrate statistical analysis and statistical yield maximization.
Below the task from electronic active filter rad_sta.atd (see Section 12.1) is illustrated and commented.

TASK;
DC; # Steady state analysis
AC; # Frequency-domain analysis
STA; # Statistical analysis
TF KU=V6/UE1; # Transfer function named KU is
# defined as the ratio between V6 and UE1
# Directive CONST sets the parameters to adjust computation
CONST LFREQ=0.0025, # Lower frequency boundary
UFREQ=0.005, # Upper frequency boundary
NUMB=50; # Sample size
# Directive FIX determines the output characteristics
FIX AMPMAX=MAXF(MA.KU), # Maximum amplitude
FREQMA=MAXA(MA.KU), # Frequency at maximum
AMP0035=FIXA(MA.KU,0.0035); # Amplitude at frequency 0.0035
# Variable parameters, their laws of distribution, and
# boundaries are specified in the STAPAR directive
STAPAR R3(1,290,310),R5(1,95,110),C1=C2(2,1.0,1.2);
# Three output characteristics are chosen to be controlled
# during STA. Names of these characteristics and their feasible
# limits are listed in the CONTROL directive
CONTROL AMPMAX(20,20), FREQMA(20,20), AMP0035(20,20);
# Three histograms are set to be output:
HISTO AMPMAX(20,6.0,15.0); # - characteristic AMPMAX
(20 intervals, only part of the sample from 6.0 to 15.0
# is to be output)
histo FREQMA(32); # - characteristic FREQMA divided by
# 32 intervals
histo AMP0035; # - characteristic AMP0035 (full range, 50 intervals by default)
&&
END

For the filter it is necessary to find the statistical characteristics of the maximum value AMPMAX of the amplitude-frequency response, corresponding to that frequency FREQMA, and the value AMP0035 of the amplitude-frequency response at the frequency point 0.0035 MHz for the gain KU=V6/UE1 with respect to the variation of following parameters:

290 Ј R3 Ј 310,
95 Ј R5 Ј 110,
1.0 Ј C1 Ј 1.2
1.0 Ј C2 Ј 1.2

(distribution law for R3 and R5 - uniform, and for C1 and C2 - normal). The histograms of AMPMAX, FREQMA, AMP0035 are set to be plotted. The range for AMPMAX is set from 6 to 15. The feasible variations of all monitored characteristics are set to be +-20% with respect to their nominal values.

The computation results are:

***************************************************************
STATISTICAL ANALYSIS
***************************************
THE NUMBER OF TESTS : 50

Variable parameters | Lower boundary | Upper boundary
R3 | 0.2900000E+03 | 0.3100000E+03
R5 | 0.9499999E+02 | 0.1100000E+03
C1 | 0.1000000E+01 | 0.1200000E+01
C2 | 0.1000000E+01 | 0.1200000E+01

Yield estimation : 10.00 %
**********************************

Controlled characteristics
***************************************************

Name | Mean value | Dispersion
AMPAX | 0.899323D+01 | 0.103128D+02
FREQMA | 0.899323D+01 | 0.186488D-07
AMPOO35 | 0.189163D+01 | 0.139117D+01

Fig. 10.1. Variable AMPMAX histogram.

Fig. 10.2. Variable FREQMA histogram.

Fig. 10.3. Variable AMP0035 histogram.


Chapter 10

Fig. 10.4. Delay line LIN

The task for statistical yield maximization is illustrated on the example of an electronic delay line design:

task
dc; # Steady-state analysis
sta; # Statistical analysis
# Directive CONST sets the parameters to adjust computation
const method=1, # Yield maximization is set
numb=30, # Sample size
ymax=90; # Desired yield value
# Directive FIX specifies the output characteristics
fix VOLT_3=fixa(V3,0), # Voltage of node 3
VOLT_8=fixa(V8,0), # Voltage of node 8
VOLT_11=fixa(V11,0); # Voltage of node 11 Directive CONTROL sets the output characteristics and their
# feasible limits to be controlled during yield maximization
control VOLT_3(5.0,5.0), VOLT_8(5,5), VOLT_11(5.0,5.0);
# These four parameters are declared variable. The first number
# in the parenthesis specifies the distribution law. To attain
# the desirable yield, the limits, initial values of which are
# listed in the parenthesis, are to be changed
stapar R3(1,0.1,3), R4(1,0.1,1), r2(1,2.5,4), R6(1,4.0,7);
# These three histograms will be plotted at initial point, at
# each step of maximization, and after the maximization.
histo VOLT_3(8);
histo VOLT_8(8);
histo VOLT_11(10);
&&
end

Below only some fragments from the output are illustrated

*********************************************************
STATISTICAL DESIGN
************************************
(object initial status)

Variable parameters | Lower bound | Upper bound | % | Nominal point
R3 | 0.1000000E+00 | 0.3000000E+01 | +-93 | 0.1550000E+01
R4 | 0.1000000E+00 | 0.1000000E+01 | +-81 | 0.5500000E+00
R2 | 0.2500000E+01 | 0.4000000E+01 | +-23 | 0.3250000E+01
R6 | 0.4000000E+01 | 0.7000000E+01 | +-27 | 0.5500000E+01

Yield estimation: 16.00 %
**********************************
Controlled characteristics
***************************************************

Name | Mean value | Dispersion
VOLT_3 | 0.483719D+01 | 0.217643D-01
VOLT_8 | 0.418165D+01 | 0.252869D-01
VOLT_11 | 0.135628D+00 | 0.437632D-03

****************************************************
STATISTICAL DESIGN
************************************
(object status after step 10)

Variable parameters | Lower bound | Upper bound | % | Nominal point
R3 | 0.1104345E+00 | 0.1901650E+01 | +-89 | 0.1006042E+01
R4 | 0.5096582E+00 | 0.9125894E+00 | +-28 | 0.7111238E+00
R2 | 0.2743816E+01 | 0.3832747E+01 | +-16 | 0.3288282E+01
R6 | 0.5468479E+01 | 0.6051998E+01 | +-5 | 0.5760239E+01

Controlled characteristics

*************************************************

Name | Mean value | Dispersion
VOLT_3 | 0.493366D+01 | 0.109184D-02
VOLT_8 | 0.429282D+01 | 0.119493D-02
VOLT_11 | 0.125979D+00 | 0.124444D-04

Yield estimation
********************************
Desired yield = 90%
Best yield = 90.0%
Yield after step 10= 90.0%
********************************


Chapter 10

Fig. 10.5. Histogram of variable VOLT_3 before maximization.

Fig. 10.6. Histogram of variable VOLT_8 before maximization.

Fig. 10.7. Histogram of variable VOLT_11 before maximization.


Chapter 10

Fig. 10.8. Histogram of variable VOLT_3 after maximization.

Fig. 10.9. Histogram of variable VOLT_8 after maximization.

Fig. 10.10. Histogram of variable VOLT_11 after maximization.


Chapter 11

Optimal Tolerances Assignment

The Optimal Tolerance Assignment operation determines the tolerances of the derived set of object parameters from the feasible deviations of output characteristics. Generally the operation is performed at the final stage of design and makes it possible to take into account the effect of production technology and environmental conditions at an early stage of object development.

Considering the entire scope of ALLTED designable objects, it is easy to determine the sort of parameters which could be of interest while assigning the tolerances:
- element geometric dimensions (pipeline length, wall thickness and diameter, orifice length, operating member stroke, etc);
- physical parameters (resistance, conductance, mass, fluid density, viscosity, Coulomb's friction force, etc.);
- parameters and coefficient of nonlinear functional relationships (linear temperature coefficient, Boltsman's constant, universal gas constant, etc.);
- tuning parameters (gain, time constant, voltage, pressure supply, etc.).

In summary, since all types of system parameters could at some time be of interest the CAD input language must be able to express any of them explicitly. In the ALLTED input language the tolerances can be assigned on either symbolic parameters or the main model linear component (except linear controlled sources). If a nonlinear component or its parameter in the main or conventional model has to be considered, some changes in the equivalent circuit configuration may be necessary. This component must be inserted into a symbolic model first.

The expressive ALLTED input language imposes no more restrictions. Some redundancy is justified when looking at it from the purely analytical point of view.

Problem Formulation

The ALLTED method for optimal tolerances assignment is based on the following assumptions:

output characteristics of the object must be of the form
(11.1)
or

where

y1,...,ym = output charactistics such as response time, overshoot, pulse front edge duration, maximum voltage, efficiency, etc. that are determined as secondary variables in the directives FIX, INT, FUNC,
yin = nominal value of i-th characteristic,
di = characteristic's allowable deviation.

In the output characteristic space, the condition (11.1) forms the region of operability Ra
(11.2)
any designable (variable) parameter in the procedure can be represented as
(11.3)

where
xni = nominal value of the i-th parameter,
ti = deviation of the parameter, measured in percentage with respect to the nominal value.
In the parameter space, condition (11.3) in conjunction with constraint [image] forms the tolerance region:
(11.4)
and deviations [image] are called tolerances
the most labor-consuming operation in optimal tolerances assignment procedures is evaluation of constraint (11.4). In ALLTED the complex, nonlinear model of the object is replaced with a simple linear relationships between output characteristics and variable parameters. To establish the relationships, the set of analysis is carried out at the first stage of the procedure. Because of small deviations about the nominal point, the linear regression model of the form [image] (11.5)
is chosen to simulate the object on the basis of observed data,

where

D yi = j-th output characteristic deviation,
aji = coefficients of the regression model

the maximum tolerances are assumed to be optimal if condition (11.2) is satisfied. This is formulated as follows
(11.6)

subject to

If tolerances for some parameters are known in advance, the deviation range of the output characteristics must be shrunk before the rest of parameters will be considered. To do this, the coefficients [image] 14 of j-th characteristic's shrinkage [image] is calculated on the basis of given tolerances [image] where p is a number of parameters with given tolerances. Finally, new output characteristics deviation ranges are determined

and substituted in the equation (11.6). The quantity [image] stands for the initial deviation.
To tackle the constrained nonlinear optimization problem (11.6), the variable order method similar to VOM (BFGS) (see Section 9.6.2) has been developed.
The method is initiated by default no matter what number is set by the parameter METHOD.

To set the procedure, two directive CONST parameters are designed:

Parameter | Purpose | Description
TOLERR (1.E-3) | To specify the acceptable accuracy to terminate the solution |
INCR (1.E-4) | Increment value to control the regression model coefficient determination | The coefficients are estimated numerically according to the formula where [image] is the increment of the i-th variable parameter, calculated as [image] is a parameter INCR


Chapter 11

Tolerances Assignment. Example

The following problems were developed to illustrate optimal tolerances assignment.
Tasks and their respective output results are illustrated below.

The design objective is to find the values of optimal tolerances of resistors R1-R7 and capacitors C1, C2 of the RAD filter (see Section 12.1). The performance sought is the maximum value of the amplitude-frequency characteristic. Also the value of the phase-frequency characteristic at 0.003 MHz for the transfer function KU=V6/UE1 should not deviate more than +/-10%.

The task to fulfill the purpose looks like:

task;
DC; # DC analysis
AC; # Frequency-domain analysis
tolas; # Optimal tolerances assignment
# Directive CONST sets the parameters to adjust computation
CONST LFREQ=0.0025, # Lower frequency boundary
UFRE Q=0.005, # Upper frequency boundary
DCMET=2; # DC analysis method
TF ku=v6/u e1; # Transfer function definition
# Two output characteristics are set with FIX directive
fix ph_fr003=fixa(ph.ku,0.003), # Phase angle at
# frequency 0.003
amplmax=maxf(ma.ku); # Maximum amplitude
# These are the parameters to be considered during assignment
varpar r1, r2, r3,r4,r5,r6,r7(5),c1,c2(10);
# The allowable deviations of output characteristics
control ph_fr003(10,10),amplmax(10,10);
&
end;

Computation results are shown below:

OPTIMAL TOLERANCES
***********************************

Parameter | Nominal value | % | Tolerance abs
R1 | 0.3799999690D+03 | +-1.249 | +-0.4748088840D+01
R2 | 0.3570000080D+02 | +-0.849 | +-0.3031897840D+00
R3 | 0.3000000000D+03 | +-0.288 | +-0.8627974990D+00
R4 | 0.5000000000D+01 | +-0.100 | +-0.4995004740D-02
R5 | 0.1068000030D+03 | +-0.100 | +-0.1066933130D+00
R6 | 0.6579999540D+02 | +-0.100 | +-0.6573426720D-01
R7 | 0.4500000000D+03 | +-0.100 | +-0.4495504500D+00
C1 | 0.1134999990D+01 | +-0.105 | +-0.1187507410D-02
C2 | 0.1134999990D+01 | +-0.100 | +-0.1135000030D-02

***************************************************************************

WORST CASE CALCULATION
to estimate the quality of the tolerances assignment
****************************************************

Output characteristic | Nominal value | Allowable deviation, % | Upper limit |  | Lower limit
 |  |  | abs | % | abs | %
PH_FR003 | 0.8354E+02 | +- 10.00 | 0.8371E+02 | 0.19 | 0.8338E+02 |  | -0.20
AMPLMAX | 0.1029E+02 | +- 10.00 | 0.1126E+02 | 9.48 | 0.9790E+01 |  | -4.82

***************************************************************************

The worst case calculation follows the optimal tolerances assignment procedure to estimate the quality of the solution. If a difference between the specified and calculated deviations of the output characteristics is too large the problem can be initialized again with another set of initial tolerances and INCR values.


Chapter 11

Setting the Procedure

To set the task for an optimal tolerances assignment, the following directives are used:

Purpose |  | Directive
To set the basic analysis type (Domain Type) | Steady-state characteristics | DC
 | Time-domain characteristics | TR
 | Time-domain characteristics with steady-state analysis run first to determine initial conditions | DC TR
 | Frequency-domain characteristics with steady-state analysis run first to linearize object in the vicinity of operating point | DC AC
Adjust the computation |  | CONST INSTALL
Optimal tolerances assignment setting |  | TOLAS
Specify parameters which tolerances are known a priory and have to be considered |  | TOLE
Specify parameters which tolerances are to be determined |  | VARPAR
Specify output characteristics and their feasible deviations |  | CONTROL
Specify output characteristics |  | FIX INT FUNC

The directive TOLAS states the mode. No parameters are used in this type of directives.

The directive VARPAR specifies the set of designable parameters. To the difference of optimization, the only number is set in parentheses and this number is the initial value of the tolerance in percentage. The directive VARPAR has the syntax:

VARPAR <var_name>(<initial_tolerance>) {,<var_name>(<initial_tolerance>)};

where
<var_name> = name of the variable parameter. Any symbolic parameter or linear two-terminal component can be set as variable one,
<initial_tolerance> = initial tolerance value (in percentage) to start the search with. It is advisable to set this value as accurate as possible.

It is strongly advised that the Multivariant Analysis be run in advance to get some idea about the initial values.

Example:

VARPAR R1(5), ALFA.TRAN(5), C2(3);

The following directive is equivalent to the above one

VARPAR R1, ALFA.TRAN(5), C2(3);

The maximum deviation of R1 and ALFA.TRAN from the nominal value is set to 5%, and C2 - to 3%.

The directive TOLE lists the parameters with their already known tolerances. These must be taken into account while assigning the tolerances for the VARPAR parameters:

TOLE <var_name>(<tolerance)> {,<var_name>(<tolerance>)};

where

<tolerance> = parameter tolerance in percentage.

The output characteristics under control and their feasible deviation range are stated by the CONTROL directive:

CONTROL <char_name>(<lower_boundary>,<upper_boundary>){,<char_name>(<lower_boundary>,<upper_boundary>)};

where
<char_name> = name of the characteristic determined in the FIX, INT, or FUNC directive,
<lower_boundary>, <upper_boundary> = feasible boundary of an output characteristic deviation (in percentage).

Example:

FIX F1=FIXA(UR1, 0.1);
FIX F2=FIXA(UR1, 0.5);
INT T1=F2-F1;
FUNC T2=F4(3,5,6/F1,F2,T1);
CONTROL F1(5,5),T1(6,6),T2(3,7);

In the example three output characteristics are monitored in the directive CONTROL: F1, T1, T2. F1 was sought to be determined in the FIX directive, T1 - in the INT directive and T2 - in the directive FUNC. Note that boundaries in the last characteristic are unequal. ALLTED can not handle unequal bounderies at this time so the boundaries will be set equal to the larger of the two values.


Chapter 12

Interactive forming of Task file

As it was shown, ALLTED supports ten different types of circuit design procedures. These are:

  1. DC Analysis (Operating Point Analysis).
  2. AC Small Signal Analysis (Calculates frequency responses).
  3. TR (Transient) Analysis (Calculates the time domain response).
  4. MV (Multi-Variants) Analysis in frequency and time domains.
  5. FR (Fourier) Analysis.
  6. SA (Sensitivity) Analysis for DC, AC and TR.
  7. WC (Worst Case) Design for DC, AC and TR.
  8. OP (Parametric Optimization) for DC, AC and TR.
  9. TS (Tolerance Optimal Assigment) for DC, AC and TR.
  10. ST (Statistical) Analysis.

All analyses are available as commands from the Menu bar of the Task file window where corresponding buttons are located (Fig. 12.1). All analysis commands require additional control parameters to be specified in dialog boxes, which appear when one of the commands is chosen.

Fig.12.1. Task file window.

The given Task file window has two operation modes:

  • automatic (with the toolbar), Fig. 12.2;
  • hand-held (entering task text from the keyboard), Fig. 12.1.

For switching modes it is necessary to select the Manual-Auto Switch button which is the third in the Menu bar (Fig. 12.1).

Fig.12.2. Automatic mode of Task file forming.

The toolbar buttons show analysis being selected (a button is pushed – an analysis is switched on). The DC and TR analyses are active in Fig. 12.1.

To make any analysis active, it is necessary to choose Task \ Properties button (the first button in the Menu bar), and to mark desirable analyses in area Enabled Analysis of the control bookmark General (Fig. 12.3).

Fig.12.3. Task Properties window

The field Scheme file of the Task Properties window (Fig. 12.3) is intended for the particular circuit description file name.

The area Library is intended for library selection. To include the library, it is necessary to push the button Add and to select the necessary library name, the button Delete is used for deleting of the library and the button Edit - for editing of a library title.

The necessary types of analysis are carried out by choosing of appropriate bookmark names in the Task Properties window (Fig. 12.3) or by choosing corresponding buttons in the Task file window (Fig. 12.1).


Chapter 12

DC Analysis

The dialog box for the DC Analysis is shown in Fig. 12.4. The area Constants is intended for a set of options with values specification (see Chapter 5.2). To reset one of the options it is necessary to click right mouse button on the field Value (to the left of a constant value) and enter a new value. If it is necessary to discard change, it is enough to push the button Default.

Fig.12.4. Dialog box for DC Analysis.

To define output variables for calculating and typing it is necessary to use the button Output Variables, which opens the Dialog box for Outputs (Fig. 12.5).

Fig.12.5. Dialog window for DC Output Variables.

For typing different variables in the same table it is necessary to enter variable names into one line in area Output Variables. Push Add button in this area, and then the selected variable names will appear in Items area (Fig. 12.5). It is possible to correct variable selection by using buttons Add, Edit and Delete of Items area. For typing same variables in different tables, it is necessary to add new lines in area Output Variables (Fig. 12.5). For defining output parameters to be calculated and typed it is necessary to use the Output Parameters button (Fig. 12.4), which opens the corresponding Dialog window (Fig. 12.6).

Fig.12.6. Dialog window for Output Parameters specification

Output Parameters are defined with commands FIX, INTERVAL and FUNCTION (see Chapter 2). To enter the command FIX, it is necessary to push Add button in FIX area (Fig. 12.6). The corresponding Dialog window will appear (Fig. 12.7).

Fig.12.7. Dialog window for selecting FIX functions.

The name of new function is entered in the field Name. It is possible to select a standard function from the list box on the right. The Description area contains a brief help information about the using of a standard function. The Parameters area is intended for filling function FIX arguments and their parameter values. After filling in all the fields it is necessary to push the button Ok.

To enter a new interval variable into area INT (Fig. 12.6), it is necessary to push the Add button near this area. The corresponding Dialog window will appear on the screen (Fig. 12.8).

Fig.12.8. Dialog window for selecting INT descriptions.

The new interval name is entered in the field Name. The Fix1 and Fix2 fields are intended for choosing an interval description from two list boxes with existing FIX values introduced before. After filling in all the fields it is necessary to push the Ok button.

The procedure of introducing a new function FUNC completely coincides with the procedure of a function FIX specification by using the list box with standard functions numbers and descriptions. The Edit and Delete buttons are intended for editing and deleting input data in appropriate areas of the Dialog window for Output Parameters (Fig. 12.6). An example of this window with the data filled is presented in Fig. 12.9.

Fig.12.9. An example of the filled Output Parameters window.


Chapter 12

AC Analysis

The Dialog box for AC Analysis is shown in Fig. 12.10. To open it, you should choose the bookmark AC from the Task Properties window (Fig. 12.3).

Fig.12.10. Dialog box for AC Analysis.

To begin with, it is necessary to specify if the AC Analysis will be performed in a frequency band or at the particular number of frequencies. If there is a mark point near the Freq field (Fig. 12.10), the first mode is selected and it is necessary to enter lower and upper frequency band values into the appropriate fields. In other way the Sweep mode is selected and it is necessary to type a set of particular frequencies values in the Sweep field.

The Transfer Function area is intended for transfer function definition. Its name is entered in the Name field and appropriate output and input variables are entered in the Output and Input fields (Fig. 12.10).

Options specification (Constants box), described in Chapter 5.3, is organized in the same way as for DC Analysis.

Selection procedures for Output variables and Output parameters are also very similar to the previous ones except some changes in the Dialog window for Output Variables (Fig. 12.11) where output variables (amplitude-frequency and phase-frequency characteristics) can be selected not only for typing, but also for plotting in the different forms (linear or logarithmic scales). To enter new characteristics into area Output Variables (Fig. 12.11), it is necessary to push the Add button near this area. After selecting Type of presentation it is necessary to push the Add button near area Items (Fig. 12.11). The corresponding Dialog window will appear on the screen (Fig. 12.12) where a user can enter the characteristics names in the Name field and their types (Re, IM, MA, DB, PH and RAD).

Fig.12.11. Dialog window for AC Output variables

Fig.12.12. Dialog window for frequency-domain characteristics selection


Chapter 12

Transient Analysis

The Dialog box for TR Analysis is shown in Fig. 12.13. To open it, you should choose the bookmark TR from the Task Properties window (Fig. 12.3).

The Final time field of this box is used for definition of upper time limit by user.

Options specification (Constants box), described in Chapter 5.4, is organized in the same way as for DC and AC Analyses. Selection procedures for Output variables and Output parameters are also very similar to the previous ones for AC Analysis except some changes in the Dialog window for Output Variables (Fig. 12.14) where different output variables (voltages, currents, second output parameters etc.) can be selected for plotting as functions of time, any other variables or parameters being selected in the Argument field (Fig. 12.14).

Fig.12.13. Dialog box for TR Analysis

Fig.12.14. Dialog window for TR Output Variables


Chapter 12(MVA)

Multi-variant Analysis (MVA)

The Dialog box for MVA Analysis is shown in Fig. 12.15. To open it, you should choose the bookmark MVA from the Task Properties window (Fig. 12.3).

Fig.12.15. Dialog box for MVA Analysis

The Rel area of this box allows selecting argument control mode (see the Chapter 7).

The Numb field of the Options area contains a number of simulations specified by user.

There are two new areas in the Dialog box in Fig. 12.15 for variable parameters and control parameters. The Var Parameters area allows specifying the values of variety range for parameters, which are selected to change during MVA Analysis. To enter a new range, it is necessary to push the Add button that opens the corresponding Dialog window (Fig. 12.16).

Fig.12.16. Dialog window for Variable Parameters selection

It is necessary to introduce the variable parameter name into the Name field of this window and put lower and upper bounds of its variety in the Min and Max fields (Fig. 12.16).

The Control area (Fig. 12.15) is intended for specification of control parameters names and their changeable value limits. The Name field allows selecting any control parameters from FIX, INT and FUNC lists defined during previous DC, AC and TR analyses setting. To enter a new control parameter, it is necessary to push Add button in the Dialog box in Fig. 12.15 and fill in the Dialog window that is shown in Fig. 12.17.

Fig.12.17. Dialog window for Control Parameters selection


Chapter 12

FOUR Analysis

The Dialog box for FOUR Analysis is shown in Fig. 12.18. To open it, you should choose the bookmark FOUR from the Task Properties window (Fig. 12.3).

Fig.12.18. Dialog box for FOUR Analysis

The Method field of this box allows selecting the Fourier analysis type, and the Realization field is intended for selecting its implementation way: in particular time points or with interpolation. The Spectr area is intended for specifying Fourier analysis outcomes (output variables), for which spectrograms will be calculated. If Add button in this area is pressed, the corresponding Dialog window appears on the screen (Fig. 12.19).

Fig.12.19. Dialog window for FOUR Variables selection

The Name field of this window contains the name of the output variable being selected, Lower freq. and Upper freq. fields contain the lower and upper frequencies of the frequency band.

Options specification (Constants box), described in Chapter 6, is organized in the same way as for DC, AC and TR Analyses.


Chapter 12

Sensitivity (SA) and Worst Case (WCD) Analysis

The Dialog box that is common for SA and WCD Analyses is shown in Fig. 12.20. To open it, you should choose the bookmarks SA and WCD from the Task Properties window (Fig. 12.3).

Fig.12.20. Dialog box for SA and WCD Analysis

Options specification (Options area), described in Chapter 8, is organized in the same way as Constants area for DC, AC and TR Analyses. The Var Parameters area is used in the same way as during the MVA Analysis for variable parameters selecting and setting.


Chapter 12

Optimization

The Dialog box for Optimization procedure is shown in Fig. 12.21. To open it, you should choose the bookmark OPTIM from the Task Properties window (Fig. 12.3).

Fig.12.21. Dialog box for Optimization

This box is very similar to the previous ones. The Constants and Var Parameters areas are completely identical to ones described earlier in Fig. 12.4 and 12.15. The Method field is used for specifying the selected optimization method number.

But there are two new OF and LIMIT buttons for selecting objective functions and constraint functions (see Chapter 9). They open corresponding Dialog windows (Fig. 12.22 and Fig. 12.23) which are similar to the Dialog window for Output Parameters selection (Fig. 12.6). A user has to specify a function name in the Name field, select the proper standard functions from the corresponding list boxes and enter variables and constants for these functions.

Fig.12.22. Dialog window for Objective functions selection

Fig.12.23. Dialog window for Constraints Definition


Chapter 12

Optimal TOLERANCEs Assignment (TOLAS)

The Dialog box for TOLAS procedure is shown in Fig. 12.24. To open it, you should choose the bookmark TOLAS from the Task Properties window (Fig. 12.3).

Fig.12.24. Dialog window for TOLAS Analysis

It can be seen that this window contains the areas Constants, Var Parameters and Control for options value setting and variable and control parameters specifications (see Chapter 11), which are similar to those have been already described in Fig. 12.4 and 12.15.


Chapter 12

Statistical Analysis (STA)

The Dialog box for STA Analysis is shown in Fig. 12.25. To open it, you should choose the bookmark STA from the Task Properties window (Fig. 12.3).

Fig.12.25. Dialog window for STA Analysis

Here only Control area is the same as in previous windows in Fig. 12.15 or Fig. 12.24. The Method field is used for selecting a statistical analysis method number to be implemented (see Chapter 12). The Numb field contains the selected number of simulation runs for Monte-Carlo procedure.

The Parameters area is intended for specification of statistically changed circuit parameters. If the Add button is pressed, the corresponding Dialog window appears on the screen (Fig. 12.26).

Fig.12.26. Dialog window for Statistical parameters selection

In this window a user introduces a statistical parameter name into the Name field, the type of the distribution law into the field Law and specifies lower and upper bounds of the selected distribution law in Down and Up fields. The selection shown in the Dialog window in Fig. 12.26 describes the resistor R3 with a parameter value that is distributed from 290 to 310 kom in according to the normal distribution law (number 1).

The Histograms button (Fig. 12.25) allows specifying variables for which output histograms must be calculated. If this button is pressed, the corresponding Dialog window is open (Fig. 12.27). A user has to enter as separated lines in the Name field names of desired histograms with their parameters (see Chapter 12).

Fig.12.27. Dialog window for Histograms setting

Have returned to the Task file window (Fig. 12.1), let mention again first three Menu bar buttons:

Task \ Properties button for calling Task Properties window (Fig. 12.3)

a button for Refreshing Content of Task file during its editing

a button for Manual-Auto description switching (Fig. 12.1 and Fig. 12.2)

After completing of the Task file interactive forming it can be executed by choosing Task \ Compile button from Menu bar of the Main ALLTED Studio Window.


Chapter 13

Schematic Editor (SchEd)

SchEd, the schematic editor, has the general features of schematic editing and symbol editing functions, to be used for digital and analog system/circuit design. SchEd has powerful features like on-line ERC (Electrical Rule Checking), customization of an instance, unlimited undo/redo, etc.

Using SchEd

The GUI(Graphic User Interface) of SchEd is shown below.

The Basics of SchEd

Window Title Bar
If the schematic or symbol data is opened, this bar shows the toolname, SchEd, with current data name and view type.

Pull-down Menu
The Pull-down Menu displays the commands available in SchEd. However, some of implicit commands are not listed in the pull-down menu such as "select an object". Most of them have shortcut keys (binding key).

Toolbars
Toolbars provides easy access to the specific command.

Standard Toolbar
This toolbar provides the access to basic commands.

Shaped Toolbar
This toolbar provides the access to editing commands of the object.

Object Toolbar
This toolbar provides the access to placing ports or drawing symbols.

Window Control Button
Window Control Button acts the same way as the other window-based application windows. Left button minimizes the window. Middle button maximizes the window. Right button closes and exits entire window.

Design Manager Window
The Design Manager Window appears when you open a design context file. This window shows the hierarchy of the design.

Status Bar
Status Bar shows the status. In the middle part, you will see the X and Y coordinates of the mouse cursor on active working window. NUM LOCK status is displayed at the far right.

Working Windows
In the Working Window, your circuit drawing is performed. There are two kinds of Working Windows: one is Schematic View Window and the other is Symbol View Window. Designer can open multiple windows to work on simultaneously. It is limited by the memory capacity of the computer.

Schematic View Window
Schematic View Window is the window where your circuit design is drawn or edited. You have to use the schematic view, not the symbol view, to draw a schematic.

Symbol View Window
Symbol View Window is the window your symbol is edited. You have to use the symbol view, not the schematic view, to draw symbols.

The Basics of Schematic View Editing
The first step of using SchEd is to make a directory at Windows Explorer to maintain the example data. At C:\myanalog\demo directory, click OK the right button to bring up the pop-up menu and then select New -> Folder. Then type the name of directory as mydir.

Creating a new MDC File and User’s Job Library

MDC File
MDC (MyCAD Design Context) file contains the information about library names and their position. Click with the right mouse button at Design Manager Window, and select NEW Design Context... (or Choose File -> New Design Context). Move to the directory created and type new mdc filename at "File Name" The extension mdc doesn’t need to be typed because it is automatically attached.

Click Save with the left mouse button, then the following dialog box is displayed. Click on OK.

Note: Whenever you create a new mdc file, SchEd automatically makes a library file where mdc file is located. The library file name is like name of mdc file. It needs to control your schematic job entries.

Library File
It contains the information about cell names.

Creating a new Cell
Click circuits on Design Manager Window with the right mouse button, and select Create Cell…. Select Cell Name and type Cell name as inv. Click on OK.

The above procedure only creates the cell directory where mdc file is. If you want to create new cell and view of it simultaneously, you choose File -> New…. Then Create View Dialog box is displayed.

Type inv in the Cell Name, and click the arrow button on the right of the View. Then the view type lists are displayed as following:schematic, symbol, truthtable, statetable, rom, ram, LogicEquation, statediagram. Select schematic. Click on OK. The following window is displayed.

Creating View

The following sequence is executed to create a type of view. Click on the circuit\inv in Design Manager Window with the right mouse button (where inv means the cell)

and select Create View… (or choose File -> Open…). On View Name, Click the arrow button at the right to display the drop-down list: schematic, symbol, truthtable, statetable, rom, ram, LogicEquation, statediagram.
Select one of them and Click on OK. The view window that you select will be shown.

Adding Library
Click with the right mouse button on Design Manager Window and select Add/Remove Library… (or choose File -> Add/Remove Library…)

In the window appeared press Add button.
Locate the directory of the library and register it. Select Allted-Analog.lib file.

Finding Symbols
To find symbol, double click on the library file name with the left mouse button in Design Manager Window. Select Allted-Analog library.

After double click on Allted-Analog with the left mouse button, you will see all Analog library lists.
Place NMOS, PMOS, CAP, VDD and GND at the desired locations in the Schematic View.

The procedure of PMOS symbol placement is as following:
Click on PMOS with the left mouse button from the Design Manager Window.

Then drag to the Schematic View and drop it to the appropriate position in the Schematic View.

Place NMOS, CAP, VDD and GND symbols in the Schematic View. Placing these symbols is shown in the following SchEd window.

Selecting Objects
Note: In the pull-down menu, there is no command entry for select and select by window.

Selecting one Object
You can select an object by clicking it with the left button. Selected object color is changed from blue to green. (Only if you use the default color of SchEd).

Selecting Multiple Objects (Select All)
If you want to select objects one by one, select by clicking the object continuously pressing SHIFT key while selecting the objects. You can also select multiple objects by defining a window. Just press down the left mouse button and drag the mouse from the upper left-hand corner to the button right hand corner to select the objects within the window you specify. Selecting all objects can be easily done by choosing Edit -> Select All.

Deselecting an Object
To deselect an object, click a background away from the object.

Deselecting Multiple Objects (Deselected All)
To deselect all objects, choose Edit -> Deselect All.

Wiring
Wiring is used only in the Schematic View.

The basic of drawing a wire
Click with the mouse left button on working area of the Schematic View. The red-dot is appeared. (Only if you use the default color of SchEd.) Drag the mouse cursor to the end point, then drop. You can draw wire to any direction from the red-dot point.

Another way of wiring (from the symbol object’s end point)
Click the left mouse button on the net point of a symbol object, then drag the mouse to the desired end point of the net and drop.

Another way of wiring (from the port point)
Click the left mouse button on the port point. Then drag the cursor to the desired end point of the net and drop.

Junction
If two wires are connected, then the junction mark is appeared. You distinguish it whether they are connected or not.

Wire Modes
There is three kind of wire mode, horizontal first, vertical first and diagonal. Click Shift button or Ctrl button, then three wiring mode displays.

Moving an Object
Select an object and then drag the mouse to move the object.
Note: In the pull-down menu, there is no command entry for move.

Copying & Deleting
Copying an Object
To copy an object, hold down the CTRL button and click on a desired object to be copied.
Drag the mouse to the specified location for the copied object to be placed.
Note: In the pull-down menu, there is no command entry for copy.

Deleting an Object
Select the object and choose Edit -> Delete.

Rotating
Select Shape -> Rotate Right / Rotate Left.

Connecting Input and Output Ports
Drag and drop input and output Ports in the Object Toolbar.
Select a port object from the Object Toolbar. Drop it on the desired position. Double-click the input port symbol first. Then Port dialog box is displayed.

Type in Name in1 and Click on OK.
For the output port, do the same as the input port.

Check Circuit (Electrical Rule Check)

When overall circuit is completed, choose Tools -> Check Circuit…
Click Check all errors button, and click Start button. At the error message window, the type and the number of the error are displayed.

When the error message in the error message window is clicked, SchEd automatically locates the error. And error messages are displayed in the message window.

The Advanced Commands of Schematic Editing

Removing Library
Click the right mouse button on Design Manager, and select Add/Remove Library…

In the dialog box appeared choose one in the list and press Remove button. And click on OK.
The following dialog box appeares.

Click on OK. Then the entry is removed from the Design Manager Window.

Note: Even though the library is removed from the design manager, the actual data still resides in the hard disk. Only the entry in the design context is removed.

Editing Objects
Undo & Redo
To undo, choose Edit -> Undo. To redo what has been undone, choose Edit -> Redo.

Note: Undo will maintain the undo list even after saving the schematic data. It will not undo the saving but undo the previous edits. The same applies to redo.

Flip Vertical & Flip Horizontal
To flip an object vertically, choose Shape -> Flip Vertical. To flip an object horizontally, choose Shape -> Flip Horizontal.

Copying & Deleting
Copying Objects to the Clipboard
To copy an object to the clipboard, choose Edit-> Copy and then Edit -> Paste. When you paste the object, the object will be located in the middle of active working view window.

Note: In the pull-down menu, Edit -> Copy indicates copying to the clipboard. Only in SchEd, an object can be copied and pasted.

Deleting
Select the object and choose Edit -> Delete.

Array Copy

Choose Edit -> Array Copy. The Array Copy dialog box is displayed.

Check the Two dimension if you want to use two-dimensional array copy feature. It allows whether a two-dimensional array is copied or not. Specify the number at the No. of objects field. Drag and drop with the left mouse button, the array copy is done. You can specify the reference point between objects by mouse click.

View
Redraw
It will refresh the image of the current working window. Choose View -> Redraw.

Whole Page
Choose View -> Zoom Fit. The objects of the current view will be shown fit to the working window.

Zoom In
Choose View -> ZoomIn. It will zoom in by 2.

Zoom Out
Choose View -> ZoomOut. It will zoom out by 2.

Drawing Mode
Net
Choose Draw -> NetMode. Net and wire are interchangeable terms.

Note: In the netmode, only drawing wire is possible. To get out of the netmode, select Draw -> NetMode.

BUS
Choose Draw -> Bus. The color of port changes from brown to gray (if you use the default color of SchEd). Drag it to the desired position and then drop the end point.

Note: In BUS mode, only BUS drawing is possible. To get out of the BUS mode, select Draw -> BUS.

Aligning Objects
Align Left
Select the objects. Choose Layout -> Align Left. Selected objects are aligned to the leftmost object’s position.

Align Right
Selects the objects. Choose Layout -> Align Right. Selected objects are aligned to the rightmost object’s position.

Align Top
Selects the objects. Choose Layout -> Align Top. Selected objects are aligned the uppermost object’s position.

Align Bottom
Selects the objects. Choose Layout -> Align Bottom. Selected objects are aligned the lowermost object’s position.

Space Across
Selects objects more than three. Choose Layout -> Space Across. Selected objects are arranged so that spacing between them becomes the same. The space between objects becomes even in between the left most object and the right most object.

Space Down
Selects objects more than three. Choose Layout -> Space Down. Selected objects are arranged so that the spacing between them becomes same.

Document Information
Choose File -> Document Info…. The following dialog box is appeared.

Title is displayed automatically at the current working window. By clicking Auto Define at Date and Time, date and time are printed automatically. Notes box is displayed on the right hand. It shows other relevant information typed in. These values are printed in the rectangular area on the right hand corner.

Customize
Choose Tools -> Customize, the following dialog box is displayed.

Toolbars can be customized. To customize toolbar, just drag the icon from the Buttons group at the right of Commands tab and drop it the toolbar you are customizing. To remove a command from the toolbar, just drag it from the toolbar and drop it outside of the toolbar.

Options
Choose Tools -> Options. The following dialog box is displayed to select Option values. Option dialog box is consisted of five tips (pages), namely Color, Data Tip, Print, Show/Hide and Path.

Color

The following Color Page determines the default color of each object. Select one of Object Type whose color to be changed, then selected object color is displayed in Color page. If you want to change the color to another, click Change Color...
The following dialog box is appeared.

Select the color. The changed color does not automatically apply to the object that was drawn before changing the color. It only applies to the drawing object after changing.

Data Tip
The Data Tip page follows.

Check on Show Datatip field if you want to show datatip.
Checking on Object Name, Schematic Describer, Symbol Port Name and Symbol Port Type determines whether related datatips are showed or not.
Object Name
If you check on Object Name, Object Name datatip will be displayed in Schematic View. Object Name datatip are the object type and the object name.
Schematic Describer
If you check on Schematic Describer, Schematic Describer datatip will be displayed in Schematic View. Schematic Describer datatip shows the object type and the information of object.
Symbol Port Name
If you check on Symbol Port Name, Symbol Port Name datatip will be displayed at the Symbol View. Symbol Port Name datatip is the only symbol port name command.
Symbol Port Type
If you check on Symbol Port Type, Symbol Port Type datatip will be displayed in Symbol View. Symbol Port Type datatip is the only symbol port direction command.

Print

Line width determines the thickness of the lines to be printed. Select Thin, depicts the thinnest line width to be printed. Normal depicts the standard thickness and Thick the thicker lines.

Show Document Info
It determines whether to print the Document Info… or not. If you check off this field, then the Document Info will not be printed. (Detail things are refer to Document Info…)

Turn on Fix Schematic Printing Factor
It determines whether Fix the Schematic Printing Factor is applied or not when print. If you check on this field, then the printing scale is fixed regardless of schematic design size.

Show/Hide

Only checked selection is displayed.

Symbol names
It determines whether to show symbol name or not at the Schematic View.

Port names
It determines whether to show port name or not at the Schematic View.

Net names
It determines whether to show net segment name or not at the Schematic View.

Instance names
It determines whether to show instance name or not at the current working view.

Connected points
It determines whether to show the connection point between symbol and wire or not.

Document origin
It determines whether to show the document origin or not at the current working view.

Properties
It determines whether to show instance properties or not at the current working view.

Instance port names
It determines whether to show instance port names or not at the current working view.

Grid
It determines whether to show the grid or not at the current working view. The number to the right specifies the space between grids. (Where space means the unit space of SchEd.)

Path
It links other tools to SchEd.

Making Symbol
Choose Tools -> Make Symbol... The following dialog box appears.

Click on OK. The symbol is generated automatically. (Symbol icon under the cell name.)

Making Image File

Choose Tools -> Make Image File. The following dialog box appears.

It makes the data of current working view schematic to copy the clipboard.You can select one of image file type by opening the drop down list box next to Type field, BMP, GIF or TIFF.

Using Symbol Editor
Schematic Editor and Symbol Editor is integrated in SchEd.

Preparing Symbol View
Select File -> New, Create View Dialog is appeared.

Type inv on the Cell Name field.
Then click the arrow button at the right the View and select symbol.

Note: Symbol View could be made from the Schematic Editor by choosing Tools -> Make Symbol at SchEd menu. It is more general case to make the Symbol View.

Drawing in Symbol View
Ports
Symbol port is classified as input, output and input-output.
Input Symbol Port
Output Symbol Port
Input-output Symbol Port

Select Add -> Port at the pull-down menu. Select port type at sub-menu.

Or click port type toolbar at Object Toolbar, then drag and drop at your desired position.

Objects
Select Add -> Figure at the pull-down menu. Select the type at the sub-menu.
Or click the object toolbar at Object Toolbar, then drag and drop at your desired position.
(1) Line

Select Line object. Handles are shown at both ends of the line as the diagram. The line is positioned and the length is changed by moving the handle.

(2) Rectangle

Select Rectangle object. The four handles are displayed. By posioning each handle to the desired position, the rectangle is formed with positioned corners.

(3) Circle

Select Cirle object. Four handles are shown. The size of the circle is determined by moving four handles.

(4) Arc

Select Arc object. Three handles are shown. Positioning the two end points to the desired end points, and moving the middle handle to the desired are shape. The position and form of the Arc is determined by the positions of three handles.

(5) Text

Select Text object. Double-click at the text field. Text editing dialog box is displayed.

Type in the text in the Content box. Select Height, Alignment, Angle, Color. The appropriate text is displayed with selected features.

Passing the parameters to your design
Select an instance, PMOS, for example, at Schematic View, then click on PMOS with the right mouse button. The pop-up menu is displayed.

Select Properties…. The Instance dialog box is displayed, then select Properties page.

The following dialog box is displayed.

Select property from the property list window, then click on Change. The following dialog box is displayed.

Here you can modify the value of the specific property.
If you want to add a new property item and specify a value fot it, click on Add at Instance dialog box.

Note: Even though you change or add the properties of symbol at symbol view after used it at schematic view, SchEd dos not automatically pass them to the schematic data.

ALLTED Object Description Generator
Logic2Allted, the ALLTED Object Description Generator, translates SchEd netlist to Allted object description.

To invoke ALLTED Object Description Generator from SchEd
(1) Choose Tools -> Export -> Allted at SchEd pull-down menu. The ALLTED Object Description Generator will be appeared.
(2) Specify Result File by typing the result file with absolute path or click Browse button at the right Result File field and locate file if the result file not defined.
You can also use ALLTED Object Description Generator from ALLTED Studio.
In that case, you should specify context file, library, cell, and result file in ALLTED Studio settings, and ALLTED Object Description Generator works in background mode, without displaying its window. This window might appear only in the case of happening an error during translation. After translation, you have schema description in ALLTED input language in your ALLTED Studio project.

Using ALLTED Analog Components’ Models in SchEd

In the table below (Comparison of ALLTED and AIM-SPICE Models) you could find accordance between AIM-SPICE and ALLTED analog components’ models as well as functions describing the behavior of different types of sources. Note that in a case of identical model names, the names of their arguments and parameters coincide as well.

Comparison of ALLTED and AIM-SPICE Models

Type of a component | AIM-SPICE |  | ALLTED
 | Initial letter | Models | Initial letter | Models
Heterostructure Field Effect Transistors (HFETs) | A | HFET | In stage of development
Non-linear Dependent Sources | B | Expression | E, J | User-defined function
Capacitors | C | Value C Absent | C | Value Absent FCAP
Diodes | D | D, level 1 (Berkeley standard diode model) D, level 2 (GaAs heterostructure diode model) Absent | D | D Absent ST (Zener diode model)
Linear Voltage-Controlled Voltage Sources | E | Linear relation POLY | E | FLIN FPOLY
Linear Current-Controlled Current Sources | F | Linear relation POLY | J | FLIN FPOLY
Linear Voltage-Controlled Current Sources | G | Linear relation POLY | J | FLIN FPOLY
Linear Current-Controlled Voltage Sources | H | Linear relation POLY | E | FLIN FPOLY
Independent Current Sources | I | Value PWL PULSE SIN EXP SFFM Absent | J | Value FPWL FPULSE FSIN FEXP FSFFM FTAB
Junction Field-Effect Transistors (JFETs) | J | NJF PJF | F | NJF PJF
Coupled Inductors (transformers) | K | Coupling coefficient | L | FMUT
Inductors | L | Value Absent | L | Value FIND
Metal Oxide Semiconductor Field Effect Transistors (MOSFETs) | M | NMOS, PMOS Level 1 (Shichman-Hodges) Level 4 (BSIM) Level 2, 3, 5-12 | M | MOST BSIM Absent
Heterojunction Bipolar Transistors (HBTs) | N | HNPN, HPNP | Absent
Lossy Transmission Lines (LTRA) | O | LTRA | Absent
Bipolar Junction Transistors (BJTs) | Q | NPN PNP Absent Absent Absent | Q | NPN PNP LPNP PNPEM (Ebers-Moll model) NPNEM (Ebers-Moll model)
Resistors | R | Value R Absent | R | Value Absent FRES
Voltage Controlled Switch | S | SW | R | FVSWIT
Transmission Lines (Lossless) | T | Characteristic impedance, transmission delay | Absent
Uniform Distributed RC Lines (URC) | U | URC | Absent
Independent Voltage Sources | V | Value PWL PULSE SIN EXP SFFM Absent | E | Value FPWL FPULSE FSIN FEXP FSFFM FTAB
Current Controlled Switch | W | CSW | R | FISWIT
GaAs Metal Semiconductor Field Effect Transistors (MESFETs) | Z | NMF, PMF (three levels) | In stage of development


Examples

Active Filter AC Analysis (RAD1_AC.ATD)

This example demonstrates how an analog circuit with the linear model of an operational amplifier is analyzed.

In circuit RAD (Fig.13.1) there are 2 operational amplifiers which are simulated by simple linear models.

Fig. 13.1. Active filter with 2 operational amplifiers.

The circuit description in the ALLTED input language is shown below:

Object;
circuit RAD;
# Filter;
R1(1,2)=380;
R2(2,0)=35.7;
R3(2,4)=300;
R4(5,0)=5;
R5(5,6)=106.8;
R6(6,7)=65.8;
R7(4,8)=450;
C1(4,0)=1.135;
C2(7,8)=1.135;
Q1(4,5,6,0)=OPAMP;
Q2(4,7,8,0)=OPAMP;
E1(1,0)=1;
Model OPAMP(4,5,6,0);# linear model OPAMP;
R8(4,5)=1000;
R10(6,0)=1;
C3(6,0)=640;
J1(0,6)=FL(4E3/UR8);
&

The objective of the analysis is to determine the
frequency response as ratio V6/UE1 plotted on a graph as the
amplitude-frequency and phase-frequency characteristics in the
frequency range from 0.0025 mHz to 0.005 mHz.

The task of the analysis written in the ALLTED input language is:

task
DC; # DC mode;
AC; # Frequency analysis;
CONST LFREQ=0.0025,UFREQ=0.005;
TF KU=V6/UE1; # Transfer function;
# Output plot;
PLOT MA.KU,PH.KU;
&
end

The output results are shown below.

Active filter RAD. Frequency characteristics.


Examples

Active Filter - Parameter Modification (RAD_AC.ATD)

The objective of this example is to illustrate how the influence of given parameters on specified output characteristics can be determined. The active filter RAD described in the previous example is analyzed here with the aid of the MODIFY directive. Three superimposed amplitude-frequency characteristics are plotted with capacitance C3 (Fig.13.1) of operational amplifiers Q1 and Q2 changing its value from 640 nF to 200 nF and then to 1000 nF. To speed up the computation, the analysis is performed only at frequencies listed in the directive SWEEP. The task to perform an investigation looks like:

task;
DC;
AC;
SWEEP FREQ(0.0025,0.0028,0.003,0.0035,0.0038,0.004,0.0043,0.0045,0.005);
CONST LFREQ=0.0025,UFREQ=0.005;
CONST DCMET=2,NVAR=3;
TF ku=v6/ue1;
PLOT ma.ku(50);
PLOT PH.KU(50);
SAVE;
&
task;
MODIFY c3.q1=200,c3.q2=200;
SAVE;
&
task;
MODIFY c3.q1=1000,c3.q2=1000;
&
end;

The output results are shown below.

Active filter RAD_AC. Amplitude-frequency characteristics at different C3 values.

Active filter RAD_AC. Phase frequency characteristics at different C3 values.


Examples

4-Bit Counter Transient Analysis (CNTR8_TR.ATD)

This example demonstrates the simulation of digital circuits with logical units being represented by the macromodels.

Four JK-triggers Q1-Q4 and three AND elements Q5-Q7 are used in the decimal counter CNTR circuit shown in Fig 13.2. The first three units Q1-Q3 perform the T-trigger function because similar signals are applied to their J and K inputs; the last one is JK-trigger as natural. The description of the counter is shown below.

Fig. 13.2. 4-bit counter.

OBJECT;
CIRCUIT CNTR;
Q1(1,2,2,3,1,4,5,0)=TTL.JKFF;
Q2(1,12,12,3,1,6,7,0)=TTL.JKFF;
Q3(1,13,13,3,1,8,9,0)=TTL.JKFF;
Q4(1,14,4,3,1,10,11,0)=TTL.JKFF;
Q5(4,11,12,0)=TTL.2AND;
Q6(6,4,13,0)=TTL.2AND;
Q7(6,4,8,14,0)=TTL.3AND;
EC(3,0)=TAB1(TIME);
ERS(1,0)=TAB2(TIME);
EJK(2,0)=3.4;
R1(5,0)=100;
R2(7,0)=100;
R3(9,0)=100;
R4(10,0)=100;
TAB1=0,0.8,5,0.8,5.2,2.8,10,2.8,10.2,0.8;
TAB2=0,2.8,3,2.8,3.2,0.8,120,0.8;
#
Model JKFF(1,2,3,4,5,6,7,0);
# JKFF JK Flip Flop;
# Inputs: 1-Reset,2-J,3-K,4-Clock,5-Set,
# J,K - data to be clocked,
# Clock - clock signal positive edge triggered,
# Reset - resets output to a logic L,
# Set - sets output to a logic H;
# Outputs:6-Q,7-Q_,
# Q_ is the complement of Q;
#basis node - 0;
JR(1,0)=F303(VT,VIL,IIH,IIL/UJR);
JJ(2,0)=F303(VT,VIL,IIH,IIL/UJJ);
JK(3,0)=F303(VT,VIL,IIH,IIL/UJK);
JC(4,0)=F303(VT,VIL,IIH,IIL/UJC);
JS(5,0)=F303(VT,VIL,IIH,IIL/UJS);
E1(6,0)=F356(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,1/UE1,IE1);
E2(7,0)=F313(RH,RL/IE2);
R1(6,0)=1000; R2(7,0)=1000;
#
LIST TTL.JKFF;
# Units - v,ma,kohm,nf,us;
VT=1.4; VIL=0.8; IIH=0.05; IIL=-1.6; VOH=3.4; VOL=0.2;
TPLH=0.025;
TPHL=0.04; RH=0.12; RL=0.062;
#
Model 2AND(1,2,17,0);
# 2AND-2_Input AND Gate;
# Inputs - 1,2;
# Outputs - 17;
# Base node - 0;
J1(1,0)=F303(VT,VIL,IIH,IIL/UJ1);
J2(2,0)=F303(VT,VIL,IIH,IIL/UJ2);
E1(17,0)=F310(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,1/UE1,IE1);
R1(17,0)=1000;
#
LIST TTL.2AND;
# Units - v,ma,kohm,nf,us;
VT=1.4; VIL=0.8; IIH=0.04; IIL=-1.6; VOH=3.4; VOL=0.2;
TPLH=0.022;
TPHL=0.016; RH=0.12; RL=0.062;
#
Model 3AND(1,2,3,17,0);
# 3AND-3_Input AND Gate;
# Inputs - 1,2,3;
# Outputs - 17;
# Base node - 0;
J1(1,0)=F303(VT,VIL,IIH,IIL/UJ1);
J2(2,0)=F303(VT,VIL,IIH,IIL/UJ2);
J3(3,0)=F303(VT,VIL,IIH,IIL/UJ3);
E1(17,0)=F310(VOH,VOL,-1,TPLH,-1,TPHL,RH,RL,1/UE1,IE1);
R1(17,0)=1000;
#
LIST TTL.3AND;
# Units - v,ma,kohm,nf,us;
VT=1.4; VIL=0.8; IIH=0.04; IIL=-1.6; VOH=3.4; VOL=0.2;
TPLH=0.022;
TPHL=0.016; RH=0.12; RL=0.062;
&

The task consists of a DC and a TR analysis. The nodal voltages V3, V4, V6, V8 reflect output stages of triggers in each time discrete during the period from 0 uS to 120 uS.
The task can be written in the following form:

TASK;
DC;
TR;
CONST TMAX=120;
PLOT V3, V4, V6, V8;
&
END


Examples

The output results are shown below.

4-bit counter. Nodal voltage V3.

4-bit counter. Nodal voltage V4.

4-bit counter. Nodal voltage V6.

4-bit counter. Nodal voltage V8.


Examples

XOR_Cell_MOS_gate - Transient Analysis (MOS_G_TR.ATD)

Fig. 13.3. XOR_Cell_MOS gate.

This example demonstrates the simulation of an analog circuit with a MOS-transistor. There are 8 MOS-transistors in the circuit XOR_Cell_MOS_gate (Fig.13.3) which are simulated by the PSpice-MOS-transistor model (level 1).

The circuit description is developed in the following form:

Object;
Circuit XOR_Cell_MOS_gate;
# Source of energy;
Edd( 10, 0) = 5;
# Input sources;
EinC0( C0 ,0) = 5;
# Pulse signal;
EinA0( A0 ,0) = Fpulse( 0, 5, 2.n, 1.n, 1.n, 50.n, 200.n );
#
Xsum0( A0, C0, SUM0, 10, 0) = XOR;
# Load ;
Rs0( SUM0,0 ) = 100.MEG;
Cs0(SUM0,0)=1.p;
#
Model XOR (inA, inC, Xout, 10, 0);
# inA, inC - input pins;
# Xout - output pin;
# 0 - ground pin;
# Input cascade
m11( 1, inA, 0, 0) = Ndef.most( L=2.u, W=10.u, rd=20, rs=20);
m12( 2, inC, 1, 0) = Ndef.most( L=2.u, W=10.u, rd=20, rs=20);
m13( 2, inA, 10, 10) = Pdef.most( L=2.u, W=5.u, rd=20, rs=20);
m14( 2, inC, 10, 10) = Pdef.most( L=2.u, W=5.u, rd=20, rs=20);
# Output cascade
m21( 3, inC, 0, 0) = Ndef.most( L=2.u, W=10.u, rd=20, rs=20);
m22( 3, inA, 0, 0) = Ndef.most( L=2.u, W=10.u, rd=20, rs=20);
m23(Xout, 2, 3, 0) = Ndef.most( L=2.u, W=10.u, rd=20, rs=20);
m24(Xout, inA, 4, 10) = Pdef.most( L=2.u, W=10.u, rd=20, rs=20);
m25( 4, inC, 10, 10) = Pdef.most( L=2.u, W=10.u, rd=20, rs=20);
m26(Xout, 2, 10, 10) = Pdef.most( L=2.u, W=5.u, rd=20, rs=20);
#
Model MOST( D, G, S, B );
# PSpice-MOS-transistor model (level 1);
Rd(D,Din)=RD; Rs(S,Sin)=RS; Rg(G,Gin)=RG; Rb(B,Bin)=RB;
Rds(Din,Sin)=RDS;
Jdrain(Din, Sin) = Fmos1(TYPE, L, W, TOX, VTO, PHI, KP, LAMBDA,
GAMMA, TPG, IS, JS, JSSW, NSUB, UO, LD, WD, AD, AS, PD, PS, CBD,
CBS, CJ, MJ, PB, CJSW, MJSW, PBSW, CGDO, CGSO, CGBO, TT, FC, OFF/
UJdrain,UJCgs,UJCbs);
JCbs(Bin,Sin) = Fmos2(/UJCbs);
JCbd(Bin,Din) = Fmos3(/UJCbd);
JCgs(Gin,Sin) = Fmos4(/UJCgs);
JCgd(Gin,Din) = Fmos5(/UJCgd);
JCgb(Gin,Bin) = Fmos6(/UJCgb);
#
List nDEF.MOST;
# Default values;
TYPE=1; L=100.u; W=100.u; TOX=0.1u; VTO=1; PHI=0.6; KP=2.e-5;
LAMBDA=0; GAMMA=0; TPG=1; IS=1.e-14; JS=0; JSSW=0; NSUB=0;
UO=600; LD=0; WD=0; AD=0; AS=0; PD=0; PS=0;
CBD=0; CBS=0; CJ=0; MJ=0.5; PB=0.8;
CJSW=0; MJSW=0.33;PBSW=0.8;
CGDO=0; CGSO=0; CGBO=0; TT=0; FC=0.5;
RD=1; RS=1; RG=0; RB=0; RDS=1.T; OFF=0;
#
List pDEF.MOST;
# Default values;
TYPE=-1; L=100.u; W=100.u; TOX=0.1u; VTO=-1; PHI=0.6; KP=2.e-5;
LAMBDA=0; GAMMA=0; TPG=1; IS=1.e-14; JS=0; JSSW=0; NSUB=0;
UO=600; LD=0; WD=0; AD=0; AS=0; PD=0; PS=0;
CBD=0; CBS=0; CJ=0; MJ=0.5; PB=0.8;
CJSW=0; MJSW=0.33;PBSW=0.8;
GDO=0; CGSO=0; CGBO=0; TT=0; FC=0.5;
RD=1; RS=1; RG=0; RB=0; RDS=1.T;OFF=0;

The task shown below consists of a DC and a TR analysis.
The nodal voltages VA0, VSUM0 are to be plotted on the time
interval from 0 to 100 uS in common scale.

task;
dc;
tr;
const dcmet=2;
const tmax=100.n;
const minstep=1.e-15,maxdm=30,maxit=30;
plot VA0, VSUM0(-100);
&
end

The results of the transient analysis are represented in
the graph below.

XOR_Cell_MOS_gate. Nodal voltages VA0 and VSUM0.


Examples

ECL Compatible Schmitt Trigger Transient Analysis (ECL_TR.ATD)

An analog circuit with different types of nonlinear transistor model is illustrated in the example. The circuit is ECL compatible Schmitt trigger with PSpice model of BJT-transistor (Fig. 13.4). The description of the circuit in the ALLTED input language is shown below.

Fig. 13.4. ECL compatible Schmitt trigger.

Object;
Circuit ECL_COMPATIBLE_SCHMITT_TRIGGER;
# Input signal;
EIN( 1, 0) = FPWL(0,-1.8, 1,-1.0, 2,-1.8);
# Source of energy;
EEE( 8, 0) = -5;
#
RIN ( 1 , 2)= 50;
RC1 ( 0 , 3)= 50;
R1 ( 3 , 5)= 185;
R2 ( 5 , 8)= 760;
RC2 ( 0 , 6)= 100;
RE ( 4 , 8)= 260;
RTH1 ( 7 , 8)= 125;
RTH2 ( 7 , 0)= 85;
CLOAD( 7 , 0)= 5.p;
# - C -- B -- E - S
T1( 3, 2, 4, 0) = QSTD.NPN;
T2( 6, 5, 4, 0) = QSTD.NPN;
T3( 0, 6, 7, 0) = QSTD.NPN;
T4( 0, 6, 7, 0) = QSTD.NPN;
#
LIST QSTD.NPN;
Is=1.00000e-016; BF=50; NF=1; Vaf=50; Ikf=0; Ise=0;
NE=1.5; BR=0.1; NR=1; Var=0; Ikr=0; Isc=0; NC=2; Rb=50;
IRb=0; Rbm=0; Re=0; Rc=10; Cje=0.4p; Vje=0.8; Mje=0.4;
Tf=5.n; XTf=0; VTf=0; ITf=0; PTf=0; Cjc=0.5p; Vjc=0.8;
Mjc=0.333; XCjc=1; Tr=0; Cjs=1.p; Vjs=0.75; Mjs=0; Xtb=0;
Eg=1.11; Xti=3; FC=0.5; Area=1; Off=0;
#
Model NPN (C,B,E,S);
#PSpice-model of BJT-transistor;
JCE(Cin,Ein)=FBJT1(Is, BF, NF, Vaf, Ikf, Ise, NE, BR, NR,
Var, Ikr, Isc, NC, Rb, IRb, Rbm,Cje, Vje,
Mje, Tf, XTf, VTf, ITf, PTf, Cjc, Vjc, Mjc, XCjc, Tr, Cjs, Vjs,
Mjs, Xtb, Eg, Xti, FC, Area, Off/UJbe, UJbc);
Jbe(Bin,Ein)=FBJT2(/UJbe,UJbc);
Jbc(Bin,Cin)=FBJT3(/UJbc);
Rbb(B,Bin) =FBJT4(/IRbb);
JCbx(B,Cin) =FBJT5(/UJCbx);
JCjs(S,Cin) =FBJT6(/UJCjs);
Rem(E,Ein) =RE;
Rcol(C,Cin) =RC;

The task consists of a DC and a TR analysis. Nodal voltages V1, V7 are assigned to be plotted on the time interval from 0 to 2 uS. The second plot is supposed to exhibit the hysteresis effect by plotting voltage V7 against voltage V1.

task
dc;
tr;
const TMAX=2, MINSTEP=1.E-10;
const DCMET=2,xmax=1.e-3;
PLOT V1,V7;
plot v7(v1);
&
end

Both plots specified in the task are shown below.

Schmitt trigger. Nodal voltages V7 and V1.


Examples

Two_input_NAND cell. Transient Analysis (2NAND_TR.ATD)

A digital circuit with 4 MOS-transistors (Fig.13.5) is considered in the example. The transistors are modeled by the PSpice-MOS-transistor model (level 1).

Fig. 13.5. Two-input NAND cell.

Object;
Circuit Two_input_NAND;
Ess(4,0)=5;
#input signal;
Ein(1,0)=Fpulse( 5, 0, 10.n, 10.n, 10.n, 50.n, 100.n );
Eg(2,0)=5;
#capacitance load;
C1(3,0)=1.p;
#Two_input_NAND;
m1(3,1,4,4) = Pdef.most( L=5.u, W=18.u );
m2(3,2,4,4) = Pdef.most( L=5.u, W=18.u );
m3(3,1,5,0) = Ndef.most( L=2.u, W=18.u );
m4(5,2,0,0) = Ndef.most( L=2.u, W=18.u );
#
Model MOST( D, G, S, B );
# PSpice-MOS-transistor model (level 1);
Rd(D,Din)=RD; Rs(S,Sin)=RS; Rg(G,Gin)=RG; Rb(B,Bin)=RB;
Rds(Din,Sin)=RDS;
Jdrain(Din,Sin) = Fmos1(TYPE,L,W,TOX,VTO,PHI,KP,LAMBDA,GAMMA,
TPG,IS,JS,JSSW,NSUB,UO,LD,WD,AD,AS,PD,PS,CBD,CBS,
CJ,MJ,PB,CJSW,MJSW,PBSW,CGDO,CGSO,CGBO,TT,FC,OFF/UJdrain,UJCgs,UJCbs);
JCbs(Bin,Sin) = Fmos2(/UJCbs);
JCbd(Bin,Din) = Fmos3(/UJCbd);
JCgs(Gin,Sin) = Fmos4(/UJCgs);
JCgd(Gin,Din) = Fmos5(/UJCgd);
JCgb(Gin,Bin) = Fmos6(/UJCgb);
#
List pDEF.MOST;
#default values;
TYPE=-1; L=100.u; W=100.u; TOX=0.1u; VTO=-1; PHI=0.6; KP=2.e-5;
LAMBDA=0; GAMMA=0; TPG=1; IS=1.e-14; JS=0; JSSW=0; NSUB=0;
UO=600;
LD=0; WD=0; AD=0; AS=0; PD=0; PS=0;
CBD=0; CBS=0; CJ=0; MJ=0.5; PB=0.8;
CJSW=0; MJSW=0.33; PBSW=0.8;
CGDO=0; CGSO=0; CGBO=0; TT=0; FC=0.5;
RD=1; RS=1; RG=0; RB=0; RDS=1.T; OFF=0;
List nDEF.MOST;
#default values;
TYPE=1; L=100.u; W=100.u; TOX=0.1u; VTO=1; PHI=0.6; KP=2.e-5;
LAMBDA=0; GAMMA=0; TPG=1; IS=1.e-14; JS=0; JSSW=0; NSUB=0;
UO=600;
LD=0; WD=0; AD=0; AS=0; PD=0; PS=0;
CBD=0; CBS=0; CJ=0; MJ=0.5; PB=0.8;
CJSW=0; MJSW=0.33; PBSW=0.8;
CGDO=0; CGSO=0; CGBO=0; TT=0; FC=0.5;
RD=1; RS=1; RG=0; RB=0; RDS=1.T; OFF=0;
&

The task consists of a DC and a TR analysis. The nodal voltages V3 (output signal) and V1 (input signal) are decided to be plotted on the time interval from 0 to 150 uS.

task
dc;
tr;
const tmax=150.n, minstep=1.e-15, maxdm=30, maxit=30;
plot V3,V1;
&
end

The output plot is shown below.

Two-input NAND cell. Input signal V1 and output voltage V3.


Examples

Amplifier with JFET Elements BER - Transient analysis (BER_TR.ATD)

Fig. 13.6. Amplifier with JFET elements BER.

An analog circuit with operational amplifier and a JFET-transistors is considered in the example.

There are an OPAmp and two JFET-transistors in circuit Ber (Fig.13.6). The models of the OPAmp and transistors are developed with the aid of ALLTED intrinsic functions F1, F7, and F8. The behavioral modeling with the algebraic equations directly specified by the FUNCTION operator is also demonstrated.

Object;
Circuit BER;
# Input signal;
eb(11,0)=Fsin(0,1e-3,1e-3,0,0,0);
# Sources energy;
eg(3,0)=6;
ef(2,0)=-6;
#
r11(6,8)=80;
r10(7,3)=910;
rf(8,0)=1;
r5(10,2)=50;
r6(14,2)=60;
r1(12,11)=15;
r2(12,0)=15e3;
r4(12,0)=5.8e3;
r3(13,0)=100;
c2(13,12)=3300;
c5(6,8)=6.8e-3;
c3(2,0)=22;
c6(5,0)=130e-3;
c7(3,0)=22;
qd3(10,14,6,2,3,7,5,0)=ounm;
qv1(13,10,3)=pc202.pnnk;
qv2(8,14,3)=pc202.pnnk;
#
model ounm(n,i,b,u1,u2,s,fc,0);
# Nonlinear model of OPAMP;
rbx(n,s)=6e3;
rb(i,s)=0.01;
rc1(n,0)=900e3;
rc2(s,0)=900e3;
rp1(u1,0)=5;
rp2(u2,0)=5;
r(fc,0)=100;
r0(a,b)=0.1;
c(fc,0)=0.796;
jcmp(n,0)=5e-3;
jcmm(s,0)=5e-3;
cmp(n,0)=0;
cmm(s,0)=0;
j(0,fc)=f1504(100,3.98,-3.98,3.98e-2,-3.98e-2/urbx);
e(a,0)=f1006(1/uc,urp1,urp2);
#
model pnnk(z,i,c);
# JFET-model;
r(i,c)=r;
czi(z,i)=f7(c0,k,fi/uczi);
czc(z,c)=f7(c0,k,fi/uczc);
jzi(z,i)=f1(i0,teta,umax/ujzi);
jzc(z,c)=f1(i0,teta,umax/ujzc);
jc(c,i)=f8(b,u0,up,m/ujzi);
jc2(i,c)=f8(b,u0,up,m/ujzc);
c1(z,i)=0;
c2(z,c)=0;
c3(c,i)=0;
#
list pc202.pnnk;
#
i0=0.6e-6; teta=30; c0=0.45e-2; fi=0.7; k=0.5; u0=-0.84;
up=0.0; b=0.7795; r=300; umax=1.1; m=0;
#
function f1006(a/x1,x2,x3);
# Voltage-controlled voltage source with bounded value;
if x1<=abs(x2) and x1>=-abs(x3) then a*x1;
else if x1>=abs(x2) then a*x2;
else a*x3;
#
function f1504(a,b,c,d,d1/x);
# Voltage-controlled current source with bounded value;
if x<=d and x>=d1 then a*x;else if x>d then b;else c;
&
The nodal voltages V11, V10 and V8 are set to be plotted
after the transient analysis TR is completed. The task consists
of a DC and a TR analysis.

task
dc;
tr;
const tmax=7e3,minstep=2;
const dcmet=2,parstep=0.1;
plot v11,v10;
plot v8;
&
end

Two output plots are shown below.

Amplifier with JFET elements BER. Nodal voltages V11 and V10.

Amplifier with JFET elements BER. Nodal voltage V8.


Examples

Pulse Former Transient Analysis (PFOM_TR.ATD)

A large scale mixed digital and analog circuit is considered in the example.

The circuit Pulse former (Fig.13.7) is composed of several digital cells (icand and icor) and several BJT-transistors and diodes. The digital cells are represented by the macromodels while the BJT-transistors and diodes are simulated by the models which makes use of Ebers-Moll model. The Ebers-Moll model is simulated by ALLTED intrinsic functions F3 and F4.

The hierarchical structure of the circuit (Fig.13.7) comprises subcircuits Form1, Form2, Form4, Form5, LOG, BUG, Wel. For convenience sake, subcircuit schematic diagrams are shown close to their description in the ALLTED input language.

Fig. 13.7. Pulse former.

Object;
Circuit pulseform;
# Input signal;
e1(1,0)=fpwl(0,5, 10,5, 60,0.3, 360,0.3, 410,5, 100e4,5);
# Subcircuits;
q1(0,1,5)=form1;
q2(0,5,6,10)=form2;
q3(0,6,7,9)=form2;
q4(0,7,8,11)=form4;
q5(0,11)=form5;
q6(0,9,10,8,14)=log;
q7(0,14,15)=wel;
q8(0,15,14,16,17)=bug;
#
r2(17,0)=100;
r1(16,0)=100;
#
model form1(0,1,19);

c2(6,9)=3e3;
q1(0,1,2,3)=m1.icand;
q2(0,3,4,2)=m1.icand;
c1(2,7)=22;
r1(3,5)=6.2;
r2(21,22)=2;
q3(22,6)=d.diode;
r3(6,0)=12;
r4(8,9)=11;
r5(21,4)=10;
q4(5,6,0)=t1.npnem;
q5(8,4,0)=t1.npnem;
r12(18,0)=6.2;
r11(7,18)=1.2;
q11(18,19,0)=t1.npnem;
r13(21,19)=4.3;
e1(21,0)=5;
r6(9,21)=21.5;
#
model diode(1,2);
# Model of BJT-diode, built with help of function F3;
r1(1,3)=r;
j1(3,2)=f3(i0,teta,umax,tau,cbar,g/uj1);
#
list d.diode;
r=0.25e-2; i0=0.73e-6; teta=27; umax=0.77;
tau=0.28; cbar=0.0126; g=0;
#
model npnem(b,c,e);
# Model of BJT-transistor, built using functions F3, F4;
rb(b,bin)=rb;
je(bin,e)=f3(i0e,tetae,umax,taue,cbe,gpne/uje);
jn(c,bin)=f4(alfan/uje);
jc(bin,c)=f3(i0c,tetac,umax,tauc,cbc,gpnc/ujc);
ji(e,bin)=f4(alfai/ujc);
#
list t1.npnem;
rb=0.01; i0e=0.2e-9; tetae=33; umax=0.9; taue=0.5e-2;
cbe=0.11e1; gpne=0.3e-5; alfan=0.993; i0c=0.8e-7; tetac=25;
tauc=0.3e-2;cbc=1.7; gpnc=0; alfai=0.16;
#
model icand(0,1,2,3);
# Macromodel 2-input AND Cell;
j1(1,0)=f300(ut,rbx/uj1);
j2(2,0)=f300(ut,rbx/uj2);
e1(3,0)=f310(u1,u0,f1,d1,f0,d0,r1,r0,-1/ue1,ie1);
#
list m1.icand;
rbx=50; ut=1; u0=0.3; u1=2.4; f1=-1; d1=10;
f0=-1; d0=10; r1=0.1; r0=0.02;
#
model form2(0,1,12,10);

epi(13,0)=5;
c1(3,6)=22;
c2(4,7)=68;
c3(5,8)=22;
r2(13,9)=4.3;
r1(13,7)=24;
r3(13,8)=20;
r4(13,10)=4.3;
r5(13,12)=4.3;
r6(6,11)=1.2;
r7(11,0)=6.2;
q1(7,9,0)=t1.npnem;
q2(8,10,0)=t1.npnem;
q3(11,12,0)=t1.npnem;
qt1(0,1,3,2)=m1.icand;
qt2(0,2,9,3)=m1.icand;
q4(0,2,2,4)=m1.icand;
q5(0,2,2,5)=m1.icand;
model form4(0,1,2,3);
#

q1(0,1,4,2)=m1.icand;
q2(0,2,5,4)=m1.icand;
c8(4,6)=22;
c9(9,8)=1.5e3;
r30(8,0)=12;
q3(10,8,0)=t1.npnem;
r28(2,10)=6.2;
q4(9,5,0)=t1.npnem;
r29(11,8)=4.3;
r31(11,9)=12;
r32(11,5)=4.3;
e1(11,0)=5;
r35(6,12)=1.2;
r36(12,0)=6.2;
q5(12,3,0)=t1.npnem;
r38(11,3)=4.3;
#
model form5(0,1);
#

q1(0,1,3,4)=m1.icand;
q2(0,4,5,3)=m1.icand;
q4(7,8,0)=t1.npnem;
q5(9,5,0)=t1.npnem;
r40(4,7)=6.2;
r44(8,0)=12;
r43(11,8)=4.3;
r46(11,9)=40;
r48(11,5)=4.3;
c10(3,12)=150;
c11(8,9)=1.5e3;
r51(11,2)=4.3;
r49(12,13)=4.3;
r50(13,0)=12;
q6(13,2,0)=t1.npnem;
epi(11,0)=5;

model log(0,1,2,3,4);

q1(0,1,1,5)=m1.icand;
q2(0,2,2,6)=m1.icand;
q3(0,3,3,7)=m1.icand;
q4(0,6,7,8)=m1.icand;
q5(0,8,8,9)=m1.icand;
q6(0,5,9,4)=m1.icand;

model wel(0,1,2);

c1(4,5)=22;
r33(1,3)=6.2;
r34(11,4)=4.3;
r39(11,5)=6.2;
r37(4,0)=12;
q1(3,4,0)=t1.npnem;
r41(5,7)=0.11;
r42(2,11)=4.3;
q2(7,2,0)=t1.npnem;
e1(11,0)=5;

model bug(0,1,2,3,4);
#

q1(0,1,1,4)=m1.icand;
q2(0,2,3,5)=m1.icand;
q3(0,4,5,5,6,3)=m2.icor;
e1(6,0)=0.3;
#


Examples

model icor(0,1,2,3,4,5);
# 4-input AND Cell;
j1(1,0)=f300(ut,rbx/uj1);
j2(2,0)=f300(ut,rbx/uj2);
j3(3,0)=f300(ut,rbx/uj3);
j4(4,0)=f300(ut,rbx/uj4);
e1(5,0)=f310(u1,u0,f1,d1,f0,d0,r1,r0,-4,2,2,2/ue1,ie1);
list m2.icor;
rbx=60; ut=1; u0=0.3; u1=3;
d1=10; f1=-1; d0=10; f0=-1;
r0=0.03; r1=0.09;
&

The nodal voltages V1, V16, V2.q5 are set to be plotted in
the task which is compiled of the DC and TR analyses:

task;
DC;
TR;
CONST TMAX=9e4, COMPL=2;
PLOT v1,v2.q5;
PLOT v16;
&
end

The output plots are shown below.

Pulse former. Nodal voltages V1 and V2.Q5.

Pulse former. Nodal voltage V8.


Examples

Operational Amplifier Worst Case Design (RCA_WCD.ATD)

Fig.13.8. Operational Amplifier.

Operational amplifier RCA 3040 (Fig.13.8) is considered in the example:

Object;
# RCA_3040 Operational Amplifier
Circuit rca3040;
#
e1(1,0)=Fpulse(-0.1,0.1,4,2,2,50,150);
e2(4,0)=-12;
e3(9,0)=12;
r3(3,4)=1.001;
r4(5,4)=1.001;
r1(1,18)=1.001;
r5(8,4)=0.811;
r6(7,4)=2.17;
r7(7,0)=0.82;
r8(9,13)=1.32;
g9(9,12)=FL(0.22/ug9);
r10(9,14)=1.32;
r11(16,0)=5.25;
r12(17,0)=5.25;
r2(2,0)=0.1;
q2(18,9,5,0)=rca30;
q1(2,9,3,0)=rca30;
q3(5,10,6,0)=rca30;
q4(3,15,6,0)=rca30;
q5(7,6,8,0)=rca30;
q8(12,13,10,0)=rca30;
q9(12,14,15,0)=rca30;
q7(12,12,11,0)=rca30;
q6(11,11,0,0)=rca30;
q10(13,9,16,0)=rca30;
q11(14,9,17,0)=rca30;
model rca30(1,2,3,4);
r1(1,5)=0.07;
c1(2,4)=2;
j1(5,2) = F3(0.11E-10,40,0.65,5,1.5,0/Uj1);
j2(3,5) = F4(0.83/Uj1);
j3(5,3) = F3(0.1E-10,40,0.65,0.1,0.9,0/Uj3);
j4(2,5) = F4(0.98/Uj3);
&

The worst case analysis is applied in the example to
compute the lower and upper boundaries of output voltage UR11.
The voltage is changed due to variation of parameters E2 (15%), R1(23%),
and R3(33%). The task that determines the specified boundaries is
written in the form:

task
dc;
tr;wcd;
varpar e2(5),r1(3),r3(3);
plot ur11=volt(40,20,80);
const tmax=100;
const reval=3,err=0.01,lerr=0.1;
const slerr=0.1;
&
end

The plot of the specified voltage and its upper and lower values is shown below.

Operational amplifier. Worst case analysis of voltage UR11.

|| Previous ||