This is a lot to add to Python itself to poorly reproduce well-tested functionally in a very popular library. There are many Python distributions that come with that extra battery included, just not the one from the PSF.

On Thu, Aug 13, 2020, 6:20 PM Stefano Borini <stefano.borini@gmail.com> wrote:
Excuse me if I am out of the loop and this is already available, but I
haven't seen it and googling is not exactly easy as numpy introduces
considerable noise.

With the introduction of the statistics module, the standard library
provides basic statistical functions that can be useful in many
scenarios, including teaching.
The math module has plenty of mathematical functions that are very
interesting, but no Matrix object. When newcomers want to have a
matrix object, they end up
implementing a list of lists (as suggested by the documentation, e.g.
see https://docs.python.org/3/tutorial/datastructures.html?highlight=matrix#nested-list-comprehensions
and https://docs.python.org/3/faq/programming.html?highlight=matrix#how-do-i-create-a-multidimensional-list)
but it's ambiguous
(is each entry a row or a column?), and does not enforce types or
equal length of each entry.

Generally, when a Matrix object is needed, numpy is the point of
reference, but numpy requires understanding pip, installing modules,
maybe creating a virtual environment and finally understanding numpy.

I would propose a simple, straightforward, low performance object to
perform trivial operations such as matrix multiplication,
transposition, addition, linear problem solving, determinant. The
absolute bare minimum for an introductory linear algebra course.
The syntax should mimic numpy to train newcomers to the numpy syntax
whenever possible, and of course should implement the @ operator.

There is already a similar entity in the "array" module, which is a
simple version of a numpy array, except that is only one-dimensional.

--
Kind regards,

Stefano Borini
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-leave@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at https://mail.python.org/archives/list/python-ideas@python.org/message/R334EPWCXRM3RXFEUXVN4HYG6WQKKCGT/
Code of Conduct: http://python.org/psf/codeofconduct/