Skip to main content

cw_constrain

PyPI version DOI License: MIT


Overview

cw_constrain is a Python package designed to provide tools and methods for constraining PBH abundance and the MSP hypothesis for the GeV excess using upper limits derived from continuous gravitational wave searches on real LIGO-Virgo-KAGRA data. It includes modules for analyzing GeV excess constraints, primordial black hole constraints, and shared utilities.


Features

  • Calculate constraints on MSP luminosity functions that explain the GeV excess using your own luminosity function, your own rotational frequency distribution and/or your own ellipticity distribution.
  • Compute constraints on the fraction of dark matter that primordial black hole (PBHs) could compose using your own mass function or PBH formation model.
  • Utility functions shared across modules for data processing
  • Well-structured package suitable for scientific research and data analysis

GeV excess constraints: how to use your own luminosity function

Please follow the tutorial in tutorials/O4a_GeV_excess_tutorial.ipynb


Constraining PBH abundance with your own mass functions or formation models

PBH asteroid-mass constraints:

Please follow the tutorial in tutorials/O4a_pbh_all_sky_tutorial.ipynb


PBH planetary-mass constraints:

Please follow the tutorial in tutorials/O4a_light_pbh_tutorial.ipynb


Ultralight dark-matter constraints

Please follow the tutorial in tutorials/O4a_DM_interaction_tutorial.ipynb

Installation

You can install the package directly from PyPI:

pip install cw-constrain

And then in Python:

import cw_constrain

If you use these codes, please cite the following Zenodo release:

DOI

as well as the original papers:

Constraining the millisecond pulsar hypothesis for the GeV excess

@article{Miller:2023qph,
    author = "Miller, Andrew L. and Zhao, Yue",
    title = "{Probing the Pulsar Explanation of the Galactic-Center GeV Excess Using Continuous Gravitational-Wave Searches}",
    eprint = "2301.10239",
    archivePrefix = "arXiv",
    primaryClass = "astro-ph.HE",
    doi = "10.1103/PhysRevLett.131.081401",
    journal = "Phys. Rev. Lett.",
    volume = "131",
    number = "8",
    pages = "081401",
    year = "2023"
}

Constraing asteroid-mass PBH abundance

@article{Miller:2021knj,
    author = "Miller, Andrew L. and Aggarwal, Nancy and Clesse, S\'ebastien and De Lillo, Federico",
    title = "{Constraints on planetary and asteroid-mass primordial black holes from continuous gravitational-wave searches}",
    eprint = "2110.06188",
    archivePrefix = "arXiv",
    primaryClass = "gr-qc",
    doi = "10.1103/PhysRevD.105.062008",
    journal = "Phys. Rev. D",
    volume = "105",
    number = "6",
    pages = "062008",
    year = "2022"
}

Constraining planetary-mass PBH abundance:

@article{Miller:2024fpo,
    author = "Miller, Andrew L. and Aggarwal, Nancy and Clesse, S\'ebastien and De Lillo, Federico and Sachdev, Surabhi and Astone, Pia and Palomba, Cristiano and Piccinni, Ornella J. and Pierini, Lorenzo",
    title = "{Gravitational Wave Constraints on Planetary-Mass Primordial Black Holes Using LIGO O3a Data}",
    eprint = "2402.19468",
    archivePrefix = "arXiv",
    primaryClass = "gr-qc",
    doi = "10.1103/PhysRevLett.133.111401",
    journal = "Phys. Rev. Lett.",
    volume = "133",
    number = "11",
    pages = "111401",
    year = "2024"
}

@article{Miller:2024jpo,
    author = "Miller, Andrew L. and Aggarwal, Nancy and Clesse, Sebastien and De Lillo, Federico and Sachdev, Surabhi and Astone, Pia and Palomba, Cristiano and Piccinni, Ornella J. and Pierini, Lorenzo",
    title = "{Method to search for inspiraling planetary-mass ultracompact binaries using the generalized frequency-Hough transform in LIGO O3a data}",
    eprint = "2407.17052",
    archivePrefix = "arXiv",
    primaryClass = "astro-ph.IM",
    doi = "10.1103/PhysRevD.110.082004",
    journal = "Phys. Rev. D",
    volume = "110",
    number = "8",
    pages = "082004",
    year = "2024"
}

Release files for cw-constrain 0.1.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cw-constrain 0.1.4
File Size Uploaded
cw_constrain-0.1.4.tar.gz 1.9 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for cw-constrain 0.1.4
File Interpreter ABI Platform
cw_constrain-0.1.4-py3-none-any.whl Python 3 none any Details

Total release size: 3.5 MB

Release files / cw_constrain-0.1.4.tar.gz

Download URL cw_constrain-0.1.4.tar.gz
Size 1.9 MB
Tags Source
SHA-256 checksum
How to use checksums
55afa93dba48f33af48f8fd3bd8c9f68c66f4182cd7f55bea54a2a6845a6e94d
BLAKE2b-256 checksum
How to use checksums
4d81d0346e6a09ce471f96ee63dabd0d1781a8483c8ad828f0b4888435458e95
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.13

Release files / cw_constrain-0.1.4-py3-none-any.whl

Download URL cw_constrain-0.1.4-py3-none-any.whl
Size 1.6 MB
Tags Python 3
SHA-256 checksum
How to use checksums
93eaad487e9e9b3affddb66810d09389227f341d685480acb093a9f4bd7e1727
BLAKE2b-256 checksum
How to use checksums
738ff6b98f990bdbd8d4585521b30d39fa52c631f299e28c8762df10be697dba
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.9.13

Release history Release notifications | RSS feed

This release

0.1.4 This release

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

0.0.17

2 release files

0.0.16

2 release files

0.0.15

2 release files

0.0.14

2 release files

0.0.13

2 release files

0.0.12

2 release files

0.0.11

2 release files

0.0.10

2 release files

0.0.9

1 release file

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page