23.01.2015 Views

Download - Wolfram Research

Download - Wolfram Research

Download - Wolfram Research

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

2.6 Modeling and Analysis of Nonlinear Circuits 95<br />

In the case of the diode we have two port nodes A and C, which are connected by an electrical port<br />

branch [A, C]. The port current, i.e. i D , is thus designated by Current[A, C] and the port voltage,<br />

i.e. v D , is designated by Voltage[A, C]. Hence, the model equation must be written as<br />

Definition −><br />

Equations[Current[A, C] == Is (Exp[Voltage[A, C]/Vt] − 1)]<br />

In this example, the Definition contains only one single equation, but there is no limit to the<br />

number of equations. We will discuss some more advanced examples in which this will become<br />

apparent later in this chapter.<br />

A note on interfacing: Some numerical circuit simulators with behavioral model simulation capabilities use the<br />

currents into the pins (port nodes) of a model object and the node voltages at the pins as symbolic quantities<br />

by which the model equations are interfaced with the exterior circuit. This approach is not well suited for other<br />

analysis methods than modified nodal analysis. Using port branches with associated currents and voltages<br />

facilitates setting up other formulations which involve loop equations, such as the sparse tableau.<br />

The Variables Argument<br />

The Variables argument serves to specify the symbols which are unknowns of the model equations.<br />

The diode equation contains two unknowns, Current[A, C] and Voltage[A, C], so the Variables<br />

argument is<br />

Variables −> {Current[A, C], Voltage[A, C]}<br />

The need for the Variables specification may not be entirely obvious here. One might argue that<br />

Analog Insydes should know that port current and voltage identifiers are unknowns. However,<br />

port currents and voltages are not always the only variables of a set of model equations. Similarly<br />

to a subcircuit which may have internal nodes, a behavioral model may also contain internal<br />

variables which are not of the form Voltage[node+, node−] or Current[node+, node−]. Without the<br />

Variables argument, Analog Insydes would not be able to distinguish between internal variables<br />

and global parameters, such as Vt in the diode equation. So, by convention, you must specify all<br />

identifiers in a set of model equations which are neither local nor global parameters, including the<br />

port branch quantities. The complete ABM definition for the diode is then given by<br />

Model[<br />

Name −> Diode,<br />

Selector −> DC,<br />

Ports −> {A, C},<br />

Parameters −> {Is, Global[Vt]},<br />

Variables −> {Current[A, C], Voltage[A, C]},<br />

Definition −><br />

Equations[Current[A, C] == Is (Exp[Voltage[A, C]/Vt] − 1)]<br />

]

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!