Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfixing in the monolithic scheme of HM coupled with T in the staggered manner #5

Merged
merged 2 commits into from
Feb 12, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions FEM/rf_mfp_new.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2055,7 +2055,7 @@ double MFPCalcFluidsHeatCapacity(CFiniteElementStd* assem)
CFluidProperties* m_mfp = NULL;
CRFProcess* m_pcs = assem->cpl_pcs;
//if (m_pcs->pcs_type_name.find("MULTI_PHASE_FLOW")!=string::npos)
if (m_pcs->type == 1212) // non-isothermal multi-phase flow
if (m_pcs && m_pcs->type == 1212) // non-isothermal multi-phase flow
{
// Capillary pressure
PG = assem->interpolate(assem->NodalValC1);
Expand Down Expand Up @@ -2084,7 +2084,7 @@ double MFPCalcFluidsHeatCapacity(CFiniteElementStd* assem)
heat_capacity_fluids = assem->FluidProp->Density() *
assem->FluidProp->SpecificHeatCapacity();

if(m_pcs->type != 1) // neither liquid nor ground water flow
if(m_pcs && m_pcs->type != 1) // neither liquid nor ground water flow
{
// pressure
PG = assem->interpolate(assem->NodalValC1);
Expand Down
5 changes: 3 additions & 2 deletions FEM/rf_mmp_new.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2639,7 +2639,8 @@ double* CMediumProperties::HeatConductivityTensor(int number)
FLOW = true;
if (FLOW) //WW
{
if (Fem_Ele_Std->cpl_pcs->type == 1212) // Multi-phase WW
CRFProcess const* cpl_pcs = Fem_Ele_Std->cpl_pcs;
if (cpl_pcs && cpl_pcs->type == 1212) // Multi-phase WW
{
double PG = Fem_Ele_Std->interpolate(
Fem_Ele_Std->NodalValC1); // Capillary pressure
Expand Down Expand Up @@ -2673,7 +2674,7 @@ double* CMediumProperties::HeatConductivityTensor(int number)
= Fem_Ele_Std->FluidProp->HeatConductivity();
Sw = 1;

if (Fem_Ele_Std->cpl_pcs->type != 1)
if (cpl_pcs && cpl_pcs->type != 1)
{
double PG = Fem_Ele_Std->interpolate(
Fem_Ele_Std->NodalValC1); // Capillary pressure
Expand Down
51 changes: 0 additions & 51 deletions FEM/rf_pcs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -556,53 +556,6 @@ void CRFProcess::AllocateMemGPoint()
ele_gp_value.push_back(new ElementValue(this, m_msh->ele_vector[i]));
}


/**************************************************************************
FEMLib-Method:
Task: This function is a part of the monolithic scheme
and it is used to assign pcs name to IC, ST, BC, TIM and OUT. object
Programing:
07/2005 WW Implementation
10/2010 TF cody style improvements
**************************************************************************/
void CRFProcess::SetOBJNames()
{
// IC
const size_t ic_vector_size(ic_vector.size());
for (size_t i = 0; i < ic_vector_size; i++)
ic_vector[i]->setProcessType(this->getProcessType());

// BC
std::list<CBoundaryCondition*>::const_iterator p_bc = bc_list.begin();
while (p_bc != bc_list.end())
{
(*p_bc)->setProcessType(this->getProcessType());
++p_bc;
}

// ST
const size_t st_vector_size (st_vector.size());
for (size_t i = 0; i < st_vector_size; i++)
st_vector[i]->setProcessType(this->getProcessType());

// TIM
const size_t time_vector_size (time_vector.size());
for (size_t i = 0; i < time_vector_size; i++)
// Tim = time_vector[i];
// Tim->pcs_type_name = _pcs_type_name;
time_vector[i]->pcs_type_name = convertProcessTypeToString (this->getProcessType());

// OUT
// OK4216
const size_t out_vector_size (out_vector.size());
for (size_t i = 0; i < out_vector_size; i++)
// m_out = out_vector[i];
// m_out->_pcs_type_name = _pcs_type_name;
out_vector[i]->setProcessType(this->getProcessType());
//m_out->pcs_pv_name = pcs_primary_function_name[0];//CMCD
//string temp = pcs_primary_function_name[0];
}

/**************************************************************************
PCSLib-Method:
10/2002 OK Implementation
Expand Down Expand Up @@ -3164,12 +3117,8 @@ void CRFProcess::ConfigDeformation()
norm_u_JFNK = new double[2];
#endif
}

if(type / 10 == 4)
SetOBJNames(); //if(type==41) SetOBJNames(); //OK->WW please put to Config()
}


/**************************************************************************
FEMLib-Method: Static problems
Task:
Expand Down
4 changes: 0 additions & 4 deletions FEM/rf_pcs.h
Original file line number Diff line number Diff line change
Expand Up @@ -729,10 +729,6 @@ class CRFProcess : public ProcessInfo
void DDCAssembleGlobalMatrix();
#endif
virtual void AssembleSystemMatrixNew(void);
// This function is a part of the monolithic scheme
// and it is related to ST, BC, IC, TIM and OUT. WW
void SetOBJNames();


//MW
int getFirstNodeBelowGWL(size_t i);
Expand Down