Electronic – LTSpice buck converter output voltage too high

buckltspicepower electronics

I am designing a 311V to 48V buck converter in LTSpice using ideal components for now.

schematic

I am using a 48V/311V = 15.434% duty cycle in V2 which controls S1:

V2 setup

This is the simulation output:

simulation

Below is the inductor current and downstream switch voltage at steady-state:

enter image description here

I don't understand why the output voltage is ~52.1V instead of 48V. I tried different SPICE directives for the switch from various tutorials online but I get the same result. I also tried decreasing the max time step to 1u, to no avail.

Any idea why this is happening? Thanks

Best Answer

Insert a rise time and fall time for the pulsed voltage source. There are default values used when you input 0 that are realistic but >0, if you want to see more ideal behavior use a value like 1n.

PULSE(0 5 10u 1n 1n 1.5434u 10u)