prisms-center / phaseField

PRISMS-PF: An Open-Source Phase-Field Modeling Framework
https://prisms-center.github.io/phaseField/
Other
229 stars 119 forks source link

Added check for consistent periodic BCs and unspecified BCs #225

Closed zachcroft closed 2 months ago

zachcroft commented 2 months ago

This pull request addresses the following issues:

1) When a boundary condition for a field is unspecified in parameters.prm (i.e. it's completely missing or blank) a segmentation fault will occur

2) Periodic boundary conditions are currently allowed to be defined in an inconsistent manner (e.g. natural, periodic, natural natural)

Changes: I made changes to load_BC_list.cc to give error messages for both of these cases. For issue (1) it checks if a BC list is empty, and for issue (2) it checks that 'periodic' is always specified in pairs for each direction.