Go to the source code of this file.
◆ sm_maximal_independent_set()
Definition at line 44 of file indep.c.
47{
48 register sm_row *best_row, *prow;
50 int least_weight;
54
56 B = build_intersection_matrix(A);
57
58 while (B->
nrows > 0) {
59
63 best_row = prow;
64 }
65 }
66
67
68 if (weight ==
NIL(
int)) {
69 least_weight = 1;
70 } else {
72 least_weight = weight[prow->
first_col->col_num];
74 if (weight[
p->col_num] < least_weight) {
75 least_weight = weight[
p->col_num];
76 }
77 }
78 }
79 indep->
cost += least_weight;
81
82
87 }
89 }
90
92
93
94
95
96
97
98 return indep;
99}
solution_t * solution_alloc()
struct solution_struct solution_t
typedefABC_NAMESPACE_HEADER_START struct sm_element_struct sm_element
#define sm_get_row(A, rownum)
sm_element * sm_row_insert()
struct sm_matrix_struct sm_matrix
struct sm_row_struct sm_row