USML
wave_front.h
1 
5 #ifndef USML_WAVEQ3D_WAVE_FRONT_H
6 #define USML_WAVEQ3D_WAVE_FRONT_H
7 
8 #include <usml/ocean/ocean.h>
9 
10 namespace usml {
11 namespace waveq3d {
12 
13 using namespace usml::ocean ;
14 
15 using boost::numeric::ublas::vector;
16 
19 
68 class USML_DECLSPEC wave_front {
69 
70 public:
71 
77 
83 
91 
97 
101  matrix<double> sound_speed ;
102 
107 
113  matrix< vector< double > > attenuation ;
114 
120  matrix< vector< double > > phase ;
121 
128  matrix<double> distance ;
129 
133  matrix<int> surface ;
134 
138  matrix<int> bottom ;
139 
149  matrix<int> caustic ;
150 
154  matrix<bool> on_edge ;
155 
162 
167  matrix< matrix<double> > distance2 ;
168 
169 private:
170 
176 
182 
187 
191  matrix<double> _c2_r ;
192 
196  matrix<double> _sin_theta ;
197 
201  matrix<double> _cot_theta ;
202 
208  const matrix<double>* _target_sin_theta ;
209 
210  //**************************************************
211  // methods
212 
213 public:
214 
230  wave_front(
231  ocean_model& ocean,
232  const seq_vector* freq,
233  unsigned num_de, unsigned num_az,
234  const wposition* targets = NULL,
235  const matrix<double>* sin_theta = NULL
236  ) ;
237 
241  inline unsigned num_de() const {
242  return position.size1() ;
243  }
244 
248  inline unsigned num_az() const {
249  return position.size2() ;
250  }
251 
265  void init_wave(
266  const wposition1& pos, const seq_vector& de, const seq_vector& az ) ;
267 
274  void update() ;
275 
281  void find_edges() ;
282 
283 private:
284 
303  void compute_target_distance() ;
304 
312  void compute_profile() ;
313 
314 };
315 
317 } // end of namespace waveq3d
318 } // end of namespace usml
319 
320 #endif
const seq_vector * _frequencies
Frequencies over which to compute propagation effects (Hz).
Definition: wave_front.h:181
matrix< bool > on_edge
Mark places where the wavefront changes the surface, bottom, or caustics.
Definition: wave_front.h:154
World location in geodetic earth coordinates (latitude, longitude, and altitude). ...
Definition: wposition.h:39
Wavefront characteristics at a specific point in time.
Definition: wave_front.h:68
matrix< vector< double > > phase
Non-spreading component of phase change in radians.
Definition: wave_front.h:120
matrix< double > sound_speed
Speed of sound at each point on the wavefront.
Definition: wave_front.h:101
wposition pos_gradient
First derivative of position with respect to time.
Definition: wave_front.h:82
matrix< matrix< double > > distance2
Distance squared from each target to each point on the wavefront.
Definition: wave_front.h:167
matrix< int > bottom
Cumulative # of bottom reflections encountered at this point in time.
Definition: wave_front.h:138
wvector ndir_gradient
First derivative of normalized direction with respect to time.
Definition: wave_front.h:96
unsigned num_az() const
Number of AZ angles in the ray fan.
Definition: wave_front.h:248
wvector _dc_c
Sound speed gradient divided by sound speed (cached intermediate term).
Definition: wave_front.h:186
Combines the effects of surface, bottom, and profile into a single model.
Definition: ocean_model.h:20
wvector sound_gradient
Sound speed gradient at each point on the wavefront.
Definition: wave_front.h:106
matrix< int > caustic
Cumulative # of caustics encountered at this point in time.
Definition: wave_front.h:149
matrix< double > distance
Distance from old location to this location.
Definition: wave_front.h:128
const wposition * targets
Position of each eigenray target.
Definition: wave_front.h:161
const matrix< double > * _target_sin_theta
Sin of colatitude for targets (cached intermediate term).
Definition: wave_front.h:208
matrix< int > surface
Cumulative # of surface reflections encountered at this point in time.
Definition: wave_front.h:133
matrix< vector< double > > attenuation
Non-spreading component of propagation loss in dB.
Definition: wave_front.h:113
matrix< double > _c2_r
Square of the speed of sound divided by rho (cached intermediate term).
Definition: wave_front.h:191
World location in geodetic earth coordinates (latitude, longitude, and altitude). ...
Definition: wposition1.h:23
unsigned num_de() const
Number of D/E angles in the ray fan.
Definition: wave_front.h:241
ocean_model & _ocean
Environmental parameters.
Definition: wave_front.h:175
wposition position
Location of each point on the wavefront in spherical earth coordinates.
Definition: wave_front.h:76
World vector in spherical earth coordinates.
Definition: wvector.h:42
static const seq_log freq(10e3, 10e3, 1)
matrix< double > _cot_theta
Cotangent of colatitude (cached intermediate term).
Definition: wave_front.h:201
A read-only, monotonic sequence of values.
Definition: seq_vector.h:36
wvector ndirection
Normalized propagation direction of each point on the wavefront in spherical earth coordinates...
Definition: wave_front.h:90
matrix< double > _sin_theta
Sine of colatitude (cached intermediate term).
Definition: wave_front.h:196