Commit bf7a4470 by Spencer Sherwin

Merge branch 'fix/FilterFieldConvert' into 'master'

Fix FilterFieldConvert in 3DH1D

See merge request !813
2 parents 52816be6 602ae325
......@@ -60,8 +60,9 @@ IF (NEKTAR_USE_FFTW)
# Test if FFTW path is a system path. Only add to include path if not an
# implicitly defined CXX include path (due to GCC 6.x now providing its own
# version of some C header files and -isystem reorders include paths).
GET_FILENAME_COMPONENT(X ${CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES} ABSOLUTE)
GET_FILENAME_COMPONENT(X "${CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES}" ABSOLUTE)
GET_FILENAME_COMPONENT(Y ${FFTW_INCLUDE_DIR} ABSOLUTE)
IF (NOT Y MATCHES ".*${X}.*")
INCLUDE_DIRECTORIES(SYSTEM ${FFTW_INCLUDE_DIR})
ENDIF()
......
......@@ -90,6 +90,12 @@ CommMpi::CommMpi(MPI_Comm pComm) : Comm()
*/
CommMpi::~CommMpi()
{
int flag;
MPI_Finalized(&flag);
if (!flag && m_comm != MPI_COMM_WORLD)
{
MPI_Comm_free(&m_comm);
}
}
/**
......
......@@ -485,14 +485,14 @@ void FilterFieldConvert::CreateFields(
m_f->m_fieldMetaDataMap = m_fieldMetaData;
m_f->m_fieldPts = LibUtilities::NullPtsField;
// Create m_f->m_exp
int NumHomogeneousDir = 0;
m_f->m_numHomogeneousDir = 0;
if (pFields[0]->GetExpType() == MultiRegions::e3DH1D)
{
NumHomogeneousDir = 1;
m_f->m_numHomogeneousDir = 1;
}
else if (pFields[0]->GetExpType() == MultiRegions::e3DH2D)
{
NumHomogeneousDir = 2;
m_f->m_numHomogeneousDir = 2;
}
m_f->m_exp.resize(m_variables.size());
......@@ -504,7 +504,7 @@ void FilterFieldConvert::CreateFields(
nfield = (n < pFields.num_elements())? n: 0;
m_f->m_exp[n] = m_f->AppendExpList(
NumHomogeneousDir, m_variables[0]);
m_f->m_numHomogeneousDir, m_variables[0]);
m_f->m_exp[n]->SetWaveSpace(false);
ASSERTL1(pFields[nfield]->GetNcoeffs() == m_outFields[n].num_elements(),
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!