-
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
413 additions
and
128 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
from . import codata as codata, constants as constants | ||
from . import _codata, _constants | ||
from ._codata import * | ||
from ._codata import physical_constants as physical_constants | ||
from ._constants import * | ||
from scipy._lib._testutils import PytestTester as PytestTester | ||
|
||
__all__: list[str] = [] | ||
__all__ += _codata.__all__ | ||
__all__ += _constants.__all__ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,115 @@ | ||
from typing import Any | ||
from typing import Final, Literal, TypeAlias | ||
|
||
from scipy._typing import Untyped | ||
from typing_extensions import LiteralString | ||
|
||
txt2002: str | ||
txt2006: str | ||
txt2010: str | ||
txt2014: str | ||
txt2018: str | ||
physical_constants: dict[str, tuple[float, str, float]] | ||
__all__ = ["ConstantWarning", "find", "physical_constants", "precision", "unit", "value"] | ||
|
||
def parse_constants_2002to2014(d: str) -> dict[str, tuple[float, str, float]]: ... | ||
def parse_constants_2018toXXXX(d: str) -> dict[str, tuple[float, str, float]]: ... | ||
_Unit: TypeAlias = Literal[ | ||
"", | ||
"(GeV/c^2)^-2", | ||
"A", | ||
"A J^-1", | ||
"C", | ||
"C kg^-1", | ||
"C m", | ||
"C m^-3", | ||
"C m^2", | ||
"C mol^-1", | ||
"C^2 m^2 J^-1", | ||
"C^3 m^3 J^-2", | ||
"C^4 m^4 J^-3", | ||
"C_90 mol^-1", | ||
"E_h", | ||
"F", | ||
"F m^-1", | ||
"GeV", | ||
"GeV^-2", | ||
"H", | ||
"Hz", | ||
"Hz K^-1", | ||
"Hz T^-1", | ||
"Hz V^-1", | ||
"J", | ||
"J Hz^-1", | ||
"J Hz^-1 mol^-1", | ||
"J K^-1", | ||
"J T^-1", | ||
"J T^-2", | ||
"J m mol^-1", | ||
"J mol^-1 K^-1", | ||
"J s", | ||
"K", | ||
"K T^-1", | ||
"MHz T^-1", | ||
"MeV", | ||
"MeV fm", | ||
"MeV/c", | ||
"N", | ||
"N A^-2", | ||
"Pa", | ||
"S", | ||
"T", | ||
"V", | ||
"V m^-1", | ||
"V m^-2", | ||
"W", | ||
"W m^-2 K^-4", | ||
"W m^2", | ||
"W m^2 sr^-1", | ||
"Wb", | ||
"eV", | ||
"eV Hz^-1", | ||
"eV K^-1", | ||
"eV T^-1", | ||
"eV s", | ||
"kg", | ||
"kg m s^-1", | ||
"kg mol^-1", | ||
"lm W^-1", | ||
"m", | ||
"m K", | ||
"m s^-1", | ||
"m s^-2", | ||
"m^-1", | ||
"m^-1 K^-1", | ||
"m^-1 T^-1", | ||
"m^-3", | ||
"m^2", | ||
"m^2 s^-1", | ||
"m^3 kg^-1 s^-2", | ||
"m^3 mol^-1", | ||
"mol^-1", | ||
"ohm", | ||
"s", | ||
"s^-1 T^-1", | ||
"u", | ||
] | ||
_Constant: TypeAlias = tuple[float, _Unit, float] | ||
_ConstantDict: TypeAlias = dict[LiteralString, _Constant] | ||
|
||
# public | ||
|
||
physical_constants: Final[_ConstantDict] | ||
|
||
class ConstantWarning(DeprecationWarning): ... | ||
|
||
def find(sub: str | None = ..., disp: bool = ...) -> list[LiteralString] | None: ... | ||
def value(key: str) -> float: ... | ||
def unit(key: str) -> str: ... | ||
def unit(key: str) -> _Unit: ... | ||
def precision(key: str) -> float: ... | ||
def find(sub: str | None = None, disp: bool = False) -> Any: ... | ||
|
||
c: Untyped | ||
mu0: Untyped | ||
epsilon0: Untyped | ||
exact_values: Untyped | ||
val: Untyped | ||
# private | ||
|
||
txt2002: Final[str] | ||
txt2006: Final[str] | ||
txt2010: Final[str] | ||
txt2014: Final[str] | ||
txt2018: Final[str] | ||
|
||
def parse_constants_2002to2014(d: str) -> _ConstantDict: ... | ||
def parse_constants_2018toXXXX(d: str) -> _ConstantDict: ... | ||
|
||
c: Final[float] | ||
mu0: Final[float] | ||
epsilon0: Final[float] | ||
exact_values: Final[_ConstantDict] |
Oops, something went wrong.