78 |
|
} |
79 |
|
|
80 |
|
|
81 |
< |
abstract static class MatrixTree extends CountedCompleter { |
81 |
> |
abstract static class MatrixTree extends CountedCompleter<Void> { |
82 |
|
// maximum difference between old and new values |
83 |
|
double maxDiff; |
84 |
< |
MatrixTree(CountedCompleter p, int c) { super(p, c); } |
84 |
> |
MatrixTree(CountedCompleter<?> p, int c) { super(p, c); } |
85 |
|
} |
86 |
|
|
87 |
|
|
95 |
|
|
96 |
|
int steps = 0; // track even/odd steps |
97 |
|
|
98 |
< |
LeafNode(CountedCompleter p, |
98 |
> |
LeafNode(CountedCompleter<?> p, |
99 |
|
double[][] A, double[][] B, |
100 |
|
int loRow, int hiRow, |
101 |
|
int loCol, int hiCol) { |
125 |
|
} |
126 |
|
|
127 |
|
maxDiff = md; |
128 |
< |
tryComplete(); |
128 |
> |
tryComplete(); |
129 |
|
} |
130 |
|
} |
131 |
|
|
134 |
|
MatrixTree q2; |
135 |
|
MatrixTree q3; |
136 |
|
MatrixTree q4; |
137 |
< |
FourNode(CountedCompleter p) { |
137 |
> |
FourNode(CountedCompleter<?> p) { |
138 |
|
super(p, 3); |
139 |
|
} |
140 |
|
|
141 |
< |
public void onCompletion(CountedCompleter caller) { |
141 |
> |
public void onCompletion(CountedCompleter<?> caller) { |
142 |
|
double md = q1.maxDiff, m; |
143 |
|
if ((m = q2.maxDiff) > md) |
144 |
|
md = m; |
163 |
|
MatrixTree q1; |
164 |
|
MatrixTree q2; |
165 |
|
|
166 |
< |
TwoNode(CountedCompleter p) { |
166 |
> |
TwoNode(CountedCompleter<?> p) { |
167 |
|
super(p, 1); |
168 |
|
} |
169 |
|
|
170 |
< |
public void onCompletion(CountedCompleter caller) { |
170 |
> |
public void onCompletion(CountedCompleter<?> caller) { |
171 |
|
double md = q1.maxDiff, m; |
172 |
|
if ((m = q2.maxDiff) > md) |
173 |
|
md = m; |