Having trouble getting the plot
정보
이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.
이전 댓글 표시
so I am having trouble getting this to display. I will be changing the value of big N to different values but I can't even get this to display properly. Im not sure what I am doing wrong here can anybody help
N = 1;
n = 0:1:150;
amplitude = (N.^n)*exp(-N)/(factorial(n))
plot(n,amplitude);
댓글 수: 0
답변 (1개)
Azzi Abdelmalek
2013년 2월 5일
편집: Azzi Abdelmalek
2013년 2월 5일
factorial(n) is an array then you have to use ./ instead of /
amplitude = (N.^n)*exp(-N)./(factorial(n))
댓글 수: 0
이 질문은 마감되었습니다.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!