dougshidong / PHiLiP

Parallel High-Order Library for PDEs through hp-adaptive Discontinuous Galerkin methods
Other
45 stars 36 forks source link

'has_nonzero_additional_[name]_terms' in ModelBase class #176

Open cyanmcg opened 1 year ago

cyanmcg commented 1 year ago

I think the condition should actually be if (model->has_nonzero_additional_convective_flux_terms) would be more appropriate than if(nstate==nstate_baseline_physics); this way we're not eliminating the possibility that the model has additional terms to the existing convective numerical flux in the istate <= nstate_baseline_physics.

The bool has_nonzero_additional_convective_flux_terms should be introduced in the ModelBase class as an input to the contructor; would also be a good idea to similarly do this for the dissipative flux, source term, and physical source term, by similarly introducing bool has_nonzero_additional_[name]_terms. Then use the appropriate flag for the other functions; like convective_eigenvalue etc

_Originally posted by @jbrillon in https://github.com/dougshidong/PHiLiP/pull/172#discussion_r977045185_