Skip to content

How to adding a new "state" variable in PeleC? #933

Closed Answered by baperry2
Soobin120596 asked this question in Q&A
Discussion options

You must be logged in to vote

To add a new state variable, the easiest way is to use the existing ADV (advected) and AUX (not advected) capabilities. In your GNUmakefile, set PELE_NUM_ADV or PELE_NUM_AUX to the number of new variables you would like. You can provide names for these variables by defining a custom ProblemSpecificFunctions::set_adv_names function in your prob.H. Then it's up to you to provide appropriate initial conditions for these components of the state vector in pc_initdata, user-defined boundary conditions if needed in bcnormal, and user-defined source terms if desired in ProblemSpecificFunctions::problem_modify_ext_sources.

See Exec/RegTests/AuxQuantities for an example.

With what you are doing, yo…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by Soobin120596
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants