- #1
JP12321
- 1
- 0
- TL;DR Summary
- I need help making a matrix, with elements that contain other matrices! If you have even a basic knowledge of MATLAB then I have provided the code for this, to make it a bit more descriptive.
Thanks.
Hi,
I haven't made a code for it yet, however I will be making a Gauss-Seidel algroithm in Fortran 90, for solving very large matrices (actually to initiate the multi-gird method but that's irrelevant for this). As part of this, I wish to insert matrices into other matrices.
in MATLAB this is very simple, for example:
A=[1,2;3,4]
B=[A,A;A,A]
Outputs:
B =
1 2 1 2
3 4 3 4
1 2 1 2
3 4 3 4
However I have been having difficulties achieving the same with Fortran.
Please ignore the context - I don't require help with the GS/MG methods, I just need help embedding matrices (for other topics too), if at all possible!
Thanks in advance,
JP.
I haven't made a code for it yet, however I will be making a Gauss-Seidel algroithm in Fortran 90, for solving very large matrices (actually to initiate the multi-gird method but that's irrelevant for this). As part of this, I wish to insert matrices into other matrices.
in MATLAB this is very simple, for example:
A=[1,2;3,4]
B=[A,A;A,A]
Outputs:
B =
1 2 1 2
3 4 3 4
1 2 1 2
3 4 3 4
However I have been having difficulties achieving the same with Fortran.
Please ignore the context - I don't require help with the GS/MG methods, I just need help embedding matrices (for other topics too), if at all possible!
Thanks in advance,
JP.