Skip to content

Optional binary records and new parameter constructor#169

Merged
prehner merged 2 commits intobinary_associationfrom
optional_binary_records
Jul 10, 2023
Merged

Optional binary records and new parameter constructor#169
prehner merged 2 commits intobinary_associationfrom
optional_binary_records

Conversation

@prehner
Copy link
Copy Markdown
Contributor

@prehner prehner commented Jul 9, 2023

This PR comprises of two changes:

  • The binary_records in Parameter::from_records is made optional. This removes some boilerplate from models that do not use binary interaction parameters at all (ideal gas models and pure component models). If the models have a GC method, they still need a custom struct for binary records to implement all necessary traits.
  • A new constructor Parameter::from_model_records is added that internally creates the PureRecords using defaults for molarweight and identifier, and does not use binary records. This is necessary, because at the moment, it is not possible to create JobackParameters from records in Python, since there is no appropriate PureRecord around.

@prehner prehner force-pushed the optional_binary_records branch from 5d77ba6 to 866ff9b Compare July 9, 2023 15:40
@prehner prehner merged commit c5667fb into binary_association Jul 10, 2023
@prehner prehner deleted the optional_binary_records branch July 10, 2023 11:51
prehner added a commit that referenced this pull request Jul 10, 2023
* Implement binary association parameters

* Optional binary records and new parameter constructor (#169)
prehner added a commit that referenced this pull request Jul 14, 2023
* Implement binary association parameters

* Optional binary records and new parameter constructor (#169)
prehner added a commit that referenced this pull request Jul 14, 2023
* Implement binary association parameters

* Optional binary records and new parameter constructor (#169)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants