필터 지우기
필터 지우기

How to calculate fourier coefficients in Matlab

조회 수: 3 (최근 30일)
Javid
Javid 2013년 10월 21일
댓글: sixwwwwww 2013년 10월 23일
Hello
Can anybody help me with this assignment because i really have no idea to do it. I only finished first part of assignment where i do not need Matlab
  댓글 수: 1
sixwwwwww
sixwwwwww 2013년 10월 21일
Can you share your first part? so that we can get idea what you actually need to do?

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

채택된 답변

sixwwwwww
sixwwwwww 2013년 10월 23일
Dear Javid, here is the code for your problem:
A = input('Enter value of A:');
B = input('Enter value of B:');
D = input('Enter value of D:');
alpha = input('Enter value of alpha:');
beta = input('Enter value of beta:');
gamma = input('Enter value of gamma:');
sigma = input('Enter value of sigma:');
n = input('Enter value of n:');
a0 = A * alpha + B * (gamma - beta) + D * (1 - sigma);
val = 1:n;
a = (-1 / (pi * val)) * (A * sin(2 * pi * val * alpha) - B * (sin(2 * pi * val * gamma) - sin(2 * pi * val * beta)) - D * (sin(2 * pi * val) - sin(2 * pi * val * sigma)));
b = (1 / (pi * val)) * (A * (cos(2 * pi * val * alpha) - 1) + B * (cos(2 * pi * val * gamma) - cos(2 * pi * val * beta)) + D * (cos(2 * pi * val) - cos(2 * pi * val * sigma)));
I hope it is what you need. Good luck!
  댓글 수: 2
Javid
Javid 2013년 10월 23일
Thank you very much.
sixwwwwww
sixwwwwww 2013년 10월 23일
You are welcome

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

추가 답변 (1개)

Javid
Javid 2013년 10월 22일
This is the first part of assignment and my solution.

카테고리

Help CenterFile Exchange에서 Mathematics에 대해 자세히 알아보기

태그

아직 태그를 입력하지 않았습니다.

Community Treasure Hunt

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

Start Hunting!

Translated by