Symbolic Differentiation wrt time

I have such an expression;
(x(t) + y(t))^2
Where x and y are function of t How can I symbolically take the derivative of this expression with respect to t
Which has to result in 2[xx' + xy' + yx' + yy']

답변 (1개)

Wayne King
Wayne King 2013년 12월 22일

4 개 추천

syms t x(t) y(t)
diff((x(t)+y(t))^2)
The above gives the output:
2*(x(t) + y(t))*(diff(x(t), t) + diff(y(t), t))
which is equivalent to what you have in your post.

댓글 수: 2

Mohammad
Mohammad 2014년 4월 1일
hi, what about when we want to have upper degree derivatives of the same expression?
Walter Roberson
Walter Roberson 2014년 4월 1일
diff((x(t)+y(t))^2,t,3) %third derivative

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

카테고리

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

질문:

2013년 12월 22일

댓글:

2014년 4월 1일

Community Treasure Hunt

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

Start Hunting!

Translated by