From b4c797994f391bba0f17a0231dec31c9dab67d7a Mon Sep 17 00:00:00 2001 From: Sebastian Eibl <sebastian.eibl@fau.de> Date: Fri, 3 Aug 2018 11:25:27 +0200 Subject: [PATCH] clang-tidy -checks=-*,modernize-use-using --- .../ComplexGeometry/ComplexGeometry.cpp | 6 +-- apps/benchmarks/CouetteFlow/CouetteFlow.cpp | 20 ++++----- .../ForcesOnSphereNearPlaneInShearFlow.cpp | 8 ++-- .../MotionSingleHeavySphere.cpp | 12 ++--- .../NonUniformGrid/NonUniformGrid.cpp | 24 +++++----- .../PeriodicGranularGas.cpp | 2 +- .../PoiseuilleChannel/PoiseuilleChannel.cpp | 20 ++++----- .../SchaeferTurek/SchaeferTurek.cpp | 44 +++++++++---------- apps/benchmarks/UniformGrid/UniformGrid.cpp | 24 +++++----- .../BidisperseFluidizedBedDPM.cpp | 12 ++--- apps/tutorials/lbm/01_BasicLBM.cpp | 12 ++--- .../lbm/02_BasicLBM_ExemplaryExtensions.cpp | 10 ++--- apps/tutorials/lbm/03_LBLidDrivenCavity.cpp | 12 ++--- apps/tutorials/pde/01_SolvingPDE.cpp | 2 +- apps/tutorials/pde/02_HeatEquation.cpp | 2 +- .../pde/03_HeatEquation_Extensions.cpp | 2 +- .../loadbalancing/StaticParMetis.cpp | 2 +- src/geometry/structured/extern/lodepng.cpp | 2 +- src/pe/Materials.cpp | 2 +- src/pe_coupling/utility/TimeStep.cpp | 2 +- tests/boundary/BoundaryHandling.cpp | 4 +- tests/core/math/GenericAABBTest.cpp | 8 ++-- tests/core/math/PlaneTest.cpp | 8 ++-- tests/core/mpi/BufferSystemTest.cpp | 2 +- .../selectable/SetSelectableObjectTest.cpp | 2 +- tests/field/FieldTiming.cpp | 2 +- tests/field/FlagFieldTest.cpp | 6 +-- tests/field/adaptors/AdaptorTest.cpp | 12 ++--- tests/field/distributors/DistributionTest.cpp | 4 +- .../interpolators/FieldInterpolationTest.cpp | 4 +- tests/geometry/Functions.cpp | 2 +- tests/geometry/VoxelFileTest.cpp | 2 +- tests/gui/GuiPdfView.cpp | 2 +- tests/gui/SimpleGuiRun.cpp | 4 +- tests/lbm/BoundaryHandlingCommunication.cpp | 10 ++--- tests/lbm/DiffusionTest.cpp | 10 ++--- tests/lbm/Poiseuille.cpp | 6 +-- tests/lbm/SweepEquivalenceTest.cpp | 10 ++--- tests/lbm/boundary/DiffusionDirichlet.cpp | 12 ++--- .../lbm/boundary/SimpleDiffusionDirichlet.cpp | 8 ++-- tests/lbm/boundary/SimplePABTest.cpp | 10 ++--- tests/lbm/evaluations/PermeabilityTest.cpp | 16 +++---- .../initializer/PdfFieldInitializerTest.cpp | 6 +-- .../refinement/CommunicationEquivalence.cpp | 8 ++-- tests/lbm/refinement/NonConstantDiffusion.cpp | 8 ++-- tests/lbm/refinement/Uniformity.cpp | 10 ++--- tests/mesh/DistributedMeshVTKTest.cpp | 2 +- tests/mesh/MeshBlockExclusionTest.cpp | 2 +- tests/mesh/MeshOperationsTest.cpp | 2 +- tests/mesh/PeVTKMeshWriterTest.cpp | 4 +- tests/mesh/QHullTest.cpp | 2 +- tests/pde/CGTest.cpp | 4 +- tests/pde/JacobiTest.cpp | 4 +- tests/pde/MGConvergenceTest.cpp | 4 +- tests/pde/MGTest.cpp | 4 +- tests/pde/RBGSTest.cpp | 4 +- tests/pde/SORTest.cpp | 4 +- tests/pe/BodyFlags.cpp | 2 +- tests/pe/BodyIterators.cpp | 2 +- tests/pe/Collision.cpp | 2 +- tests/pe/DeleteBody.cpp | 2 +- tests/pe/DestroyBody.cpp | 2 +- tests/pe/DynamicRefinement.cpp | 2 +- tests/pe/Marshalling.cpp | 8 ++-- tests/pe/ParMetis.cpp | 4 +- tests/pe/PeDocumentationSnippets.cpp | 4 +- tests/pe/SerializeDeserialize.cpp | 2 +- tests/pe/ShadowCopy.cpp | 2 +- tests/pe/SimpleCCD.cpp | 2 +- tests/pe/SyncEquivalence.cpp | 2 +- tests/pe/Synchronization.cpp | 2 +- tests/pe/SynchronizationDelete.cpp | 2 +- tests/pe/SynchronizationLargeBody.cpp | 2 +- tests/pe/Union.cpp | 2 +- .../HinderedSettlingDynamicsDPM.cpp | 16 +++---- .../SphereWallCollisionBehaviorDPM.cpp | 16 +++---- .../BodyAtBlockBoarderCheck.cpp | 14 +++--- .../BodyMappingTest.cpp | 12 ++--- .../DragForceSphereMEM.cpp | 12 ++--- .../DragForceSphereMEMRefinement.cpp | 10 ++--- ...lobalBodyAsBoundaryMEMStaticRefinement.cpp | 12 ++--- .../LubricationCorrectionMEM.cpp | 8 ++-- .../PeriodicParticleChannelMEM.cpp | 10 ++--- .../SegreSilberbergMEM.cpp | 8 ++-- .../SettlingSphereMEM.cpp | 8 ++-- .../SettlingSphereMEMDynamicRefinement.cpp | 8 ++-- .../SettlingSphereMEMStaticRefinement.cpp | 8 ++-- .../momentum_exchange_method/SquirmerTest.cpp | 14 +++--- .../TaylorCouetteFlowMEM.cpp | 10 ++--- .../TorqueSphereMEM.cpp | 10 ++--- .../DragForceSpherePSM.cpp | 12 ++--- .../DragForceSpherePSMRefinement.cpp | 12 ++--- .../SegreSilberbergPSM.cpp | 10 ++--- .../TorqueSpherePSM.cpp | 10 ++--- .../BodiesForceTorqueContainerTest.cpp | 2 +- .../pe_coupling/utility/PeSubCyclingTest.cpp | 2 +- 96 files changed, 350 insertions(+), 350 deletions(-) diff --git a/apps/benchmarks/ComplexGeometry/ComplexGeometry.cpp b/apps/benchmarks/ComplexGeometry/ComplexGeometry.cpp index 52b02c677..8a18cbccd 100644 --- a/apps/benchmarks/ComplexGeometry/ComplexGeometry.cpp +++ b/apps/benchmarks/ComplexGeometry/ComplexGeometry.cpp @@ -217,9 +217,9 @@ int main( int argc, char * argv[] ) typedef lbm::D3Q19<lbm::collision_model::SRT, false, lbm::force_model::SimpleConstant> LatticeModel_T; - typedef walberla::uint8_t flag_t; - typedef FlagField< flag_t > FlagField_T; - typedef lbm::PdfField< LatticeModel_T > PdfField_T; + using flag_t = walberla::uint8_t; + using FlagField_T = FlagField<flag_t>; + using PdfField_T = lbm::PdfField<LatticeModel_T>; LatticeModel_T latticeModel{ lbm::collision_model::SRT( omega ), lbm::force_model::SimpleConstant( bodyForce ) }; diff --git a/apps/benchmarks/CouetteFlow/CouetteFlow.cpp b/apps/benchmarks/CouetteFlow/CouetteFlow.cpp index 48fe122e9..1653b7fe5 100644 --- a/apps/benchmarks/CouetteFlow/CouetteFlow.cpp +++ b/apps/benchmarks/CouetteFlow/CouetteFlow.cpp @@ -139,12 +139,12 @@ typedef lbm::D3Q27< lbm::collision_model::TRT, true > D3Q27_TRT_COMP; template< typename LatticeModel_T > struct Types { - typedef typename LatticeModel_T::Stencil Stencil_T; - typedef lbm::PdfField< LatticeModel_T > PdfField_T; + using Stencil_T = typename LatticeModel_T::Stencil; + using PdfField_T = lbm::PdfField<LatticeModel_T>; }; -typedef walberla::uint16_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint16_t; +using FlagField_T = FlagField<flag_t>; const uint_t FieldGhostLayers = uint_t(4); @@ -399,7 +399,7 @@ template< typename LatticeModel_T > typename MyBoundaryHandling<LatticeModel_T>::BoundaryHandling_T * MyBoundaryHandling<LatticeModel_T>::operator()( IBlock * const block ) const { - typedef typename Types<LatticeModel_T>::PdfField_T PdfField_T; + using PdfField_T = typename Types< LatticeModel_T >::PdfField_T; FlagField_T * flagField = block->getData< FlagField_T >( flagFieldId_ ); PdfField_T * pdfField = block->getData< PdfField_T > ( pdfFieldId_ ); @@ -457,7 +457,7 @@ class ErrorVTKWriter : public vtk::BlockCellDataWriter< OutputType, 3 > { public: - typedef lbm::PdfField< LatticeModel_T > PdfField_T; + using PdfField_T = lbm::PdfField< LatticeModel_T >; ErrorVTKWriter( const ConstBlockDataID & pdfFieldId, const std::string & id, const Setup & setup ) : vtk::BlockCellDataWriter< OutputType, 3 >( id ), bdid_( pdfFieldId ), pdf_( nullptr ), setup_( setup ) {} @@ -589,7 +589,7 @@ void addRefinementTimeStep( SweepTimeloop & timeloop, shared_ptr< blockforest::S const bool syncComm, const bool fullComm, const bool linearExplosion, shared_ptr< Sweep_T > & sweep, const std::string & info ) { - typedef typename MyBoundaryHandling< LatticeModel_T >::BoundaryHandling_T BH_T; + using BH_T = typename MyBoundaryHandling< LatticeModel_T >::BoundaryHandling_T; auto ts = lbm::refinement::makeTimeStep< LatticeModel_T, BH_T >( blocks, sweep, pdfFieldId, boundaryHandlingId ); ts->asynchronousCommunication( !syncComm ); @@ -612,7 +612,7 @@ struct AddRefinementTimeStep { if( pure ) { - typedef lbm::SplitPureSweep< LatticeModel_T > Sweep_T; + using Sweep_T = lbm::SplitPureSweep< LatticeModel_T >; auto mySweep = make_shared< Sweep_T >( pdfFieldId ); addRefinementTimeStep< LatticeModel_T, Sweep_T >( timeloop, blocks, pdfFieldId, boundaryHandlingId, timingPool, levelwiseTimingPool, @@ -685,8 +685,8 @@ void run( const shared_ptr< Config > & config, const LatticeModel_T & latticeMod Vector3< real_t >( initVelocity, real_c(0), real_c(0) ), real_t(1), FieldGhostLayers, field::zyxf ); - typedef typename lbm::Adaptor<LatticeModel_T>::VelocityVector VelocityAdaptor_T; - typedef typename lbm::Adaptor<LatticeModel_T>::Density DensityAdaptor_T; + using VelocityAdaptor_T = typename lbm::Adaptor< LatticeModel_T >::VelocityVector; + using DensityAdaptor_T = typename lbm::Adaptor< LatticeModel_T >::Density; BlockDataID velocityAdaptorId = field::addFieldAdaptor< VelocityAdaptor_T >( blocks, pdfFieldId, "velocity adaptor" ); BlockDataID densityAdaptorId = field::addFieldAdaptor< DensityAdaptor_T >( blocks, pdfFieldId, "density adaptor" ); diff --git a/apps/benchmarks/ForcesOnSphereNearPlaneInShearFlow/ForcesOnSphereNearPlaneInShearFlow.cpp b/apps/benchmarks/ForcesOnSphereNearPlaneInShearFlow/ForcesOnSphereNearPlaneInShearFlow.cpp index 5e0a0b457..895ca85bc 100644 --- a/apps/benchmarks/ForcesOnSphereNearPlaneInShearFlow/ForcesOnSphereNearPlaneInShearFlow.cpp +++ b/apps/benchmarks/ForcesOnSphereNearPlaneInShearFlow/ForcesOnSphereNearPlaneInShearFlow.cpp @@ -80,11 +80,11 @@ using walberla::uint_t; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 4; diff --git a/apps/benchmarks/MotionSingleHeavySphere/MotionSingleHeavySphere.cpp b/apps/benchmarks/MotionSingleHeavySphere/MotionSingleHeavySphere.cpp index 4a137fa7b..f94561e77 100644 --- a/apps/benchmarks/MotionSingleHeavySphere/MotionSingleHeavySphere.cpp +++ b/apps/benchmarks/MotionSingleHeavySphere/MotionSingleHeavySphere.cpp @@ -78,11 +78,11 @@ using walberla::uint_t; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; typedef std::pair< pe::BodyID, real_t > BodyAndVolumeFraction_T; @@ -101,7 +101,7 @@ typedef pe_coupling::CurvedQuadratic< LatticeModel_T, FlagField_T > MEM_MR_T; typedef boost::tuples::tuple< UBB_T, Outlet_T, MEM_BB_T, MEM_CLI_T, MEM_MR_T > BoundaryConditions_T; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; -typedef boost::tuple<pe::Sphere> BodyTypeTuple; +using BodyTypeTuple = boost::tuple<pe::Sphere>; /////////// // FLAGS // @@ -1204,7 +1204,7 @@ int main( int argc, char **argv ) // reconstruct missing PDFs - typedef pe_coupling::SphereNormalExtrapolationDirectionFinder ExtrapolationFinder_T; + using ExtrapolationFinder_T = pe_coupling::SphereNormalExtrapolationDirectionFinder; ExtrapolationFinder_T extrapolationFinder( blocks, bodyFieldID ); typedef pe_coupling::ExtrapolationReconstructor< LatticeModel_T, BoundaryHandling_T, ExtrapolationFinder_T > Reconstructor_T; Reconstructor_T reconstructor( blocks, boundaryHandlingID, pdfFieldID, bodyFieldID, extrapolationFinder, true ); diff --git a/apps/benchmarks/NonUniformGrid/NonUniformGrid.cpp b/apps/benchmarks/NonUniformGrid/NonUniformGrid.cpp index 9bfa2c771..6533faa12 100644 --- a/apps/benchmarks/NonUniformGrid/NonUniformGrid.cpp +++ b/apps/benchmarks/NonUniformGrid/NonUniformGrid.cpp @@ -105,12 +105,12 @@ typedef lbm::D3Q19< lbm::collision_model::D3Q19MRT, false > D3Q19_MRT_INCOMP; template< typename LatticeModel_T > struct Types { - typedef typename LatticeModel_T::Stencil Stencil_T; - typedef lbm::PdfField< LatticeModel_T > PdfField_T; + using Stencil_T = typename LatticeModel_T::Stencil; + using PdfField_T = lbm::PdfField< LatticeModel_T >; }; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; const uint_t FieldGhostLayers = uint_t(4); const uint_t BlockForestLevels = uint_t(4); @@ -443,12 +443,12 @@ class MyBoundaryHandling : public blockforest::AlwaysInitializeBlockDataHandling { public: - typedef typename MyBoundaryTypes< LatticeModel_T >::NoSlip_T NoSlip_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::UBB_T UBB_T; + using NoSlip_T = typename MyBoundaryTypes< LatticeModel_T >::NoSlip_T; + using UBB_T = typename MyBoundaryTypes< LatticeModel_T >::UBB_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::BoundaryConditions_T BoundaryConditions_T; + using BoundaryConditions_T = typename MyBoundaryTypes< LatticeModel_T >::BoundaryConditions_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::BoundaryHandling_T BoundaryHandling_T; + using BoundaryHandling_T = typename MyBoundaryTypes< LatticeModel_T >::BoundaryHandling_T; @@ -473,7 +473,7 @@ template< typename LatticeModel_T > typename MyBoundaryHandling<LatticeModel_T>::BoundaryHandling_T * MyBoundaryHandling<LatticeModel_T>::initialize( IBlock * const block ) { - typedef typename Types<LatticeModel_T>::PdfField_T PdfField_T; + using PdfField_T = typename Types<LatticeModel_T>::PdfField_T; WALBERLA_ASSERT_NOT_NULLPTR( block ); @@ -598,7 +598,7 @@ void addRefinementTimeStep( SweepTimeloop & timeloop, shared_ptr< blockforest::S const bool syncComm, const bool fullComm, const bool linearExplosion, shared_ptr< Sweep_T > & sweep, const std::string & info ) { - typedef typename MyBoundaryHandling< LatticeModel_T >::BoundaryHandling_T BH_T; + using BH_T = typename MyBoundaryHandling< LatticeModel_T >::BoundaryHandling_T; auto ts = lbm::refinement::makeTimeStep< LatticeModel_T, BH_T >( blocks, sweep, pdfFieldId, boundaryHandlingId ); ts->asynchronousCommunication( !syncComm ); @@ -621,7 +621,7 @@ struct AddRefinementTimeStep { if( pure ) { - typedef lbm::SplitPureSweep< LatticeModel_T > Sweep_T; + using Sweep_T = lbm::SplitPureSweep< LatticeModel_T >; auto mySweep = make_shared< Sweep_T >( pdfFieldId ); addRefinementTimeStep< LatticeModel_T, Sweep_T >( timeloop, blocks, pdfFieldId, boundaryHandlingId, timingPool, levelwiseTimingPool, @@ -784,7 +784,7 @@ void run( const shared_ptr< Config > & config, const LatticeModel_T & latticeMod } else { - typedef blockforest::DynamicLevelwiseDiffusionBalance< blockforest::NoPhantomData > DLDB; + using DLDB = blockforest::DynamicLevelwiseDiffusionBalance<blockforest::NoPhantomData>; DLDB balancer( diffusionMaxIterations, diffusionFlowIterations ); if( diffusionMode == 0 ) balancer.setMode( DLDB::DIFFUSION_PUSH ); diff --git a/apps/benchmarks/PeriodicGranularGas/PeriodicGranularGas.cpp b/apps/benchmarks/PeriodicGranularGas/PeriodicGranularGas.cpp index 875b6bd80..db8edbea7 100644 --- a/apps/benchmarks/PeriodicGranularGas/PeriodicGranularGas.cpp +++ b/apps/benchmarks/PeriodicGranularGas/PeriodicGranularGas.cpp @@ -35,7 +35,7 @@ namespace walberla { using namespace walberla::pe; using namespace walberla::timing; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; int main( int argc, char ** argv ) { diff --git a/apps/benchmarks/PoiseuilleChannel/PoiseuilleChannel.cpp b/apps/benchmarks/PoiseuilleChannel/PoiseuilleChannel.cpp index 5b1938bf4..9b8d8e326 100644 --- a/apps/benchmarks/PoiseuilleChannel/PoiseuilleChannel.cpp +++ b/apps/benchmarks/PoiseuilleChannel/PoiseuilleChannel.cpp @@ -127,12 +127,12 @@ typedef lbm::D3Q27< lbm::collision_model::TRT, true, lbm::force_model::SimpleCo template< typename LatticeModel_T > struct Types { - typedef typename LatticeModel_T::Stencil Stencil_T; - typedef lbm::PdfField< LatticeModel_T > PdfField_T; + using Stencil_T = typename LatticeModel_T::Stencil; + using PdfField_T = lbm::PdfField<LatticeModel_T>; }; -typedef walberla::uint16_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint16_t; +using FlagField_T = FlagField<flag_t>; const uint_t FieldGhostLayers = uint_t(4); @@ -478,7 +478,7 @@ template< typename LatticeModel_T > typename MyBoundaryHandling<LatticeModel_T>::BoundaryHandling_T * MyBoundaryHandling<LatticeModel_T>::operator()( IBlock * const block ) const { - typedef typename Types<LatticeModel_T>::PdfField_T PdfField_T; + using PdfField_T = typename Types< LatticeModel_T >::PdfField_T; FlagField_T * flagField = block->getData< FlagField_T >( flagFieldId_ ); PdfField_T * pdfField = block->getData< PdfField_T > ( pdfFieldId_ ); @@ -497,7 +497,7 @@ class CurvedDeltaValueCalculation { public: - typedef typename LatticeModel_T::Stencil Stencil; + using Stencil = typename LatticeModel_T::Stencil; CurvedDeltaValueCalculation( const shared_ptr< StructuredBlockForest > & blocks, const IBlock & block, const Channel & channel ) : blocks_( blocks ), block_( block ), channel_( channel ) {} @@ -587,7 +587,7 @@ class ErrorVTKWriter : public vtk::BlockCellDataWriter< OutputType, 3 > { public: - typedef lbm::PdfField< LatticeModel_T > PdfField_T; + using PdfField_T = lbm::PdfField< LatticeModel_T >; ErrorVTKWriter( const ConstBlockDataID & pdfFieldId, const std::string & id, const Setup & setup ) : vtk::BlockCellDataWriter< OutputType, 3 >( id ), bdid_( pdfFieldId ), pdf_( nullptr ), setup_( setup ) {} @@ -786,8 +786,8 @@ void run( const shared_ptr< Config > & config, const LatticeModel_T & latticeMod Vector3< real_t >( initVelocity, real_c(0), real_c(0) ), real_t(1), FieldGhostLayers, field::zyxf ); - typedef typename lbm::Adaptor<LatticeModel_T>::VelocityVector VelocityAdaptor_T; - typedef typename lbm::Adaptor<LatticeModel_T>::Density DensityAdaptor_T; + using VelocityAdaptor_T = typename lbm::Adaptor< LatticeModel_T >::VelocityVector; + using DensityAdaptor_T = typename lbm::Adaptor< LatticeModel_T >::Density; BlockDataID velocityAdaptorId = field::addFieldAdaptor< VelocityAdaptor_T >( blocks, pdfFieldId, "velocity adaptor" ); BlockDataID densityAdaptorId = field::addFieldAdaptor< DensityAdaptor_T >( blocks, pdfFieldId, "density adaptor" ); @@ -834,7 +834,7 @@ void run( const shared_ptr< Config > & config, const LatticeModel_T & latticeMod shared_ptr<WcTimingPool> refinementTimeStepTiming = make_shared<WcTimingPool>(); shared_ptr<WcTimingPool> refinementTimeStepLevelwiseTiming = make_shared<WcTimingPool>(); - typedef typename MyBoundaryHandling< LatticeModel_T >::BoundaryHandling_T BH_T; + using BH_T = typename MyBoundaryHandling< LatticeModel_T >::BoundaryHandling_T; auto mySweep = lbm::makeCellwiseSweep< LatticeModel_T, FlagField_T >( pdfFieldId, flagFieldId, Fluid_Flag ); auto ts = lbm::refinement::makeTimeStep< LatticeModel_T, BH_T >( blocks, mySweep, pdfFieldId, boundaryHandlingId ); diff --git a/apps/benchmarks/SchaeferTurek/SchaeferTurek.cpp b/apps/benchmarks/SchaeferTurek/SchaeferTurek.cpp index 648f6834a..f936bcebe 100644 --- a/apps/benchmarks/SchaeferTurek/SchaeferTurek.cpp +++ b/apps/benchmarks/SchaeferTurek/SchaeferTurek.cpp @@ -158,12 +158,12 @@ typedef lbm::D3Q27< lbm::collision_model::TRT, true > D3Q27_TRT_COMP; template< typename LatticeModel_T > struct Types { - typedef typename LatticeModel_T::Stencil Stencil_T; - typedef lbm::PdfField< LatticeModel_T > PdfField_T; + using Stencil_T = typename LatticeModel_T::Stencil; + using PdfField_T = lbm::PdfField< LatticeModel_T >; }; -typedef walberla::uint16_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint16_t; +using FlagField_T = FlagField<flag_t>; const uint_t FieldGhostLayers = uint_t(4); @@ -799,17 +799,17 @@ class MyBoundaryHandling : public blockforest::AlwaysInitializeBlockDataHandling { public: - typedef typename MyBoundaryTypes< LatticeModel_T >::NoSlip_T NoSlip_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::Obstacle_T Obstacle_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::Curved_T Curved_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::DynamicUBB_T DynamicUBB_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::Outlet21_T Outlet21_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::Outlet43_T Outlet43_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::PressureOutlet_T PressureOutlet_T; + using NoSlip_T = typename MyBoundaryTypes<LatticeModel_T>::NoSlip_T; + using Obstacle_T = typename MyBoundaryTypes<LatticeModel_T>::Obstacle_T; + using Curved_T = typename MyBoundaryTypes<LatticeModel_T>::Curved_T; + using DynamicUBB_T = typename MyBoundaryTypes<LatticeModel_T>::DynamicUBB_T; + using Outlet21_T = typename MyBoundaryTypes<LatticeModel_T>::Outlet21_T; + using Outlet43_T = typename MyBoundaryTypes<LatticeModel_T>::Outlet43_T; + using PressureOutlet_T = typename MyBoundaryTypes<LatticeModel_T>::PressureOutlet_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::BoundaryConditions_T BoundaryConditions_T; + using BoundaryConditions_T = typename MyBoundaryTypes<LatticeModel_T>::BoundaryConditions_T; - typedef typename MyBoundaryTypes< LatticeModel_T >::BoundaryHandling_T BoundaryHandling_T; + using BoundaryHandling_T = typename MyBoundaryTypes<LatticeModel_T>::BoundaryHandling_T; @@ -837,7 +837,7 @@ template< typename LatticeModel_T > typename MyBoundaryHandling<LatticeModel_T>::BoundaryHandling_T * MyBoundaryHandling<LatticeModel_T>::initialize( IBlock * const block ) { - typedef typename Types<LatticeModel_T>::PdfField_T PdfField_T; + using PdfField_T = typename Types< LatticeModel_T >::PdfField_T; FlagField_T * flagField = block->getData< FlagField_T >( flagFieldId_ ); PdfField_T * pdfField = block->getData< PdfField_T > ( pdfFieldId_ ); @@ -866,7 +866,7 @@ class CurvedDeltaValueCalculation { public: - typedef typename LatticeModel_T::Stencil Stencil; + using Stencil = typename LatticeModel_T::Stencil; CurvedDeltaValueCalculation( const shared_ptr< StructuredBlockForest > & blocks, const IBlock & block, const Cylinder & cylinder ) : blocks_( blocks ), block_( block ), cylinder_( cylinder ) {} @@ -909,7 +909,7 @@ class BoundarySetter { public: - typedef typename MyBoundaryTypes< LatticeModel_T >::BoundaryHandling_T BoundaryHandling_T; + using BoundaryHandling_T = typename MyBoundaryTypes< LatticeModel_T >::BoundaryHandling_T; BoundarySetter( const weak_ptr<StructuredBlockForest> & blockForest, const BlockDataID & boundaryHandlingId, const Setup & setup, const int obstacleBoundary, const int outletType, @@ -1267,7 +1267,7 @@ class Pseudo2DPhantomWeight // used as a 'PhantomBlockForest::PhantomBlockDataAs { public: - typedef uint8_t weight_t; + using weight_t = uint8_t; Pseudo2DPhantomWeight( const weight_t _weight ) : weight_( _weight ) {} @@ -1399,8 +1399,8 @@ class Evaluation { public: - typedef typename Types<LatticeModel_T>::PdfField_T PdfField_T; - typedef typename LatticeModel_T::Stencil Stencil_T; + using PdfField_T = typename Types< LatticeModel_T >::PdfField_T; + using Stencil_T = typename LatticeModel_T::Stencil; Evaluation( const weak_ptr< StructuredBlockStorage > & blocks, const uint_t checkFrequency, const BlockDataID & pdfFieldId, const BlockDataID & flagFieldId, const FlagUID & fluid, const FlagUID & obstacle, @@ -2357,7 +2357,7 @@ void addRefinementTimeStep( SweepTimeloop & timeloop, shared_ptr< blockforest::S const shared_ptr< Evaluation< LatticeModel_T > > & evaluation, const shared_ptr< lbm::TimeTracker > & timeTracker ) { - typedef typename MyBoundaryHandling< LatticeModel_T >::BoundaryHandling_T BH_T; + using BH_T = typename MyBoundaryHandling< LatticeModel_T >::BoundaryHandling_T; auto ts = lbm::refinement::makeTimeStep< LatticeModel_T, BH_T >( blocks, sweep, pdfFieldId, boundaryHandlingId, None, Empty ); ts->asynchronousCommunication( !syncComm ); @@ -2386,7 +2386,7 @@ struct AddRefinementTimeStep { if( pure ) { - typedef lbm::SplitPureSweep< LatticeModel_T > Sweep_T; + using Sweep_T = lbm::SplitPureSweep< LatticeModel_T >; auto mySweep = make_shared< Sweep_T >( pdfFieldId ); addRefinementTimeStep< LatticeModel_T, Sweep_T >( timeloop, blocks, pdfFieldId, boundaryHandlingId, timingPool, levelwiseTimingPool, @@ -2470,7 +2470,7 @@ void run( const shared_ptr< Config > & config, const LatticeModel_T & latticeMod // add density adaptor - typedef typename lbm::Adaptor<LatticeModel_T>::Density DensityAdaptor_T; + using DensityAdaptor_T = typename lbm::Adaptor< LatticeModel_T >::Density; BlockDataID densityAdaptorId = field::addFieldAdaptor< DensityAdaptor_T >( blocks, pdfFieldId, "density adaptor", None, Empty ); // add velocity field + initialize velocity field writer (only used for simulations with an adaptive block structure) diff --git a/apps/benchmarks/UniformGrid/UniformGrid.cpp b/apps/benchmarks/UniformGrid/UniformGrid.cpp index 0f389f121..b08a506b4 100644 --- a/apps/benchmarks/UniformGrid/UniformGrid.cpp +++ b/apps/benchmarks/UniformGrid/UniformGrid.cpp @@ -112,13 +112,13 @@ typedef lbm::D3Q27< lbm::collision_model::D3Q27Cumulant, true > D3Q27_CUMULANT_ template< typename LatticeModel_T > struct Types { - typedef typename LatticeModel_T::Stencil Stencil_T; - typedef typename LatticeModel_T::CommunicationStencil CommunicationStencil_T; - typedef lbm::PdfField< LatticeModel_T > PdfField_T; + using Stencil_T = typename LatticeModel_T::Stencil; + using CommunicationStencil_T = typename LatticeModel_T::CommunicationStencil; + using PdfField_T = lbm::PdfField< LatticeModel_T >; }; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; const uint_t FieldGhostLayers = 1; @@ -368,7 +368,7 @@ template< typename LatticeModel_T > typename MyBoundaryHandling<LatticeModel_T>::BoundaryHandling_T * MyBoundaryHandling<LatticeModel_T>::operator()( IBlock * const block, const StructuredBlockStorage * const storage ) const { - typedef typename Types<LatticeModel_T>::PdfField_T PdfField_T; + using PdfField_T = typename Types< LatticeModel_T >::PdfField_T; WALBERLA_ASSERT_NOT_NULLPTR( block ); WALBERLA_ASSERT_NOT_NULLPTR( storage ); @@ -487,8 +487,8 @@ void MyVTKOutput<LatticeModel_T>::operator()( std::vector< shared_ptr<vtk::Block template< typename LatticeModel_T, class Enable = void > struct AddLB { - typedef typename Types<LatticeModel_T>::PdfField_T PdfField; - typedef typename Types<LatticeModel_T>::CommunicationStencil_T CommunicationStencil; + using PdfField = typename Types< LatticeModel_T >::PdfField_T; + using CommunicationStencil = typename Types< LatticeModel_T >::CommunicationStencil_T; static void add( shared_ptr< blockforest::StructuredBlockForest > & blocks, SweepTimeloop & timeloop, const BlockDataID & pdfFieldId, const BlockDataID & flagFieldId, const BlockDataID & boundaryHandlingId, @@ -551,7 +551,7 @@ struct AddLB { if( pure ) { - typedef lbm::SplitPureSweep< LatticeModel_T > Sweep_T; + using Sweep_T = lbm::SplitPureSweep< LatticeModel_T >; auto sweep = make_shared< Sweep_T >( pdfFieldId ); timeloop.add() << Sweep( lbm::CollideSweep< Sweep_T >( sweep ), "split pure LB sweep (collide)" ); @@ -591,8 +591,8 @@ struct AddLB< LatticeModel_T, typename boost::enable_if_c< boost::mpl::or_< lbm::collision_model::Cumulant_tag > >::value >::type > { - typedef typename Types<LatticeModel_T>::PdfField_T PdfField; - typedef typename Types<LatticeModel_T>::CommunicationStencil_T CommunicationStencil; + using PdfField = typename Types< LatticeModel_T >::PdfField_T; + using CommunicationStencil = typename Types< LatticeModel_T >::CommunicationStencil_T; static void add( shared_ptr< blockforest::StructuredBlockForest > & blocks, SweepTimeloop & timeloop, const BlockDataID & pdfFieldId, const BlockDataID & flagFieldId, const BlockDataID & boundaryHandlingId, @@ -659,7 +659,7 @@ template< typename LatticeModel_T > void run( const shared_ptr< Config > & config, const LatticeModel_T & latticeModel, const bool split, const bool pure, const bool fzyx, const bool fullComm, const bool fused, const bool directComm ) { - typedef typename Types<LatticeModel_T>::PdfField_T PdfField; + using PdfField = typename Types<LatticeModel_T>::PdfField_T; Config::BlockHandle configBlock = config->getBlock( "UniformGrid" ); diff --git a/apps/showcases/BidisperseFluidizedBed/BidisperseFluidizedBedDPM.cpp b/apps/showcases/BidisperseFluidizedBed/BidisperseFluidizedBedDPM.cpp index 13db6651c..16fc1b886 100644 --- a/apps/showcases/BidisperseFluidizedBed/BidisperseFluidizedBedDPM.cpp +++ b/apps/showcases/BidisperseFluidizedBed/BidisperseFluidizedBedDPM.cpp @@ -77,14 +77,14 @@ const uint_t FieldGhostLayers( 1 ); typedef GhostLayerField< Matrix3<real_t>, 1 > TensorField_T; typedef GhostLayerField< Vector3<real_t>, 1 > Vec3Field_T; typedef GhostLayerField< real_t, 1 > ScalarField_T; -typedef lbm::force_model::GuoField< Vec3Field_T > ForceModel_T; +using ForceModel_T = lbm::force_model::GuoField<Vec3Field_T>; typedef lbm::D3Q19< lbm::collision_model::SRTField<ScalarField_T>, false, ForceModel_T > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; // boundary handling typedef lbm::NoSlip< LatticeModel_T, flag_t > NoSlip_T; @@ -1374,7 +1374,7 @@ int main( int argc, char **argv ) { std::function<void(void)> lubricationEvaluationFunction; if( lubricationCutOffDistance > real_t(0) ) { - typedef pe_coupling::discrete_particle_methods::LubricationForceEvaluator LE_T; + using LE_T = pe_coupling::discrete_particle_methods::LubricationForceEvaluator; shared_ptr<LE_T> lubEval = make_shared<LE_T>( blocks, globalBodyStorage, bodyStorageID, viscosity, lubricationCutOffDistance ); lubricationEvaluationFunction = std::bind(&LE_T::operator(), lubEval); } diff --git a/apps/tutorials/lbm/01_BasicLBM.cpp b/apps/tutorials/lbm/01_BasicLBM.cpp index 0633ec001..1380a1f10 100644 --- a/apps/tutorials/lbm/01_BasicLBM.cpp +++ b/apps/tutorials/lbm/01_BasicLBM.cpp @@ -33,14 +33,14 @@ namespace walberla { -typedef lbm::D2Q9< lbm::collision_model::SRT > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef LatticeModel_T::CommunicationStencil CommunicationStencil_T; +using LatticeModel_T = lbm::D2Q9<lbm::collision_model::SRT>; +using Stencil_T = LatticeModel_T::Stencil; +using CommunicationStencil_T = LatticeModel_T::CommunicationStencil; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; diff --git a/apps/tutorials/lbm/02_BasicLBM_ExemplaryExtensions.cpp b/apps/tutorials/lbm/02_BasicLBM_ExemplaryExtensions.cpp index 8478a086a..77aea9d87 100644 --- a/apps/tutorials/lbm/02_BasicLBM_ExemplaryExtensions.cpp +++ b/apps/tutorials/lbm/02_BasicLBM_ExemplaryExtensions.cpp @@ -34,13 +34,13 @@ namespace walberla { typedef lbm::D2Q9< lbm::collision_model::SRT, false, lbm::force_model::SimpleConstant > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef LatticeModel_T::CommunicationStencil CommunicationStencil_T; +using Stencil_T = LatticeModel_T::Stencil; +using CommunicationStencil_T = LatticeModel_T::CommunicationStencil; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; diff --git a/apps/tutorials/lbm/03_LBLidDrivenCavity.cpp b/apps/tutorials/lbm/03_LBLidDrivenCavity.cpp index 6327603fb..e28259f8d 100644 --- a/apps/tutorials/lbm/03_LBLidDrivenCavity.cpp +++ b/apps/tutorials/lbm/03_LBLidDrivenCavity.cpp @@ -63,15 +63,15 @@ namespace walberla { // TYPEDEFS // ////////////// -typedef lbm::D3Q19< lbm::collision_model::SRT > LatticeModel_T; // the LB lattice model - here: D3Q19, SRT, incompressible, no additional forces -typedef LatticeModel_T::Stencil Stencil_T; // just the D3Q19 stencil without LB specific information -typedef LatticeModel_T::CommunicationStencil CommunicationStencil_T; // the stencil that is needed for the communication: This stencil determines which +using LatticeModel_T = lbm::D3Q19<lbm::collision_model::SRT>; // the LB lattice model - here: D3Q19, SRT, incompressible, no additional forces +using Stencil_T = LatticeModel_T::Stencil; // just the D3Q19 stencil without LB specific information +using CommunicationStencil_T = LatticeModel_T::CommunicationStencil; // the stencil that is needed for the communication: This stencil determines which // neighbor blocks are involved during the communication. -typedef lbm::PdfField< LatticeModel_T > PdfField_T; // type of the PDF field that stores the 19 distribution functions +using PdfField_T = lbm::PdfField<LatticeModel_T>; // type of the PDF field that stores the 19 distribution functions -typedef walberla::uint8_t flag_t; // each flag consists of an 8 bit value and therefore can distinguish between 8 different markers/flags -typedef FlagField< flag_t > FlagField_T; // the flag field: used for marking cells as fluid or obstacle cells +using flag_t = walberla::uint8_t; // each flag consists of an 8 bit value and therefore can distinguish between 8 different markers/flags +using FlagField_T = FlagField<flag_t>; // the flag field: used for marking cells as fluid or obstacle cells // (also used for distinguishing between different boundary conditions // -> every boundary condition possesses its own, unique flag) diff --git a/apps/tutorials/pde/01_SolvingPDE.cpp b/apps/tutorials/pde/01_SolvingPDE.cpp index 261a44b4d..55eb90fb2 100644 --- a/apps/tutorials/pde/01_SolvingPDE.cpp +++ b/apps/tutorials/pde/01_SolvingPDE.cpp @@ -39,7 +39,7 @@ namespace walberla { typedef GhostLayerField<real_t,1> ScalarField; -typedef stencil::D2Q5 Stencil_T; +using Stencil_T = stencil::D2Q5; // function to initialize the boundaries of the source and destination fields diff --git a/apps/tutorials/pde/02_HeatEquation.cpp b/apps/tutorials/pde/02_HeatEquation.cpp index 0f4e00285..931644c34 100644 --- a/apps/tutorials/pde/02_HeatEquation.cpp +++ b/apps/tutorials/pde/02_HeatEquation.cpp @@ -43,7 +43,7 @@ namespace walberla { typedef GhostLayerField<real_t,1> ScalarField; -typedef stencil::D2Q5 Stencil_T; +using Stencil_T = stencil::D2Q5; diff --git a/apps/tutorials/pde/03_HeatEquation_Extensions.cpp b/apps/tutorials/pde/03_HeatEquation_Extensions.cpp index 40e60a051..15d8859c1 100644 --- a/apps/tutorials/pde/03_HeatEquation_Extensions.cpp +++ b/apps/tutorials/pde/03_HeatEquation_Extensions.cpp @@ -44,7 +44,7 @@ namespace walberla { typedef GhostLayerField<real_t,1> ScalarField; -typedef stencil::D2Q5 Stencil_T; +using Stencil_T = stencil::D2Q5; diff --git a/src/blockforest/loadbalancing/StaticParMetis.cpp b/src/blockforest/loadbalancing/StaticParMetis.cpp index 34f83aca8..5853cdf1e 100644 --- a/src/blockforest/loadbalancing/StaticParMetis.cpp +++ b/src/blockforest/loadbalancing/StaticParMetis.cpp @@ -48,7 +48,7 @@ T * ptr( std::vector<T> & v ) return &( v.front() ); } -typedef uint_t idx_t; +using idx_t = uint_t; uint_t StaticLevelwiseParMetis::operator()( SetupBlockForest & forest, const uint_t numberOfProcesses, const memory_t /*perProcessMemoryLimit*/ ) const diff --git a/src/geometry/structured/extern/lodepng.cpp b/src/geometry/structured/extern/lodepng.cpp index 3355007e4..7bc845577 100644 --- a/src/geometry/structured/extern/lodepng.cpp +++ b/src/geometry/structured/extern/lodepng.cpp @@ -2921,7 +2921,7 @@ static void addColorBits(unsigned char* out, size_t index, unsigned bits, unsign else out[index * bits / 8] |= in; } -typedef struct ColorTree ColorTree; +using ColorTree = struct ColorTree; /* One node of a color tree diff --git a/src/pe/Materials.cpp b/src/pe/Materials.cpp index b66e115f0..1f82e7fa6 100644 --- a/src/pe/Materials.cpp +++ b/src/pe/Materials.cpp @@ -162,7 +162,7 @@ MaterialID createMaterial( const std::string& name, real_t density, real_t cor, real_t csf, real_t cdf, real_t poisson, real_t young, real_t stiffness, real_t dampingN, real_t dampingT ) { - typedef Material M; + using M = Material; // Checking the material name Materials::const_iterator begin( M::materials_.begin() ); diff --git a/src/pe_coupling/utility/TimeStep.cpp b/src/pe_coupling/utility/TimeStep.cpp index 79a9d85d0..a85fb0de3 100644 --- a/src/pe_coupling/utility/TimeStep.cpp +++ b/src/pe_coupling/utility/TimeStep.cpp @@ -49,7 +49,7 @@ void TimeStep::operator()() // generate map from all known bodies (process local) to total forces/torques // this has to be done on a block-local basis, since the same body could reside on several blocks from this process - typedef domain_decomposition::IBlockID::IDType BlockID_T; + using BlockID_T = domain_decomposition::IBlockID::IDType; std::map< BlockID_T, std::map< walberla::id_t, std::array< real_t, 6 > > > forceTorqueMap; for( auto blockIt = blockStorage_->begin(); blockIt != blockStorage_->end(); ++blockIt ) diff --git a/tests/boundary/BoundaryHandling.cpp b/tests/boundary/BoundaryHandling.cpp index df06f25f3..dbc83e1fe 100644 --- a/tests/boundary/BoundaryHandling.cpp +++ b/tests/boundary/BoundaryHandling.cpp @@ -42,9 +42,9 @@ namespace walberla { -typedef uint8_t flag_t; +using flag_t = uint8_t; -typedef FlagField< flag_t > FlagField_T; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< uint_t, stencil::D3Q27::Size > WorkField_T; typedef GhostLayerField< uint_t, 1 > FactorField_T; diff --git a/tests/core/math/GenericAABBTest.cpp b/tests/core/math/GenericAABBTest.cpp index 9194c0ba8..e27731aae 100644 --- a/tests/core/math/GenericAABBTest.cpp +++ b/tests/core/math/GenericAABBTest.cpp @@ -36,7 +36,7 @@ using math::GenericAABB; template< typename T > void testEmptyAABB( const GenericAABB< T > & aabb ) { - typedef Vector3< T > VecT; + using VecT = Vector3<T>; WALBERLA_CHECK_EQUAL( aabb.minCorner(), VecT( T(0), T(0), T(0) ) ); WALBERLA_CHECK_EQUAL( aabb.maxCorner(), VecT( T(0), T(0), T(0) ) ); @@ -122,7 +122,7 @@ void testNonEmptyAABB( const GenericAABB< T > & aabb ) template< typename T > void testAnyAABB( const GenericAABB< T > & aabb ) { - typedef Vector3< T > VecT; + using VecT = Vector3<T>; WALBERLA_CHECK_IDENTICAL( aabb.minCorner()[0], aabb.xMin() ); @@ -274,7 +274,7 @@ void testAnyAABB( const GenericAABB< T > & aabb ) template< typename T > void testFixedAABB() { - typedef Vector3< T > VecT; + using VecT = Vector3<T>; GenericAABB<T> aabb0; testEmptyAABB( aabb0 ); @@ -330,7 +330,7 @@ void testFixedAABB() template< typename T > void testConstructors( const T x0, const T y0, const T z0, const T x1, const T y1, const T z1 ) { - typedef Vector3< T > VecT; + using VecT = Vector3<T>; { GenericAABB< T > refAABB; diff --git a/tests/core/math/PlaneTest.cpp b/tests/core/math/PlaneTest.cpp index 73e7d56c7..12b1f32d0 100644 --- a/tests/core/math/PlaneTest.cpp +++ b/tests/core/math/PlaneTest.cpp @@ -36,10 +36,10 @@ using math::Plane; template < typename scalar_t > struct RandomPointGenerator { - typedef walberla::Vector3<scalar_t> vector_t; + using vector_t = walberla::Vector3<scalar_t>; typedef std::mersenne_twister_engine< walberla::uint32_t, 32, 351, 175, 19, 0xccab8ee7, 11, 0xffffffff, 7, 0x31b6ab00, 15, 0xffe50000, 17, 0xa37d3c92 > mt11213b; - typedef mt11213b RandomNumberEngine; - typedef std::normal_distribution<scalar_t> NormalDistribution; + using RandomNumberEngine = mt11213b; + using NormalDistribution = std::normal_distribution<scalar_t>; RandomPointGenerator( const vector_t & mu, const vector_t & sigma ) { @@ -99,7 +99,7 @@ int main(int argc, char * argv[]) mpi::Environment mpiEnv( argc, argv ); - typedef Vector3<real_t> Vec3Real; + using Vec3Real = Vector3<real_t>; Plane p( Vec3Real( real_t(0), real_t(0), real_t(0) ), Vec3Real( real_t(1), real_t(0), real_t(0) ) ); diff --git a/tests/core/mpi/BufferSystemTest.cpp b/tests/core/mpi/BufferSystemTest.cpp index 358f801c4..a57d24123 100644 --- a/tests/core/mpi/BufferSystemTest.cpp +++ b/tests/core/mpi/BufferSystemTest.cpp @@ -41,7 +41,7 @@ using namespace std::literals::chrono_literals; -typedef std::mt19937 base_generator_type; +using base_generator_type = std::mt19937; /** * Utility function for sleeping a random time diff --git a/tests/core/selectable/SetSelectableObjectTest.cpp b/tests/core/selectable/SetSelectableObjectTest.cpp index 484050711..7e3ffec4a 100644 --- a/tests/core/selectable/SetSelectableObjectTest.cpp +++ b/tests/core/selectable/SetSelectableObjectTest.cpp @@ -41,7 +41,7 @@ int main( int /*argc*/, char** /*argv*/ ) { debug::enterTestMode(); - typedef Set<size_t> A; + using A = Set<size_t>; selectable::SetSelectableObject< std::string, size_t > container; diff --git a/tests/field/FieldTiming.cpp b/tests/field/FieldTiming.cpp index 8017e48c3..4eea53a33 100644 --- a/tests/field/FieldTiming.cpp +++ b/tests/field/FieldTiming.cpp @@ -197,7 +197,7 @@ double initFieldRandom(DoubleField & field) return sum; } -typedef std::function<double (const DoubleField & field)> Func; +using Func = std::function<double (const DoubleField &)>; void timeFunction( WcTimer & timer, Func f, const DoubleField & field, double sum, double epsilon, int nrExecutions=30 ) { for(int i=0 ; i < nrExecutions; ++i) diff --git a/tests/field/FlagFieldTest.cpp b/tests/field/FlagFieldTest.cpp index ce5887c5b..97b9d382e 100644 --- a/tests/field/FlagFieldTest.cpp +++ b/tests/field/FlagFieldTest.cpp @@ -119,7 +119,7 @@ void shallowCopyTest() { // Test shallow copy - typedef FlagField<wlb::uint8_t> FField; + using FField = FlagField<wlb::uint8_t>; FField ff ( 3,3,3,1 ); ff.registerFlag("FirstFlag"); @@ -152,7 +152,7 @@ void shallowCopyTest() void printingTest() { - typedef FlagField<wlb::uint8_t> FField; + using FField = FlagField<wlb::uint8_t>; FField ff ( 3,3,3,1 ); auto ns = ff.registerFlag("NoSlip"); auto fs = ff.registerFlag("FreeSlip"); @@ -172,7 +172,7 @@ void printingTest() void neighborhoodTest() { - typedef FlagField<wlb::uint8_t> FField; + using FField = FlagField<wlb::uint8_t>; FField ff ( 3,3,3,1 ); auto i = ff.registerFlag("Interface"); auto l = ff.registerFlag("Liquid"); diff --git a/tests/field/adaptors/AdaptorTest.cpp b/tests/field/adaptors/AdaptorTest.cpp index bcfc43efd..109c348e3 100644 --- a/tests/field/adaptors/AdaptorTest.cpp +++ b/tests/field/adaptors/AdaptorTest.cpp @@ -43,9 +43,9 @@ namespace walberla { -typedef lbm::D3Q19< lbm::collision_model::SRT > LatticeModel_T; +using LatticeModel_T = lbm::D3Q19<lbm::collision_model::SRT>; -typedef lbm::PdfField< LatticeModel_T > PdfField; +using PdfField = lbm::PdfField<LatticeModel_T>; typedef GhostLayerField<real_t,1 > ScalarField; typedef GhostLayerField<Vector3<real_t>,1 > VectorField; @@ -54,9 +54,9 @@ template<typename Field_T> class DoubledValueOfField { public: - typedef Field_T basefield_t; - typedef typename Field_T::const_base_iterator basefield_iterator; - typedef typename Field_T::value_type value_type; + using basefield_t = Field_T; + using basefield_iterator = typename Field_T::const_base_iterator; + using value_type = typename Field_T::value_type; static_assert( basefield_t::F_SIZE >= 2, "Only for fields with F_SIZE >=2 " ); @@ -84,7 +84,7 @@ void iteratorTest() GhostLayerField<real_t, 2> field ( 4, 4, 3, 2, MAGIC_SRC ); // adapter reduces field to have only one f and one ghost layer - typedef DoubledValueOfField< decltype(field) > Functor; + using Functor = DoubledValueOfField<decltype(field)>; field::GhostLayerFieldAdaptor<Functor, 1 > adaptor ( field ); uint_t ctr = 0; diff --git a/tests/field/distributors/DistributionTest.cpp b/tests/field/distributors/DistributionTest.cpp index 0be91bc26..daf4784ba 100644 --- a/tests/field/distributors/DistributionTest.cpp +++ b/tests/field/distributors/DistributionTest.cpp @@ -38,8 +38,8 @@ using namespace walberla; const uint_t FieldGhostLayers( 1 ); -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< real_t, 1> ScalarField_T; typedef GhostLayerField< Vector3<real_t>, 1> Vec3Field_T; diff --git a/tests/field/interpolators/FieldInterpolationTest.cpp b/tests/field/interpolators/FieldInterpolationTest.cpp index 119322156..3571c3fd9 100644 --- a/tests/field/interpolators/FieldInterpolationTest.cpp +++ b/tests/field/interpolators/FieldInterpolationTest.cpp @@ -38,8 +38,8 @@ namespace field_interpolation_tests { const uint_t FieldGhostLayers( 1 ); -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< real_t, 1> ScalarField_T; typedef GhostLayerField< Vector3<real_t>, 1> Vec3Field_T; diff --git a/tests/geometry/Functions.cpp b/tests/geometry/Functions.cpp index f4341fae6..83da9eac2 100644 --- a/tests/geometry/Functions.cpp +++ b/tests/geometry/Functions.cpp @@ -27,7 +27,7 @@ using namespace walberla; using namespace walberla::geometry; -typedef math::Vector3<real_t> Vec3; +using Vec3 = math::Vector3<real_t>; int main( int argc, char** argv ) { diff --git a/tests/geometry/VoxelFileTest.cpp b/tests/geometry/VoxelFileTest.cpp index e93b1cfa1..726616dc1 100644 --- a/tests/geometry/VoxelFileTest.cpp +++ b/tests/geometry/VoxelFileTest.cpp @@ -293,7 +293,7 @@ void runTests(const std::string & filename, size_t xSize, size_t ySize, size_t z data.clear(); - typedef boost::multi_array_types::index bindex; + using bindex = boost::multi_array_types::index; boost::multi_array<T, 3> reference(boost::extents[walberla::numeric_cast<bindex>(zSize)][walberla::numeric_cast<bindex>(ySize)][walberla::numeric_cast<bindex>(xSize)]); makeRandomMultiArray(reference); diff --git a/tests/gui/GuiPdfView.cpp b/tests/gui/GuiPdfView.cpp index e09f74f8d..279db04f8 100644 --- a/tests/gui/GuiPdfView.cpp +++ b/tests/gui/GuiPdfView.cpp @@ -40,7 +40,7 @@ namespace walberla { typedef GhostLayerField<real_t,19> PdfField; typedef GhostLayerField<real_t,1> ScalarField; typedef GhostLayerField<Vector3<real_t>,1 > VectorField; -typedef FlagField<walberla::uint32_t > FField; +using FField = FlagField<walberla::uint32_t>; int main(int argc, char **argv) diff --git a/tests/gui/SimpleGuiRun.cpp b/tests/gui/SimpleGuiRun.cpp index c04272d4e..cb8d39af5 100644 --- a/tests/gui/SimpleGuiRun.cpp +++ b/tests/gui/SimpleGuiRun.cpp @@ -46,9 +46,9 @@ namespace walberla { typedef GhostLayerField<real_t,19> PdfField; typedef GhostLayerField<real_t,1> ScalarField; typedef GhostLayerField<Vector3<real_t>,1 > VectorField; -typedef FlagField<walberla::uint32_t > FField; +using FField = FlagField<walberla::uint32_t>; -typedef lbm::D3Q19<lbm::collision_model::SRT> LatticeModel; +using LatticeModel = lbm::D3Q19<lbm::collision_model::SRT>; int main(int argc, char **argv ) diff --git a/tests/lbm/BoundaryHandlingCommunication.cpp b/tests/lbm/BoundaryHandlingCommunication.cpp index d8e3a7c82..781b7ca9c 100644 --- a/tests/lbm/BoundaryHandlingCommunication.cpp +++ b/tests/lbm/BoundaryHandlingCommunication.cpp @@ -65,8 +65,8 @@ namespace walberla{ -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; const FlagUID Fluid_Flag( "fluid" ); const FlagUID UBB_Flag( "velocity bounce back" ); @@ -108,7 +108,7 @@ template< typename LatticeModel_T > typename MyBoundaryHandling<LatticeModel_T>::BoundaryHandling_T * MyBoundaryHandling<LatticeModel_T>::operator()( IBlock * const block, const StructuredBlockStorage * const storage ) const { - typedef lbm::PdfField<LatticeModel_T> PdfField_T; + using PdfField_T = lbm::PdfField< LatticeModel_T >; WALBERLA_ASSERT_NOT_NULLPTR( block ); WALBERLA_ASSERT_NOT_NULLPTR( storage ); @@ -267,7 +267,7 @@ int main( int argc, char ** argv ) // D3Q19 // /////////// - typedef lbm::D3Q19< lbm::collision_model::TRT > D3Q19_TRT_COMP; + using D3Q19_TRT_COMP = lbm::D3Q19<lbm::collision_model::TRT>; D3Q19_TRT_COMP d3q19comp = D3Q19_TRT_COMP( lbm::collision_model::TRT::constructWithMagicNumber( GlobalOmega ) ); BlockDataID pdfFieldId1 = lbm::addPdfFieldToStorage( blocks, "pdf field (D3Q19 with ghosts set)", d3q19comp ); @@ -315,7 +315,7 @@ int main( int argc, char ** argv ) // D3Q27 // /////////// - typedef lbm::D3Q27< lbm::collision_model::TRT > D3Q27_TRT_COMP; + using D3Q27_TRT_COMP = lbm::D3Q27<lbm::collision_model::TRT>; D3Q27_TRT_COMP d3q27comp = D3Q27_TRT_COMP( lbm::collision_model::TRT::constructWithMagicNumber( GlobalOmega ) ); BlockDataID pdfFieldId3 = lbm::addPdfFieldToStorage( blocks, "pdf field (D3Q27 with ghosts set)", d3q27comp ); diff --git a/tests/lbm/DiffusionTest.cpp b/tests/lbm/DiffusionTest.cpp index 4bed8c474..c1aa84508 100644 --- a/tests/lbm/DiffusionTest.cpp +++ b/tests/lbm/DiffusionTest.cpp @@ -84,12 +84,12 @@ namespace walberla { -typedef uint8_t flag_t; -typedef Vector3< real_t > vec3_t; +using flag_t = uint8_t; +using vec3_t = Vector3<real_t>; typedef GhostLayerField< real_t, 1 > ScalarField; typedef GhostLayerField< vec3_t, 1 > VectorField; -typedef FlagField < flag_t > MyFlagField; +using MyFlagField = FlagField<flag_t>; typedef lbm::D3Q19< lbm::collision_model::SRT, true, lbm::force_model::Correction<VectorField>, 1 > AdvDiffLatticeModel_Corr; typedef lbm::D3Q19< lbm::collision_model::SRT, true, lbm::force_model::None, 1 > AdvDiffLatticeModel_None; @@ -170,8 +170,8 @@ template< typename AdvDiffLatticeModel > int run( int argc, char **argv ) { // typedefs - typedef typename AdvDiffLatticeModel::Stencil AdvDiffStencil; - typedef lbm::PdfField< AdvDiffLatticeModel > AdvDiffPDFField; + using AdvDiffStencil = typename AdvDiffLatticeModel::Stencil; + using AdvDiffPDFField = lbm::PdfField<AdvDiffLatticeModel>; #ifdef _OPENMP omp_set_num_threads( std::max( omp_get_num_threads()>>1, 4 ) ); diff --git a/tests/lbm/Poiseuille.cpp b/tests/lbm/Poiseuille.cpp index 7f74d5eac..fecccb13d 100644 --- a/tests/lbm/Poiseuille.cpp +++ b/tests/lbm/Poiseuille.cpp @@ -88,7 +88,7 @@ namespace walberla { -typedef walberla::uint8_t flag_t; +using flag_t = walberla::uint8_t; // Compressible SRT with constant force using lbm::collision_model::SRT; @@ -96,8 +96,8 @@ using lbm::force_model::GuoConstant; typedef lbm::D3Q19< SRT, true, GuoConstant> LM; // Fields -typedef lbm::PdfField<LM> PdfField; -typedef FlagField<flag_t> FField; +using PdfField = lbm::PdfField<LM>; +using FField = FlagField<flag_t>; typedef GhostLayerField<Vector3<real_t>,1 > VectorField; typedef GhostLayerField<real_t,1 > ScalarField; diff --git a/tests/lbm/SweepEquivalenceTest.cpp b/tests/lbm/SweepEquivalenceTest.cpp index dbd98b1fe..2c8f0e15a 100644 --- a/tests/lbm/SweepEquivalenceTest.cpp +++ b/tests/lbm/SweepEquivalenceTest.cpp @@ -72,8 +72,8 @@ namespace walberla { -typedef walberla::uint64_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint64_t; +using FlagField_T = FlagField<flag_t>; const FlagUID Fluid_Flag( "fluid" ); const FlagUID UBB_Flag( "velocity bounce back" ); @@ -119,7 +119,7 @@ template< typename LatticeModel_T > typename MyBoundaryHandling<LatticeModel_T>::BoundaryHandling_T * MyBoundaryHandling<LatticeModel_T>::operator()( IBlock * const block, const StructuredBlockStorage * const storage ) const { - typedef lbm::PdfField<LatticeModel_T> PdfField_T; + using PdfField_T = lbm::PdfField< LatticeModel_T >; WALBERLA_ASSERT_NOT_NULLPTR( block ); WALBERLA_ASSERT_NOT_NULLPTR( storage ); @@ -256,8 +256,8 @@ struct AddTRTTest< LatticeModel_T, typename boost::enable_if_c< boost::is_same< template< typename LatticeModel1_T, typename LatticeModel2_T > void check( const shared_ptr< StructuredBlockForest > & blocks, const BlockDataID & fieldId1, const BlockDataID & fieldId2 ) { - typedef lbm::PdfField< LatticeModel1_T > PdfField1_T; - typedef lbm::PdfField< LatticeModel2_T > PdfField2_T; + using PdfField1_T = lbm::PdfField< LatticeModel1_T >; + using PdfField2_T = lbm::PdfField< LatticeModel2_T >; for( auto block = blocks->begin(); block != blocks->end(); ++block ) { diff --git a/tests/lbm/boundary/DiffusionDirichlet.cpp b/tests/lbm/boundary/DiffusionDirichlet.cpp index 807dd39ff..33670cb3b 100644 --- a/tests/lbm/boundary/DiffusionDirichlet.cpp +++ b/tests/lbm/boundary/DiffusionDirichlet.cpp @@ -84,17 +84,17 @@ namespace walberla { -typedef uint8_t flag_t; -typedef Vector3< real_t > vec3_t; +using flag_t = uint8_t; +using vec3_t = Vector3<real_t>; typedef lbm::D3Q19< lbm::collision_model::SRT, true, lbm::force_model::None, 1 > LM; -typedef LM::CommunicationStencil CommunicationStencil; +using CommunicationStencil = LM::CommunicationStencil; -typedef lbm::PdfField < LM > MyPdfField; +using MyPdfField = lbm::PdfField<LM>; typedef GhostLayerField< real_t, 1 > ScalarField; typedef GhostLayerField< Vector3<real_t>, 1> VectorField; -typedef FlagField < flag_t > MyFlagField; +using MyFlagField = FlagField<flag_t>; typedef lbm::DefaultDiffusionBoundaryHandlingFactory< LM, MyFlagField > MyBoundaryHandling; @@ -104,7 +104,7 @@ const FlagUID& getFluidFlag(){ static FlagUID uid( "Fluid" ); return uid; } class PlugFlow { public: - typedef std::complex<real_t> cplx_t; + using cplx_t = std::complex<real_t>; PlugFlow( real_t L, real_t H, real_t u, real_t k ) : period_( real_t(2)*math::PI/L ), diff --git a/tests/lbm/boundary/SimpleDiffusionDirichlet.cpp b/tests/lbm/boundary/SimpleDiffusionDirichlet.cpp index 1d4e95008..30c95b82a 100644 --- a/tests/lbm/boundary/SimpleDiffusionDirichlet.cpp +++ b/tests/lbm/boundary/SimpleDiffusionDirichlet.cpp @@ -93,11 +93,11 @@ typedef GhostLayerField< Vector3<real_t>, 1 > VectorField; typedef lbm::D3Q19< lbm::collision_model::SRT, true, lbm::force_model::None, 1 > LM; -typedef LM::CommunicationStencil CommunicationStencil; -typedef lbm::PdfField< LM > MyPdfField; +using CommunicationStencil = LM::CommunicationStencil; +using MyPdfField = lbm::PdfField<LM>; -typedef uint8_t flag_t; -typedef FlagField< flag_t > MyFlagField; +using flag_t = uint8_t; +using MyFlagField = FlagField<flag_t>; typedef lbm::DefaultDiffusionBoundaryHandlingFactory< LM, MyFlagField > MyBoundaryHandling; diff --git a/tests/lbm/boundary/SimplePABTest.cpp b/tests/lbm/boundary/SimplePABTest.cpp index 6b07233df..31bc21a74 100644 --- a/tests/lbm/boundary/SimplePABTest.cpp +++ b/tests/lbm/boundary/SimplePABTest.cpp @@ -62,12 +62,12 @@ namespace walberla { - typedef uint8_t flag_t; + using flag_t = uint8_t; typedef lbm::D3Q19< lbm::collision_model::SRT, false > LatticeModel; - typedef LatticeModel::Stencil Stencil; - typedef LatticeModel::CommunicationStencil CommunicationStencil; - typedef lbm::PdfField< LatticeModel > PDFField; - typedef FlagField< flag_t > MyFlagField; + using Stencil = LatticeModel::Stencil; + using CommunicationStencil = LatticeModel::CommunicationStencil; + using PDFField = lbm::PdfField<LatticeModel>; + using MyFlagField = FlagField<flag_t>; shared_ptr< StructuredBlockForest > makeStructuredBlockStorage( uint_t channelWidth, uint_t channelLength ) diff --git a/tests/lbm/evaluations/PermeabilityTest.cpp b/tests/lbm/evaluations/PermeabilityTest.cpp index 6a0d25cbd..022ad2788 100644 --- a/tests/lbm/evaluations/PermeabilityTest.cpp +++ b/tests/lbm/evaluations/PermeabilityTest.cpp @@ -30,8 +30,8 @@ namespace walberla { -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; enum Scenario { BCC }; @@ -117,7 +117,7 @@ BlockDataID initPdfField( const shared_ptr<StructuredBlockForest> & blocks, real template< > BlockDataID initPdfField< lbm::collision_model::SRT >( const shared_ptr<StructuredBlockForest> & blocks, real_t omega ) { - typedef lbm::D3Q19< lbm::collision_model::SRT > LatticeModel_T; + using LatticeModel_T = lbm::D3Q19<lbm::collision_model::SRT>; LatticeModel_T latticeModel = LatticeModel_T( lbm::collision_model::SRT( omega ) ); return lbm::addPdfFieldToStorage( blocks, "PDF Field (SRT)", latticeModel, Vector3<real_t>(), real_t(1) ); @@ -126,7 +126,7 @@ BlockDataID initPdfField< lbm::collision_model::SRT >( const shared_ptr<Structur template< > BlockDataID initPdfField< lbm::collision_model::TRT >( const shared_ptr<StructuredBlockForest> & blocks, real_t omega ) { - typedef lbm::D3Q19< lbm::collision_model::TRT > LatticeModel_T; + using LatticeModel_T = lbm::D3Q19<lbm::collision_model::TRT>; LatticeModel_T latticeModel = LatticeModel_T( lbm::collision_model::TRT::constructWithMagicNumber( omega ) ); return lbm::addPdfFieldToStorage( blocks, "PDF Field (TRT)", latticeModel, Vector3<real_t>(), real_t(1) ); @@ -135,7 +135,7 @@ BlockDataID initPdfField< lbm::collision_model::TRT >( const shared_ptr<Structur template< > BlockDataID initPdfField< lbm::collision_model::D3Q19MRT >( const shared_ptr<StructuredBlockForest> & blocks, real_t omega ) { - typedef lbm::D3Q19< lbm::collision_model::D3Q19MRT > LatticeModel_T; + using LatticeModel_T = lbm::D3Q19<lbm::collision_model::D3Q19MRT>; LatticeModel_T latticeModel = LatticeModel_T( lbm::collision_model::D3Q19MRT::constructPanWithMagicNumber( omega ) ); return lbm::addPdfFieldToStorage( blocks, "PDF Field (MRT)", latticeModel, Vector3<real_t>(), real_t(1) ); @@ -155,7 +155,7 @@ template< typename LatticeModel_T > BlockDataID initBoundaryHandling( shared_ptr<StructuredBlockForest> & blocks, const BlockDataID & pdfFieldId, const BlockDataID & flagFieldId, const FlagUID & fluid, Setup setup ) { typedef lbm::DefaultBoundaryHandlingFactory< LatticeModel_T, FlagField_T > BHFactory_T; - typedef typename BHFactory_T::BoundaryHandling BoundaryHandling_T; + using BoundaryHandling_T = typename BHFactory_T::BoundaryHandling; BlockDataID boundaryHandlingId = BHFactory_T::addBoundaryHandlingToStorage( blocks, "boundary handling", flagFieldId, pdfFieldId, fluid, Vector3<real_t>(), @@ -207,9 +207,9 @@ BlockDataID initBoundaryHandling( shared_ptr<StructuredBlockForest> & blocks, co template< typename LM_T > int setupAndExecute( Setup setup ) { - typedef lbm::PdfField< LM_T > PdfField_T; + using PdfField_T = lbm::PdfField< LM_T >; typedef lbm::DefaultBoundaryHandlingFactory< LM_T, FlagField_T > BHFactory_T; - typedef typename BHFactory_T::BoundaryHandling BoundaryHandling_T; + using BoundaryHandling_T = typename BHFactory_T::BoundaryHandling; Vector3<uint_t> blockLength; blockLength[0] = setup.length / setup.blocks[0]; diff --git a/tests/lbm/initializer/PdfFieldInitializerTest.cpp b/tests/lbm/initializer/PdfFieldInitializerTest.cpp index 282fbd689..5e8b2ac39 100644 --- a/tests/lbm/initializer/PdfFieldInitializerTest.cpp +++ b/tests/lbm/initializer/PdfFieldInitializerTest.cpp @@ -33,9 +33,9 @@ namespace walberla { -typedef lbm::D3Q19< lbm::collision_model::SRT > LatticeModel_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; -typedef lbm::initializer::PdfFieldInitializer< LatticeModel_T > PdfFieldInitializer_T; +using LatticeModel_T = lbm::D3Q19<lbm::collision_model::SRT>; +using PdfField_T = lbm::PdfField<LatticeModel_T>; +using PdfFieldInitializer_T = lbm::initializer::PdfFieldInitializer<LatticeModel_T>; struct DensityInit diff --git a/tests/lbm/refinement/CommunicationEquivalence.cpp b/tests/lbm/refinement/CommunicationEquivalence.cpp index 9b14c1430..150f78949 100644 --- a/tests/lbm/refinement/CommunicationEquivalence.cpp +++ b/tests/lbm/refinement/CommunicationEquivalence.cpp @@ -72,12 +72,12 @@ namespace walberla{ typedef lbm::D3Q19< lbm::collision_model::SRT, false > LatticeModel_T; //typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; //typedef lbm::D3Q19< lbm::collision_model::D3Q19MRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; +using Stencil_T = LatticeModel_T::Stencil; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; const uint_t FieldGhostLayers = 4; diff --git a/tests/lbm/refinement/NonConstantDiffusion.cpp b/tests/lbm/refinement/NonConstantDiffusion.cpp index dca9d0529..83ac2f989 100644 --- a/tests/lbm/refinement/NonConstantDiffusion.cpp +++ b/tests/lbm/refinement/NonConstantDiffusion.cpp @@ -93,11 +93,11 @@ typedef GhostLayerField< Vector3<real_t>, 1 > VectorField; typedef lbm::D3Q19< lbm::collision_model::SRTField<ScalarField>, true, lbm::force_model::None, 1 > LM; -typedef LM::Stencil Stencil; -typedef lbm::PdfField< LM > MyPdfField; +using Stencil = LM::Stencil; +using MyPdfField = lbm::PdfField<LM>; -typedef uint8_t flag_t; -typedef FlagField< flag_t > MyFlagField; +using flag_t = uint8_t; +using MyFlagField = FlagField<flag_t>; typedef lbm::DefaultDiffusionBoundaryHandlingFactory< LM, MyFlagField > MyBoundaryHandling; diff --git a/tests/lbm/refinement/Uniformity.cpp b/tests/lbm/refinement/Uniformity.cpp index aabd8d6fb..cd6eda7cd 100644 --- a/tests/lbm/refinement/Uniformity.cpp +++ b/tests/lbm/refinement/Uniformity.cpp @@ -78,18 +78,18 @@ using walberla::uint_t; typedef lbm::D3Q19< lbm::collision_model::SRT, false > LatticeModel_T; //typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; //typedef lbm::D3Q19< lbm::collision_model::D3Q19MRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; +using Stencil_T = LatticeModel_T::Stencil; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; const uint_t FieldGhostLayers = 4; // dummy boundary handling typedef lbm::NoSlip< LatticeModel_T, flag_t > NoSlip_T; -typedef boost::tuples::tuple< NoSlip_T > BoundaryConditions_T; +using BoundaryConditions_T = boost::tuples::tuple<NoSlip_T>; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; /////////// diff --git a/tests/mesh/DistributedMeshVTKTest.cpp b/tests/mesh/DistributedMeshVTKTest.cpp index 8b9dcc55a..e69aad05e 100644 --- a/tests/mesh/DistributedMeshVTKTest.cpp +++ b/tests/mesh/DistributedMeshVTKTest.cpp @@ -42,7 +42,7 @@ void test( const std::string & meshFile ) auto aabb = computeAABB( *mesh ); - typedef typename MeshType::Scalar Scalar; + using Scalar = typename MeshType::Scalar; Vector3<Scalar> translation( numeric_cast<Scalar>( aabb.xSize() ) * Scalar(2) * Scalar( MPIManager::instance()->rank() ), Scalar(0), Scalar(0) ); translate( *mesh, translation ); diff --git a/tests/mesh/MeshBlockExclusionTest.cpp b/tests/mesh/MeshBlockExclusionTest.cpp index 60833bf92..7685ac644 100644 --- a/tests/mesh/MeshBlockExclusionTest.cpp +++ b/tests/mesh/MeshBlockExclusionTest.cpp @@ -58,7 +58,7 @@ struct PointInAABB struct AnyPointInAABB { - typedef std::vector< Vector3<real_t> > Points; + using Points = std::vector<Vector3<real_t> >; AnyPointInAABB( const Points & points ) : points_(points) {} diff --git a/tests/mesh/MeshOperationsTest.cpp b/tests/mesh/MeshOperationsTest.cpp index b12d6fb33..91af5d0bf 100644 --- a/tests/mesh/MeshOperationsTest.cpp +++ b/tests/mesh/MeshOperationsTest.cpp @@ -47,7 +47,7 @@ void testCube() { MeshType mesh; - typedef typename MeshType::Scalar Scalar; + using Scalar = typename MeshType::Scalar; readAndBroadcast("cube.obj", mesh); diff --git a/tests/mesh/PeVTKMeshWriterTest.cpp b/tests/mesh/PeVTKMeshWriterTest.cpp index 518f020e7..0c56132e3 100644 --- a/tests/mesh/PeVTKMeshWriterTest.cpp +++ b/tests/mesh/PeVTKMeshWriterTest.cpp @@ -145,8 +145,8 @@ int main( int argc, char ** argv ) std::function<void(void)> syncCall = std::bind( pe::syncNextNeighbors<BodyTuple>, std::ref(*forest), storageID, static_cast<WcTimingTree*>(nullptr), real_c(0.0), false ); - typedef mesh::FloatPolyMesh OutputMeshType; - typedef mesh::pe::DefaultTesselation<OutputMeshType> TesselationType; + using OutputMeshType = mesh::FloatPolyMesh; + using TesselationType = mesh::pe::DefaultTesselation<OutputMeshType>; TesselationType tesselation; mesh::pe::PeVTKMeshWriter<OutputMeshType, TesselationType> writer( forest, storageID, tesselation, "MeshOutput", uint_c(visSpacing) ); diff --git a/tests/mesh/QHullTest.cpp b/tests/mesh/QHullTest.cpp index 5206b9997..65998853e 100644 --- a/tests/mesh/QHullTest.cpp +++ b/tests/mesh/QHullTest.cpp @@ -104,7 +104,7 @@ void test( const std::string & testName, const std::vector<Vector3<real_t>> & po const typename MeshType::Point pointOnFace = mesh.point( *mesh.cfv_begin(fh) ); for(const auto & p : pointCloud) { - typedef typename MeshType::Scalar Scalar; + using Scalar = typename MeshType::Scalar; WALBERLA_CHECK_LESS( (toOpenMeshNumericCast<Scalar>(p) - pointOnFace) | n, real_comparison::Epsilon<Scalar>::value, "Point: " << p << " Face normal: " << n << " v: " << toOpenMeshNumericCast<Scalar>(p) - pointOnFace ); } diff --git a/tests/pde/CGTest.cpp b/tests/pde/CGTest.cpp index b3619d157..eecd1c6a2 100644 --- a/tests/pde/CGTest.cpp +++ b/tests/pde/CGTest.cpp @@ -48,8 +48,8 @@ namespace walberla { typedef GhostLayerField< real_t, 1 > PdeField_T; -typedef stencil::D2Q5 Stencil_T; -typedef pde::CGIteration<Stencil_T>::StencilField_T StencilField_T; +using Stencil_T = stencil::D2Q5; +using StencilField_T = pde::CGIteration<Stencil_T>::StencilField_T; diff --git a/tests/pde/JacobiTest.cpp b/tests/pde/JacobiTest.cpp index 22376f9b9..275cbf8df 100644 --- a/tests/pde/JacobiTest.cpp +++ b/tests/pde/JacobiTest.cpp @@ -51,8 +51,8 @@ namespace walberla { typedef GhostLayerField< real_t, 1 > PdeField_T; -typedef stencil::D2Q5 Stencil_T; -typedef pde::Jacobi<Stencil_T>::StencilField_T StencilField_T; +using Stencil_T = stencil::D2Q5; +using StencilField_T = pde::Jacobi<Stencil_T>::StencilField_T; diff --git a/tests/pde/MGConvergenceTest.cpp b/tests/pde/MGConvergenceTest.cpp index 56065b48a..f9643a83f 100644 --- a/tests/pde/MGConvergenceTest.cpp +++ b/tests/pde/MGConvergenceTest.cpp @@ -49,8 +49,8 @@ namespace walberla { typedef GhostLayerField< real_t, 1 > PdeField_T; -typedef stencil::D3Q7 Stencil_T; -typedef pde::VCycles<Stencil_T>::StencilField_T StencilField_T; +using Stencil_T = stencil::D3Q7; +using StencilField_T = pde::VCycles<Stencil_T>::StencilField_T; diff --git a/tests/pde/MGTest.cpp b/tests/pde/MGTest.cpp index 648d83b38..275a2ecc1 100644 --- a/tests/pde/MGTest.cpp +++ b/tests/pde/MGTest.cpp @@ -50,8 +50,8 @@ namespace walberla { typedef GhostLayerField< real_t, 1 > PdeField_T; -typedef stencil::D3Q7 Stencil_T; -typedef pde::VCycles<Stencil_T>::StencilField_T StencilField_T; +using Stencil_T = stencil::D3Q7; +using StencilField_T = pde::VCycles<Stencil_T>::StencilField_T; diff --git a/tests/pde/RBGSTest.cpp b/tests/pde/RBGSTest.cpp index f289a4ca8..c3a922ea1 100644 --- a/tests/pde/RBGSTest.cpp +++ b/tests/pde/RBGSTest.cpp @@ -51,8 +51,8 @@ namespace walberla { typedef GhostLayerField< real_t, 1 > PdeField_T; -typedef stencil::D2Q5 Stencil_T; -typedef pde::RBGS<Stencil_T>::StencilField_T StencilField_T; +using Stencil_T = stencil::D2Q5; +using StencilField_T = pde::RBGS<Stencil_T>::StencilField_T; diff --git a/tests/pde/SORTest.cpp b/tests/pde/SORTest.cpp index 46f55ea94..520df1cfa 100644 --- a/tests/pde/SORTest.cpp +++ b/tests/pde/SORTest.cpp @@ -51,8 +51,8 @@ namespace walberla { typedef GhostLayerField< real_t, 1 > PdeField_T; -typedef stencil::D2Q5 Stencil_T; -typedef pde::SOR<Stencil_T>::StencilField_T StencilField_T; +using Stencil_T = stencil::D2Q5; +using StencilField_T = pde::SOR<Stencil_T>::StencilField_T; diff --git a/tests/pe/BodyFlags.cpp b/tests/pe/BodyFlags.cpp index dbd673567..dac328391 100644 --- a/tests/pe/BodyFlags.cpp +++ b/tests/pe/BodyFlags.cpp @@ -37,7 +37,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; int main( int argc, char ** argv ) { diff --git a/tests/pe/BodyIterators.cpp b/tests/pe/BodyIterators.cpp index 48f4bd5d8..e53b44a6a 100644 --- a/tests/pe/BodyIterators.cpp +++ b/tests/pe/BodyIterators.cpp @@ -36,7 +36,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; int main( int argc, char **argv ) { diff --git a/tests/pe/Collision.cpp b/tests/pe/Collision.cpp index c69ac6b06..958b4de97 100644 --- a/tests/pe/Collision.cpp +++ b/tests/pe/Collision.cpp @@ -235,7 +235,7 @@ void CapsuleTest2() void UnionTest() { - typedef Union< boost::tuple<Sphere> > UnionT; + using UnionT = Union<boost::tuple<Sphere> >; UnionT un1(120, 0, Vec3(0,0,0), Vec3(0,0,0), Quat(), false, true, false); UnionT un2(121, 0, Vec3(real_t(1.5),0,0), Vec3(0,0,0), Quat(), false, true, false); auto sp1 = createSphere(&un1, 123, Vec3(0,0,0), 1); diff --git a/tests/pe/DeleteBody.cpp b/tests/pe/DeleteBody.cpp index d552a7426..ea6adfbfc 100644 --- a/tests/pe/DeleteBody.cpp +++ b/tests/pe/DeleteBody.cpp @@ -36,7 +36,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; int main( int argc, char** argv ) { diff --git a/tests/pe/DestroyBody.cpp b/tests/pe/DestroyBody.cpp index f8e33d563..b2deb57fa 100644 --- a/tests/pe/DestroyBody.cpp +++ b/tests/pe/DestroyBody.cpp @@ -34,7 +34,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; int main( int argc, char** argv ) { diff --git a/tests/pe/DynamicRefinement.cpp b/tests/pe/DynamicRefinement.cpp index ef0266270..284949aba 100644 --- a/tests/pe/DynamicRefinement.cpp +++ b/tests/pe/DynamicRefinement.cpp @@ -32,7 +32,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; class ReGrid { diff --git a/tests/pe/Marshalling.cpp b/tests/pe/Marshalling.cpp index a5272bfe3..8eaa11069 100644 --- a/tests/pe/Marshalling.cpp +++ b/tests/pe/Marshalling.cpp @@ -38,10 +38,10 @@ namespace walberla { using namespace walberla::pe; using namespace walberla::pe::communication; -typedef boost::tuple<Sphere> UnionTypeTuple; -typedef Union< UnionTypeTuple > UnionT; -typedef UnionT* UnionID; -typedef std::unique_ptr<UnionT> UnionPtr; +using UnionTypeTuple = boost::tuple<Sphere>; +using UnionT = Union<UnionTypeTuple>; +using UnionID = UnionT *; +using UnionPtr = std::unique_ptr<UnionT>; typedef boost::tuple<Box, Capsule, Sphere, Squirmer, UnionT, Ellipsoid> BodyTuple ; diff --git a/tests/pe/ParMetis.cpp b/tests/pe/ParMetis.cpp index f43a92f57..0f66faf31 100644 --- a/tests/pe/ParMetis.cpp +++ b/tests/pe/ParMetis.cpp @@ -45,8 +45,8 @@ class MetisAssignmentFunctor { public: - typedef blockforest::DynamicParMetisBlockInfo PhantomBlockWeight; - typedef blockforest::DynamicParMetisBlockInfoPackUnpack PhantomBlockWeightPackUnpackFunctor; + using PhantomBlockWeight = blockforest::DynamicParMetisBlockInfo; + using PhantomBlockWeightPackUnpackFunctor = blockforest::DynamicParMetisBlockInfoPackUnpack; void operator()( std::vector< std::pair< const PhantomBlock *, walberla::any > > & blockData, const PhantomBlockForest & ) { diff --git a/tests/pe/PeDocumentationSnippets.cpp b/tests/pe/PeDocumentationSnippets.cpp index baf33aa07..d9b3396bb 100644 --- a/tests/pe/PeDocumentationSnippets.cpp +++ b/tests/pe/PeDocumentationSnippets.cpp @@ -48,8 +48,8 @@ using namespace walberla::pe; //! [Definition of Union Types] typedef boost::tuple<Box, Capsule, Sphere> UnionTypeTuple; -typedef Union< UnionTypeTuple > UnionT; -typedef UnionT* UnionID; +using UnionT = Union<UnionTypeTuple>; +using UnionID = UnionT *; //! [Definition of Union Types] //! [Definition BodyTypeTuple] diff --git a/tests/pe/SerializeDeserialize.cpp b/tests/pe/SerializeDeserialize.cpp index 883a15242..9d92831a2 100644 --- a/tests/pe/SerializeDeserialize.cpp +++ b/tests/pe/SerializeDeserialize.cpp @@ -37,7 +37,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; void createDump() { diff --git a/tests/pe/ShadowCopy.cpp b/tests/pe/ShadowCopy.cpp index 8b1e82027..bf3f39c92 100644 --- a/tests/pe/ShadowCopy.cpp +++ b/tests/pe/ShadowCopy.cpp @@ -34,7 +34,7 @@ namespace walberla { using namespace walberla::pe; -typedef Union< boost::tuple<Sphere> > UnionT; +using UnionT = Union<boost::tuple<Sphere> >; typedef boost::tuple<Sphere, UnionT> BodyTuple ; int main( int argc, char** argv ) diff --git a/tests/pe/SimpleCCD.cpp b/tests/pe/SimpleCCD.cpp index 08571dce0..b1388dab5 100644 --- a/tests/pe/SimpleCCD.cpp +++ b/tests/pe/SimpleCCD.cpp @@ -36,7 +36,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; int main( int argc, char** argv ) { diff --git a/tests/pe/SyncEquivalence.cpp b/tests/pe/SyncEquivalence.cpp index 0ebfe4778..f15dcd4c7 100644 --- a/tests/pe/SyncEquivalence.cpp +++ b/tests/pe/SyncEquivalence.cpp @@ -44,7 +44,7 @@ namespace walberla { using namespace walberla::pe; using namespace walberla::timing; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; struct BodyData { diff --git a/tests/pe/Synchronization.cpp b/tests/pe/Synchronization.cpp index 180ca7747..646e6d239 100644 --- a/tests/pe/Synchronization.cpp +++ b/tests/pe/Synchronization.cpp @@ -36,7 +36,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; void checkSphere(StructuredBlockForest& forest, BlockDataID storageID, walberla::id_t sid, Sphere& ref, const Vec3& newPos) { diff --git a/tests/pe/SynchronizationDelete.cpp b/tests/pe/SynchronizationDelete.cpp index 29645627c..6b649c298 100644 --- a/tests/pe/SynchronizationDelete.cpp +++ b/tests/pe/SynchronizationDelete.cpp @@ -36,7 +36,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; void integrate(StructuredBlockForest& forest, BlockDataID storageID, const real_t dt) { diff --git a/tests/pe/SynchronizationLargeBody.cpp b/tests/pe/SynchronizationLargeBody.cpp index 158d56a30..3846a2b55 100644 --- a/tests/pe/SynchronizationLargeBody.cpp +++ b/tests/pe/SynchronizationLargeBody.cpp @@ -35,7 +35,7 @@ namespace walberla { using namespace walberla::pe; -typedef boost::tuple<Sphere> BodyTuple ; +using BodyTuple = boost::tuple<Sphere> ; // checkSphere without dx void checkSphere(StructuredBlockForest& forest, BlockDataID storageID, walberla::id_t sid, SphereID ref, const Vec3& newPos) diff --git a/tests/pe/Union.cpp b/tests/pe/Union.cpp index bd780f28f..91db8412e 100644 --- a/tests/pe/Union.cpp +++ b/tests/pe/Union.cpp @@ -44,7 +44,7 @@ namespace walberla { using namespace walberla::pe; -typedef Union< boost::tuple<Sphere> > UnionType ; +using UnionType = Union<boost::tuple<Sphere> > ; typedef boost::tuple<Sphere, Plane, UnionType> BodyTuple ; void SnowManFallingOnPlane() diff --git a/tests/pe_coupling/discrete_particle_methods/HinderedSettlingDynamicsDPM.cpp b/tests/pe_coupling/discrete_particle_methods/HinderedSettlingDynamicsDPM.cpp index f8931f9f8..8730491ec 100644 --- a/tests/pe_coupling/discrete_particle_methods/HinderedSettlingDynamicsDPM.cpp +++ b/tests/pe_coupling/discrete_particle_methods/HinderedSettlingDynamicsDPM.cpp @@ -75,19 +75,19 @@ const uint_t FieldGhostLayers( 1 ); typedef GhostLayerField< Matrix3<real_t>, 1 > TensorField_T; typedef GhostLayerField< Vector3<real_t>, 1 > Vec3Field_T; typedef GhostLayerField< real_t, 1 > ScalarField_T; -typedef lbm::force_model::GuoField< Vec3Field_T > ForceModel_T; +using ForceModel_T = lbm::force_model::GuoField<Vec3Field_T>; typedef lbm::D3Q19< lbm::collision_model::SRTField<ScalarField_T>, false, ForceModel_T > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; // boundary handling typedef lbm::NoSlip< LatticeModel_T, flag_t > NoSlip_T; -typedef boost::tuples::tuple< NoSlip_T > BoundaryConditions_T; +using BoundaryConditions_T = boost::tuples::tuple<NoSlip_T>; typedef BoundaryHandling<FlagField_T, Stencil_T, BoundaryConditions_T> BoundaryHandling_T; typedef boost::tuple<pe::Plane, pe::Sphere> BodyTypeTuple ; @@ -1328,13 +1328,13 @@ int main( int argc, char **argv ) { if( useLubricationCorrection ) { - typedef pe_coupling::LubricationCorrection LE_T; + using LE_T = pe_coupling::LubricationCorrection; shared_ptr<LE_T> lubEval = make_shared<LE_T>( blocks, globalBodyStorage, bodyStorageID, viscosity, lubricationCutOffDistance ); lubricationEvaluationFunction = std::bind(&LE_T::operator(), lubEval); } else { - typedef pe_coupling::discrete_particle_methods::LubricationForceEvaluator LE_T; + using LE_T = pe_coupling::discrete_particle_methods::LubricationForceEvaluator; shared_ptr<LE_T> lubEval = make_shared<LE_T>( blocks, globalBodyStorage, bodyStorageID, viscosity, lubricationCutOffDistance ); lubricationEvaluationFunction = std::bind(&LE_T::operator(), lubEval); } diff --git a/tests/pe_coupling/discrete_particle_methods/SphereWallCollisionBehaviorDPM.cpp b/tests/pe_coupling/discrete_particle_methods/SphereWallCollisionBehaviorDPM.cpp index 1ed4cbb0f..41f952f16 100644 --- a/tests/pe_coupling/discrete_particle_methods/SphereWallCollisionBehaviorDPM.cpp +++ b/tests/pe_coupling/discrete_particle_methods/SphereWallCollisionBehaviorDPM.cpp @@ -74,19 +74,19 @@ const uint_t FieldGhostLayers( 1 ); typedef GhostLayerField< Matrix3<real_t>, 1 > TensorField_T; typedef GhostLayerField< Vector3<real_t>, 1 > Vec3Field_T; typedef GhostLayerField< real_t, 1 > ScalarField_T; -typedef lbm::force_model::GuoField< Vec3Field_T > ForceModel_T; +using ForceModel_T = lbm::force_model::GuoField<Vec3Field_T>; typedef lbm::D3Q19< lbm::collision_model::SRTField<ScalarField_T>, false, ForceModel_T > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; // boundary handling typedef lbm::NoSlip< LatticeModel_T, flag_t > NoSlip_T; -typedef boost::tuples::tuple< NoSlip_T > BoundaryConditions_T; +using BoundaryConditions_T = boost::tuples::tuple<NoSlip_T>; typedef BoundaryHandling<FlagField_T, Stencil_T, BoundaryConditions_T> BoundaryHandling_T; typedef boost::tuple<pe::Plane, pe::Sphere> BodyTypeTuple ; @@ -1125,13 +1125,13 @@ int main( int argc, char **argv ) { if( useLubricationCorrection ) { - typedef pe_coupling::LubricationCorrection LE_T; + using LE_T = pe_coupling::LubricationCorrection; shared_ptr<LE_T> lubEval = make_shared<LE_T>( blocks, globalBodyStorage, bodyStorageID, viscosity, lubricationCutOffDistance ); lubricationEvaluationFunction = std::bind(&LE_T::operator(), lubEval); } else { - typedef pe_coupling::discrete_particle_methods::LubricationForceEvaluator LE_T; + using LE_T = pe_coupling::discrete_particle_methods::LubricationForceEvaluator; shared_ptr<LE_T> lubEval = make_shared<LE_T>( blocks, globalBodyStorage, bodyStorageID, viscosity, lubricationCutOffDistance ); lubricationEvaluationFunction = std::bind(&LE_T::operator(), lubEval); } diff --git a/tests/pe_coupling/momentum_exchange_method/BodyAtBlockBoarderCheck.cpp b/tests/pe_coupling/momentum_exchange_method/BodyAtBlockBoarderCheck.cpp index 5457aee89..e78072cbf 100644 --- a/tests/pe_coupling/momentum_exchange_method/BodyAtBlockBoarderCheck.cpp +++ b/tests/pe_coupling/momentum_exchange_method/BodyAtBlockBoarderCheck.cpp @@ -77,23 +77,23 @@ using namespace walberla; using walberla::uint_t; // PDF field, flag field & body field -typedef lbm::D3Q19< lbm::collision_model::TRT > LatticeModel_T; +using LatticeModel_T = lbm::D3Q19<lbm::collision_model::TRT>; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; const uint_t FieldGhostLayers = 4; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; // boundary handling typedef pe_coupling::SimpleBB< LatticeModel_T, FlagField_T > MO_T; -typedef boost::tuples::tuple< MO_T > BoundaryConditions_T; +using BoundaryConditions_T = boost::tuples::tuple<MO_T>; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /////////// // FLAGS // diff --git a/tests/pe_coupling/momentum_exchange_method/BodyMappingTest.cpp b/tests/pe_coupling/momentum_exchange_method/BodyMappingTest.cpp index 81c65a694..695b87400 100644 --- a/tests/pe_coupling/momentum_exchange_method/BodyMappingTest.cpp +++ b/tests/pe_coupling/momentum_exchange_method/BodyMappingTest.cpp @@ -60,15 +60,15 @@ using namespace walberla; using walberla::uint_t; // PDF field, flag field & body field -typedef lbm::D3Q19< lbm::collision_model::SRT > LatticeModel_T; +using LatticeModel_T = lbm::D3Q19<lbm::collision_model::SRT>; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; const uint_t FieldGhostLayers = 1; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; // boundary handling @@ -77,7 +77,7 @@ typedef pe_coupling::SimpleBB< LatticeModel_T, FlagField_T > MO_T; typedef boost::tuples::tuple< NoSlip_T, MO_T > BoundaryConditions_T; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /////////// // FLAGS // diff --git a/tests/pe_coupling/momentum_exchange_method/DragForceSphereMEM.cpp b/tests/pe_coupling/momentum_exchange_method/DragForceSphereMEM.cpp index 4a7ddd4d9..caa0987ed 100644 --- a/tests/pe_coupling/momentum_exchange_method/DragForceSphereMEM.cpp +++ b/tests/pe_coupling/momentum_exchange_method/DragForceSphereMEM.cpp @@ -76,14 +76,14 @@ using walberla::uint_t; using lbm::force_model::SimpleConstant; // PDF field, flag field & body field -typedef lbm::force_model::LuoConstant ForceModel_T; +using ForceModel_T = lbm::force_model::LuoConstant; typedef lbm::D3Q19< lbm::collision_model::TRT, false, ForceModel_T, 1> LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 1; @@ -96,7 +96,7 @@ typedef pe_coupling::CurvedQuadratic< LatticeModel_T, FlagField_T > MO_MR_T; typedef boost::tuples::tuple< MO_BB_T, MO_CLI_T, MO_MR_T > BoundaryConditions_T; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /////////// // FLAGS // diff --git a/tests/pe_coupling/momentum_exchange_method/DragForceSphereMEMRefinement.cpp b/tests/pe_coupling/momentum_exchange_method/DragForceSphereMEMRefinement.cpp index 4664929da..3d60be54a 100644 --- a/tests/pe_coupling/momentum_exchange_method/DragForceSphereMEMRefinement.cpp +++ b/tests/pe_coupling/momentum_exchange_method/DragForceSphereMEMRefinement.cpp @@ -86,13 +86,13 @@ using lbm::force_model::SimpleConstant; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::TRT, false, lbm::force_model::SimpleConstant, 1> LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; const uint_t FieldGhostLayers = 4; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; // boundary handling @@ -102,7 +102,7 @@ typedef pe_coupling::CurvedLinear < LatticeModel_T, FlagField_T > MO_CLI_T; typedef boost::tuples::tuple< MO_BB_T, MO_CLI_T > BoundaryConditions_T; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /////////// // FLAGS // diff --git a/tests/pe_coupling/momentum_exchange_method/GlobalBodyAsBoundaryMEMStaticRefinement.cpp b/tests/pe_coupling/momentum_exchange_method/GlobalBodyAsBoundaryMEMStaticRefinement.cpp index c8a320987..4643443ed 100644 --- a/tests/pe_coupling/momentum_exchange_method/GlobalBodyAsBoundaryMEMStaticRefinement.cpp +++ b/tests/pe_coupling/momentum_exchange_method/GlobalBodyAsBoundaryMEMStaticRefinement.cpp @@ -78,11 +78,11 @@ using walberla::uint_t; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 4; @@ -90,10 +90,10 @@ const uint_t FieldGhostLayers = 4; // boundary handling typedef pe_coupling::SimpleBB< LatticeModel_T, FlagField_T > MO_SBB_T; -typedef boost::tuples::tuple< MO_SBB_T > BoundaryConditions_T; +using BoundaryConditions_T = boost::tuples::tuple<MO_SBB_T>; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; -typedef boost::tuple< pe::Plane > BodyTypeTuple; +using BodyTypeTuple = boost::tuple<pe::Plane>; /////////// // FLAGS // diff --git a/tests/pe_coupling/momentum_exchange_method/LubricationCorrectionMEM.cpp b/tests/pe_coupling/momentum_exchange_method/LubricationCorrectionMEM.cpp index dd78fba43..0f4dbd3fe 100644 --- a/tests/pe_coupling/momentum_exchange_method/LubricationCorrectionMEM.cpp +++ b/tests/pe_coupling/momentum_exchange_method/LubricationCorrectionMEM.cpp @@ -79,11 +79,11 @@ using walberla::uint_t; // pdf field & flag field typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; const uint_t FieldGhostLayers = 1; diff --git a/tests/pe_coupling/momentum_exchange_method/PeriodicParticleChannelMEM.cpp b/tests/pe_coupling/momentum_exchange_method/PeriodicParticleChannelMEM.cpp index 774d993fa..2ecfd788d 100644 --- a/tests/pe_coupling/momentum_exchange_method/PeriodicParticleChannelMEM.cpp +++ b/tests/pe_coupling/momentum_exchange_method/PeriodicParticleChannelMEM.cpp @@ -86,11 +86,11 @@ using walberla::uint_t; // pdf field & flag field typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 1; @@ -125,7 +125,7 @@ class VelocityCheck { public: - typedef lbm::PdfField< LatticeModel_T > PdfField; + using PdfField = lbm::PdfField<LatticeModel_T>; VelocityCheck( const ConstBlockDataID & pdfFieldID, const ConstBlockDataID & flagFieldID, const Set< FlagUID > & cellsToCheck, const real_t uMax, const uint_t checkFrequency ) : diff --git a/tests/pe_coupling/momentum_exchange_method/SegreSilberbergMEM.cpp b/tests/pe_coupling/momentum_exchange_method/SegreSilberbergMEM.cpp index a83aa7f56..a238ce167 100644 --- a/tests/pe_coupling/momentum_exchange_method/SegreSilberbergMEM.cpp +++ b/tests/pe_coupling/momentum_exchange_method/SegreSilberbergMEM.cpp @@ -84,11 +84,11 @@ using lbm::force_model::SimpleConstant; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::TRT, false, SimpleConstant > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 1; diff --git a/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEM.cpp b/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEM.cpp index 178ca2e62..b90dcf005 100644 --- a/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEM.cpp +++ b/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEM.cpp @@ -81,11 +81,11 @@ using walberla::uint_t; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 1; diff --git a/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEMDynamicRefinement.cpp b/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEMDynamicRefinement.cpp index 0684d1b49..fa5d1d216 100644 --- a/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEMDynamicRefinement.cpp +++ b/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEMDynamicRefinement.cpp @@ -83,11 +83,11 @@ using walberla::uint_t; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 4; diff --git a/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEMStaticRefinement.cpp b/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEMStaticRefinement.cpp index 6c2202535..41da5d22c 100644 --- a/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEMStaticRefinement.cpp +++ b/tests/pe_coupling/momentum_exchange_method/SettlingSphereMEMStaticRefinement.cpp @@ -81,11 +81,11 @@ using walberla::uint_t; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 4; diff --git a/tests/pe_coupling/momentum_exchange_method/SquirmerTest.cpp b/tests/pe_coupling/momentum_exchange_method/SquirmerTest.cpp index 61e99ab65..ecc2e6642 100644 --- a/tests/pe_coupling/momentum_exchange_method/SquirmerTest.cpp +++ b/tests/pe_coupling/momentum_exchange_method/SquirmerTest.cpp @@ -80,14 +80,14 @@ using namespace walberla; using walberla::uint_t; // PDF field, flag field & body field -typedef lbm::force_model::None ForceModel_T; +using ForceModel_T = lbm::force_model::None; typedef lbm::D3Q19<lbm::collision_model::TRT, false, ForceModel_T> LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField<LatticeModel_T> PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField<flag_t> FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField<pe::BodyID, 1> PeBodyField_T; const uint_t FieldGhostLayers = 1; @@ -95,10 +95,10 @@ const uint_t FieldGhostLayers = 1; // boundary handling typedef pe_coupling::SimpleBB<LatticeModel_T, FlagField_T> MO_BB_T; -typedef boost::tuples::tuple<MO_BB_T> BoundaryConditions_T; +using BoundaryConditions_T = boost::tuples::tuple<MO_BB_T>; typedef BoundaryHandling<FlagField_T, Stencil_T, BoundaryConditions_T> BoundaryHandling_T; -typedef boost::tuple<pe::Squirmer> BodyTypeTuple; +using BodyTypeTuple = boost::tuple<pe::Squirmer>; /////////// // FLAGS // diff --git a/tests/pe_coupling/momentum_exchange_method/TaylorCouetteFlowMEM.cpp b/tests/pe_coupling/momentum_exchange_method/TaylorCouetteFlowMEM.cpp index aad525dc6..0205b4695 100644 --- a/tests/pe_coupling/momentum_exchange_method/TaylorCouetteFlowMEM.cpp +++ b/tests/pe_coupling/momentum_exchange_method/TaylorCouetteFlowMEM.cpp @@ -77,18 +77,18 @@ using walberla::uint_t; // pdf field & flag field typedef lbm::D3Q19< lbm::collision_model::TRT, false > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 1; typedef pe_coupling::CurvedLinear< LatticeModel_T, FlagField_T > MO_T; -typedef boost::tuples::tuple< MO_T > BoundaryConditions_T; +using BoundaryConditions_T = boost::tuples::tuple<MO_T>; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; typedef boost::tuple< pe::Capsule, pe::CylindricalBoundary > BodyTypeTuple; diff --git a/tests/pe_coupling/momentum_exchange_method/TorqueSphereMEM.cpp b/tests/pe_coupling/momentum_exchange_method/TorqueSphereMEM.cpp index 7512c6bfb..7f43c9fd2 100644 --- a/tests/pe_coupling/momentum_exchange_method/TorqueSphereMEM.cpp +++ b/tests/pe_coupling/momentum_exchange_method/TorqueSphereMEM.cpp @@ -78,11 +78,11 @@ using walberla::uint_t; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::TRT, false, lbm::force_model::None, 1> LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 1; @@ -95,7 +95,7 @@ typedef pe_coupling::CurvedQuadratic< LatticeModel_T, FlagField_T > MO_MR_T; typedef boost::tuples::tuple< MO_BB_T, MO_CLI_T, MO_MR_T > BoundaryConditions_T; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /////////// // FLAGS // diff --git a/tests/pe_coupling/partially_saturated_cells_method/DragForceSpherePSM.cpp b/tests/pe_coupling/partially_saturated_cells_method/DragForceSpherePSM.cpp index 3b2ba12a1..fb92b0c68 100644 --- a/tests/pe_coupling/partially_saturated_cells_method/DragForceSpherePSM.cpp +++ b/tests/pe_coupling/partially_saturated_cells_method/DragForceSpherePSM.cpp @@ -76,19 +76,19 @@ using walberla::uint_t; using lbm::force_model::SimpleConstant; // PDF field, flag field & body field -typedef lbm::force_model::LuoConstant ForceModel_T; +using ForceModel_T = lbm::force_model::LuoConstant; typedef lbm::D3Q19< lbm::collision_model::SRT, false, ForceModel_T, 1> LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef std::pair< pe::BodyID, real_t > BodyAndVolumeFraction_T; typedef GhostLayerField< std::vector< BodyAndVolumeFraction_T >, 1 > BodyAndVolumeFractionField_T; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /////////// // FLAGS // diff --git a/tests/pe_coupling/partially_saturated_cells_method/DragForceSpherePSMRefinement.cpp b/tests/pe_coupling/partially_saturated_cells_method/DragForceSpherePSMRefinement.cpp index d403e0a24..2fbc0fcbe 100644 --- a/tests/pe_coupling/partially_saturated_cells_method/DragForceSpherePSMRefinement.cpp +++ b/tests/pe_coupling/partially_saturated_cells_method/DragForceSpherePSMRefinement.cpp @@ -86,22 +86,22 @@ using lbm::force_model::SimpleConstant; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::SRT, false, lbm::force_model::SimpleConstant, 1> LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; const uint_t FieldGhostLayers = 4; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef std::pair< pe::BodyID, real_t > BodyAndVolumeFraction_T; typedef GhostLayerField< std::vector< BodyAndVolumeFraction_T >, 1 > BodyAndVolumeFractionField_T; typedef lbm::NoSlip< LatticeModel_T, flag_t > NoSlip_T; -typedef boost::tuples::tuple< NoSlip_T > BoundaryConditions_T; +using BoundaryConditions_T = boost::tuples::tuple<NoSlip_T>; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /////////// // FLAGS // diff --git a/tests/pe_coupling/partially_saturated_cells_method/SegreSilberbergPSM.cpp b/tests/pe_coupling/partially_saturated_cells_method/SegreSilberbergPSM.cpp index 6cc579090..46f2a10e4 100644 --- a/tests/pe_coupling/partially_saturated_cells_method/SegreSilberbergPSM.cpp +++ b/tests/pe_coupling/partially_saturated_cells_method/SegreSilberbergPSM.cpp @@ -84,11 +84,11 @@ using lbm::force_model::SimpleConstant; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::SRT, false, SimpleConstant > LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef GhostLayerField< pe::BodyID, 1 > BodyField_T; const uint_t FieldGhostLayers = 1; @@ -98,7 +98,7 @@ typedef GhostLayerField< std::vector< BodyAndVolumeFraction_T >, 1 > BodyAndVolu // boundary handling typedef lbm::NoSlip< LatticeModel_T, flag_t > NoSlip_T; -typedef boost::tuples::tuple< NoSlip_T > BoundaryConditions_T; +using BoundaryConditions_T = boost::tuples::tuple<NoSlip_T>; typedef BoundaryHandling< FlagField_T, Stencil_T, BoundaryConditions_T > BoundaryHandling_T; typedef boost::tuple< pe::Sphere, pe::Plane > BodyTypeTuple; diff --git a/tests/pe_coupling/partially_saturated_cells_method/TorqueSpherePSM.cpp b/tests/pe_coupling/partially_saturated_cells_method/TorqueSpherePSM.cpp index 33a6d9876..64114c43e 100644 --- a/tests/pe_coupling/partially_saturated_cells_method/TorqueSpherePSM.cpp +++ b/tests/pe_coupling/partially_saturated_cells_method/TorqueSpherePSM.cpp @@ -77,16 +77,16 @@ using walberla::uint_t; // PDF field, flag field & body field typedef lbm::D3Q19< lbm::collision_model::SRT, false, lbm::force_model::None, 1> LatticeModel_T; -typedef LatticeModel_T::Stencil Stencil_T; -typedef lbm::PdfField< LatticeModel_T > PdfField_T; +using Stencil_T = LatticeModel_T::Stencil; +using PdfField_T = lbm::PdfField<LatticeModel_T>; -typedef walberla::uint8_t flag_t; -typedef FlagField< flag_t > FlagField_T; +using flag_t = walberla::uint8_t; +using FlagField_T = FlagField<flag_t>; typedef std::pair< pe::BodyID, real_t > BodyAndVolumeFraction_T; typedef GhostLayerField< std::vector< BodyAndVolumeFraction_T >, 1 > BodyAndVolumeFractionField_T; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /////////// // FLAGS // diff --git a/tests/pe_coupling/utility/BodiesForceTorqueContainerTest.cpp b/tests/pe_coupling/utility/BodiesForceTorqueContainerTest.cpp index 5b98ed977..bf84cbe06 100644 --- a/tests/pe_coupling/utility/BodiesForceTorqueContainerTest.cpp +++ b/tests/pe_coupling/utility/BodiesForceTorqueContainerTest.cpp @@ -40,7 +40,7 @@ namespace force_torque_container_test using namespace walberla; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /*!\brief Test cases for the force torque container provided by the coupling module diff --git a/tests/pe_coupling/utility/PeSubCyclingTest.cpp b/tests/pe_coupling/utility/PeSubCyclingTest.cpp index 11b84d160..fb869661f 100644 --- a/tests/pe_coupling/utility/PeSubCyclingTest.cpp +++ b/tests/pe_coupling/utility/PeSubCyclingTest.cpp @@ -41,7 +41,7 @@ namespace pe_sub_cycling_test using namespace walberla; -typedef boost::tuple<pe::Sphere> BodyTypeTuple ; +using BodyTypeTuple = boost::tuple<pe::Sphere> ; /*!\brief test case to check functionality of sub cycling in the pe time step provided by the coupling module * -- GitLab