Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013 #ifndef _OCS_REDU_OPT_FIBER_HH_
00014 #define _OCS_REDU_OPT_FIBER_HH_
00015
00016 #include "ocsReduOptSignal.hh"
00017
00018
00019
00021
00040 class ReduOptFiber
00041 {
00042 public:
00043
00045
00046 ReduOptFiber(string InFileName,
00047 ReduOptSignal *oReduOptSignalTmp,
00048 RanNumGen *oRanNumGenTmp);
00049
00051
00053 ReduOptFiber(const ReduOptFiber &oReduOptFiber);
00054
00056
00057
00058 ~ReduOptFiber();
00059
00061
00063 void CopyReduOptFiber(const ReduOptFiber &oReduOptFiber);
00064
00066
00067 void GetFiberSampleCompleteScatt(void);
00068
00070
00081 void SetScatteringMatrix( int IndexStep, double Theta,
00082 double Phi, double Psi);
00083
00084
00087
00096 void SetLengthFiberAndQtStepsFiber(double Length,int numSteps);
00097
00099
00107 void SetStepLengths(double *usrStepLength);
00108
00109 void SetAttenuation(double AttenuationFiber2);
00110
00111 double GetAttenuationFiber() {return AttenuationFiber;};
00112
00113 double GetLengthFiber() {return LengthFiber;};
00114
00116
00118 void GetRandomStepLengths(double RelativeRangeLengths);
00119
00122
00123 void SyncNumChannels(void);
00124
00126
00127 void PropagateFiberCoupledNLS(double *PropagatedLength);
00128 void PropagateFiberCoupledNLS(void)
00129 {double PropagatedLength;
00130 PropagateFiberCoupledNLS(&PropagatedLength);};
00131
00133
00140 void WriteFileSteps(char *outFile);
00141
00144
00157 void SetMeanDGD_SqrtLength(double MeanDGD_SqrtLength2);
00158
00160
00172 void SetPMD_Fiber(double PMD_Fiber2);
00173
00174
00176
00193 double RMS2meanDGD(void);
00194
00195
00196
00199
00213 double GetDGD(double Freq);
00214
00216
00220 double GetSndOrderDGD(double Freq);
00221
00224
00225 void GetInPD_Vector(double Freq,double *InPD_Vector);
00226
00229
00230 void GetOutPD_Vector(double Freq,double *OutPD_Vector);
00231
00234
00235 void GetSndOrderOutPD_Vector(double Freq,double *SndOrderOutPD_Vector);
00236
00239
00240 double GetExpectedDGD()
00241 {return sqrt(8./(3.*pi)*LengthFiber)*PMD_Fiber; };
00242
00245
00246 double GetExpectedSndOrderDGD()
00247 {return sq(GetExpectedDGD())/sqrt(3.); };
00248
00250
00251 double GetMeanDGD_SqrtLength(void)
00252 {return sqrt(1e3)/1e-12*MeanDGD_SqrtLength;};
00253
00254
00255 private:
00256
00259
00266 void AllocateMemory_SetLengthSteps(void);
00267
00269
00273 void ReleaseMemory();
00274
00277
00278 ReduOptSignal *oReduOptSignal;
00279
00283
00284 RanNumGen *oRanNumGen;
00285
00287
00288 int NumChannels;
00289
00291
00292 int GotFiberSample;
00293
00295
00296 double LengthFiber;
00297
00299
00304 int qtStepsFiber;
00305
00307
00312 double PMD_Fiber;
00313
00315
00320 double MeanDGD_SqrtLength;
00321
00323
00325 double AttenuationFiber;
00326
00328
00332 double NepperAttenuationFiber;
00333
00335
00336 double CenterFreq;
00337
00339
00340 double *psi,*phi,*theta;
00341
00343
00346 double *StepLength;
00347
00348 double cvtheta2,cvtheta;
00349
00352
00353 double DeltaZ;
00354
00356
00365 double dBeta_2dOmega;
00366
00368
00371 int TypeScattering;
00372 };
00373
00374
00375 #endif