Beige Bag Software

Variable Capacitor

About the writer: Harvey Morehouse is a contractor/consultant with many years of experience using circuit analysis programs. His primary activities are in Reliability, Safety, Testability and Circuit Analysis. He may be reached at harvey.annie@verizon.net. Simple questions for which I know the answer are free. Complex questions, especially where I am ignorant of the answers, are costly!!!

Summary: In previous articles I showed how to create a variable transformer, as well as a variable resistor. This article will show how to create a voltage-variable capacitor.

Voltage variable capacitor:

It would seem trivial to create a voltage-variable capacitor. One could just pass parameter variables to a capacitor's capacitance. Simple …… or is it?

If one does this, one creates a model that will exhibit steps in voltage across the capacitor if the capacitor value is changed. This is neither desired nor correct. This occurs due the model error, as a result of misusing/misapplying the fundamental capacitor equations.

The defining equation for a capacitor is:

I(t) = C(v2(t)) * dv/dt

Clearly, the capacitance is a variable, a function of the controlling voltage. The other 'v' in dv/dt refers to the voltage applied to the capacitor. To keep them separate, we designate the controlling voltage as v2(t). Solving for dv/dt,

dv/dt = i(t)/C(v2(t))

Integrating both sides results in:

v = integral [i(t)/C(v2(t))]

Let the value of the capacitance C(v2(t)) be Co + v2(t)*Co, where Co is the value of the capacitor with va(t) = 0. It is convenient to nominally define the control voltage limits to between zero and one volts. This would however limit the capacitance variation to 2 * Co. One could allow va(t) to vary greater than 1 volt. We can get a little more flexibility by introducing another variable, k. The defining equation for C(v2(t)) becomes:

C(v2(t)) = Co + k*v2(t)*Co

'k' could of course be fractional. Suppose the maximum v2(t) were 5V, however, if it were desired to make the maximum capacitance be perhaps 3.5 times the zero voltage value, k would be set to a value equal to 3.5/5 or 0.7.

Modeling:

A model embedded in a test circuit is shown in Figure 1 following:


Figure 1
Voltage variable capacitor test circuit

A netlist for this circuit is:

Circuit1
************************
* B2 Spice
************************
* B2 Spice default format (same as Berkeley Spice 3F format)
***** subcircuit definitions
**-- Continuous Filtering Function Macromodel --**
.SUBCKT cffm 10 30 20
* Node 10= Input, Node 30= Output, Node 20= GND
RIN 10 20 1.000000e-003
BEIN 100 0 V= V(10,20) * 1.000000e+000 - V(101) * 0.000000e+000
REI 100 0 1
G1 0 101 100 0 1
R1 101 0 1T
C1 101 0 1
BESO 102 0 V= V(100) * 0.000000e+000 + V(101) * 1.000000e+000
ROT 102 30 1.000000e-003
RDY 30 0 1T
.ENDS cffm

***** main circuit
VAm1 N3 5 0
B1 5 0 v=v(n4,0)
B2 6 0 v = I(Vam1) / (1e-6+1e-6*1*v(n1,n2))
V3 7 0 DC 10
V1 8 0 DC 10
R1 N3 8 10K
R2 N4 0 1Meg
R3 N1 0 1G
V2 N1 0 DC 0 PULSE( 0 2 5m 1p 1p 100m 1)
XX1 6 N4 0 cffm
R4 7 N5 10K
C1 N5 0 1u

.OPTIONS gmin = 1E-12 reltol = 1E-4 itl1 = 500 itl4 = 500
+ rshunt = 1G
.TRAN 10u .1 0 10u uic
.IC
.END

A perhaps unfamiliar block in the model is the continuous filtering function. This block is used as a LaPlace function integrator. Its transfer function is '1/s', where 's' is the Laplace operator. The control voltage is a pulse with an amplitude of 2V, starting at 5 mS and lasting for 100 mS.

A graph of the output with the values of 'Co' to be simulated as 1uFd, k =1, and 10V DC in series with a resistance of 10K applied to the 'capacitor' is shown in Figure 2.


Figure 2
Voltage variable capacitor test circuit

The 'pink' trace is the 'reference' capacitor. The test circuit 'orange' trace and the reference trace coincide until about 5 mS, when the test capacitor value changes for the duration of the trace. The output trace shows no abrupt jumps, as should be the case.

It is left as an exercise for the reader to create a parameterized subcircuit model for this device as well as an appropriate symbol, passing it values for Co and k.

Summary:

A voltage variable capacitor model has been created. The B2 device equation may be changed to reflect devices that operate in other manners, such as perhaps a square law function of voltage.


 

 


Beige Bag Software, Inc., 623 W. Huron, Suite 2, Ann Arbor, MI, 48103
(phone) 734.332.0487 (fax) 734.332.0392 (email) info@beigebag.com
© 2005-2010 Beige Bag Software, Inc