Calculates the inverse cosine of a number #include <math.h> double
1. If x is outside the function's domainthat is, greater than 1 or less than -1the function incurs a domain error.xThe return value is given in radians, and is thus in the range 0 ## Example/* * Calculate the pitch of a roof given * the sloping width from eaves to ridge and * the horizontal width of the floor below it. */ #define PI 3.141593 #define DEG_PER_RAD (180.0/PI) double floor_width = 30.0; double roof_width = 34.6; double roof_pitch = This code produces the following output: The pitch of the roof is 30 degrees. ## See AlsoThe arc cosine functions for complex numbers: |