Question: In each part below you will write two different MATLAB functions, poly 1 and poly 2 , to compute the nth - degree polynomial, a

In each part below you will write two different MATLAB functions, poly1 and poly2, to compute the nth-degree
polynomial,
a0+a1x+a2x2+dots+anxn
Indicate each line you type below with the line number given in the comments.
a) The function poly1 below will take two inputs a row vector, a, containing the coefficients in the same order as above,
and a scalar real number, x, which is the value at which the polynomial is to be evaluated. (The function assumes n1).
The output, y, will be the polynomial evaluated at x. Use only the variables defined below to compute the sum, and no loops
The only built-in function you can use one needed to compute the sum. Fill in the blanks.
function y=poly1(a,x)
q,m= length (a)
In each part below you will write two different

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!