Measuring average power dissipated by a component in LTSpice

Thread Starter

cmartinez

Joined Jan 17, 2007
6,463
Is there a way of obtaining an average value of a measurement over time in LTSpice? For instance, I've just measured the power dissipated by a resistor in a sim, and although the graphic is very telling, it's also full of "spikes" that are very hard to read just by looking at them. Even though the spikes can reach levels of up to 400W, I know that maybe that resistor is not dissipating more than just a watt or two, because those events are extremely narrow.

upload_2018-6-10_1-10-11.png

So my specific question is, how can I measure the average power dissipated by R2 (according to the graph being shown) through a specific amount of time?
 

Thread Starter

cmartinez

Joined Jan 17, 2007
6,463
Got it! ... the sim I'm running is a bit heavy, and it takes LTSpice about 20 minutes to complete a 50 ms simulation. So I get the message "Integration isn't possible while the simulation is running" ... fair enough, I'll wait.
 

Thread Starter

cmartinez

Joined Jan 17, 2007
6,463
20 minutes, I said? That stupid thing's been doing calculations for more than two hours now!
 

Thread Starter

cmartinez

Joined Jan 17, 2007
6,463
Obviously something wrong with the simulation. Post your schematic and we'll take a look.

eT
I agree ... there's probably a value in there that pushes the calculations to numerical limits. Or maybe the floating voltage sources V2 and V3 are interfering somehow, and their grounds should be connected to general ground via very high value resistors. Say 10 megs?

Thanks to you guys, I've got the result I wanted, anyway. But it'd be nice if I could learn how to speed things up.

upload_2018-6-10_18-53-39.png
 

Attachments

eetech00

Joined Jun 8, 2013
1,660
I agree ... there's probably a value in there that pushes the calculations to numerical limits. Or maybe the floating voltage sources V2 and V3 are interfering somehow, and their grounds should be connected to general ground via very high value resistors. Say 10 megs?

Thanks to you guys, I've got the result I wanted, anyway. But it'd be nice if I could learn how to speed things up.

Hi

Use the startup option, like this:
.tran 0 50m 0 startup
If you don't do this, then LTspice expects you to know/set all initial operating conditions.

All voltage sources have serial resistance. Use some serial resistance in your voltage sources V1, V2, V3. Unless you know specifics, use 100milli ohms.

Once I did the above, the simulation completed in about 7 seconds. :cool:

eT
 

Thread Starter

cmartinez

Joined Jan 17, 2007
6,463
Hi

Use the startup option, like this:
.tran 0 50m 0 startup
If you don't do this, then LTspice expects you to know/set all initial operating conditions.

All voltage sources have serial resistance. Use some serial resistance in your voltage sources V1, V2, V3. Unless you know specifics, use 100milli ohms.

Once I did the above, the simulation completed in about 7 seconds. :cool:

eT
Nice trick! ... thanks for sharing :)
 

Thread Starter

cmartinez

Joined Jan 17, 2007
6,463
Question, how come when I ctrl-click on the label of a current waveform I get a report with average and rms data, but when I do the same on a power waveform I only get data for average? Wouldn't rms be a more adequate indicator for power than a simple average?
 
Top