Differentiation of an Integral Function

Hello,
I have this problem at hand to solve but it's taking longer than I envisaged to solve.
Let A be a function with respect to x,y,z i.e A(x,y,z)
B is the integration of A(x,y,z) w.r.t to time t from t_0 to t_f.
I need to solve dz/dt = B( x(t),y,z(t)).
A(x,y,z), where A can be anything, if possible a constant but a function of x,y,z.
x is a function of time, i.e x(t)
z also is a function of time i.e z(t)
Let just say B = integral(@(t) A,t_0,t_f)
Then I need to solve dz/dt = B(x,y,z);
I have tried both numerical means to solve this but what I am getting is not making sense.
Please advise what I can do.

8 comentarios

Walter Roberson
Walter Roberson el 11 de Jul. de 2018
Do you mean A is A(x(t), y(t), z(t)) and B = int(A(x(t), y(t), z(t)), t, t_0, t_f) ?
Is the question how to find the function A(x(t), y(t), z(t)) such that dz(t)/dt = int(A(x(t), y(t), z(t)), t, t_0, t_f) ? If so, then for arbitrary x(t), y(t), z(t) ?
Hi Walter, Yes, that is my question. I wrote a numerical code for it but I don't think it's correct.
if true
m=1;
t_0=0;
t_final=1;
NT=100;
delta_t = (t_final-t_0)/NT;
f(1)=20; % the fist value of f(m)
F(1)=0; % The initial value of f at t=0
disp([' delta_t',' f(1)',' F(1)'])
disp([delta_t,f(1),F(1)]);
while m<=NT
f(m+1)=F(m)+f(m);
F(m+1)=F(m)+f(m+1)*delta_t
m=m+1;
end
t_m=t_0:delta_t:t_final;
plot(t_m,f)
end
I also saw something on functional derivative, but I don't know if it can be applied here. Not sure how to even apply to the problem at hand.
Walter Roberson
Walter Roberson el 12 de Jul. de 2018
I do not see any x(t), y(t) or z(t) there?
There is not going to be a closed form solution for arbitrary x(t), y(t), z(t) . Perhaps there are some solutions for particular x(t), y(t), z(t)
Shozeal
Shozeal el 12 de Jul. de 2018
Yes, there are some solutions for particular x(t), y(t), z(t) at each particular point in time. The differential of z (dz/dt) is to be determined w.r.t to the integral of A( x(t),y(t),z(t) ) at this particular time.
If possible, can we just pick a particular solution for x(t),y(t),z(t) at this particular time in order to solve the equation?
What I wrote up there is a general way to see if something can be done numerically.
If we look at
dz(t)/dt = int(A(x(t), y(t), z(t)), t, t_0, t_f)
then the right hand side is going to be constant relative to t, because of the definite integral that substitutes t_0 and t_f for t.
But the left hand side, dz(t)/dt would generally be dependent on t, except in the case where dz(t)/dt is a constant, in which case z(t) would have to be constant1*t+constant2 in form.
So the situation is not possible unless z(t) is of that form.
Shozeal
Shozeal el 12 de Jul. de 2018
"_So the situation is not possible unless z(t) is of that form._" With this, I can differentiate z(t) w.r.t time t. But since the right hand side is a constant, won't that give an error?
syms x(t) y(t) z(t) C1 C2
z(t) = C1 * t + C2;
lhs = diff(z(t),t); %would be C1
syms A(X, Y, Z) t_0 t_f
rhs = int(A(x(t), y(t), z(t)), t, t_0, t_f);
eqn = lhs == rhs
No error (but also not much you can do with this.)
Note that for this purpose, C1 and C2 might be related to additional variables other than t: they just have to be independent of t, not of any other variable.
Shozeal
Shozeal el 12 de Jul. de 2018
Thank you, Walter.
Let me see how I can develop this to make it compatible with what I am working on.

Iniciar sesión para comentar.

Respuestas (0)

Productos

Versión

R2017a

Preguntada:

el 11 de Jul. de 2018

Comentada:

el 12 de Jul. de 2018

Community Treasure Hunt

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

Start Hunting!

Translated by