Friday, January 28, 2022

Prime Number - prefixes

As part of a personal project regarding prime numbers, I created a toolkit to help do some research and one of the interesting finds was related to prime prefixes.

First let me define prime numbers for my use; A prime number is an integer greater than or equal to 1 which can ONLY be expressed by multiplication as itself times 1.  Some definitions seem to exclude 1 but I include it. So the first 5 prime numbers are 1, 2, 3, 5, 7.

As for prefixes, let me first describe a process for constructing prime numbers of 3 or greater.

Each prime number (Pn) > 3 can be created from the sum of some unique subset of the primes P1 to Pn-2  which are added to Pn-1 . Where n is an integer > 0.  If you list out primes in vertical list, n represents the row number of the prime.  P1 represents the prime 1.  P2 represents the prime 2.  P5 represents the prime 7.

Examples:

P1 = 1

P2 = 2

P3 is 3  =>    P1 + P(3-1)    =>    1 + P2     =>  1 + 2    =>  1 + 2 => 3

P4 is 5  =>    P2 + P(4-1)    =>    2 + P3    =>  2 + 3    =>  5 

P5 is 7  =>    P2 + P(5-1)    =>    2 + P =>  2 + 5    =>  7

P6 is 11 =>    P1 + P3 + P(6-1) => 1 + 3 + P5 =>    1 + 3 + 7 =>  11

So "prefix" represents the subset of primes in the range P1 to Pn-2 that are added to Pn-1 to get the value Pn.

So:

P3 has a prefix of a single prime which is 1.

P4  has a prefix of a single prime which is 2.

P5 has a prefix of a single prime which is 2.

P6 has a prefix of two primes: 1,3.

Given those definitions and general method; I added some support to my Prime Tool Kit to find the prefixes for the first 5,000,000 primes. It turned out that only 98 prefixes were needed for that 5,000,000 prime numbers.

Below are the prefixes and the counts of primes associated with each prefix.  Note that the empty prefix [] was for Primes 1 and 2 and the Prefix of [1] is from prime 3. One odd observation is that I didn't run across a prefix consisting of just [1,3,5] - this may be due to some primes having multiple possible prefixes and my algorithm only selects one. One other interesting display form of this would be a tree form (so counts would apply to any common prefix among the prefixes) and show the sum from the current node either down or up the tree.

Prefix: []  count: [2]

Prefix: [1]  count: [1]

Prefix: [2]  count: [385375]

Prefix: [1,3]  count: [385268]

Prefix: [1,2,3]  count: [672224]

Prefix: [1,2,5]  count: [292025]

Prefix: [2,5,7]  count: [255156]

Prefix: [2,3,5]  count: [375266]

Prefix: [2,3,7]  count: [469249]

Prefix: [1,2,3,5,7]  count: [333879]

Prefix: [1,3,5,11]  count: [175644]

Prefix: [1,2,3,5,11]  count: [152378]

Prefix: [2,3,5,11,13]  count: [61166]

Prefix: [1,2,3,7,11]  count: [222949]

Prefix: [1,3,5,7]  count: [187797]

Prefix: [1,2,5,7,11]  count: [103143]

Prefix: [2,3,5,7,11]  count: [111693]

Prefix: [2,3,5,7,13]  count: [191643]

Prefix: [1,2,5,11,13]  count: [58527]

Prefix: [2,3,7,11,13]  count: [97522]

Prefix: [1,3,5,7,11,17]  count: [29594]

Prefix: [1,2,3,5,7,11,13]  count: [73926]

Prefix: [1,3,5,7,11,13]  count: [51884]

Prefix: [1,2,3,5,11,13,17]  count: [17392]

Prefix: [1,2,3,5,7,13,17]  count: [42347]

Prefix: [2,5,7,11,13]  count: [44256]

Prefix: [2,3,7,11,13,17,19]  count: [7043]

Prefix: [1,3,5,11,13,17]  count: [23387]

Prefix: [1,2,5,7,11,17,19]  count: [7155]

Prefix: [1,2,3,7,11,13,17]  count: [28388]

Prefix: [2,3,5,7,11,13,19]  count: [23918]

Prefix: [2,3,5,7,11,13,17]  count: [12368]

Prefix: [1,2,3,5,7,11,17]  count: [25017]

Prefix: [1,2,5,7,11,13,17]  count: [13978]

Prefix: [2,3,5,7,11,17,19]  count: [7398]

Prefix: [1,2,5,11,13,17,19]  count: [5183]

Prefix: [1,3,5,7,11,17,19,23]  count: [1320]

Prefix: [2,3,5,7,13,17,19]  count: [12986]

