PB3D [2.47]
Ideal linear high-n MHD stability in 3-D
Loading...
Searching...
No Matches
num_utilities::calc_det Interface Reference

Calculate determinant of a matrix. More...

Public Member Functions

integer function calc_det_0d (det_0d, a)
 private constant version
integer recursive function calc_det_3d (deta, a, n)
 private array version

Detailed Description

Calculate determinant of a matrix.

This matrix can be defined on a 3-D grid or constant. The storage convention described in eq_vars.eq_2_type is used.

In the former case the size of the matrix (last two indices) should be small, as the direct formula employing cofactors is used through a recursive formulation.

In the latter case, lapack routines are used.

See also
Adapted from http://dualm.wordpress.com/2012/01/06/computing-determinant-in-fortran/
Returns
ierr

Definition at line 63 of file num_utilities.f90.

Member Function/Subroutine Documentation

◆ calc_det_0d()

integer function num_utilities::calc_det::calc_det_0d ( real(dp), intent(inout) det_0d,
real(dp), dimension(:,:), intent(in) a )

private constant version

Parameters
[in,out]det_0doutput
[in]ainput

Definition at line 621 of file num_utilities.f90.

◆ calc_det_3d()

integer recursive function num_utilities::calc_det::calc_det_3d ( real(dp), dimension(:,:,:), intent(inout) deta,
real(dp), dimension(:,:,:,:), intent(in) a,
integer, intent(in) n )

private array version

Parameters
[in,out]detaoutput
[in]ainput
[in]nsize of matrix

Definition at line 542 of file num_utilities.f90.

Here is the call graph for this function:

The documentation for this interface was generated from the following file: