From de3cde0b1d2eba07238b07d10a5847d3c373d6f3 Mon Sep 17 00:00:00 2001 From: Wolfgang Bangerth Date: Tue, 2 May 2006 01:18:13 +0000 Subject: [PATCH] Move the stuff that is common to all space dimensions to their own file. This worked by accident before. git-svn-id: https://svn.dealii.org/trunk@12947 0785d39b-7218-0410-832d-ea1e28bc413d --- .../dofs/hp_dof_levels.all_dimensions.cc | 50 +++++++++++++++++++ deal.II/deal.II/source/dofs/hp_dof_levels.cc | 30 ----------- 2 files changed, 50 insertions(+), 30 deletions(-) create mode 100644 deal.II/deal.II/source/dofs/hp_dof_levels.all_dimensions.cc diff --git a/deal.II/deal.II/source/dofs/hp_dof_levels.all_dimensions.cc b/deal.II/deal.II/source/dofs/hp_dof_levels.all_dimensions.cc new file mode 100644 index 0000000000..8df4c72598 --- /dev/null +++ b/deal.II/deal.II/source/dofs/hp_dof_levels.all_dimensions.cc @@ -0,0 +1,50 @@ +//---------------------------- hp_dof_levels.cc --------------------------- +// $Id$ +// Version: $Name$ +// +// Copyright (C) 2003, 2006 by the deal.II authors +// +// This file is subject to QPL and may not be distributed +// without copyright and license information. Please refer +// to the file deal.II/doc/license.html for the text and +// further information on this license. +// +//---------------------------- hp_dof_levels.cc ------------------------ + + +#include +#include + + +namespace internal +{ + namespace hp + { + unsigned int + DoFLevel<1>::memory_consumption () const + { + return (MemoryConsumption::memory_consumption (line_dofs) + + MemoryConsumption::memory_consumption (dof_line_index_offset)); + } + + + + unsigned int + DoFLevel<2>::memory_consumption () const + { + return (DoFLevel<1>::memory_consumption () + + MemoryConsumption::memory_consumption (quad_dofs) + + MemoryConsumption::memory_consumption (dof_quad_index_offset)); + } + + + + unsigned int + DoFLevel<3>::memory_consumption () const + { + return (DoFLevel<2>::memory_consumption () + + MemoryConsumption::memory_consumption (hex_dofs) + + MemoryConsumption::memory_consumption (dof_hex_index_offset)); + } + } +} diff --git a/deal.II/deal.II/source/dofs/hp_dof_levels.cc b/deal.II/deal.II/source/dofs/hp_dof_levels.cc index aefa556a6f..4da48a1b5f 100644 --- a/deal.II/deal.II/source/dofs/hp_dof_levels.cc +++ b/deal.II/deal.II/source/dofs/hp_dof_levels.cc @@ -22,36 +22,6 @@ namespace internal { namespace hp { - unsigned int - DoFLevel<1>::memory_consumption () const - { - return (MemoryConsumption::memory_consumption (line_dofs) + - MemoryConsumption::memory_consumption (dof_line_index_offset)); - } - - - - unsigned int - DoFLevel<2>::memory_consumption () const - { - return (DoFLevel<1>::memory_consumption () + - MemoryConsumption::memory_consumption (quad_dofs) + - MemoryConsumption::memory_consumption (dof_quad_index_offset)); - } - - - - unsigned int - DoFLevel<3>::memory_consumption () const - { - return (DoFLevel<2>::memory_consumption () + - MemoryConsumption::memory_consumption (hex_dofs) + - MemoryConsumption::memory_consumption (dof_hex_index_offset)); - } - - - - template unsigned int DoFLevel<1>:: -- 2.39.5