Prime numbers. Corelation with physics, quantum physics and chemistry. Part 6.

So what about symmetry_results.txt from Part 1.?


I think sequences xT and yF has a connection with chemistry or physics. I am a programmer and I had a vision.
And I am not a chemist.

How can I say that this file has a corelation to any part of science?

Check for example 1F 1T sequence.
It is common for some amount numbers and my favourite: 2067.
It occurs at numbers:

25
44
53
62
81
...
972
1040
1060
1100
1208
...
2067
...
8514
8694
8874
9054
9234
...

Try to divide smaller number by larger number.
Paste it to google with smaller amount of demical places and add “chemistry” keyword.

There are many, really, many results related with physics, quantum physics and chemistry.

Maybe that is huge discover?

Prime numbers. Visualisation of Center Numbers Symmetries. Part 5.

From Part 4. we know:

Each Prime1 has a twin Prime2.

Prime1 < Prime2

Prime1 and Prime2 are connected with a CenterNumber

(Prime1 + Prime2) / 2 = CenterNumber

If we assume on Euclidean Space for each symmetry:

  • x = 0
  • draw a circle
    • center of circle is CenterNumber
    • radius of circle is length of symmetry

then on x = 0 shape of the circles will be touching other shape of circles at prime numbers.

As you can see – the circles at length of radius are creating triangles seems to be placed at diagonal axes with some pattern.

Is this pattern is random?

Code is available Github.

Prime numbers. Discovering symmetries between prime numbers. The Center Number. Part 4.

Source code of this part can be found at Github.

Part 1., Part 2. and Part 3. was about some numerology based equations.

sin(101) = 0.98162718344766397571
cos(101) = -0.19080899537654480436
tan(101) = -5.1445540159703107008
sin(103) = 0.97437006478523524589
cos(103) = -0.22495105434386480914
tan(103) = -4.3314758742841590333

I cannot explain why the main requirement is take 3 numbers if angle is build of 3 numbers.
As you can quickly calculate with 2 or 4 taken numbers it does not work in a symmetry context.

After this discovery I get an idea to test symmetry of known prime numbers. I asked myself:

Is there a center number between two primary numbers?

Of course there is.

I had discover, that every prime number has a “twin” at the same length from center number.

If you check https://banit.pl/wp-content/uploads/2019/08/result.txt you will find:

Size:	2		
Count:	24		
---------
Size:	6		
Count:	46		
---------
Size:	10		
Count:	32
...
  • Size is length between 2 prime numbers abs(prime1 - prime2) = size
  • In range <0, 500>:
    • there are 24 * 2 prime numbers so there is 24 symmetries
    • there are 46 * 2 prime numbers so there is 46 symmetries

And so on.
Next files are more detailed.

In https://banit.pl/wp-content/uploads/2019/08/result_details.txt you can confirm:

Size:	2		
Count:	24		
___DETAILS___
Below:	3
Center:	4
Upper:	5
---
Below:	5
Center:	6
Upper:	7
---
Below:	11
Center:	12
Upper:	13
---
Below:	17
Center:	18
Upper:	19
---
Below:	29
Center:	30
Upper:	31
---
Below:	41
Center:	42
Upper:	43
...

...
Size:	6		
Count:	46		
___DETAILS___
Below:	5
Center:	8
Upper:	11
---
Below:	7
Center:	10
Upper:	13
---
Below:	11
Center:	14
Upper:	17
---
Below:	13
Center:	16
Upper:	19
---
Below:	17
Center:	20
Upper:	23
---
Below:	23
Center:	26
Upper:	29
...

And you can define:

UpperPrime – LowerPrime = Size
and Size is given by 4n + 2 formula

File https://banit.pl/wp-content/uploads/2019/08/result_number_symmetry.txt confirms previous. File is grouped by number and it shows where the prime number exists in symmetry:

NUMBER:	3			
	C	4		P	5		L	1
	C	8		P	13		L	5
	C	10		P	17		L	7
	C	16		P	29		L	13			
	C	20		P	37		L	17			
	C	22		P	41		L	19
...

...
NUMBER:	5			
	C	4		P	3		L	1			
	C	6		P	7		L	1			
	C	8		P	11		L	3			
	C	12		P	19		L	7			
	C	14		P	23		L	9			
	C	18		P	31		L	13			
	C	24		P	43		L	19			
	C	26		P	47		L	21

