Skip to content

Setting up custom property and reaction packages #1338

Answered by andrewlee94
tk3016 asked this question in Q&A
Discussion options

You must be logged in to vote

Hi again,

The first issue is that a single Pyomo component (e.g. Param is this case) can only have a single set of units; you cannot give different units for different indices. So, in your case you will need separate Params for each reaction. For the (relatively rare) case where all the Arrhenius constants have the same units, you can use a single indexed Param, but unfortunately Arrhenius constants tend to have weird units.

I think this is the source of your problem, although the error does not make this very clear (it is strictly correct, but does nothing to explain why it happened).

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@tk3016
Comment options

Comment options

You must be logged in to vote
1 reply
@tk3016
Comment options

Answer selected by tk3016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants