login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A277198 a(n) = gcd(A260443(n), A260443(n+1)). 8
1, 1, 3, 1, 1, 3, 15, 1, 1, 15, 15, 5, 5, 15, 105, 1, 1, 105, 75, 5, 5, 375, 525, 7, 7, 525, 525, 35, 35, 105, 1155, 1, 1, 1155, 525, 245, 35, 2625, 18375, 7, 7, 91875, 13125, 35, 245, 18375, 40425, 11, 11, 40425, 25725, 245, 245, 128625, 202125, 77, 77, 40425, 40425, 385, 385, 1155, 15015, 1, 1, 15015, 5775, 2695, 2695, 1414875, 1414875, 77, 77 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
LINKS
FORMULA
a(n) = gcd(A260443(n), A260443(n+1)).
PROG
(Scheme) (define (A277198 n) (gcd (A260443 (+ 1 n)) (A260443 n)))
;; A more practical version, needing only an implementation of A000040:
(define (A277198 n) (product_primes_to_kth_powers (gcd_of_exp_lists (A260443as_coeff_list n) (A260443as_coeff_list (+ 1 n)))))
(define (product_primes_to_kth_powers nums) (let loop ((p 1) (nums nums) (i 1)) (cond ((null? nums) p) (else (loop (* p (expt (A000040 i) (car nums))) (cdr nums) (+ 1 i))))))
(definec (A260443as_coeff_list n) (cond ((zero? n) (list)) ((= 1 n) (list 1)) ((even? n) (cons 0 (A260443as_coeff_list (/ n 2)))) (else (add_two_lists (A260443as_coeff_list (/ (- n 1) 2)) (A260443as_coeff_list (/ (+ n 1) 2))))))
(define (add_two_lists nums1 nums2) (let ((len1 (length nums1)) (len2 (length nums2))) (cond ((< len1 len2) (add_two_lists nums2 nums1)) (else (map + nums1 (append nums2 (make-list (- len1 len2) 0)))))))
(define (gcd_of_exp_lists nums1 nums2) (let ((len1 (length nums1)) (len2 (length nums2))) (cond ((< len1 len2) (gcd_of_exp_lists nums2 nums1)) (else (map min nums1 (append nums2 (make-list (- len1 len2) 0)))))))
(PARI) A=[];
A003961(n)=my(f=factor(n)); f[, 1] = apply(p->nextprime(p+1), f[, 1]); factorback(f)
A260443(n)=if(n<3, return(n+1)); if(#A<n, A=concat(A, vector(n-#A))); if(A[n], return(A[n])); A[n]=if(n%2, A260443(n\2)*A260443(n\2+1), A003961(A260443(n/2)))
a(n)=gcd(A260443(n), A260443(n+1)) \\ Charles R Greathouse IV, Oct 13 2016
CROSSREFS
Cf. A277327, A277328 (number of prime factors).
Sequence in context: A016563 A025254 A245537 * A242735 A177058 A176921
KEYWORD
nonn
AUTHOR
Antti Karttunen, Oct 10 2016
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 23 04:43 EDT 2024. Contains 374544 sequences. (Running on oeis4.)