C: center number
P: prime in pair
L: length in center number

So:

  • number 3 (confirmed in NUMBER: 5)
    • has a 5 prime number twin
    • symmetry size is equal 2: 5 - 3 = 2
    • center number is 4: (5 + 3) / 2 = 4
    • length from center number is equal 1: 3 + 1 = 5 - 1
  • number 5
    • has a 47 prime number twin
    • symmetry size is equal 42: 47 - 5 = 42
    • center number is 26: (47 + 5) / 2 = 26
    • length from center number is equal 21: 5 + 21 = 47 - 21

Part 5. of Prime Numbers topic is available.

Trigonometry. Symmetry and simple analysis. Part 3.

Whole code is available on Github.

Let us modify our trigonometry C++ definitions from previous part.
They are numeric error free – if you get INF type from tan() it just converts it to 0.

static double degreeToRadian(double d) {
    return (d / 180.0) * ((double) M_PI);
}

double sind(double x) {
    if (!isfinite(x)) {
        return sin(x);
    }
    if (x < 0.0) {
        return -sind(-x);
    }
    int quo;
    double x90 = remquo(fabs(x), 90.0, &quo);
    switch (quo % 4) {
        case 0:
            // Use * 1.0 to avoid -0.0
            return sin(degreeToRadian(x90) * 1.0);
        case 1:
            return cos(degreeToRadian(x90));
        case 2:
            return sin(degreeToRadian(-x90) * 1.0);
        case 3:
            return -cos(degreeToRadian(x90));
    }
    return 0.0;
}

double cosd(double x /* degrees */) {
    if (!isfinite(x)) {
        return std::cos(x);
    }
    int quo;
    double x90 = std::remquo(std::fabs(x), 90.0, &quo);
    double xr = degreeToRadian(x90);
    switch (quo % 4) {
        case 0:
            return std::cos(xr);
        case 1:
            // Use + 0.0 to avoid -0.0
            return std::sin(-xr + 0.0);
        case 2:
            return -std::cos(xr);
        case 3:
            return std::sin(xr + 0.0);
    }
    return 0.0;
}

double _tand(double x /* degrees */) {
    if (!isfinite(x)) {
        return tan(x);
    } else if (x < 0.0) {
        return -_tand(-x);
    }
    int quo;
    double x45 = remquo(fabs(x), 90.0, &quo);
    switch (quo % 4) {
        case 0:
            return tan(degreeToRadian(x45));
        case 1:
            return 1.0 / tan(degreeToRadian(-x45));
        case 2:
            return -tan(degreeToRadian(-x45));
        case 3:
            return -1.0 / tan(degreeToRadian(x45));
    }
    return 0.0;
}

double tand(double x) {
    double result = _tand(x);
    if (!isfinite(result)) {
        return 0.0;
    }
    return result;
}

Let define types which will be useful for calculating sum symmetries.

// data types
typedef long long T_NUM;
typedef std::vector<T_NUM> T_NUM_VEC;
typedef std::string T_STR;
typedef std::vector<T_STR> T_STR_VEC;
typedef std::pair<T_NUM, T_NUM> T_PAIR;
typedef std::vector<T_PAIR> T_PAIR_VEC;
typedef std::vector<std::vector<std::vector<T_NUM>>> T_3D_NUM_VEC;
struct T_STRUCT {
    T_NUM angle;
    T_NUM angleSize;
    T_NUM sum = 0;
};
typedef std::vector<T_STRUCT> T_STRUCTURE_VECTOR;
struct T_STRUCT_SYMMETRY {
    T_NUM start = -999999999;
    T_NUM center = -999999999;
    T_NUM end = -999999999;
    T_NUM angle = -999999999;
    T_NUM length = -999999999;
    T_NUM sum = 0;
};
typedef std::vector<T_STRUCT_SYMMETRY> T_SYMMETRY_VECTOR;
struct T_SORT_STRUCT {
    inline bool operator()(const T_STRUCT &s1, const T_STRUCT &s2) {
        return (s1.angle < s2.angle);
    }
};
struct T_HISTOGRAM_SORT_STRUCT {
    inline bool operator()(const T_PAIR &s1, const T_PAIR &s2) {
        return (s1.first < s2.first);
    }
};

