Skip to content

HotJupiter implements Monte Carlo simulations of exoplanet formation in globular clusters by high-e migration.

Notifications You must be signed in to change notification settings

James-Wirth/hot-jupiter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HotJupiter

License: MIT Python 3.11

HotJupiter is a Monte-Carlo simulation package for studying Hot Jupiter formation in dense globular clusters via high-e migration. We have used the REBOUND code with the IAS15 numerical integrator to simulate the dynamical evolution of planetary systems due to stellar perturbation.

The final states of planetary systems are categorized into five unique outcomes:

Category Description
Ionisation Unbound systems with $e > 1$
Tidal Disruption Systems disrupted if $r(t) < R_{\mathrm{td}}$ at any time $t$
Hot Jupiter Systems with orbital periods $T < 10 \ \mathrm{days}$
Warm Jupiter Systems with orbital periods $10 < T < 100 \ \mathrm{days}$
No Migration Systems that do not fall into the above categories

Installation

To get started with HotJupiter, clone the repository and install the dependencies:

git clone https://github.com/James-Wirth/HotJupiter
cd HotJupiter
pip install -r requirements.txt

Usage

Quickstart

The DynamicPlummer class is a simple time-interpolated Plummer model for a globular cluster. For example, for the 47 Tuc cluster (following Giersz & Heggie, 2011), we can set up a 12 Gyr-evolved instance as follows:

from hjmodel.cluster import DynamicPlummer

plummer = DynamicPlummer(
    m0=(1.64E6, 0.9E6),        # Mass at t=0 and t=total_time
    rt=(86, 70),               # Tidal radius at t=0 and t=total_time
    rh=(1.91, 4.96),           # Half-mass radius at t=0 and t=total_time
    n=(2E6, 1.85E6),           # Number of stars/binaries at t=0 and t=total_time
    total_time=12000           # Evolution duration in Myr
)

Run the Monte-Carlo simulation

With the cluster instance created, we can now initialize an HJModel instance and run the Monte-Carlo simulation.

from hjmodel import HJModel

model = HJModel(res_path=PATH)   # Specify output path

model.run_dynamic(
    time=12000,                  # Total simulation time in Myr
    num_systems=500000,          # Number of planetary systems to simulate
    cluster=plummer              # Cluster instance
)

The results are saved to the specified res_path. You can access the full data frame of results with model.df, or use built-in methods for a summary.

Analyze the results

  1. Formation rates:

Retrieve the formation rates of different planetary system outcomes:

outcome_probs = model.get_outcome_probabilities()
# Returns: {'I': f_i, 'TD': f_td, 'HJ': f_hj, 'WJ': f_wj, 'NM': f_nm}
  1. System feature statistics

Generate histogram data for system features across specified outcomes:

stats = model.get_stats_for_outcome(outcomes=["HJ", "WJ"], feature="stopping_time")
# Returns: list of values for the stopping time feature in Hot and Warm Jupiters
  1. Summary figures:

HotJupiter includes several visual summary functions for analyzing and presenting simulation results:

fig1 = model.get_summary_figure()
fig2 = model.get_projected_probability_figure()

License

About

HotJupiter implements Monte Carlo simulations of exoplanet formation in globular clusters by high-e migration.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Languages