fzero help
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
y=@(T) I*T*sind(A)-(0.5*G*(T^2));
root = fzero(y, 0)
abouve eqation is for a projectile that projected at an angle (gose in a kind of ar half oval shape)
want to find the time it hist ground but fzero only gives me the biginning which is 0
23 comentarios
Matt Tearle
el 25 de Feb. de 2011
Can I suggest using an initial guess of 2*I*sind(A)/G? Just sayin'...
Matt Fig
el 25 de Feb. de 2011
Come on now, Matt! Where is the fun of solving the equation with your brain instead of making MATLAB do it?
Respuesta aceptada
Honglei Chen
el 17 de Sept. de 2012
The anwser is in the comments above
From Matt Fig
rt = 0;
d = .1;
cnt = 1;
while rt<.1
rt = fzero(y,rt+d*cnt);
cnt = cnt + 1;
end
2 comentarios
Matt Fig
el 17 de Sept. de 2012
Digging deep, Honglei! How did you come across this one from over a year ago?
Más respuestas (0)
Ver también
Categorías
Más información sobre Startup and Shutdown en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!