buds  0.1
FORTRAN reference counted types
Modules | Data Types | Functions/Subroutines | Variables

Detailed Description

integer(selected_int_kind(9)) data type

Collaboration diagram for Integer (int):

Modules

module  bud_ism_csr
 

Data Types

type  ism_csr
 Sparse matrix type in the CSR format. More...
 
interface  new
 Create a new sparse matrix. More...
 
interface  new_ism_csr
 See interface #new More...
 
interface  mat_fold
 Fold a sparse matrix to form a smaller sparse matrix. More...
 
interface  mat_sort
 Sorts columns in the sparse pattern. More...
 
interface  mat_pointerp
 Retrieve a pointer to the row offsets/pointers. More...
 
interface  mat_offsetp
 See interface #mat_pointerp More...
 
interface  mat_columnp
 Retrieve a pointer to the column indices. More...
 
interface  nonzeros
 Return number of non-zero elements stored in the sparse matrix. More...
 
interface  mat_rows
 Number of rows in matrix. More...
 
interface  mat_cols
 Number of columns in matrix. More...
 
interface  attach
 Retrieve access to sparse pattern variables via pointers. More...
 
interface  print
 Print, to std-out, some basic information of the data-container. More...
 
interface  assignment(=)
 Assignment of bud to another bud. More...
 
interface  initialize
 Initialization of data container. More...
 
interface  is_initialized
 Query whether bud is associated with any data. More...
 
interface  initialized
 See interface is_initialized More...
 
interface  is_initd
 See interface is_initialized More...
 
interface  is_same
 Check whether two buds point to the same data (function) More...
 
interface  same
 See interface #is_same More...
 
interface  delete
 Deletes the bud by decreasing references to the underlying data. More...
 
interface  nullify
 Nullifies the current bud. More...
 
interface  references
 Query number of references to the bud. More...
 
interface  refs
 See interface #references More...
 

Functions/Subroutines

procedure, public delete => delete_
 See interface delete More...
 
procedure, public nullify => nullify_
 See interface nullify More...
 
procedure, public initialize => initialize_
 See interface initialize More...
 
procedure, public is_initialized => is_initialized_
 See interface is_initialized More...
 
procedure, public is_initd => is_initialized_
 See interface is_initialized More...
 
procedure, public initialized => is_initialized_
 See interface is_initialized More...
 
procedure, public is_same => is_same_
 See interface is_same More...
 
procedure, public same => is_same_
 See interface is_same More...
 
procedure, public references => references_
 See interface references More...
 
procedure, public refs => references_
 See interface references More...
 
procedure, public print => print_
 See interface print More...
 
procedure, private new_dim_ => new_dim_
 
procedure, private new_copy_ => new_copy_
 
generic, public new => new_dim_, new_copy_
 See interface new More...
 
procedure, public nonzeros => nonzeros_
 See interface nonzeros More...
 
procedure, public rows => mat_rows_
 See interface mat_rows More...
 
procedure, public mat_rows => mat_rows_
 See interface mat_rows More...
 
procedure, public cols => mat_cols_
 See interface mat_cols More...
 
procedure, public mat_cols => mat_cols_
 See interface mat_cols More...
 
procedure, public fold => fold_
 See interface mat_fold More...
 
procedure, public mat_fold => fold_
 See interface mat_fold More...
 
procedure, public sort => sort_
 See interface mat_sort More...
 
procedure, public mat_sort => sort_
 See interface mat_sort More...
 
procedure, public pointerp => get_row_offsetp_
 See interface mat_pointerp More...
 
procedure, public mat_pointerp => get_row_offsetp_
 See interface mat_pointerp More...
 
procedure, public offsetp => get_row_offsetp_
 See interface mat_pointerp More...
 
procedure, public mat_offsetp => get_row_offsetp_
 See interface mat_pointerp More...
 
procedure, public columnp => get_columnp_
 See interface mat_columnp More...
 
procedure, public mat_columnp => get_columnp_
 See interface mat_columnp More...
 
procedure, public attach => attach_
 See interface attach More...
 
subroutine new_dim_ (this, nr, nc, nz)
 
subroutine new_copy_ (this, nr, nc, nz, rptr, col)
 
