1,574 bytes added
, 19:10, 8 June 2017
<div style="font-size:30px">'''MATRIXADD (a,b,afactor,bfactor)'''</div><br/>
*<math> a </math> and <math>b</math> are any two matrices.
==Description==
*This function calculates the addition of the two matrices.
*In <math>MATRIXADD (a,b,afactor,bfactor)</math>,<math>a</math> and <math>b</math> are two matrices.
*<math>afactor</math> is the multiplying value with <math>a</math> and <math>bfactor</math> is the multiplying value with <math>b</math>.
*Matrix addition is the basic operation of adding two matrices with the corresponding entries.
*Two matrices must have an equal number of rows and columns.
*The sum of matrices A and B is denoted by <math>A+B=
\begin{bmatrix}
a_{11} & a_{12}&\cdots & a_{1n} \\
a_{21}& a_{22}& \cdots & a_{2n} \\
\vdots & \ddots & \vdots \\
a_{m1} & a_{m2}& \cdots & a_{mn}
\end{bmatrix} +\begin{bmatrix}
b_{11} & b_{12}&\cdots & b_{1n} \\
b_{21}& b_{22}& \cdots & b_{2n} \\
\vdots & \ddots & \vdots \\
b_{m1} & b_{m2}& \cdots & b_{mn}
\end{bmatrix} = \begin{bmatrix}
a_{11}+b_{11} & a_{12}+b_{12}&\cdots & a_{1n}+b_{1n} \\
a_{21}+b_{21}& a_{22}+b_{22}& \cdots & a_{2n}+b_{2n} \\
\vdots & \ddots & \vdots \\
a_{m1}+b_{m1} & a_{m2}+b_{m2}& \cdots & a_{mn}+b_{mn}
\end{bmatrix}
*Here <matrix>afactor</math> constant value is multiplied with each values in matrix A and <math>bfactor</math> constant value is multiplied with each values in matrix B.
*Then it is doing the matrix addition with all the corresponding entries.
*If the factor values are not given then it is doing usual matrix addition with the factor values as 1.