Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write the program in Java, Use JUnit for testing. In Java there are Math libraries containing various trigonometric functions. You will be tasked to write
Write the program in Java, Use JUnit for testing.
In Java there are Math libraries containing various trigonometric functions. You will be tasked to write your own trigonometric library for Java. In doing so you will need to implement all the standard functions, SIN, COS, TAN. To calculate these functions consider the Taylor series expansions. You might find the following resource helpful: It should be noted that these series are based in radian measure. It would be nice that your library could also generate the function values from degrees. Thus your library will require the appropriate conversion as well to allow the user to chain together functions to produce the desired result. You are not allowed to use any java math library functions when developing your own. If you need a function, then you must create it. As part of your testing make sure that the functions are sound in all 4 quadrants. Will throw a custom exception for invalid usage. The class you will develop will be a static class. As part of this assignment, you will be required to code the trigonometric functions sin, cos, tan in both radian and degree, integrating the Junit testing as you go. That is, you will also develop a test class under Junit to test the framework of your class as you implement the constructors and methods. When you are finished you should be able to run the test and verify that all cases have been covered and that your class is sound. In Java there are Math libraries containing various trigonometric functions. You will be tasked to write your own trigonometric library for Java. In doing so you will need to implement all the standard functions, SIN, COS, TAN. To calculate these functions consider the Taylor series expansions. You might find the following resource helpful: It should be noted that these series are based in radian measure. It would be nice that your library could also generate the function values from degrees. Thus your library will require the appropriate conversion as well to allow the user to chain together functions to produce the desired result. You are not allowed to use any java math library functions when developing your own. If you need a function, then you must create it. As part of your testing make sure that the functions are sound in all 4 quadrants. Will throw a custom exception for invalid usage. The class you will develop will be a static class. As part of this assignment, you will be required to code the trigonometric functions sin, cos, tan in both radian and degree, integrating the Junit testing as you go. That is, you will also develop a test class under Junit to test the framework of your class as you implement the constructors and methods. When you are finished you should be able to run the test and verify that all cases have been covered and that your class is soundStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started