⨸ — Factors / Factor spec
Function. Keys: Alt-o u. Hanzi: 因. Ranks: 0 monadic, 0 0 dyadic
⨸N: sorted prime factors, with multiplicity. J’s q: family. Positive whole input. Results take the argument’s domain: ⨸12ᵣ gives [2 2 3]ᵣ.
⨸700 ⍝ [2 2 5 5 7]ₓ
⨸1 ⍝ ⍬ₓ
⨸⁻⨸700 ⍝ 700ₓInverse: product. A product of machine integers past 64 bits gives the largest 64-bit integer. K⨸N selects exponents or a factor table.
| K | Result |
|---|---|
| Nonnegative whole number | Exponents of the first K primes; remaining factors are omitted |
∞ |
Exponents through the largest factor |
| Negative whole number | Last \|K distinct factors and their exponents, in two rows |
¯∞ |
Complete two-row factor/exponent table |
2⨸700 ⍝ [2 0]ₓ
∞⨸700 ⍝ [2 0 2 1]ₓ
¯2⨸700 ⍝ [5 7⋄2 1]ₓ
¯∞⨸700 ⍝ [2 5 7⋄2 2 1]ₓ
0⨸700 ⍝ ⍬ₓ
¯∞⨸1 ⍝ 2 0⍴0ₓUnit cells; results assemble with fill. Large factors follow Prime’s probable-prime policy.
Errors
DOMAIN: anNthat isn’t positive and whole; a finiteKthat isn’t whole