Lemma is an Electromagnetics API
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. /* This file is part of Lemma, a geophysical modelling and inversion API */
  2. /* This Source Code Form is subject to the terms of the Mozilla Public
  3. * License, v. 2.0. If a copy of the MPL was not distributed with this
  4. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  5. /**
  6. @file
  7. @author M. Andy Kass
  8. @date 01/03/2013
  9. @version $Id$
  10. **/
  11. #ifndef __DATAREADERFEMUBC_H
  12. #define __DATAREADERFEMUBC_H
  13. #include "datareader.h"
  14. #include "datafem.h"
  15. namespace Lemma {
  16. // ===================================================================
  17. // Class: DataReaderFemUBC
  18. /// \brief Reads UBC-format observation files
  19. /// \details This class reads UBC-format EM1DFM observation files and
  20. /// populates a DataFEM class. Assumptions: the frequencies and coil
  21. /// geometries remain fixed throughout a survey.
  22. // ===================================================================
  23. class DataReaderFemUBC : DataReader {
  24. friend std::ostream &operator<<(std::ostream &stream,
  25. const DataReaderFemUBC &ob);
  26. public:
  27. // ==================== LIFECYCLE =======================
  28. static DataReaderFemUBC* New();
  29. void Delete();
  30. // ==================== OPERATORS =======================
  31. // ==================== OPERATIONS =======================
  32. void ReadData(const std::string &datafile,int vbs = 0);
  33. // ==================== ACCESS =======================
  34. ///Attach the data object
  35. void SetDataFEM(DataFEM* inputtemp);
  36. // ==================== INQUIRY =======================
  37. /// Return the data object
  38. DataFEM* GetData();
  39. protected:
  40. // ==================== LIFECYCLE =======================
  41. /// Default protected constructor.
  42. DataReaderFemUBC (const std::string &name);
  43. /// Default protected constructor.
  44. ~DataReaderFemUBC ();
  45. void Release();
  46. /// Load read data into data object
  47. void SendData();
  48. // ==================== DATA MEMBERS =========================
  49. DataFEM* InputData;
  50. int nObs;
  51. int nFreq;
  52. MatrixXr DataMatrix;
  53. MatrixXr Uncertainties;
  54. Vector3Xr PositionVec;
  55. VectorXr Freqs;
  56. VectorXr TxMom;
  57. Vector3Xr TxRxSep;
  58. Eigen::Matrix<ORIENTATION,Eigen::Dynamic,1> TxOrientation;
  59. Eigen::Matrix<ORIENTATION,Eigen::Dynamic,1> RxOrientation;
  60. VectorXr ScaleFac;
  61. private:
  62. }; // ----- end of class DataReaderFemUBC -----
  63. } // end of namespace Lemma
  64. #endif
  65. /* vim: set tabstop=4 expandtab: */
  66. /* vim: set filetype=cpp: */