Skip to content

Instantly share code, notes, and snippets.

View jateenrawal1002's full-sized avatar

Jateen Rawal jateenrawal1002

View GitHub Profile
@jateenrawal1002
jateenrawal1002 / Trajectory analysis.py
Created August 6, 2025 08:52
This Python script calculates interplanetary transfer parameters for a spacecraft mission departing from Earth (Planet A) to a distant ice giant (Planet C) located ~40 AU away in the Epsilon Eridani system.
import math
# === Constants ===
G = 6.67430e-11 # m^3/kg/s^2 (Gravitational Constant)
g0 = 9.81 # m/s^2 (Standard gravity)
AU = 1.496e11 # meters
M_star = 1.989e30 # kg (Sun-like)
M_a= 5.972e24 # kg
# === Spacecraft Settings ===