Prefix: [2,3,5,11,13,17,19]  count: [7383]

Prefix: [1,2,3,5,7,11,13,17,19]  count: [5638]

Prefix: [1,3,5,7,11,13,17,19]  count: [2950]

Prefix: [1,2,3,5,7,11,13,17,23]  count: [1952]

Prefix: [1,2,3,7,11,13,17,19,23]  count: [1325]

Prefix: [2,3,5,7,11,13,19,23,29]  count: [260]

Prefix: [2,3,5,7,11,13,17,19,23]  count: [725]

Prefix: [2,5,7,11,13,17,19]  count: [3586]

Prefix: [1,2,3,5,7,13,17,19,23]  count: [2750]

Prefix: [1,2,3,5,7,11,13,19,23]  count: [3882]

Prefix: [1,2,5,7,11,17,19,23,29]  count: [389]

Prefix: [1,3,5,7,11,13,17,23]  count: [2723]

Prefix: [1,2,3,5,7,11,17,19,23]  count: [1370]

Prefix: [1,2,5,7,11,13,17,19,23]  count: [689]

Prefix: [1,3,5,11,13,17,19,23]  count: [881]

Prefix: [2,3,5,7,11,13,17,19,29]  count: [338]

Prefix: [1,2,3,5,11,13,17,19,23]  count: [800]

Prefix: [2,3,5,7,13,17,19,23,29]  count: [151]

Prefix: [1,2,3,5,7,11,13,17,19,23,31]  count: [105]

Prefix: [1,2,5,7,11,13,17,19,29]  count: [396]

Prefix: [1,2,3,7,11,13,17,19,29]  count: [857]

Prefix: [2,3,5,7,11,13,17,23,29]  count: [377]

Prefix: [2,5,7,11,13,17,19,23,29]  count: [163]

Prefix: [1,2,5,11,13,17,19,23,29]  count: [353]

Prefix: [1,2,3,5,7,11,17,19,23,29,31]  count: [30]

Prefix: [1,2,5,7,11,13,17,23,29]  count: [597]

Prefix: [2,3,5,11,13,17,19,23,29]  count: [107]

Prefix: [1,2,3,5,7,11,13,17,19,29,31]  count: [70]

Prefix: [1,3,5,7,11,13,17,19,23,29]  count: [58]

Prefix: [1,2,3,5,11,13,17,19,23,29,31]  count: [8]

Prefix: [1,2,3,5,7,11,13,17,19,23,29]  count: [58]

Prefix: [2,3,5,7,11,17,19,23,29]  count: [151]

Prefix: [1,3,5,7,11,17,19,23,29,31]  count: [18]

Prefix: [1,3,5,7,11,13,17,19,29,31]  count: [34]

Prefix: [2,3,7,11,13,17,19,23,29]  count: [115]

Prefix: [2,5,7,11,13,17,19,29,31]  count: [36]

Prefix: [1,3,5,7,11,13,17,23,29,31]  count: [44]

Prefix: [1,3,5,11,13,17,19,23,29,31]  count: [18]

Prefix: [1,2,3,5,7,11,13,17,23,29,31]  count: [27]

Prefix: [1,2,3,5,7,11,13,19,23,29,31]  count: [37]

Prefix: [1,2,3,5,7,13,17,19,23,29,31]  count: [29]

Prefix: [2,3,5,7,11,13,19,23,29,31,37]  count: [1]

Prefix: [1,2,3,7,11,13,17,19,23,29,31]  count: [18]

Prefix: [1,2,5,7,11,13,17,19,23,29,37]  count: [4]

Prefix: [1,2,3,5,7,11,13,17,19,23,31,37,41]  count: [1]

Prefix: [1,2,3,7,11,13,17,19,29,31,37]  count: [4]

Prefix: [2,3,5,7,11,13,17,19,23,29,31]  count: [8]

Prefix: [1,2,5,7,11,17,19,23,29,31,37]  count: [1]

Prefix: [2,3,5,7,11,13,17,19,23,31,37]  count: [7]

Prefix: [1,2,5,7,11,13,17,23,29,31,37]  count: [4]

Prefix: [1,2,5,7,11,13,17,19,29,31,37]  count: [1]

Prefix: [1,2,3,7,11,13,17,19,23,29,37]  count: [6]

Prefix: [2,3,5,7,11,13,17,23,29,31,37]  count: [4]

Prefix: [1,2,3,5,7,11,13,17,19,23,29,31,37]  count: [1]

Prefix: [1,2,3,5,7,11,13,17,23,29,31,37,41]  count: [1]

