Matlab: Convert [2x1 sym] to a numerical value
Mostrar comentarios más antiguos
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]
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Symbolic Math Toolbox en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!