AngouriMath
Concat(AngouriMath.MathS.Matrices.Direction,AngouriMath.Entity.Matrix[])
Method (no overloads)
Summary
Concatenates two matrices by the given direction.
Parameter "dir"
Parameter "matrices"
Returns
Example
using System;
using static AngouriMath.MathS;
using static AngouriMath.Entity;
Matrix A = @"
[[1, 2, 3]]
";
Matrix B = @"
[[1, 2, 3],
[4, 5, 6]]";
Matrix C = @"
[[2, 4, 1],
[4, 1, 2],
[a, x, y]]
";
Console.WriteLine(
Matrices.Concat(Matrices.Direction.Vertical, A, B, C)
.ToString(multilineFormat: true)
);
Console.WriteLine("----------------------------");
Matrix D = "[1, 2, 3]";
Matrix E = "[4, 5, 6]";
Console.WriteLine(D.ToString(multilineFormat: true));
Console.WriteLine(E.ToString(multilineFormat: true));
Console.WriteLine(
Matrices.Concat(Matrices.Direction.Horizontal, D, E)
.ToString(multilineFormat: true)
);
Prints
Matrix[6 x 3]
1 2 3
1 2 3
4 5 6
2 4 1
4 1 2
a x y
----------------------------
Matrix[3 x 1]
1
2
3
Matrix[3 x 1]
4
5
6
Matrix[3 x 2]
1 4
2 5
3 6
Angouri © 2019-2023 · Project's repo · Site's repo · Octicons · Transparency · 1534 pages online