Matlab Question, Mechanical Engineering

Assignment Help:
help write the matlab code desired:
The sine function can be evaluated by the following infinite series as (where the angle x is given in
radians):
xsinx = x-(x^3)/3! + (x^5)/5! - (x^7)/7!....
(a) Create a function M-file mysin1 that takes the angle x (in degrees) and the number of terms n as
the input, and returns sin(x) as the output using n number of terms in the above expansion. Test
your function with x=1.53, and n=10.
(b)Create a second function M-file mysin2 that takes the angle x (in radians) and the significant
digits sigdig as the input, and returns sin(x) correct to sigdig significant digits as the output.  Test
your function to find sine of 2.24 correct to 14 significant digits.

Related Discussions:- Matlab Question

Chassis lubrication system, Chassis Lubrication System : This lubrication ...

Chassis Lubrication System : This lubrication system consists of outer body parts, which are lubricated from outside of the body. Table of Lubrication Points Sl.

Material utilized for composites, Material Utilized For Composites Comp...

Material Utilized For Composites Composite presents a very broad range. From usual reinforced concrete to metal- metal fibre composites of high strength are in employ. The stre

Determine the rankine efficiency, A simple Rankine cycle works between pres...

A simple Rankine cycle works between pressures 0.06 bar and 28 bar, the initial condition of steam being dry saturated. Determine the cycle efficiency, specific steam consumption a

Differences between direct stress and bending stress, Give differences betw...

Give differences between direct stress and bending stress. Direct tensile and compressive stress is set up because of load applied parallel to length of object, and direct shea

Resultant of non coplanar concurrent force system, Resultant of Non coplana...

Resultant of Non coplanar concurrent force system: How do you find resultant of Non coplanar concurrent force system? Sol.: The resultant of non concurrent force system

Simulate the compression test, This assignment will simulate large deformat...

This assignment will simulate large deformations (nonlinear geometry) and occurrence of necking and buckling due to static tensile and compressive loading of a given elastic-plasti

Temperature scales - thermodynamics, Temperatur e Scales: The tempera...

Temperatur e Scales: The temperature of a system can be determined by bringing a 2 nd body, a thermometer, into contact with the system and allowing thermal equilibrium to b

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd