How can I get 2 signal differences in log scale?

Can anybody help me, please!! I have a problem, hope you can help me! I have 2 signals in logarithmic scale, their power levels are different. The plot is here: https://www.dropbox.com/s/17dkngq0a4dqzgc/plot.bmp
I need to subtract this 2 signals and get their power level differences in dB, for example, for 1K level difference is appx. 30 dB. All results I need to plot in log scale as well. I used 10^(db/20) to get them into power scale, but do not know how to get them back to dB scale. So, which command to choose to subtract them in log-scale??
Thank you in advance!!

답변 (2개)

Matt J
Matt J 2013년 7월 4일

0 개 추천

Wouldn't it just be the inverse of 10^(db/20), i.e.,
db=20*log10(power)

댓글 수: 2

Lucky
Lucky 2013년 7월 4일
thank you for your answer, but I tried this, the argument should be a number log10(20) for example, but I have a signal curve, log10(signal) doesn't work for me.. should I calculate to each frequency dB values by this formula??
Works fine for me
>> signal=1:5; db=20*log10(signal)
db =
0 6.0206 9.5424 12.0412 13.9794

댓글을 달려면 로그인하십시오.

Iain
Iain 2013년 7월 4일

0 개 추천

You can get the ratio between the power levels simply by taking dB1 - dB2. This is probably more sensible unless the numbers are very similar.
p1 = 10^(10*dB); % etc
dp = p1 - p2
ddB = 10*log10(dp); %
Thats to do it through power. For voltage or current:
i1 = 10^(20*dB1);
di = i1 - i2
ddB = 10*log10(di);

댓글 수: 1

Lucky
Lucky 2013년 7월 4일
thank you, now its more clear, but the next question is, how to extract values (dBs from X axes) from my signal figures? As I understand, these formulas work only for real values?

댓글을 달려면 로그인하십시오.

카테고리

도움말 센터 및 File Exchange에서 MATLAB에 대해 자세히 알아보기

질문:

2013년 7월 4일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by