# SPICE Diode

SPICE-compatible diode

• Library:
• Simscape / Electrical / Additional Components / SPICE Semiconductors

## Description

The SPICE Diode block represents a SPICE-compatible diode.

SPICE, or Simulation Program with Integrated Circuit Emphasis, is a simulation tool for electronic circuits. You can convert some SPICE subcircuits into equivalent Simscape™ Electrical™ models using the Environment Parameters block and SPICE-compatible blocks from the Additional Components library. For more information, see `subcircuit2ssc`.

### Equations

Variables for the SPICE Diode block equations include:

• Variables that you define by specifying parameters for the SPICE Diode block. The visibility of some of the parameters depends on the value that you set for other parameters. For more information, see Parameters.

• Geometry-adjusted variables, which depend on several values that you specify using parameters for the SPICE Diode block. For more information, see Geometry-Adjusted Variables.

• Temperature, T, which is `300.15` `K` by default. You can use a different value by specifying parameters for the SPICE Diode block or by specifying parameters for both the SPICE Diode block and an Environment Parameters block. For more information, see Diode Temperature.

• Minimal conductance, GMIN, which is `1e–12` `1/Ohm` by default. You can use a different value by specifying a parameter for an Environment Parameters block. For more information, see Minimal Conduction.

Several variables in the equations for the SPICE diode model consider the geometry of the device that the block represents. These geometry-adjusted variables depend on variables that you define by specifying SPICE Diode block parameters. The geometry-adjusted variables depend on these variables:

• AREA — Area of the device

• SCALE — Number of parallel connected devices

The table includes the geometry-adjusted variables and the defining equations.

VariableDescriptionEquation
`$CJ{O}_{d}=CJO*AREA*SCALE$`
`$IB{V}_{d}=IBV*AREA*SCALE$`
`$I{S}_{d}=IS*AREA*SCALE$`
`$R{S}_{d}=\frac{RS}{AREA*SCALE}$`

Diode Temperature

You can use these options to define diode temperature, T:

• Fixed temperature — The block uses a temperature that is independent from the circuit temperature when the Model temperature dependence using parameter in the Temperature settings of the Spice Diode block is set to `Fixed temperature`. For this model, the block sets T equal to TFIXED.

• Device temperature — The block uses a temperature that depends on circuit temperature when the Model temperature dependence using parameter in the Temperature settings of the Spice Diode block is set to `Device temperature`. For this model, the block defines temperature as

`$T={T}_{C}+TOFFSET$`

Where:

• TC is the circuit temperature.

If there is no Environment Parameters block in the circuit, TC is equal to 300.15 K.

If there is an Environment Parameters block in the circuit, TC is equal to the value that you specify for the Temperature parameter in the Spice settings of the Environment Parameters block. The default value for the Temperature parameter is `300.15` `K`.

• TOFFSET is the offset local circuit temperature.

Minimal Conduction

Minimal conductance, GMIN, has a default value of `1e–12` `1/Ohm`. To specify a different value:

1. If there is not an Environment Parameters block in the diode circuit, add one.

2. In the Spice settings of the Environment Parameters block, specify the desired GMIN value for the GMIN parameter.

Thermal Voltage

Thermal voltage, Vt, is defined by the equation

`${V}_{t}=N\frac{k*T}{q}$`

Where:

• N is the emission coefficient.

• T is the diode temperature. For more information, see Diode Temperature.

• k is the Boltzmann constant.

• q is the elementary charge on an electron.

Current-Voltage Equations

These equations define the relationship between the diode current, Id, and the diode voltage, Vd. As applicable, the model parameters are first adjusted for temperature. For more information, see Temperature Dependence.

`${I}_{d}=AREA*\left({I}_{fwd}-{I}_{rev}\right)$`

`${I}_{fwd}={I}_{nrm}*{K}_{inj}+{I}_{rec}*{K}_{gen}$`

`${I}_{rev}={I}_{revh}+{I}_{revl}$`

`${I}_{nrm}={I}_{S}{e}^{{V}_{d}/\left(N*Vt\right)-1}$`

`${I}_{rec}={I}_{SR}{e}^{{V}_{d}/\left(NR*Vt\right)-1}$`

`${K}_{inj}={\left(\frac{IKF}{IKF+{I}_{nrm}}\right)}^{0.5}$`

`${K}_{gen}={\left[{\left(\frac{1-{V}_{d}}{VJ}\right)}^{2}+0.005\right]}^{\frac{M}{2}}$`

`${I}_{revh}=IBV*{e}^{-\frac{{V}_{d}+BV}{NBV*Vt}}$`

`${I}_{revl}=IBVL*{e}^{-\frac{{V}_{d}+BV}{NBVL*Vt}}$`

Where:

• Ifwd is the forward current.

• Irev is the reverse current.

• Inrm is the normal current.

• Irec is the recombination current.

• Kinj is the high-injection factor.

• Kgen is the generation factor.

• Irevh is the high-level breakdown current.

• Irevl is the low-level breakdown current.

• IS is the saturation current.

