diff --git a/library/LibUtilities/Foundations/Basis.cpp b/library/LibUtilities/Foundations/Basis.cpp index 45b58f300633c1d43c1c49262d3f57f7e1fa1b47..d153fbd41faee4bf4df73f291b91cae4fa856f9d 100644 --- a/library/LibUtilities/Foundations/Basis.cpp +++ b/library/LibUtilities/Foundations/Basis.cpp @@ -610,11 +610,9 @@ namespace Nektar case eFourierHalfModeIm: m_bdata[0] = -sin(M_PI*z[0]); - m_dbdata[0] = -M_PI*cos(M_PI*z[0]); + m_dbdata[0] =-M_PI*cos(M_PI*z[0]); break; - - case eChebyshev: { mode = m_bdata.data(); diff --git a/library/SolverUtils/Driver.cpp b/library/SolverUtils/Driver.cpp index acc5dadf70d639cf858f97241d8b8cd5cde22ff0..e748970f9640a326f89c72d3f3424227a6b33479 100644 --- a/library/SolverUtils/Driver.cpp +++ b/library/SolverUtils/Driver.cpp @@ -88,7 +88,6 @@ namespace Nektar { vEquation = m_session->GetSolverInfo("SolverType"); } - // Check such a module exists for this equation. ASSERTL0(GetEquationSystemFactory().ModuleExists(vEquation), "EquationSystem '" + vEquation + "' is not defined.\n" @@ -132,6 +131,7 @@ namespace Nektar break; default: ASSERTL0(false, "Unrecognised evolution operator."); + } } catch (int e) diff --git a/library/SolverUtils/DriverArnoldi.cpp b/library/SolverUtils/DriverArnoldi.cpp index 440979936e1b964353ff3e1debf3ddfbb0f4ac01..8840cbd6377715d1a1761ec2c2817f8942b9bcbe 100644 --- a/library/SolverUtils/DriverArnoldi.cpp +++ b/library/SolverUtils/DriverArnoldi.cpp @@ -63,8 +63,7 @@ namespace Nektar */ void DriverArnoldi::v_InitObject(ostream &out) { - Driver::v_InitObject(out); - + Driver::v_InitObject(out); m_session->MatchSolverInfo("SolverType","VelocityCorrectionScheme",m_timeSteppingAlgorithm, false); if(m_timeSteppingAlgorithm) @@ -98,6 +97,7 @@ namespace Nektar m_equ[0]->SetLambda(m_realShift); m_session->LoadParameter("imagShift", m_imagShift, 0.0); + cout << "Driver Arndoli end " << endl; } void DriverArnoldi::ArnoldiSummary(std::ostream &out) diff --git a/library/SolverUtils/DriverModifiedArnoldi.cpp b/library/SolverUtils/DriverModifiedArnoldi.cpp index 43870583a1a94bc6900cd82ffc5334f8749233cc..68df9316d075440e1e4862534e85fcc61eb152c1 100644 --- a/library/SolverUtils/DriverModifiedArnoldi.cpp +++ b/library/SolverUtils/DriverModifiedArnoldi.cpp @@ -140,7 +140,7 @@ namespace Nektar out << "Iteration: " << 0 << endl; // Normalise first vector in sequence - alpha[0] = std::sqrt(Vmath::Dot(ntot, &Kseq[0][0], 1, &Kseq[0][0], 1)); + alpha[0] = std::sqrt(Blas::Ddot(ntot, &Kseq[0][0], 1, &Kseq[0][0], 1)); m_comm->AllReduce(alpha[0], Nektar::LibUtilities::ReduceSum); //alpha[0] = std::sqrt(alpha[0]); @@ -154,10 +154,9 @@ namespace Nektar EV_update(Kseq[i-1], Kseq[i]); // Normalise - alpha[i] = std::sqrt(Vmath::Dot(ntot, &Kseq[i][0], 1, &Kseq[i][0], 1)); + alpha[i] = std::sqrt(Blas::Ddot(ntot, &Kseq[i][0], 1, &Kseq[i][0], 1)); m_comm->AllReduce(alpha[i], Nektar::LibUtilities::ReduceSum); - //alpha[i] = std::sqrt(alpha[i]); Vmath::Smul(ntot, 1.0/alpha[i], Kseq[i], 1, Kseq[i], 1); diff --git a/library/SolverUtils/EquationSystem.cpp b/library/SolverUtils/EquationSystem.cpp index 16f2fcd0aa75eda0192e33f174a1f3e95f314133..057d9d6c1ec3346028c7256fdfea088f1caea2a8 100644 --- a/library/SolverUtils/EquationSystem.cpp +++ b/library/SolverUtils/EquationSystem.cpp @@ -363,18 +363,8 @@ namespace Nektar for (i = 0; i < m_fields.num_elements(); i++) { - - m_fields[i] = MemoryManager<MultiRegions - ::ContField3DHomogeneous1D> - ::AllocateSharedPtr( - m_session, BkeyZR, m_LhomZ, - m_useFFT, m_homogen_dealiasing, - m_graph, - m_session->GetVariable(i), - m_checkIfSystemSingular[i]); - - if (i == m_fields.num_elements()-2) - { + if(m_session->GetVariable(i).compare("w") == 0) + { m_fields[i] = MemoryManager<MultiRegions ::ContField3DHomogeneous1D> ::AllocateSharedPtr( @@ -386,6 +376,17 @@ namespace Nektar m_checkIfSystemSingular[i]); } + m_fields[i] = MemoryManager<MultiRegions + ::ContField3DHomogeneous1D> + ::AllocateSharedPtr( + m_session, BkeyZR, m_LhomZ, + m_useFFT, m_homogen_dealiasing, + m_graph, + m_session->GetVariable(i), + m_checkIfSystemSingular[i]); + + + } } // Normal homogeneous 1D @@ -1218,7 +1219,7 @@ namespace Nektar m_useFFT, m_homogen_dealiasing, m_graph, m_session->GetVariable(i)); - m_base[i]->SetWaveSpace(true); + m_base[i]->SetWaveSpace(true); } } else diff --git a/solvers/IncNavierStokesSolver/AdvectionTerms/AdjointAdvection.cpp b/solvers/IncNavierStokesSolver/AdvectionTerms/AdjointAdvection.cpp index a9cef118369a3e028a00e91f2dd83f02d6ce9e33..1f72acd146c8a391e35c22b7980a3db4d71a91b9 100644 --- a/solvers/IncNavierStokesSolver/AdvectionTerms/AdjointAdvection.cpp +++ b/solvers/IncNavierStokesSolver/AdvectionTerms/AdjointAdvection.cpp @@ -463,9 +463,12 @@ namespace Nektar std::vector<std::vector<NekDouble> > FieldData; int nqtot = m_base[0]->GetTotPoints(); - //Get Homogeneous - LibUtilities::Import(pInfile,FieldDef,FieldData); - + + //Get Homogeneous + LibUtilities::FieldIOSharedPtr fld = + MemoryManager<LibUtilities::FieldIO>::AllocateSharedPtr(m_session->GetComm()); + fld->Import(pInfile, FieldDef, FieldData); + int nvar = m_session->GetVariables().size(); int s; diff --git a/solvers/IncNavierStokesSolver/AdvectionTerms/LinearisedAdvection.cpp b/solvers/IncNavierStokesSolver/AdvectionTerms/LinearisedAdvection.cpp index 3ff06f73368e2a6da97dcbc261dffc4c7d665ff6..99a977893cf40594fb6a894a67b5aa87dd4112f1 100644 --- a/solvers/IncNavierStokesSolver/AdvectionTerms/LinearisedAdvection.cpp +++ b/solvers/IncNavierStokesSolver/AdvectionTerms/LinearisedAdvection.cpp @@ -466,8 +466,11 @@ namespace Nektar int nqtot = m_base[0]->GetTotPoints(); //Get Homogeneous - - LibUtilities::Import(pInfile,FieldDef,FieldData); + LibUtilities::FieldIOSharedPtr fld = + MemoryManager<LibUtilities::FieldIO>::AllocateSharedPtr(m_session->GetComm()); + fld->Import(pInfile, FieldDef, FieldData); + + //LibUtilities::Import(pInfile,FieldDef,FieldData); int nvar = m_session->GetVariables().size(); int s;