is_sum_even Function

public function is_sum_even(x, y, z) result(sum_even)

checks if the sum of 3 integers is an even integer

Arguments

Type IntentOptional Attributes Name
integer(kind=int32), intent(in) :: x

variables to check if the sum is even

integer(kind=int32), intent(in) :: y

variables to check if the sum is even

integer(kind=int32), intent(in) :: z

variables to check if the sum is even

Return Value logical

(out) result: true/false


Called by

proc~~is_sum_even~~CalledByGraph proc~is_sum_even is_sum_even proc~zero_projections_3j_condition zero_projections_3j_condition proc~zero_projections_3j_condition->proc~is_sum_even proc~check_nonzero_pes_matrix_elements check_nonzero_pes_matrix_elements proc~check_nonzero_pes_matrix_elements->proc~zero_projections_3j_condition proc~process_single_matrix_element process_single_matrix_element proc~process_single_matrix_element->proc~zero_projections_3j_condition proc~initialize_pes_matrix initialize_pes_matrix proc~initialize_pes_matrix->proc~check_nonzero_pes_matrix_elements proc~prepare_pes_matrix_elements prepare_pes_matrix_elements proc~initialize_pes_matrix->proc~prepare_pes_matrix_elements proc~prepare_pes_matrix_elements->proc~process_single_matrix_element program~scattering SCATTERING program~scattering->proc~initialize_pes_matrix

Contents

Source Code


Source Code

      function is_sum_even(x, y, z) result(sum_even)
         !! checks if the sum of 3 integers is an even integer
         !---------------------------------------------------------------------!
         integer(int32), intent(in) :: x, y, z
            !! variables to check if the sum is even
         logical :: sum_even
            !! (out) result: true/false
         !---------------------------------------------------------------------!
         sum_even = (modulo(x + y + z, 2) == 0)
         !---------------------------------------------------------------------!
      end function is_sum_even