set_dof Subroutine

private subroutine set_dof(self, dof)

Set the degrees of freedom (2 or 3) of positions and optionals; clears the trajectory.

Type Bound

Trajectory

Arguments

Type IntentOptional Attributes Name
class(Trajectory), intent(inout) :: self
integer, intent(in) :: dof

degrees of freedom (2 or 3)


Calls

proc~~set_dof~~CallsGraph proc~set_dof Trajectory%set_dof proc~clear Trajectory%clear proc~set_dof->proc~clear

Source Code

    subroutine set_dof(self, dof)
        class(Trajectory), intent(inout) :: self
        integer, intent(in) :: dof                          !! degrees of freedom (2 or 3)
        self%dof_ = max(2, min(3, dof))
        call self%clear()
    end subroutine set_dof