Logo

Greetings from The On-Line Encyclopedia of Integer Sequences!

Hints

Search: id:A091878
Displaying 1-1 of 1 results found. page 1
     Format: long | short | internal | text      Sort: relevance | references | number      Highlight: on | off
A091878 a(n) can be expressed as the difference of the squares of consecutive primes in just four distinct ways. +0
5
4920, 801528, 1484280, 5351640, 7257720, 7647360, 12168912, 12302472, 15540360, 17348520, 21623160, 25639320, 27285048, 27462840, 27470352, 34714680, 35684040, 38466288, 48449640, 49936152, 51272760, 54037368, 60948888 (list; graph; listen)
OFFSET

1,1

EXAMPLE

4920=211^2-199^2=251^2-241^2=617^2-613^2=1231^2-1229^2

PROGRAM

(C) #define NMAX 200000000 #include <stdlib.h> #include <stdio.h> #include <limits.h> int isprime(const int n) { for(int i=2 ; i*i <= n ; i++) if( n % i == 0) return(0) ; return 1 ; } int main(int argc, char *argv[]) { short * n= (short*)calloc(NMAX, sizeof(short)) ; int wm=0; for(int p=2 ; ; ) { int np=p+1 ; while( !isprime(np) ) np++ ; if(np<0) break ; if ( p+np < INT_MAX/(np-p) ) { const int i=(p+np)*(np-p) ; const int nw= p+np ; if( i < NMAX ) n[i]++ ; for(int j=wm ; j < nw ; j++) if ( n[j] == 4) printf("%d ", j) ; wm=nw ; } p=np ; if( p > INT_MAX-np ) break ; } free(n) ; } - R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Oct 05 2006

CROSSREFS

Cf. A078667, A090783, A090784, A090785.

Sequence in context: A013884 A043480 A028550 this_sequence A015357 A037044 A116147

Adjacent sequences: A091875 A091876 A091877 this_sequence A091879 A091880 A091881

KEYWORD

nonn

AUTHOR

Ray G. Opao (1260(AT)email.com) and Ray Chandler (rayjchandler(AT)sbcglobal.net), Feb 11 2004

EXTENSIONS

More terms from R. J. Mathar (mathar(AT)strw.leidenuniv.nl), Oct 05 2006

page 1

Search completed in 0.002 seconds

Lookup | Welcome | Find friends | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Transforms | Puzzles | Hot | Classics
More pages | Superseeker | Maintained by N. J. A. Sloane (njas@research.att.com)

Last modified December 4 08:07 EST 2009. Contains 170310 sequences.


AT&T Labs Research