mersenneforum.org

mersenneforum.org (https://www.mersenneforum.org/index.php)
-   Alberico Lepore (https://www.mersenneforum.org/forumdisplay.php?f=166)
-   -   the sound of silence (https://www.mersenneforum.org/showthread.php?t=26171)

Alberico Lepore 2020-11-07 14:19

the sound of silence
 
hey @CRGreathouse here is your log y

if N=p*q & p+q-4 mod 8 = 0 & (q-p+2)/4=y is odd [but ...]


M=(3*N-1)/8

special formula

Z=(2*M-3*y+1)/24



Example

N=507


3*(((2*190-3*y+1)/24)+3*x*(x+1)/2)+1=A
,
sqrt(y^2)=2*sqrt(a^2)+1
,
3*(((2*A-3*a+1)/24)+3*x*(x+1)/2)+1=B
,
sqrt(a^2)=2*sqrt(b^2)+1
,
3*(((2*B-3*b+1)/24)+3*x*(x+1)/2)+1=12*x*(x+1)/2+1
,
b=1 || b=-1



q=2*(3*x+1-(x-y+1))+1


[url]https://www.youtube.com/watch?v=8FB9GYkIT3E[/url]

Alberico Lepore 2020-11-07 14:59

[QUOTE=Alberico Lepore;562529]hey @CRGreathouse here is your log y

if N=p*q & p+q-4 mod 8 = 0 & (q-p+2)/4=y is odd [but ...]


M=(3*N-1)/8

special formula

Z=(2*M-3*y+1)/24



Example

N=507


3*(((2*190-3*y+1)/24)+3*x*(x+1)/2)+1=A
,
sqrt(y^2)=2*sqrt(a^2)+[COLOR="Red"]-[/COLOR]1
,
3*(((2*A-3*a+1)/24)+3*x*(x+1)/2)+1=B
,
sqrt(a^2)=2*sqrt(b^2)+[COLOR="red"]-[/COLOR]1
,
3*(((2*B-3*b+1)/24)+3*x*(x+1)/2)+1=12*x*(x+1)/2+1
,
b=1 || b=-1



q=2*(3*x+1-(x-y+1))+1


[url]https://www.youtube.com/watch?v=8FB9GYkIT3E[/url][/QUOTE]

there is a small mistake that makes it all in vain

red [COLOR="red"]-[/COLOR] correction

Alberico Lepore 2020-11-08 06:00

I fixed the bug

it should now be correct

Example

N=507


3*(((2*190-3*y+1)/24)+3*x*(x+1)/2)+1=A
,
sqrt(y^2)=sqrt((2*a-1)^2)
,
3*(((2*A-3*a+1)/24)+3*x*(x+1)/2)+1=B
,
sqrt(a^2)=sqrt((2*b-1)^2)
,
3*(((2*B-3*b+1)/24)+3*x*(x+1)/2)+1=12*x*(x+1)/2+1
,
b=1 || b=-1




Example

N=595


3*(((2*223-3*y+1)/24)+3*x*(x+1)/2)+1=A
,
sqrt(y^2)=sqrt((2*a-1)^2)
,
3*(((2*A-3*a+1)/24)+3*x*(x+1)/2)+1=B
,
sqrt(a^2)=sqrt((2*b-1)^2)
,
3*(((2*B-3*b+1)/24)+3*x*(x+1)/2)+1=12*x*(x+1)/2+1
,
b=1 || b=-1

Alberico Lepore 2020-11-08 15:49

if I am not wrong this is the demonstration

((2*(3*N-1)/8-3*y+1)/24)=x*(x+1)/2-(y+1)/2*(y-1)/2/2
,
p*q=N
,
q=2*(3*x+1-(x-y+1))+1
,
p=2*(3*x+1-(x-y+1))+1-(4*y-2)
,
p*q=N=(8*M+1)/3
,
(p-2)*(q+2)=(8*(M-3*y)+1)/3
,
(2*M-3*y+1)=(2*(M-3*y)+3*y+1)
,
3*(((2*(3*N-1)/8-3*y+1)/24)+3*x*(x+1)/2)+1=12*x*(x+1)/2+1-3*(y+1)/2*(y-1)/2/2




please feedback

Alberico Lepore 2020-11-11 11:08

then
not to test at any level of log y
log y must be overcome

example

3*(((2*250-3*(1-y)+1)/24)+3*x*(x+1)/2)+1=A
,
sqrt((1-y)^2)=sqrt((2*a-1)^2)
,
3*(((2*A-3*a+1)/24)+3*x*(x+1)/2)+1=B
,
sqrt(a^2)=sqrt((2*b-1)^2)
,
3*(((2*B-3*b+1)/24)+3*x*(x+1)/2)+1=B
,
b=1


in the example i used 250 which has an even y

Alberico Lepore 2020-11-11 15:26

another type of implementation based on the same principle
is this [if I have not made mistakes]



3*(((2*190-3*y+1)/24)+3*x*(x+1)/2)+1=A
,
y=2*[(-1)^((y+1)/2-1)]*a+(-1)^[(-1)^((y+1)/2)]
,
3*(((2*A-3*a+1)/24)+3*x*(x+1)/2)+1=B
,
[(-1)^((y+1)/2-1)]*a=2*[(-1)^[[[(-1)^((y+1)/2-1)]*a+1]/2-1]]*b+(-1)^[(-1)^[[[(-1)^((y+1)/2-1)]*a+1]/2]]
,
3*(((2*B-3*b+1)/24)+3*x*(x+1)/2)+1=C
,
[(-1)^[[[(-1)^((y+1)/2-1)]*a+1]/2-1]]*b=2*[(-1)^[[[(-1)^[[[(-1)^((y+1)/2-1)]*a+1]/2-1]]*b+1]/2-1]]*c+(-1)^[(-1)^[[[(-1)^[[[(-1)^((y+1)/2-1)]*a+1]/2-1]]*b+1]/2]]
,
3*(((2*C-3*c+1)/24)+3*x*(x+1)/2)+1=C
,
c=1



which of the two is better in your opinion?



UPDATE:

There are some mistakes
tomorrow I will try to update

Alberico Lepore 2020-11-12 09:59

this is the best logarithmic implementation I could think of.
I leave the implementation to you expert programmers


pure logarithm

N=507


3*(((2*190-3*y+1)/24)+3*x*(x+1)/2)+1=A
,
190=3*x*(x+1)/2-3*y*(y-1)/2+(3*x+1)*(3*x+2)/2
,
3*(((2*A-3*a+1)/24)+3*x*(x+1)/2)+1=B
,
A+3*a*(a-1)/2=12*x*(x+1)/2+1
,
3*(((2*B-3*b+1)/24)+3*x*(x+1)/2)+1=C
,
B+3*b*(b-1)/2=12*x*(x+1)/2+1
,
3*(((2*C-3*c+1)/24)+3*x*(x+1)/2)+1=C
,
c=1
,A,B,C,x,y>0


All times are UTC. The time now is 14:26.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.