What is NL5? back to top

NL5 is an analog electronic circuit simulator working with ideal and piecewise-linear components. The first version of NL simulator for personal computers was developed in the early ‘90s as a tool for switching power supplies design. Since then NL has evolved into the Microsoft Windows®-based tool, which is being used extensively by world-class engineers in different fields of electronics for almost 15 years. The first publicly available version, NL5, was released in 2009.

How does NL5 work? back to top

While conventional SPICE-based simulators are trying to perform accurate simulation using "real" models of non-linear components with dozens of parameters, NL5 is using an opposite approach. Instead of complex models, it offers very simple **"ideal"** components.
*more...*

An "ideal" component is a component that provides just a basic functionality required for a component of that type. Ideal component is very simple; it is described by a minimal number of parameters, or even no parameters at all (for example, ideal switch). As a result, its behavior is clear and predictable, so that any potential problems caused by numerical algorithms can be easily detected.

Another important NL5 feature is its ability to perform **instantaneous switching** of ideal switches and diodes.

Instead of accurate "real" non-linear models NL5 uses its **piece-wise linear** (PWL) representation. Simulation with PWL models can be performed much faster than solving complex non-linear equations at almost every step of simulation.

*...less*

Why "ideal" components? back to top

There are many advantages of using "ideal" components in circuit simulation.

If "real" parts are used, each one adds a lot of "variables" in the system equations: parasitic capacitance and inductance, leakage, offsets, on/off resistance, limited gain and bandwidth, etc. All of them are considered in the simulation process, which makes it extremely complex, slow, and very often non-reliable.
*more...*

| *
For instance, "real" switches and diodes with small/large on/off resistance add very small and very large numbers in the matrix representing the circuit. It may result in so called "stiff system", which is very difficult to solve. Typical problems with such systems are loss of accuracy, bad convergence, and even absolutely wrong simulation results.
*Small and high resistance of "real" components may also create very small time constants. This, in turn, will require simulation step to be very small. Reducing the step will slow down simulation, and may produce non-reliable results. Special precautions should also be taken during switching process, when resistance is rapidly changing.
| |

Using “ideal” components, along with "instantaneous switching" feature, considerably simplifies simulation task.

| *
"Ideal" switch and diode are represented by short or open circuit, which drastically simplifies circuit equations. There is no need to reduce simulation step in order to account for non-critical parameters of "real" models, or during switching, which is performed instantaneously. If simulation result looks suspicious, it can be easily analyzed and verified, since all circuit components are very simple.
* | |

Simulation with "ideal' components is especially useful and effective at early stages of a project: evaluating a new circuit idea, new topology, or design concept. It gives clear understanding of general operation of the circuit that is not disturbed by combined effects of hundreds of "real" parameters.

| *
While evaluating a new idea, you may not know yet what parameters of a "real" part would be critical for circuit operation, and what could be disregarded. In this case, starting with very simple "ideal" components would be much more reasonable and efficient than selecting from thousands of "real" parts with unknown behavior. When simulation with “ideal” components is completed, some components can be sequentially (step-by-step) modified to investigate effects of more "realistic" behavior. This will help to identify which parameters are critical for circuit operation, and should be considered when selecting specific "real" parts.
* | |

When design concept is approved with "ideal" components, a thorough and detailed simulation can be performed by either adding reasonable complexity to critical components, or continuing analysis with standard SPICE-based tools.

*...less*

NL5 vs. SPICE back to top

One might think that dealing with such simple components must be a very simple task, so why not use “ideal” components in SPICE? Unfortunately, that’s not possible.

SPICE algorithm has been initially designed to perform accurate simulation of "real" integrated circuits, and it does that very well. However, "ideal" components may cause quite specific operating conditions, which almost never exist in “real” life: floating nodes, voltage loops, current cut-sets, to name a few. It happened that a standard SPICE algorithm has inherent limitations, which prevent it from dealing with such conditions.
*more...*

On the contrary, NL5 has been designed for "ideal" simulation, so it handles such "troublesome" situations easily.

| *
Interestingly enough, even non SPICE-based simulation tools that offer very simple components with "instantaneous switching' feature (such as PSIM, SIMPLIS), still do not allow true "ideal' components with zero/infinite resistance. That is, as of now NL5 is the only simulator on the market offering true “ideal” components.
* | |

Although SPICE algorithm is capable to provide fast and accurate simulation of quite complex circuits, sometimes it would take significant efforts to make it work right, or simply work at all. There are dozens of simulation parameters (such as step, tolerances, etc.) that must be thoroughly selected. It requires either a lot of experience, or a good knowledge of simulation algorithms and methods.

In NL5, the only parameter which should be set up properly by the user is simulation step. A couple of other parameters and settings may be tuned to achieve better performance, however it is not required.

The following table summarizes main differences between NL5 and SPICE:

**NL5** |
**SPICE** |

Simple "ideal" and PWL components |
Complex non-linear models of "real" parts |

Simple integration method with practically no side effects. Numerical problems can be easily discovered and avoided |
Complex numerical algorithm may easily produce wrong results. Users have to have a fair level of expertise to configure it properly |

Robust instantaneous switching algorithm |
Convergence problems at switching points |

Accepts arbitrary (even unrealizable) topology, component parameters, and simulation conditions |
Prefers "real" (realizable) circuit topology, component parameters, and simulation conditions |

Use NL5 to evaluate new design ideas, prove a concept of a design using very simple "ideal" components, models, and methods |
Use SPICE to perform detailed analysis of a design using complex and accurate "real" components, models, and methods |

*...less*

Who can use NL5? back to top

NL5 perfectly fits the needs of all users, regardless of their experience, interests, and expectations.

NL5 is ideal for novices and students studying electronics. The learning curve is negligibly short: basic knowledge of the Windows® operating system is all that’s needed to start working with NL5. A friendly and intuitive interface allows fast modifying of the schematic, even “on-the-fly” editing while the simulation is running, thus giving instant answers to “what if …?” questions.
*more...*

Experienced engineers can simulate rather large systems, taking advantage of extremely fast and robust algorithm, since the convergence problem inherent to SPICE is no longer an issue. A powerful scripting language and HTTP-link allow the user to perform complex tasks with NL5 itself, and using it as “add-on” simulation engine with popular engineering tools such as MATLAB®, PYTHON, and others.

Although NL5 was originally designed for simulating switching power supplies, it has proved to be an excellent simulation tool for almost any type of electronic circuitry: from nanoseconds transmission lines and high power RF generators, to precision instrumentation and digital signal processing.

Due to the very basic nature of ideal components used in NL5, its application area is not limited to electronics. It can be successfully used for systems simulation by researchers in many disciplines, such as mechanics, heat transfer, fluid dynamics, to name a few.

*...less*