login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A082729 Least positive number that can be written using all divisors of n and the operations add and subtract. 3
1, 1, 2, 1, 4, 2, 6, 1, 5, 2, 10, 2, 12, 4, 6, 1, 16, 1, 18, 2, 10, 8, 22, 2, 19, 10, 14, 2, 28, 2, 30, 1, 18, 14, 22, 1, 36, 16, 22, 2, 40, 2, 42, 4, 12, 20, 46, 2, 41, 7, 30, 6, 52, 2, 38, 2, 34, 26, 58, 2, 60, 28, 22, 1, 46, 2, 66, 10, 42, 2, 70, 1, 72, 34, 26, 12, 58, 2, 78, 2, 41, 38, 82 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,3

COMMENTS

a(n) < A000203(n); a(n)=A000010(n)=n-1 iff n is prime or n=6;

a(2^n)=1, a(A000079(n))=1.

LINKS

Donovan Johnson, Table of n, a(n) for n = 1..1000

EXAMPLE

Divisors of n=18: {1,2,3,6,9,18} -> a(18)=-1+2-3-6-9+18=1.

Divisors of n=15: {1,3,5,15} -> a(15)=-1-3-5+15=6, as

-1-3-5-15<1, 1-3-5-15<1, -1+3-5-15<1, 1+3-5-15<1, -1-3+5-15<1, 1-3+5-15<1,

-1+3+5-15<1, 1+3+5-15<1, 1-3-5+15>6, -1+3-5+15>6, 1+3-5+15>6, -1-3+5+15>6,

1-3+5+15>6, -1+3+5+15>6 and 1+3+5+15>6.

PROG

(PARI) for(n=1, 1000, nd=numdiv(n); d=divisors(n); nn=3048; for(j=0, 2^nd-1, s=0; for(h=0, nd-1, if(bittest(j, h)==0, s=s-d[h+1], s=s+d[h+1])); if(s>0, if(s<nn, nn=s))); write("b082729.txt", n " " nn)) /* Donovan Johnson, Sep 14 2013 */

CROSSREFS

Cf. A081806, A000005.

Sequence in context: A125131 A003958 A326140 * A326069 A326068 A318878

Adjacent sequences:  A082726 A082727 A082728 * A082730 A082731 A082732

KEYWORD

nonn

AUTHOR

Reinhard Zumkeller, Apr 13 2003

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified June 17 22:17 EDT 2019. Contains 324200 sequences. (Running on oeis4.)