Matlab: Convert [2x1 sym] to a numerical value
Afficher commentaires plus anciens
Below is my code and I wish to solve for A, B, C and D. How do i change the code to get numerical values for A, B, C and D? Instead of [2x1 sym].
syms A B C D
E = (89*50*sind(170))+(92.3*A*sind(C))+(83.3*B*sind(D))==0;
F = (89*50*cosd(170))+(92.3*A*cosd(C))+(83.3*B*cosd(D))==0;
G = (89*sind(170)) + (92.3*sind(C)) + (83.3*sind(D))==0;
H = 68.4 + (89*cosd(170)) + (92.3*cosd(C)) + (83.3*cosd(D))==0;
s = solve([E,F,G,H],[A,B,C,D])
When the code is run:
RV1_SDbalancing
s =
struct with fields:
A: [2×1 sym]
B: [2×1 sym]
C: [2×1 sym]
D: [2×1 sym]
Réponse acceptée
Plus de réponses (0)
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!