Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-11-07 10:11:39

0001 //------------------------------- -*- C++ -*- -------------------------------//
0002 // Copyright Celeritas contributors: see top-level COPYRIGHT file for details
0003 // SPDX-License-Identifier: (Apache-2.0 OR MIT)
0004 //---------------------------------------------------------------------------//
0005 //! \file celeritas/optical/surface/model/SmearRoughnessModel.hh
0006 //---------------------------------------------------------------------------//
0007 #pragma once
0008 
0009 #include "corecel/data/ParamsDataStore.hh"
0010 #include "celeritas/inp/OpticalPhysics.hh"
0011 #include "celeritas/optical/surface/SurfaceModel.hh"
0012 
0013 #include "SmearRoughnessData.hh"
0014 
0015 namespace celeritas
0016 {
0017 namespace inp
0018 {
0019 struct SmearRoughness;
0020 }
0021 
0022 namespace optical
0023 {
0024 //---------------------------------------------------------------------------//
0025 /*!
0026  * Smear roughness model.
0027  *
0028  * Approximates the surface roughness of an optical surface with the GliSur3
0029  * uniform smear roughness model.
0030  */
0031 class SmearRoughnessModel : public SurfaceModel
0032 {
0033   public:
0034     //!@{
0035     //! \name Type aliases
0036     using InputT = inp::SmearRoughness;
0037     //!@}
0038 
0039   public:
0040     // Construct the model from an ID and layer map
0041     SmearRoughnessModel(SurfaceModelId, std::map<PhysSurfaceId, InputT> const&);
0042 
0043     //! Get the list of physical surfaces this model applies to
0044     VecSurfaceLayer const& get_surfaces() const final { return surfaces_; }
0045 
0046     // Execute the model with host data
0047     void step(CoreParams const&, CoreStateHost&) const final;
0048 
0049     // Execute the model with device data
0050     void step(CoreParams const&, CoreStateDevice&) const final;
0051 
0052   private:
0053     VecSurfaceLayer surfaces_;
0054     ParamsDataStore<SmearRoughnessData> data_;
0055 };
0056 
0057 //---------------------------------------------------------------------------//
0058 }  // namespace optical
0059 }  // namespace celeritas