Solving non-linear equation in vector form
Afficher commentaires plus anciens
Hi all, hope you are doing well.
Soi have a simple equation where the known value is a vector. So i need to get a vector as the solution.
The equation is very simple and can be easily caluclated by hand but i require it to be solved using Matlab.
Here is the code i have tried:
u2 = rand(1,1000);
syms t1
eq = t1.^2/64 == u2;
solve(eq, t1)
Any help would be appreciated, thanks.
Réponse acceptée
Plus de réponses (2)
syms u t
fun=matlabFunction( solve(t^2/64==u,t) );
u2=[1,4,9];
t1=fun(u2)
1 commentaire
Tayyab Khalil
le 28 Avr 2021
Matt J
le 28 Avr 2021
u2 = rand(1,1000);
t1=8*sqrt(u2);
3 commentaires
Tayyab Khalil
le 28 Avr 2021
Matt J
le 28 Avr 2021
All the commands in my solution are Matlab commands...
Tayyab Khalil
le 28 Avr 2021
Catégories
En savoir plus sur Symbolic Math Toolbox dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!