• Welcome to the new Internet Infidels Discussion Board, formerly Talk Freethought.

Python programming project

excreationist

Married mouth-breather
Joined
Aug 28, 2000
Messages
2,644
Location
Australia
Basic Beliefs
Probably in a simulation
From "Metaphysics > Base 6 the magic base" post 22:

https://talkfreethought.org/showthr...the-magic-base&p=673695&viewfull=1#post673695

In the novel "Contact" by Carl Sagan there is a hidden message encoded in PI in base 11:
She find a long string of 1's and 0's late in the expansion of Pi in base 11. It's length is a product of two primes, indicating a two dimensional array. So, she plots it on her computer screen (each digit representing a pixel) and sees a perfect circle. The constant which describes the ratio of a circle's circumference to its diameter itself contains a picture of a circle!


I heard that Tau is superior to Pi (tau = 2 PI)
https://en.wikipedia.org/wiki/Turn_(geometry)#Tau_proposals


Then I thought the base should be base 36:
https://en.wikipedia.org/wiki/Senary#Base_36_as_senary_compression


(Math.PI*2).toString(36) [in the javascript console]


= 6.a70akmheav


hmmmm kind of interesting... I'll see if I can get more characters


https://pythonhosted.org/bigfloat/


"...arbitrary-precision floating-point reliable arithmetic...."

Here is how to convert integers to Base 36 in Python:
https://en.wikipedia.org/wiki/Base36#Python_implementation

I was wondering if someone could help convert 2PI (Tau) into Base 36 as floating point so I can see what happens after 6.a70akmheav

edit:
I noticed that I could shift the decimal place by multiplying by 36...

(2*pi*(36**14)).toString(36)

= 6a70akmheaw0000 (the zeroes would be from the limited precision)

edit:

The Wikipedia link about Base 36 conversion in Python can handle hundreds of digits....

https://docs.python.org/3/library/math.html

Looks like there is math.tau in python 3.6
 
Last edited:
From "Metaphysics > Base 6 the magic base" post 22:

https://talkfreethought.org/showthr...the-magic-base&p=673695&viewfull=1#post673695

In the novel "Contact" by Carl Sagan there is a hidden message encoded in PI in base 11:
She find a long string of 1's and 0's late in the expansion of Pi in base 11. It's length is a product of two primes, indicating a two dimensional array. So, she plots it on her computer screen (each digit representing a pixel) and sees a perfect circle. The constant which describes the ratio of a circle's circumference to its diameter itself contains a picture of a circle!


I heard that Tau is superior to Pi (tau = 2 PI)
https://en.wikipedia.org/wiki/Turn_(geometry)#Tau_proposals


Then I thought the base should be base 36:
https://en.wikipedia.org/wiki/Senary#Base_36_as_senary_compression


(Math.PI*2).toString(36) [in the javascript console]


= 6.a70akmheav


hmmmm kind of interesting... I'll see if I can get more characters


https://pythonhosted.org/bigfloat/


"...arbitrary-precision floating-point reliable arithmetic...."

Here is how to convert integers to Base 36 in Python:
https://en.wikipedia.org/wiki/Base36#Python_implementation

I was wondering if someone could help convert 2PI (Tau) into Base 36 as floating point so I can see what happens after 6.a70akmheav

thanks!

Did you say floating point?

Anything that happens beyond 6.a70akmheav will be rounded off with standard floating point numbers.

You may have better luck with the arbitrary precision `Decimal` number format.

Or better yet maybe, derive the value in base 36 to start with based on formula like https://en.wikipedia.org/wiki/Viète's_formula or some such - since any decimal representation you may start with is an approximation too.
 
Did you say floating point?

Anything that happens beyond 6.a70akmheav will be rounded off with standard floating point numbers.
https://pythonhosted.org/bigfloat/
says "...arbitrary-precision floating-point reliable arithmetic...."
Note it includes const_pi()

You may have better luck with the arbitrary precision `Decimal` number format.
Hmmm....
https://docs.python.org/2/library/decimal.html

I tried this:
>>> from decimal import *
>>> Decimal('1.00000000000000000000000000000000000000000000000000000000000000000000000000000000001')
and it works!

Or better yet maybe, derive the value in base 36 to start with based on formula like https://en.wikipedia.org/wiki/Viète's_formula or some such - since any decimal representation you may start with is an approximation too.
Thanks for the ideas... I'm a beginner as far as python goes - I appreciate the help
 
Did you say floating point?

Anything that happens beyond 6.a70akmheav will be rounded off with standard floating point numbers.
https://pythonhosted.org/bigfloat/
says "...arbitrary-precision floating-point reliable arithmetic...."

You may have better luck with the arbitrary precision `Decimal` number format.

Or better yet maybe, derive the value in base 36 to start with based on formula like https://en.wikipedia.org/wiki/Viète's_formula or some such - since any decimal representation you may start with is an approximation too.
Thanks for the ideas... I'm a beginner as far as python goes - I appreciate the help

There's nothing python specific about floating point imprecision.
 
There's nothing python specific about floating point imprecision.
It seems to have arbitrarily long integers and decimals built in and python is a popular language so I thought we could focus on python.
 
Ok I found the answer:

https://www.wolframalpha.com/input/?i=pi+*+2+in+base+36

BaseForm[Pi 2, 36]