Prefix: [1,2,5,7,11,13,17,19,23,29,31]  count: [7]

Prefix: [2,3,5,7,11,13,17,19,29,31,37]  count: [3]

Prefix: [1,3,5,7,11,13,17,19,23,29,31,37]  count: [1]

Prefix: [2,3,5,7,11,17,19,23,29,31,37]  count: [1]

Prefix: [2,3,5,7,11,13,17,19,23,29,37]  count: [1]

Total handled = 5000001


Thanks for reading!

Scott

Sunday, January 23, 2022

Graphing data related to prime numbers

 It is kind of interesting, as part of the Prime Tool Kit I created, one feature is the generation of all unique combinations of 3 primes that sum to each prime.  

For Prime 863, I took that list of triples and used it to create cubes in the OpenSCAD "Programmers Solid 3D CAD modeller" opensource software.

The toolkit source is available at github.

See my blog entry for more info on the toolkit and its design.

The resulting output was this:




Data / prog here:


for(i = [ 

  [263,293,307], [271,281,311], [269,283,311], [269,281,313], [257,293,313], 

        [239,311,313], [269,277,317], [263,283,317], [239,307,317], [233,313,317], 

        [263,269,331], [251,281,331], [239,293,331], [257,269,337], [233,293,337], 

        [239,277,347], [233,283,347], [223,293,347], [199,317,347], [179,337,347], 

        [251,263,349], [233,281,349], [197,317,349], [167,347,349], [241,269,353], 

        [239,271,353], [233,277,353], [229,281,353], [227,283,353], [199,311,353], 

        [197,313,353], [193,317,353], [179,331,353], [173,337,353], [163,347,353], 

        [241,263,359], [233,271,359], [227,277,359], [223,281,359], [211,293,359], 

        [197,307,359], [193,311,359], [191,313,359], [173,331,359], [167,337,359], 

        [157,347,359], [151,353,359], [239,257,367], [233,263,367], [227,269,367], 

        [179,317,367], [149,347,367], [137,359,367], [239,251,373], [233,257,373], 

        [227,263,373], [197,293,373], [179,311,373], [173,317,373], [137,353,373], 

        [131,359,373], [233,251,379], [227,257,379], [191,293,379], [173,311,379], 

        [167,317,379], [137,347,379], [131,353,379], [239,241,383], [229,251,383], 

        [223,257,383], [211,269,383], [199,281,383], [197,283,383], [173,307,383], 

        [167,313,383], [163,317,383], [149,331,383], [131,349,383], [127,353,383], 

        [113,367,383], [107,373,383], [101,379,383], [233,241,389], [223,251,389], 

        [211,263,389], [197,277,389], [193,281,389], [191,283,389], [181,293,389], 

        [167,307,389], [163,311,389], [157,317,389], [137,337,389], [127,347,389], 

        [107,367,389], [101,373,389], [227,239,397], [197,269,397], [173,293,397], 

        [149,317,397], [113,353,397], [107,359,397], [83,383,397], [229,233,401], 

        [223,239,401], [211,251,401], [199,263,401], [193,269,401], [191,271,401], 

        [181,281,401], [179,283,401], [151,311,401], [149,313,401], [131,331,401], 

        [113,349,401], [109,353,401], [103,359,401], [89,373,401], [83,379,401], 

        [79,383,401], [73,389,401], [197,257,409], [191,263,409], [173,281,409], 

        [137,317,409], [107,347,409], [101,353,409], [71,383,409], [53,401,409], 

        [211,233,419], [193,251,419], [181,263,419], [173,271,419], [167,277,419], 

        [163,281,419], [151,293,419], [137,307,419], [131,313,419], [127,317,419], 

        [113,331,419], [107,337,419], [97,347,419], [71,373,419], [61,383,419], 

        [47,397,419], [43,401,419], [191,251,421], [179,263,421], [173,269,421], 

        [149,293,421], [131,311,421], [89,353,421], [83,359,421], [59,383,421], 

        [53,389,421], [41,401,421], [23,419,421], [199,233,431], [193,239,431], 

        [191,241,431], [181,251,431], [163,269,431], [151,281,431], [149,283,431], 

        [139,293,431], [101,331,431], [83,349,431], [79,353,431], [73,359,431], 

        [59,373,431], [53,379,431], [43,389,431], [31,401,431], [23,409,431], 

        [13,419,431], [11,421,431], [197,233,433], [191,239,433], [179,251,433], 

        [173,257,433], [167,263,433], [149,281,433], [137,293,433], [113,317,433], 

        [83,347,433], [71,359,433], [47,383,433], [41,389,433], [29,401,433], 

        [11,419,433], [197,227,439], [191,233,439], [173,251,439], [167,257,439], 

        [131,293,439], [113,311,439], [107,317,439], [71,353,439], [41,383,439], 

        [23,401,439], [5,419,439], [3,421,439], [197,223,443], [193,227,443], 

        [191,229,443], [181,239,443], [179,241,443], [163,257,443], [157,263,443], 

        [151,269,443], [149,271,443], [139,281,443], [137,283,443], [127,293,443], 

        [113,307,443], [109,311,443], [107,313,443], [103,317,443], [89,331,443], 

        [83,337,443], [73,347,443], [71,349,443], [67,353,443], [61,359,443], 

        [53,367,443], [47,373,443], [41,379,443], [37,383,443], [31,389,443], 

        [23,397,443], [19,401,443], [11,409,443], [1,419,443], [191,223,449], 

        [181,233,449], [173,241,449], [163,251,449], [157,257,449], [151,263,449], 

        [137,277,449], [131,283,449], [107,307,449], [103,311,449], [101,313,449], 

        [97,317,449], [83,331,449], [67,347,449], [61,353,449], [47,367,449], 

        [41,373,449], [31,383,449], [17,397,449], [13,401,449], [5,409,449], 

        [179,227,457], [173,233,457], [167,239,457], [149,257,457], [137,269,457], 

        [113,293,457], [89,317,457], [59,347,457], [53,353,457], [47,359,457], 

        [23,383,457], [17,389,457], [5,401,457], [191,211,461], [179,223,461], 

        [173,229,461], [163,239,461], [151,251,461], [139,263,461], [131,271,461], 

        [109,293,461], [89,313,461], [71,331,461], [53,349,461], [43,359,461], 

        [29,373,461], [23,379,461], [19,383,461], [13,389,461], [5,397,461], 

        [1,401,461], [173,227,463], [167,233,463], [149,251,463], [137,263,463], 

        [131,269,463], [107,293,463], [89,311,463], [83,317,463], [53,347,463], 

        [47,353,463], [41,359,463], [17,383,463], [11,389,463], [3,397,463], 

        [197,199,467], [173,223,467], [167,229,467], [163,233,467], [157,239,467], 

        [139,257,467], [127,269,467], [113,283,467], [103,293,467], [89,307,467], 

        [83,313,467], [79,317,467], [59,337,467], [47,349,467], [43,353,467], 

        [37,359,467], [29,367,467], [23,373,467], [17,379,467], [13,383,467], 

        [7,389,467], [191,193,479], [173,211,479], [157,227,479], [151,233,479], 

        [127,257,479], [113,271,479], [107,277,479], [103,281,479], [101,283,479], 

        [73,311,479], [71,313,479], [67,317,479], [53,331,479], [47,337,479], 

        [37,347,479], [31,353,479], [17,367,479], [11,373,479], [5,379,479], 

        [1,383,479], [179,197,487], [149,227,487], [137,239,487], [113,263,487], 

        [107,269,487], [83,293,487], [59,317,487], [29,347,487], [23,353,487], 

        [17,359,487], [3,373,487], [181,191,491], [179,193,491], [173,199,491], 

        [149,223,491], [139,233,491], [131,241,491], [109,263,491], [103,269,491], 

        [101,271,491], [89,283,491], [79,293,491], [61,311,491], [59,313,491], 

        [41,331,491], [23,349,491], [19,353,491], [13,359,491], [5,367,491], 

        [173,191,499], [167,197,499], [137,227,499], [131,233,499], [113,251,499], 

        [107,257,499], [101,263,499], [83,281,499], [71,293,499], [53,311,499], 

        [47,317,499], [17,347,499], [11,353,499], [5,359,499], [179,181,503], 

        [167,193,503], [163,197,503], [149,211,503], [137,223,503], [131,229,503], 

        [127,233,503], [109,251,503], [103,257,503], [97,263,503], [89,271,503], 

        [83,277,503], [79,281,503], [67,293,503], [53,307,503], [47,313,503], 

        [43,317,503], [29,331,503], [23,337,503], [13,347,503], [11,349,503], 

        [7,353,503], [1,359,503], [173,181,509], [163,191,509], [157,197,509], 

        [131,223,509], [127,227,509], [113,241,509], [103,251,509], [97,257,509], 

        [83,271,509], [73,281,509], [71,283,509], [61,293,509], [47,307,509], 

        [43,311,509], [41,313,509], [37,317,509], [23,331,509], [17,337,509], 

        [7,347,509], [5,349,509], [1,353,509], [163,179,521], [151,191,521], 

        [149,193,521], [131,211,521], [113,229,521], [109,233,521], [103,239,521], 

        [101,241,521], [79,263,521], [73,269,521], [71,271,521], [61,281,521], 

        [59,283,521], [31,311,521], [29,313,521], [11,331,521], [5,337,521], 

        [167,173,523], [149,191,523], [113,227,523], [107,233,523], [101,239,523], 

        [89,251,523], [83,257,523], [71,269,523], [59,281,523], [47,293,523], 

        [29,311,523], [23,317,523], [3,337,523], [149,173,541], [131,191,541], 

        [89,233,541], [83,239,541], [71,251,541], [59,263,541], [53,269,541], 

        [41,281,541], [29,293,541], [11,311,541], [5,317,541], [149,167,547], 

        [137,179,547], [89,227,547], [83,233,547], [59,257,547], [53,263,547], 

        [47,269,547], [23,293,547], [5,311,547], [3,313,547], [149,157,557], 

        [139,167,557], [127,179,557], [113,193,557], [109,197,557], [107,199,557], 

        [83,223,557], [79,227,557], [73,233,557], [67,239,557], [43,263,557], 

        [37,269,557], [29,277,557], [23,283,557], [13,293,557], [149,151,563], 

        [137,163,563], [127,173,563], [109,191,563], [107,193,563], [103,197,563], 

        [101,199,563], [89,211,563], [73,227,563], [71,229,563], [67,233,563], 

        [61,239,563], [59,241,563], [43,257,563], [37,263,563], [31,269,563], 

        [29,271,563], [23,277,563], [19,281,563], [17,283,563], [7,293,563], 

        [137,157,569], [131,163,569], [127,167,569], [113,181,569], [103,191,569], 

        [101,193,569], [97,197,569], [83,211,569], [71,223,569], [67,227,569], 

        [61,233,569], [53,241,569], [43,251,569], [37,257,569], [31,263,569], 

        [23,271,569], [17,277,569], [13,281,569], [11,283,569], [1,293,569], 

        [113,179,571], [101,191,571], [59,233,571], [53,239,571], [41,251,571], 

        [29,263,571], [23,269,571], [11,281,571], [137,149,577], [113,173,577], 

        [107,179,577], [89,197,577], [59,227,577], [53,233,577], [47,239,577], 

        [29,257,577], [23,263,577], [17,269,577], [5,281,577], [3,283,577], 

        [137,139,587], [127,149,587], [113,163,587], [109,167,587], [103,173,587], 

        [97,179,587], [83,193,587], [79,197,587], [53,223,587], [47,229,587], 

        [43,233,587], [37,239,587], [19,257,587], [13,263,587], [7,269,587], 

        [5,271,587], [131,139,593], [113,157,593], [107,163,593], [103,167,593], 

        [97,173,593], [89,181,593], [79,191,593], [73,197,593], [71,199,593], 

        [59,211,593], [47,223,593], [43,227,593], [41,229,593], [37,233,593], 

        [31,239,593], [29,241,593], [19,251,593], [13,257,593], [7,263,593], 

        [1,269,593], [127,137,599], [113,151,599], [107,157,599], [101,163,599], 

        [97,167,599], [83,181,599], [73,191,599], [71,193,599], [67,197,599], 

        [53,211,599], [41,223,599], [37,227,599], [31,233,599], [23,241,599], 

        [13,251,599], [7,257,599], [1,263,599], [113,149,601], [89,173,601], 

        [83,179,601], [71,191,601], [29,233,601], [23,239,601], [11,251,601], 

        [5,257,601], [107,149,607], [89,167,607], [83,173,607], [59,197,607], 

        [29,227,607], [23,233,607], [17,239,607], [5,251,607], [113,137,613], 

        [101,149,613], [83,167,613], [71,179,613], [59,191,613], [53,197,613], 

        [23,227,613], [17,233,613], [11,239,613], [109,137,617], [107,139,617], 

        [97,149,617], [89,157,617], [83,163,617], [79,167,617], [73,173,617], 

        [67,179,617], [53,193,617], [47,199,617], [23,223,617], [19,227,617], 

        [17,229,617], [13,233,617], [7,239,617], [5,241,617], [113,131,619], 

        [107,137,619], [71,173,619], [53,191,619], [47,197,619], [17,227,619], 

        [11,233,619], [5,239,619], [3,241,619], [101,131,631], [83,149,631], 

        [59,173,631], [53,179,631], [41,191,631], [5,227,631], [3,229,631], 

        [109,113,641], [83,139,641], [73,149,641], [71,151,641], [59,163,641], 

        [43,179,641], [41,181,641], [31,191,641], [29,193,641], [23,199,641], 

        [11,211,641], [107,113,643], [89,131,643], [83,137,643], [71,149,643], 

        [53,167,643], [47,173,643], [41,179,643], [29,191,643], [23,197,643], 

        [107,109,647], [103,113,647], [89,127,647], [79,137,647], [67,149,647], 

        [59,157,647], [53,163,647], [43,173,647], [37,179,647], [23,193,647], 

        [19,197,647], [17,199,647], [5,211,647], [103,107,653], [101,109,653], 

        [97,113,653], [83,127,653], [79,131,653], [73,137,653], [71,139,653], 

        [61,149,653], [59,151,653], [53,157,653], [47,163,653], [43,167,653], 

        [37,173,653], [31,179,653], [29,181,653], [19,191,653], [17,193,653], 

        [13,197,653], [11,199,653], [101,103,659], [97,107,659], [73,131,659], 

        [67,137,659], [53,151,659], [47,157,659], [41,163,659], [37,167,659], 

        [31,173,659], [23,181,659], [13,191,659], [11,193,659], [7,197,659], 

        [5,199,659], [89,113,661], [71,131,661], [53,149,661], [29,173,661], 

        [23,179,661], [11,191,661], [5,197,661], [3,199,661], [89,101,673], 

        [83,107,673], [59,131,673], [53,137,673], [41,149,673], [23,167,673], 

        [17,173,673], [11,179,673], [89,97,677], [83,103,677], [79,107,677], 

        [73,113,677], [59,127,677], [47,139,677], [37,149,677], [29,157,677], 

        [23,163,677], [19,167,677], [13,173,677], [7,179,677], [5,181,677], 

        [83,97,683], [79,101,683], [73,107,683], [71,109,683], [67,113,683], 

        [53,127,683], [43,137,683], [41,139,683], [31,149,683], [29,151,683], 

        [23,157,683], [17,163,683], [13,167,683], [7,173,683], [1,179,683], 

        [83,89,691], [71,101,691], [59,113,691], [41,131,691], [23,149,691], 

        [5,167,691], [79,83,701], [73,89,701], [61,101,701], [59,103,701], 

        [53,109,701], [31,131,701], [23,139,701], [13,149,701], [11,151,701], 

        [5,157,701], [71,83,709], [53,101,709], [47,107,709], [41,113,709], 

        [23,131,709], [17,137,709], [5,149,709], [3,151,709], [71,73,719], 

        [61,83,719], [47,97,719], [43,101,719], [41,103,719], [37,107,719], 

        [31,113,719], [17,127,719], [13,131,719], [7,137,719], [5,139,719], 

        [53,83,727], [47,89,727], [29,107,727], [23,113,727], [5,131,727], 

        [59,71,733], [47,83,733], [41,89,733], [29,101,733], [23,107,733], 

        [17,113,733], [3,127,733], [53,71,739], [41,83,739], [23,101,739], 

        [17,107,739], [11,113,739], [59,61,743], [53,67,743], [47,73,743], 

        [41,79,743], [37,83,743], [31,89,743], [23,97,743], [19,101,743], 

        [17,103,743], [13,107,743], [11,109,743], [7,113,743], [53,59,751], 

        [41,71,751], [29,83,751], [23,89,751], [11,101,751], [5,107,751], 

        [3,109,751], [47,59,757], [23,83,757], [17,89,757], [5,101,757], 

        [3,103,757], [43,59,761], [41,61,761], [31,71,761], [29,73,761], 

        [23,79,761], [19,83,761], [13,89,761], [5,97,761], [1,101,761], 

        [41,53,769], [23,71,769], [11,83,769], [5,89,769], [43,47,773], 

        [37,53,773], [31,59,773], [29,61,773], [23,67,773], [19,71,773], 

        [17,73,773], [11,79,773], [7,83,773], [1,89,773], [29,47,787], 

        [23,53,787], [17,59,787], [5,71,787], [3,73,787], [29,37,797], 

        [23,43,797], [19,47,797], [13,53,797], [7,59,797], [5,61,797], 

        [23,31,809], [17,37,809], [13,41,809], [11,43,809], [7,47,809], 

        [1,53,809], [23,29,811], [11,41,811], [5,47,811], [19,23,821], 

        [13,29,821], [11,31,821], [5,37,821], [1,41,821], [17,23,823], 

        [11,29,823], [3,37,823], [17,19,827], [13,23,827], [7,29,827], 

        [5,31,827], [11,23,829], [5,29,829], [3,31,829], [11,13,839], 

        [7,17,839], [5,19,839], [1,23,839], [3,7,853], [1,5,857], 

        [1,3,859]

] )

