Kinematics#

class agabpylib.simulation.starclusters.kinematics.Kinematics#

Bases: ABC

Abstract base class for classes representing the kinematics of stars in a cluster.

Methods Summary

addinfo()

returns:

info -- String with specific information about the cluster kinematics.

generate_kinematics(x, y, z, rng)

Generate the velocity vectors of the stars randomly according to the prescribed kinematics of the cluster.

getinfo()

returns:

info -- String with information about the cluster kinematics.

getmeta()

returns:

meta -- Metadata on the kinematics of the cluster stars.

Methods Documentation

abstract addinfo()#
Returns:

info – String with specific information about the cluster kinematics.

Return type:

str

abstract generate_kinematics(x, y, z, rng)#

Generate the velocity vectors of the stars randomly according to the prescribed kinematics of the cluster.

Parameters:
  • x (astropy.units.Quantity arrays) – The x, y, z positions of the stars with respect to the barycentre, in units of pc, where the barycentre of the cluster is assumed to be at (0, 0, 0) pc!

  • y (astropy.units.Quantity arrays) – The x, y, z positions of the stars with respect to the barycentre, in units of pc, where the barycentre of the cluster is assumed to be at (0, 0, 0) pc!

  • z (astropy.units.Quantity arrays) – The x, y, z positions of the stars with respect to the barycentre, in units of pc, where the barycentre of the cluster is assumed to be at (0, 0, 0) pc!

  • rng (numpy.random.Generator) – Random number generator. This is provided separately to enable user control over the random number sequence.

Returns:

v_x, v_y, v_z – The v_x, v_y, v_z velocity components of the stars in units of km/s.

Return type:

astropy.units.Quantity arrays

getinfo()#
Returns:

info – String with information about the cluster kinematics.

Return type:

str

abstract getmeta()#
Returns:

meta – Metadata on the kinematics of the cluster stars.

Return type:

dict