Nektar++
Loading...
Searching...
No Matches
TestAdvDiffFusedElmt.cpp
Go to the documentation of this file.
1///////////////////////////////////////////////////////////////////////////////
2//
3// File: TestAdvDiffFusedElmt.cpp
4//
5// For more information, please see: http://www.nektar.info
6//
7// The MIT License
8//
9// Copyright (c) 2006 Division of Applied Mathematics, Brown University (USA),
10// Department of Aeronautics, Imperial College London (UK), and Scientific
11// Computing and Imaging Institute, University of Utah (USA).
12//
13// Permission is hereby granted, free of charge, to any person obtaining a
14// copy of this software and associated documentation files (the "Software"),
15// to deal in the Software without restriction, including without limitation
16// the rights to use, copy, modify, merge, publish, distribute, sublicense,
17// and/or sell copies of the Software, and to permit persons to whom the
18// Software is furnished to do so, subject to the following conditions:
19//
20// The above copyright notice and this permission notice shall be included
21// in all copies or substantial portions of the Software.
22//
23// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
24// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
25// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
26// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
27// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
28// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
29// DEALINGS IN THE SOFTWARE.
30//
31// Description: Unit test of the fused element-local advection-diffusion
32// operator against the separate operators it replaces, for model Navier-Stokes
33// policies in one, two and three dimensions.
34//
35///////////////////////////////////////////////////////////////////////////////
36
37#define BOOST_TEST_MODULE TestAdvDiffFusedElmt
38
40
41#include <iostream>
42
43TEST_FUSEDELMT_FIXTURE(NSSeg, NavierStokesModel<1>, true, "run/segment.xml")
44TEST_FUSEDELMT_FIXTURE(NSSegCurved, NavierStokesModel<1>, true,
45 "run/segment_curved.xml")
46TEST_FUSEDELMT_FIXTURE(NSQuadTri, NavierStokesModel<2>, true,
47 "run/square_all_elements.xml")
48TEST_FUSEDELMT_FIXTURE(NSQuadTriCurved, NavierStokesModel<2>, true,
49 "run/square_all_elements_curved.xml")
50TEST_FUSEDELMT_FIXTURE(NSHex, NavierStokesModel<3>, true, "run/hex.xml")
51TEST_FUSEDELMT_FIXTURE(NSPrism, NavierStokesModel<3>, true, "run/prism.xml")
52TEST_FUSEDELMT_FIXTURE(NSPrismCurved, NavierStokesModel<3>, true,
53 "run/prism_curved.xml")
54TEST_FUSEDELMT_FIXTURE(NSPyr, NavierStokesModel<3>, true, "run/pyr.xml")
55TEST_FUSEDELMT_FIXTURE(NSPyrCurved, NavierStokesModel<3>, true,
56 "run/pyr_curved.xml")
57TEST_FUSEDELMT_FIXTURE(NSTet, NavierStokesModel<3>, true, "run/tet.xml")
58TEST_FUSEDELMT_FIXTURE(NSTetCurved, NavierStokesModel<3>, true,
59 "run/tet_curved.xml")
60
61BOOST_AUTO_TEST_SUITE(TestSuiteAdvDiffFusedElmt)
62
63TEST_FUSEDELMT_CASE(ns_seg, NSSeg, 1.0E-10)
64TEST_FUSEDELMT_CASE(ns_seg_curved, NSSegCurved, 1.0E-10)
65TEST_FUSEDELMT_CASE(ns_quad_tri, NSQuadTri, 1.0E-10)
66TEST_FUSEDELMT_CASE(ns_quad_tri_curved, NSQuadTriCurved, 1.0E-10)
67TEST_FUSEDELMT_CASE(ns_hex, NSHex, 1.0E-10)
68TEST_FUSEDELMT_CASE(ns_prism, NSPrism, 1.0E-10)
69TEST_FUSEDELMT_CASE(ns_prism_curved, NSPrismCurved, 1.0E-10)
70TEST_FUSEDELMT_CASE(ns_pyr, NSPyr, 1.0E-10)
71TEST_FUSEDELMT_CASE(ns_pyr_curved, NSPyrCurved, 1.0E-10)
72TEST_FUSEDELMT_CASE(ns_tet, NSTet, 1.0E-10)
73TEST_FUSEDELMT_CASE(ns_tet_curved, NSTetCurved, 1.0E-10)
74
75TEST_FUSEDELMT_DEFAULT_CASE(ns_quad_tri_default, NSQuadTri)
76TEST_FUSEDELMT_DEFAULT_CASE(ns_hex_default, NSHex)
77
78BOOST_AUTO_TEST_SUITE_END()
#define TEST_FUSEDELMT_CASE(test_name, test, tol)
#define TEST_FUSEDELMT_DEFAULT_CASE(test_name, test)
#define TEST_FUSEDELMT_FIXTURE(type, policy, viscous, filename)
A fixture for policy on the mesh filename, testing the advection-diffusion operator for viscous and t...