RC analysis

I have the circuit whose LTSPICE text is given below. The voltage sources and voltage controlled switches are only there to set the initial voltages on the capacitors. Thus the circuit of interest consists of two capacitors and two resistors.

I've been trying to determine an equation that describes the voltage on C2 as it varies with time, but with my limited mathematical skill, haven't been able to. I end up with differential equations that contain the voltage on C1 as well, in a way that I can't substitute for.

Any thoughts?

Sylvia.

Version 4 SHEET 1 880 680 WIRE 624 16 256 16 WIRE 96 32 0 32 WIRE -48 128 -96 128 WIRE 0 128 0 112 WIRE 576 128 528 128 WIRE 624 128 624 96 WIRE -48 144 -48 128 WIRE 96 144 96 32 WIRE 144 144 96 144 WIRE 256 144 256 16 WIRE 256 144 224 144 WIRE 320 144 256 144 WIRE 576 144 576 128 WIRE 96 208 0 208 WIRE 256 208 96 208 WIRE 368 208 256 208 WIRE 400 208 400 144 WIRE 400 208 368 208 WIRE 544 208 528 208 WIRE 576 208 576 192 WIRE 576 208 544 208 WIRE -96 224 -96 208 WIRE -64 224 -96 224 WIRE -48 224 -48 192 WIRE -48 224 -64 224 WIRE 400 256 400 208 WIRE 624 256 624 208 WIRE 624 256 400 256 FLAG 368 208 0 FLAG -64 224 0 FLAG 544 208 0 SYMBOL cap 80 144 R0 SYMATTR InstName C1 SYMATTR Value 10 SYMBOL cap 240 144 R0 SYMATTR InstName C2 SYMATTR Value 300 SYMBOL res 240 128 R90 WINDOW 0 0 56 VBottom 2 WINDOW 3 32 56 VTop 2 SYMATTR InstName R1 SYMATTR Value 0.5 SYMBOL res 416 128 R90 WINDOW 0 0 56 VBottom 2 WINDOW 3 32 56 VTop 2 SYMATTR InstName R2 SYMATTR Value 1 SYMBOL sw 0 112 R0 SYMATTR InstName S1 SYMATTR Value SW1 SYMBOL voltage 0 16 R0 WINDOW 123 0 0 Left 2 WINDOW 39 0 0 Left 2 SYMATTR InstName V1 SYMATTR Value 50 SYMBOL voltage -96 224 R180 WINDOW 0 24 96 Left 2 WINDOW 3 24 16 Invisible 2 WINDOW 123 0 0 Left 2 WINDOW 39 0 0 Left 2 SYMATTR InstName V2 SYMATTR Value PULSE(-1 1 0 0 0 1 2 1) SYMBOL sw 624 112 R0 SYMATTR InstName S2 SYMATTR Value SW1 SYMBOL voltage 528 224 R180 WINDOW 0 24 96 Left 2 WINDOW 3 24 16 Invisible 2 SYMATTR InstName V3 SYMATTR Value PULSE(-1 1 0 0 0 1 2 1) SYMBOL voltage 624 0 R0 WINDOW 123 0 0 Left 2 WINDOW 39 0 0 Left 2 SYMATTR InstName V4 SYMATTR Value 1 TEXT -412 232 Left 2 !.tran 50 TEXT -368 328 Left 2 !.model SW1 SW(Ron=0.0001)

Reply to
Sylvia Else
Loading thread data ...

Actually, never mind. It involves solving simultaneous differential equations. I'll just have to read up on that.

Sylvia.

Reply to
Sylvia Else

SPICE has an initial condition function for what you want:

The .ic directive allows initial conditions for transient analysis to be sp ecified. Node voltages and inductor currents may be specified. A DC solutio n is performed using the initial conditions as constraints. Note that altho ugh inductors are normally treated as short circuits in the DC solution in other SPICE programs, if an initial current is specified, they are treated as infinite-impedance current sources in LTspice.

Syntax: .ic [V()=] [I()=]

Example: .ic V(in)=2 V(out)=5 V(vc)=1.8 I(L1)=300m

Reply to
bloggs.fredbloggs.fred

Sylvia Else wrote in news: snipped-for-privacy@mid.individual.net:

Or get into the S-domain and use Laplace maths, which should get you some time domain equation at the end. Don't ask me the details though, its been a long time

Reply to
Geoff

Yep, that's the correct way.

Replace C's with an impedance value 1/(Cs), where "s" is the Laplace variable, then simply write a transfer V(OUT)/V(IN)

You'll get a second order equation which must be partial-fraction expanded, then you can write down the time domain by observation.

