RSTT: rstt/SLBM/include/LayerProfileG.h Source File

RSTT 3.1.0 Regional Seismic Travel Time

LayerProfileG.h
Go to the documentation of this file.
1 //- ****************************************************************************
2 //-
3 //- Copyright 2009 National Technology & Engineering Solutions of Sandia, LLC
4 //- (NTESS). Under the terms of Contract DE-NA0003525 with NTESS, the U.S.
5 //- Government retains certain rights in this software.
6 //-
7 //- BSD Open Source License
8 //- All rights reserved.
9 //-
10 //- Redistribution and use in source and binary forms, with or without
11 //- modification, are permitted provided that the following conditions are met:
12 //-
13 //- 1. Redistributions of source code must retain the above copyright notice,
14 //- this list of conditions and the following disclaimer.
15 //-
16 //- 2. Redistributions in binary form must reproduce the above copyright
17 //- notice, this list of conditions and the following disclaimer in the
18 //- documentation and/or other materials provided with the distribution.
19 //-
20 //- 3. Neither the name of the copyright holder nor the names of its
21 //- contributors may be used to endorse or promote products derived from
22 //- this software without specific prior written permission.
23 //-
24 //- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
25 //- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
26 //- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
27 //- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
28 //- LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
29 //- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
30 //- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
31 //- INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
32 //- CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
33 //- ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
34 //- POSSIBILITY OF SUCH DAMAGE.
35 //-
36 //- ****************************************************************************
37
38 #ifndef LayerProfileG_H
39 #define LayerProfileG_H
40
41 // **** _SYSTEM INCLUDES_ ******************************************************
42
43 #include <vector>
44
45 using namespace std;
46
47 // **** _LOCAL INCLUDES_ *******************************************************
48
49 #include "LayerProfile.h"
50 #include "InterpolatedProfile.h"
51
52 // **** _BEGIN SLBM NAMESPACE_ **************************************************
53
54 namespace slbm {
55
56 class SLBM_EXP_IMP LayerProfileG : public LayerProfile
64 {
65
66 public:
67
74 LayerProfileG(GreatCircle* greatCircle, Location& location);
75
79 LayerProfileG(const LayerProfileG& LayerProfileG);
80
84 ~LayerProfileG();
85
89 LayerProfileG& operator=(const LayerProfileG& other);
90
94 bool operator==(const LayerProfileG& other);
95
99 bool operator!=(const LayerProfileG& other) {return ! (*this == other);};
100
106 double getGradient() { return gradient; };
107
108 size_t memSize();
109
110 private:
111
115 double gradient;
116
117 };
118
119 //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
120 //
121 // INLINE FUNCTIONS
122 //
123 //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
124
125 inline size_t LayerProfileG::memSize()
126 {
127 return LayerProfile::memSize() + sizeof(gradient);
128 }
129
130 } // end slbm namespace
131
132 #endif // LayerProfileG.h
slbm::Location
The Location Class manages a single point in/on the Earth, which is described by the GRS80 ellipsoid.
Definition: Location.h:78
slbm::LayerProfileG::getGradient
double getGradient()
Retrieve the velocity gradient in the interval represented by this LayerProfileG, in 1/s.
Definition: LayerProfileG.h:106
slbm::LayerProfileG::operator==
bool operator==(const LayerProfileG &other)
Equality operator.
slbm::LayerProfileG
A LayerProfile with mantle velocity gradient information.
Definition: LayerProfileG.h:64
LayerProfile.h
slbm::LayerProfileG::LayerProfileG
LayerProfileG(GreatCircle *greatCircle, Location &location)
Parameterized constructor.
slbm::LayerProfileG::~LayerProfileG
~LayerProfileG()
Destructor.
InterpolatedProfile.h
slbm::LayerProfile
A Profile object based on values interpolated from nearby GridProfile objects.
Definition: LayerProfile.h:76
slbm::LayerProfileG::LayerProfileG
LayerProfileG(const LayerProfileG &LayerProfileG)
Copy constructor.
slbm::LayerProfileG::operator!=
bool operator!=(const LayerProfileG &other)
Inequality operator.
Definition: LayerProfileG.h:99
SLBM_EXP_IMP
#define SLBM_EXP_IMP
Definition: SLBMGlobals.h:180
slbm::LayerProfileG::operator=
LayerProfileG & operator=(const LayerProfileG &other)
Equal operator.
slbm::GreatCircle
The GreatCircle class manages information related to a great circle path between two Locations on the...
Definition: GreatCircle.h:115
slbm
Definition: CrustalProfile.h:59