필터 지우기
필터 지우기

How to plot this signal?

조회 수: 2 (최근 30일)
Abdullah Alasfour
Abdullah Alasfour 2023년 7월 19일
댓글: Abdullah Alasfour 2023년 7월 19일
dt= 0.0001;
t = 0:dt:10;
ht= abs( (1/2*pi*j*t)*( exp(j*1460*pi*t) - exp(j*1450*pi*t)) );
plot(t,ht)
title(' plotting h(t)')
xlabel(' Time')
ylabel(' h(t)')
grid on
I want to plot this signal in Octave or Matlab, but it dosen't work, and I don't know why it dosen't plot.

채택된 답변

Adam Danz
Adam Danz 2023년 7월 19일
편집: Adam Danz 2023년 7월 19일
ht= abs( (1/2*pi*j*t).*( exp(j*1460*pi*t) - exp(j*1450*pi*t)) );
% Add this ----------^
".*" is element-wise multiplication.
"*" is matrix multiplication and requires size-agreement between the two values you are multiplying.
  댓글 수: 3
Adam Danz
Adam Danz 2023년 7월 19일
Looks like you're using the imaginary unit j. I initially thought j may have been a variable not included in your question. That doesn't impact the answer, just double checking that this is your intention.
Abdullah Alasfour
Abdullah Alasfour 2023년 7월 19일
Yes, this was my intention

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

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by