From 9c8c5eee0338187a61c4eb922d87cc8e70d1fbe9 Mon Sep 17 00:00:00 2001 From: Bertrand Thierry Date: Thu, 23 May 2024 23:02:01 +0200 Subject: [PATCH] uncrustify --- .../AcousticTTIFletcherWaveEquationSEM.cpp | 107 +++++++++--------- .../AcousticTTIFletcherWaveEquationSEM.hpp | 4 +- ...ousticTTIFletcherWaveEquationSEMKernel.hpp | 26 ++--- .../AcousticTTIZhangWaveEquationSEM.cpp | 17 +-- .../AcousticTTIZhangWaveEquationSEM.hpp | 2 +- .../AcousticTTIZhangWaveEquationSEMKernel.hpp | 2 +- 6 files changed, 80 insertions(+), 78 deletions(-) diff --git a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEM.cpp b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEM.cpp index ba1ebb5d1bd..cf923f38696 100644 --- a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEM.cpp +++ b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEM.cpp @@ -40,7 +40,7 @@ using namespace dataRepository; using namespace fields; AcousticTTIFletcherWaveEquationSEM::AcousticTTIFletcherWaveEquationSEM( const std::string & name, - Group * const parent ): + Group * const parent ): WaveSolverBase( name, parent ) { @@ -130,7 +130,7 @@ void AcousticTTIFletcherWaveEquationSEM::postProcessInput() } void AcousticTTIFletcherWaveEquationSEM::precomputeSourceAndReceiverTerm( MeshLevel & mesh, - arrayView1d< string const > const & regionNames ) + arrayView1d< string const > const & regionNames ) { GEOS_MARK_FUNCTION; NodeManager const & nodeManager = mesh.getNodeManager(); @@ -337,30 +337,30 @@ void AcousticTTIFletcherWaveEquationSEM::initializePostInitialConditionsPreSubGr AcousticMatricesSEM::DampingMatrix< FE_TYPE > kernelD( finiteElement ); // Damping Matrices are computed as in the VTI case kernelD.template computeVTIFletcherDampingMatrices< EXEC_POLICY, ATOMIC_POLICY >( elementSubRegion.size(), - nodeCoords, - elemsToFaces, - facesToNodes, - facesDomainBoundaryIndicator, - freeSurfaceFaceIndicator, - lateralSurfaceFaceIndicator, - bottomSurfaceFaceIndicator, - velocity, - density, - vti_epsilon, - vti_delta, - vti_sigma, - damping_pp, - damping_pq, - damping_qp, - damping_qq ); + nodeCoords, + elemsToFaces, + facesToNodes, + facesDomainBoundaryIndicator, + freeSurfaceFaceIndicator, + lateralSurfaceFaceIndicator, + bottomSurfaceFaceIndicator, + velocity, + density, + vti_epsilon, + vti_delta, + vti_sigma, + damping_pp, + damping_pq, + damping_qp, + damping_qq ); } ); } ); } ); WaveSolverUtils::initTrace( "seismoTraceReceiver", getName(), m_outputSeismoTrace, m_receiverConstants.size( 0 ), m_receiverIsLocal ); - m_seismoCoeff.resize(m_receiverIsLocal.size()); - m_seismoCoeff.setValues< EXEC_POLICY >(0.5); + m_seismoCoeff.resize( m_receiverIsLocal.size()); + m_seismoCoeff.setValues< EXEC_POLICY >( 0.5 ); } void AcousticTTIFletcherWaveEquationSEM::precomputeSurfaceFieldIndicator( DomainPartition & domain ) @@ -537,10 +537,10 @@ void AcousticTTIFletcherWaveEquationSEM::applyPML( real64 const GEOS_UNUSED_PARA } real64 AcousticTTIFletcherWaveEquationSEM::explicitStepForward( real64 const & time_n, - real64 const & dt, - integer cycleNumber, - DomainPartition & domain, - bool computeGradient ) + real64 const & dt, + integer cycleNumber, + DomainPartition & domain, + bool computeGradient ) { real64 dtOut = explicitStepInternal( time_n, dt, cycleNumber, domain ); @@ -572,10 +572,10 @@ real64 AcousticTTIFletcherWaveEquationSEM::explicitStepForward( real64 const & t real64 AcousticTTIFletcherWaveEquationSEM::explicitStepBackward( real64 const & GEOS_UNUSED_PARAM( time_n ), - real64 const & GEOS_UNUSED_PARAM( dt ), - integer GEOS_UNUSED_PARAM( cycleNumber ), - DomainPartition & GEOS_UNUSED_PARAM( domain ), - bool GEOS_UNUSED_PARAM( computeGradient ) ) + real64 const & GEOS_UNUSED_PARAM( dt ), + integer GEOS_UNUSED_PARAM( cycleNumber ), + DomainPartition & GEOS_UNUSED_PARAM( domain ), + bool GEOS_UNUSED_PARAM( computeGradient ) ) { GEOS_ERROR( "This option is not supported yet" ); return 0.; @@ -615,12 +615,12 @@ void AcousticTTIFletcherWaveEquationSEM::prepareNextTimestep( MeshLevel & mesh ) } void AcousticTTIFletcherWaveEquationSEM::computeUnknowns( real64 const & GEOS_UNUSED_PARAM( time_n ), - real64 const & dt, - integer cycleNumber, - DomainPartition & GEOS_UNUSED_PARAM( domain ), - MeshLevel & mesh, - arrayView1d< string const > const & regionNames, - bool const isForward ) + real64 const & dt, + integer cycleNumber, + DomainPartition & GEOS_UNUSED_PARAM( domain ), + MeshLevel & mesh, + arrayView1d< string const > const & regionNames, + bool const isForward ) { NodeManager & nodeManager = mesh.getNodeManager(); @@ -645,7 +645,7 @@ void AcousticTTIFletcherWaveEquationSEM::computeUnknowns( real64 const & GEOS_UN arrayView1d< real32 > const stiffnessVector_q = nodeManager.getField< acousticvtifields::StiffnessVector_q >(); arrayView1d< real32 > const rhs = nodeManager.getField< acousticfields::ForcingRHS >(); - if(isForward) + if( isForward ) { auto kernelFactory = acousticTTIFletcherWaveEquationSEMKernels::ExplicitAcousticTTIFletcherSEMFactory( dt ); @@ -658,12 +658,13 @@ void AcousticTTIFletcherWaveEquationSEM::computeUnknowns( real64 const & GEOS_UN "", kernelFactory ); } - else{ - //Adjoint - GEOS_ERROR( "This option is not supported yet" ); + else + { + //Adjoint + GEOS_ERROR( "This option is not supported yet" ); /* auto kernelFactory = acousticTTIFletcherAdjointWaveEquationSEMKernels::ExplicitAdjointAcousticTTIFletcherSEMFactory( dt ); - finiteElement:: + finiteElement:: regionBasedKernelApplication< EXEC_POLICY, constitutive::NullModel, CellElementSubRegion >( mesh, @@ -671,7 +672,7 @@ void AcousticTTIFletcherWaveEquationSEM::computeUnknowns( real64 const & GEOS_UN getDiscretizationName(), "", kernelFactory ); - */ + */ } EventManager const & event = getGroupByPath< EventManager >( "/Problem/Events" ); real64 const & minTime = event.getReference< real64 >( EventManager::viewKeyStruct::minTimeString() ); @@ -695,11 +696,11 @@ void AcousticTTIFletcherWaveEquationSEM::computeUnknowns( real64 const & GEOS_UN } void AcousticTTIFletcherWaveEquationSEM::synchronizeUnknowns( real64 const & time_n, - real64 const & dt, - integer const, - DomainPartition & domain, - MeshLevel & mesh, - arrayView1d< string const > const & ) + real64 const & dt, + integer const, + DomainPartition & domain, + MeshLevel & mesh, + arrayView1d< string const > const & ) { NodeManager & nodeManager = mesh.getNodeManager(); @@ -741,10 +742,10 @@ void AcousticTTIFletcherWaveEquationSEM::synchronizeUnknowns( real64 const & tim } real64 AcousticTTIFletcherWaveEquationSEM::explicitStepInternal( real64 const & time_n, - real64 const & dt, - integer const cycleNumber, - DomainPartition & domain, - bool const ifForward ) + real64 const & dt, + integer const cycleNumber, + DomainPartition & domain, + bool const ifForward ) { GEOS_MARK_FUNCTION; @@ -762,10 +763,10 @@ real64 AcousticTTIFletcherWaveEquationSEM::explicitStepInternal( real64 const & } void AcousticTTIFletcherWaveEquationSEM::cleanup( real64 const time_n, - integer const cycleNumber, - integer const eventCounter, - real64 const eventProgress, - DomainPartition & domain ) + integer const cycleNumber, + integer const eventCounter, + real64 const eventProgress, + DomainPartition & domain ) { // call the base class cleanup (for reporting purposes) SolverBase::cleanup( time_n, cycleNumber, eventCounter, eventProgress, domain ); diff --git a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEM.hpp b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEM.hpp index 25a2b8a84ca..9245e6f9763 100644 --- a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEM.hpp +++ b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEM.hpp @@ -38,7 +38,7 @@ class AcousticTTIFletcherWaveEquationSEM : public WaveSolverBase using ATOMIC_POLICY = AtomicPolicy< EXEC_POLICY >; AcousticTTIFletcherWaveEquationSEM( const std::string & name, - Group * const parent ); + Group * const parent ); virtual ~AcousticTTIFletcherWaveEquationSEM() override; @@ -177,7 +177,7 @@ class AcousticTTIFletcherWaveEquationSEM : public WaveSolverBase /// Pressure_np1 at the receiver location for each time step for each receiver array2d< real32 > m_pressureNp1AtReceivers; - + /// Array of size the number of receivers and full of 0.5 (used for calculating the seismos) array1d< real32 > m_seismoCoeff; }; diff --git a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEMKernel.hpp b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEMKernel.hpp index ccce0fe6d84..fc6ec97838f 100644 --- a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEMKernel.hpp +++ b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIFletcherWaveEquationSEMKernel.hpp @@ -56,10 +56,10 @@ template< typename SUBREGION_TYPE, typename CONSTITUTIVE_TYPE, typename FE_TYPE > class ExplicitAcousticTTIFletcherSEM : public finiteElement::KernelBase< SUBREGION_TYPE, - CONSTITUTIVE_TYPE, - FE_TYPE, - 1, - 1 > + CONSTITUTIVE_TYPE, + FE_TYPE, + 1, + 1 > { public: @@ -94,13 +94,13 @@ class ExplicitAcousticTTIFletcherSEM : public finiteElement::KernelBase< SUBREGI * elements to be processed during this kernel launch. */ ExplicitAcousticTTIFletcherSEM( NodeManager & nodeManager, - EdgeManager const & edgeManager, - FaceManager const & faceManager, - localIndex const targetRegionIndex, - SUBREGION_TYPE const & elementSubRegion, - FE_TYPE const & finiteElementSpace, - CONSTITUTIVE_TYPE & inputConstitutiveType, - real64 const dt ): + EdgeManager const & edgeManager, + FaceManager const & faceManager, + localIndex const targetRegionIndex, + SUBREGION_TYPE const & elementSubRegion, + FE_TYPE const & finiteElementSpace, + CONSTITUTIVE_TYPE & inputConstitutiveType, + real64 const dt ): Base( elementSubRegion, finiteElementSpace, inputConstitutiveType ), @@ -147,7 +147,7 @@ class ExplicitAcousticTTIFletcherSEM : public finiteElement::KernelBase< SUBREGI real32 vti_epsi; // (1 + 2*epsilon) real32 vti_2delta; // 2*delta real32 vti_f; // f parameter - real32 tti_tilt; //TTI tilt angle + real32 tti_tilt; //TTI tilt angle real32 tti_azimuth; //TTI azimuth angle }; //*************************************************************************** @@ -308,7 +308,7 @@ class ExplicitAcousticTTIFletcherSEM : public finiteElement::KernelBase< SUBREGI /// The factory used to construct a ExplicitAcousticWaveEquation kernel. using ExplicitAcousticTTIFletcherSEMFactory = finiteElement::KernelFactory< ExplicitAcousticTTIFletcherSEM, - real64 >; + real64 >; } // namespace acousticTTIFletcherWaveEquationSEMKernels diff --git a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEM.cpp b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEM.cpp index 09d21d4c26e..2f8cc3c4615 100644 --- a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEM.cpp +++ b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEM.cpp @@ -356,8 +356,8 @@ void AcousticTTIZhangWaveEquationSEM::initializePostInitialConditionsPreSubGroup } ); WaveSolverUtils::initTrace( "seismoTraceReceiver", getName(), m_outputSeismoTrace, m_receiverConstants.size( 0 ), m_receiverIsLocal ); - m_seismoCoeff.resize(m_receiverIsLocal.size()); - m_seismoCoeff.setValues< EXEC_POLICY >(0.5); + m_seismoCoeff.resize( m_receiverIsLocal.size()); + m_seismoCoeff.setValues< EXEC_POLICY >( 0.5 ); } void AcousticTTIZhangWaveEquationSEM::precomputeSurfaceFieldIndicator( DomainPartition & domain ) @@ -642,7 +642,7 @@ void AcousticTTIZhangWaveEquationSEM::computeUnknowns( real64 const & GEOS_UNUSE arrayView1d< real32 > const stiffnessVector_q = nodeManager.getField< acousticvtifields::StiffnessVector_q >(); arrayView1d< real32 > const rhs = nodeManager.getField< acousticfields::ForcingRHS >(); - if(isForward) + if( isForward ) { auto kernelFactory = acousticTTIZhangWaveEquationSEMKernels::ExplicitAcousticTTIZhangSEMFactory( dt ); @@ -655,12 +655,13 @@ void AcousticTTIZhangWaveEquationSEM::computeUnknowns( real64 const & GEOS_UNUSE "", kernelFactory ); } - else{ - //Adjoint - GEOS_ERROR( "This option is not supported yet" ); + else + { + //Adjoint + GEOS_ERROR( "This option is not supported yet" ); /* auto kernelFactory = acousticTTIZhangAdjointWaveEquationSEMKernels::ExplicitAdjointAcousticTTIZhangSEMFactory( dt ); - finiteElement:: + finiteElement:: regionBasedKernelApplication< EXEC_POLICY, constitutive::NullModel, CellElementSubRegion >( mesh, @@ -668,7 +669,7 @@ void AcousticTTIZhangWaveEquationSEM::computeUnknowns( real64 const & GEOS_UNUSE getDiscretizationName(), "", kernelFactory ); - */ + */ } EventManager const & event = getGroupByPath< EventManager >( "/Problem/Events" ); real64 const & minTime = event.getReference< real64 >( EventManager::viewKeyStruct::minTimeString() ); diff --git a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEM.hpp b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEM.hpp index 25a6dd3a23a..60bba1b0987 100644 --- a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEM.hpp +++ b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEM.hpp @@ -177,7 +177,7 @@ class AcousticTTIZhangWaveEquationSEM : public WaveSolverBase /// Pressure_np1 at the receiver location for each time step for each receiver array2d< real32 > m_pressureNp1AtReceivers; - + /// Array of size the number of receivers and full of 0.5 (used for calculating the seismos) array1d< real32 > m_seismoCoeff; }; diff --git a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEMKernel.hpp b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEMKernel.hpp index 81fd1e34ec9..e95b41d351a 100644 --- a/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEMKernel.hpp +++ b/src/coreComponents/physicsSolvers/wavePropagation/sem/acoustic/secondOrderEqn/anisotropic/AcousticTTIZhangWaveEquationSEMKernel.hpp @@ -145,7 +145,7 @@ class ExplicitAcousticTTIZhangSEM : public finiteElement::KernelBase< SUBREGION_ real32 invDensity; real32 vti_epsi; // (1 + 2*epsilon) real32 vti_sqrtDelta; // sqrt(1 + 2*delta) - real32 tti_tilt; //TTI tilt angle + real32 tti_tilt; //TTI tilt angle real32 tti_azimuth; //TTI azimuth angle }; //***************************************************************************