Integrator

NAME_TABLE:

C_Function_Name: cm_int

Spice_Model_Name: int

Description: "time-integration block"

PORT_TABLE:

Port Name: in out

Description: "input" "output"

Direction: in out

Default_Type: v v

Allowed_Types: [v,vd,i,id] [v,vd,i,id]

Vector: no no

Vector_Bounds: - -

Null_Allowed: no no

PARAMETER_TABLE:

Parameter_Name: in_offset gain

Description: "input offset" "gain"

Data_Type: real real

Default_Value: 0.0 1.0

Limits: - -

Vector: no no

Vector_Bounds: - -

Null_Allowed: yes yes

PARAMETER_TABLE:

Parameter_Name: out_lower_limit out_upper_limit

Description: "output lower limit" "output upper limit"

Data_Type: real real

Default_Value: - -

Limits: - -

Vector: no no

Vector_Bounds: - -

Null_Allowed: yes yes

PARAMETER_TABLE:

Parameter_Name: limit_range

Description: "upper & lower limit smoothing range"

Data_Type: real

Default_Value: 1.0e-6

Limits: -

Vector: no

Vector_Bounds: -

Null_Allowed: yes

PARAMETER_TABLE:

Parameter_Name: out_ic

Description: "output initial condition"

Data_Type: real

Default_Value: 0.0

Limits: -

Vector: no

Vector_Bounds: -

Null_Allowed: yes

  • Description:
    The Integrator block is a simple integration stage that approximates the integral with respect to time of an input signal. The block also includes gain and input offset parameters to allow for tailoring of the required signal, and output upper and lower limits to prevent convergence errors resulting from excessively large output values. Note that these limits specify integrator behavior similar to that found in an operational amplifier-based integration stage, in that once a limit is reached, additional storage does not occur. Thus, the input of a negative value to an integrator that is currently driving at the out upper limit level will immediately cause a drop in the output, regardless of how long the integrator was previously summing positive inputs. The incremental value of output below the output upper limit and above the output lower limit at which smoothing begins is specified via the limit range parameter. In AC analysis, the value returned is equal to the gain divided by the radian frequency of analysis.
    Note that truncation error checking is included in the int block. This should provide for a more accurate simulation of the time integration function, since the model will inherently request smaller time increments between simulation points if truncation errors would otherwise be excessive.

Example SPICE Usage:

a13 7 12 time_count

.

.

.model time_count int(in_offset=0.0 gain=1.0

+ out_lower_limit=-1e12 out_upper_limit=1e12

+ limit_range=1e-9 out_ic=0.0)