필터 지우기
필터 지우기

How to find the derivative of one output quantity with respect to another output quantity

조회 수: 2 (최근 30일)
I want to consult that how to find the derivative of one output quantity with respect to another output quantity. For example, output module 1 is force and output module 2 is time, and I want to find the derivative of module 1 with respect to module 2. Thank you for your help.

답변 (2개)

Chunru
Chunru 2022년 7월 8일
x = 0:32;
y = sin(2*pi*x/16);
d = gradient(y)./gradient(x);
plot(x, y, 'r-', x, d, 'b-')

John D'Errico
John D'Errico 2022년 7월 8일
Basic calculus. Each module must be a function of SOMETHING else, thu some other parameter. What parameter is controlling them? For example, suppose I have two modules.
Use this basic rule for differentiation:
dx/dy = (dx/dt)/(dy/dt)
Now lets try it. I'll make up some arbitrary relations to put in the two modules.
module1 = @(p) sin(p);
module2 = @(p) cos(p);
Suppose I want to compute the derivative of module1, with respect to module 2, at the point where p=1.
dp = 1e-8;
p0 = 1;
dm1dm2 = ((module1(p0 + dp) - module1(p0))/dp) / ((module2(p0 + dp) - module2(p0))/dp)
dm1dm2 = -0.6421

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by