Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
3
3OGC-parity
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Yifan Wang
3OGC-parity
Commits
e9a1ee98
Commit
e9a1ee98
authored
3 years ago
by
Yifan Wang
Browse files
Options
Downloads
Patches
Plain Diff
add the corrected mpv waveform without the small phase expansion for GW190521
parent
d5f46a96
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
waveform/wrapper_mpv_nosmallexpansion/mpvnosmallwaveform.py
+36
-0
36 additions, 0 deletions
waveform/wrapper_mpv_nosmallexpansion/mpvnosmallwaveform.py
waveform/wrapper_mpv_nosmallexpansion/setup.py
+32
-0
32 additions, 0 deletions
waveform/wrapper_mpv_nosmallexpansion/setup.py
with
68 additions
and
0 deletions
waveform/wrapper_mpv_nosmallexpansion/mpvnosmallwaveform.py
0 → 100644
+
36
−
0
View file @
e9a1ee98
import
numpy
def
integrand_parityamu_mpvinverse
(
redshift
):
"""
The integrand:
(1.0 + z)^parity_beta / sqrt(Omega_m (1+z)^3 + Omega_Lambda)
"""
omega_m
=
0.3075
#pycbc.cosmology.get_cosmology().Om0 # matter density
omega_l
=
0.6910098821161554
#pycbc.cosmology.get_cosmology().Ode0 # dark energy density
return
(
1.0
+
redshift
)
/
numpy
.
sqrt
(
omega_m
*
(
1.0
+
redshift
)
**
3.0
+
omega_l
)
def
gen
(
**
kwds
):
from
pycbc.waveform
import
get_fd_waveform
from
pycbc
import
cosmology
import
lal
from
scipy
import
integrate
#print(kwds)
if
'
approximant
'
in
kwds
:
kwds
.
pop
(
"
approximant
"
)
if
kwds
[
'
baseapprox
'
]
is
None
:
raise
ValueError
(
"
A base waveform approximant is required.
"
)
hp
,
hc
=
get_fd_waveform
(
approximant
=
kwds
[
'
baseapprox
'
],
**
kwds
)
zz
=
cosmology
.
redshift
(
kwds
[
'
distance
'
])
intz
=
integrate
.
quad
(
integrand_parityamu_mpvinverse
,
0
,
zz
)[
0
]
temp
=
kwds
[
'
parity_mpvinverse
'
]
*
intz
/
1e9
/
lal
.
QE_SI
*
(
lal
.
H_SI
/
2
/
lal
.
PI
)
*
lal
.
PI
*
lal
.
PI
/
lal
.
H0_SI
expminus
=
np
.
exp
(
-
1j
*
temp
*
hp
.
sample_frequencies
**
2
)
expplus
=
1
/
expplus
hp_parity
=
(
hp
+
1j
*
hc
)
*
expminus
/
2
+
(
hp
-
1j
*
hc
)
*
expplus
/
2
hc_parity
=
(
hp
+
1j
*
hc
)
*
expminus
/
2j
-
(
hp
-
1j
*
hc
)
*
expplus
/
2j
return
hp_parity
,
hc_parity
This diff is collapsed.
Click to expand it.
waveform/wrapper_mpv_nosmallexpansion/setup.py
0 → 100644
+
32
−
0
View file @
e9a1ee98
"""
setup.py file for testing birefringence pycbc waveform plugin package
"""
from
setuptools
import
Extension
,
setup
,
Command
from
setuptools
import
find_packages
VERSION
=
'
0.0.dev0
'
setup
(
name
=
'
pycbc-birefringence-mpvnosmall
'
,
version
=
VERSION
,
description
=
'
A waveform plugin for PyCBC
'
,
author
=
'
Yifan Wang
'
,
author_email
=
'
yifan.wang@aei.mpg.de
'
,
url
=
'
http://www.pycbc.org/
'
,
#download_url = 'https://github.com/gwastro/revchirp/tarball/v%s' % VERSION,
keywords
=
[
'
pycbc
'
,
'
signal processing
'
,
'
gravitational waves
'
],
py_modules
=
[
'
mpvnosmall
'
],
entry_points
=
{
"
pycbc.waveform.fd
"
:
"
mpvnosmall=mpvnosmallwaveform:gen
"
},
classifiers
=
[
'
Programming Language :: Python
'
,
'
Programming Language :: Python :: 2.7
'
,
'
Programming Language :: Python :: 3.6
'
,
'
Intended Audience :: Science/Research
'
,
'
Natural Language :: English
'
,
'
Topic :: Scientific/Engineering
'
,
'
Topic :: Scientific/Engineering :: Astronomy
'
,
'
Topic :: Scientific/Engineering :: Physics
'
,
'
License :: OSI Approved :: GNU General Public License v3 (GPLv3)
'
,
],
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment