Changeset 94a967 in git


Ignore:
Timestamp:
Jun 19, 2008, 5:58:18 PM (15 years ago)
Author:
Hans Schönemann <hannes@…>
Branches:
(u'spielwiese', '828514cf6e480e4bafc26df99217bf2a1ed1ef45')
Children:
6f49c34b8c235506ef7d34be2d0cd7b9ed4f708d
Parents:
4f48983e2d88ea0745d1992935e0f1c7b97642d0
Message:
*hannes: format


git-svn-id: file:///usr/local/Singular/svn/trunk@10768 2c84dea3-7e68-4137-9b89-c4e89433aadc
Location:
factory
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • factory/canonicalform.cc

    r4f4898 r94a967  
    11/* emacs edit mode for this file is -*- C++ -*- */
    2 /* $Id: canonicalform.cc,v 1.41 2007-12-04 15:24:53 Singular Exp $ */
     2/* $Id: canonicalform.cc,v 1.42 2008-06-19 15:57:37 Singular Exp $ */
    33
    44#include <config.h>
     
    252252            else
    253253                return *this;
    254         else  if ( CFFactory::gettype() == PrimePowerDomain ) {
     254        else  if ( CFFactory::gettype() == PrimePowerDomain )
     255        {
    255256            ASSERT( value->levelcoeff() == PrimePowerDomain || value->levelcoeff() == IntegerDomain, "no proper map defined" );
    256257            if ( value->levelcoeff() == PrimePowerDomain )
     
    259260                return CFFactory::basic( getmpi( value ) );
    260261        }
    261         else {
     262        else
     263        {
    262264            int val;
    263265            if ( value->levelcoeff() == IntegerDomain )
     
    274276                return CanonicalForm( int2imm_p( val ) );
    275277        }
    276     else {
     278    else
     279    {
    277280        Variable x = value->variable();
    278281        CanonicalForm result;
    279282        for ( CFIterator i = *this; i.hasTerms(); i++ )
    280             result += power( x, i.exp() ) * i.coeff().mapinto();
     283            result += (power( x, i.exp() ) * i.coeff().mapinto());
    281284        return result;
    282285    }
  • factory/cf_algorithm.cc

    r4f4898 r94a967  
    11/* emacs edit mode for this file is -*- C++ -*- */
    2 /* $Id: cf_algorithm.cc,v 1.12 2008-05-16 13:10:14 Singular Exp $ */
     2/* $Id: cf_algorithm.cc,v 1.13 2008-06-19 15:58:18 Singular Exp $ */
    33
    44//{{{ docu
     
    348348    int fLevel = f.level();
    349349    int gLevel = g.level();
    350     if ( gLevel > 0 && fLevel == gLevel )
     350    if ( (gLevel > 0) && (fLevel == gLevel) )
    351351        // f and g are polynomials in the same main variable
    352352        if ( degree( f ) <= degree( g )
    353353             && fdivides( f.tailcoeff(), g.tailcoeff() )
    354              && fdivides( f.LC(), g.LC() ) ) {
     354             && fdivides( f.LC(), g.LC() ) )
     355        {
    355356            CanonicalForm q, r;
    356357            return divremt( g, f, q, r ) && r.isZero();
     
    361362        // g is a coefficient w.r.t. f
    362363        return false;
    363     else {
     364    else
     365    {
    364366        // either f is a coefficient w.r.t. polynomial g or both
    365367        // f and g are from a base domain (should be Z or Z/p^n,
Note: See TracChangeset for help on using the changeset viewer.