Let define output data files and helper functions.

// data files
std::ofstream fileHistogram;
std::ofstream fileSumsSymmetry;
std::ofstream fileSumsSymmetry2;

// helpers
int charToInt(char c) {
    int result = c;
    switch (result) {
        case 48:
            return 0;
        case 49:
            return 1;
        case 50:
            return 2;
        case 51:
            return 3;
        case 52:
            return 4;
        case 53:
            return 5;
        case 54:
            return 6;
        case 55:
            return 7;
        case 56:
            return 8;
        case 57:
            return 9;
        default:
            return 0;
    }
}

T_STR getNumbersFromTri(double num, bool ommit, unsigned long length) {
    T_STR result;
    T_STR str = std::to_string(num);

    for (size_t i = 0; i < str.length(); i++) {
        if (str.at(i) == '-') {
            continue;
        }
        if (ommit) {
            if (str.at(i) != '.') {
                continue;
            } else {
                ommit = false;
                continue;
            }
        } else {
            if (str.at(i) == '.') {
                continue;
            }
        }

        result += str.at(i);

        if (result.length() == length) {
            break;
        }
    }

    return result;
}

T_NUM sumVector(T_NUM_VEC vec) {
    T_NUM result = 0;
    for (size_t i = 0; i < vec.size(); i++) {
        result += vec.at(i);
    }
    return result;
}

T_NUM_VEC createVectorFromTri(T_STR sinus, T_STR cosinus, T_STR tangent) {
    T_NUM_VEC result = T_NUM_VEC();
    for (int i = 0; i < sinus.length(); i++) {
        result.push_back(charToInt(sinus.at(i)));
    }
    for (int i = 0; i < cosinus.length(); i++) {
        result.push_back(charToInt(cosinus.at(i)));
    }
    for (int i = 0; i < tangent.length(); i++) {
        result.push_back(charToInt(tangent.at(i)));
    }
    return result;
}

T_STR createCell(T_NUM tabLength, T_STR content) {
    T_NUM subtract = (tabLength * 4) - (T_NUM) content.length();
    auto numTabs = (T_NUM) ceil((int) subtract / (int) 4);

    if (((int) subtract) % 4 != 0) {
        numTabs++;
    }

    for (T_NUM i = 0; i < numTabs; i++) {
        content.append("\t");
    }

    return content;
}

void writeHistogramToFile(T_STRUCTURE_VECTOR arr) {
    T_PAIR_VEC histogram;
    T_NUM allSum = 0;

    for (size_t i = 0; i < arr.size(); i++) {
        bool found = false;
        T_NUM sum = arr[i].sum;

        allSum += sum;

        for (size_t j = 0; j < histogram.size(); j++) {
            if (histogram[j].first == sum) {
                histogram[j].second++;
                found = true;
            }
        }

        if (!found) {
            histogram.push_back(std::make_pair(sum, 1));
        }
    }

    std::sort(histogram.begin(), histogram.end(), T_HISTOGRAM_SORT_STRUCT());
    auto it = std::unique(histogram.begin(), histogram.end());
    histogram.resize(std::distance(histogram.begin(), it));

    for (size_t j = 0; j < histogram.size(); j++) {
        fileHistogram << histogram[j].first << ":\t" << histogram[j].second << "\n";
    }
}

Now we are ready to do some computations.

As limit angles we choose a range <-999, 999> defined by:

const T_NUM ___BEGIN___ = 999;

First loop is taking numbers from trigonometry functions and saving them for future use.

// start
    T_NUM_VEC allFound;
    T_STRUCTURE_VECTOR arr; // main data container

    for (T_NUM step = -___BEGIN___; step <= ___BEGIN___; step += 1) {
        T_NUM_VEC vec1 = createVectorFromTri(
                getNumbersFromTri(sind(step), true, std::to_string(abs(step)).length()),
                getNumbersFromTri(cosd(step), true, std::to_string(abs(step)).length()),
                getNumbersFromTri(tand(step), false, std::to_string(abs(step)).length()));

        // create data
        T_STRUCT s1;
        s1.angle = step;
        s1.angleSize = (T_NUM) std::to_string(abs(step)).length();
        s1.sum = sumVector(vec1);

        arr.push_back(s1);
    }