{    

    cube(i, center=true);

}


Friday, January 14, 2022

PrimeToolkit - BETA

I've had a pet project for a while related to Prime Numbers and a number of other things.  I finally took some time and created the start of what i'll describe as a toolkit.  

I've made it available on github; https://github.com/scottcase3374/primetoolkit

[Update 2022/01/25]

I'm integrating in the LWJGL library to allow creating some different 3D representations of some of the data. Hopefully that won't take too long to get into a useful state.

The LWJGL libraries were a bit excessive considering some of my goals.  I've still got the default visualization support I started with and have cleaned up and extended things quite a bit.


I exported some of the data to visualize it using an opensource program- OpenSCAD.  See my blog entry about the visualized data.


The toolkit is organized along the lines of this:


The above diagram was created using yed. The source diagram file is found here.

I'm fairly happy with how it has turned out so far but with software development - it may never be completely "done" as I find new things to experiment with or tweak.  I'd still like to include some metrics generation and a few experimental data structures to compare time/space trade-offs.

Below is a quick demo of it - the demo is not as polished as desired but will hopefully be understandable enough for now.  I did end up reducing some of the data ranges for the demo since running the demo and OBS studio at the same time was fairly resource intensive.



Thanks,

Scott

Monday, January 10, 2022

Door stopper options - trying something new

