Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

decibel calculation

Status
Not open for further replies.

clapper62

Programmer
Apr 17, 2003
113
US
Hello All
I have this code​

Private Sub cmdCalcPowerDbGainLoss_Click()
Dim PowerGainRatio As Double
PowerGainRatio = Me.tboxOutputPower / Me.tboxInputPower

Me.tboxDbGainLoss = Log(PowerGainRatio) * 0.43429
Me.tboxDbGainLoss = Me.tboxDbGainLoss * 10

Me.tboxVoltageDbGainLoss = Log(PowerGainRatio) * 0.43429
Me.tboxVoltageDbGainLoss = Me.tboxVoltageDbGainLoss * 10 * 2

End Sub

It takes a given input power/voltage and and an output power/voltage and calculates
decibel gain/loss (accurately I think)

I would also like to enter an input voltage and a Decibel gain/loss and calculate the output voltage
but I can't figure out the equation to do it, math skills not so great

thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top