split_tensor_index Function

public pure function split_tensor_index(ind_in, dims) result(ind_out)

transform flat index to nd index

Arguments

Type IntentOptional Attributes Name
integer(kind=int_8), intent(in) :: ind_in

flat index

integer, intent(in), DIMENSION(:) :: dims

nd dimensions

Return Value integer, DIMENSION(SIZE(dims))

nd index