필터 지우기
필터 지우기

Vectors as a function

조회 수: 2 (최근 30일)
Soham Patil
Soham Patil 2021년 11월 24일
답변: Dyuman Joshi 2021년 11월 25일
I am trying to solve the total derivative of f with respect to t so my idea is to take gradient of f and takes it dot product of the derivative of r with respect to t. I am trying to find the value of t at which r is sol so that i find the total derivative of f at sol but i am unable to get the value of t using
solve(sol==r,t) and also whenever i want to use first index of r using r(1) and it is putting t=1 instead of using its first index . Please help with this Thank you!
syms x y z t r
x=@(t) cos(t);
y=@(t) log(t+2);
z=@(t) t;
r=@(t) [x(t) y(t) z(t)];
f=@(x,y,z) x^2*exp(2*y)*cos(3*z);
Dr=diff(r,t);
sol=[1 log(2) 0];
solve(eq(r,sol),t)
  댓글 수: 4
Dyuman Joshi
Dyuman Joshi 2021년 11월 25일
syms x y z t r
x=cos(t);
y=log(t+2);
z=t;
r=[x y z];
sol=[1 log(2) 0];
arrayfun(@(k) solve(eq(r(k),sol(k)),t), 1:numel(r))
ans = 
Soham Patil
Soham Patil 2021년 11월 25일
Thanks i think log(2) can be fixed with log(sym(2))

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

채택된 답변

Dyuman Joshi
Dyuman Joshi 2021년 11월 25일
syms x y z t r
x=cos(t);
y=log(t+2);
z=t;
r=[x y z];
sol=[1 log(sym(2)) 0];
arrayfun(@(k) solve(eq(r(k),sol(k)),t), 1:numel(r))
ans = 

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by