I decided to try something different than the normal door stoppers that screw into your baseboard.  Why?  I guess because I can..  The hope is it would have a cleaner look and not prevent any type of snag hazard.  I used these items on our master bedroom closet doors - which are not overly wide and are very light.  Some of the reviews I read indicated they might not be a great fit for solid core doors or doors with a potential to be slammed much (i.e. young kids). I'll agree with that - forcing past the set point would strain the hinges and likely cause damage at some point.

These do have a decent amount of adjustment possible though which was nice. One closet door I just wanted to prevent from hitting the wall but the second door could hit a painting if we were careless.  We'll see if these result in damage to the trim over time - hoping not.

These simply go above the hinge and your existing hinge pin goes through it - note that the hinge pin won't end up going as far down in the hinge as before - with a heavier / wider door you might want to find long hinge pins if available or find a way to extend the existing pins.

And yes, you'll notice I am missing the rosettes at the top of the trim as I mentioned in a different post.. working on those still. I also need to do  some hole filling and touch up painting.


Wishing everyone a blessed day!

Scott 

 

Doorway rosettes and Lowes delivery

 I've been slowly working my way through our house and replacing flooring, painting and we had decided on some more ornate trim for the interior doors (plus paint doors and trim in white).

I completed most of the master bath and master bedroom trim minus some floor trim, rosettes on outside of closet doors and still needed to paint and trim the door to the lanai. I needed more trim and rosettes though - lets call some of my initial attempts "practice work".  Trying to find a good way to quickly/easily strip off the paint from my worse mistakes was a great way to spend money on new tools/accessories, waste time and make a bigger mess with some of the rosettes and door trim. I can't quite get myself to just trash all of them but I did listen to the advise of my wonderful wife and father as well - order new stuff so I can just get it done.

