V element as a Mains Transformer Winding
Behaviour of real world mains transformers very much depends on two things, the actual mains Voltage going in, and what's called 'regulation'.
'Regulation' is the term used to describe the loss at the output, due to losses in the core, winding resistance and so on, as a percentage. It means the output Voltage drops as the current increases. This is easily simulated by setting an appropriate impedance for the winding.
If the manufacturer was sensible he would have added so many percent extra turns to the winding to compensate for this Voltage drop, usually at the maximum current rating for the winding. This explains why if you meaure a transformer's secondaries if just connect it to the mains and nothing else, without any load, the Voltages are likely to appear to be too high.
Code: Select all
.param mains=230
.param Tpri=240
.param Trms=450
.param TImax=0.25
.param Treg=10
.param Tover=Trms*(1+(Treg/100))
.param Tratio=Tover/Tpri
.param Tsec=(mains*Tratio)*1.414
mains: your actual mains Voltage. Can vary!
Tpri: what mains Voltage the transformer expects. I.e. what it's wound for.
Trms: the secondary AC r.m.s. Volts, as 'what it's supposed to be' or is labelled as.
TImax: the maximum rated output current for the winding. (r.m.s.)
Treg: the percent regulation. 10% is typical. Means the secondary will have 10% extra turns.
The parameters for the V element are:
V1 SINE(0 {Tsec} 50)
and ~
Rser={(Trms*(Treg/100))/TImax}
As my mains can more often than not be 220, doing the sim as above shows why the Voltages I typically measure in my circuits are low! Especially as an HT winding is usually some step-up from the mains, so the difference can be quite marked.
.