Skip to content

Current Source ​

Single-phase ideal current source. Drives a configurable DC or sinusoidal current, or (Controlled mode) the instantaneous current commanded by the in control signal in amps, out of the p terminal, through the external circuit, and back in at n, whatever voltage that takes, optionally with a shunt resistance across its terminals (0 = ideal). Supports a soft-start amplitude ramp and monitoring of the delivered terminal current (A / kA) and the terminal voltage (V / kV). Use it as a stiff DC load on a rectifier, a harmonic or test-current injection, or a Norton source. An ideal source with no shunt needs a current path in the external circuit; in series with an open switch or with only an inductor it is ill-posed. Takes no part in the load flow. In Controlled mode the control signal reaches the source one time step late (the standard control-to-network delay).

Category: Single-Phase / Sources

Overview ​

The Current Source drives a prescribed current through whatever is connected to it, taking on whatever terminal voltage that requires. It is the dual of the voltage source: where a voltage source fixes V(p)−V(n), the current source fixes the current I(t) that leaves the p terminal, flows through the external circuit, and returns at n.

I(t)={IDC2Isin⁡(2πft+φ)AC (I entered as RMS)uin(t−Δt)Controlled

Typical uses:

  • a stiff DC load on a rectifier (a large smoothing inductor makes the DC current nearly constant, which is exactly a current source);
  • a harmonic or test-current injection into a network to measure its impedance;
  • a Norton source, by giving it a shunt resistance;
  • a controlled current source driven by a control signal, for average-value converter models, the DC side of an inverter, or a measured load profile played back into the network.

Controlled mode ​

Set Mode to Controlled and an in control port appears on the right of the symbol. Its value is the instantaneous source current in amps: there is no RMS scaling and no soft-start ramp, so scale the signal with a Gain block if your control works in per unit.

The control signal reaches the source one time step late. Every signal crossing from the control domain into the electrical network reads the value the control side wrote on the previous step, so on the first step the source carries zero current. This one-step delay is the standard way EMT programs couple control systems to the network; keep it in mind when closing a fast current loop around the source.

Shunt resistance ​

With R_shunt = 0 the source is ideal: it has no internal path, and the whole source current flows in the external circuit. A non-zero R_shunt places a resistance across the terminals, turning the source into a Norton equivalent. The current delivered to the circuit is then

Iout=I(t)−V(p)−V(n)Rshunt.

Ill-posed circuits ​

An ideal current source forces its current to flow somewhere. The circuit around it has to provide a path, otherwise the problem has no solution:

  • Open circuit. If a terminal, and everything wired to it, connects to the rest of the circuit only through the source, the simulation refuses to start and names the source and the node. Add a load across the source or give it a shunt resistance.
  • Open breaker or off switch. These still conduct through their off-resistance, so the run starts, but the source drives its full current through that resistance and the terminal voltage becomes enormous. Add a shunt resistance, or a resistor across the switch.
  • Inductor-only path. In series with an inductor only, the source sets the inductor current directly, and the inductor voltage Ldi/dt jumps whenever the source current does (at t=0 in particular). Use the soft-start ramp, or add a shunt resistance.
  • Two current sources in series with different currents contradict each other. The simulation stops at the first step where they disagree, with an error naming the node between them; the results up to that step are kept. The same applies to currents into a floating neutral that do not sum to zero.

The soft-start ramp (t_ramp) raises the amplitude linearly from zero over t_ramp, which avoids the t=0 step into inductive loads.

Monitoring ​

Enable Measure current to record the delivered terminal current Iout (equal to I(t) for an ideal source) and Measure voltage to record V(p)−V(n). With the current leaving p into a load the terminal voltage is positive and the source delivers V⋅I.

Load flow ​

The current source takes no part in the load flow. Circuits that rely on the load flow to initialize machines and controllers treat it as absent; it acts from the start of the simulation.

Ports ​

PortKindSignalNotes
pElectrical terminal—
nElectrical terminal—
inControl inputRealShown when Mode is Controlled

Parameters ​

Config ​

ParameterTypeDefaultUnitsDescriptionID
ModeChoice: DC / AC / ControlledDC—0=DC, 1=AC, 2=Controlled. In DC mode the source holds a constant current; the frequency and phase fields are hidden. In Controlled mode the `in` control port appears and its value is the instantaneous source current in amps (no RMS scaling, no ramp); the current, frequency, phase and ramp fields are hidden.mode
INumber1A (also kA)Source current (RMS for AC, magnitude for DC). In AC mode the peak is sqrt(2) times this value, matching the voltage source. Positive current leaves the p terminal.current
fNumber60Hz (also kHz)Frequency of the AC current (Hz).frequency
φNumber0rad (also deg)Phase angle of the AC current, I(t) = sqrt(2) I sin(2 pi f t + phi). Radians or degrees via the unit dropdown.phase
t_rampNumber0s (also ms)Current ramp-up time. The amplitude scales linearly from 0 to full over t_ramp, then holds. Use it to start an inductive circuit without an inrush. 0 disables.ramp_time
R_shuntNumber0Ω (also kΩ)Resistance across the source terminals (a Norton source). 0 = ideal current source with no internal path.shunt_resistance
Measure currentChoice: Off / OnOff—Emit the current delivered out of the p terminal (the source current less the shunt current) as an observable. The signal name and unit are on this row.measure_current
Positive directionChoice: +ve in / +ve out+ve out—Sign convention for this current. '+ve out' (default) is positive when current flows out of the p terminal into the network. '+ve in' flips the sign.current_dir
Measure voltageChoice: Off / OnOff—Emit the terminal voltage V(p) - V(n) as an observable. The signal name and unit are on this row.measure_voltage

Signal Names ​

ParameterTypeDefaultUnitsDescriptionID
Current nameTextIA (also kA)Signal name for the delivered terminal current. Blank = skip. Pick the unit from the dropdown; the published value is scaled to it.current_name
Voltage nameTextVV (also kV)Signal name for the terminal voltage V(p) - V(n). Blank = skip. Pick the unit from the dropdown; the published value is scaled to it.voltage_name

Observables ​

Default nameKindRecorded whenDescriptionID
set by Current nameSignalMeasure current is onCurrent delivered out of the p terminal (and back in at n), scaled to the chosen unit (A / kA): the source current less the current the shunt resistance takes. Equal to the source current for an ideal source. Positive out of the p terminal into the network for '+ve out' (default); the other direction flips the sign.branchCurrent
set by Voltage nameSignalMeasure voltage is onTerminal voltage V(p) - V(n), scaled to the chosen unit (V / kV). With the current leaving p into a load, V(p) - V(n) is positive and the source delivers V * I.terminalVoltage

Used in samples ​