Skip to main content

A Python package implementing Terry's unique mathematical system

Project description

Terryology

A Python package implementing Terry's unique mathematical system, where multiplication is defined as a × b = a + b copies of a.

Installation

Using uv:

uv pip install terryology

Using pip:

pip install terryology

Basic Usage

from terryology import multiply, power

# Terry multiplication
result = multiply(2, 3)  # Returns 8 (2 + 3*2)

# Terry power
result = power(2, 2)    # Returns 6 (2 + 2*2)

Extending Terry's Mathematics

The package exposes the use_terryology decorator, allowing you to create your own Terry-style mathematical operations:

from terryology import use_terryology

# Create a new operation using Terry multiplication
@use_terryology
def square(a, b):
    # In Terry's system, squaring is the same as multiply(x, x)
    return a * a

# Create more complex expressions
@use_terryology
def complex_operation(a, b):
    # This will use Terry's multiplication and power rules
    return math.pow(a * b, 2)

# You can also use it for your own mathematical insights
@use_terryology
def my_terry_formula(a, b):
    return a * b + math.pow(a, b)

How the Decorator Works

The use_terryology decorator transforms mathematical operations within a function to follow Terry's system:

  • Regular multiplication (*) becomes a + (b * a)
  • math.pow(a, b) is redefined according to Terry's multiplication rules

Contributing

Contributions are welcome! If you have discovered new insights into Terry's mathematical system, please feel free to submit a pull request.

License

MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

terryology-0.1.2.tar.gz (2.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

terryology-0.1.2-py3-none-any.whl (3.9 kB view details)

Uploaded Python 3

File details

Details for the file terryology-0.1.2.tar.gz.

File metadata

  • Download URL: terryology-0.1.2.tar.gz
  • Upload date:
  • Size: 2.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.7

File hashes

Hashes for terryology-0.1.2.tar.gz
Algorithm Hash digest
SHA256 748942ebc438878ba291b10c1ee48dfdad074a318a491bf9bf5d9b7804c1259a
MD5 2504102020885e795c790368aaeced78
BLAKE2b-256 5ffaf4c18b06a5a70bdbe9f29ea1f0276be5f33c30995781764fe8d50f2da3cd

See more details on using hashes here.

File details

Details for the file terryology-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: terryology-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 3.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.7

File hashes

Hashes for terryology-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 195f840f97b271af79a631d25f64d76c533550bd15ba218dac372faacf0bed0b
MD5 e9ffd47a0206cb2c5255922958241d44
BLAKE2b-256 c7b56aa6c57a188c899280c889f3e97c4903813c670cf4024cfa18d8bf8dcebc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page