필터 지우기
필터 지우기

How do i implement a gain of 10 inside my filter MAtlab?

조회 수: 10 (최근 30일)
Sachin NARAIN
Sachin NARAIN 2019년 5월 16일
댓글: Jan 2019년 5월 16일
In MAtlab i have a filter with transfer functions coefficients A and B and then i use the 'filter' funtion syntax to implement the filter in our input signal.
Now i also need to implement a gain of 10 or 20 inside my filter so that i get an amplified signal.How do i do that?
ANy help will be appreciated

채택된 답변

Jan
Jan 2019년 5월 16일
편집: Jan 2019년 5월 16일
See this:
t = 1:30;
x = rand(1, 30); % Some test data
[b, a] = butter(3, 0.8); % A Butterworth filter
x1 = filter(b, a, x) * 4; % Filter and amplify
x2 = filter(b * 4, a, x); % Amplify internally
plot(t, x1, 'ro', t, x2, 'c-')
max(abs(x1-x2)) % 0.0, but some rounding error can be expected
  댓글 수: 2
sachin narain
sachin narain 2019년 5월 16일
Thanks for the response so i should do b*4 (that is the denominator *4) right??
Jan
Jan 2019년 5월 16일
b — Numerator coefficients of rational transfer function

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

추가 답변 (0개)

태그

Community Treasure Hunt

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

Start Hunting!

Translated by