Marco Sulla writes:

 > Another big problem with tensors is the covariance and contravariance.
 > Usually in informatic you denote the covariance with the subscript
 > operator, that on paper is written as subscript. Contravariant index
 > on the contrary is a superscript.

You're talking about the notation that makes the Einstein summation
convention so pleasant?  I think summation will have to be an explict
operator or function, along a specified axis -- as numpy supports.

 > Not sure how a programming language can easily represent it.

Do you need to represent it?  It seems to me you could have a Tensor
class whose constructor takes a bool argument 'contravariant' (default
False), and then recommend that users adopt a naming convention to
distinguish covariant Tensors from contravariant Tensors.

Steve
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@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/QSLTWFNKN2K4WGKX44WXXQMP4CFOD6XY/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to