COIN-OR::LEMON - Graph Library

Changeset 2623:90defb96ee61 in lemon-0.x


Ignore:
Timestamp:
10/06/08 17:08:17 (10 years ago)
Author:
Peter Kovacs
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@3508
Message:

Add missing pointer initializing in min cost flow classes

Location:
lemon
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • lemon/capacity_scaling.h

    r2620 r2623  
    256256                     const SupplyMap &supply ) :
    257257      _graph(graph), _lower(&lower), _capacity(graph), _cost(cost),
    258       _supply(graph), _flow(0), _local_flow(false),
    259       _potential(0), _local_potential(false),
    260       _res_cap(graph), _excess(graph), _pred(graph)
     258      _supply(graph), _flow(NULL), _local_flow(false),
     259      _potential(NULL), _local_potential(false),
     260      _res_cap(graph), _excess(graph), _pred(graph), _dijkstra(NULL)
    261261    {
    262262      // Removing non-zero lower bounds
     
    289289                     const SupplyMap &supply ) :
    290290      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
    291       _supply(supply), _flow(0), _local_flow(false),
    292       _potential(0), _local_potential(false),
    293       _res_cap(capacity), _excess(graph), _pred(graph)
     291      _supply(supply), _flow(NULL), _local_flow(false),
     292      _potential(NULL), _local_potential(false),
     293      _res_cap(capacity), _excess(graph), _pred(graph), _dijkstra(NULL)
    294294    {
    295295      // Checking the sum of supply values
     
    318318                     Supply flow_value ) :
    319319      _graph(graph), _lower(&lower), _capacity(graph), _cost(cost),
    320       _supply(graph), _flow(0), _local_flow(false),
    321       _potential(0), _local_potential(false),
    322       _res_cap(graph), _excess(graph), _pred(graph)
     320      _supply(graph), _flow(NULL), _local_flow(false),
     321      _potential(NULL), _local_potential(false),
     322      _res_cap(graph), _excess(graph), _pred(graph), _dijkstra(NULL)
    323323    {
    324324      // Removing non-zero lower bounds
     
    355355                     Supply flow_value ) :
    356356      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
    357       _supply(graph, 0), _flow(0), _local_flow(false),
    358       _potential(0), _local_potential(false),
    359       _res_cap(capacity), _excess(graph), _pred(graph)
     357      _supply(graph, 0), _flow(NULL), _local_flow(false),
     358      _potential(NULL), _local_potential(false),
     359      _res_cap(capacity), _excess(graph), _pred(graph), _dijkstra(NULL)
    360360    {
    361361      _supply[s] =  flow_value;
  • lemon/cost_scaling.h

    r2620 r2623  
    182182    bool _local_potential;
    183183
     184    // The residual cost map
     185    ResidualCostMap<LargeCostMap> _res_cost;
    184186    // The residual graph
    185187    ResGraph *_res_graph;
    186     // The residual cost map
    187     ResidualCostMap<LargeCostMap> _res_cost;
    188188    // The reduced cost map
    189189    ReducedCostMap *_red_cost;
     
    210210                 const SupplyMap &supply ) :
    211211      _graph(graph), _lower(&lower), _capacity(graph), _orig_cost(cost),
    212       _cost(graph), _supply(graph), _flow(0), _local_flow(false),
    213       _potential(0), _local_potential(false), _res_cost(_cost),
    214       _excess(graph, 0)
     212      _cost(graph), _supply(graph), _flow(NULL), _local_flow(false),
     213      _potential(NULL), _local_potential(false), _res_cost(_cost),
     214      _res_graph(NULL), _red_cost(NULL), _excess(graph, 0)
    215215    {
    216216      // Removing non-zero lower bounds
     
    242242                 const SupplyMap &supply ) :
    243243      _graph(graph), _lower(NULL), _capacity(capacity), _orig_cost(cost),
    244       _cost(graph), _supply(supply), _flow(0), _local_flow(false),
    245       _potential(0), _local_potential(false), _res_cost(_cost),
    246       _excess(graph, 0)
     244      _cost(graph), _supply(supply), _flow(NULL), _local_flow(false),
     245      _potential(NULL), _local_potential(false), _res_cost(_cost),
     246      _res_graph(NULL), _red_cost(NULL), _excess(graph, 0)
    247247    {
    248248      // Checking the sum of supply values
     
    271271                 Supply flow_value ) :
    272272      _graph(graph), _lower(&lower), _capacity(graph), _orig_cost(cost),
    273       _cost(graph), _supply(graph), _flow(0), _local_flow(false),
    274       _potential(0), _local_potential(false), _res_cost(_cost),
    275       _excess(graph, 0)
     273      _cost(graph), _supply(graph), _flow(NULL), _local_flow(false),
     274      _potential(NULL), _local_potential(false), _res_cost(_cost),
     275      _res_graph(NULL), _red_cost(NULL), _excess(graph, 0)
    276276    {
    277277      // Removing nonzero lower bounds
     
    307307                 Supply flow_value ) :
    308308      _graph(graph), _lower(NULL), _capacity(capacity), _orig_cost(cost),
    309       _cost(graph), _supply(graph, 0), _flow(0), _local_flow(false),
    310       _potential(0), _local_potential(false), _res_cost(_cost),
    311       _excess(graph, 0)
     309      _cost(graph), _supply(graph, 0), _flow(NULL), _local_flow(false),
     310      _potential(NULL), _local_potential(false), _res_cost(_cost),
     311      _res_graph(NULL), _red_cost(NULL), _excess(graph, 0)
    312312    {
    313313      _supply[s] =  flow_value;
  • lemon/cycle_canceling.h

    r2620 r2623  
    169169                    const SupplyMap &supply ) :
    170170      _graph(graph), _lower(&lower), _capacity(graph), _cost(cost),
    171       _supply(graph), _flow(0), _local_flow(false),
    172       _potential(0), _local_potential(false), _res_cost(_cost)
     171      _supply(graph), _flow(NULL), _local_flow(false),
     172      _potential(NULL), _local_potential(false), _res_graph(NULL),
     173      _res_cost(_cost)
    173174    {
    174175      // Removing non-zero lower bounds
     
    199200                    const SupplyMap &supply ) :
    200201      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
    201       _supply(supply), _flow(0), _local_flow(false),
    202       _potential(0), _local_potential(false), _res_cost(_cost)
     202      _supply(supply), _flow(NULL), _local_flow(false),
     203      _potential(NULL), _local_potential(false), _res_graph(NULL),
     204      _res_cost(_cost)
    203205    {
    204206      // Checking the sum of supply values
     
    227229                    Supply flow_value ) :
    228230      _graph(graph), _lower(&lower), _capacity(graph), _cost(cost),
    229       _supply(graph), _flow(0), _local_flow(false),
    230       _potential(0), _local_potential(false), _res_cost(_cost)
     231      _supply(graph), _flow(NULL), _local_flow(false),
     232      _potential(NULL), _local_potential(false), _res_graph(NULL),
     233      _res_cost(_cost)
    231234    {
    232235      // Removing non-zero lower bounds
     
    262265                    Supply flow_value ) :
    263266      _graph(graph), _lower(NULL), _capacity(capacity), _cost(cost),
    264       _supply(graph, 0), _flow(0), _local_flow(false),
    265       _potential(0), _local_potential(false), _res_cost(_cost)
     267      _supply(graph, 0), _flow(NULL), _local_flow(false),
     268      _potential(NULL), _local_potential(false), _res_graph(NULL),
     269      _res_cost(_cost)
    266270    {
    267271      _supply[s] =  flow_value;
  • lemon/network_simplex.h

    r2619 r2623  
    3232#include <lemon/smart_graph.h>
    3333#include <lemon/math.h>
    34 
    35 #define _DEBUG_
    3634
    3735namespace lemon {
     
    610608      _pred_edge(_graph), _thread(_graph), _forward(_graph),
    611609      _state(_graph), _red_cost(_graph, _cost, _potential),
    612       _flow_result(0), _potential_result(0),
     610      _flow_result(NULL), _potential_result(NULL),
    613611      _local_flow(false), _local_potential(false),
    614612      _node_ref(graph), _edge_ref(graph)
     
    660658      _pred_edge(_graph), _thread(_graph), _forward(_graph),
    661659      _state(_graph), _red_cost(_graph, _cost, _potential),
    662       _flow_result(0), _potential_result(0),
     660      _flow_result(NULL), _potential_result(NULL),
    663661      _local_flow(false), _local_potential(false),
    664662      _node_ref(graph), _edge_ref(graph)
     
    704702      _pred_edge(_graph), _thread(_graph), _forward(_graph),
    705703      _state(_graph), _red_cost(_graph, _cost, _potential),
    706       _flow_result(0), _potential_result(0),
     704      _flow_result(NULL), _potential_result(NULL),
    707705      _local_flow(false), _local_potential(false),
    708706      _node_ref(graph), _edge_ref(graph)
     
    754752      _pred_edge(_graph), _thread(_graph), _forward(_graph),
    755753      _state(_graph), _red_cost(_graph, _cost, _potential),
    756       _flow_result(0), _potential_result(0),
     754      _flow_result(NULL), _potential_result(NULL),
    757755      _local_flow(false), _local_potential(false),
    758756      _node_ref(graph), _edge_ref(graph)
Note: See TracChangeset for help on using the changeset viewer.