Skip to content

MassBalance and EnergyBalance needs to be generalized. #19

@At11011

Description

@At11011

In blocks.rs, we need to generalize the approach to track all streams entering and leaving the block for mass and energy balances. The following can be done:

  • Track all connectors, not just a single mass in-mass out value pairs
  • Compare relative error, for example, the total difference as compared to the total input. This should be an adjustable parameter similar to TOLERANCE_ENERGY and TOLERANCE_MASS, but should be dimensionless instead.
  • The mass_balance_check function should just take a &self reference, instead of actual value arguments. The blocks should contain references to Mconnectors and Econnectors (these I also believe should be revised, but that is a later issue).

I have included TODO's in the style-fix branch (to be uploaded in due time) that reference this issue.

Metadata

Metadata

Labels

enhancementNew feature or request

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions