1 / 7

Math.h

Math.h. 數學程式庫. 三角函數. double cos(double); double sin(double); double tan(double); double acos(double);  [0, pi] double asin(double);  [-pi/2, pi/2] double atan(double);  [-pi/2, pi/2] double atan2(double x, double y);  [-pi, pi] 利用 x, y 的正負號 , 區分角度的象限 . 指數和對數.

walker
Download Presentation

Math.h

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Math.h 數學程式庫

  2. 三角函數 • double cos(double); • double sin(double); • double tan(double); • double acos(double); [0, pi] • double asin(double);  [-pi/2, pi/2] • double atan(double);  [-pi/2, pi/2] • double atan2(double x, double y); [-pi, pi] 利用 x, y 的正負號, 區分角度的象限.

  3. 指數和對數 • double exp(double); • double log(double); // ln(x) • double log10(double); • y = double frexp(double x, int*n); // x = 2^n * y • y = ldexp(double x, int n); // y = x * 2^n

  4. power • double pow(double x, double y); // x^y • double sqrt(double x); // square root of x

  5. Hyperbolic functions • double sinh(double x); // hyperbolic sine • double cosh(double x); // hyperbolic cosine • double tanh(double x); // hyperbolic tangent

  6. Ceil and floor • double ceil(double x); // 比 x 大的最小整數, 以 double 數態 傳回. • double floor(double x); // 比 x 小的最大整數, 以 double 數態 傳回.

  7. Module and fabs • double fabs(double x); // x 絕對值 • double fmod(x, y); // x / y 得到整數後的餘數, 絕對值大 於等於零, 小於 y; 符號和 x 相同. • double modf(double x, double *nx); // 傳回 x 的小數部分, 整數部分放在 nx.

More Related