subroutine new_dim_ (this, nr, nc, nz)
 
subroutine new_copy_ (this, nr, nc, nz, rptr, col)
 
subroutine fold_ (from, nr, nc, to, single)
 
subroutine sort_ (this, err, pvt)
 
integer(ii_) function, dimension(:), pointer, contiguous get_row_offsetp_ (this)
 
integer(ii_) function, dimension(:), pointer, contiguous get_row_offsetp_ (this)
 
integer(ii_) function, dimension(:), pointer, contiguous get_columnp_ (this)
 
elemental integer function nonzeros_ (this)
 
elemental integer function mat_rows_ (this)
 
elemental integer function mat_cols_ (this)
 
subroutine attach_ (this, D, nr, nc, nz, rptr, col )
 
subroutine print_ (this, info, indent)
 
subroutine assign_ (lhs, rhs)
 
subroutine initialize_ (this)
 
pure logical function is_initialized_ (this)
 
pure logical function is_initialized_ (this)
 
pure logical function is_initialized_ (this)
 
elemental logical function is_same_ (lhs, rhs)
 
elemental logical function is_same_ (lhs, rhs)
 
elemental subroutine delete_ (this)
 
elemental subroutine nullify_ (this)
 
elemental integer function references_ (this)
 
elemental integer function references_ (this)
 
subroutine initialize_ (this)
 
pure logical function is_initialized_ (this)
 
elemental logical function is_same_ (lhs, rhs)
 
elemental subroutine delete_ (this)
 
elemental subroutine nullify_ (this)
 
subroutine assign_ (lhs, rhs)
 
elemental integer function references_ (this)
 
elemental integer function nonzeros_ (this)
 
elemental integer function mat_rows_ (this)
 
elemental integer function mat_cols_ (this)
 
subroutine new_dim_ (this, nr, nc, nz)
 
subroutine new_copy_ (this, nr, nc, nz, rptr, col)
 
subroutine attach_ (this, D, nr, nc, nz, rptr, col )
 
subroutine fold_ (from, nr, nc, to, single)
 
subroutine fold_row_only (from, nr, to)
 
integer(ii_) function, dimension(:), pointer, contiguous get_columnp_ (this)
 
subroutine sort_ (this, err, pvt)
 

Variables

integer, parameter, private bud_id_len = 36
 Size of ID parameter for bud data-containers. More...
 
character(len=*), parameter, private bud_mod = "bud_" // "bud_iSM_CSR"
 Name of module. More...
 
character(len=*), parameter, private bud_type = "iSM_CSR"
 Name of bud in this module. More...
 
integer, parameter, public sm_none = 0
 Errors with a negative number refers to the -err element. More...
 
integer, parameter, public sm_entry_multiple = 1
 Signals two or more equivalent sparse elements. More...
 
integer, parameter, public sm_input = 1000
 The input argument that is wrong by err-SM_INPUT More...
 

Function/Subroutine Documentation

subroutine assign_ ( class(ism_csr), intent(inout)  lhs,
class(ism_csr), intent(in)  rhs 
)
private
Parameters
[in,out]lhscontains rhs after exit
[in]rhscopy the containing element bud
subroutine bud_ism_csr::assign_ ( class(ism_csr), intent(inout)  lhs,
class(ism_csr), intent(in)  rhs 
)
private
Parameters
[in,out]lhscontains rhs after exit
[in]rhscopy the containing element bud
procedure, public attach ( )

See interface attach

subroutine bud_ism_csr::attach_ ( class(ism_csr), intent(in)  this,
logical, intent(in), optional  D,
integer(ii_), intent(out), optional  nr,
integer(ii_), intent(out), optional  nc,
integer(ii_), intent(out), optional  nz,
integer(ii_), dimension(:), intent(out), optional, pointer, contiguous  rptr,
integer(ii_), dimension(:), intent(out), optional, pointer, contiguous  col 
)
private
Parameters
[in]thissparse matrix bud
[out]nroptional number of rows in SM
[out]ncoptional number of columns in SM
[out]nzoptional number of non-zero elements in SM
[out]rptroptional row pointer (rptr(2) is starting index of ir=2)
[out]coloptional column index
subroutine attach_ ( class(ism_csr), intent(in)  this,
logical, intent(in), optional  D,
integer(ii_), intent(out), optional  nr,
integer(ii_), intent(out), optional  nc,
integer(ii_), intent(out), optional  nz,
integer(ii_), dimension(:), intent(out), optional, pointer, contiguous  rptr,
integer(ii_), dimension(:), intent(out), optional, pointer, contiguous  col 
)
private
Parameters
[in]thissparse matrix bud
[out]nroptional number of rows in SM
[out]ncoptional number of columns in SM
[out]nzoptional number of non-zero elements in SM
[out]rptroptional row pointer (rptr(2) is starting index of ir=2)
[out]coloptional column index
procedure, public cols ( )

