simulating_a_time-varying_capacitor_in_spice
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
simulating_a_time-varying_capacitor_in_spice [2024/09/10 10:25] – bm | simulating_a_time-varying_capacitor_in_spice [2024/09/10 11:51] (current) – bm | ||
---|---|---|---|
Line 22: | Line 22: | ||
.subckt capacitor + - params: VC0=0 | .subckt capacitor + - params: VC0=0 | ||
.func C(time) {5n+3n*sin(2*pi*100k*time)} | .func C(time) {5n+3n*sin(2*pi*100k*time)} | ||
- | hvolt + - value={(sdt(I(+,-))+VC0*C(0))/ | + | hvolt + - value={(sdt(I(hvolt))+VC0*C(0))/ |
.ends | .ends | ||
</ | </ | ||
Line 38: | Line 38: | ||
To use the time-varying capacitor in a circuit, click " | To use the time-varying capacitor in a circuit, click " | ||
- | Plotting the value of the inductance | + | Plotting the value of the capacitance |
Case (i): We apply a high frequency source in order to create an envelope facilitating comparison between both cases. | Case (i): We apply a high frequency source in order to create an envelope facilitating comparison between both cases. | ||
+ | {{: | ||
- | {{: | + | At a certain time, e.g., t=50µs, the value of the capacitor |
- | + | ||
- | At a certain time, e.g., t=50µs, the value of the inductor | + | |
If we then zoom in at the simulation at t=50µs, we find the peak value of voltage over and current through the inductor. | If we then zoom in at the simulation at t=50µs, we find the peak value of voltage over and current through the inductor. | ||
- | Case (ii): We compare this value with a static inductor of 5 mH: | + | Case (ii): We compare this value with a static inductor of 5 nF: |
- | + | {{: | |
- | {{: | + | |
We find that both the current and voltage correspond to case (i). | We find that both the current and voltage correspond to case (i). | ||
- | We do the same for a lot of other values of time, and always find a correspondence between both cases. This is not a rigid proof, but it gives us sufficient confidence that the inductor | + | We do the same for a lot of other values of time, and always find a correspondence between both cases. This is not a rigid proof, but it gives us sufficient confidence that the capacitor |
simulating_a_time-varying_capacitor_in_spice.1725963907.txt.gz · Last modified: by bm