Command-line interface

Numerov.jl ships a Comonicon-based command-line interface. Install the numerov command once:

julia> using Numerov

julia> Numerov.CLI.comonicon_install()

This places a numerov executable in ~/.julia/bin (add that directory to your PATH). Then:

numerov input.in      # run a calculation
numerov --help        # usage and argument description
numerov --version     # package version

The CLI writes the same output files as numerov, into the current working directory. Invalid input prints a single-line error message and exits with a nonzero status instead of a stacktrace; when calling the library function numerov from Julia instead, the same errors are thrown as catchable ArgumentErrors.

Without installing the shim, the same entry point is available as a script:

julia --project=<Numerov.jl dir> <Numerov.jl dir>/bin/numerov.jl input.in

Entry point

Numerov.CLIModule

CLI entry point. Lives in a submodule so the command can be named numerov without clashing with the library function of the same name; user errors are printed as a single line instead of a stacktrace.

source
Numerov.CLI.numerovFunction

numerov - solve the Schrödinger equation using the Numerov method.

Intro

Runs a full Numerov calculation: reads the input file, solves the 1D, 2D or 3D time-independent Schrödinger equation on the grid potential defined therein and writes the resulting eigenvalues, eigenvectors and frequencies - and, if requested, the band structure - to .dat files together with a log file (default: Numerov.out). All output files are written to the current working directory; an existing eigenvalues.dat file is deleted before the new eigenvalues are written.

Args

  • inputFileName: The name of the input file.
source