uw-comphys / openccm

OpenCCM is a CFD-based compartment modelling software package. It is primarily intended for convection dominated reactive flows which feature a weak or one-way coupling between the reactive species and the carrier fluid, i.e. the reaction does not substantially influence the fluid flow over the course of the simulation.
https://uw-comphys.github.io/openccm/
GNU Lesser General Public License v2.1
0 stars 3 forks source link

Fix for incorrect variable passed to linprog #25

Closed Alex-Vasile closed 5 months ago

Alex-Vasile commented 5 months ago

linprog takes a parameter integrality which specifies whether the result should be continuous, semi-continuous, or an integer. I previous incorrectly set this value to 1 which forced the results to be integers. I have changed it to the correct value of 2 which requires the results to be continuous but bounded by the specified bounds.

Also, I have included a pytest file which runs all of the examples. It makes no comparison of the results, it's purpose is to make sure that all of the examples pass their assert statements.