Xref: utzoo sci.research:1536 sci.electronics:18020 Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!zaphod.mps.ohio-state.edu!uakari.primate.wisc.edu!dali.cs.montana.edu!milton!whit From: whit@milton.u.washington.edu (John Whitmore) Newsgroups: sci.research,sci.electronics Subject: Re: Variable Capacitor in SPICE Message-ID: <17096@milton.u.washington.edu> Date: 25 Feb 91 05:01:02 GMT References: <1991Feb21.223126.15937@sol.UVic.CA> Distribution: na Organization: University of Washington, Seattle Lines: 25 In article <1991Feb21.223126.15937@sol.UVic.CA> shankar@face.UVic.CA (P.S.Shankar.) writes: > I am trying to simulate what is essentially a RC circuit using SPICE. > ... I need to put in > capacitors, whose values depend on the voltages on them, all of which are > typically time-varying. This is where the controlled sources come in handy. First, replace the capacitor by a current meter (zero V voltage source), and a voltage-controlled voltage source in series. Then make a current-controlled current source onto a dummy capacitor, whose output current is identically the current measured by the current meter. So you now have a dummy capacitor whose state of charge is identical to that of your real capacitor. Its voltage, of course, is proportional to the capacitor charge. SO, now use a voltage-controlled voltage source (controlled by the voltage on the dummy capacitor) to emulate the REAL capacitor (of course, the controlled source is exactly the one you replaced your capacitor with. The rest of the solution will involve translating the behavior of your (voltage-variable capacitor diode?) into a suitable form (Vcapacitor= polynomial in Qcapacitor). John Whitmore Brought to you by Super Global Mega Corp .com