Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed directional convention of energy flows in thermal_simulation.py #1

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

lkmo-stack
Copy link

The calculation of the mass flow out of nodes was based on calculating the mass flow into nodes and flipping the sign. Now the mass flow out of nodes is calculated directly. Given conservation of mass, this should not change anything. However, there are small numerical imprecisions. This change make the calculation more accurate.

The calculation of the mass flow out of nodes was based on calculating the mass flow into nodes and flipping the sign. Now the mass flow out of nodes is calculated directly. Given conservation of mass, this should not change anything. However, there are small numerical imprecisions. This change make the calculation more accurate.
@rboghe
Copy link
Member

rboghe commented Oct 23, 2024

Hi @lkmo-stack, thank you very much for pointing this out and for the pull request. I’ll run some tests to see how the Jacobian behaves and plan to merge it in the next update along with some other fixes. Do you have any insights on cases where the current convention leads to numerical imprecisions?

@rboghe rboghe self-assigned this Oct 23, 2024
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