This repository has been archived by the owner on Jan 10, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Made the outputs for pika warning about incorrect interface choices …
…(refer to pg 8 of Kaempfer 2009)
- Loading branch information
1 parent
8fcc0ad
commit 8d811c9
Showing
8 changed files
with
210 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
/****************************************************************/ | ||
/* DO NOT MODIFY THIS HEADER */ | ||
/* MOOSE - Multiphysics Object Oriented Simulation Environment */ | ||
/* */ | ||
/* (c) 2010 Battelle Energy Alliance, LLC */ | ||
/* ALL RIGHTS RESERVED */ | ||
/* */ | ||
/* Prepared by Battelle Energy Alliance, LLC */ | ||
/* Under Contract No. DE-AC07-05ID14517 */ | ||
/* With the U. S. Department of Energy */ | ||
/* */ | ||
/* See COPYRIGHT for full restrictions */ | ||
/****************************************************************/ | ||
|
||
#ifndef PIKADEBUG_H | ||
#define PIKADEBUG_H | ||
|
||
// MOOSE includes | ||
#include "PetscOutput.h" | ||
#include "FormattedTable.h" | ||
#include "PropertyUserObjectInterface.h" | ||
#include "PhaseFieldProperties.h" | ||
class PikaDebug; | ||
|
||
template<> | ||
InputParameters validParams<PikaDebug>(); | ||
|
||
/** | ||
* Base class for scalar variables and postprocessors output objects | ||
* | ||
* This class populates three FormattedTable objects that may then be used | ||
* by child classes for creating custom output objects: | ||
* _all_data_table - includes the data from both postprocessors and scalar aux variables | ||
* _postprocessor_table - includes the data from only the postprocessors | ||
* _scalar_table - includes the data from only the scalar aux variables | ||
* | ||
* @see CSV Console | ||
*/ | ||
class PikaDebug : | ||
public | ||
PetscOutput, | ||
PropertyUserObjectInterface, | ||
MaterialPropertyInterface | ||
{ | ||
public: | ||
|
||
/** | ||
* Class constructor. | ||
*/ | ||
PikaDebug(const std::string & name, InputParameters); | ||
|
||
/** | ||
* Destructor | ||
*/ | ||
virtual ~PikaDebug(); | ||
|
||
protected: | ||
|
||
//@{ | ||
/** | ||
* Produces an error, it is not possible to output nodal and elemental data to a table | ||
* | ||
* The call to this function is disable by suppressing the input parameter: output_nodal_variables | ||
*/ | ||
virtual void outputNodalVariables(); | ||
virtual void outputElementalVariables(); | ||
virtual void outputScalarVariables(); | ||
virtual void outputPostprocessors(); | ||
virtual void outputVectorPostprocessors(); | ||
virtual std::string filename(); | ||
//@} | ||
virtual void output(); | ||
const Real & _d_o; | ||
const Real & _beta; | ||
}; | ||
|
||
#endif /* TABLEOUTPUT_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
/****************************************************************/ | ||
/* DO NOT MODIFY THIS HEADER */ | ||
/* MOOSE - Multiphysics Object Oriented Simulation Environment */ | ||
/* */ | ||
/* (c) 2010 Battelle Energy Alliance, LLC */ | ||
/* ALL RIGHTS RESERVED */ | ||
/* */ | ||
/* Prepared by Battelle Energy Alliance, LLC */ | ||
/* Under Contract No. DE-AC07-05ID14517 */ | ||
/* With the U. S. Department of Energy */ | ||
/* */ | ||
/* See COPYRIGHT for full restrictions */ | ||
/****************************************************************/ | ||
|
||
// MOOSE includes | ||
#include "PikaDebug.h" | ||
#include "FEProblem.h" | ||
#include "Postprocessor.h" | ||
#include "PetscSupport.h" | ||
#include "Executioner.h" | ||
#include "MooseApp.h" | ||
#include "Conversion.h" | ||
|
||
// libMesh includes | ||
#include "libmesh/string_to_enum.h" | ||
|
||
template<> | ||
InputParameters validParams<PikaDebug>() | ||
{ | ||
// Fit mode selection Enum | ||
MooseEnum pps_fit_mode(FormattedTable::getWidthModes()); | ||
|
||
// Base class parameters | ||
InputParameters params = validParams<PetscOutput>(); | ||
params.addParam<unsigned int>("_tid",0,"HACKED thread ID, fix later!"); | ||
// Suppressing the output of nodal and elemental variables disables this type of output | ||
params.suppressParameter<bool>("output_elemental_variables"); | ||
params.suppressParameter<bool>("output_nodal_variables"); | ||
params.suppressParameter<bool>("elemental_as_nodal"); | ||
params.suppressParameter<bool>("scalar_as_nodal"); | ||
params.suppressParameter<bool>("output_input"); | ||
params.suppressParameter<bool>("output_postprocessors"); | ||
params.suppressParameter<bool>("output_vector_postprocessors"); | ||
params.suppressParameter<bool>("file_base"); | ||
|
||
return params; | ||
} | ||
|
||
PikaDebug::PikaDebug(const std::string & name, InputParameters parameters) : | ||
PetscOutput(name, parameters), | ||
PropertyUserObjectInterface(name, parameters), | ||
MaterialPropertyInterface(name,parameters), | ||
_d_o(_property_uo.getParam<Real>("capillary_length")), | ||
_beta(_property_uo.getParam<Real>("interface_kinetic_coefficient")) | ||
|
||
{ | ||
} | ||
|
||
PikaDebug::~PikaDebug() | ||
{ | ||
} | ||
|
||
void | ||
PikaDebug::outputNodalVariables() | ||
{ | ||
mooseError("Nodal nonlinear variable output not supported by PikaDebug output class"); | ||
} | ||
|
||
void | ||
PikaDebug::outputElementalVariables() | ||
{ | ||
mooseError("Elemental nonlinear variable output not supported by PikaDebug output class"); | ||
} | ||
|
||
void | ||
PikaDebug::outputPostprocessors() | ||
{ | ||
//MOOSE Error | ||
} | ||
|
||
void | ||
PikaDebug::outputVectorPostprocessors() | ||
{ | ||
//Moose Error | ||
} | ||
|
||
void | ||
PikaDebug::outputScalarVariables() | ||
{ | ||
//Moose Error | ||
} | ||
|
||
std::string PikaDebug::filename() | ||
{ | ||
//Moose Error | ||
return std::string(); | ||
} | ||
|
||
void | ||
PikaDebug::output() | ||
{ | ||
_console << "Moose Test in pika" << std::endl; | ||
_console<< "Temporal Scale Value = "<< _property_uo.temporalScale()<<std::endl; | ||
_console<< "Interface Thickness = "<< _property_uo._W<<std::endl; | ||
_console<< "Capillary Length (d_o) = "<< _d_o<<std::endl; | ||
_console<< "Interface Kinetic Coefficient (beta) = "<< _beta<<std::endl; | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters