Cithakan:Truecomp
1
{{ truecomp | x | y | op | tolerance }}
Performs the comparison " x op y " subject to the condition that x = y if the fractional difference between x and y is less than tolerance.
Allowed values of op are:
- =
- <>
- >
- <
- >= (must be escaped as ">{{=}}", due to template quirks)
- <= (must be escaped as "<{{=}}", due to template quirks)
Returns 1 if true and 0 if false.
If omitted, tolerance defaults to 1e-11.