|
| Filename | Size |
|---|---|
| spice_RCL_init.mph | 25 KB |
| Download all files (Zip-archive) | ~ 20 KB |
SPICE RCL-circuit with initial conditions
Per Sundqvist, ABB Corporate Research AB
Email:
This model shows how to set up a SPICE model of a RCL-circuit in COMSOL4.0a with other initial conditions than default.
The SPICE (Electric Circuit, "cir") in COMSOL does not allow you to specify initial voltage of a capacitor or an initial current through an inductor.
This is a way of walking around this problem, using sub-circuits (External IvsU and UvsI) in combination with the equations of state for C and L in an "ODEs and DAEs"-node in COMSOL.
The tricky part is to find out what the variable name for the voltage across the inductor (mod1.cir.UvsI1_v) and the current through the capacitor (mod1.cir.X1_i) are, as these enters in the ODE's. One could find out these from the plot-menu: Results->1D Plot Group 1->Global 1->Expressions->(+)->Electrical Circuit->Voltage across device UvsI1 (mod1.cir.UvsI1_v).
Other Entries by This Contributor
User Comments
|
JM Aniceto Oct 13, 2010 at 2:34pm UTC |
|
Very useful for those who want to couple a FEM simulation with an oscillating circuit. |
|
Heigo Mõlder Nov 23, 2010 at 8:59am UTC |
|
Can you save this in Comsol 3.5 version ? |
|
JM Aniceto Dec 8, 2010 at 3:10pm UTC |
|
Hi Heigo, |
|
Linlin Yu Jul 21, 2011 at 10:00am UTC |
|
thanks, JM Aniceto. |
|
Maestro Conalep Conalep Cuernavaca Sep 10, 2011 at 2:46am UTC |
|
thanks for your aportations... |
Login to comment on this entry.

