Logo
  • GETTING STARTED
  • SCIENCE
  • FUNCTIONS

EXAMPLES

  • Time Phase Relation Theoretical
  • Doppler Theoretical in four scenarios
  • Density Through the Orbit and Absorption Column
  • Density and Ionization Parameter in the Orbital Path of Radiation
  • Ionization Map of 4U0114+65
  • Ns pulse shape in Vela X-1
  • Fe XXV Doppler Shifts Cen X-3
  • CONTRIBUTE
  • REFERENCES
xraybinaryorbit
  • EXAMPLES
  • Doppler Theoretical in four scenarios

Doppler Evolution in Various Orbital Scenarios¶

In this notebook, we will provide theoretical examples of Doppler evolution through different orbital scenarios:

  • Conic orbit
  • Spiral orbit
  • Disc in a main orbit (or ballistic motion, referred to as disc for simplicity)
  • Spiral in a main orbit

The input in these scenarios will be a time array, which we will generate artificially in the next cell.

In [7]:
Copied!
import xraybinaryorbit
from xraybinaryorbit import *
import xraybinaryorbit from xraybinaryorbit import *
In [8]:
Copied!
#In first place we define a time array
time_array=np.arange(1000,2*24*60*60,1)
#In first place we define a time array time_array=np.arange(1000,2*24*60*60,1)
In [9]:
Copied!
time_orbit, phase_orbit, ev_orbit = doppler_orbit_theoretical(time_array, units="keV", show_plot=True, load_directly=False)
time_orbit, phase_orbit, ev_orbit = doppler_orbit_theoretical(time_array, units="keV", show_plot=True, load_directly=False)
iphase: 0.5
semimajor: 1.5
orbitalperiod: 2.0
eccentricity: 0.2
periapsis: 200.0
inclination: 90.0
Rstar: 12.0
Mstar1: 22.0
Mstar2: 1.4
wind_vel: 600.0
feature: 6.7
No description has been provided for this image
In [10]:
Copied!
doppler_spiral_theoretical?
doppler_spiral_theoretical?
Signature:
doppler_spiral_theoretical(
    t,
    units='keV',
    show_plot=False,
    load_directly=False,
    parameter_list=None,
    verbose_complete=False,
)
Docstring:
Computes the Doppler variation expected from a spiral movement given a time array in seconds.

A logarithmic spiral is a type of spiral that grows by a constant factor with each turn. The spiral equation
in polar coordinates is r = a * e^(b * θ), where:

- r is the distance from the origin (radius)
- θ is the angle from a reference direction (usually the positive x-axis)
- a is the scale factor determining how quickly the spiral grows
- b is the rate of rotation controlling the tightness or looseness of the spiral

Parameters
----------
t : array-like
    Time array in seconds.
units : str, optional
    Units for the output Doppler variation. Default is "keV". Options include:
    - "keV": Doppler variation in keV.
    - "s": Doppler variation in seconds.
    - "angstrom": Doppler variation in angstroms.
show_plot : bool, optional
    If True, displays and saves a plot of the spiral and Doppler evolution. Default is False.

Notes
-----
A form will appear to input the necessary orbital parameters. These parameters are saved in a .txt file
in the current directory and automatically loaded in subsequent runs, avoiding the need to re-enter parameters.
You can modify only those parameters that require adjustment.

Returns
-------
x : array-like
    Orbital phase array corresponding to the input time array.
equation : array-like
    Expected Doppler variation computed for the given spiral movement.
File:      ~/Desktop/git/xraybinaryorbit/xraybinaryorbit/theoretical/doppler_related.py
Type:      function
In [5]:
Copied!
time_disc_in_orbit, phase1_disc_in_orbit, phase2_disc_in_orbit, ev_disc_in_orbit = doppler_disc_theoretical(time_array, units="keV",show_plot=True, load_directly=False)
time_disc_in_orbit, phase1_disc_in_orbit, phase2_disc_in_orbit, ev_disc_in_orbit = doppler_disc_theoretical(time_array, units="keV",show_plot=True, load_directly=False)
iphase: 0.0
semimajor: 2.0
orbitalperiod: 2.0
eccentricity: 0.1
periapsis: 200.0
inclination: 90.0
Rstar: 12.0
Mstar1: 20.0
Mstar2: 1.4
iphase2: 0.3
semimajor2: 0.3
orbitalperiod2: 0.06
eccentricity2: 0.2
periapsis2: 200.0
inclination2: 90.0
Mass3: 0.01
wind_vel: 0.0
feature: 6.7
No description has been provided for this image
In [6]:
Copied!
time_spiral_in_orbit, phase1_spiral_in_orbit, phase2_spiral_in_orbit, ev_spiral_in_orbit = doppler_spiral_in_orbit_theoretical(time_array,units="keV",show_plot=True, load_directly=True)
time_spiral_in_orbit, phase1_spiral_in_orbit, phase2_spiral_in_orbit, ev_spiral_in_orbit = doppler_spiral_in_orbit_theoretical(time_array,units="keV",show_plot=True, load_directly=True)
iphase: 0.0
semimajor: 1.0
orbitalperiod: 2.0
eccentricity: 0.2
periapsis: 170.0
inclination: 60.0
iphase_spiral: 0.0
semimajor_spiral: 1.0
b: 0.001
omega: 0.0001
inclination_spiral: 60.0
Rstar: 12.0
Mstar1: 20.0
Mstar2: 2.0
wind_vel: 0.0
feature: 6.7
No description has been provided for this image
In [13]:
Copied!
time_spiral_in_orbit, phase1_spiral_in_orbit, phase2_spiral_in_orbit, ev_spiral_in_orbit = doppler_spiral_theoretical(time_array,units="keV",show_plot=True, load_directly=False)
time_spiral_in_orbit, phase1_spiral_in_orbit, phase2_spiral_in_orbit, ev_spiral_in_orbit = doppler_spiral_theoretical(time_array,units="keV",show_plot=True, load_directly=False)
iphase_spiral: 0.0
semimajor_spiral: 0.8716480454950168
b: -0.01
omega: 0.001
inclination_spiral: 29.0
feature: 6.4
No description has been provided for this image
In [ ]:
Copied!

Previous Next

Built with MkDocs using a theme provided by Read the Docs.
« Previous Next »