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.

206 3. Reference Manual<br />

With the InitialConditions argument, you can specify initial conditions for dynamic variables in<br />

behavioral model equations. Initial conditions can be assigned to any quantity x whose derivative x’<br />

appears in the equations. This applies to internal model variables as well as to branch voltages and<br />

currents.<br />

The following example shows how to specify an initial condition for the branch quantity<br />

Voltage["P", "N"]. Note that it is not important whether this quantity appears directly in the<br />

equations or not. However, its derivative Voltage["P", "N"]’ must be present as a prerequisite for<br />

the assignment of an initial condition.<br />

Model[<br />

Name −> "Capacitor", Selector −> "Behavioral",<br />

Ports −> {"P", "N"}, Parameters −> {C},<br />

Variables −> {Current["P", "N"], Voltage["P", "N"]},<br />

Definition −> Equations[<br />

Current["P", "N"] == C*Voltage["P", "N"]’<br />

],<br />

InitialConditions −> {Voltage["P", "N"] −> 1.52}<br />

]<br />

Examples<br />

Load Analog Insydes.<br />

In[1]:= "SimpleACbeta",<br />

Scope −> Global, Ports −> {"C", "B", "E"},<br />

Parameters −> {RB, beta},<br />

Definition −> Netlist[<br />

{"RB", {"B", "X"}, RB},<br />

{"CC", {"X", "E", "C", "E"}, beta}<br />

]<br />

],<br />

Model[<br />

Name −> "BJT", Selector −> "SimpleACgm",<br />

Scope −> Global, Ports −> {"C", "B", "E"},<br />

Parameters −> {RB, beta},<br />

Translation −> {gm −> RB*beta},<br />

Definition −> Netlist[<br />

{"RB", {"B", "E"}, RB},<br />

{"VC", {"B", "E", "C", "E"}, gm}<br />

]<br />

]<br />

] // ExpandSubcircuits;<br />

List the contents of the<br />

global subcircuit database.<br />

In[3]:= GlobalSubcircuits[]<br />

Out[3]= BJT, SimpleACbeta, BJT, SimpleACgm

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

Saved successfully!

Ooh no, something went wrong!