Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

If you fire a projectile fast enough, the curve of the earth will match the spee

ID: 2247849 • Letter: I

Question

If you fire a projectile fast enough, the curve of the earth will match the speed at which the projective falls. The projectile will then orbit the earth. The speed, in meters/second, necessary to orbit the earth at an altitude h can be calculated by velocity = squareroot G Me/R + h where: G is the universal gravitation constant, 6.67408 times 10^-11 m^3/kg sec^2 (written 6.67408e-l1 in Java) Me is the mass of the earth, 5.972 times 10^24 Kg R is the radius of the earth, 6.371 times 10^6 meters b is the height of the orbiting object in meters Write a program that asks the user the altitude of an obit in kilometers and then displays the velocity in meters/second. Note that there are 1000 meters in a kilometer. You will have to convert the input from kilometers to meters. Enter the orbit altitude in Km 225 The orbit speed is 7773.476322849655 m/s

Explanation / Answer

CalOrbitSpeed.java

import java.util.Scanner;

public class CalOrbitSpeed {

public static void main(String[] args) {
//Declaring variables
double orbitSpeed, h;

//Declaring constants
final double G = 6.67408 * Math.pow(10, -11);
final double Me = 5.972 * Math.pow(10, 24);
final double R = 6.371 * Math.pow(10, 6);

/* Creating an Scanner class object which is used
* to get the inputs entered by the user
*/
Scanner sc = new Scanner(System.in);

//Getting the inputs entered by the user
System.out.print("Enter the Orbit altitude in km:");
h = sc.nextDouble();

//Calculate the orbit speed
orbitSpeed = Math.sqrt((G * Me) / (R + h * 1000));

//Displaying output
System.out.println("The orbit speed is :" + orbitSpeed + " m/s");


}

}

________________________

Output:

Enter the Orbit altitude in km:225
The orbit speed is :7773.476322849654 m/s


_____________Could you rate me well.Plz .Thank You

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote