Multisim and Ultiboard

cancel
Showing results for 
Search instead for 
Did you mean: 

Using the grpdelay function.

I have been trying to calculate the group delay thru a filter circuit, 3rd order bessel, with little success.  I've tried to use the expression builder on the output tab of the AC analysis.  The expression I've used is:
   
    grpdelay(V(4))  where V(4) is the output of circuit.

I know what to expect for the group delay based on two different tools that I can download from the TI website.  But the values that I get don't match up.

Can anyone offer a suggestion?

Thanks,

Greg

0 Kudos
Message 1 of 4
(4,599 Views)
I realize this is about 3 months late, but I'm having similar issues.  Maybe someone more familiar with the postprocessor can clarify why the SPICE commands in Multisim (10.0.343) work this way.

The group delay of a circuit is simply the negative derivative of phase wrt frequency: -dphase/dfreq.  According to my SPICE reference book, vg(vout1) will simply perform this derivative for you, and I incorrectly assumed "grpdelay" was NI's re-mapping of this macro.  In order to obtain the correct delay values I need to enter:

180*grpdelay(V(vout1))/pi

or equivalently,

-deriv(vp(V(vout1)))/(2*pi)

Why do we need a conversion factor to get the correct group delay?

-Jason
0 Kudos
Message 2 of 4
(4,440 Views)

Hi,

 

I'd really appreciate a response from NI regarding this matter.  I've run into another case where I need to calculate the group delay of an analog filter, but the supplied grpdelay() macro does not supply the correct value unless I scale it appropriately.

0 Kudos
Message 3 of 4
(4,148 Views)

Hello,

 

You have come across a bug.  There is a factor error in the resulting group delay calculation. This problem will be rectified as soon as possible.

 

 For now, the best way to get the correct result is to do it manually by writing the following expression in the in the post processor (without quotes):

 

"-deriv(ph(V(out)))/(2*pi)"

 

where v(out) is the complex vector of interest.

 

Note that the function ph() returns the phase in radians and hence the 2pi scaler.

 

Sorry for this inconvenience

Message Edited by MaxNI on 03-16-2009 11:15 AM
Max
National Instruments
0 Kudos
Message 4 of 4
(4,109 Views)