Question: % Problem 3 clc clear format long g cos _ 3 3 = zeros ( 1 , 5 ) ; cos _ 1 6 0
Problem
clc
clear
format long g
cos zeros;
cos zeros;
xpi; is this correct?
xpi;
nvalues ;
for i :lengthnvalues
n nvaluesi;
cosval ;
cosval;
for v ::n Start from increment by for cosine series
z xvfactorialv;
zxvfactorialv;
if remv Alter sign based on the power of v
cosval cosval z;
cosval cosval z;
else
cosval cosval z;
cosval cosval z;
end
end
cosi cosval;
cosi cosval;
end
fprintfTaylor series expansion of cos degrees:
;
dispcos;
fprintf
Taylor series expansion of cos degrees:
;
dispcos; is this corrct?
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
