{"id":93,"date":"2020-06-29T10:41:09","date_gmt":"2020-06-29T10:41:09","guid":{"rendered":"\/?p=93"},"modified":"2020-06-29T10:44:01","modified_gmt":"2020-06-29T10:44:01","slug":"sine-series-sinxx-x3-3-x5-5","status":"publish","type":"post","link":"http:\/\/suryaprakash.com.np\/?p=93","title":{"rendered":"sine series (sin(x)=x &#8211; x^3\/3! +x^5\/5!&#8230;&#8230;..)"},"content":{"rendered":"<p>\/\/c program to find the value of sine series<br \/>\n#include&lt;stdio.h&gt;<br \/>\n#define pi 3.1416<br \/>\nvoid main()<br \/>\n{<br \/>\nint n,i;<br \/>\nfloat x, sum=0;<br \/>\nprintf(&#8220;enter the value of angle in degree\\n&#8221;);<br \/>\nscanf(&#8220;%f&#8221;,&amp;x);\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \/\/ x in degree<br \/>\nprintf(&#8220;enter the value of n:&#8221;);<br \/>\nscanf(&#8220;%d&#8221;,&amp;n);<br \/>\nx= pi*x\/180;\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \/\/ x in radian<br \/>\nfloat t1=x;<br \/>\nfor(i=1;i&lt;=n;i++)<br \/>\n{<br \/>\nsum+=t1;<br \/>\nt1= t1*(-x*x)\/((i+1)*(i+2));\u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0 \u00a0\/\/sin(x)=x &#8211; x^3\/3! +x^5\/5!&#8230;&#8230;..<br \/>\n}<br \/>\nprintf(&#8220;Sin(x)=%f&#8221;,sum);<br \/>\n}<\/p>\n<p><strong>OUTPUT<\/strong><\/p>\n<p><img loading=\"lazy\" class=\"alignnone size-medium wp-image-94\" src=\"\/wp-content\/uploads\/2020\/06\/sinnseries-300x173.png\" alt=\"\" width=\"300\" height=\"173\" srcset=\"\/wp-content\/uploads\/2020\/06\/sinnseries-300x173.png 300w, \/wp-content\/uploads\/2020\/06\/sinnseries.png 485w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p>Greater the value of n Greater will be accuracy in result.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\/\/c program to find the value of sine series #include&lt;stdio.h&gt; #define pi 3.1416 void main() { int n,i; float x, &hellip; <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[7,6],"tags":[],"_links":{"self":[{"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=\/wp\/v2\/posts\/93"}],"collection":[{"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=93"}],"version-history":[{"count":2,"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=\/wp\/v2\/posts\/93\/revisions"}],"predecessor-version":[{"id":97,"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=\/wp\/v2\/posts\/93\/revisions\/97"}],"wp:attachment":[{"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=93"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=93"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/suryaprakash.com.np\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=93"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}