FYI, there is no known algorithm for optimal Egyptian fractions. Therefore this problem should allow the trivial solution of p/q as 1/q times p, which is not currently (this could be the worst score, a penalty can be included for repeated denominators). The solution for this problem is a greedy one (which may produce huge denominators), or the combination of non-greedy techniques that breaks the problem into several smaller pieces and which may create a huge sequence. I hope that the author has tested for upper and lower bounds on the test suite numbers since he is requesting an unknown solution and random numbers.
And my advice is if you do find a solution for this which attends the general case, don't publish it here, write a scientific paper.
927 Solvers
Generate a vector like 1,2,2,3,3,3,4,4,4,4
3630 Solvers
return row and column indices given 2 values which define a range
46 Solvers
Divisible by n, Truncated-number Divisors
47 Solvers
Sorting integers by their digits (Level 2)
34 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!