All Questions
Tagged with enumeration number-theory
4 questions
2
votes
2
answers
175
views
How to iterate the Hardy-Ramanujan integers quickly
The Hardy-Ramanujan integers, A025487 - OEIS, are integers which when factorized, have their exponents for all the primes starting from 2, in decreasing (not strictly) order. The first few terms are:
$...
0
votes
0
answers
60
views
Finding index of $p_{k}$ element in the original sorted array if elements were to be removed using a specific condition
Consider a sorted list of numbers $C_{0}=\{0,1,2,3,...,n-1\}$ from where one element will be eliminated at each step. We are also given a value $L$ in $[0, 1)$ and let the indexing start from $0$.
...
8
votes
2
answers
943
views
How can I generate first n elements of the sequence 3^i * 5^j * 7^k?
How can I efficiently generate the first N elements of the sequence $3^i 5^j 7^k$, where $i,j,k \in \mathbb{N}$?
I've googled around a bit and found the sequence in OEIS, but I don't really see a ...
12
votes
3
answers
5k
views
How fast can we find all Four-Square combinations that sum to N?
A question was asked at Stack Overflow here:
Given an integer $N$, print out all possible combinations of integer values of $A,B,C$ and $D$ which solve the equation $A^2+B^2+C^2+D^2 = N$.
This ...