Roman and Rubin simulations and analisys.
The repository contains simulations and analyses to study the impact of combining observations of Roman and Rubin microlensing events.
The all_results
directory contains analysis results for a set of events corresponding to Free Floating Planets (FFP), Black Holes (BH), and Bound Planets (PB).
true.csv
: Contains the true simulation parameters.fit_rr.csv
: Contains the estimated parameters and uncertainties from the fit using data from both the Roman and Rubin observatories.fit_roman.csv
: Contains similar information asfit_rr.csv
but using only Roman data.
Each of these files includes the following columns:
-
Event Identifiers:
Source
: Identification number of the event.Set
: Set identifier, as events are generated in different sets.
-
Microlensing Parameters:
t0
: Time of maximum magnification.u0
: Impact parameter.te
: Einstein timescale.rho
: Ratio of the source’s angular radius to the Einstein angular radius.s
: Separation between lenses, in units of Einstein radius (θE).q
: Mass ratio of the lenses.alpha
: Angle between the lens axis and line of sight.piEN
: North component of the parallax.piEE
: East component of the parallax.
-
Uncertainties for Each Parameter:
t0_err
: Uncertainty int0
.u0_err
: Uncertainty inu0
.te_err
: Uncertainty inte
.rho_err
: Uncertainty inrho
.s_err
: Uncertainty ins
.q_err
: Uncertainty inq
.alpha_err
: Uncertainty inalpha
.piEN_err
: Uncertainty inpiEN
.piEE_err
: Uncertainty inpiEE
.
-
Additional Parameters:
piE
: Total parallax magnitude.piE_err
: Uncertainty in the total parallax.piE_err_MC
: Monte Carlo-derived uncertainty in the total parallax.
-
Mass-Related Parameters:
mass_thetaE
: Mass estimate derived from θE.mass_mu
: Mass estimate derived from proper motion.mass_thetaS
: Mass estimate derived from the source’s angular radius.err_mass_thetaE_NotMC
: Non-Monte Carlo uncertainty inmass_thetaE
.mass_err_thetaE
: Uncertainty inmass_thetaE
.mass_err_mu
: Uncertainty inmass_mu
.mass_err_thetaS
: Uncertainty inmass_thetaS
.
-
Fit Quality Metrics:
chichi
: Fit quality parameter.dof
: Degrees of freedom for the fit.chi2
: Chi-squared value of the fit.
The notebooks in the notebooks
directory contains three notebooks
Binary_Lens_results.ipynb
FFP_results.ipynb
BH_results.ipynb
these notebooks contain the plot of the metrics
In the results you can find two propagation of uncertainty one using the error propagation formulae for a set of functions which all depend on the n random variables , thus
The second is using a montecarlo aproach by generating samples using the covariance matrix in a multinormal distribution, the covariance matrix is provided by the TRF routine in pyLIMA.
We run three test for the mass estimation using
- Assuming known . We use only the information about the estimation of and its uncertainty.
- Assuming known . We use the information about the estimation of and its uncertainty and the estimation of and its uncertainty to compute and propagate its uncertainty.
- Assuming known . We use the information about the estimation of and its uncertainty and the estimation of and its uncertainty to compute and propagate its uncertainty.
The code functions_roman_rubin.py
contains the fit routine and the simulation using pyLIMA and rubin_sim.
Purpose:
Simulates telescope observations for Rubin Observatory and Roman Space Telescope, creating synthetic light curves for microlensing events.
Inputs:
path_ephemerides
: Path to ephemerides file for spacecraft positions.path_dataslice
: Path to Rubin data slice file.
Outputs:
- A microlensing event object with telescope data.
Purpose:
Checks if there are at least four data points within [t0 - tE, t0 + tE]
that deviate from the constant flux baseline by more than 3σ.
Inputs:
pyLIMA_parameters
: Parameters describing the microlensing model.pyLIMA_telescopes
: Telescope data objects with light curves.
Outputs:
- A boolean indicating whether the deviation condition is satisfied.
Purpose:
Ensures that at least one light curve contains at least five data points within the range [t0 - tE, t0 + tE]
.
Inputs:
pyLIMA_parameters
: Microlensing model parameters.pyLIMA_telescopes
: Telescope data objects with light curves.
Outputs:
- A boolean indicating whether the condition is met.
Purpose:
Converts flux measurements into magnitudes.
Inputs:
zp
: Zero-point magnitude.Flux
: Light curve flux values.
Outputs:
- Magnitudes corresponding to the input flux values.
Purpose:
Filters light curve data based on magnitude limits and 5σ depth criteria, ensuring that the curve contains sufficient points for analysis.
Inputs:
mjd
: Modified Julian Dates.mag
: Magnitudes.magerr
: Magnitude errors.m5
: 5σ limiting magnitudes.fil
: Filter name.
Outputs:
- Filtered light curve data points and a boolean indicating significant detections.
Purpose:
Checks if there are at least three consecutive numbers in a list.
Inputs:
lst
: List of integers.
Outputs:
- A boolean indicating if the condition is met.
Purpose:
Configures photometric parameters, including exposure time and read noise.
Inputs:
exptime
: Exposure time.nexp
: Number of exposures.readnoise
: (Optional) Read noise in electrons per pixel.
Outputs:
- A photometric parameters object.
Purpose:
Performs model fitting for Rubin and Roman telescope data using various microlensing models (e.g., FSPL, USBL, PSPL).
Inputs:
- Parameters for the event, model type, algorithm, and light curves for Rubin and Roman data.
Outputs:
- Fit results and associated event data.
Purpose:
Saves processed event data, light curves, and model parameters to an HDF5 file.
Inputs:
- Event index, paths to save location, and model parameters.
Outputs:
- HDF5 file containing the saved data.
Purpose:
Reads event data (simulated) for further processing.