I want to compute the integral of normDf between a and b. What am I doing wrong?
This is my code
syms t
assume(t, "real")
f1 = 3*t-t*t*t;
f2 = 3*t*t;
f = [f1, f2]
f = 
df = diff(f, t)
df = 
a = 0;
b = 1;
normDf = sqrt(df(1)*df(1)+df(2)*df(2))
normDf = 
int(normDf, t, a, b)
ans = 

 Respuesta aceptada

Paul
Paul el 4 de Mzo. de 2022
Simplify normDf before applying int(). Don't know why int() doesn't do this on its own
syms t
assume(t, "real")
f1 = 3*t-t*t*t;
f2 = 3*t*t;
f = [f1, f2];
df = diff(f, t);
a = 0;
b = 1;
normDf = sqrt(df(1)*df(1)+df(2)*df(2))
normDf = 
normDf = simplify(normDf)
normDf = 
int(normDf, t, a, b)
ans = 
4

Más respuestas (1)

David Hill
David Hill el 4 de Mzo. de 2022

0 votos

use vpaintegral
syms t
assume(t, "real")
f1 = 3*t-t*t*t;
f2 = 3*t*t;
f = [f1, f2];
df = diff(f, t);
a = 0;
b = 1;
normDf = sqrt(df(1)*df(1)+df(2)*df(2));
vpaintegral(3*(4*t^2 + (3*t^2 - 3)^2/9)^(1/2), t, a, b)

Categorías

Más información sobre Symbolic Math Toolbox en Centro de ayuda y File Exchange.

Productos

Versión

R2021a

Preguntada:

el 4 de Mzo. de 2022

Respondida:

el 4 de Mzo. de 2022

Community Treasure Hunt

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

Start Hunting!

Translated by