Let's first make sure we have the latest version of PHOEBE 2.2 installed. (You can comment out this line if you don't use pip for your installation or don't want to update to the latest release).
In [1]:
!pip install -I "phoebe>=2.2,<2.3"
As always, let's do imports and initialize a logger and a new Bundle. See Building a System for more details.
In [2]:
import phoebe
from phoebe import u # units
import numpy as np
import matplotlib.pyplot as plt
logger = phoebe.logger()
b = phoebe.default_binary()
There are a number of built-in constraints that can be applied to our system. Those added by default are listed below as well as in the API docs for b.add_constraint:
In [3]:
b['asini@constraint']
Out[3]:
In [4]:
b['esinw@constraint']
Out[4]:
In [5]:
b['ecosw@constraint']
Out[5]:
This constraint handles converting between different t0 conventions - namely providing a reference time at periastron passage (t0_perpass) and at superior conjunction (t0_supconj).
Currently, this constraint only supports inverting to be solved for 't0_supconj' (ie you cannot automatically invert this constraint to constraint phshift or per0).
In [6]:
b['t0_perpass@constraint']
Out[6]:
In [7]:
b['freq@constraint']
Out[7]:
In [8]:
b['freq@binary@constraint']
Out[8]:
In [9]:
b['freq@primary@constraint']
Out[9]:
In [10]:
b['mass@constraint']
Out[10]:
In [11]:
b['mass@primary@constraint']
Out[11]:
In [12]:
b['sma@constraint']
Out[12]:
In [13]:
b['sma@primary@constraint']
Out[13]:
In [14]:
b['asini@component']
Out[14]:
In [15]:
b['asini@primary@constraint']
Out[15]:
In [16]:
b['requiv_max@constraint']
Out[16]:
In [17]:
b['requiv_max@primary@constraint']
Out[17]:
In [18]:
b['period@constraint']
Out[18]:
In [19]:
b['period@primary@constraint']
Out[19]:
In [20]:
b['incl@constraint']
Out[20]:
In [21]:
b['incl@primary@constraint']
Out[21]:
In [22]:
b['long_an@constraint']
Out[22]:
In [23]:
b['long_an@primary@constraint']
Out[23]:
Next up: let's add a dataset to our Bundle.
In [ ]: