# Maple program to create b133420.txt # usage: # maple -q thisprogramhere > b133420.txt # Richard J. Mathar, 2007-11-30 # auxiliary program to implement A133419 A133419 := proc(n) option remember ; if n mod 2 = 0 then n/2 ; elif n mod 3 = 0 then n/3; else 5*n+1 ; fi ; end: A133420 := proc(n) local a,map5x1 ; a := 0 ; map5x1 := n ; while map5x1 <> 1 do map5x1 := A133419(map5x1) ; a := a+1 ; od: RETURN(a) ; end: # increase the upper limit of 20,000 if more are needed... for n from 1 to 20000 do printf("%d %d\n",n,A133420(n)) ; od: