Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4OpticalSurface.hh
Go to the documentation of this file.
1//
2// ********************************************************************
3// * License and Disclaimer *
4// * *
5// * The Geant4 software is copyright of the Copyright Holders of *
6// * the Geant4 Collaboration. It is provided under the terms and *
7// * conditions of the Geant4 Software License, included in the file *
8// * LICENSE and available at http://cern.ch/geant4/license . These *
9// * include a list of copyright holders. *
10// * *
11// * Neither the authors of this software system, nor their employing *
12// * institutes,nor the agencies providing financial support for this *
13// * work make any representation or warranty, express or implied, *
14// * regarding this software system or assume any liability for its *
15// * use. Please see the license in the file LICENSE and URL above *
16// * for the full disclaimer and the limitation of liability. *
17// * *
18// * This code implementation is the result of the scientific and *
19// * technical work of the GEANT4 collaboration. *
20// * By using, copying, modifying or distributing the software (or *
21// * any work based on the software) you agree to acknowledge its *
22// * use in resulting scientific publications, and indicate your *
23// * acceptance of all terms of the Geant4 Software license. *
24// ********************************************************************
25//
26//
27// $Id$
28//
29//
30////////////////////////////////////////////////////////////////////////
31// G4OpticalSurface Definition
32////////////////////////////////////////////////////////////////////////
33//
34// File: G4OpticalSurface.hh
35// Description: A optical surface class for use in G4OpBoundaryProcess
36// Version: 2.0
37// Created: 1997-06-26
38// Author: Peter Gumplinger
39// Updated: 1999-10-29 add method and class descriptors
40// mail: [email protected]
41//
42////////////////////////////////////////////////////////////////////////
43
44#ifndef G4OpticalSurface_h
45#define G4OpticalSurface_h 1
46
47/////////////
48// Includes
49/////////////
50
51#include "G4Types.hh"
52#include "G4SurfaceProperty.hh"
53
54// Class Description:
55// A optical surface class for use in the G4OpBoundaryProcess class.
56// Contains the enumerations: G4OpticalSurfaceFinish, G4OpticalSurfaceType,
57// and G4OpticalSurfaceModel.
58// Class Description - End:
59
61{
62 polished, // smooth perfectly polished surface
63 polishedfrontpainted, // smooth top-layer (front) paint
64 polishedbackpainted, // same is 'polished' but with a back-paint
65
66 ground, // rough surface
67 groundfrontpainted, // rough top-layer (front) paint
68 groundbackpainted, // same as 'ground' but with a back-paint
69
70 polishedlumirrorair, // mechanically polished surface, with lumirror
71 polishedlumirrorglue, // mechanically polished surface, with lumirror & meltmount
72 polishedair, // mechanically polished surface
73 polishedteflonair, // mechanically polished surface, with teflon
74 polishedtioair, // mechanically polished surface, with tio paint
75 polishedtyvekair, // mechanically polished surface, with tyvek
76 polishedvm2000air, // mechanically polished surface, with esr film
77 polishedvm2000glue, // mechanically polished surface, with esr film & meltmount
78
79 etchedlumirrorair, // chemically etched surface, with lumirror
80 etchedlumirrorglue, // chemically etched surface, with lumirror & meltmount
81 etchedair, // chemically etched surface
82 etchedteflonair, // chemically etched surface, with teflon
83 etchedtioair, // chemically etched surface, with tio paint
84 etchedtyvekair, // chemically etched surface, with tyvek
85 etchedvm2000air, // chemically etched surface, with esr film
86 etchedvm2000glue, // chemically etched surface, with esr film & meltmount
87
88 groundlumirrorair, // rough-cut surface, with lumirror
89 groundlumirrorglue, // rough-cut surface, with lumirror & meltmount
90 groundair, // rough-cut surface
91 groundteflonair, // rough-cut surface, with teflon
92 groundtioair, // rough-cut surface, with tio paint
93 groundtyvekair, // rough-cut surface, with tyvek
94 groundvm2000air, // rough-cut surface, with esr film
95 groundvm2000glue // rough-cut surface, with esr film & meltmount
96};
97
99{
100 glisur, // original GEANT3 model
101 unified, // UNIFIED model
102 LUT // Look-Up-Table model
104
106
107/////////////////////
108// Class Definition
109/////////////////////
110
112{
113
114public: // Without description
115
116 //////////////
117 // Operators
118 //////////////
119
122
123 G4int operator==(const G4OpticalSurface &right) const;
124 G4int operator!=(const G4OpticalSurface &right) const;
125
126public: // With description
127
128 ////////////////////////////////
129 // Constructors and Destructor
130 ////////////////////////////////
131
132 G4OpticalSurface(const G4String& name,
136 G4double value = 1.0);
137 // Constructor of an optical surface object.
138
139public: // Without description
140
141 virtual ~G4OpticalSurface();
142
143 ////////////
144 // Methods
145 ////////////
146
147 // public methods
148
149public: // With description
150
151 void SetType(const G4SurfaceType& type);
152
153 inline G4OpticalSurfaceFinish GetFinish() const { return theFinish; }
154 // Returns the optical surface finish.
156 // Sets the optical surface finish.
157
158 inline G4OpticalSurfaceModel GetModel() const { return theModel; }
159 // Returns the optical surface model used.
160 inline void SetModel(const G4OpticalSurfaceModel model)
161 { theModel = model; }
162 // Sets the optical surface model to be followed.
163
164 inline G4double GetSigmaAlpha() const { return sigma_alpha; }
165 // Returns an unified model surface parameter.
166 inline void SetSigmaAlpha(const G4double s_a) { sigma_alpha = s_a; }
167 // Sets an unified model surface parameter.
168
169 G4double GetPolish() const { return polish; }
170 // Returns the optical surface polish type.
171 inline void SetPolish(const G4double plsh) { polish=plsh; }
172 // Sets the optical surface polish type.
173
175 { return theMaterialPropertiesTable; }
176 // Retrieves the pointer of the G4MaterialPropertiesTable
177 // attached to optical surface.
178
180 { theMaterialPropertiesTable = anMPT; }
181 // Attaches a G4MaterialPropertiesTable to the optical surface.
182
183 void DumpInfo() const;
184 // Prints information about the optical surface.
185
186 void ReadFile(void);
187 // Method to read the Look-Up-Table into array AngularDistribution
188
190
191 inline G4int GetThetaIndexMax(void) const { return thetaIndexMax; }
192 inline G4int GetPhiIndexMax(void) const { return phiIndexMax; }
193
194private:
195
196// ------------------
197// Basic data members ( To define an optical surface)
198// ------------------
199
200 G4OpticalSurfaceModel theModel; // Surface model
201 G4OpticalSurfaceFinish theFinish; // Surface finish
202
203 G4double sigma_alpha; // The sigma of micro-facet polar angle
204 G4double polish; // Polish parameter in glisur model
205
206 G4MaterialPropertiesTable* theMaterialPropertiesTable;
207
208 static const G4int incidentIndexMax = 91;
209 static const G4int thetaIndexMax = 45;
210 static const G4int phiIndexMax = 37;
211
212 G4float* AngularDistribution;
213
214 // Open LUT with Material and Integer Angle
215 FILE* readFileHandle;
216
217};
218
219////////////////////
220// Inline methods
221////////////////////
222
223inline
225 G4int thetaIndex,
226 G4int phiIndex)
227{
228 return AngularDistribution[angleIncident+
229 thetaIndex*incidentIndexMax+
230 phiIndex*thetaIndexMax*incidentIndexMax];
231}
232
233#endif /* G4OpticalSurface_h */
G4OpticalSurfaceModel
@ unified
@ glisur
G4OpticalSurfaceFinish
@ groundfrontpainted
@ polishedlumirrorair
@ groundtyvekair
@ groundtioair
@ groundvm2000glue
@ polishedair
@ groundair
@ etchedteflonair
@ etchedtyvekair
@ etchedvm2000glue
@ polishedbackpainted
@ etchedtioair
@ groundvm2000air
@ polished
@ polishedlumirrorglue
@ polishedtyvekair
@ ground
@ polishedteflonair
@ etchedair
@ polishedvm2000air
@ etchedlumirrorglue
@ polishedvm2000glue
@ polishedfrontpainted
@ polishedtioair
@ groundlumirrorglue
@ etchedvm2000air
@ groundbackpainted
@ etchedlumirrorair
@ groundlumirrorair
@ groundteflonair
G4SurfaceType
@ dielectric_dielectric
double G4double
Definition: G4Types.hh:64
float G4float
Definition: G4Types.hh:65
int G4int
Definition: G4Types.hh:66
virtual ~G4OpticalSurface()
void SetSigmaAlpha(const G4double s_a)
void DumpInfo() const
void SetMaterialPropertiesTable(G4MaterialPropertiesTable *anMPT)
G4OpticalSurfaceModel GetModel() const
G4double GetSigmaAlpha() const
G4OpticalSurfaceFinish GetFinish() const
void SetModel(const G4OpticalSurfaceModel model)
G4int GetThetaIndexMax(void) const
G4int GetPhiIndexMax(void) const
void SetType(const G4SurfaceType &type)
G4double GetPolish() const
G4int operator!=(const G4OpticalSurface &right) const
G4OpticalSurface & operator=(const G4OpticalSurface &right)
G4MaterialPropertiesTable * GetMaterialPropertiesTable() const
G4double GetAngularDistributionValue(G4int, G4int, G4int)
void SetFinish(const G4OpticalSurfaceFinish)
G4int operator==(const G4OpticalSurface &right) const
void SetPolish(const G4double plsh)