pa****@gmail.com writes:
I know that I must include math.h and use sin() and cos() functions,but
my main questions are
1) why in linux operating system there were not any trig function.I
used Red hat and Mandriva and debian but in all the header file was not
okay,I know that this is not relevant to OS
2) What should I write in that header file to work properly?
The C standard provides several trig functions, including sin() and
cos(), declared in <math.h>. Any conforming C implementation will
support these. I've never seen a Linux system that didn't have a
conforming C implementation (possibly with some minor bugs), assuming
that gcc is installed.
What *exactly* do you mean when you say "in linux operating system
there were not any trig function"? What happens when you try to use
them? What makes you think "the header file was not okay"?
The C FAQ is at <http://www.eskimo.com/~scs/C-faq/faq.html>. You
might take a look at question 14.3.
If that *is* the problem, you could have saved yourself and the rest
of us a lot of time by showing us exactly what you tried and exactly
what happened when you tried it.
--
Keith Thompson (The_Other_Keith)
ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>
We must do something. This is something. Therefore, we must do this.