You should introduce variables corresponding to current through the inductor I and capacitor voltage U. Let's say it is series LCR filter (picture attached) feed by voltage source Vin(t) and the output is voltage across R. You can write corresponding diff equations as
Vin(t) = L* dI/dt + U + R*I
C* dU/dt = I
We define output as
Vout(t) = R *I
Time discrete variant will be
Vin[k] = L *( I[k+1] - i[k])/dt + R *I[k] +U[k]
C *( U[k+1] - U[k] ) = dt*I[k]
Vout[k] = R *I[k]
You can solve it as (assuming some initial conditions e.g. I[0]=0 , U[0]=0 ):
Here's a MATLAB function example for a series RLC (for voltage across the capacitor). You can modify it for other circuits (e.g. parallel), or currents/voltages. See Nikolay's answer.