isce3  0.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Pages
Swath.h
1 //-*- C++ -*-
2 //-*- coding: utf-8 -*-
3 
4 #pragma once
5 
6 // std
7 #include <valarray>
8 
9 // isce3::core
10 #include <isce3/core/DateTime.h>
11 #include <isce3/core/LUT2d.h>
12 #include <isce3/core/Constants.h>
13 
14 // isce3::io
15 #include <isce3/io/Raster.h>
16 
17 // Declaration
18 namespace isce3 {
19  namespace product {
20  class Swath;
21  }
22 }
23 
24 // isce3::product::Swath definition
26 
27  public:
28  // Constructors
29  inline Swath() {};
30 
32  inline const std::valarray<double> & slantRange() const { return _slantRange; }
34  inline void slantRange(const std::valarray<double> & rng) { _slantRange = rng; }
35 
37  inline double rangePixelSpacing() const { return _slantRange[1] - _slantRange[0]; }
38 
40  inline const std::valarray<double> & zeroDopplerTime() const { return _zeroDopplerTime; }
42  inline void zeroDopplerTime(const std::valarray<double> & t) { _zeroDopplerTime = t; }
43 
45  inline size_t samples() const { return _slantRange.size(); }
46 
48  inline size_t lines() const { return _zeroDopplerTime.size(); }
49 
51  inline double acquiredCenterFrequency() const { return _acquiredCenterFrequency; }
53  inline void acquiredCenterFrequency(double f) { _acquiredCenterFrequency = f; }
54 
56  inline double processedCenterFrequency() const { return _processedCenterFrequency; }
58  inline void processedCenterFrequency(double f) { _processedCenterFrequency = f; }
59 
61  inline double processedWavelength() const {
62  return isce3::core::speed_of_light / _processedCenterFrequency;
63  }
64 
66  inline double acquiredRangeBandwidth() const { return _acquiredRangeBandwidth; }
68  inline void acquiredRangeBandwidth(double b) { _acquiredRangeBandwidth = b; }
69 
71  inline double processedRangeBandwidth() const { return _processedRangeBandwidth; }
73  inline void processedRangeBandwidth(double b) { _processedRangeBandwidth = b; }
74 
76  inline double nominalAcquisitionPRF() const { return _nominalAcquisitionPRF; }
78  inline void nominalAcquisitionPRF(double f) { _nominalAcquisitionPRF = f; }
79 
81  inline double sceneCenterAlongTrackSpacing() const {
82  return _sceneCenterAlongTrackSpacing;
83  }
85  inline void sceneCenterAlongTrackSpacing(double s) {
86  _sceneCenterAlongTrackSpacing = s;
87  }
88 
90  inline double sceneCenterGroundRangeSpacing() const {
91  return _sceneCenterGroundRangeSpacing;
92  }
94  inline void sceneCenterGroundRangeSpacing(double s) {
95  _sceneCenterGroundRangeSpacing = s;
96  }
97 
99  inline double processedAzimuthBandwidth() const { return _processedAzimuthBandwidth; }
101  inline void processedAzimuthBandwidth(double b) { _processedAzimuthBandwidth = b; }
102 
104  inline const isce3::core::DateTime & refEpoch() const { return _refEpoch; }
106  inline void refEpoch(const isce3::core::DateTime & epoch) { _refEpoch = epoch; }
107 
109  inline std::array<size_t, 2> validSamples() const { return {_validStart, _validEnd}; }
111  inline void validSamples(const std::array<size_t, 2> & valid) {
112  _validStart = valid[0];
113  _validEnd = valid[1];
114  }
115 
116  private:
117  // Coordinates
118  std::valarray<double> _slantRange;
119  std::valarray<double> _zeroDopplerTime;
120 
121  // Other metadata
122  double _acquiredCenterFrequency;
123  double _processedCenterFrequency;
124  double _acquiredRangeBandwidth;
125  double _processedRangeBandwidth;
126  double _nominalAcquisitionPRF;
127  double _sceneCenterAlongTrackSpacing;
128  double _sceneCenterGroundRangeSpacing;
129  double _processedAzimuthBandwidth;
130  size_t _validStart;
131  size_t _validEnd;
132 
133  // Reference epoch
134  isce3::core::DateTime _refEpoch;
135 };
size_t lines() const
Get the number of lines.
Definition: Swath.h:48
double processedCenterFrequency() const
Get processed center frequency.
Definition: Swath.h:56
void zeroDopplerTime(const std::valarray< double > &t)
Set zero Doppler time array.
Definition: Swath.h:42
double sceneCenterGroundRangeSpacing() const
Get scene center ground range spacing.
Definition: Swath.h:90
Definition: Swath.h:25
double processedRangeBandwidth() const
Get processed range bandwidth.
Definition: Swath.h:71
size_t samples() const
Get the number of samples.
Definition: Swath.h:45
std::array< size_t, 2 > validSamples() const
Get valid array indices.
Definition: Swath.h:109
const std::valarray< double > & slantRange() const
Get slant range array.
Definition: Swath.h:32
Data structure to store date time to nano-sec precision.
Definition: DateTime.h:18
double processedAzimuthBandwidth() const
Get processed azimuth bandwidth.
Definition: Swath.h:99
void refEpoch(const isce3::core::DateTime &epoch)
Set reference epoch.
Definition: Swath.h:106
double acquiredCenterFrequency() const
Get acquired center frequency.
Definition: Swath.h:51
double rangePixelSpacing() const
Get the range pixel spacing.
Definition: Swath.h:37
void acquiredRangeBandwidth(double b)
Set acquired range bandwidth.
Definition: Swath.h:68
const isce3::core::DateTime & refEpoch() const
Get reference epoch.
Definition: Swath.h:104
void acquiredCenterFrequency(double f)
Set acquired center frequency.
Definition: Swath.h:53
double processedWavelength() const
Get processed wavelength.
Definition: Swath.h:61
void validSamples(const std::array< size_t, 2 > &valid)
Set valid array indices.
Definition: Swath.h:111
void sceneCenterAlongTrackSpacing(double s)
Set scene center along track spacing.
Definition: Swath.h:85
void processedRangeBandwidth(double b)
Set acquired range bandwidth.
Definition: Swath.h:73
void processedAzimuthBandwidth(double b)
Set processed azimuth bandwidth.
Definition: Swath.h:101
void nominalAcquisitionPRF(double f)
Set nominal acquisition PRF.
Definition: Swath.h:78
void sceneCenterGroundRangeSpacing(double s)
Set scene center ground range spacing.
Definition: Swath.h:94
void slantRange(const std::valarray< double > &rng)
Set slant range array.
Definition: Swath.h:34
double sceneCenterAlongTrackSpacing() const
Get scene center along track spacing.
Definition: Swath.h:81
void processedCenterFrequency(double f)
Set processed center frequency.
Definition: Swath.h:58
double acquiredRangeBandwidth() const
Get acquired range bandwidth.
Definition: Swath.h:66
double nominalAcquisitionPRF() const
Get nominal acquisition PRF.
Definition: Swath.h:76
const std::valarray< double > & zeroDopplerTime() const
Get zero Doppler time array.
Definition: Swath.h:40

Generated for ISCE3.0 by doxygen 1.8.5.