To plot:
The polynomial
Answer to Problem 1P
Solution:
The plot of the given polynomial
Explanation of Solution
The given polynomial function is,
The
Substitute the value of
Substitute the value of
Hence, the value of
Write the MATLAB script to plot the polynomial
MATLAB Code:
%MATLAB program to plot the polynomial function
x = -6:0.1:6;%Define a vector x.
y = [0.1 -0.2 -1 5 -41.5 235];
r = polyval(y,x);%polyval function is used to calculate y
plot(x,r)
xlabel('x')
ylabel('y')
Save the MATLAB script with the name, Chapter8_29864_8_1P.m in the current folder. Execute the script by typing the script name at the command window to get the plot of the polynomial
Result:
Conclusion:
Therefore, the plot of the given polynomial
Want to see more full solutions like this?
Chapter 8 Solutions
EBK MATLAB: AN INTRODUCTION WITH APPLIC
- Introductory Circuit Analysis (13th Edition)Electrical EngineeringISBN:9780133923605Author:Robert L. BoylestadPublisher:PEARSONDelmar's Standard Textbook Of ElectricityElectrical EngineeringISBN:9781337900348Author:Stephen L. HermanPublisher:Cengage LearningProgrammable Logic ControllersElectrical EngineeringISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
- Fundamentals of Electric CircuitsElectrical EngineeringISBN:9780078028229Author:Charles K Alexander, Matthew SadikuPublisher:McGraw-Hill EducationElectric Circuits. (11th Edition)Electrical EngineeringISBN:9780134746968Author:James W. Nilsson, Susan RiedelPublisher:PEARSONEngineering ElectromagneticsElectrical EngineeringISBN:9780078028151Author:Hayt, William H. (william Hart), Jr, BUCK, John A.Publisher:Mcgraw-hill Education,