| [601] | 1 | // This may look like C code, but it is really -*- C++ -*-
 | 
|---|
 | 2 | //--------------------------------------------------------------------------
 | 
|---|
 | 3 | // File and Version Information:
 | 
|---|
| [831] | 4 | //      $Id: specrespvector.h,v 1.5 2000-04-06 17:11:03 ansari Exp $
 | 
|---|
| [601] | 5 | //
 | 
|---|
 | 6 | // Description:
 | 
|---|
 | 7 | //
 | 
|---|
 | 8 | // History (add to end):
 | 
|---|
 | 9 | //      Sophie   Oct, 1999  - creation
 | 
|---|
 | 10 | //
 | 
|---|
 | 11 | //------------------------------------------------------------------------
 | 
|---|
 | 12 | #ifndef SPECRESPVEC_H_SEEN
 | 
|---|
 | 13 | #define SPECRESPVEC_H_SEEN
 | 
|---|
 | 14 | 
 | 
|---|
 | 15 | #include "machdefs.h"
 | 
|---|
 | 16 | #include <iostream.h>
 | 
|---|
 | 17 | 
 | 
|---|
 | 18 | #include "specresp.h"
 | 
|---|
 | 19 | #include "tvector.h"
 | 
|---|
| [668] | 20 | #include "objfio.h"
 | 
|---|
| [601] | 21 | 
 | 
|---|
 | 22 | //------------------------------------
 | 
|---|
 | 23 | // Collaborating Class Declarations --
 | 
|---|
 | 24 | //------------------------------------
 | 
|---|
 | 25 | 
 | 
|---|
 | 26 | //              ---------------------
 | 
|---|
 | 27 | //              -- Class Interface --
 | 
|---|
 | 28 | //              ---------------------
 | 
|---|
 | 29 | 
 | 
|---|
 | 30 | // ***IMPORTANT*** All frequencies are expressed in GHz  (10^9 Hz)
 | 
|---|
 | 31 | 
 | 
|---|
| [668] | 32 | namespace SOPHYA {
 | 
|---|
 | 33 |   
 | 
|---|
 | 34 |   class SpecRespVec :  public SpectralResponse
 | 
|---|
 | 35 |   {
 | 
|---|
| [601] | 36 | 
 | 
|---|
 | 37 | public:
 | 
|---|
 | 38 |   //Constructor
 | 
|---|
| [668] | 39 |   SpecRespVec();
 | 
|---|
| [669] | 40 |   SpecRespVec(Vector const & nu, Vector const & fdenu, double numin, double numax);
 | 
|---|
 | 41 |   SpecRespVec(Vector const & nu, Vector const & fdenu);
 | 
|---|
| [601] | 42 | 
 | 
|---|
 | 43 |   // destructor
 | 
|---|
 | 44 |   virtual ~SpecRespVec();
 | 
|---|
 | 45 | 
 | 
|---|
 | 46 |   //
 | 
|---|
 | 47 |   //  Member Functions
 | 
|---|
 | 48 |   //
 | 
|---|
 | 49 | 
 | 
|---|
 | 50 |   //  The transmission() function is virtual: 
 | 
|---|
 | 51 |   virtual double transmission(double nu) const; 
 | 
|---|
 | 52 | 
 | 
|---|
| [607] | 53 |   // Acces to Nu and T(nu) vectors 
 | 
|---|
| [668] | 54 |   inline Vector&  getNuVec()  { return _vecOfNu; } ;
 | 
|---|
 | 55 |   inline Vector& getTNuVec()  { return _vecOfFDeNu; }
 | 
|---|
 | 56 |   inline double getNuVec(int i) const { return _vecOfNu(i); }
 | 
|---|
 | 57 |   inline double getTNuVec(int i) const { return _vecOfFDeNu(i); }
 | 
|---|
 | 58 |   inline int NbElts() const { return _size;}
 | 
|---|
 | 59 |   
 | 
|---|
| [601] | 60 |   virtual void      Print(ostream& os)  const;
 | 
|---|
 | 61 | 
 | 
|---|
 | 62 | protected:
 | 
|---|
 | 63 |   Vector _vecOfNu;
 | 
|---|
 | 64 |   Vector _vecOfFDeNu;
 | 
|---|
| [668] | 65 |   int _size;
 | 
|---|
| [601] | 66 | };
 | 
|---|
 | 67 | 
 | 
|---|
| [668] | 68 |   // ObjFileIO<SpecRespVec> pour les PPersist 
 | 
|---|
 | 69 |   inline POutPersist& operator << (POutPersist& os, SpecRespVec & obj)
 | 
|---|
 | 70 |     { ObjFileIO<SpecRespVec> fio(&obj); fio.Write(os); return(os);}
 | 
|---|
 | 71 |   
 | 
|---|
 | 72 |   inline PInPersist& operator >> (PInPersist& os, SpecRespVec & obj)
 | 
|---|
 | 73 |     { ObjFileIO<SpecRespVec> fio(&obj); fio.Read(os); return(os);}
 | 
|---|
| [601] | 74 | 
 | 
|---|
| [831] | 75 | }  // End of namespace 
 | 
|---|
| [601] | 76 | #endif
 | 
|---|