Skip to main content

For more information, see the GitHub Repository.

AutomaPy

Supported Python versions Total downloads

The package contains a set of tools and algorithms for theoretical computer science, which could include automata theory as well as other topics.

Installation

pip install AutomaPy

Examples of How To Use (AutomaPy)

1. Create a program that implements a machine that accepts strings ending with '101'.

from AutomaPy import EndingWithOneZeroOne

dfa = EndingWithOneZeroOne()

print(dfa.check_string("101"))

2. Design a Program for creating machine that accepts three consecutive one.

from AutomaPy import ThreeConsecutiveOne

dfa = ThreeConsecutiveOne()

print(dfa.check_string("111")) # True
print(dfa.check_string("11100")) # True
print(dfa.check_string("1100")) # False

3. Write a program for tokenization of given input.

from AutomaPy import Tokenizer

tokenizer = Tokenizer()

print(tokenizer.tokenize("This is an example of tokenization."))

4. Design a program for accepting decimal number divisible by 2.

from AutomaPy import DecimalNumberDivisibleByTwo

dfa = DecimalNumberDivisibleByTwo()

print(dfa.check_string("111")) # True
print(dfa.check_string("11100")) # True
print(dfa.check_string("1001")) # False

5. Design a program for creating a machine which accepts string having equal no. of 1’s and 0’s.

from AutomaPy import EqualNumberOfOneZero

dfa = EqualNumberOfOneZero()

print(dfa.check_string("111000")) # True
print(dfa.check_string("111001")) # False
print(dfa.check_string("1100")) # True

6. Design a program for creating a machine which count number of 1's and 0's in a given string.

from AutomaPy import CountNumberOfOneZero

dfa = CountNumberOfOneZero()

print(dfa.check_string("111000")) # True
print(dfa.check_string("111001")) # False
print(dfa.check_string("1100")) # True

7. Design a program for Turing machine that’s accepts the even number of 1's.

from AutomaPy import TuringMachineEvenOnes

dfa = TuringMachineEvenOnes()

print(dfa.check_string("101111")) #False because 5 is odd (there is 5 1's)
print(dfa.check_string("101")) #True because 2 is even (there is 2 1's)

You can enter following command to see what functions this package have.

AutomaPy --help

Metadata

Release files for AutomaPy 1.3.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for AutomaPy 1.3.5
File Size Uploaded
AutomaPy-1.3.5.tar.gz 6.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for AutomaPy 1.3.5
File Interpreter ABI Platform
AutomaPy-1.3.5-py3-none-any.whl Python 3 none any Details

Total release size: 14.4 kB

Release files / AutomaPy-1.3.5.tar.gz

Download URL AutomaPy-1.3.5.tar.gz
Size 6.6 kB
Tags Source
SHA-256 checksum
How to use checksums
5b39768b9189b3ecb37a134b8b287a630951e32e2680a6370046bcb93a407730
BLAKE2b-256 checksum
How to use checksums
6d33c043df9a1d18d2bf85237c567847a6550d85e3e6b582b563868523b8f058
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.0

Release files / AutomaPy-1.3.5-py3-none-any.whl

Download URL AutomaPy-1.3.5-py3-none-any.whl
Size 7.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f7aa9fbd97b7da0ab76f25a425477598acf3dcfc8dd45b4c7396449d86a3df5b
BLAKE2b-256 checksum
How to use checksums
7e2c99d3bdce267ec541cabd879196ff21aabc8befee7a79eb1bc4bce26f88dc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.0

Release history Release notifications | RSS feed

This release

1.3.5 This release

2 release files

1.3.4

2 release files

1.3.3

2 release files

1.3.2

2 release files

1.3.1

2 release files

1.3.0

2 release files

1.2.9

2 release files

1.2.8

2 release files

1.2.7

2 release files

1.2.6

2 release files

1.2.5

2 release files

1.2.4

2 release files

1.2.3

2 release files

1.2.2

2 release files

1.2.1

2 release files

1.2.0

2 release files

1.1.9

2 release files

1.1.8

2 release files

1.1.7

2 release files

1.1.6

2 release files

1.1.5

2 release files

1.1.4

2 release files

1.1.3

2 release files

1.1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.9

2 release files

1.0.8

2 release files

1.0.7

2 release files

1.0.6

2 release files

1.0.5

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page