Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion e3sm_submodules/Omega
Submodule Omega updated 149 files
12 changes: 4 additions & 8 deletions polaris/constants/__init__.py
Original file line number Diff line number Diff line change
@@ -1,18 +1,14 @@
from polaris.constants import pcd

# Temporary dictionary of constants not yet available via PCD, only the ones
# we actually use for now.
CONSTANTS = {
'seawater_specific_heat_capacity_reference': 3.996e3, # J kg-1 K-1
'seawater_density_reference': 1.026e3, # kg m-3
}
# Dictionary of any constants not covered by PCD
CONSTANTS: dict[str, float] = {}

CONVERSION_FACTORS = {
CONVERSION_FACTORS: dict[str, float] = {
'day_to_s': 86400.0,
}


def get_constant(name):
def get_constant(name: str) -> float:
"""
Get constants from the Physical Constants Dictionary (PCD) if available,
otherwise from the temporary dictionary of constants.
Expand Down
Loading
Loading