module Tofn:sig..end
Typed ordered fuzzy numbers (OFNs) and associated operations, following "Rings of Typed Ordered Fuzzy Numbers."
exception OFN_type_mismatch
Incompatible OFN type families.
exception Improper_OFN
An OFN is improper when it has no membership function.
type | | | Trapezoidal | 
| | | Gaussian | 
| | | Exponential | 
Supported families are trapezoidal, Gaussian, and exponential.
type |    | ofn_type :  | 
|    | au :  | 
|    | bu :  | 
|    | ad :  | 
|    | bd :  | 
}
OFN with type family  and essential tuple (au, bu, ad, bd).
Components of the tuple are represented as individual fields (as opposed to
an element of float * float * float * float) for ease-of-access.
val sametype : tofn -> tofn -> boolDetermine if two given OFNs are of the same type.
val tuplemap : (float -> float -> float) -> tofn -> tofn -> tofnApply a binary operator to the essential tuples of two OFNs.
val tuplemap_safe : (float -> float -> float) -> tofn -> tofn -> tofnApply a binary operator to the essential tuples of two OFNs only when the
types match.  Raises OFN_type_mistmatch if arguments are not of the same
type.
val inv : family -> float -> floatInverses of base functions
val (|+|) : tofn -> tofn -> tofnOFN addition.
val (|-|) : tofn -> tofn -> tofnOFN subtraction.
val (|*|) : tofn -> tofn -> tofnOFN multiplication.
val (|/|) : tofn -> tofn -> tofnOFN division
val is_increasing : tofn -> boolDetermine if an OFN is increasing.
val is_decreasing : tofn -> boolDetermine if an OFN is decreasing.
val is_proper : tofn -> boolCheck if an OFN is proper.
val membership : tofn -> float -> floatThe membership function associated to an OFN.  Raises Improper_OFN if the OFN 
is improper.
val conv_ofn : tofn -> family -> tofnConvert an OFN of one type to another type.