github ↗
docs menu

Module Norn.Support

Sets of values a distribution gives positive density.

A support names the set; it carries the bounds that do not depend on a tensor. Each continuous support has one bijector (Norn.Bij) whose coordinates cover it.

#type t =
  1. #| Real
    (*

    The real numbers.

    *)
  2. #| Greater of float
    (*

    The reals above a bound, exclusive.

    *)
  3. #| Less of float
    (*

    The reals below a bound, exclusive.

    *)
  4. #| Interval of float * float
    (*

    The reals between two bounds, exclusive.

    *)
  5. #| Simplex of int
    (*

    Vectors of n positive components that sum to one.

    *)
  6. #| Ordered
    (*

    Vectors whose components strictly increase.

    *)
  7. #| Correlation_cholesky of int
    (*

    Lower-triangular n × n matrices with a positive diagonal and rows of unit norm: Cholesky factors of correlation matrices.

    *)
  8. #| Sum_to_zero
    (*

    Vectors whose components sum to zero.

    *)
  9. #| Integers_from of int
    (*

    The integers from a bound, inclusive.

    *)
  10. #| Integer_interval of int * int
    (*

    The integers between two bounds, inclusive.

    *)
  11. #| Boolean
    (*

    false and true.

    *)

The type for supports.

#val equal : t -> t -> bool

equal s s' is true iff s and s' are the same constructor with equal arguments, floats compared with Float.equal.

#val pp : Stdlib.Format.formatter -> t -> unit

pp ppf s formats s as a set: (-inf, inf), (0, inf), (-inf, 0), (0, 1), {0, 1, 2, ...}, {0, 1, ..., 10}, {false, true}, or a phrase such as simplex of 3.