News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

help degree to sin, cos, tan?

Started by paragasu, September 13, 2006, 08:39:05 AM

Previous topic - Next topic

paragasu

anyone can can help me? i got an assigment to make a program in asm. the program will ask the user input in degree
and then display the value in sin, cos, tan. I really don't have idea how to make it work.
i know, first  i have to convert the value into radian,..
and using FPU instruction like FSINCOS, FPTAN, FCOS..
i don't have any idea how it works. can somebody help me?

sw337

hi paragasu !

radians = degrees*PI / 180.0

Did that help ?

Tedd

Look up the following instructions.. :wink
- finit
- fild/fld
- fistp/fstp
- fmul/fdiv
- fsin/fcos/fptan

And of course, you'll need to figure out how to get the user's input.
No snowflake in an avalanche feels responsible.

raymond

When you assume something, you risk being wrong half the time
http://www.ray.masmcode.com