Logo Search packages:      
Sourcecode: inkscape version File versions

Piecewise< SBasis > Geom::signSb ( Piecewise< SBasis > const &  f  ) 

Return the sign of the two functions pointwise.

f function

Definition at line 130 of file sbasis-math.cpp.

References partition(), Geom::Piecewise< T >::segs, sign(), and Geom::Piecewise< T >::size().

    Piecewise<SBasis> sign=partition(f,roots(f));
    for (unsigned i=0; i<sign.size(); i++){
        sign.segs[i] = (sign.segs[i](.5)<0)? Linear(-1.):Linear(1.);
    return sign;

Generated by  Doxygen 1.6.0   Back to index