[GAP Forum] amicable chains
Lisette Brillemans
lisette.brillemans at mensa.nl
Tue Nov 22 10:22:09 GMT 2011
Dear forum,
I would like to learn the programming-language of GAP fluently, but of
course cannot do that without asking for help sometimes.
So I wonder how I can find amicable chains with GAP.
Firstly I already defined a function SumProper which calculates the sum
of the proper divisors of a number. (The divisors of a number without
the number itself).
It so happens that SumProper(28)=28.
Also SumProper(220)=284 and SumProper(284)=220.
Now I would like to be able to find all such amicable chains like
220,284,220,... but also: 12496,14288,15472,14536,14264,12496,... using
GAP. How could I do this?
With thanks for any help. This way I (hopefully once ;) ) will learn to
program GAP very well.
Lisette
More information about the Forum
mailing list