Use magnitude to compute dB #92

This commit is contained in:
Vadim Kuznetsov 2023-06-19 13:20:04 +03:00
parent 757aab9078
commit d6cc945b17

View File

@ -228,7 +228,8 @@ void Marker::createText()
break;
}
} else {
double val = qucs::num2db(fabs(*pz),ax->Units);
double mag = sqrt(pz[0]*pz[0] + pz[1]*pz[1]);
double val = qucs::num2db(mag,ax->Units);
Text += QString::number(val,'g',Precision);
}