Discussion Overview
The discussion revolves around the use of the MATMUL command in Fortran for multiplying a rank one complex array with a 3x3 complex matrix. Participants explore issues related to array shape conformity and the correct definition of complex arrays in Fortran.
Discussion Character
- Technical explanation
- Debate/contested
Main Points Raised
- One participant describes their attempt to use MATMUL with a rank one complex array and a 3x3 complex matrix, expressing confusion over a compilation error related to array shape conformity.
- Another participant asserts that a rank one array cannot be multiplied by a rank two array, suggesting that for MATMUL to work, the rank of array A should be 3x1.
- A participant references a book, NUMERICAL RECIPES IN FORTRAN 90, which states that one-dimensional arrays can be used as either row or column vectors, but not both in the multiplication.
- There is a suggestion that the issue may depend on the compiler being used, with a query about whether a 3x1 matrix was tried.
- A participant mentions that while they successfully used a 3x1 matrix, they are unsure how to calculate the dot product of array A in that format.
- Another participant identifies a specific issue in their code related to the definition of the variable "c" and seeks suggestions for proper definition.
- A later reply indicates that one participant believes they have solved the problem, but no details are provided.
Areas of Agreement / Disagreement
Participants express differing views on the correct approach to defining and using arrays in Fortran, particularly regarding the rank of the arrays involved in the MATMUL operation. The discussion remains unresolved as participants have not reached a consensus on the best solution.
Contextual Notes
There are limitations regarding the assumptions made about array ranks and the specific requirements of the MATMUL command in Fortran, which may vary by compiler. The discussion includes unresolved mathematical steps related to defining the output variable correctly.