Commit 15a7e567 authored by Kilian Lackhove's avatar Kilian Lackhove
Browse files

ptsField::Interpolate: do not clear intField before writing

parent d77a7f4b
......@@ -139,10 +139,8 @@ void PtsField::Interpolate(Array<OneD, Array<OneD, NekDouble> > &intFields)
int nPhysPts = m_weights.num_elements();
// interpolate points and transform
intFields = Array<OneD, Array<OneD, NekDouble> >(nFields);
for (int i = 0; i < nFields; ++i)
{
intFields[i] = Array<OneD, NekDouble>(nPhysPts);
for (int j = 0; j < nPhysPts; ++j)
{
......
......@@ -913,7 +913,11 @@ namespace Nektar
ptsField->GetWeights(m_interpWeights[weightsKey], m_interpInds[weightsKey]);
}
Array<OneD, Array<OneD, NekDouble> > intFields;
Array<OneD, Array<OneD, NekDouble> > intFields(ptsField->GetNFields());
for (int i = 0; i < ptsField->GetNFields(); ++i)
{
intFields[i] = Array<OneD, NekDouble>(ptsField->GetNpoints());
}
ptsField->Interpolate(intFields);
int fieldInd;
......
......@@ -103,6 +103,10 @@ void ProcessInterpPointDataToFld::Process(po::variables_map &vm)
// interpolate points and transform
Array<OneD, Array<OneD, NekDouble> > intFields(nFields);
for (int i = 0; i < nFields; ++i)
{
intFields[i] = Array<OneD, NekDouble>(totpoints);
}
if (m_f->m_session->GetComm()->GetRank() == 0)
{
m_f->m_fieldPts->setProgressCallback(
......
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