This is good advice but even it comes with problems. I used the "pick up at store" option for the door trim since this time I couldn't find a way to get free shipping.  The trim that was waiting for me at the store was the correct trim but the people picking don't really check the items for quality so some had a number of spots I had to fill with wood putty and sand before I can do much.

For the top corner pieces for the doors, I was able to order and get free shipping - in fact, it didn't offer me an option for pickup at store because it looks like it had to come from a nearby store instead of my normal location.  What I ordered are pieces with a flower shape - what I ended up getting was a mix of the flower shape (bottom of below picture) and a different shape.  I was perplexed at first and then realized that the "wrong" items actually are marked with the same item/model # as the correct ones.  So if someone just had a bunch of these face down and sticker up - they would get a random selection of the 2 items.  I need to contact Lowes to correct this - hope next time it works out correct.  Fortunately, this isn't that important in the grand scheme of life so not really a big deal.


And just in case this helps someone else; I had used a mix of latex paint and polyurethane which I had sprayed the initial trim and rosettes with.  A low odor, weaker paint stripper didn't work great.  Nor does a soda blaster work great in this case.  A drill with brass or steel wire wheel works but can damage the trim and effectively remove detail from the rosettes pretty quickly.  With the grooves in the trim and the details in the rosettes - it is hard to scrape in an effective fashion.  For the door trim, a drill with a nylon wheel actually worked pretty well and was less prone to damaging the wood.   For the rosettes, I'm slowly (trying to fix) some of them with a file (to recreate the grooves) and picked up a small wood carving set as well (i.e. used the opportunity to justify the need for a few more small tools).  For now, I'll focus on doing a better job spraying the new rosettes now that I know what works/doesn't..   Don't paint anything when the temps and humidity are high..


