mdolab / pygeo

pyGeo provides geometric design variables and constraints suitable for gradient-based optimization.
https://mdolab-pygeo.readthedocs-hosted.com/en/latest/?badge=latest
Apache License 2.0
122 stars 54 forks source link

Adds Distance constarints #251

Open joanibal opened 1 month ago

joanibal commented 1 month ago

Purpose

Adds a new type of constraint, distance constraints. These constraints have one end that is embedded in the geometry and another end that is fixed. I've found these useful to constrain the distance to a symmetry plane.

I've added functions to add sets of distance constraints or to create them from a polyline.

Expected time until merged

2 weeks

Type of change

Testing

run test_DVConstraint.py

Checklist

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 72.41379% with 24 lines in your changes missing coverage. Please review.

Project coverage is 65.59%. Comparing base (3404b51) to head (c4852c3).

Files Patch % Lines
pygeo/constraints/radiusConstraint.py 0.00% 12 Missing :warning:
pygeo/mphys/mphys_dvgeo.py 0.00% 9 Missing :warning:
pygeo/constraints/DVCon.py 89.28% 3 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #251 +/- ## ========================================== + Coverage 65.47% 65.59% +0.12% ========================================== Files 47 47 Lines 12265 12352 +87 ========================================== + Hits 8030 8102 +72 - Misses 4235 4250 +15 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.