utilities for Andrew Wetzel's packages
Project description
Description
Python package of utility functions that are useful in analyzing various datasets, in particular, catalogs of particles or galaxies/halos from cosmological simulations.
Requirements
python 3, numpy, scipy, h5py, matplotlib.
Content
lower-level utilities
array.py
- create, manipulate, analyze arrays
binning.py
- binning of array data
constant.py
- physical constants and unit conversions
coordinate.py
- manipulate positions and velocities
io.py
- read, write, print during run time
math.py
- math, statistics, and fitting
plot.py
- supplementary functions for plotting with matplotlib
higher-level utilities
catalog.py
- analyze catalogs of halos/galaxies
cosmology.py
- calculate cosmological values, including cosmic density, distance, age, volume
halo_property.py
- calculate halo properties at different radii, convert between virial definitions
orbit.py
- compute orbital quantities such as peri/apo-centric distance, orbital time, in a given gravitational potential
particle.py
- high-level analysis of N-body particle data
simulation.py
- tools to help set up and run a simulation
Units
Unless otherwise noted, this package stores all quantities in (combinations of) these base units
- mass [M_sun]
- position [kpc comoving]
- distance, radius [kpc physical]
- time [Gyr]
- temperature [K]
- magnetic field [Gauss]
- elemental abundance [linear mass fraction]
These are the common exceptions to those standards
- velocity [km/s]
- acceleration [km/s / Gyr]
- gravitational potential [km^2 / s^2]
- rates (star formation, cooling, accretion) [M_sun / yr]
- metallicity (if converted from stored massfraction) [log10(mass_fraction / mass_fraction_solar)], using Asplund et al 2009 for Solar
Installing
The easiest way to install utilities
is with pip
python -m pip install git+ssh://git@bitbucket.org/awetzel/utilities.git
We recommend working on a virtual environment with venv
or conda
within which to install the package.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file utilities_awetzel-1.0.0.tar.gz
.
File metadata
- Download URL: utilities_awetzel-1.0.0.tar.gz
- Upload date:
- Size: 106.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.12.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 724466d24ac378cdcdd92d7441779f19d8317ec99bc97211b818cc77570e63ef |
|
MD5 | 4ed2e3ddbbbb064e1472b82caacbf999 |
|
BLAKE2b-256 | 513540a737b9b5e27b7cf8a4dcdb31c9c8ed6ed97479e17bf5c80023feff4b12 |
File details
Details for the file utilities_awetzel-1.0.0-py3-none-any.whl
.
File metadata
- Download URL: utilities_awetzel-1.0.0-py3-none-any.whl
- Upload date:
- Size: 111.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.12.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e1ff72e0b85ad3b12da904703b8b7697723f0beb933f8468f7ef94cda3948728 |
|
MD5 | fe2e0a281ca2c4f668d6b37721397ce9 |
|
BLAKE2b-256 | 6bcad262d430f9fdc2305f928e6a429c514939946448c7bfb5ac85e3d288ec26 |