• ISR is the recombination current.

• IKF is the forward knee current.

• VJ is the junction potential.

• N is the emission coefficient.

• NR is the reverse emission coefficient.

• NBV is the reverse breakdown emission coefficient.

• NBVL is the low-level reverse breakdown ideality factor.

• M is the grading coefficient.

• BV is the reverse breakdown voltage.

• IBV is the reverse breakdown current.

• IBVL is the low-level reverse breakdown knee current.

Junction Charge Model

The table shows the equations that define the relationship between the diode charge Qd, and the diode voltage, Vd. As applicable, the model parameters are first adjusted for temperature. For more information, see Temperature Dependence.

Vd RangeQd Equation
${V}_{d}${Q}_{d}=TT*AREA*{I}_{fwd}+CJ{O}_{d}*VJ*\frac{1-{\left(1-\frac{{V}_{d}}{VJ}\right)}^{1-M}}{1-M}$
${V}_{d}\ge FC*VJ$$\begin{array}{l}{Q}_{d}=TT*AREA*{I}_{fwd}+\\ \text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}\text{\hspace{0.17em}}CJ{O}_{d}*\left(F1+\frac{F3*\left({V}_{d}-FC*VJ\right)+\left(\frac{M}{2*VJ}\right)*\left({V}_{d}^{2}-{\left(FC*VJ\right)}^{2}\right)}{F2}\right)\text{​}\end{array}$

Where:

• FC is the forward bias depletion capacitance coefficient.

• VJ is the junction potential.

• TT is the transit time.

• M is the grading coefficient.

• $F1=VJ*\left(1-{\left(1-FC\right)}^{\left(1-M\right)}\right)/\left(1-M\right)$

• $F2={\left(1-FC\right)}^{\left(1+M\right)}$

• $F3=1-FC*\left(1+M\right)$

Temperature Dependence

The relationship between the geometry-adjusted saturation current and the diode temperature is

`$I{S}_{d}\left(T\right)=I{S}_{d}*{\left(T/TMEAS\right)}^{\frac{XTI}{N}}*{e}^{\left(\frac{T}{TMEAS}-1\right)*\frac{EG}{N*{V}_{t}}}$`

Where:

• T is the diode temperature. For more information, see Diode Temperature.

• TMEAS is the parameter extraction temperature.

• XTI is the saturation current temperature exponent.

• N is the emission coefficient.

• EG is the activation energy.

The relationship between the recombination current and the diode temperature is

`$ISR\left(T\right)=ISR*{\left(\frac{T}{TMEAS}\right)}^{\frac{XTI}{NR}}*{e}^{\left(\frac{T}{TMEAS}-1\right)*\frac{EG}{NR*{V}_{t}}}$`

Where:

• ISR is the recombination current.

• NR is the reverse emission coefficient.

The relationship between the forward knee current and the diode temperature is

`$IKF\left(T\right)=IKF*\left[1+TIKF*\left(T-TMEAS\right)\right]$`

Where:

• IKF is the forward knee current.

• TIKF is the linear IKF temperature coefficient.

The relationship between the breakdown voltage and the diode temperature is

`$BV\left(T\right)=BV*\left[1+TBV1*\left(T-TMEAS\right)+TBV2*{\left(T-TMEAS\right)}^{2}\right]$`

Where:

• BV is the breakdown voltage.

• TBV1 is the linear BV temperature coefficient.

• TBV2 is the quadratic BV temperature coefficient.

The relationship between the ohmic resistance and the diode temperature is

`$RS\left(T\right)=RS*\left[1+TRS1*\left(T-TMEAS\right)+TRS2*{\left(T-TMEAS\right)}^{2}\right]$`

Where:

• RS is the ohmic resistance.

• TRS1 is the linear RS temperature coefficient.

• TRS2 is the quadratic RS temperature coefficient.

The relationship between the junction potential and the diode temperature is

`$VJ\left(T\right)=VJ*\left(\frac{T}{TMEAS}\right)-3*Vt*\mathrm{ln}\left(\frac{T}{TMEAS}\right)-\left(\frac{T}{TMEAS}\right)*E{G}_{TMEAS}+E{G}_{T}$`

Where:

• VJ is the junction potential.

• EGTMEAS is the activation energy for the temperature at which the diode parameters were measured. The defining equation is $E{G}_{TMEAS}=1.16eV-\left(7.02e-4*TMEA{S}^{2}\right)/\left(TMEAS+1108\right)$.

• EGT is the activation energy for the diode temperature. The defining equation is $E{G}_{T}=1.16eV-\left(7.02e-4*{T}^{2}\right)/\left(T+1108\right)$.

The relationship between the geometry-adjusted diode zero-bias junction capacitance and the diode temperature is

`$CJ{O}_{d}\left(T\right)=CJ{O}_{d}*\left[1+M*\left(400e-6*\left(T-TMEAS\right)-\frac{VJ\left(T\right)-VJ}{VJ}\right)\right]$`

Where:

• M is the grading coefficient.

## Assumptions and Limitations

