mirror of
https://github.com/sfilippone/psblas3.git
synced 2026-10-07 15:14:57 +00:00
psblas3:
base/modules/psb_d_mat_mod.f90 base/modules/psb_serial_mod.f90 Added minreal in psb_Serial_mod for use in aggrmat.
This commit is contained in:
@@ -44,7 +44,7 @@
|
||||
! the functionalities to have the encapsulated class change its
|
||||
! type dynamically, and to extract/input an inner object.
|
||||
!
|
||||
! A sparse matric has a state corresponding to its progression
|
||||
! A sparse matrix has a state corresponding to its progression
|
||||
! through the application life.
|
||||
! In particular, computational methods can only be invoked when
|
||||
! the matrix is in the ASSEMBLED state, whereas the other states are
|
||||
|
||||
@@ -44,6 +44,10 @@ module psb_serial_mod
|
||||
module procedure psb_snrm1, psb_dnrm1, psb_cnrm1, psb_znrm1
|
||||
end interface psb_nrm1
|
||||
|
||||
interface psb_minreal
|
||||
module procedure psb_sminreal, psb_dminreal, psb_cminreal, psb_zminreal
|
||||
end interface psb_minreal
|
||||
|
||||
interface psb_amax
|
||||
function psb_samax_s(n, x) result(val)
|
||||
import :: psb_ipk_, psb_spk_, psb_dpk_
|
||||
@@ -561,6 +565,30 @@ contains
|
||||
res = abs( real( x ) ) + abs( aimag( x ) )
|
||||
end function psb_znrm1
|
||||
|
||||
elemental function psb_sminreal(x) result(res)
|
||||
real(psb_spk_), intent(in) :: x
|
||||
real(psb_spk_) :: res
|
||||
res = ( x )
|
||||
end function psb_sminreal
|
||||
|
||||
elemental function psb_dminreal(x) result(res)
|
||||
real(psb_dpk_), intent(in) :: x
|
||||
real(psb_dpk_) :: res
|
||||
res = ( x )
|
||||
end function psb_dminreal
|
||||
|
||||
elemental function psb_cminreal(x) result(res)
|
||||
complex(psb_spk_), intent(in) :: x
|
||||
real(psb_spk_) :: res
|
||||
res = min( real( x ) , aimag( x ) )
|
||||
end function psb_cminreal
|
||||
|
||||
elemental function psb_zminreal(x) result(res)
|
||||
complex(psb_dpk_), intent(in) :: x
|
||||
real(psb_dpk_) :: res
|
||||
res = min( real( x ) , aimag( x ) )
|
||||
end function psb_zminreal
|
||||
|
||||
|
||||
subroutine crot( n, cx, incx, cy, incy, c, s )
|
||||
!
|
||||
|
||||
Reference in New Issue
Block a user