nv-number-basic

nv-number-basic =============== - nv-number-basic

Usage no npm install needed!

<script type="module">
  import nvNumberBasic from 'https://cdn.skypack.dev/nv-number-basic';
</script>

README

nv-number-basic

  • nv-number-basic

install

  • npm install nv-number-basic

usage

example

const num_bsc = require("nv-number-basic");

> num_bsc.bigint_to_safe_ary(111111111111111111n)
[ 3024720054219219, 12 ]
> BigInt(Number.MAX_SAFE_INTEGER) * 12n + 3024720054219219n
111111111111111111n
>

APIS

{
  TYPE_DICT: {
    NumericLiteral: 5,
    Integer: 6,
    Float: 7,
    BigInt: 8,
    PosInfinity: 9,
    NegInfinity: 10,
    NaN: 11
  },
  is_num: [Function: is_num],
  is_float: [Function: is_float],
  is_int: [Function: is_int],
  is_infinity: [Function: is_infinity],
  is_nan: [Function: is_nan],
  is_abnormal_num: [Function: is_abnormal_num],
  is_normal_num: [Function: is_normal_num],
  is_bigint: [Function: is_bigint],
  is_int_or_bigint: [Function: is_int_or_bigint],
  bwidth: [Function: bwidth],
  owidth: [Function: owidth],
  dwidth: [Function: dwidth],
  xwidth: [Function: xwidth],
  nwidth: [Function: nwidth],
  int: [Function: int],
  bigint: [Function: bigint],
  is_pow2_int: [Function: is_pow2_int],
  is_pow2_bigint: [Function: is_pow2_bigint],
  is_pow2: [Function: is_pow2],
  uround_pow2_int: [Function: uround_pow2_int],
  uround_pow2_bigint: [Function: uround_pow2_bigint],
  uround_pow2: [Function: uround_pow2],
  lround_pow2_int: [Function: lround_pow2_int],
  lround_pow2_bigint: [Function: lround_pow2_bigint],
  lround_pow2: [Function: lround_pow2],
  fiseq: [Function: fiseq],
  fixy: [Function: fixy],
  fix: [Function: fix],
  fiy: [Function: fiy],
  fidiag: [Function: fidiag],
  fbiseq: [Function: fbiseq],
  fbixy: [Function: fbixy],
  fbix: [Function: fbix],
  fbiy: [Function: fbiy],
  fbidiag: [Function: fbidiag],
  iseq: [Function: iseq],
  ixy: [Function: ixy],
  ix: [Function: ix],
  iy: [Function: iy],
  idiag: [Function: idiag],
  biseq: [Function: biseq],
  bixy: [Function: bixy],
  bix: [Function: bix],
  biy: [Function: biy],
  bidiag: [Function: bidiag],
  creat_fiseq: [Function (anonymous)],
  creat_fbiseq: [Function (anonymous)],
  creat_fixy: [Function (anonymous)],
  creat_fix: [Function (anonymous)],
  creat_fiy: [Function (anonymous)],
  creat_fbixy: [Function (anonymous)],
  creat_fbix: [Function (anonymous)],
  creat_fbiy: [Function (anonymous)],
  creat_fidiag: [Function (anonymous)],
  creat_fbidiag: [Function (anonymous)],
  creat_iseq: [Function (anonymous)],
  creat_biseq: [Function (anonymous)],
  creat_ixy: [Function (anonymous)],
  creat_ix: [Function (anonymous)],
  creat_iy: [Function (anonymous)],
  creat_bixy: [Function (anonymous)],
  creat_bix: [Function (anonymous)],
  creat_biy: [Function (anonymous)],
  creat_idiag: [Function (anonymous)],
  creat_bidiag: [Function (anonymous)],
  q: [Function: q],
  int_fmid: [Function (anonymous)],
  bi_fmid: [Function (anonymous)],
  int_tmid: [Function (anonymous)],
  bi_tmid: [Function (anonymous)],
  int_sqrt: [Function (anonymous)],
  bigint_sqrt: [Function (anonymous)],
  is_square_int: [Function (anonymous)],
  is_square_bigint: [Function (anonymous)],
  radix_ary: [Function: radix_ary],
  bigint_radix_ary: [Function: bigint_radix_ary],
  radix_gen: [GeneratorFunction: radix_gen],
  bigint_radix_gen: [GeneratorFunction: bigint_radix_gen],
  n2ch: [Function: n2ch],
  bn2ch: [Function: bn2ch],
  ch2n: [Function: ch2n],
  ch2bn: [Function: ch2bn],
  radix_str: [Function: radix_str],
  bigint_radix_str: [Function: bigint_radix_str],
  MAX_SAFE_INT_BN: 9007199254740991n,
  bigint_to_safe_ary: [Function: bigint_to_safe_ary]
}

LICENSE

  • ISC