Examples (examples
)#
Functions:
|
Load a json file into a dict. |
|
Load a dictionary of data |
|
Load an example file |
Create an |
|
Create an |
|
Create an |
|
Create an |
Classes:
Example dict |
|
|
Dataclass to hold example data. |
- lnpy.examples.json_to_dict(basename)[source]#
Load a json file into a dict.
All files names are relative to ‘lnpy/data/’
- lnpy.examples.load_example_dict(name)[source]#
Load a dictionary of data
- Parameters:
name (
{'lj_sub', 'lj_sup', 'ljmix_sup', 'hsmix', 'watermof}
)
- lnpy.examples.load_example_lnpimasked(name)[source]#
Load an example file
- Parameters:
name (
{'lj_sub', 'lj_sup', 'ljmix_sup', 'hsmix', 'watermof}
)
- class lnpy.examples.Example(ref, phase_creator, build_phases)[source]#
Bases:
object
Dataclass to hold example data.
Attributes:
Reference state
lnPiMasked
.PhaseCreator
instanceCallable to build phases.
Methods:
to_dict
()Transform class to dictionary.
unpack
([keys])Unpack keys.
- ref#
Reference state
lnPiMasked
.
- phase_creator#
PhaseCreator
instance
- build_phases#
Callable to build phases.
- lnpy.examples.lj_sup_example()[source]#
Create an
Example
instance for a Lennard-Jones fluid (subcritical)
- lnpy.examples.lj_sub_example()[source]#
Create an
Example
instance for a Lennard-Jones fluid (subcritical)