Classical And Quantum Dynamics of the Multispherical Nanostructures

One of the most important problems is the realization of matrix and vectorial operations, when both matrixes and vectors may have complex structure. In this book the technique of work with a transfer matrix, and also various vectorial representations for field's component is widely used. As a rule we exploit one of the important features of C++ which is its adaptability to write the mathematical expressions in a natural form by means of the technique of the operators overloading. For instance, we can write the expression for three matrices A, B, C in the form A * B + C, if the arithmetical operators for matrices and vectors are defined by the correct way. Further, the program and classes for vectorial and matrix complex operations are presented (see Fig. 20.1). Various operations of summation, subtraction or multiplication of vectors or matrices do not represent any diffculties. More diffcult task is the matrix inversion. Figure 20.2 shows the output for such a program. We have inverted a complex matrix 3 3 order and then we have multiplied it by the initial matrix. In result the unitary matrix is obtained (see Fig. 20.2).
//---------------------- #include#pragma hdrstop #include "MatrTest4.h" ...