Packages

Numeric algorithms in Elixir. Version 0.1.0 includes a Newton solver for nonlinear equations in one dimension.

Current section

Files

Jump to
fluxion lib function.ex
Raw

lib/function.ex

defmodule Fluxion.Function do
@moduledoc """
An Elixir behaviour for a mathematical function definition and it's
derivative.
"""
@type t() :: module()
@doc "evaluate the function f(x) at x"
@callback f(number) :: number
@doc "evaluate f'(x) at x"
@callback dfdx(number) :: number
end