Unfortunately, you have a snag - your current cannot go negative because you have a diode, so instead of getting a nice triangle wave for the current (being the integral of a squarewave) the negative side is clipped.Maybe it's not that tough. All periodic waveforms are made up of a sum of sine and cosine functions. The voltage wave is just an amplitude V multiplied by a unity wave function. When the V = L(di/dt) is integrated for a sine wave, we integrate
di = V/L cos(wt) dt
so
i(t) = V/wL sin(wt)
the current becomes V/wL (the amplitude of the current) multiplied by another unity wave function. Since all the components of a periodic wave are sine or cosine, all integrate as another sine or -cosine with the w coming out as 1/w and you still get V/wL and a unity wave function. So the reactance is always wL.
For example, a unity square wave is just
square(t) = 4/pi * [sin(wt) + 1/3*sin(3wt) + 1/5*sin(5wt) + ...]
This produces a square wave from -1 to +1, and the voltage formula would be just
v(t) = V * square(t).
Every term of the unity function would integrate to 1/w multiplied by a sine or -cosine and the w would come out and combine with the V/L as V/wL from the distributive property.
You then have two separate situations with different solutions know as "continuous current" and "discontinuous current".
If your waveform was driven to the positive supply by another MOSFET, instead of allowing the stored energy to do it for you via the diode, the current could go negative (energy put back into the supply from the inductor) and your maths would work in all cases.
I think someone mentioned that back in post #73.Actually, if all periodic waves are explained by a Fourier series, then even a DC-offset wave should have a Fourier series. Perhaps X=wt for any periodic wave.
Don