%$Id: language.tex,v 25.95 2006/08/26 01:26:53 al Exp $ -*- LaTeX -*-
% man behavior language .
% Copyright (C) 2001 Albert Davis
% Author: Albert Davis <aldavis@ieee.org>
%
% This file is part of "Gnucap", the Gnu Circuit Analysis Package
%
% This program is free software; you can redistribute it and/or modify
% it under the terms of the GNU General Public License as published by
% the Free Software Foundation; either version 2, or (at your option)
% any later version.
%
% This program is distributed in the hope that it will be useful,
% but WITHOUT ANY WARRANTY; without even the implied warranty of
% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
% GNU General Public License for more details.
%
% You should have received a copy of the GNU General Public License
% along with this program; if not, write to the Free Software
% Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
% 02110-1301, USA.
%------------------------------------------------------------------------
Gnucap behavioral modeling is in a state of transition, so this is
subject to change in a future release.

All simple components can have a behavioral description,
with syntax designed as an extension of the Spice time dependent
sources.  They are not necessarily physically realizeable.  Some only
work on particular types of analysis, or over a small range of
values.  Some can be used together, some cannot.

All simple components are considered to have simple
transformations.  A function returns one parameter as a function of
one other, as an extension of their linear behavior.

Linear behavior:

\begin{description}
\item[{\tt Capacitor}] $q = C v$
\item[{\tt Inductor}] $\phi = L i$
\item[{\tt Resistor}] $v = I r$
\item[{\tt Admittance}] $i = Y v$
\item[{\tt VCVS}] $v_o = E v_i$
\item[{\tt VCCS}] $i_o = G v_i$
\item[{\tt CCVS}] $v_o = E i_i$
\item[{\tt CCCS}] $i_o = G i_i$
\end{description}

Sources are defined as functions of time:

\begin{description}
\item[{\tt Voltage source}] $v = f(t)$
\item[{\tt Current source}] $i = f(t)$
\end{description}

For behavioral modeling / nonlinear values, replace the constant times 
input by an arbitrary function:

\begin{description}
\item[{\tt Capacitor}] $q = f(v)$
\item[{\tt Inductor}] $\phi = f(i)$
\item[{\tt Resistor}] $v = f(r)$
\item[{\tt Admittance}] $i = f(v)$
\item[{\tt VCVS}] $v_o = f(v_i)$
\item[{\tt VCCS}] $i_o = f(v_i)$
\item[{\tt CCVS}] $v_o = f(i_i)$
\item[{\tt CCCS}] $i_o = f(i_i)$
\end{description}


\subsection*{Conditionals}

\begin{description}

\item[{\tt AC}] AC analysis only.
\item[{\tt DC}] DC (steady state) value.
\item[{\tt OP}] OP analysis.
\item[{\tt TRAN}] Transient analysis.
\item[{\tt FOUR}] Fourier analysis only.
\item[{\tt ELSE}] Anything not listed.
\item[{\tt ALL}] All modes.

\end{description}

\subsection*{Functions}

\begin{description}

\item[{\tt COMPLEX}] Complex (re, im) value.
\item[{\tt EXP}] Spice Exp source.  (time dependent value).
\item[{\tt FIT}] Fit a curve with splines.
\item[{\tt GENERATOR}] Value from Generator command.
\item[{\tt POLY}] Polynomial (Spice style).
\item[{\tt POSY}] Posynomial (Like poly, non-integer powers).
\item[{\tt PULSE}] Spice Pulse source.  (time dependent value).
\item[{\tt PWL}] Piece-wise linear.
\item[{\tt SFFM}] Spice Frequency Modulation (time dependent value).
\item[{\tt SIN}] Spice Sin source.  (time dependent value).
\item[{\tt TANH}] Hyperbolic tangent xfer function.

\end{description}

\subsection*{Model Functions}

\begin{description}

\item[{\tt TABLE}] Fit a curve with splines.
\item[{\tt Cap}] Spice semiconductor ``capacitor'' model.
\item[{\tt Res}] Spice semiconductor ``resistor'' model.

\end{description}
%------------------------------------------------------------------------
%------------------------------------------------------------------------