See interface mat_cols

procedure, public columnp ( )

See interface mat_columnp

procedure, public delete ( )

See interface delete

elemental subroutine delete_ ( class(ism_csr), intent(inout)  this)
private
Parameters
[in,out]thisreturned bud is un-initialized with no data associated
elemental subroutine bud_ism_csr::delete_ ( class(ism_csr), intent(inout)  this)
private
Parameters
[in,out]thisreturned bud is un-initialized with no data associated
procedure, public fold ( )

See interface mat_fold

subroutine fold_ ( class(ism_csr), intent(in)  from,
integer(ii_), intent(in)  nr,
integer(ii_), intent(in)  nc,
class(ism_csr), intent(inout)  to,
logical, intent(in), optional  single 
)
private
Parameters
[in]fromthe originating sparse pattern
[in]nrnew number of rows in the sparse pattern
[in]ncnew number of columns in the sparse pattern
[in,out]tothe resulting sparse pattern
[in]singleoptional=.false. if .true.: will compress equivalent entries to a single entry, no double entries will be found subsequently.
subroutine bud_ism_csr::fold_ ( class(ism_csr), intent(in)  from,
integer(ii_), intent(in)  nr,
integer(ii_), intent(in)  nc,
class(ism_csr), intent(inout)  to,
logical, intent(in), optional  single 
)
private
Parameters
[in]fromthe originating sparse pattern
[in]nrnew number of rows in the sparse pattern
[in]ncnew number of columns in the sparse pattern
[in,out]tothe resulting sparse pattern
[in]singleoptional=.false. if .true.: will compress equivalent entries to a single entry, no double entries will be found subsequently.

Here is the call graph for this function:

subroutine bud_ism_csr::fold_row_only ( class(ism_csr), intent(in)  from,
integer(ii_), intent(in)  nr,
class(ism_csr), intent(inout)  to 
)
private
Parameters
[in]fromthe originating sparse pattern
[in]nrnew number of rows in the sparse pattern
[in,out]tothe resulting sparse pattern

Here is the caller graph for this function:

integer(ii_) function, dimension(:), pointer, contiguous bud_ism_csr::get_columnp_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thissparse matrix
Returns
a pointer to the column indices for the sparse matrix (contiguous)
integer(ii_) function, dimension(:), pointer, contiguous get_columnp_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thissparse matrix
Returns
a pointer to the column indices for the sparse matrix (contiguous)
integer(ii_) function, dimension(:), pointer, contiguous get_row_offsetp_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thissparse matrix
Returns
a pointer to the row offsets for the sparse matrix (contiguous)
integer(ii_) function, dimension(:), pointer, contiguous get_row_offsetp_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thissparse matrix
Returns
a pointer to the row offsets for the sparse matrix (contiguous)
procedure, public initialize ( )

See interface initialize

subroutine initialize_ ( class(ism_csr), intent(inout)  this)
private
Parameters
[in,out]thisbud that is initialized
subroutine bud_ism_csr::initialize_ ( class(ism_csr), intent(inout)  this)
private
Parameters
[in,out]thisbud that is initialized
procedure, public initialized ( )

See interface is_initialized

procedure, public is_initd ( )

See interface is_initialized

procedure, public is_initialized ( )

See interface is_initialized

pure logical function is_initialized_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thischeck if this bud is initialized
Returns
.true. if it is associated, else .false.
pure logical function is_initialized_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thischeck if this bud is initialized
Returns
.true. if it is associated, else .false.
pure logical function is_initialized_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thischeck if this bud is initialized
Returns
.true. if it is associated, else .false.
pure logical function bud_ism_csr::is_initialized_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thischeck if this bud is initialized
Returns
.true. if it is associated, else .false.
procedure, public is_same ( )

