> For the complete documentation index, see [llms.txt](https://www.opal-rt.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://www.opal-rt.com/docs/smart-power-simulation-software-sps/blocks-functions-tools/basics/passives/nonlinear-inductor.md).

# Nonlinear Inductor

## Description

<figure><img src="https://799605156-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FdlNg8IbOdahCpFCyzxSN%2Fuploads%2Fgit-blob-6c10423e29cff1ffbf775f2e264a111cc024750c%2Fnonlinear_inductor_block.png?alt=media" alt=""><figcaption></figcaption></figure>

The **Nonlinear Inductor** block, located in the **OPAL-RT SPS Software/Passives** library, represents a time-varying inductor. It implements a discrete variable inductor as a current source. The inductance is specified by a monotonically increasing flux linkage-current characteristic.

When you use a Nonlinear Inductor block in your model, set the powergui block **Simulation type** to Discrete and select the **Automatically handle Discrete solver and Advanced tab solver settings of blocks** parameter in the **Preferences** tab. The robust discrete solver is used to discretize the electrical model. Simulink® signals an error if the robust discrete solver is not used.

### Equations

The block uses the following equations for the relationship between the voltage, v, across the device and the current through the inductor, i, and the flux linkage:

$$
v=\frac{d\phi}{dt}\\\[8pt]
\phi = L \cdot i = \text{ flux linkage.}
$$

## Ports

### Conserving

| <p><strong>+</strong> — Positive terminal<br>SPS electrical</p> | SPS electrical conserving port associated with the inductor positive voltage. |
| --------------------------------------------------------------- | ----------------------------------------------------------------------------- |
| <p><strong>-</strong> — Negative terminal<br>SPS electrical</p> | SPS electrical conserving port associated with the inductor negative voltage. |

## Parameters

<table data-header-hidden><thead><tr><th width="171.60003662109375"></th><th></th></tr></thead><tbody><tr><td><strong>Discrete Solver</strong> — Solver type<br>Backward Euler (default) | Trapezoidal</td><td>Robust integration method used by the block. The discrete solver method is automatically set to <code>Trapezoidal</code> when, in the powergui block, in the <strong>Preferences</strong> settings, you select <strong>Automatically handle discrete solver and Advanced tab solver settings of blocks</strong>.<br>The <code>Trapezoidal</code> robust solver is slightly more accurate than the <code>Backward Euler</code> robust solver, especially when the model is simulated at larger sample times. The <code>Trapezoidal</code> robust solver may produce slight damped numerical oscillations on machine voltage in no-load conditions, while the <code>Backward Euler</code> robust solver prevents oscillations and maintains good accuracy.</td></tr><tr><td><strong>Flux linkage - current characteristics [(V.s);(A)]</strong> — Inductance characteristic, L<br>[0,0 ; 1,1] (default) | 2-by- <em>n</em> matrix</td><td>Resistance specified by a monotonically increasing flux linkage-current characteristic, specified as a 2-by- <em>n</em> matrix where <em>n</em> is greater than or equal to 2.</td></tr><tr><td><strong>Initial flux linkage (V.s)</strong> — Initial flux linkage<br>0 (default) | scalar</td><td>Initial flux linkage.</td></tr><tr><td><strong>Measurements</strong> — Measurement type<br>None (default) | Flux, Imag</td><td>Measurement type. Select <code>Flux, Imag</code> to measure the flux and magnetization current of the nonlinear inductor. Place a Multimeter block in your model to display the selected measurements during the simulation.</td></tr></tbody></table>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://www.opal-rt.com/docs/smart-power-simulation-software-sps/blocks-functions-tools/basics/passives/nonlinear-inductor.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
