Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Consider the following quadratic equation. x 2 + 8x + 15 = 0 where a = 1, b = 8 and c = 15 Write

Consider the following quadratic equation.

x 2 + 8x + 15 = 0 where a = 1, b = 8 and c = 15

Write a MATLAB script file program using the basic commands(+/- * / ^) we discussed on Friday. In this program the first few lines of your code should include the statements below:

clear;clc

a = 1;

b = 8;

c = 15;

By defining your input variables above there is no need to type in numbers to perform your calculations

Use root1 and root2 as the variable names for each root. Also note that placing a semicolon after each line will prevent your command window from being cluttered with calculations. The end of your program should include the following lines

results = [root1 root2];

disp('The roots are displayed below')

disp(results)

The disp commands will display your results.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Understanding Oracle APEX 5 Application Development

Authors: Edward Sciore

2nd Edition

1484209893, 9781484209899

More Books

Students also viewed these Databases questions

Question

Find the derivative of y= cos cos (x + 2x)

Answered: 1 week ago

Question

(4) What do you do that creates obstacles in their way?

Answered: 1 week ago

Question

What do they need to do differently?

Answered: 1 week ago

Question

What do they do well?

Answered: 1 week ago