  Efficiently planning an Unmanned Aerial Vehicle (UAV) path is crucial,
especially in dynamic settings where potential threats are prevalent. A Dynamic
Path Planner (DPP) for UAV using the Spherical Vector-based Particle Swarm
Optimisation (SPSO) technique is proposed in this study. The UAV is supposed to
go from a starting point to an end point through an optimal path according to
some flight criteria. Path length, Safety, Attitude and Path Smoothness are all
taken into account upon deciding how an optimal path should be. The path is
constructed as a set of way-points that stands as re-planning checkpoints. At
each path way-point, threats are allowed some constrained random motion, where
their exact positions are updated and fed to the SPSO-solver. Four test
scenarios are carried out using real digital elevation models. Each test gives
different priorities to path length and safety, in order to show how well the
SPSO-DPP is capable of generating a safe yet efficient path segments. Finally,
a comparison is made to reveal the persistent overall superior performance of
the SPSO, in a dynamic environment, over both the Particle Swarm Optimisation
(PSO) and the Genetic Algorithm (GA). The methods are compared directly, by
averaging costs over multiple runs, and by considering different challenging
levels of obstacle motion. SPSO outperformed both PSO and GA, showcasing cost
reductions ranging from 330\% to 675\% compared to both algorithms.
