Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Problem: Rotate Point About The Origin (40 points+10) Write a program to compute the new coordinates of a 2D point rotated about the origin. Input
Problem: Rotate Point About The Origin (40 points+10) Write a program to compute the new coordinates of a 2D point rotated about the origin. Input Validation: None for numerical input (assume user will enter Bloating point or integral values). Rotation direction is indicated byfor counter-clockwise or for clockwise. Prompt the user to enter x-and y- co-ordinates. Prompt the user to enter angle or rotation in degrees . Prompt to use to enter direction of rotation. Calculate and display the new co-ordinates after rotation. . "bonus" Compute and display the quadrant before and after the rotation. HINT: Pay attention to the angle measurement units assumed by the Java triganometry functions Submit: RotatePoint.java Formulas and other info: .For point (x, y) rotated counter-clockwise about the origin by angle 8 the new co- ordinates (x', y') are given by for clockwise rotation, use the same formula but multiply 8 by (-1) . You should test your program against an online calculator such as this one. Sample Runs: with bonus: (15 points) Write a program that produces the output below java Diagonal Input Validation: . No user input, so none required. . The program uses only one Systen . The program uses
Step 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