[Sin]
Trong ngôn ngữ lập trình C, hàm sin trả về sin của x
cú pháp
Cú pháp của hàm sin trong ngôn ngữ C là
double sin[double x];
Tham số hoặc Đối số
Giá trị xA được biểu thị bằng radian [không phải độ]lợi nhuận
Hàm sin trả về sin của x, được đo bằng radian
Tiêu đề bắt buộc
Trong Ngôn ngữ C, tiêu đề bắt buộc cho hàm tội lỗi là
________một_______Áp dụng đối với
Trong Ngôn ngữ C, chức năng tội lỗi có thể được sử dụng trong các phiên bản sau
- ANSI/ISO 9899-1990
không có ví dụ
/* Example using sin by TechOnTheNet.com */ #include #include int main[int argc, const char * argv[]] { /* Define temporary variables */ double value; double result; /* Assign the value we will find the sin of */ value = 0.5; /* Calculate the Sine of value */ result = sin[value]; /* Display the result of the calculation */ printf["The Sine of %f is %f\n", value, result]; return 0; }
Khi được biên dịch và chạy, ứng dụng này sẽ xuất ra
The Sine of 0.500000 is 0.479426
Chức năng tương tự
Các hàm C khác tương tự như hàm sin
- acos function
- asin function
- hàm atan < toán học. h>
- atan2 function
- hàm cos < phép toán. h>
- tan function
Hàm tan[] trả về tỷ lệ tiếp tuyến của góc đã cho theo đơn vị radian. Trong lượng giác, tang của một góc được định nghĩa là tỉ số giữa độ dài cạnh đối và cạnh kề
tan[x] = đối diện/liền kề
tang của một góc cũng được định nghĩa là tỷ số của sin và cosin của nó
tan[x] = sin[x]/cos[x]
Nếu x=45 độ, tan[x] = 1 như trong tam giác vuông thì các cạnh đối và kề bằng nhau
Hàm này trả về một giá trị float
cú pháp
tan [ float $arg ] : float
thông số
Ông. NoParameter & Description1argMột giá trị dấu phẩy động đại diện cho góc tính bằng radian
Giá trị trả về
Hàm tan[] trong PHP trả về tỷ lệ tiếp tuyến của tham số đã cho
Phiên bản PHP
Chức năng này có sẵn trong phiên bản PHP 4. x, PHP5. x cũng như PHP 7. x
Thí dụ
bản thử trực tiếp
Ví dụ sau tính tan[pi/2] và trả về 1. 6331239353195E+16 [số rất lớn]. tỷ lệ tiếp tuyến của 90 độ là vô cực -
đầu ra
Điều này sẽ tạo ra kết quả sau -
tan[1.5707963267949] = 1.6331239353195E+16
Thí dụ
bản thử trực tiếp
Ví dụ sau sử dụng hàm deg2rad[] để chuyển đổi độ sang radian và sau đó tính toán tan[60]. kết quả là 1. 7320508075689 là sqrt[3] −
Hàm lượng giác trong PHP Cập nhật lần cuối — ngày 20 tháng 5 năm 2022Tác giả — Nitish Kumar
Hàm lượng giác trong PHP Tên hàm Mô tả hàm SineCosineTangentArc sineArc cosineArc tangentArc tangent của hai biếnSine hyperbol nghịch đảoCosine hyperbol ngược Tang hyperbol ngượcChuyển đổi số theo độ thành tương đương radianChuyển đổi số radian thành số tương đương theo độTrên Trang nàyHàm PHP
9
PHP
9 Cách sử dụng
Hàm PHP ________6_______9
sẽ cung cấp cho bạn sin của tham số
cos [ float $arg ] : float
2. Tham số cos [ float $arg ] : float
2 tính bằng radianCú pháp PHP
9
sin [ float $arg ] : float
PHP
_9 Tham số
2 — Một giá trị tính bằng radiancos [ float $arg ] : float
PHP
_9 Giá trị trả về
Hàm PHP
9 trả về sin của cos [ float $arg ] : float
2PHP
9 Ví dụ hoạt động
1. sin[] ví dụ
Hàm PHP
1
PHP
1 Cách sử dụng
Hàm PHP ________20_______1
sẽ cung cấp cho bạn cosine của tham số
cos [ float $arg ] : float
2. Tham số cos [ float $arg ] : float
2 tính bằng radianCú pháp PHP
1
cos [ float $arg ] : float
PHP
1 Tham số
2 — Góc tính bằng radiancos [ float $arg ] : float
PHP
1 Giá trị trả về
Hàm PHP
1 trả về cosin của cos [ float $arg ] : float
2PHP
1 Ví dụ hoạt động
1. ví dụ cos[]
________hai mươi_______Hàm PHP tan [ float $arg ] : float
3
tan [ float $arg ] : float
PHP tan [ float $arg ] : float
3 Cách sử dụng
tan [ float $arg ] : float
Hàm PHP ________34_______3
sẽ cung cấp cho bạn tiếp tuyến của tham số
cos [ float $arg ] : float
2. Tham số cos [ float $arg ] : float
2 tính bằng radianCú pháp PHP tan [ float $arg ] : float
3
________3.4_______ tan [ float $arg ] : float
PHP tan [ float $arg ] : float
3 Tham số
tan [ float $arg ] : float
2 — Đối số để xử lý theo đơn vị radiancos [ float $arg ] : float
PHP tan [ float $arg ] : float
3 Giá trị trả về
tan [ float $arg ] : float
Hàm PHP
tan [ float $arg ] : float
3 trả về tang của cos [ float $arg ] : float
2PHP tan [ float $arg ] : float
3 Ví dụ làm việc
tan [ float $arg ] : float
1. tan[] ví dụ
Hàm PHP
5
PHP
5 Cách sử dụng
Hàm PHP ________47_______5
sẽ cung cấp cho bạn cung sin của
cos [ float $arg ] : float
2 theo đơn vị radian.
5 là hàm nghịch đảo của
9, có nghĩa là a==sin[asin[a]] với mọi giá trị của a nằm trong phạm vi của
5Cú pháp PHP
5
asin [ float $arg ] : float
Tham số PHP
5
2 — Đối số để xử lýcos [ float $arg ] : float
PHP
5 Giá trị trả về
Hàm PHP
5 trả về cung sin của cos [ float $arg ] : float
2 theo đơn vị radianHàm PHP asin [ float $arg ] : float
8
asin [ float $arg ] : float
PHP asin [ float $arg ] : float
8 Cách sử dụng
asin [ float $arg ] : float
Hàm PHP ________56_______8
sẽ cung cấp cho bạn cung cosin của
cos [ float $arg ] : float
2 theo đơn vị radian. asin [ float $arg ] : float
8 là hàm nghịch đảo của
1, có nghĩa là a==cos[acos[a]] với mọi giá trị của a nằm trong phạm vi của asin [ float $arg ] : float
8Cú pháp PHP asin [ float $arg ] : float
8
asin [ float $arg ] : float
acos [ float $arg ] : float
Các tham số PHP asin [ float $arg ] : float
8
asin [ float $arg ] : float
2 — Đối số để xử lýcos [ float $arg ] : float
PHP asin [ float $arg ] : float
8 Giá trị trả về
asin [ float $arg ] : float
Hàm PHP
asin [ float $arg ] : float
8 trả về cung cosin của cos [ float $arg ] : float
2 theo đơn vị radianHàm PHP atan [ float $arg ] : float
1
atan [ float $arg ] : float
PHP atan [ float $arg ] : float
1 Cách sử dụng
atan [ float $arg ] : float
Hàm PHP ________76_______1
sẽ cung cấp cho bạn cung tiếp tuyến của
cos [ float $arg ] : float
2 theo đơn vị radian. atan [ float $arg ] : float
_1 là hàm nghịch đảo của tan [ float $arg ] : float
3, có nghĩa là a==tan[atan[a]] với mọi giá trị của a nằm trong phạm vi của atan [ float $arg ] : float
1Cú pháp PHP atan [ float $arg ] : float
1
atan [ float $arg ] : float
atan [ float $arg ] : float
Tham số PHP atan [ float $arg ] : float
1
atan [ float $arg ] : float
2 — Đối số để xử lýcos [ float $arg ] : float
PHP atan [ float $arg ] : float
1 Giá trị trả về
atan [ float $arg ] : float
Hàm PHP
atan [ float $arg ] : float
1 trả về cung tiếp tuyến của cos [ float $arg ] : float
2 theo đơn vị radianMẹo bổ sung từ các nhà phát triển đồng nghiệp
đóng góp bởi. vô danh
Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
Hàm PHP Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
4
Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
PHP Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
4 Cách sử dụng
Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
Hàm PHP ________90_______4
sẽ tính toán cung tiếp tuyến của hai biến
Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
7 và Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
8. Nó tương tự như tính toán tang cung của Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
8 / Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
7, ngoại trừ dấu của cả hai đối số được sử dụng để xác định góc phần tư của kết quảCú pháp PHP Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
4
Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
0PHP Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
4 Tham số
Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
8 — Tham số cổ tứcContrary to the current description, it should hold y == tan[atan[y]] for ALL y. However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2. Of course, those equalities are limited by precision. On my machine tan[atan[1000]] returns 1000.0000000001. atan[tan[0]] returns 0 [correct]. atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
7 — Tham số chiaContrary to the current description, it should hold y == tan[atan[y]] for ALL y. However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2. Of course, those equalities are limited by precision. On my machine tan[atan[1000]] returns 1000.0000000001. atan[tan[0]] returns 0 [correct]. atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
PHP Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
4 Giá trị trả về
Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
Hàm PHP
Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
4 trả về cung tiếp tuyến của Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
8/Contrary to the current description, it should hold y == tan[atan[y]] for ALL y.
However, x == atan[tan[x]] only holds for those x which are in the range of atan, which are those x with -pi/2 < x < pi/2.
Of course, those equalities are limited by precision. On my machine
tan[atan[1000]] returns 1000.0000000001.
atan[tan[0]] returns 0 [correct].
atan[tan[M_PI]] returns -1.2246467991474E-16 instead of 0.
7 theo đơn vị radianMẹo bổ sung từ các nhà phát triển đồng nghiệp
đóng góp bởi. sự phản bội
1Hàm PHP
09
PHP
09 Cách sử dụng
Hàm PHP ________6_______09
sẽ cung cấp cho bạn sin hyperbol nghịch đảo của
cos [ float $arg ] : float
2, i. e. giá trị có sin hyperbol là cos [ float $arg ] : float
2Cú pháp PHP
09
2PHP
09 Tham số
2 — Đối số để xử lýcos [ float $arg ] : float
PHP
09 Giá trị trả về
Hàm PHP
09 trả về sin hyperbol nghịch đảo của cos [ float $arg ] : float
2Nhật ký thay đổi cho Hàm asinh[] trong PHP
5. 3. 0 — Chức năng này hiện khả dụng trên tất cả các nền tảng
Hàm PHP
20
PHP
20 Cách sử dụng
Hàm PHP ________6_______20
sẽ cung cấp cho bạn cosin hyperbol nghịch đảo của
cos [ float $arg ] : float
2, i. e. giá trị có cosin hyperbol là cos [ float $arg ] : float
2Cú pháp PHP
20
3PHP
20 Tham số
2 — Giá trị để xử lýcos [ float $arg ] : float
PHP
20 Giá trị trả về
Hàm PHP
20 trả về cosin hyperbol nghịch đảo của cos [ float $arg ] : float
2Nhật ký thay đổi cho hàm PHP acosh[]
5. 3. 0 — Chức năng này hiện khả dụng trên tất cả các nền tảng
Hàm PHP
31
PHP
31 Cách sử dụng
Hàm PHP ________6_______31
sẽ cung cấp cho bạn tang hyperbol nghịch đảo của
cos [ float $arg ] : float
2, i. e. giá trị có tiếp tuyến hyperbol là cos [ float $arg ] : float
2Cú pháp PHP
31
4PHP
31 Tham số
2 — Đối số để xử lýcos [ float $arg ] : float
PHP
31 Giá trị trả về
Hàm PHP
31 trả về tang hyperbol nghịch đảo của cos [ float $arg ] : float
2Nhật ký thay đổi cho hàm PHP atanh[]
5. 3. 0 — Chức năng này hiện khả dụng trên tất cả các nền tảng
Hàm PHP
42
PHP
42 Cách sử dụng
Hàm PHP ________6_______42
sẽ chuyển đổi số theo độ thành radian tương đương
Cú pháp PHP
42
5PHP
42 Tham số
47 — Giá trị góc theo độ
PHP
42 Giá trị trả về
Hàm PHP
42 trả về radian tương đương với
47PHP
42 Ví dụ làm việc
1. ví dụ deg2rad[]
6Hàm PHP
52
PHP
52 Cách sử dụng
Hàm PHP ________6_______52
sẽ chuyển đổi số radian thành số tương đương theo độ
Cú pháp PHP
52
7PHP
52 Tham số
47 — Giá trị radian
PHP
52 Giá trị trả về
Hàm PHP
52 trả về giá trị tương đương của
47 theo độPHP
52 Ví dụ làm việc
1. ví dụ rad2deg[]
8Chia sẻ với bạn bè
Đánh giá bài viết này -
thẻ. môn Toán. PHP
Đặt mua
thông báo về
nhãn
{} [+]
Mứt*E-mail*trang mạng
nhãn
{} [+]
Mứt*E-mail*trang mạng
0 Nhận xét
Phản hồi nội tuyến
Xem tất cả bình luận