Some Sum of Some Sum

Find the sum of all the positive square-free integers whose divisors add up to 288 288 .


The answer is 1158.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

2 solutions

Sam Zhou
Aug 7, 2019

If a number's prime factorization is p 1 q 1 × p 2 q 2 × p 3 q 3 × . . . × p k q k p_{1}^{q_{1}}\times p_{2}^{q_{2}}\times p_{3}^{q_{3}}\times...\times p_{k}^{q_{k}} , where p 1 , p 2 , p 3 , . . . , p k p_{1},p_{2},p_{3},...,p_{k} are primes, its sum of divisors is ( p 1 0 + p 1 1 + . . . + p 1 q 1 ) ( p 2 0 + p 2 1 + . . . + p 2 q 2 ) . . . ( p k 0 + p k 1 + . . . + p k q k ) (p_{1}^{0}+p_{1}^{1}+...+p_{1}^{q_{1}})(p_{2}^{0}+p_{2}^{1}+...+p_{2}^{q_{2}})...(p_{k}^{0}+p_{k}^{1}+...+p_{k}^{q_{k}}) .

As the integers are square-free, their prime factorizations do not contain any exponents greater than 1. Therefore, their sum of divisors will be ( 1 + p 1 ) ( 1 + p 2 ) . . . ( 1 + p k ) (1+p_{1})(1+p_{2})...(1+p_{k}) .

288 = 2 5 × 3 2 288=2^{5}\times3^{2} . There are a total of 6 6 ways to express 288 288 as the product ( 1 + p 1 ) ( 1 + p 2 ) . . . ( 1 + p k ) (1+p_{1})(1+p_{2})...(1+p_{k}) :

288 = ( 1 + 3 ) ( 1 + 71 ) 288=(1+3)(1+71) , giving the number 3 × 71 = 213 3\times71=213

288 = ( 1 + 5 ) ( 1 + 47 ) 288=(1+5)(1+47) , giving the number 5 × 47 = 235 5\times47=235

288 = ( 1 + 11 ) ( 1 + 23 ) 288=(1+11)(1+23) , giving the number 11 × 23 = 253 11\times23=253

288 = ( 1 + 2 ) ( 1 + 3 ) ( 1 + 23 ) 288=(1+2)(1+3)(1+23) , giving the number 2 × 3 × 23 = 138 2\times3\times23=138

288 = ( 1 + 2 ) ( 1 + 7 ) ( 1 + 11 ) 288=(1+2)(1+7)(1+11) , giving the number 2 × 7 × 11 = 154 2\times7\times11=154

288 = ( 1 + 3 ) ( 1 + 5 ) ( 1 + 11 ) 288=(1+3)(1+5)(1+11) , giving the number 3 × 5 × 11 = 165 3\times5\times11=165

The sum of these numbers is 1158 \boxed{1158} .

Nicely done!

David Vreken - 1 year, 10 months ago
Kyle T
Aug 8, 2019

PHP solution, half elegant, half brute force

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<?php
$t = 0;
for($i=2;$i<=288;$i++){
    if(squarefree($i)){
        $factors = factors($i);
        $sum = array_sum($factors);
        if($sum==288){
            $t += $i;

        echo 'i: '.$i.'<br>';
        echo 'factors: '.implode(', ',$factors).'<br>';
        echo 'sum: '.$sum.'<br><br>';
        }
    }
}
echo 'answer: '.$t;


function squarefree($n){
    $i = 1;
    do {
        $i++;
        if($n%pow($i,2)==0){
            return false;
        }
    } while($n>=pow($i,2));
    return true;
}

function factors($n){
    $f = array();
    for($i=1;$i<=$n/2;$i++){
        if($n%$i==0){
            $f[] = $i;
            $f[] = $n/$i;
        }
    }
    $f = array_unique($f);
    sort($f);
    return $f;
}
/*
i: 138
factors: 1, 2, 3, 6, 23, 46, 69, 138
sum: 288

i: 154
factors: 1, 2, 7, 11, 14, 22, 77, 154
sum: 288

i: 165
factors: 1, 3, 5, 11, 15, 33, 55, 165
sum: 288

i: 213
factors: 1, 3, 71, 213
sum: 288

i: 235
factors: 1, 5, 47, 235
sum: 288

i: 253
factors: 1, 11, 23, 253
sum: 288

answer: 1158
*/
?>

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...