See interface is_same

elemental logical function is_same_ ( class(ism_csr), intent(in)  lhs,
class(ism_csr), intent(in)  rhs 
)
private
Parameters
[in]lhsfirst bud
[in]rhssecond bud
Returns
.true. if lhs and rhs point to the same data
elemental logical function is_same_ ( class(ism_csr), intent(in)  lhs,
class(ism_csr), intent(in)  rhs 
)
private
Parameters
[in]lhsfirst bud
[in]rhssecond bud
Returns
.true. if lhs and rhs point to the same data
elemental logical function bud_ism_csr::is_same_ ( class(ism_csr), intent(in)  lhs,
class(ism_csr), intent(in)  rhs 
)
private
Parameters
[in]lhsfirst bud
[in]rhssecond bud
Returns
.true. if lhs and rhs point to the same data
procedure, public mat_cols ( )

See interface mat_cols

elemental integer function bud_ism_csr::mat_cols_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thisthe sparse matrix
Returns
number of columns in the matrix
elemental integer function mat_cols_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thisthe sparse matrix
Returns
number of columns in the matrix
procedure, public mat_columnp ( )

See interface mat_columnp

procedure, public mat_fold ( )

See interface mat_fold

procedure, public mat_offsetp ( )

See interface mat_pointerp

procedure, public mat_pointerp ( )

See interface mat_pointerp

procedure, public mat_rows ( )

See interface mat_rows

elemental integer function bud_ism_csr::mat_rows_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thisthe sparse matrix
Returns
number of rows in the matrix
elemental integer function mat_rows_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thisthe sparse matrix
Returns
number of rows in the matrix
procedure, public mat_sort ( )

See interface mat_sort

generic, public new ( )

See interface new

procedure, private new_copy_ ( )
private
subroutine bud_ism_csr::new_copy_ ( class(ism_csr), intent(inout)  this,
integer(ii_), intent(in)  nr,
integer(ii_), intent(in)  nc,
integer(ii_), intent(in)  nz,
integer(ii_), dimension(nr), intent(in)  rptr,
integer(ii_), dimension(nz), intent(in)  col 
)
private
Parameters
[in,out]thisthe new sparse matrix
[in]nrnumber of rows of the matrix
[in]ncnumber of columns of the matrix
[in]nznumber of non-zero elements of the matrix
[in]rptrrow pointers (at least size nr)
[in]colcolumn indices for the sparse elements
subroutine new_copy_ ( class(ism_csr), intent(inout)  this,
integer(ii_), intent(in)  nr,
integer(ii_), intent(in)  nc,
integer(ii_), intent(in)  nz,
integer(ii_), dimension(nr), intent(in)  rptr,
integer(ii_), dimension(nz), intent(in)  col 
)
private
Parameters
[in,out]thisthe new sparse matrix
[in]nrnumber of rows of the matrix
[in]ncnumber of columns of the matrix
[in]nznumber of non-zero elements of the matrix
[in]rptrrow pointers (at least size nr)
[in]colcolumn indices for the sparse elements
subroutine new_copy_ ( class(ism_csr), intent(inout)  this,
integer(ii_), intent(in)  nr,
integer(ii_), intent(in)  nc,
integer(ii_), intent(in)  nz,
integer(ii_), dimension(nr), intent(in)  rptr,
integer(ii_), dimension(nz), intent(in)  col 
)
private
Parameters
[in,out]thisthe new sparse matrix
[in]nrnumber of rows of the matrix
[in]ncnumber of columns of the matrix
[in]nznumber of non-zero elements of the matrix
[in]rptrrow pointers (at least size nr)
[in]colcolumn indices for the sparse elements
procedure, private new_dim_ ( )
private
subroutine new_dim_ ( class(ism_csr), intent(inout)  this,
integer(ii_), intent(in)  nr,
integer(ii_), intent(in)  nc,
integer(ii_), intent(in)  nz 
)
private
Parameters
[in,out]thisthe sparse matrix
[in]nrnumber of rows of the matrix
[in]ncnumber of columns of the matrix
[in]nznumber of non-zero elements the matrix
subroutine bud_ism_csr::new_dim_ ( class(ism_csr), intent(inout)  this,
integer(ii_), intent(in)  nr,
integer(ii_), intent(in)  nc,
integer(ii_), intent(in)  nz 
)
private
Parameters
[in,out]thisthe sparse matrix
[in]nrnumber of rows of the matrix
[in]ncnumber of columns of the matrix
[in]nznumber of non-zero elements the matrix
subroutine new_dim_ ( class(ism_csr), intent(inout)  this,
integer(ii_), intent(in)  nr,
integer(ii_), intent(in)  nc,
integer(ii_), intent(in)  nz 
)
private
Parameters
[in,out]thisthe sparse matrix
[in]nrnumber of rows of the matrix
[in]ncnumber of columns of the matrix
[in]nznumber of non-zero elements the matrix
procedure, public nonzeros ( )

