Skip to content

Fix EFFICIENCY calculation - #1074

Merged
pcarruscag merged 4 commits into
su2code:developfrom
mladenbanovic:develop
Sep 27, 2020
Merged

Fix EFFICIENCY calculation#1074
pcarruscag merged 4 commits into
su2code:developfrom
mladenbanovic:develop

Conversation

@mladenbanovic

Copy link
Copy Markdown
Contributor

Proposed Changes

This fix resolves a problem related to mismatched gradients between the forward and reverse mode of AD when considering EFFICIENCY as the objective function.

PR Checklist

Put an X by all that apply. You can fill this out after submitting the PR. If you have any questions, don't hesitate to ask! We want to help. These are a guide for you to know what the reviewers will be looking for in your contribution.

  • [X ] I am submitting my contribution to the develop branch.
  • My contribution generates no new compiler warnings (try with the '-Wall -Wextra -Wno-unused-parameter -Wno-empty-body' compiler flags).
  • My contribution is commented and consistent with SU2 style.
  • I have added a test case that demonstrates my contribution, if necessary.
  • I have updated appropriate documentation (Tutorials, Docs Page, config_template.cpp) , if necessary.

@pcarruscag pcarruscag changed the title Fix EFFICIENCY calculation in CFVMFlowSolverBase.inl Fix EFFICIENCY calculation Sep 17, 2020
…iciency value is computed outside of a for-loop that iterates through all markers.
Comment thread SU2_CFD/include/solvers/CFVMFlowSolverBase.inl Outdated

@pcarruscag pcarruscag left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@koodlyakshay

Copy link
Copy Markdown
Member

Not directly related to this PR, but I noticed an potential bug in the Friction Forces routine, line 2258. The if condition checks

if (iDim == 3)

instead of

if (nDim == 3)

Could you fix this one too?

@pcarruscag

Copy link
Copy Markdown
Member

Good catch, same bug exists in the Momentum forces routine.

@pcarruscag

Copy link
Copy Markdown
Member

I will fix the iDim==3 issues in #1022

@pcarruscag
pcarruscag merged commit e6cff74 into su2code:develop Sep 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants