-
Notifications
You must be signed in to change notification settings - Fork 31
Expand file tree
/
Copy pathlib.rs
More file actions
65 lines (59 loc) · 1.68 KB
/
lib.rs
File metadata and controls
65 lines (59 loc) · 1.68 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
//! FeOs - An open-source framework for equations of state and classical functional density theory.
//!
//! # Example: critical point of a pure substance using PC-SAFT
//!
//! ```ignore
//! # use feos_core::EosError;
//! use feos::pcsaft::{PcSaft, PcSaftParameters};
//! use feos_core::parameter::{IdentifierOption, Parameter};
//! use feos_core::{Contributions, State};
//! use quantity::si::KELVIN;
//! use std::sync::Arc;
//!
//! // Read parameters from json file.
//! let parameters = PcSaftParameters::from_json(
//! vec!["propane"],
//! "tests/pcsaft/test_parameters.json",
//! None,
//! IdentifierOption::Name,
//! )?;
//!
//! // Define equation of state.
//! let saft = Arc::new(PcSaft::new(Arc::new(parameters)));
//!
//! // Define thermodynamic conditions.
//! let critical_point = State::critical_point(&saft, None, None, Default::default())?;
//!
//! // Compute properties.
//! let p = critical_point.pressure(Contributions::Total);
//! let t = critical_point.temperature;
//! println!("Critical point: T={}, p={}.", t, p);
//! # Ok::<(), EosError>(())
//! ```
#![warn(clippy::all)]
#![allow(clippy::too_many_arguments)]
#![allow(deprecated)]
#[cfg(feature = "dft")]
mod dft;
#[cfg(feature = "dft")]
pub use dft::FunctionalVariant;
mod eos;
pub use eos::{IdealGasModel, ResidualModel};
#[cfg(feature = "estimator")]
pub mod estimator;
#[cfg(feature = "association")]
pub mod association;
pub mod hard_sphere;
// models
#[cfg(feature = "gc_pcsaft")]
pub mod gc_pcsaft;
#[cfg(feature = "pcsaft")]
pub mod pcsaft;
#[cfg(feature = "pets")]
pub mod pets;
#[cfg(feature = "saftvrqmie")]
pub mod saftvrqmie;
#[cfg(feature = "uvtheory")]
pub mod uvtheory;
#[cfg(feature = "python")]
mod python;