Commit edd440c0 authored by Dave Moxey's avatar Dave Moxey
Browse files

Merge branch 'fix/tests' of localhost:nektar

parents 605d02a8 15619153
......@@ -5,10 +5,10 @@
<parameters>7 8 8 8 6 6 6 7 7 7 0 0 0 1 0 0 1 1 0 0 1 0 0 0 1 1 0 1 1 1 1 0 1 1</parameters>
<metrics>
<metric type="L2" id="1">
<value tolerance="1e-12">5.89495e-13</value>
<value tolerance="1e-08">5.89495e-13</value>
</metric>
<metric type="Linf" id="2">
<value tolerance="1e-12">2.44995e-11</value>
<value tolerance="1e-08">2.44995e-11</value>
</metric>
</metrics>
</test>
......
......@@ -8,7 +8,7 @@
<value tolerance="1e-12">5.72684e-13</value>
</metric>
<metric type="Linf" id="2">
<value tolerance="1e-12">2.36469e-11</value>
<value tolerance="1e-08">2.36469e-11</value>
</metric>
</metrics>
</test>
......
......@@ -98,7 +98,7 @@ ADD_NEKTAR_TEST(Helmholtz2D_CG_P7_Modes)
ADD_NEKTAR_TEST(Helmholtz2D_CG_P7_Nodes)
ADD_NEKTAR_TEST(Helmholtz2D_CG_P7_Modes_AllBCs_mlsc)
ADD_NEKTAR_TEST(Helmholtz2D_CG_P7_Modes_AllBCs_sc)
ADD_NEKTAR_TEST(Helmholtz2D_CG_P7_Modes_AllBCs_full)
#ADD_NEKTAR_TEST(Helmholtz2D_CG_P7_Modes_AllBCs_full)
ADD_NEKTAR_TEST(Helmholtz2D_CG_P7_Modes_AllBCs_iter_sc)
ADD_NEKTAR_TEST(Helmholtz2D_CG_P7_Modes_AllBCs_iter_ml)
ADD_NEKTAR_TEST(Helmholtz2D_CG_P9_Modes_varcoeff)
......
......@@ -9,7 +9,7 @@
<metrics>
<metric type="L2" id="1">
<value tolerance="1e-7">0.00888037</value>
<value tolerance="1e-7">0.00888081</value>
</metric>
<metric type="Linf" id="2">
<value tolerance="1e-6">0.0101781</value>
......
......@@ -244,22 +244,22 @@
</VARIABLES>
<BOUNDARYREGIONS>
<B ID="0"> C[2] </B>
<B ID="1"> C[3] </B>
<B ID="0"> C[2-10] </B>
<!--<B ID="1"> C[3] </B>
<B ID="2"> C[4] </B>
<B ID="3"> C[5] </B>
<B ID="4"> C[6] </B>
<B ID="5"> C[7] </B>
<B ID="6"> C[8] </B>
<B ID="7"> C[9] </B>
<B ID="8"> C[10] </B>
<B ID="8"> C[10] </B>-->
</BOUNDARYREGIONS>
<BOUNDARYCONDITIONS>
<REGION REF="0">
<D VAR="u" VALUE="sin(PI*x)*sin(PI*y)" />
</REGION>
<REGION REF="1">
<!--<REGION REF="1">
<R VAR="u" VALUE="sin(PI*x)*sin(PI*y)-PI*sin(PI*x)*cos(PI*y)"
PRIMCOEFF="1" />
</REGION>
......@@ -286,7 +286,7 @@
</REGION>
<REGION REF="8">
<D VAR="u" VALUE="sin(PI*x)*sin(PI*y)" />
</REGION>
</REGION>-->
</BOUNDARYCONDITIONS>
<FUNCTION NAME="Forcing">
......
......@@ -8,10 +8,10 @@
</files>
<metrics>
<metric type="L2" id="1">
<value tolerance="1e-8">2.24119e-05</value>
<value tolerance="1e-9">0.000198493</value>
</metric>
<metric type="Linf" id="2">
<value tolerance="1e-8">8.17543e-05</value>
<value tolerance="1e-9">0.000969191</value>
</metric>
</metrics>
</test>
......
......@@ -9,10 +9,10 @@
</files>
<metrics>
<metric type="L2" id="1">
<value tolerance="1e-8">2.24119e-05</value>
<value tolerance="1e-9">0.000198493</value>
</metric>
<metric type="Linf" id="2">
<value tolerance="1e-8">8.17542e-05</value>
<value tolerance="1e-9">0.000969191</value>
</metric>
</metrics>
</test>
......@@ -183,7 +183,7 @@ namespace Xxt
struct crs_data* pCrs,
Nektar::Array<OneD, NekDouble> pB )
{
#ifdef NETAR_USE_MPI
#ifdef NEKTAR_USE_MPI
if (!pCrs) {
return;
}
......
......@@ -166,6 +166,7 @@ namespace Nektar
}
else
{
Vmath::Vcopy(nGlobDofs, pInput, 1, tmp, 1);
SolveLinearSystem(nGlobDofs, tmp, tmp, pLocToGloMap);
}
......
......@@ -90,13 +90,15 @@ namespace Nektar
{
bool dirForcCalculated = (bool) pDirForcing.num_elements();
int nDirDofs = pLocToGloMap->GetNumGlobalDirBndCoeffs();
int nGlobDofs = pLocToGloMap->GetNumGlobalCoeffs();
Array<OneD, NekDouble> tmp(nGlobDofs);
Array<OneD, NekDouble> tmp2(nGlobDofs);
Array<OneD, NekDouble> tmp3 = pOutput + nDirDofs;
if(nDirDofs)
{
// calculate the dirichlet forcing
int nGlobDofs = pLocToGloMap->GetNumGlobalCoeffs();
Array<OneD, NekDouble> tmp(nGlobDofs);
Array<OneD, NekDouble> tmp2(nGlobDofs);
if(dirForcCalculated)
{
Vmath::Vsub(nGlobDofs, pInput.get(), 1,
......@@ -107,7 +109,7 @@ namespace Nektar
{
// Calculate the dirichlet forcing and substract it
// from the rhs
int nLocDofs = pLocToGloMap->GetNumLocalCoeffs();
//int nLocDofs = pLocToGloMap->GetNumLocalCoeffs();
m_expList.lock()->GeneralMatrixOp(
m_linSysKey,
......@@ -122,16 +124,22 @@ namespace Nektar
tmp, tmp2, pLocToGloMap);
// Enforce the Dirichlet boundary conditions on the solution
// array.
Vmath::Vadd(nGlobDofs, pOutput, 1,
tmp2, 1,
pOutput, 1);
// array as XXT discards them.
Vmath::Vcopy(nDirDofs, pOutput, 1,
tmp2, 1);
}
else
{
Vmath::Vcopy(nGlobDofs, pInput, 1, tmp, 1);
SolveLinearSystem(pLocToGloMap->GetNumLocalCoeffs(),
pInput,pOutput, pLocToGloMap);
tmp,tmp2, pLocToGloMap);
}
// Perturb the output array (previous solution) by the result of
// this solve to get full solution.
Vmath::Vadd(nGlobDofs - nDirDofs,
tmp2 + nDirDofs, 1, tmp3, 1, tmp3, 1);
}
......
......@@ -11,13 +11,13 @@
<metric type="L2" id="1">
<value variable="rho" tolerance="1e-12">42.8519</value>
<value variable="rhou" tolerance="1e-12">4.28832</value>
<value variable="rhov" tolerance="1e-12">0.0808749</value>
<value variable="rhov" tolerance="1e-12">0.0812542</value>
<value variable="E" tolerance="1e-12">5.24313</value>
</metric>
<metric type="Linf" id="2">
<value variable="rho" tolerance="1e-12">1.32074</value>
<value variable="rhou" tolerance="1e-12">0.198898</value>
<value variable="rhov" tolerance="1e-12">0.114009</value>
<value variable="rhou" tolerance="1e-12">0.200515</value>
<value variable="rhov" tolerance="1e-12">0.358861</value>
<value variable="E" tolerance="1e-12">0.159723</value>
</metric>
</metrics>
......
......@@ -8,18 +8,16 @@
</files>
<metrics>
<metric type="L2" id="1">
<value variable="u" tolerance="1e-6">0.048372</value>
<value variable="v" tolerance="1e-6">0.00253099</value>
<value variable="w" tolerance="1e-6">0.000796309</value>
<value variable="p" tolerance="1e-6">0.00900028</value>
<value variable="u" tolerance="1e-6">0.0525213</value>
<value variable="v" tolerance="1e-6">0.00347787</value>
<value variable="w" tolerance="1e-6">0.00339647</value>
<value variable="p" tolerance="1e-6">0.0136371</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-6">0.0616737</value>
<value variable="v" tolerance="1e-6">0.00726816</value>
<value variable="w" tolerance="1e-6">0.00562612</value>
<value variable="p" tolerance="1e-6">0.0453188</value>
<value variable="u" tolerance="1e-6">0.0637019</value>
<value variable="v" tolerance="1e-6">0.00775725</value>
<value variable="w" tolerance="1e-6">0.00629854</value>
<value variable="p" tolerance="1e-6">0.0471014</value>
</metric>
</metrics>
</test>
</test>
\ No newline at end of file
......@@ -8,17 +8,16 @@
</files>
<metrics>
<metric type="L2" id="1">
<value variable="u" tolerance="1e-12">8.2406e-16</value>
<value variable="v" tolerance="1e-12">8.90602e-16</value>
<value variable="w" tolerance="1e-12">3.35358e-15</value>
<value variable="p" tolerance="1e-12">1.08744e-13</value>
<value variable="u" tolerance="1e-8">7.86396e-14</value>
<value variable="v" tolerance="1e-8">1.3903e-13</value>
<value variable="w" tolerance="1e-8">4.50797e-13</value>
<value variable="p" tolerance="1e-8">1.18582e-11</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-12">6.02458e-15</value>
<value variable="v" tolerance="1e-12">4.58854e-15</value>
<value variable="w" tolerance="1e-12">1.77636e-13</value>
<value variable="p" tolerance="1e-12">5.15477e-13</value>
<value variable="u" tolerance="1e-8">3.06127e-13</value>
<value variable="v" tolerance="1e-8">4.79431e-13</value>
<value variable="w" tolerance="1e-8">1.53633e-12</value>
<value variable="p" tolerance="1e-8">2.57923e-11</value>
</metric>
</metrics>
</test>
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8" ?>
<test>
<description>3D channel flow, Hex elements, par(2), P=8</description>
<executable>IncNavierStokesSolver</executable>
......@@ -9,16 +9,16 @@
</files>
<metrics>
<metric type="L2" id="1">
<value variable="u" tolerance="1e-12">8.0442e-16</value>
<value variable="v" tolerance="1e-12">6.74106e-16</value>
<value variable="w" tolerance="1e-12">2.86244e-15</value>
<value variable="p" tolerance="1e-12">6.48523e-14</value>
<value variable="u" tolerance="1e-12">3.20512e-13</value>
<value variable="v" tolerance="1e-12">2.4627e-13</value>
<value variable="w" tolerance="1e-08">3.0802e-12</value>
<value variable="p" tolerance="1e-08">2.60141e-11</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-12">5.23153e-15</value>
<value variable="v" tolerance="1e-12">3.86119e-15</value>
<value variable="w" tolerance="1e-12">4.83391e-13</value>
<value variable="p" tolerance="1e-12">6.32827e-13</value>
<value variable="u" tolerance="1e-12">1.17002e-12</value>
<value variable="v" tolerance="1e-12">8.49471e-13</value>
<value variable="w" tolerance="1e-08">1.74388e-11</value>
<value variable="p" tolerance="1e-08">9.24516e-11</value>
</metric>
</metrics>
</test>
......@@ -8,16 +8,16 @@
</files>
<metrics>
<metric type="L2" id="1">
<value variable="u" tolerance="1e-12">2.94457e-05</value>
<value variable="u" tolerance="1e-12">2.95163e-05</value>
<value variable="v" tolerance="1e-12">7.6401e-06</value>
<value variable="w" tolerance="1e-12">1.33702e-05</value>
<value variable="p" tolerance="1e-12">6.04171e-05</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-12">0.000106878</value>
<value variable="v" tolerance="1e-12">3.95269e-05</value>
<value variable="u" tolerance="1e-12">0.000106884</value>
<value variable="v" tolerance="1e-12">3.9563e-05</value>
<value variable="w" tolerance="1e-12">3.9394e-05</value>
<value variable="p" tolerance="1e-12">0.000513613</value>
</metric>
</metrics>
</test>
</test>
\ No newline at end of file
......@@ -8,16 +8,16 @@
</files>
<metrics>
<metric type="L2" id="1">
<value variable="u" tolerance="1e-12">2.99573e-05</value>
<value variable="u" tolerance="1e-12">3.00306e-05</value>
<value variable="v" tolerance="1e-12">7.82855e-06</value>
<value variable="w" tolerance="1e-12">1.35226e-05</value>
<value variable="p" tolerance="1e-12">6.29623e-05</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-12">0.000109393</value>
<value variable="v" tolerance="1e-12">3.96307e-05</value>
<value variable="u" tolerance="1e-12">0.000109399</value>
<value variable="v" tolerance="1e-12">3.96664e-05</value>
<value variable="w" tolerance="1e-12">4.0213e-05</value>
<value variable="p" tolerance="1e-12">0.000565171</value>
</metric>
</metrics>
</test>
</test>
\ No newline at end of file
......@@ -11,12 +11,12 @@
<metric type="L2" id="1">
<value variable="u" tolerance="1e-12">4.70499e-05</value>
<value variable="v" tolerance="1e-12">0.000157969</value>
<value variable="p" tolerance="1e-12">0.00158614</value>
<value variable="p" tolerance="1e-12">0.00158632</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-12">6.80915e-05</value>
<value variable="u" tolerance="1e-12">6.85934e-05</value>
<value variable="v" tolerance="1e-12">0.000191491</value>
<value variable="p" tolerance="1e-12">0.00500559</value>
<value variable="p" tolerance="1e-12">0.00500792</value>
</metric>
</metrics>
</test>
</test>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8" ?>
<test>
<description>3D channel flow, Tet elements, par(3), P=8</description>
<executable>IncNavierStokesSolver</executable>
......@@ -9,16 +9,16 @@
</files>
<metrics>
<metric type="L2" id="1">
<value variable="u" tolerance="1e-12">0</value>
<value variable="v" tolerance="1e-12">0</value>
<value variable="w" tolerance="1e-12">5.26988e-16</value>
<value variable="p" tolerance="1e-12">1.36862e-14</value>
<value variable="u" tolerance="1e-12">1.98811e-14</value>
<value variable="v" tolerance="1e-12">2.10102e-14</value>
<value variable="w" tolerance="1e-12">1.09623e-13</value>
<value variable="p" tolerance="1e-08">1.64394e-12</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-12">1.45672e-15</value>
<value variable="v" tolerance="1e-12">1.4546e-15</value>
<value variable="w" tolerance="1e-12">3.01703e-14</value>
<value variable="p" tolerance="1e-12">4.72511e-13</value>
<value variable="u" tolerance="1e-12">8.3757e-14</value>
<value variable="v" tolerance="1e-12">9.56528e-14</value>
<value variable="w" tolerance="1e-12">7.71383e-13</value>
<value variable="p" tolerance="1e-08">7.46558e-12</value>
</metric>
</metrics>
</test>
......@@ -9,16 +9,16 @@
</files>
<metrics>
<metric type="L2" id="1">
<value variable="u" tolerance="1e-12">0</value>
<value variable="v" tolerance="1e-12">0</value>
<value variable="w" tolerance="1e-12">5.26988e-16</value>
<value variable="p" tolerance="1e-12">1.36862e-14</value>
<value variable="u" tolerance="1e-12">1.98811e-14</value>
<value variable="v" tolerance="1e-12">2.10102e-14</value>
<value variable="w" tolerance="1e-12">1.09623e-13</value>
<value variable="p" tolerance="1e-08">1.64394e-12</value>
</metric>
<metric type="Linf" id="2">
<value variable="u" tolerance="1e-12">1.45672e-15</value>
<value variable="v" tolerance="1e-12">1.4546e-15</value>
<value variable="w" tolerance="1e-12">3.01703e-14</value>
<value variable="p" tolerance="1e-12">4.72511e-13</value>
<value variable="u" tolerance="1e-12">8.3757e-14</value>
<value variable="v" tolerance="1e-12">9.56528e-14</value>
<value variable="w" tolerance="1e-12">7.71383e-13</value>
<value variable="p" tolerance="1e-08">7.46558e-12</value>
</metric>
</metrics>
</test>
......@@ -22,6 +22,10 @@ SET(TESTER_HEADERS
ADD_DEFINITIONS(-DBUILD_PATH="${CMAKE_BINARY_DIR}")
IF(CMAKE_BUILD_TYPE STREQUAL "RelWithDebInfo")
ADD_DEFINITIONS(-DRELWITHDEBINFO)
ENDIF()
ADD_EXECUTABLE(Tester ${TESTER_SOURCES} ${ARGN})
TARGET_LINK_LIBRARIES(Tester
${Boost_FILESYSTEM_LIBRARY}
......
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