toms571, a Fortran77 code which implements ACM toms algorithm 571, containing routines to determine the concentration parameter from the average modulus of a set of sample vectors, and vice versa, for both the von Mises (circular) and Fisher (spherical) distributions of directions.
The text of many ACM toms algorithms is available online through ACM: https://www.acm.org/pubs/calgo or NETLIB: https://www.netlib.org/toms/index.html.
The information on this web page is distributed under the MIT license.
toms571 is available in a Fortran77 version.
prob, a Fortran90 library which contains routines to sample the von Mises and Fisher distributions.