Write a program that asks the user for an angle, entered in radians. The program should then display the sine, cosine, and tangent of the angle. (Use the sin, cos, and tan library functions to determine these values .) All numeric values in the output
Write a program that asks the user for an angle, entered in radians. The program should then display the sine, cosine, and tangent of the angle. (Use the sin, cos, and tan library functions to determine these values .) All numeric values in the output should be displayed in fixed-point notation, rounded to four decimal places of precision.
Here is one sample run:
Enter angle: 1.07078
sin(1.07078)=0.8776
cos(1.07078)=0.4794
tan(1.07078)=1.8304
I got this so far
#include <iostream>
#include <iomanip>
#include <cmath>
using namespace std;
int main ()
{
double radians;
cout << "Enter angle:";
cin >> radians;
cout << " sin(3.1415)=" <<
fixed << setprecision(4) << sin(radians) << endl;
cout << "cos(3.1415)="
<< fixed << setprecision(4) << cos(radians) << endl;
cout << "tan(3.1415)=" <<
fixed << setprecision(4) << tan(radians) << endl;
cin.ignore();
cin.get();
return 0;
}
12 years ago
5
Purchase the answer to view it

Purchase the answer to view it

- ALGEBRA PROJECT
- BUS644 Final The Case of Stickley Furniture
- Chapter 8 Quiz
- Ashford University - BUS 681 Compensation and Benefits - week 4 DBs plus assignment
- 200-300 Words Material Manager
- HRM 531 Week 1-6 entire GRADE A++ 100% 2#
- What are the indole test, methyl red test, voges-proskauer test and citrate test (IMViC) reactions
- CMC 260 Week 6 CheckPoint
- Performance Management Assignment ...
- Software Process Improvement - Software Process Improvement
