Several methods for planning paths in a terrain represented by a digital map under different strategies and constraints for an autonomous vehicle are presented. The planning task is formulated as a variational problem in a space with a non-Euclidean metric depending on the applied strategy. The resulting nonlinear Hamilton-Jakobi equation can be approximated by a linear Fokker-Planck equation suitable for analytical calculations. Furthermore, an efficient dynamic programming algorithm is presented with complexity linear in the points of the discretized space. Because of the digitization bias, a second calculation step based on direct optimization can be appended. The method is applied to plan optimal flight paths in three dimensions.