to_reordered_index Module Subroutine

module subroutine to_reordered_index(self, index_original, index_reordered)

Arguments

Type IntentOptional Attributes Name
class(type_reordering), intent(in) :: self
integer(kind=int32), intent(in) :: index_original
integer(kind=int32), intent(inout) :: index_reordered

Called by

proc~~to_reordered_index~~CalledByGraph proc~to_reordered_index to_reordered_index interface~to_reordered_index type_reordering%to_reordered_index interface~to_reordered_index->proc~to_reordered_index none~to_reordered type_reordering%to_reordered none~to_reordered->interface~to_reordered_index proc~apply_reordering type_domain%apply_reordering proc~apply_reordering->none~to_reordered proc~initialize_type_bc_thermal_adiabatic initialize_type_bc_thermal_adiabatic proc~initialize_type_bc_thermal_adiabatic->none~to_reordered proc~initialize_type_bc_thermal_dirichlet initialize_type_bc_thermal_dirichlet proc~initialize_type_bc_thermal_dirichlet->none~to_reordered proc~initialize_type_crs type_crs%initialize_type_crs proc~initialize_type_crs->none~to_reordered interface~initialize_type_bc_thermal_adiabatic type_bc_thermal_adiabatic%initialize_type_bc_thermal_adiabatic interface~initialize_type_bc_thermal_adiabatic->proc~initialize_type_bc_thermal_adiabatic interface~initialize_type_bc_thermal_dirichlet type_bc_thermal_dirichlet%initialize_type_bc_thermal_dirichlet interface~initialize_type_bc_thermal_dirichlet->proc~initialize_type_bc_thermal_dirichlet proc~construct_type_thermal_3phase_2d construct_type_thermal_3phase_2d proc~construct_type_thermal_3phase_2d->proc~initialize_type_crs proc~initialize_type_domain type_domain%initialize_type_domain proc~initialize_type_domain->proc~apply_reordering interface~construct_type_thermal_3phase_2d construct_type_thermal_3phase_2d interface~construct_type_thermal_3phase_2d->proc~construct_type_thermal_3phase_2d interface~type_thermal_3phase_2d type_thermal_3phase_2d interface~type_thermal_3phase_2d->interface~construct_type_thermal_3phase_2d

Source Code

    module subroutine to_reordered_index(self, index_original, index_reordered)
        implicit none
        class(type_reordering), intent(in) :: self
        integer(int32), intent(in) :: index_original
        integer(int32), intent(inout) :: index_reordered

        if (self%algorithm_name == "none") then
            index_reordered = index_original
            return
        end if

        if (.not. self%is_reordered_iperm) error stop "'iperm' not ready. Call 'invert' first."

        index_reordered = self%iperm(index_original)

    end subroutine to_reordered_index