Constants Utility
Physical and numerical constants utilities for ReaxKit.
This module provides access to commonly used constants defined in a packaged YAML file and exposes a small, cached API for retrieving them by name.
Constant values are stored in reaxkit/data/constants.yaml and loaded on
demand.
const(name, default=None)
Retrieve a named constant.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
name
|
str
|
Name of the constant to retrieve. |
required |
default
|
float
|
Value to return if the constant is not defined. |
None
|
Returns:
| Type | Description |
|---|---|
float or None
|
Constant value if found; otherwise |
Examples:
>>> const("kB")
>>> const("e_charge", default=1.0)