/**************************************************************************** Square of the shells calculator. Rule discovered by Vernon Brown Novenber 5th 1991 shows that a simple relationship between the masses of shells that make up elementary particles may exist. This construct for mass has the proton made of 3 sandwiched electromagnetic shells and the neutron made of four. The neutron's outer shell, s1, starts a square of shells sequence that derives the mass of the other 3 shells, s2, s3, and s4. s2 = s1 * s1; s3 = s2 * s2; s4 = s3 * s3; Proton = s4 + s3 + s2. Neutron = Proton + s1 To compile and run in Linux use the following commands at the console: cc mevs.c ./a.out ****************************************************************************/ #include #include #include #include int main(int argc, char **argv){ double e, s1, s2, s3, s4; double prot, neut, plc; /* plc = Planks Constant */ double pvprot, pvneut, caltry; double pi, dia1, dia2, dia3, dia4; /* Will be used for diameters */ double lightspeed, diae; double dia4x; int x; char try[80]; char c; char electron[] = {".51099905"}; /* Physical Review D June 1992 */ char proton[] = {"938.27231"}; /* Measured nominal values */ char neutron[] = {"939.56563"}; plc = 6.6260755; /* Planck's Constant */ pi = 3.1415926535; lightspeed = .00299792458; /* times 10 to the 11th */ try[0] = 0; strcpy(try, "2.549920405"); /* Neutron - Proton mass */ s1 = atof(try); /* in electron masses */ caltry = atof(neutron) - atof(proton); e = atof(electron); while(s1 > 0){ //system("cls"); /* Uncomment for Windows */ system("clear"); /* Uncomment for Linux */ s2 = s1 * s1; s3 = s2 * s2; s4 = s3 * s3; prot = s4 + s3 + s2; neut = prot + s1; diae = plc / (pi * e * lightspeed); dia1 = plc / (pi * s1 * lightspeed); dia2 = plc / (pi * s2 * lightspeed); dia3 = plc / (pi * s3 * lightspeed); dia4 = plc / (pi * s4 * lightspeed); /* Diameters assume wave-length=circumfrence */ /* Divided by shell 4 diameter for units in shell 4 dia */ /* */ /* Un-comment the below for diameter in units of Shell 4 */ /* Comment out the below for diameter in cemtimeters -11 */ /*********************************************************/ if(dia4 <= 0){ printf("\nShell 4 is zero or less -- must abort -- \n"); return 0; } diae /= dia4; dia1 /= dia4; dia2 /= dia4; dia3 /= dia4; dia4 /= dia4; /*********************************************************/ printf(" Square-of-the-Shells rule\n"); printf(" Vernon Brown Nov 5th 1991\n"); printf(" Diameters are in units of Shell 4 diameter\n\n"); printf("\nPublished values: in mev"); printf(" electrons "); printf(" diameters "); printf("\nElectron----------------------- %s", electron); printf(" 1.00000"); printf(" %05.5f", diae); printf("\nNeutron------------------------ %s", neutron); pvneut = atof(neutron) / atof(electron); printf(" or %5.5f", pvneut); printf(" %5.5f", dia1); printf("\nProton------------------------- %s", proton); pvprot = atof(proton) / atof(electron); printf(" or %05.5f", pvprot); printf(" %5.5f", dia2); printf("\nNeutron - Proton -----------------%5.5f", caltry); printf(" or %5.5f", caltry / e); printf("\n\nCalculated values: in mev"); printf(" electrons "); printf(" diameters"); printf("\nShell one mass ---------------"); printf(" %5.5f", s1 * e); printf(" %5.5f", s1); printf(" %5.5f", dia1); printf("\nShell two mass ---------------"); printf(" %5.5f", s2 * e); printf(" %5.5f", s2); printf(" %5.5f", dia2); printf("\nShell three mass -------------"); printf(" %5.5f", s3 * e); printf(" %5.5f", s3); printf(" %5.5f", dia3); printf("\nShell four mass -------------"); printf(" %5.5f", s4 * e); printf(" %5.5f", s4); printf(" %5.5f", dia4); printf("\n"); printf("\nProton mass = s4 + s3 + s2 ---- %5.5f", prot * e); printf(" %5.5f", prot); if(pvprot - prot > 0) printf(" binding %5.5f ", pvprot - prot); else printf(" binding %5.5f ", pvprot - prot); printf("\nNeutron mass = proton + s1 ---- %5.5f", neut * e); printf(" %5.5f", neut); if(pvneut - neut > 0) printf(" binding %5.5f ", pvneut - neut); else printf(" binding %5.5f ", pvneut - neut); c = 0; x = 0; printf("\n\nValues with shell one mass set to %s", try); printf("\nEnter a new number to try "); while(c != 0x0a){ c = getc(stdin); try[x++] = c; } s1 = atof(try); if(s1 < 1) break; try[x - 1] = 0; } return 1; }