init_subsystem Subroutine

private subroutine init_subsystem(this, id, factor, atoms)

Arguments

TypeIntentOptionalAttributesName
class(subsystem_type), intent(inout) :: this
integer, intent(in) :: id
real(kind=dp), intent(in) :: factor
type(atom_type), intent(in), dimension(:):: atoms

Contents

Source Code


Source Code

subroutine init_subsystem(this, id, factor, atoms)

    class(subsystem_type), intent(inout) :: this
    integer, intent(in) :: id
    real(dp), intent(in) :: factor
    type(atom_type), dimension(:), intent(in) :: atoms

    this%id = id
    this%factor = factor
    this%num_atoms = size(atoms)
    allocate(this%atoms(this%num_atoms))
    this%atoms = atoms
    this%num_fragments = -1

end subroutine init_subsystem