HSpice transient analysis computes the circuit solution as a function of
time over a time range specified in the .TRAN statement. Since
transient analysis is dependent on time, it uses different analysis
algorithms, control options with different convergence-related issues and
different initialization parameters than DC analysis. However, since
a transient analysis first performs a DC operating point analysis ( unless
the UIC option is initialization and convergence issues also apply to
Some circuits, such as oscillators or circuits with feedback, do not have
stable operating point solutions. For these circuits, either the feedback
loop must be broken so that a DC operating point can be calculated so the
initial conditions must be provided in the simulation input. the DC
operating point analysis is bypassed if the UIC parameter is included in
the .TRAN statement. If UIC is included in the .TRAN statement,
a transient analysis is started using node voltages specified in a .IC
statement. If a node is set to 5V in a .IC statement, the value at
that node for the first time point (time 0) is 5V.
The .OP statement can be used to store an estimate of the DC operating
point during a transient analysis.
.TRAN 1ns 100ns UIC
The .TRAN statement UIC parameter in the above example bypasses the
initial DC operating point analysis. The .OP statement calculateds
transient operating points at time=0 and time=20ns during
the transient analysis.
Although a transient analysis might provide a convergence DC solution, the
transient analysis itself can still fail to converge. In a transient
analysis, the error message "internal timestep too small" indicates
that the circuit failed to converge. The convergence failure might be due
to stated initial conditions that are not close enough to the actual DC
operating point values.
.TRAN var1 START=start1 STOP=stop1 STEP=incr1
.TRAN var1 START=[param_expr1] STOP=[param_expr2] STEP=[param_expr3]
.TRAN var1 START=start1 STOP=stop1 STEP=incr1 [SWEEP var2 type np start2
.TRAN tinc1 tsop1 [tincr2 tstop2 ... tincrN tstopN] [START=val] [UIC]
[SWEEP var pstart pstop pincr]
The following example performs and prints the transient analysis every 1ns
.TRAN 1ns 100ns
The following performs the calculation every 0.1ns for the first 25ns, and
then every 1ns until 40ns. Printing and plotting begin at 10ns.
.TRAN .1ns 25ns 1ns 40ns START=10ns
The following performs the calculation every 10ns for 1us. The initial DC
operating point calculation is bypassed, and the nodal voltages specified
in the .IC statement (or by IC parameters in element statement) are
used to calculate initial conditions.
.TRAN 10ns 1us UIC
The following example increases the temperature by 10 degrees Celcius
through the range -55 to 75 and performs transient analysis for each
.TRAN 10ns 1us UIC SWEEP TEMP -55 75 10
The following performs an analysis for each load parameter value at 1pF, 5pF,
.TRAN 10ns 1us SWEEP load POI 3 1pf 5pf 10pf
Specifications of the parameters:
np - number of points or number od points per decade or octave,
depending on the preceding keyword
param_expr - user-specified expressions, for example,
param_expr1, ..., param_exprN
pincr - voltage, current, element or model parameter, or temperature
pstart - starting voltage, current, temperature, any element or model
pstop - final voltage, current, temperature, any element or model
START - time at which printing or plotting is to begin. The
START keyword is optional: the start time can be specified without
preceding it with "START="
SWEEP - keyword to indicate a second sweep is specified on the
tincr1 - printing or plotting increment for printer output, and the
suggested computing increment for the postprocessor
tstop1 - time at which the transient analysis stops incrementing
by tincr1. If another tincr-tstop pair follows, the analysis
continues with the new statement.
var - name of an independent voltage or current source, any element
or model parameter, or the keyword TEMP (indicating a temperature
sweep). HSpice supports source value sweep, referring to the source name.
example is a simple RC ladder.
******transient analysis example
Vin 1 0 exp(0V 0.2V 2ms 20ms 40ms 20ms)
R1 1 2 3
R2 2 3 5
C1 2 4 7m
R3 4 0 8
C2 3 5 6m
R4 5 0 4
.tr 0.1ms 50ms
Vin 1 0 pulse(0V 5V 5ms 0.5ms 0.5ms 4.5ms 10ms)
Vin 1 0 sin(0 1V 1kHz 2ms 10 45)
By exciting the source with different input waveforms, we have the
Here is another example, this circuit uses MOS transistors to build a
NAND2 circuit. For the figure shown below,
the netlist file is given by
netlist. The MOS models is given by
model. The HSpice simulation file is given by
nand2.sp. The simulation results are shown below.
From the simulation results, we have the correct functionality of the
NAND2 gate. Now, you should be able to do your transient analysis. You
might note that there are two .meas statements in the HSpice
file, these two are for measuring the 50%-50% rise delay and fall delay.
After running the simulation, you can look for these measurements in the
*.mt0 file. If you want to have a symmetrical NAND2 gate or
optimize the performance, you can use the sweep function provided
by HSpice. Since parameters are specified in the netlist file, you can
just add the following statements in your simulation code.
.tr 0.1ns 25ns sweep wn start_value stop_value increment
.tr 0.1ns 25ns sweep beta start_value stop_value increment
The first statement is for optimizing gate delays and the second one will
help you to build a symmetric gate. The simulation results can be found in
the *.mt0 file, you can choose the right parameter values base on
the measured rise delays and fall delays. The optimizations are left to
In some cases, you might want to specify some of the nodes in your
circuits to some predefined values, in this case you can use the
.IC command to do so. The general form for this command is given
.IC V(node1) val1 V(node2) val2 ...