New functions to get the masses and semimajor axes of companions accurately #56
Open
cevawm wants to merge 24 commits intokima-org:mainfrom
Open
New functions to get the masses and semimajor axes of companions accurately #56cevawm wants to merge 24 commits intokima-org:mainfrom
cevawm wants to merge 24 commits intokima-org:mainfrom
Conversation
…panion (untested)
…(horrendously slow!)
…nion masses in primary mass
…vide by zero (does not work)
…oring this error and reverting back to previous commit
…nan values in mass and SMA
…ally) fully tested and functional
…nan results correspond to those where sini = 0)
Author
|
I just realized: these functions are only correct if the posterior samples reordering function applied to the posteriors beforehand places any/all "fake" companions' samples after all real companions' samples in If not, then 1.) the "fake" companions' masses may be included in the calculations as part of the "total inner mass" when calculating the mass and SMA of any real companions, and/or 2.) some outer real companions may be included as part of the "total inner mass" if they are placed before inner real companions in |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I have added three new functions to
analysis.py, for use with posteriors from the RVHGPMmodel:get_planet_mass_and_semimajor_axis_accurate, which runsget_planet_mass_accurateandget_planet_semimajor_axis_accurate. These latter two functions calculate the mass and semimajor axis of a companion more accurately than the originalget_planet_massandget_planet_semimajor_axisfunctions, since they take into account the mass of the companion itself (instead of assuming that the companion mass is negligible compared to the host star's mass), as well as the mass of any inner companions, when calculating these two orbital parameters.I have tested/bug checked these functions, and they appear to be robust. I applied an automatic PEP 8 formatting to the
analysis.pyfile; be warned this may have changed some of the formatting in other functions in this file.Most importantly, I ran these new functions on the posterior results from RVHGPMmodel fits to multiple targets, and the masses and semimajor axes are now clearly well aligned with results from
orvarafor the same targets.