• The block does not support noise analysis.

• The block applies initial conditions across junction capacitors and not across the block ports.

## Ports

### Conserving

expand all

Electrical conserving port associated with positive voltage.

Electrical conserving port associated with negative voltage.

## Parameters

expand all

### Main

Diode area. The value must be greater than `0`.

Number of parallel diodes that the block represents. The value must be greater than `0`.

Magnitude of the current that the ideal diode equation approaches asymptotically for very large reverse bias levels. The value must be greater than or equal to `0`.

Current value at which forward-beta high-current roll-off occurs. The value must be greater than or equal to `0`.

Magnitude of the current generated from the process of the recombination of electrons and holes inside the junction.

Diode emission coefficient or ideality factor. The value must be greater than `0`.

Diode emission coefficient for the recombination current. The value must be greater than `0`.

Grading coefficient, M. The value must be greater than `0` and less than `0.9`.

#### Dependencies

This parameter is only visible when you select `Yes` for the Model junction capacitance parameter.

Junction potential, VJ. The value must be greater than `0.01` `V`.

#### Dependencies

This parameter is only visible when you select `Yes` for the Model junction capacitance parameter.

Series diode connection resistance. The value must be greater than or equal to `0`.

### Junction Capacitance

Options for modeling the junction capacitance:

• `No` — Do not include junction capacitance in the model.

• `Yes` — Specify zero-bias junction capacitance, junction potential, grading coefficient, forward-bias depletion capacitance coefficient, and transit time.

Value of the capacitance placed in parallel with the exponential diode term. The value must be greater than or equal to `0`.

#### Dependencies

To enable this parameter, set Model junction capacitance to `Yes`.

Fitting coefficient,, FC, that quantifies the decrease of the depletion capacitance with applied voltage. The value must be greater than or equal to `0` and less than `0.95`.

#### Dependencies

To enable this parameter, set Model junction capacitance to `Yes`.

Transit time, TT, of the carriers that cause diffusion capacitance. The value must be greater than or equal to `0`.

#### Dependencies

To enable this parameter, set Model junction capacitance to `Yes`.

Options for specifying initial conditions:

• `No` — Do not specify an initial condition for the model.

• `Yes` — Specify the initial diode voltage.

Note

The SPICE Diode block applies the initial diode voltage across the junction capacitors and not across the ports.

#### Dependencies

To enable this parameter, set Model junction capacitance to `Yes`.

Diode voltage at the start of the simulation.

Note

The block applies the initial condition across the diode junction, so the initial condition is only effective when charge storage is included, that is, when one or both of the Zero-bias junction capacitance, CJO and Transit time, TT parameters are greater than zero.

#### Dependencies

To enable this parameter, set Model junction capacitance and Specify initial condition to `Yes`.

### Reverse Breakdown

Options for modeling reverse breakdown:

• `No` — Do not model reverse breakdown.

• `Yes` — Introduce a second exponential term to the diode I-V relationship, thereby modeling a rapid increase in conductance as the breakdown voltage is exceeded.

If voltage drops below this value, the block models the rapid increase in conductance that occurs at diode breakdown. The value must be greater than or equal to `0`.

#### Dependencies

To enable this parameter, set Model reverse breakdown to `Yes`.

Diode current that corresponds to the voltage specified for the Reverse breakdown voltage, BV parameter. The value must be greater than `0`.

#### Dependencies

To enable this parameter, set Model reverse breakdown to `Yes`.

Low-level reverse breakdown knee current.

#### Dependencies

To enable this parameter, set Model reverse breakdown to `Yes`.

Ideality factor for the Reverse breakdown voltage, BV.

#### Dependencies

To enable this parameter, set Model reverse breakdown to `Yes`.

Ideality factor for the Low-level reverse breakdown knee current, IBVL

#### Dependencies

To enable this parameter, set Model reverse breakdown to `Yes`.

### Temperature

Select one of these options for modeling the diode temperature dependence:

• `Device temperature` — Use the device temperature to model temperature dependence.

• `Fixed temperature` — Use a temperature that is independent of the circuit temperature to model temperature dependence.

Order of the exponential increase in the saturation current as temperature increases. The value must be greater than `0`.

Diode activation energy. The value must be greater than or equal to `0.1` `eV`.

Linear temperature coefficient for the High-injection knee current, IKF.

Linear temperature coefficient for the Ohmic resistance, RS.

Quadratic temperature coefficient for the Ohmic resistance, RS.

Linear temperature coefficient for the Breakdown voltage, BV.

Quadratic temperature coefficient for the Breakdown voltage, BV.

Diode simulation temperature. The value must be greater than `0` `K`.

#### Dependencies

To enable this parameter, set Model temperature dependence using to `Fixed temperature`.

Temperature at which the diode parameters are measured. The value must be greater than `0` `K`.

Amount by which the diode temperature differs from the circuit temperature.

#### Dependencies

To enable this parameter, set Model temperature dependence using to ```Device temperature```.

## Extended Capabilities

### Functions

Introduced in R2008a