Re: [eigen] compiles (Re: specializing void MatrixBase<Derived>::makeHouseholder)

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


On 2016-09-12 12:50, Peter wrote:
template<typename Scalar, typename RealScalar, typename EssentialPart>
void handle_householder_zero( Scalar& tau, RealScalar& beta,
EssentialPart& essential , const RealScalar& tol, const Scalar& c0)
{
    tau=0;
    beta = 0;

beta should still be numext::real(c0); here.

Overall, we might consider including such change, if you actually found a solution for your use case (maybe this allows/requires specializing less/more of the method).
But I guess you are ok with a local change, while you are debugging.

Christoph


    essential.setZero();
}

[ ...]

  if(tailSqNorm <= tol && numext::abs2(numext::imag(c0))<=tol)
  {
    //tau = RealScalar(0);
    //beta = numext::real(c0);
    //essential.setZero();
    handle_householder_zero( tau, beta, essential, tol, c0 );
  }

And in my code

template<typename EssentialPart>
void handle_householder_zero( TpFloat& tau, TpRFloat& beta,
EssentialPart& essential, const TpRFloat&  tol, const TpFloat& c0 )
{
    tau=0;
    beta = 0;
    essential.setZero();
    std::cerr << "tol: " << tau << " c0: " << c0 << std::endl;
}

calls my specialization.
So, I can now start looking for a solution.

Thanks for your help,
Peter




--
 Dipl. Inf., Dipl. Math. Christoph Hertzberg

 Universität Bremen
 FB 3 - Mathematik und Informatik
 AG Robotik
 Robert-Hooke-Straße 1
 28359 Bremen, Germany

 Zentrale: +49 421 178 45-6611

 Besuchsadresse der Nebengeschäftsstelle:
 Robert-Hooke-Straße 5
 28359 Bremen, Germany

 Tel.:    +49 421 178 45-4021
 Empfang: +49 421 178 45-6600
 Fax:     +49 421 178 45-4150
 E-Mail:  chtz@xxxxxxxxxxxxxxxxxxxxxxxx

 Weitere Informationen: http://www.informatik.uni-bremen.de/robotik



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/