The end result is supposed to look like the picture below - note that I still have a bit of caulking/filler and touch up painting to do.



Below is a pic from the outside of the same door prior to putting up the door trim and rosettes - end result after adding trim is pretty much like the above picture.

Thanks for reading..

Scott


Harbor Freight compressor repaired!

I had bought a cheap Harbor Freight air compressor for some small stuff around the house so I didn't have to drag my 30 gallon rolling compressor around which gets awkward for small/quick needs.  I knew they are not great quality but figured I wouldn't be using it all the time. One day my wife had a need at work though - she needed an air source to blow the dust out of computers at the schools she works at.  I figured this was a good use for the harbor freight unit so I toted it out to the car with a good air house and a nice blow gun setup.

When she got home that night, she said it worked fine until it stopped working completely.  Uh oh..  Note, I know she wasn't at fault - some of this equipment just has some flaws.

I had planned to look at it for months now and had left it sitting in the corner of the garage. I finally got around to looking at it about a week ago and quickly found that the tube from the compressor to the air tank and snapped in half at the point of one of the compression nuts.  The tube is relatively thick walled and appears to be aluminum. After a bit of research and trips to Lowes, I had what I needed - a piece of 1/4" soft copper tubing and 2 new ferrules.  I ended up just reusing the existing nuts.  I was going to replace both the nuts and ferrules but it seems like an odd size which wasn't at Lowes at the time.


