erdc / proteus

A computational methods and simulation toolkit
http://proteustoolkit.org
MIT License
88 stars 56 forks source link

Isolate Meshing Routines #1238

Closed zhang-alvin closed 4 years ago

zhang-alvin commented 4 years ago

Mandatory Checklist

Please ensure that the following criteria are met:

As a general rule of thumb, try to follow PEP8 guidelines.

Description

This PR aims to isolate the meshing calls from NumericalSolution and put it under a function generateMesh in MeshTools. The result is a more readable initialization in NS_base and makes the mesh generation process more independent of the analysis.

To make this transition possible, a number of meshing specific options need to be defined in the 'domain.MeshOptions' object. This includes attributes like genMesh, nnx, nny, nn, hex, quad, and triangleOptions. This will hopefully make the setup more readable and debuggable.

codecov[bot] commented 4 years ago

Codecov Report

Merging #1238 (012270f) into master (2b9aa83) will increase coverage by 0.07%. The diff coverage is 63.06%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1238      +/-   ##
==========================================
+ Coverage   52.74%   52.82%   +0.07%     
==========================================
  Files         531      531              
  Lines      109730   109745      +15     
==========================================
+ Hits        57876    57969      +93     
+ Misses      51854    51776      -78     
Impacted Files Coverage Δ
proteus/tests/SWFlow/mach_flow.py 0.00% <0.00%> (ø)
proteus/tests/SWFlow/runup_solitaryWave.py 0.00% <0.00%> (ø)
proteus/tests/ci/poisson_3d_c0q1_n.py 93.75% <ø> (ø)
...roteus/tests/solver_tests/import_modules/step2d.py 0.00% <0.00%> (ø)
proteus/MeshTools.py 55.37% <45.53%> (+0.65%) :arrow_up:
proteus/NumericalSolution.py 78.11% <56.75%> (+7.34%) :arrow_up:
proteus/tests/elliptic_redist/RDLS/vortex2D.py 86.88% <83.33%> (+1.17%) :arrow_up:
proteus/tests/elliptic_redist/RDLS3P/vortex2D.py 86.44% <83.33%> (+1.25%) :arrow_up:
proteus/tests/levelset/vortex2D/vortex2D.py 82.92% <83.33%> (+1.10%) :arrow_up:
proteus/default_n.py 98.21% <100.00%> (+0.01%) :arrow_up:
... and 41 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 2b9aa83...012270f. Read the comment docs.