Skip to content

A077140

OEIS Lean4

a(1) = 1 and then add n to the previous term if n is coprime to the previous term, otherwise subtract n from the previous term. a(1) = 1 and a(n) = a(n-1) + n if gcd(n, a(n-1)) = 1, otherwise a(n) = a(n-1) - n.

offset: 1
codomain: ℤ
n123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
A077140130-4170-81110-121150-161190-201230-241270-281310-321350-361390-401430-441470-481510-521550-561590-601630-641670-681710-721750-761790-801830-841870-881910-921950-961990-100