Commit 9f35d4a3 authored by Yan Bao's avatar Yan Bao

a bug is fixed

parent 371d23a7
......@@ -829,7 +829,7 @@ namespace Nektar
ElementGIDs);
int idx = -1;
// Loop over all the expansions
for (int i = 0; i < FieldDef.size(); ++i)
{
......@@ -844,13 +844,10 @@ namespace Nektar
}
if (idx >= 0)
{
if(m_session->GetComm()->GetRank() == i)
{
m_fields[0]->ExtractDataToCoeffs(
FieldDef[i], FieldData[i],
FieldDef[i]->m_fields[idx], vCoeffs);
}
{
m_fields[0]->ExtractDataToCoeffs(
FieldDef[i], FieldData[i],
FieldDef[i]->m_fields[idx], vCoeffs);
}
else
{
......
......@@ -105,6 +105,5 @@ IF( NEKTAR_SOLVER_INCNAVIERSTOKES )
IF (NEKTAR_USE_PETSC)
ADD_NEKTAR_TEST_LENGTHY(Tet_channel_m8_petsc_sc_par)
ENDIF (NEKTAR_USE_PETSC)
ADD_NEKTAR_TEST(CylFlow_HomoStrip)
ENDIF (NEKTAR_USE_MPI)
ENDIF( NEKTAR_SOLVER_INCNAVIERSTOKES )
......@@ -125,8 +125,7 @@ void FilterMovingBody::v_Initialise(
const Array<OneD, const MultiRegions::ExpListSharedPtr> &pFields,
const NekDouble &time)
{
m_index_v = 0;
m_index_f = 0;
m_index = 0;
m_outputStream = Array<OneD, std::ofstream>(2);
// Parse the boundary regions into a list.
std::string::size_type FirstInd = m_BoundaryString.find_first_of('[') + 1;
......@@ -517,7 +516,7 @@ void FilterMovingBody::UpdateForce(
}
// Only output every m_outputFrequency.
if ((m_index_f++) % m_outputFrequency)
if ((m_index++) % m_outputFrequency)
{
return;
}
......@@ -611,7 +610,7 @@ void FilterMovingBody::UpdateForce(
}
// Only output every m_outputFrequency.
if ((m_index_f++) % m_outputFrequency)
if ((m_index) % m_outputFrequency)
{
return;
}
......@@ -703,7 +702,7 @@ void FilterMovingBody::UpdateMotion(
const NekDouble &time)
{
// Only output every m_outputFrequency.
if ((m_index_v++) % m_outputFrequency)
if ((m_index++) % m_outputFrequency)
{
return;
}
......@@ -874,7 +873,7 @@ void FilterMovingBody::UpdateMotion(
{
for (int var = 0; var < nStrVars; var++)
{
int xoffset = var*local_planes+plane;
int xoffset = plane*nStrVars+var;
int yoffset = nStrVars*local_planes+xoffset;
Motion_x[var][plane] = MotionVars[xoffset];
Motion_y[var][plane] = MotionVars[yoffset];
......
......@@ -104,8 +104,7 @@ class FilterMovingBody : public SolverUtils::Filter
/// Determines if a given Boundary Region is in
/// m_boundaryRegionsIdList
vector<bool> m_boundaryRegionIsInList;
unsigned int m_index_f;
unsigned int m_index_v;
unsigned int m_index;
unsigned int m_outputFrequency;
/// plane to take history point from if using a homogeneous1D
/// expansion
......
......@@ -8,16 +8,16 @@
</files>
<metrics>
<metric type="L2" id="1">
<value variable="u" tolerance="1e-11">8.6117e-06</value>
<value variable="v" tolerance="1e-11">3.04872e-14</value>
<value variable="w" tolerance="1e-11">8.55267e-05</value>
<value variable="p" tolerance="1e-11">9.07916e-05</value>
<value variable="u" tolerance="1e-11">2.53106e-13</value>
<value variable="v" tolerance="1e-11">2.83952e-14</value>
<value variable="w" tolerance="1e-11">7.00669e-14</value>
<value variable="p" tolerance="1e-11">3.58285e-13</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-11">0.000369264</value>
<value variable="v" tolerance="1e-11">4.00843e-13</value>
<value variable="w" tolerance="1e-11">0.0022091</value>
<value variable="p" tolerance="1e-11">0.00142775</value>
<value variable="u" tolerance="1e-11">2.56861e-12</value>
<value variable="v" tolerance="1e-11">3.47405e-13</value>
<value variable="w" tolerance="1e-11">5.99992e-13</value>
<value variable="p" tolerance="1e-11">6.1374e-12</value>
</metric>
</metrics>
</test>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment