Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Help with Ltspice - .Meas command

Status
Not open for further replies.

Ofer Sharabi

New Member
Hello All,

I need to find the absolute maximum peak value (not peak to peak) .

It can be negative or positive.

Now I am using the command .meas var tran max v(var)

The command is working good but only for the positive side.

I can use the min function but it will give me only the negative side.

Is there a combination of 1 command that will give me the max of the max and the absolute of min ?

Please help

thanks
 
LTSpice has an abs(x) function. Perhaps this is what you're looking for?

http://ltwiki.org/index.php?title=Waveform_Arithmetic

Example: If you're looking for the absolute max deviation from your x axis, set one variable to the max(y) value (positive side), set one variable to the min(y) value (negative side), use the abs() function on each one to get the absolute value of each one, and then compare the two results to see which one is higher.

I'm not expert in LTSpice, so I have no idea if this is useful at all.
 
You'll have to be a little more specific than "it will not work".
 
Try this: .meas var tran max(abs(v(var)))

 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top