Project Description
Release History
## Release History

Download Files
## Download Files

Simple module to work with matrices. Division between matrices isn't supported yet.

Examples:

>>> from easymatrix import Matrix

# Create a 2x3 matrix.

>>> a = Matrix([

... [1, 5, 0],

... [2, 0, 3]

... ])

# Output is automatically created to be human-readable.

>>> a

1 5 0

2 0 3

# Define another to operate with.

>>> b = Matrix([

... [-3, -5, 7],

... [0, 9, 1]

... ])

# Arithmetic operations.

>>> c = a + b

>>> c

-2 0 7

2 9 4

>>> d = a - b

>>> d

4 10 -7

2 -9 2

# Multiplication: matrix * matrix.

>>> e = d * c

Traceback (most recent call last):

ValueError: Expected ?x3 and 2x? matrices.

>>> f = Matrix([

... [1, 0],

... [3, -2],

... [0, 5]

... ])

>>> g = d * f

>>> print(g)

34 -55

-25 28

# Matrix * number.

>>> g*2

68 -110

-50 56

# Power.

>>> g**2

2531 -3410

-1550 2159

# Division: matrix / number.

>>> g/10.

3.4 -5.5

-2.5 2.8

Examples:

>>> from easymatrix import Matrix

# Create a 2x3 matrix.

>>> a = Matrix([

... [1, 5, 0],

... [2, 0, 3]

... ])

# Output is automatically created to be human-readable.

>>> a

1 5 0

2 0 3

# Define another to operate with.

>>> b = Matrix([

... [-3, -5, 7],

... [0, 9, 1]

... ])

# Arithmetic operations.

>>> c = a + b

>>> c

-2 0 7

2 9 4

>>> d = a - b

>>> d

4 10 -7

2 -9 2

# Multiplication: matrix * matrix.

>>> e = d * c

Traceback (most recent call last):

ValueError: Expected ?x3 and 2x? matrices.

>>> f = Matrix([

... [1, 0],

... [3, -2],

... [0, 5]

... ])

>>> g = d * f

>>> print(g)

34 -55

-25 28

# Matrix * number.

>>> g*2

68 -110

-50 56

# Power.

>>> g**2

2531 -3410

-1550 2159

# Division: matrix / number.

>>> g/10.

3.4 -5.5

-2.5 2.8

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help | Version | File Type | Upload Date |
---|---|---|---|

easymatrix-1.0.0a1-py2.py3-none-any.whl (4.0 kB) Copy SHA256 Checksum SHA256 | any | Wheel | Nov 3, 2014 |

easymatrix-1.0.0a1.zip (4.8 kB) Copy SHA256 Checksum SHA256 | – | Source | Nov 2, 2014 |