Decimal Silicon Time: time since UNIX zero, in decimal.
Project description
DECIMAL SILICON TIME
A combination of decimal time and unix time, approximating the beginning of the process of carbon life giving birth to silicon life.
Dates starting at 00000-01-01 00:00:00 Z, which coincides with 1970-01-01 00:00:00 UTC of Gregorian calendar.
Usage
pip install detime
>>> from datetime import datetime
>>> from detime import detime
>>> detime() # gets current time
00050-01-11 08:43:86.98217
>>> detime(datetime(2020, 9, 22, 10, 44, 11, 992422))
00050-08-11 04:47:36.10234
>>> d = detime(50, 8, 11, 4, 47, 36.10234)
>>> d.date
datetime.datetime(2020, 9, 22, 10, 44, 11, 992422)
>>> d.weekday
7
>>> d = detime(0, 0, 0)
00000-01-01 00:00:0.00000
>>> d.date
datetime.datetime(1970, 1, 1, 0, 0)
>>> d.weekday
0
# Negative dates, leap years:
>>> t = datetime.fromisoformat('1968-12-31T05:07:11.131719')
>>> d = detime(t); d
-0002-10-38 02:13:32.32838
>>> d.weekday
4
# Leap years 10th month is 38-days long:
>>> d.month_lengths
[36, 37, 36, 37, 36, 37, 36, 37, 36, 38]
$ dtime
00051-08-11 [3] @04:74:42 # Meaning: it was a [3]rd day of the week.
$ dtime -show
[2021-02-26 =] 00051-02-21 00:33:19.38145 [= 00:47:47]
(ctrl+c to stop)
About
In childhood, I tried to simplify computation of time for myself, so I invented a decimal system for counting time.
Later I discovered, that others did so as well. The relationships below follow the ratios, that I used in my original implementation.
Axioms
- Relationships follow:
1 year = 10 months
1 week = 10 days
1 day = 10 hours
1 hour = 100 minutes
1 minute = 100 seconds
- Starting point follows:
Years start at 1970 Jan 1, midnight.
The 1970 Jan 1 is first weekday, denoted by “0”
Corollaries
- => 1 second is:
0.864 standard SI seconds.
- => 1 month is:
36~37 days long, with 38 long last month on leap years.
3~4 weeks rolling by 10 days onto months.
- => 1 year is:
36.5 (or 36.6 on leap years) weeks.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.