Message-Id: <199812171034.FAA02881@delorie.com> From: "Robert Darmochwal" To: Subject: Re: sin() and cos() ??? Date: Thu, 17 Dec 1998 11:13:50 +0100 X-MSMail-Priority: Normal X-Priority: 3 X-Mailer: Microsoft Internet Mail 4.70.1155 MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Reply-To: djgpp AT delorie DOT com off course you know that but... make it like this: float sin_d(float x){ return sin(x*3.1415926/180); } and similiar cos_d function... ---------- > From: Kertis Henderson > To: djgpp AT delorie DOT com > Subject: Re: sin() and cos() ??? > Date: Thursday, December 17, 1998 8:39 AM > > Mike Purtell wrote: > > > > What am I missing ? > > > > I call ... > > > > #include > > #include > > ... > > printf("The SIN of 45 Deg is %.2f\n",sin(45) ); > > and get .851 ?? > > and then > > printf("The COS of 45 Deg is %.2f\n",cos(45) ); > > and get .525 ???? > > ... > > I would expect .707 for both ! > > The sine of 45 radians is .851, and the cosine of 45 radians is .525. > These functions don't take degrees as arguments. > > -- > > Kertis Henderson > kertis AT frozenwave DOT com