MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / getRuleSet

Method getRuleSet

src/compute-engine/index.ts:1870–1925  ·  view source on GitHub ↗

* Return a set of built-in rules.

(id?: string)

Source from the content-addressed store, hash-verified

1868 * - `isZero()`
1869 * - `sign()` (1, 0 or -1)
1870 *
1871 */
1872 bignum(a: string | number | bigint | BigDecimal): BigDecimal {
1873 return this._numericConfiguration.bignum(a);
1874 }
1875
1876 /** Create a complex number.
1877 * The return value is an object with methods to perform arithmetic
1878 * operations:
1879 * - `re` (real part, as a JavaScript `number`)
1880 * - `im` (imaginary part, as a JavaScript `number`)
1881 * - `add()`
1882 * - `sub()`
1883 * - `neg()` (unary minus)
1884 * - `mul()`
1885 * - `div()`
1886 * - `pow()`
1887 * - `sqrt()` (square root)
1888 * - `exp()` (e^x)
1889 * - `log()`
1890 * - `ln()` (natural logarithm)
1891 * - `mod()`
1892
1893 * - `abs()`
1894 * - `ceil()`
1895 * - `floor()`
1896 * - `round()`
1897
1898 * - `arg()` the angle of the complex number
1899 * - `inverse()` the inverse of the complex number 1/z
1900 * - `conjugate()` the conjugate of the complex number
1901
1902 * - `equals()`
1903 *
1904 * - `cos()`
1905 * - `sin()`
1906 * - `tanh()`
1907 * - `acos()`
1908 * - `asin()`
1909 * - `atan()`
1910 * - `cosh()`
1911 * - `sinh()`
1912 * - `acosh()`
1913 * - `asinh()`
1914 * - `atanh()`
1915 *
1916 * - `isFinite()`
1917 * - `isNaN()`
1918 * - `isZero()`
1919 * - `sign()` (1, 0 or -1)
1920 */
1921 complex(a: number | BigDecimal | Complex, b?: number | BigDecimal): Complex {
1922 if (a instanceof BigDecimal) a = a.toNumber();
1923 if (b instanceof BigDecimal) b = b.toNumber();
1924 return new Complex(a, b);
1925 }
1926
1927 /**

Callers

nothing calls this directly

Calls 6

_cacheMethod · 0.95
boxRulesFunction · 0.90
aggregateHotHeadDispatchFunction · 0.90
invalidateMethod · 0.80
markCachedMethod · 0.80

Tested by

no test coverage detected