Representation of arbitrary number of 1d integer arrays with arbitrary sizes. This is needed for generic handling of dimension-specific tensor quantities (such as block index).
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
character(len=*), | private, | parameter | :: | moduleN | = | 'dbcsr_array_list_methods' |
get ith array
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list | |||
integer, | intent(in) | :: | i | |||
integer, | intent(out), | DIMENSION(:), ALLOCATABLE | :: | array |
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer, | public, | DIMENSION(:), ALLOCATABLE | :: | col_data | |||
integer, | public, | DIMENSION(:), ALLOCATABLE | :: | ptr |
number of arrays stored in list
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list |
Get an element for each array.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list | |||
integer, | intent(in), | DIMENSION(number_of_arrays(list)) | :: | indices |
element index for each array |
extract a subset of arrays
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list |
list of arrays |
||
integer, | intent(in), | DIMENSION(:) | :: | i_selected |
array numbers to retrieve |
sizes of arrays stored in list
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list |
sum of all elements for each array stored in list
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list |
check whether two array lists are equal
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list1 | |||
type(array_list), | intent(in) | :: | list2 |
check whether two arrays are equal
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer, | intent(in), | DIMENSION(:) | :: | arr1 | ||
integer, | intent(in), | DIMENSION(:) | :: | arr2 |
collects any number of arrays of different sizes into a single array (list%col_data), storing the indices that start a new array (list%ptr).
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(out) | :: | list |
list of arrays |
||
integer, | intent(in) | :: | ndata |
number of arrays |
||
integer, | intent(in), | optional, | DIMENSION(:) | :: | data_1 |
arrays 1 and 2 |
integer, | intent(in), | optional, | DIMENSION(:) | :: | data_2 |
arrays 1 and 2 |
integer, | intent(in), | optional, | DIMENSION(:) | :: | data_3 |
arrays 1 and 2 |
integer, | intent(in), | optional, | DIMENSION(:) | :: | data_4 |
arrays 1 and 2 |
destroy array list.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(inout) | :: | list |
Get all arrays contained in list
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list | |||
integer, | intent(out), | optional, | ALLOCATABLE, DIMENSION(:) | :: | data_1 |
arrays 1 and 2 |
integer, | intent(out), | optional, | ALLOCATABLE, DIMENSION(:) | :: | data_2 |
arrays 1 and 2 |
integer, | intent(out), | optional, | ALLOCATABLE, DIMENSION(:) | :: | data_3 |
arrays 1 and 2 |
integer, | intent(out), | optional, | ALLOCATABLE, DIMENSION(:) | :: | data_4 |
arrays 1 and 2 |
integer, | intent(in), | optional, | DIMENSION(:) | :: | i_selected |
array numbers to retrieve (if not present, all arrays are returned) |
get ith array
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list | |||
integer, | intent(in) | :: | i | |||
integer, | intent(in) | :: | array_size | |||
integer, | intent(out), | DIMENSION(array_size) | :: | array |
get ith array
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list | |||
integer, | intent(in) | :: | i | |||
integer, | intent(out), | DIMENSION(:), ALLOCATABLE | :: | array |
partial sums of array elements.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list_in | |||
type(array_list), | intent(out) | :: | list_out |
reorder array list.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(array_list), | intent(in) | :: | list_in | |||
type(array_list), | intent(out) | :: | list_out | |||
integer, | intent(in), | DIMENSION(number_of_arrays(list_in)) | :: | order |