LTspice Lesson 4c discussed creating a waveform using a handful of discrete points, but by using PWL FILE as shown below, large number of points can be easily imported into LTspice simulator to generate more sophisticated waveforms. In this lesson, we will create a practical system level ESD stimulus waveform as specified in IEC61000_4_2. Data points will created from an equation in IEC61000_4_2 standard using a Matlab script (download at the end if you interested).
First of all why we need such a simulation in a first place? Electrostatic Discharged (ESD) is a big issue and a threat when it comes to designing products that interface with human beings (i.e usb ports, antenna, various connectors etc) . All of these paths connect to sensitive ICs inside the system and ESD discharge can easily ruin them. So various standard got develop to test real word use case scenarios. In particular IEC 61000-4-2 is a industry standard; your product won’t get UL certified if you don’t meet this standard  Standard spells out type of ESD pulses that need to be tested and it proposes type of ESD pulses that need to tested and could be simulated using RLC type models. But the problem is some of the RLC models may not accurately model the type of pulse that is needed as shown below:
Standard specifies test voltages ±2kV, ±4kV,±6kV,±8kV. We will create a discharge pulse under the ±4kV. The values of the parameters are I1 =16.6A, I2 =9.3A, τ1 =1.1ns, τ2 =2ns, τ3 =12ns, τ4 =37ns, and n=1.8 .
Equations to generate an ESD pulse are specified below 
Matlab script to generate the data points is following:
Let’s load this file into PWL File for verification :
Following values are extracted from the plot and seem well matched with the IEC61000-4-2 standard
In general, a lot of complicated waveforms can be generated using PieceWise Linear approximation. This is especially useful if circuit or system need to be model for a non-standard waveforms.
- International Electrotechnical Commission. International Standard IEC 61000-4-2: “Electromagnetic Compatibility (EMC), Part 4: Testing and Measurement Techniques, Section 2: Electrostatic Discharge Immunity Test–Basic EMC Publication”; 2008.
- Katsivelis, Pavlos & Fotis, G.P. & Gonos, Ioannis & Koussiouris, Trifon & Stathopulos, Ioannis. (2010). Electrostatic Discharge Current Linear Approach and Circuit Design Method. Energies. 3. 1728-1740. 10.3390/en3111728.
To discuss or provide a comment:
could you share the PWL file as well
Hi Roshan, added a link on the bottom to download the file.
Could you please also generate files for 2kV, 6kV and 8kV? I can’t find any values for I1 and I2 for these voltages.