Equation with time dependent variable

Hi, I need to solve this equation y(x)=2*exp(-x)/(p*n)
In which p is a range of values already given and n is a constant that I have already defined, and x = time. How can I define x to be time to solve this equation? y is said to be a function of p and n

답변 (1개)

bio lim
bio lim 2016년 12월 3일

0 개 추천

p = -10:10; % range of values
n = 2; % constant
for j = 1:length(p) % We find y at each, p
for t = 1:10 % time loop
y(t,j)=2*exp(-t)/(p(j)*n)
end
end

카테고리

도움말 센터File Exchange에서 Programming에 대해 자세히 알아보기

질문:

2016년 12월 3일

답변:

2016년 12월 3일

Community Treasure Hunt

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

Start Hunting!

Translated by