From 5000e35891afbbeb11884e1a869d2324c7c960e5 Mon Sep 17 00:00:00 2001 From: Mike Gerwitz Date: Mon, 4 Dec 2017 14:03:54 -0500 Subject: [PATCH] vector/arithmetic: Add _{v,m}product_ Products of vectors and matrices respectively. It's surprising that this was unneeded until now based on the requirements of the projects we have done thusfar---dot products and other features have been sufficient. * vector/arithmetic.xml (_vproduct_, _mproduct_): New templates. (_vproduct, _mproduct): New functions. --- core/vector/arithmetic.xml | 171 +++++++++++++++++++++++++++++-------- 1 file changed, 136 insertions(+), 35 deletions(-) diff --git a/core/vector/arithmetic.xml b/core/vector/arithmetic.xml index bca17266..c687eb3b 100644 --- a/core/vector/arithmetic.xml +++ b/core/vector/arithmetic.xml @@ -26,50 +26,151 @@ + - - - + + + \ref{_vproduct_} produces the product of two vectors: + $V_k = A_k B_k$. + + + + + \ref{_vproduct} is its helper function for recursion. + + + + + + + + + + + + + + + + + + + + + + + + +
+ \ref{_mproduct_} produces the product of two matrices: + $M_{ij} = A_{ij} B_{ij}$. + + + + + \ref{_mproduct} is its helper function for recursion. + \ref{_vproduct_} is used to reduce the problem to the product of + and array of~vectors. + + + + + + + + + + + + + + + + + + + + + + + + + + +