Previous Answers:
5.2.1 Solving Equations
For any constantsa,b,c, solve the equationa*x^2 + b*x + c = 0.
Matlab Programming Exercise 5.2.1: Solving the parameterized equation a*x^2 + b*x + c = 0
Program:
syms a b c x
eqn = a*x^2 + b*x + c == 0;
solx = solve(eqn)
Running Result:
solx =
-(b + (b^2 - 4*a*c)^(1/2))/(2*a)
-(b - (b^2 - 4*a*c)^(1/2))/(2*a)
———————Non-Decorative Divider————————5.2.2 Solving a System of Equations:x² + y² = 5,x + 2y = 4.
(The answer will be published in the next issue)
Recommended Popular Content from Previous Issues
Matlab Beginner Exercise 5.1.1: Steel Pipe Weight Function Modeling
Matlab Weekly Exercise 4.6.2: Plotting Date-Time Axis Graphs
Matlab Quick Exercise 4.3.1: Plotting Surface Graphs Based on Data
Matlab Weekly Practice 4.3.2: Plotting Surface Graphs Based on Function Expressions
Matlab Exercise 3.3.1: Writing Data to Specific Areas in Excel Files
Matlab Exercise 2.2: The Concept and Application of Matrix Indexing
End