Ignore:
Timestamp:
Jul 3, 2013, 4:12:21 PM (11 years ago)
Author:
Yue Ren <ren@…>
Branches:
(u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
Children:
47e8b0441e7692a4a4b6c2f23817976fe5203f1c
Parents:
f80a5305e1e0960855d4bd8702e48d1c2bbf8710
git-author:
Yue Ren <ren@mathematik.uni-kl.de>2013-07-03 16:12:21+02:00
git-committer:
Yue Ren <ren@mathematik.uni-kl.de>2013-07-18 14:56:51+02:00
Message:
chg: print routines for polyhedral cones

corresponds to a2e8ff135c1975091940c626c92759347447fa73 in master
File:
1 edited

Legend:

Unmodified
Added
Removed
  • dyn_modules/callgfanlib/bbcone.cc

    rf80a530 rc8e115  
    120120{
    121121  std::stringstream s;
    122   gfan::ZMatrix i=c->getInequalities();
    123   gfan::ZMatrix e=c->getEquations();
    124122  s<<"AMBIENT_DIM"<<std::endl;
    125123  s<<c->ambientDimension()<<std::endl;
     124
     125  gfan::ZMatrix i=c->getInequalities();
     126  char* ineqs = toString(i);
    126127  if (c->areFacetsKnown())
    127128    s<<"FACETS"<<std::endl;
    128129  else
    129130    s<<"INEQUALITIES"<<std::endl;
    130   s<<toString(i)<<std::endl;
    131   // std::cout << toString(i) << std::endl;
     131  if (ineqs!=NULL)
     132  {
     133    s<<ineqs<<std::endl;
     134    delete ineqs;
     135  }
     136
     137  gfan::ZMatrix e=c->getEquations();
     138  char* eqs = toString(e);
    132139  if (c->areImpliedEquationsKnown())
    133140    s<<"LINEAR_SPAN"<<std::endl;
    134141  else
    135142    s<<"EQUATIONS"<<std::endl;
    136   s<<toString(e)<<std::endl;
    137   // std::cout << toString(e) << std::endl;
     143  if (eqs!=NULL)
     144  {
     145    s<<eqs<<std::endl;
     146    delete eqs;
     147  }
     148
     149  if (c->areExtremeRaysKnown())
     150  {
     151    gfan::ZMatrix r=c->extremeRays();
     152    char* rs = toString(r);
     153    s<<"RAYS"<<std::endl;
     154    if (rs!=NULL)
     155    {
     156      s<<rs<<std::endl;
     157      delete rs;
     158    }
     159    gfan::ZMatrix l=c->generatorsOfLinealitySpace();
     160    char* ls = toString(l);
     161    s<<"LINEALITY_SPACE"<<std::endl;
     162    if (ls!=NULL)
     163    {
     164      s<<ls<<std::endl;
     165      delete ls;
     166    }
     167  }
     168
    138169  return s.str();
    139170}
Note: See TracChangeset for help on using the changeset viewer.