Ignore:
Timestamp:
Jun 1, 2006, 1:34:50 PM (19 years ago)
Author:
ansari
Message:

1/ passage en sa_size_t (au lieu de int) dans Alm<T> et Bm<T>
2/ Ajout des methodes optimisees (statiques) pour calcul transforme Ylm
ds LambdaLMBuilder et utilisation ds SphericalTransformServer

Reza , 1/06/2006

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaLib/Samba/sphericaltransformserver.cc

    r2872 r2958  
    232232      //              b(m,theta) = sum_over_l>m (lambda_l_m(theta) * a_l_m)
    233233      //              ------------------------------------------------------
     234      // ===> Optimisation Reza, Mai 2006
     235      /*---  Le bout de code suivant est remplace par l'appel a la nouvelle fonction
     236        qui calcule la somme au vol
    234237      LambdaLMBuilder lb(theta,nlmax,nmmax);
    235238      //  somme sur m de 0 a l'infini
    236       int m;
    237       for (m = 0; m <= nmmax; m++)
     239      for (int_4 m = 0; m <= nmmax; m++)
    238240        {
    239241          b_m_theta(m) = (T)( lb.lamlm(m,m) ) * alm(m,m);
     
    243245            }
    244246        }
     247      ------- Fin version PRE-Mai2006 */
     248      LambdaLMBuilder::ComputeBmFrAlm(theta,nlmax,nmmax, alm, b_m_theta);
     249      //Fin Optimisation Reza, Mai 2006 <====
     250
    245251    //        obtains the negative m of b(m,theta) (= complex conjugate)
    246252
    247       for (m=1;m<=nmmax;m++)
     253      for (int_4 m=1;m<=nmmax;m++)
    248254        {
    249255          b_m_theta(-m) = conj(b_m_theta(m));
     
    555561//      for each m and l
    556562//      -----------------------------------------------------------------------
     563
     564      // ===> Optimisation Reza, Mai 2006
     565      /*---  Le bout de code suivant est remplace par l'appel a la nouvelle fonction
     566        qui calcule la somme au vol
    557567      //        PrtTim("avant instanciation LM ");
    558568      LambdaLMBuilder lb(theta,nlmax,nmmax);
     
    576586            }
    577587        }
     588      ------- Fin version PRE-Mai2006 */
     589      r_8 domega=map.PixSolAngle(map.PixIndexSph(theta,phi0));
     590      phase *= complex<T>((T)domega, 0.);
     591      LambdaLMBuilder::ComputeAlmFrPhase(theta,nlmax,nmmax, phase, alm);
     592      //Fin Optimisation Reza, Mai 2006 <====
    578593     
    579594
Note: See TracChangeset for help on using the changeset viewer.