Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

These are all accessible using the "dot" object-oriented notation. See, for example, this documentation, from which this example stems.

sage: v = vector([1,2,3]); w = vector([0,5,-9])
sage: v.cross_product(v)
(0, 0, 0)
sage: u = v.cross_product(w); u
(-33, 9, 5)
sage: u.dot_product(v)
0
sage: u.dot_product(w)
0