Ignore:
Timestamp:
Oct 18, 2010 4:20:06 PM (10 years ago)
Author:
pbelotti
Message:

improved output level (unified output level). Undoing a change by Jim that triggers a compilation error (Compute_Symmetry() is already executed within setupSymmetry()). Changed Find_Orbit to avoid copying std::vector. Cut some symmetry output.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Couenne/src/main/BonCouenne.cpp

    r407 r424  
    4747#include "CouenneProblemElem.hpp"
    4848#include "CouenneProblem.hpp"
     49#include "CouenneJournalist.hpp"
    4950
    5051#include "config_couenne.h"
     
    6061
    6162  try {
    62 
    63     printf ("\
    64 ====================================================================\n\
    65 Couenne\n\
    66 An Open-Source solver for Mixed Integer Nonlinear Optimization\n\
    67 Version: %s\n\
    68 Send questions/comments to %s\n\
    69 See http://www.coin-or.org/Couenne for more information\n\
    70 ====================================================================\n",
    71             PACKAGE_VERSION,
    72             PACKAGE_BUGREPORT
    73             );
    7463
    7564    Bonmin::Bab bb;
     
    10291    if (!couenne.InitializeCouenne (argv, p, NULL, ci, &bb))
    10392      throw infeasible;
     93
     94    // initial printout
     95
     96    ConstJnlstPtr jnlst = couenne. couennePtr () -> Jnlst ();
     97
     98    jnlst -> Printf (J_INSUPPRESSIBLE, J_COUENNE, "Couenne %s --  an Open-Source exact solver for MINLP\n", strcmp (PACKAGE_VERSION, "trunk") ? PACKAGE_VERSION : "");
     99
     100    jnlst -> Printf (J_ERROR, J_COUENNE, "\
     101Mailing list: %s\n\
     102Instructions: http://www.coin-or.org/Couenne\n",
     103            PACKAGE_BUGREPORT);
     104
     105    CouenneProblem *prob = couenne. couennePtr () -> Problem ();
     106
     107    jnlst -> Printf (J_ERROR, J_COUENNE, "\n\
     108Loaded instance \"%s\"\n\
     109Variables:       %8d (%d integer)\n\
     110Constraints:     %8d\n\
     111Auxiliaries:     %8d\n\n",
     112                     prob -> problemName ().c_str (),
     113                     prob -> nOrigVars (),
     114                     prob -> nOrigIntVars (),
     115                     prob -> nOrigCons (),
     116                     prob -> nVars () - prob -> nOrigVars ());
    104117
    105118    double time_start = CoinCpuTime();
     
    118131    //////////////////////////////////
    119132
     133    jnlst -> Printf (J_ERROR, J_COUENNE, "Starting branch-and-bound\n");
    120134    bb (couenne); // do branch and bound
    121135
     
    151165    double global_opt;
    152166    couenne.options () -> GetNumericValue ("couenne_check", global_opt, "couenne.");
     167
     168    jnlst -> Printf (J_ERROR, J_COUENNE, "\n\
     169Linearization cuts added at root node:   %8d\n\
     170Linearization cuts added in total        %8d  (separation time: %gs)\n\
     171Total solving time:                      %8gs (%gs in branch-and-bound)\n\
     172Lower bound:                           %10g\n\
     173Upper bound:                           %10g  (gap: %.2f%%)\n\
     174Branch-and-bound nodes:                  %8d\n\n",
     175                     nr, nt, st,
     176                     CoinCpuTime () - time_start,
     177                     cg ? (CoinCpuTime () - cg -> rootTime ()) : CoinCpuTime (),
     178                     bb.model (). getBestPossibleObjValue (),
     179                     bb.model (). getObjValue (),
     180                     100. * (bb.model (). getObjValue () -
     181                             bb.model (). getBestPossibleObjValue ()) / (1. + fabs (bb.model (). getBestPossibleObjValue ())),
     182                     bb.numNodes ());
    153183
    154184    if (global_opt < COUENNE_INFINITY) { // some value found in couenne.opt
Note: See TracChangeset for help on using the changeset viewer.