Answer to Question #288360 in Java | JSP | JSF for mengal

Question #288360


Program the following in Java language.


Implement the following equation


3x4sin(180x) + 4x3 cos(90x) + x2sin(tan(45)) + 7x + 9cos(90x2 )


where x may be user defined value.


1
Expert's answer
2022-01-18T02:07:10-0500
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        double x = Math.toRadians(new Scanner(System.in).nextDouble());
        System.out.println(3 * x * 4 * Math.sin(180 * x)
                + 4 * x * 3 * Math.cos(90 * x)
                + x * 2 * Math.sin(Math.tan(Math.toRadians(45)))
                + 7 * x
                + 9 * Math.cos(90 * x * 2));
    }
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog