source: Sophya/trunk/SigPredictor/abslobenopolar.h@ 1647

Last change on this file since 1647 was 1148, checked in by ansari, 25 years ago

mise a jour

File size: 2.9 KB
Line 
1// Dominique YVON, CEA/DAPNIA/SPP 02/2000
2
3#ifndef AbsLobeNoPolar_H
4#define AbsLobeNoPolar_H
5
6#ifdef __MWERKS__
7// #include "unixmac.h"
8 #include "macenvvariables.h"
9#endif
10
11#include <stdlib.h>
12#include "unitvector.h"
13
14#include "lobespecresp.h"
15#include "radspec.h"
16
17class AbsLobeNoPolar{
18//friend class SigCalcTool;
19// Base class for Implementing Lobes
20
21 public:
22 AbsLobeNoPolar(double FMin,double FMax):FreqMin(FMin),FreqMax(FMax)
23 { cosanglemax=-1.;
24 sprintf(Name,"");
25 }
26 virtual double weigth(const UnitVector& VInteg, const UnitVector& VP,
27 const UnitVector& VY, double freq) const =0;
28 // Return relative weigth of incoming power from direction VInteg
29 // at frequency freq no dimensions
30 virtual double lobeResol() const =0;
31 // Return reasonable computing resolution for this lobe
32 virtual double ResolutionCurve(double angle) const=0;
33 // Compute angular resolution degradation factor as a function of angle
34 // Usefull to optimize the speed of computation at large angle
35 // Overloaded when optimisation is required.
36 virtual void print(ostream& OutStr) const;
37 inline LobeSpecResp WeigthVsFreq(const UnitVector& VInteg,
38 const UnitVector& VP, const UnitVector& VY)
39 {
40 LobeSpecResp TheSpecResp(this,VInteg,VP,VY,this->minFreq(),this->maxFreq());
41 return TheSpecResp;
42 }
43 // Return an object including WeigthVsFreq with no dimensions.
44
45/* virtual DPixelMap& getLobeMap(double ResLSrcMap)=0;
46 // Return Map of Lobe to allow multiplication of map
47 // To be implemented
48*/
49 inline double AngleMax() const{return angleMax;}
50 inline double minFreq() const {return FreqMin;}
51 inline double maxFreq() const {return FreqMax;}
52 inline bool IsFreqSep() const {return LobeFSep;}
53
54 int gorskyNlatFromRes() const;
55 // Compute Gorsky Nlat to prepare a map with full resolution of the lobe
56
57 virtual UnitVector VecShift(const UnitVector& VPointe,const UnitVector& VY) const{
58 // Usefull when peak sensitivity is not in boresight direction
59 return VPointe;
60 }
61
62 // Optimisations tools for frequency separable Lobe computations.
63 virtual double spectre(double freq) const{
64 freq=0.; //evite un warning
65 if(!LobeFSep) cerr<< "appel a lobe.spectre() in a non separable lobe"<<endl;
66 exit(-1);
67 return 0;
68 }
69 virtual double weigthAmpl(const UnitVector& VInteg, const UnitVector& VP,
70 const UnitVector& VY) const{
71 if(!LobeFSep) cerr<< "appel a lobe.weigthAmpl() in a non separable lobe"<<endl;
72 exit(-1);
73 return 0;
74 }
75
76 protected:
77 char Name[32];
78 double FreqMin;
79 double FreqMax;
80 double angleMax;
81 double cosanglemax;
82 // Angle beyond which constributions is neglected for this lobe
83 // Lobe 4 M_PI angleMax=180.
84 bool LobeFSep;
85 // Are spatial coordinated and frequency separable variables?
86 inline double minToRad(double minute) { return minute/(180.*60.)*M_PI;}
87 inline double radToMin(double rad) { return rad/M_PI*180.*60.; }
88 //SpectralResponse* pSpecRep;
89};
90
91
92#endif
Note: See TracBrowser for help on using the repository browser.