Returns the identity transformation matrix
function identity() result(r) !! Returns the identity transformation matrix real(kind=wp) :: r(4, 4) r(:, 1) = [1._wp, 0._wp, 0._wp, 0._wp] r(:, 2) = [0._wp, 1._wp, 0._wp, 0._wp] r(:, 3) = [0._wp, 0._wp, 1._wp, 0._wp] r(:, 4) = [0._wp, 0._wp, 0._wp, 1._wp] end function identity