Ejemplo n.º 1
0
          Fonc_Num_Computed * compute (const Arg_Fonc_Num_Comp & arg)
          {
    
              Box2di b(0);
              Tjs_El_User.ElAssert
              (
                   arg.flux()->is_rect_2d(b),
                   EEM0 << "Must use operator created  by `create_op_buf_simple_tpl'"
                        << " with 2D rectangle flux"
              );


              INT nbpcky = mOptimizeNbPackY                               ?
                           adjust_nb_pack_y(_nb_pack_y,b._p1.y-b._p0.y)   :
                           _nb_pack_y                                     ;

              Simple_OPBuf_Gen * calc = 0;

              if (_f.integral_fonc(true))
                 calc = _calc_I;
              else
                 calc = _calc_R;

              Fonc_Num f =  calc->adapt_box(_f,b);

              if (f.integral_fonc(true))
                 return new Simple_Buffered_Op_Comp<INT,Itin> 
                            (arg,_dim_out,f,_side,_calc_I,nbpcky,mCatFoncInit);
              else
                 return new Simple_Buffered_Op_Comp<REAL,Rtin>
                            (arg,_dim_out,f,_side,_calc_R,nbpcky,mCatFoncInit);
          }
Ejemplo n.º 2
0
 virtual bool  integral_fonc (bool iflx) const 
 {return _f.integral_fonc(iflx);}