Convert to decibels.
g=db(f)
g=db(f,ref)
DB(F) is the base 10 logarithm of the ordinate values of the imat_fn F. Complex results are produced if F is not positive. REF is an optional input scalar specifying the reference value to use.
DB only looks at the Ordinate Numerator. If REF is not supplied, DB uses 2e-5 Pa as a reference for Pressure and Sound Pressure data types, and 1G as a reference for Acceleration. For squared OrdNumTypeQual, DB uses the formula
DB = 10 * log10(F/REF)
For linear OrdNumTypeQual, DB uses the formula
DB = 20 * log10(F/REF)
DB places the OrdNumDataType label into OrdNumAxisLab, and sets OrdinateUnitsLab to 'DB'. It then sets the OrdNumDataType of the output to Unknown. The reference value used for the Decibel conversion is stored in UserValue3.