필터 지우기
필터 지우기

what is the difference between "unwrap" and "phasez" function

조회 수: 2 (최근 30일)
sohyeon jung
sohyeon jung 2018년 8월 20일
댓글: Nathan Jessurun 2018년 12월 10일
Hello, I'm trying to analyze the phase response of S-parameter.
And there are 2 functions in Matlab in term of unwrapped phase, which are "unwrap" and "phasez".
When I plot three case below, it shows difference result.
test1 = angle(S21)*180/pi;
test2 = unwrap(angle(S21)*180/pi);
test3 = phasez(angle(S21)*180/pi);
I understood the how the "unwrap" function work. (It just make it flat.)
But, I couldn't get How the matlab create the "phasez" plot. And, I found out the "phasez" function make the matrix size to be 512*1. Is there specific reason for this?
In addition,in principle, the unwrapped phase need to start from 0 in DC.
But, the plot of test2 doesn't. So, that's also confusing.
Is there anyone to explain this question?

채택된 답변

Rachana Reddy Mamilla
Rachana Reddy Mamilla 2018년 8월 30일
Unwrap function is used to make the phase continuous and it’s not necessary for it to Start from 0.It depends on the input you give. phasez returns the n-point unwrapped phase response vector. If n is not defined ,It would consider the default value to be 512(which is an intermediate value using which one can hopefully get most of the information). If n is not defined , it would consider the default value to be 512 (which is an intermediate value using which one can hopefully get most of the information). For best results, set n to a value greater than the filter order. You can check this for more info.
  댓글 수: 1
Nathan Jessurun
Nathan Jessurun 2018년 12월 10일
Hi Rachana,
The answer you linked no longer exists. Would you mind updating the reference?
Also, I attempted to plot the phase with a greater n than the filter order in this example (https://www.mathworks.com/matlabcentral/answers/435035-how-does-phasez-work) but it didn't make any difference. Do you have any other suggestions?
Thanks!

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

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by