Metadata-Version: 2.1
Name: beamingfactor
Version: 1.0.1
Summary: Program to compute beaming factor.
Home-page: https://github.com/shift-method/beamingfactor
Author: Chuanjie Zheng
Author-email: zhengchuanjie@nao.cas.cn
License: MIT
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Requires-Python: >=3.6.0
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: scipy
Requires-Dist: numpy
Requires-Dist: matplotlib
Requires-Dist: astropy
Requires-Dist: dust-extinction


# Beaming Facor Library
**A pre-computed beaming factor library is presented in directory *BeamingFactor_Lib***.  

# BeamingFactor  
## Installation:
&ensp;&ensp;We present python based program BeamingFactor for users who want to compute factors themselves.  

    pip install beamingfactor  
## Quick Start Usage:  
Users should specify at least three components for a run:  
- the spectrum file  
- the filter transmission curve  
- orbital parameters  
### Examples:

    from beamingfactor import BeamingFactor as bf
    bf.factor(specfile='/path/to/file/file_name',spectype='PHOENIX',band='V',K=100)  
### Input Spectra Files:  
Supported spectral type included: ATLAS9, PHOENIX, TMAP, and USER.  
Users can specify synthetic spectra (files direct download from [PHOENIX](https://phoenix.astro.physik.uni-goettingen.de/?page_id=15)[^1](Must use high resolution file), [ATLAS9](https://wwwuser.oats.inaf.it/fiorella.castelli/grids.html), or [TMAP](http://astro.uni-tuebingen.de/~rauch/TMAF/flux_H+He.html)), for example:  

    bf.factor(specfile='/path/to/file/file_name',spectype='ATLAS9',band='V',K=100)
Alternatively, users can specific their own flux calibrated spectra as follows:  

    bf.factor(specfile='/path/to/file/file_name',spectype='USER',band='V',K=100)  
- Files should be an **ascii** format **csv** file.  
- First column should be **wavelength** in Angstorm and second column being **flux**, seperated by comma.
- First line can be comments or colnames begin with **'#'**.
  
An example spectrum file:  

    #Wave,Flux  
    200,2.0  
    3000,2.1  
### Input Filter Passband:    
Filter name should be given with band='Filter_Name'.  
Support Filter_Name: u,g,r,i,z,TESS,G,Gbp,Grp,U,B,V,R,I,kepler,NUV_CSST,u_c,g_c,r_c,i_c,z_c,y_c.  
>    u,g,r,i,z are from SDSS;
> 
>    NUV_CSST,u_c,g_c,r_c,i_c,z_c,y_c are from CSST
>
> TESS for TESS
>
> kepler for *Kepler*
> 
For Example:  

    bf.factor(specfile='/path/to/file/file_name',spectype='ATLAS9',band='G',K=100)  
Alternatively, users can specify their own transmission curve as follows:

    bf.factor(specfile='/path/to/file/file_name',spectype='USER',band='USER',bandfile='/path/to/your/file',bandtype='E',K=100)  
- Files should be an **ascii** format **csv** file.  
- First column should be **wavelength** in Angstorm and second column being corresponding transmission efficiency, seperated by comma.
- First line can be comments or colnames begin with **'#'**.
  
An example filter transmission curve file:  

    #Wave,T  
    200,0.01  
    3000,0.5  
The default filter type is for energy counter detector (bandtype='E'). For photon counter detertor, please give bandtype='P'.
### Orbital Parameters:
Users can directly define the radial velocity speed range with RV_min (km/s) and RV_max (km/s).  
Alternatively, users can defined the orbaital parameters with K (km/s), V0 (km/s), e, omega (degree).  
For example:  

    bf.factor(specfile='/path/to/file/file_name',spectype='ATLAS9',band='G',K=100,V0=40,e=0.1,omega=20)
    bf.factor(specfile='/path/to/file/file_name',spectype='ATLAS9',band='G',RV_min=-100,RV_max=+120)

[^1]: Must use high resolution (R=500,000) file.
