Jumper icon indicating copy to clipboard operation
Jumper copied to clipboard

Include weighting for A-star based search algorithms

Open Yonaba opened this issue 10 years ago • 0 comments

I should consider including weighting for A-star based search algorithms when summing G-cost and H-cost to compose F-cost.

local function weightedF(G, H, alpha)
  alpha = alpha or 0.5
  return alpha * G + (1 - alpha) * H
end

The purpose of this is to give full control to balance between Dijkstra search (alpha = 1), Classical A-Star (alpha = 0,5) and Best-First-Search (alpha = 0).

Yonaba avatar Jan 24 '14 10:01 Yonaba