Changeset 3191 in Sophya for trunk/Cosmo/RadioBeam/multicyl.cc


Ignore:
Timestamp:
Mar 19, 2007, 9:29:05 AM (19 years ago)
Author:
legoff
Message:

Cylinders have different x positions (NS).
This is taken into account in the signal phase shift
and in the exp() term when combining cylinders.
We can have more bins in x than antennas in one cylinder
to see the gain in resolution along x due to several cylinders at different x

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Cosmo/RadioBeam/multicyl.cc

    r3163 r3191  
    8484void MultiCylinders::ReconstructSourceBox(int halfny, double stepangy)
    8585{
    86 
    8786  ReconstructCylinderPlaneS(true);
    8887  TMatrix< complex<r_4> > & mtx = GetCylinder(0).getRecSrcPlane();
    8988  // boite 3D X:angX, Y:angY , Z: freq
    9089  sa_size_t sz[5] = {0,0,0,0,0};
    91   sz[0] = mtx.NCols();
     90//  int nx=mtx.NCols(); // uncomment to go back to nxbin = nantenna
     91  int nx=256;
     92  sz[0] = nx;
    9293  sz[1] = halfny*2+1;
    9394  sz[2] = mtx.NRows();
     
    113114
    114115      double facl = - 2*M_PI*frq*cyl.getCylinderYPos();  // attention au signe -
     116//      double facl_x = - 2*M_PI*cyl.getCylinderXPos()/cyl.Da/(double)cyl.NR;
     117      double facl_x = - 2*M_PI*cyl.getCylinderXPos()/cyl.Da;
    115118      double dphi;
    116119      complex< r_4 > phasefactor;
    117120      int jyy = 0;
    118121      for(int jy=-halfny; jy<=halfny; jy++) {  // Loop over Y angular steps
    119         double dphi = facl * sin( (double)jy*stepangy );
    120         phasefactor = complex< r_4 > ((r_4) cos(dphi) , (r_4) sin(dphi));
    121         for(int ix=0; ix<sz[0]; ix++) {  // Loop over AngX directions
     122        for(int ix=0; ix<nx; ix++) {  // Loop over AngX directions
     123          double dphi = facl * sin( (double)jy*stepangy )
     124                        + facl_x*(double(ix)/double(nx)-1./2.);
     125          phasefactor = complex< r_4 > ((r_4) cos(dphi) , (r_4) sin(dphi));
    122126          // sur recp : index ligne -> frequence  ,    index colonne -> angX ,
    123           box(ix, jyy, kf) += recp(kf, ix)*phasefactor;
     127          int ixx=(int)(ix*(double)cyl.NR/double(nx));
     128          box(ix, jyy, kf) += recp(kf, ixx)*phasefactor;
    124129        }  // 
    125130        jyy++;
Note: See TracChangeset for help on using the changeset viewer.