Second loop creates a vector of all symmetries available. Not only on multipliers of 90 degress but even hidden somewhere between or above or conflicting with another symmetries.

T_SYMMETRY_VECTOR symmetries;

    for (T_NUM base = -___BEGIN___, start = 0; base <= ___BEGIN___; base += 1, start++) {
        if (base == -___BEGIN___) { // not smallest angle
            continue;
        }

        T_NUM range = 1;

        while (true) {
            if (start - range < 0 || start + range > arr.size()) {
                break;
            }

            // select ranges
            T_NUM currentUpperSum = arr[start + range].sum;
            T_NUM currentBelowSum = arr[start - range].sum;
            T_NUM prevUpperSum = arr[start + (range - 1)].sum;
            T_NUM prevBelowSum = arr[start - (range - 1)].sum;

            if (currentUpperSum != currentBelowSum && prevUpperSum == prevBelowSum && range > 1) {
                T_STRUCT_SYMMETRY symmetry;
                symmetry.start = start - (range - 1);
                symmetry.end = start + (range - 1);
                symmetry.center = start;
                symmetry.angle = arr[start].angle;
                symmetry.length = (start + (range - 1)) - (start - (range - 1));

                for (T_NUM i = (start - range); i <= (start + range); i++) {
                    symmetry.sum += arr[i].sum;
                }

                symmetries.push_back(symmetry);
                break;
            }

            range++;
        }
    }

Later, in C++ code we are saving data about symmetries.

You may want to check the results of algorithms:

Result files are available:

https://banit.pl/wp-content/uploads/2019/08/sums_symmetry.txt

https://banit.pl/wp-content/uploads/2019/08/sums_symmetry_2.txt

https://banit.pl/wp-content/uploads/2019/08/histogram.txt

As we know from previous part for sure symmetry exists at degress 90 and 101. In sums_symmetry_2.txt there are described as follows:

---------------------
ANGLE		90		
START ANGLE	81		
END ANGLE	99		
LENGTH		18		
SUM		640		
---------------------
...

...
---------------------
ANGLE		101		
START ANGLE	88		
END ANGLE	114		
LENGTH		26		
SUM		1005	
---------------------

You may want to check histograms of sums:

You can find there some suprising facts about symmetries:

  • The largest length of symmetry at range <-999, 999> is equal 880!
  • It is almost half of range.
  • There are 2 such a symmetries
    • -980 to -100
    • 100 to 980
  • Inside this symmetries are another symmetries.
  • Symmetries are conflicting.
Visualisation of sums symmetry.

Part 4. of Prime Numbers topic is available.

Enjoy!

Trigonometry. Hidden symmetry in base trigonometric functions. Part 2.

Definitions. It’s all about definitions. I prefer to discover a definition.

Lets go!

  • Assume that center of symmetry is angle of 90 degrees.
  • Convert angle from degree to radian and calculate:
    • sin(90)
    • cos(90)
    • tan(90)
  • If 90 is build of two numbers: nine and zero take two numbers from:
    • sin() after decimal point
    • cos()after decimal point
    • tan() – before decimal point and maybe after decimal point – i.e. when degree will be build of higher amount of numbers than amount numbers before decimal point
  • If number will be build of three numbers i.e. 911 you take three numbers
  • Sum all taken numbers.
  • The symmetry means the sum of numbers will be perfomed on degrees: 89 and 91 and that sums will be equal. The length of symmetry will be equal 1 – one number before and after 90 degrees.
  • When the sums will be equal at numbers 88 and 92 then length of symmetry will be equal 2 – two numbers before and after 90 degrees.

We will use some C++ code to show it.

Definitions:

const double PI = std::acos(-1);

double degreeToRadian(double degree) {
    return degree * PI / 180.0;
}

double radianToDegree(double radians) {
    return radians * 180 / PI;
}

double _sin(double x) {
    return std::sin(degreeToRadian(x));
}

double _cos(double x) {
    return std::cos(degreeToRadian(x));
}

double _tan(double x) {
    return std::tan(degreeToRadian(x));
}

Now we can calculate 89 and 91 degress:

