Hi again,
I think most of the problems you are encountering are due to the difference
between the pure theoretical circuit and the circuit analysis program.
Most circuit analysis programs use numerical analysis and dont actually solve
the ODE perfectly like you have here.
This means that when we compare the perfect analysis to the program analysis we
are going to see differences and so something is going to look wrong.
Note for example, that there are two frequencies: w and TH as you found,
yet we see (apparently) only one sinusoidal wave in the solution for iL(t)
with the circuit analysis program. The two amplitudes are significant too
in the pure analysis, yet we see only one component. How can this be?
There could be a couple reasons for this, but the simplest would be that the
analysis program is inserting some default nonzero value for the resistance in the
inductor. In any case, what we might do is solve the circuit using theory
but first insert some small resistance in series with the inductor before we start.
In other words, look at a circuit with R as well as the L and C, and the R would
be in series with the L and C. This could be called the bulk resistance of the
circuit and may represent both the L and C ESR. Note also that the current wave
starts out as a relatively fast oscillation, which dies out after a short time. This
is also indicative of some small series resistance, because without that resistance
this oscillation would never go away.
It goes almost without saying that if we look at the analysis program output and
try to reckon that with some assumed property about a circuit with "no resistor'
that we are going to have a problem because the analysis program actually did
insert some nonzero resistance. We thus end up theorizing about a circuit that
the analysis program knows nothing about
Thus, if you want to see a wave that looks like the circuit analysis program you
are going to have to insert some small series R and do the analysis again.
Alternately, you'll have to figure out how to stop your program from inserting
default values like that.
Also, a wave that has two different frequency components can still be periodic,
although the period may be longer than any single frequency component period.
You should also think about the relative sizes of the components. For example,
if you use a very very small inductor value (like 1nH) you may not see a wave
that looks like an inductor in series with a capacitor, but one that looks more
like a single capacitor. This would be because some of the effects of the inductor
may die out during the first 1ns (for example) when we are looking at tens of ms.
Thus, the size of the inductor may have to be increased in order to see a more
typical response.
BTW, if you do the calculations with the pure analysis you did you should find that
at say t=10ms you get one amplitude in iL(t) and at t=11ms you get a big change
in amplitude while the circuit analysis program shows a very small change. This
indicates that the circuit analysis program is not showing the same analysis.