6.a70akmheavkkb2z4e50glko8fttz6kp732jzaih7nv8c3rx9k2vjxmp09o5gvik5r2lse0oyd22a7e7yjz6abp5z614lft3wx3do0cf1wjtbyryja937msrn1s4mcakpjf16j724dlmaogvuhkb7fkufekd2ancyp5e6ygtxu8x4f9yldwzl0jab4d8qmqeyly8i37e4dygl4l1afgvycm8jtzc8d7bogw480g1qch6ud8kkj05xpy1m5dze4f32j6g4tgk3ts01f1ecfe0joffhefy6ior0k456trthifzvacdzlswcnpxtwu9iq8gwlh1wwgdnjlqqmcqhs6k8pwmh3gwa325hg23abl36uts8rlttkpcwddb7um9sxf0pqvp7jk3up6p4693086p4o53fz76yukic8fyxk0p2tubhx0qp3gjq5weh0p89ei974uqvmqnsrbdw0emsedrc3vq4im6hp5cm6rcaxc1r6yfyd07bbetwxbyltsuh5z2h8baxl3xb0owcrb8bgh4y56p10a1krikab06yalal0g6am01sn6fiu7jebi58qe9trnw8mcltylkxibzfl59v88mv9wi4pw8tb6w1y5djmg8vu2n6xauqn02ctw569nunaqn3wv1x0h1opd7zliwjty4v81a38w7dfvosnxurzxhs21vdzvfttl88yd602q0ki75awqwg9coywk6ywsnnaqymc8i4fcfoyp7zn32hqx66t94fqv7vizqdp0lnmxw0vjoy8disu27qmoogv806w87hj1mrcbn66c8io28xpsskz2b784zsu40j1rhr4be2o8yxw0t7rs6xjvs7728ucv2gscma6oegxazlekp4uz0jbpwg9lhd0a6c8afs6i3jtrmskdeoqbrry4dzfzdh1tkjhq7yg554npac3tc0b09xkz4nvi2qw6c1go1anxzb353qtnwmmmtd0fvpeumqcc7jfn1148jgrb0ll6xg4z82ifiwvww0jph07q3el8y
 
Ok I found the answer:

https://www.wolframalpha.com/input/?i=pi+*+2+in+base+36

BaseForm[Pi 2, 36]

6.a70akmheavkkb2z4e50glko8fttz6kp732jzaih7nv8c3rx9k2vjxmp09o5gvik5r2lse0oyd22a7e7yjz6abp5z614lft3wx3do0cf1wjtbyryja937msrn1s4mcakpjf16j724dlmaogvuhkb7fkufekd2ancyp5e6ygtxu8x4f9yldwzl0jab4d8qmqeyly8i37e4dygl4l1afgvycm8jtzc8d7bogw480g1qch6ud8kkj05xpy1m5dze4f32j6g4tgk3ts01f1ecfe0joffhefy6ior0k456trthifzvacdzlswcnpxtwu9iq8gwlh1wwgdnjlqqmcqhs6k8pwmh3gwa325hg23abl36uts8rlttkpcwddb7um9sxf0pqvp7jk3up6p4693086p4o53fz76yukic8fyxk0p2tubhx0qp3gjq5weh0p89ei974uqvmqnsrbdw0emsedrc3vq4im6hp5cm6rcaxc1r6yfyd07bbetwxbyltsuh5z2h8baxl3xb0owcrb8bgh4y56p10a1krikab06yalal0g6am01sn6fiu7jebi58qe9trnw8mcltylkxibzfl59v88mv9wi4pw8tb6w1y5djmg8vu2n6xauqn02ctw569nunaqn3wv1x0h1opd7zliwjty4v81a38w7dfvosnxurzxhs21vdzvfttl88yd602q0ki75awqwg9coywk6ywsnnaqymc8i4fcfoyp7zn32hqx66t94fqv7vizqdp0lnmxw0vjoy8disu27qmoogv806w87hj1mrcbn66c8io28xpsskz2b784zsu40j1rhr4be2o8yxw0t7rs6xjvs7728ucv2gscma6oegxazlekp4uz0jbpwg9lhd0a6c8afs6i3jtrmskdeoqbrry4dzfzdh1tkjhq7yg554npac3tc0b09xkz4nvi2qw6c1go1anxzb353qtnwmmmtd0fvpeumqcc7jfn1148jgrb0ll6xg4z82ifiwvww0jph07q3el8y

Is that rounded or truncated? Or is it the result of converting a rounded/truncated binary or decimal representation without properly accounting for its imprecision? You understand that since we're talking about representing an irrational number in an integer base, it cannot, in principle, be precise?
 
Is that rounded or truncated? Or is it the result of converting a rounded/truncated binary or decimal representation without properly accounting for its imprecision? You understand that since we're talking about representing an irrational number in an integer base, it cannot, in principle, be precise?
It isn't the full answer but it is long enough for now
 
Is that rounded or truncated? Or is it the result of converting a rounded/truncated binary or decimal representation without properly accounting for its imprecision? You understand that since we're talking about representing an irrational number in an integer base, it cannot, in principle, be precise?
It isn't the full answer but it is long enough for now

Long enough for what? For most practical purposes, your original answer is good enough, and a füll answer you'll Never get
 
It isn't the full answer but it is long enough for now
Long enough for what?
To see if there are any obvious messages

For most practical purposes, your original answer is good enough,
No the original answer had half a message - "heav..."

and a füll answer you'll Never get
In the Carl Sagan story there was a message in Pi and that was after a limited number of decimal places.

BTW in 1/(2Pi) there is the word "scrum"
https://talkfreethought.org/showthr...the-magic-base&p=673717&viewfull=1#post673717

Wolfram Alpha can show up to 1045 digits...
 
Back
Top Bottom