control.mag2db

control.mag2db(mag)

Convert a magnitude to decibels (dB)

If A is magnitude,

db = 20 * log10(A)
Parameters:

mag : float or ndarray

input magnitude or array of magnitudes

Returns:

db : float or ndarray

corresponding values in decibels