@@ -235,24 +235,24 @@ private void contractNodesUsingHeuristicNodeOrdering() {
235
235
checkCounter = 0 ;
236
236
final long logSize = params .getLogMessagesPercentage () == 0
237
237
? Long .MAX_VALUE
238
- : Math .round (Math .max (10 , initSize * params .getLogMessagesPercentage () / 100d ));
238
+ : Math .round (Math .max (10 , initSize * ( params .getLogMessagesPercentage () / 100d ) ));
239
239
240
240
// specifies after how many contracted nodes the queue of remaining nodes is rebuilt. this takes time but the
241
241
// more often we do this the more up-to-date the node priorities will be
242
242
// todo: instead of using a fixed interval size maybe try adjusting it depending on the number of remaining
243
243
// nodes ?
244
244
final long periodicUpdatesCount = params .getPeriodicUpdatesPercentage () == 0
245
245
? Long .MAX_VALUE
246
- : Math .round (Math .max (10 , initSize * params .getPeriodicUpdatesPercentage () / 100d ));
246
+ : Math .round (Math .max (10 , initSize * ( params .getPeriodicUpdatesPercentage () / 100d ) ));
247
247
int updateCounter = 0 ;
248
248
249
249
// enable lazy updates for last x percentage of nodes. lazy updates make preparation slower but potentially
250
250
// keep node priorities more up to date, possibly resulting in a better preparation.
251
- final long lastNodesLazyUpdates = Math .round (initSize * params .getLastNodesLazyUpdatePercentage () / 100d );
251
+ final long lastNodesLazyUpdates = Math .round (initSize * ( params .getLastNodesLazyUpdatePercentage () / 100d ) );
252
252
253
253
// according to paper "Polynomial-time Construction of Contraction Hierarchies for Multi-criteria Objectives" by Funke and Storandt
254
254
// we don't need to wait for all nodes to be contracted
255
- final long nodesToAvoidContract = Math .round (initSize * (100 - params .getNodesContractedPercentage ()) / 100d );
255
+ final long nodesToAvoidContract = Math .round (initSize * (( 100 - params .getNodesContractedPercentage ()) / 100d ) );
256
256
257
257
// Recompute priority of (the given percentage of) uncontracted neighbors. Doing neighbor updates takes additional
258
258
// time during preparation but keeps node priorities more up to date. this potentially improves query time and
0 commit comments