# LVS Device Classes

KLayout implements a variety of standard device classes. These device classes are the basis for forming particular incarnations of device classes. For example, the MOS4 class is the basis for the specific device classes for NMOS and PMOS transistors.

## Resistor

The plain resistor has two terminals, A and B. It features the following parameters:

- R: The resistance value in Ohm
- L: The length in µm
- W: The width in µm
- A: The area of the resistor area in µm²
- P: The perimeter of the resistor area in µm

Resistors can combine in parallel or serial fashion.

In SPICE, plain resistors are represented by the "R" element. The API class is .

## Resistor with bulk terminal

The resistor with bulk terminal is an extension of the plain resistor. If has the same parameters, but one additional terminal (W) which connects to the area the resistor sits in (e.g. well or substrate).

Resistors with bulk can combine in parallel or serial fashion if their bulk terminals are connected to the same net.

The API class of the resistor with bulk is .

## Capacitor

The plain capacitor has two terminals, A and B. It features the following parameters:

- C: The capacitance value in Farad
- A: The area of the capacitor area in µm²
- P: The perimeter of the capacitor area in µm

In SPICE, plain capacitors are represented by the "C" element. The API class is .

## Capacitor with bulk terminal

The capacitor with bulk terminal is an extension of the plain capacitor. If has the same parameters, but one additional terminal (W) which connects to the area the capacitor sits in (e.g. well or substrate).

Capacitors with bulk can combine in parallel or serial fashion if their bulk terminals are connected to the same net.

The API class of the capacitor with bulk is .

## Diode

Diodes have two terminals, A and C for anode and cathode. Diodes feature the following parameters:

- A: The area of the diode in µm²
- P: The perimeter of the diode in µm

Diodes combine in parallel (A to A and C to C). In this case their areas and perimeters will add.

In SPICE, diodes are represented by the "D" element using the device class name as the model name. The API class is .

## MOS transistor

Three-terminal MOS transistors have terminals S, G and D for source, gate and drain. S and D are commutable. They feature the following parameters:

- W: The gate width in µm
- L: The gate (channel) length in µm
- AS: The source area in µm²
- PS: The source perimeter in µm
- AD: The drain area in µm²
- PD: The drain perimeter in µm

MOS3 transistors combine in parallel when the source/drains and gates are connected and their gate lengths are identical. In this case their widths, areas and perimeters will add.

## MOS transistor with bulk

The API class of the three-terminal MOS transistor is .

The four-terminal transistor is an extension of the three-terminal one and offers an additional bulk terminal (B). It is probably the most prominent transistor device as the four-terminal version is compatible with the SPICE "M" element.

MOS transistors with bulk can combine in parallel the same way the three-terminal versions do if their bulk terminals are connected to the same net.

In SPICE, MOS4 devices are represented by the "M" element with the device class name as the model name. The API class is .

## Bipolar transistor

The three-terminal bipolar transistor can be either NPN or PNP type. In KLayout, this device type can represent both lateral and vertical types. The parameters are:

- AE: The emitter area in µm²
- PE: The emitter perimeter in µm
- NE: The emitter count (initially 1)
- AB: The base area in µm²
- PB: The base perimeter in µm
- AC: The collector area in µm²
- PC: The collector perimeter in µm

Upon extraction, multi-emitter versions are extracted as multiple devices - one for each emitter area - and NE = 1. Bipolar transistors combine when in parallel. In this case, their emitter parameters AE, PE and NE are added.

In SPICE, BJT3 devices are represented by the "Q" element with the device class name as the model name. The API class is .

## Bipolar transistor with substrate

The four-terminal transistor is an extension of the three-terminal one and offers an additional bulk terminal (S).

Bipolar transistors with bulk can combine in parallel the same way the three-terminal versions do if their bulk terminals are connected to the same net.

In SPICE, BJT4 devices are represented by the "Q" element with four nodes and the device class name as the model name. The API class is .