login
A395742
Superior highly composite numbers (A002201) where a new prime factor is introduced for the first time.
1
2, 6, 60, 2520, 55440, 720720, 367567200, 6983776800, 321253732800, 65214507758400, 6064949221531200, 448806242393308800, 18401055938125660800, 791245405339403414400, 37188534050951960476800, 9854961523502269526352000, 581442729886633902054768000, 780296143507862696557498656000
OFFSET
1,1
COMMENTS
This sequence is the subsequence of superior highly composite numbers (A002201) where a new prime factor is introduced for the first time. Because superior highly composite numbers are primorial-regular and their prime factors are added strictly in increasing order, a(n) is the first superior highly composite number to be divisible by the n-th prime.
FORMULA
a(n) = min { x in A002201 : A001221(x) = n }.
EXAMPLE
a(1) = 2 because it is the first superior highly composite number with 1 distinct prime factor (2).
a(2) = 6 because it is the first superior highly composite number with 2 distinct prime factors (2 and 3).
a(3) = 60 because the preceding superior highly composite numbers (2, 6, 12) have at most 2 distinct prime factors, making 60 (2^2 * 3 * 5) the first to have 3 distinct prime factors.
MAPLE
# Assuming shcnList is a pre-defined list of Superior Highly Composite Numbers
with(NumberTheory):
result := [];
seen := 0;
for x in shcnList do
d := NumberOfPrimeFactors(x, 'distinct');
if d > seen then
result := [op(result), x];
seen := d;
fi;
od:
print(result);
MATHEMATICA
(* Selects the first SHCN for each unique count of distinct prime factors *)
shcnList = Import["https://oeis.org/A002201/b002201.txt", "Data"][[All, -1]]; DeleteDuplicatesBy[shcnList, PrimeNu]
PROG
(Python)
import urllib.request
def get_prime_factors(n):
"""Efficiently finds unique prime factors of n."""
factors = set()
if n % 2 == 0:
factors.add(2)
while n % 2 == 0:
n //= 2
d = 3
while d * d <= n:
if n % d == 0:
factors.add(d)
while n % d == 0:
n //= d
d += 2
if n > 1:
factors.add(n)
return factors
def main():
url = "https://oeis.org/A002201/b002201.txt"
output_filename = "b395742.txt"
print(f"Fetching data from {url}...")
try:
req = urllib.request.Request(
url,
headers={'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64)'}
)
with urllib.request.urlopen(req) as response:
lines = response.read().decode('utf-8').splitlines()
except Exception as e:
print(f"Error fetching the file: {e}")
return
seen_primes = set()
output_index = 1 # Sequential numbering starting at 1
print(f"Writing strict OEIS-compliant b-file to {output_filename}...")
# 'newline="\n"' forces Unix LF endings. 'encoding="utf-8"' writes without BOM.
with open(output_filename, 'w', encoding='utf-8', newline='\n') as f:
for line in lines:
line = line.strip()
if not line or line.startswith('#'):
continue
parts = line.split()
if len(parts) != 2:
continue
value = int(parts[1])
factors = get_prime_factors(value)
new_primes = factors - seen_primes
if new_primes:
# Format: "index value\n" (Strictly no trailing spaces or comments)
f.write(f"{output_index} {value}\n")
seen_primes.update(new_primes)
output_index += 1
print(f"Done! '{output_filename}' has been created with {output_index - 1} terms.")
if __name__ == "__main__":
main()
CROSSREFS
Subsequence of A002201. Cf. A000040, A000705, A001221, A006530.
Sequence in context: A156472 A108640 A084971 * A224883 A001577 A156503
KEYWORD
nonn
AUTHOR
James McKay, Jun 08 2026
STATUS
approved