int main() {
    std::cout.precision(20);

    std::cout << "sin(89) = " << _sin(89) << std::endl;
    std::cout << "cos(89) = " << _cos(89) << std::endl;
    std::cout << "tan(89) = " << _tan(89) << std::endl;

    std::cout << "sin(91) = " << _sin(91) << std::endl;
    std::cout << "cos(91) = " << _cos(91) << std::endl;
    std::cout << "tan(91) = " << _tan(91) << std::endl;

    return 0;
}

Result will be:

sin(89) = 0.99984769515639126958
cos(89) = 0.017452406437283376345
tan(89) = 57.289961630759876243
sin(91) = 0.99984769515639126958
cos(91) = -0.017452406437283476959
tan(91) = -57.289961630759549394

So what now? We can see:

sin(89) = sin(91)
abs(cos(89)) = abs(cos(91))
abs(tan(89)) = abs(tan(91))

And as we define above we take numbers from trigonometry functions from degree 89 and degree 91.
9 + 9 + 0 + 1 + 5 + 7 = 31
9 + 9 + 0 + 1 + 5 + 7 = 31
Symmetry exists because two sums are equal.
When the symmetry is calculated between multipliers of 90 degrees then symmetry should exists.

But what if I tell you the secret if the symmetry exists when the center is available on 102 degress?

Let us check it.

int main() {
    std::cout.precision(20);

    std::cout << "sin(101) = " << _sin(101) << std::endl;
    std::cout << "cos(101) = " << _cos(101) << std::endl;
    std::cout << "tan(101) = " << _tan(101) << std::endl;

    std::cout << "sin(103) = " << _sin(103) << std::endl;
    std::cout << "cos(103) = " << _cos(103) << std::endl;
    std::cout << "tan(103) = " << _tan(103) << std::endl;

    return 0;
}

You will get:

sin(101) = 0.98162718344766397571
cos(101) = -0.19080899537654480436
tan(101) = -5.1445540159703107008
sin(103) = 0.97437006478523524589
cos(103) = -0.22495105434386480914
tan(103) = -4.3314758742841590333

You will find:

sin(101) != sin(103)
cos(101) != cos(103)
tan(101) != tan(101)

So where is that symmetry?

As we are following the previous definitions:

  • from sin(101) take: “9”, “8”, “1”: after decimal separator
  • from cos(101) take: “1”, “9”, “0”: after decimal separator
  • from tan(101) take “5”, “1”, “4”: before decimal separator and after

and

  • from sin(103) take: “9”, “7”, “4”: after decimal separator
    from cos(103) take: “2”, “2”, “4”: after decimal separator
    from tan(103) take “4”, “3”, “3”: before decimal separator and after

From _numbers(101) you will build a sum:
9 + 8 + 1 +
1 + 9 + 0 +
5 + 1 + 4 = 38
And from _numbers(103) you will build a sum:
9 + 7 + 4 +
2 + 2 + 4 +
4 + 3 + 3 = 38

So it means:

sum(_numbers(101)) = sum(_numbers(103))

So it is fact:

When angle number is build of 4 numbers (i.e. “1337”) or any other quantity of numbers – using the same amount of numbers to calculate symmetry from sum(_numbers(x)) will create real symmetry results!

Also we can observe that symmetries are not only at multipliers of 90 degress but at other degree values with different symmetry lengths.

Pretty clever, huh?

I am open for suggestions how it can be possible.

At incoming Part 3. I will introduce c++ code and result text files for larger range of numbers.

Code for this part can be found at Github.

Trigonometry. Prime numbers result file. Part 1.

Hello again. Long time, huh?

Today I will describe a symmetry result file.
Everything has started from generating that file with C++ code.
The result file is here:

https://banit.pl/wp-content/uploads/2019/08/symmetry_results.txt

Three things are important in that file:

  • at header angle means the transformations are generated from that number (i.e. first one is -17999)
  • at header comparisons means the primary numbers are close to transformations from that angle
  • I cannot reproduce that file with C++ code but something told me that is important clue…

Another thing is just weird. If you will be doing some research you will find that the number “2067” is described in some books. At one book is described as year of comet.

At the other side the year 1910 was year of Great January Comet of 1910.

These two numbers has a connection in file.

After doing some research informations from that file has something common with chemical roots… I don’t have time for further research.

So how I generated that file?

You will get this knowledge after some introductions at coming posts.

Next posts will be published at 1:37 or 13:37 Warsaw time.