See interface nonzeros

elemental integer function bud_ism_csr::nonzeros_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thisthe sparse matrix
Returns
number of non-zero elements in the matrix
elemental integer function nonzeros_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thisthe sparse matrix
Returns
number of non-zero elements in the matrix
procedure, public nullify ( )

See interface nullify

elemental subroutine nullify_ ( class(ism_csr), intent(inout)  this)
private
Parameters
[in,out]thisnullify references from this bud
elemental subroutine bud_ism_csr::nullify_ ( class(ism_csr), intent(inout)  this)
private
Parameters
[in,out]thisnullify references from this bud
procedure, public offsetp ( )

See interface mat_pointerp

procedure, public pointerp ( )

See interface mat_pointerp

procedure, public print ( )

See interface print

subroutine print_ ( class(ism_csr), intent(in)  this,
character(len=*), intent(in), optional  info,
integer, intent(in), optional  indent 
)
private
Parameters
[in]thissparse matrix
[in]infooptional="iSM_CSR" additional information printed
[in]indentoptional=1 possible indentation of printed statement
procedure, public references ( )

See interface references

elemental integer function bud_ism_csr::references_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thisreference counted bud
Returns
number of times this has been referenced
elemental integer function references_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thisreference counted bud
Returns
number of times this has been referenced
elemental integer function references_ ( class(ism_csr), intent(in)  this)
private
Parameters
[in]thisreference counted bud
Returns
number of times this has been referenced
procedure, public refs ( )

See interface references

procedure, public rows ( )

See interface mat_rows

procedure, public same ( )

See interface is_same

procedure, public sort ( )

See interface mat_sort

subroutine sort_ ( class(ism_csr), intent(inout)  this,
integer(ii_), intent(out)  err,
integer(ii_), dimension(:), intent(out), optional, target  pvt 
)
private
Parameters
[in]thissparse pattern to sort (in-place)
[out]errassociated error message of the sparsity pattern
[out]pvtoptional= if requested the pivoting array for the sorted sparsity pattern
subroutine bud_ism_csr::sort_ ( class(ism_csr), intent(inout)  this,
integer(ii_), intent(out)  err,
integer(ii_), dimension(:), intent(out), optional, target  pvt 
)
private
Parameters
[in]thissparse pattern to sort (in-place)
[out]errassociated error message of the sparsity pattern
[out]pvtoptional= if requested the pivoting array for the sorted sparsity pattern

Variable Documentation

integer, parameter, private bud_id_len = 36
private

Size of ID parameter for bud data-containers.

character(len=*), parameter, private bud_mod = "bud_" // "bud_iSM_CSR"
private

Name of module.

character(len=*), parameter, private bud_type = "iSM_CSR"
private

Name of bud in this module.

integer, parameter, public sm_entry_multiple = 1

Signals two or more equivalent sparse elements.

integer, parameter, public sm_input = 1000

The input argument that is wrong by err-SM_INPUT

This constant is an offset in the error number that refers to the input parameter err - SM_INPUT. I.e. if err = SM_INPUT + 2, the second argument is erroneous.

integer, parameter, public sm_none = 0

Errors with a negative number refers to the -err element.

This may mean that the entry is beyond the matrix size. Definition of no errors in the call