MCPcopy Create free account
hub / github.com/Singular/Singular / maxNorm

Function maxNorm

factory/cf_algorithm.cc:535–549  ·  view source on GitHub ↗

CanonicalForm maxNorm ( const CanonicalForm & f ) * * * maxNorm() - return maximum norm of `f'. * * That is, the base coefficient of `f' with the largest absolute * value. * * Valid for arbitrary polynomials over arbitrary domains, but * most useful for multivariate polynomials over Z. * * Type info: * ---------- * f: CurrentPP * **/

Source from the content-addressed store, hash-verified

533 *
534**/
535CanonicalForm
536maxNorm ( const CanonicalForm & f )
537{
538 if ( f.inBaseDomain() )
539 return abs( f );
540 else {
541 CanonicalForm result = 0;
542 for ( CFIterator i = f; i.hasTerms(); i++ ) {
543 CanonicalForm coeffMaxNorm = maxNorm( i.coeff() );
544 if ( coeffMaxNorm > result )
545 result = coeffMaxNorm;
546 }
547 return result;
548 }
549}
550
551/** CanonicalForm euclideanNorm ( const CanonicalForm & f )
552 *

Callers 8

absBiFactorizeMainFunction · 0.85
modGCDZFunction · 0.85
gcd_poly_univar0Function · 0.85
coeffBound_oldFunction · 0.85
gcd_poly_univar0Function · 0.85
modularIrredTestFunction · 0.85
coeffBoundFunction · 0.85
modularDiophantFunction · 0.85

Calls 4

hasTermsMethod · 0.80
absFunction · 0.70
inBaseDomainMethod · 0.45
coeffMethod · 0.45

Tested by

no test coverage detected