I do it automatically... trying to explain it is hard :-(

I'll look for a write-up... must have it around here somewhere.

The technique, BTW, is courtesy of Oliver Heaviside... not Laplace. ...Jim Thompson

--
| James E.Thompson                                 |    mens     | 
| Analog Innovations                               |     et      | 
 Click to see the full signature
Reply to
Jim Thompson

Jim Thompson wrote in news: snipped-for-privacy@4ax.com:

I remember Heaviside being mentioned occasionally in maths class in college. I just looked him up in wiki. What a character, and to think he coined words like impedance and permeativity.

Reply to
Geoff

Yep. Neat fellow. Lots of engineering short-hand techniques from him. ...Jim Thompson

--
| James E.Thompson                                 |    mens     | 
| Analog Innovations                               |     et      | 
 Click to see the full signature
Reply to
Jim Thompson

First of all can we see a circuit diagram instead of a Spice listing!!! Secondly what voltage is the input ie dc a sine wave etc

Reply to
gyansorova

Sylvia posted an LTspice .ASC file, which _is_ a schematic. ...Jim Thompson

--
| James E.Thompson                                 |    mens     | 
| Analog Innovations                               |     et      | 
 Click to see the full signature
Reply to
Jim Thompson

Useful to know. Thanks.

Sylvia.

Reply to
Sylvia Else

Partial fraction expansion, all nicely explained...

...Jim Thompson

--
| James E.Thompson                                 |    mens     | 
| Analog Innovations                               |     et      | 
 Click to see the full signature
Reply to
Jim Thompson

Thanks.

After looking at some stuff relating to solving simultaneous 1st order differential equations, I learnt that two first order simultaneous equations in two variables can be written as a single second order differential equation in one variable, which I do know how to solve.

So I went back, and saw how that could be achieved.

The result is a rather involved function of the six variables (C1, C2, R1, R2, V1 and V2).

This is not actually an electronic circuit, but a representation of the thermal behaviour of a water heater. Consequently I don't know the values of V1, C1 or R1. I was hoping to infer them from the equation and the measured behaviour. I'd end up with three simultaneous equations to solve, which, given their complexity, would probably have to be done numerically.

Maybe I still will, out of interest, but it'll be a lot simpler to interpolate from those measurements that I do have, and probably more than adequate.

Sylvia.

Reply to
Sylvia Else

Well all I see is a list of numbers! I need a real circuit diagram.

Reply to
gyansorova

Ahh I've done that. Usually you can stare at it and find one RC that dominates the behavior. You'll want to model the heater as a current source. Temperature corresponds to voltage and Energy is like charge. So a one watt heater is like a 1 amp current source. The heat capacity of the water should be pretty easy to get. What else is unknown? (One issue you may have in modelling is if there are convective heat currents in the water.) So what are your R's and C's?

George H.

Reply to
George Herold

Advice to smart-ass little wimp f*ck-head... get with the action and install LTspice. ...Jim Thompson

--
| James E.Thompson                                 |    mens     | 
| Analog Innovations                               |     et      | 
 Click to see the full signature
Reply to
Jim Thompson

It's easy to install LTspice, which is free, and cut and past the list of numbers into a file and open it with LTspice.

This group can only have text so no schematics.

--
Mike Perkins 
Video Solutions Ltd 
 Click to see the full signature
Reply to
Mike Perkins

d

inates the behavior. You'll want to model the heater as a current source.

tt heater is like a 1 amp current source.

s unknown? (One issue you may have in modelling is if there are convective heat currents in the water.) So what are your R's and C's?

That's very boring, like you're going to construct a homemade heater anywhe re near as efficient as off-the-shelf models... but this is interesting, al most doubles the effective heat capacity of the tank, useful for people in situations of sporadic high demand:

formatting link

Reply to
bloggs.fredbloggs.fred

Yes.

R1 is the thermal resistance between the heater element[*] and the water. C1 is the specific heat of the heater element.

R2 is the thermal resistance from the water to ambient. In this particular situation it appears to be pretty much independent of the amount of water. C2 is the specific heat of the water and its container.

V1 is the temperature of the heater at the point where it is turned off. V2 is the temperature of the water at the point where the heater is turned off.

The main issue I have is determining the point at which to turn off the heater so that the temperature of the water peaks at a predetermined point.

I wouldn't have expected C1 to matter much, but it clearly does, at least in conjunction with the also unknown V1. Depending on the amount of water, I can see an overshoot after the heater is turned off of 20 degrees Celsius.

The heat capacity of the water certainly dominates C2, and that's easy to calculate. Similarly, R2 is easy to measure just by observing how quickly the water cools. V2 is just the temperature of the water immediately after the heater is turned off.

I can determine a good value for (V1 - V2) / R1 based on the rate of temperature rise of the water just before the heater is turned off (after allowing for the known loss through R2). I've yet to look at the math to see whether that helps much.

Convection in the water seems inevitable, since water is a poor conductor of heat. The effects are quite visible in the temperature measurements, though the variability is less than a degree in the setup I have (admittedly, I'm only measuring the temperature at one point). Things quieten down once the heater is off.

Sylvia.

[*] Actually, of course, the heater element is a resistance wire inside an insulator, so it has its own somewhat complex thermal behaviour. I'm assuming I can ignore that for practical purposes, and treat it as a single thermal mass at some temperature.
Reply to
Sylvia Else

Who mentioned efficiency? I certainly didn't.

Sylvia.

Reply to
Sylvia Else

Besides, with the LTSpice input, you have a model there ready to be run.

Sylvia.

Reply to
Sylvia Else

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.