3 #include "../../include/matrixFreePDE.h" 6 template <
int dim,
int degree>
9 computing_timer.enter_section(
"matrixFreePDE: solve");
10 pcout <<
"\nsolving...\n\n";
13 if (isTimeDependentBVP){
16 if (userInputs.grain_remapping_activated and (currentIncrement%userInputs.skip_grain_reassignment_steps == 0 or currentIncrement == 0) ) {
21 generatingInitialGuess =
true;
22 setNonlinearEqInitialGuess();
23 generatingInitialGuess =
false;
29 if (userInputs.outputTimeStepList[currentOutput] == currentIncrement) {
31 for(
unsigned int fieldIndex=0; fieldIndex<fields.size(); fieldIndex++){
32 constraintsDirichletSet[fieldIndex]->distribute(*solutionSet[fieldIndex]);
33 constraintsOtherSet[fieldIndex]->distribute(*solutionSet[fieldIndex]);
34 solutionSet[fieldIndex]->update_ghost_values();
40 if (userInputs.checkpointTimeStepList[currentCheckpoint] == currentIncrement) {
49 while (userInputs.outputTimeStepList.size() > 0 && userInputs.outputTimeStepList[currentOutput] < currentIncrement){
52 while (userInputs.checkpointTimeStepList.size() > 0 && userInputs.checkpointTimeStepList[currentCheckpoint] < currentIncrement){
57 pcout <<
"\nTime stepping parameters: timeStep: " << userInputs.dtValue <<
" timeFinal: " << userInputs.finalTime <<
" timeIncrements: " << userInputs.totalIncrements <<
"\n";
60 for (; currentIncrement<=userInputs.totalIncrements; ++currentIncrement){
62 currentTime+=userInputs.dtValue;
63 if (currentIncrement%userInputs.skip_print_steps==0){
64 pcout <<
"\ntime increment:" << currentIncrement <<
" time: " << currentTime <<
"\n";
68 adaptiveRefine(currentIncrement);
74 if (userInputs.grain_remapping_activated and (currentIncrement%userInputs.skip_grain_reassignment_steps == 0 or currentIncrement == 0) ) {
79 solveIncrement(
false);
82 if (userInputs.outputTimeStepList[currentOutput] == currentIncrement) {
83 for(
unsigned int fieldIndex=0; fieldIndex<fields.size(); fieldIndex++){
84 constraintsDirichletSet[fieldIndex]->distribute(*solutionSet[fieldIndex]);
85 constraintsOtherSet[fieldIndex]->distribute(*solutionSet[fieldIndex]);
86 solutionSet[fieldIndex]->update_ghost_values();
93 if (userInputs.checkpointTimeStepList[currentCheckpoint] == currentIncrement) {
103 generatingInitialGuess =
false;
106 solveIncrement(
false);
113 computing_timer.exit_section(
"matrixFreePDE: solve");
116 #include "../../include/matrixFreePDE_template_instantiations.h"