pynbody.analysis.profile

Contents

pynbody.analysis.profile#

profile#

A set of classes and functions for making profiles of simulation properties.

Functions

E_circ(p)

Energy of particles on circular orbits.

Q(self)

Toomre Q parameter

X(self)

X parameter defined as kappa^2*R/(2*pi*G*sigma*m) See Binney & Tremaine 2008, eq.

beta(p)

3D Anisotropy parameter as defined in Binney and Tremiane

density(self)

Generate a radial density profile for the current type of profile

density_enc(self)

Generate the mean enclosed density profile

dyntime(self)

The dynamical time of the bin, sqrt(R^3/2GM).

fourier(self[, delta_t, phi_bins])

Generate a profile of fourier coefficients, amplitudes and phases

g_spherical(self)

The naive gravitational acceleration assuming spherical symmetry = GM_enc/r^2

j_circ(p)

Angular momentum of particles on circular orbits.

j_phi(self)

Angle that the angular momentum vector of the bin makes with the x-axis in the xy plane.

j_theta(self)

Angle that the angular momentum vector of the bin makes with respect to the xy-plane.

jtot(self)

Magnitude of the total angular momentum

kappa(...)

magnitudes(self[, band])

Calculate magnitudes in each bin

mass(self)

mass_enc(self)

Generate the enclosed mass profile

omega(p)

Circular frequency Omega = v_circ/radius (see Binney & Tremaine Sect.

pattern_frequency(pro)

Estimate the pattern speed from the m=2 Fourier mode

pot(p)

Calculates the potential in the midplane - can be expensive

rotation_curve_spherical(self)

The naive rotation curve assuming spherical symmetry: vc = sqrt(G M_enc/r)

sb(self[, band])

v_circ(p[, grav_sim])

Circular velocity, i.e. rotation curve.

weight_fn(self[, weight_by])

Calculate mass in each bin

Classes

InclinedProfile(sim, angle[, ...])

Creates a profile object to be used with a snapshot inclined by some known angle to the xy plane.

Profile(sim[, load_from_file, ndim, type, ...])

A basic profile class for arbitrary profiles.

QuantileProfile(sim[, q, weights, ...])

Creates a profile object that returns the requested quantiles for a given array in a given bin.

VerticalProfile(sim, rmin, rmax, zmax[, ...])

Creates a profile object that uses the absolute value of the z-coordinate for binning.