I didn't end up using the compression nut/inserts in the pic below - the thread size didn't match what I needed but the copper tubing was fine - just needed to cut an appropriate size chunk off of it.


You can see pretty clearly the wall thickness difference between the 2 tubes.  I did some some quick checking to determine whether the copper tubing was too thin for this use but all the numbers I found indicated it was more than adequate.  The compressor only goes to 100 psi.
You can see the break in the original tubing here and I'm showing the copper tubing with the a new ferrule on one end along with one of the original nuts on it.


Just to add a bit of safety factor, I tested the compressor up to 60 psi and left it for a few days - it held the pressure with no leaks.  I then filled it to 100 psi and left it for a few more days and it has not leaked air yet.


You would think that I was done at this point but I found that I didn't keep the tube bend low enough which results in it preventing the cover from being reinstalled.  I'll handle that shortly - at least I know this works overall.  I did find that I have to be extremely careful with the copper tubing though - it will kink pretty easily when bending.  I could probably find a few ways to help reduce that - heat it up with a torch to soften it a bit more and maybe run something inside of it like a couple decent diameter wires to help limit the kink.  Just need to be careful to prevent getting the wires stuck.

Below pic is before fixing the tube bend to prevent interference when putting the cover back. The copper tube is in the mid/lower foreground.







Drapery and rod finally reinstalled - master bedroom

After replacing the flooring and painting the room, I wanted to put the drapes back up.  They came with house but are ok for now.  Unfortunately, I misplaced something or thought I did - too embarrassed to admin what exactly.  Anyways, once I got it sorted out I was able to get everything put back into place.  I had done some significant patching where it was attached to the wall before and this time I used some deck screws with the star shaped heads (T20?) since I have had a number of issues with Phillips head screws stripping out elsewhere. This worked perfectly.

I had painted the finials on the ends of the bar to match the trim in the room.  I haven't painted the actual bar yet - well see if I do, it isn't a high priority.

There are blinds as well which is good thing. The drapes just darken the room a bit extra against some mid-morning sun.

I got this done around new years or so - still some more work to do in the master bedroom but it isn't a total mess now.





Pioneer Mini-split heat pump arrives

My new mini-split heat pump has arrived!  This is for my office for which the main house AC is connected to but the location lacks temperature control.  With no temp control and the hot water heater located in the room, it gets extremely warm. It is difficult to work (or interview) when the room is in the upper 80's.  It is a 9000 btu unit which should be more than adequate for my office.

I just need to take the time to install it now.  I ended up getting a wall mounted unit - I  was going to get a ceiling cassette model but decided the extra cost/complexity to install it was too much.



 


Here is a link over to the Pioneer site.

I'm hoping some things are a little easier after getting this in installed. I'll have to blog a bit on the install once done.


John 14:1 Do not let your hearts be troubled. You believe in God; believe also in me.  (NIV)