Skip to content
This repository was archived by the owner on Aug 28, 2024. It is now read-only.

Commit

Permalink
Cleaning up after the restructuring
Browse files Browse the repository at this point in the history
  • Loading branch information
daminton committed Dec 16, 2022
1 parent 56d1512 commit e031a2e
Show file tree
Hide file tree
Showing 20 changed files with 436 additions and 460 deletions.
1 change: 0 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ SET(FAST_MATH_FILES
${SRC}/modules/whm_classes.f90
${SRC}/modules/swiftest.f90
${SRC}/collision/collision_io.f90
${SRC}/collision/collision_placeholder.f90
${SRC}/collision/collision_setup.f90
${SRC}/collision/collision_util.f90
${SRC}/discard/discard.f90
Expand Down
147 changes: 93 additions & 54 deletions src/collision/collision_io.f90

Large diffs are not rendered by default.

53 changes: 0 additions & 53 deletions src/collision/collision_placeholder.f90

This file was deleted.

35 changes: 27 additions & 8 deletions src/collision/collision_setup.f90
Original file line number Diff line number Diff line change
Expand Up @@ -34,22 +34,41 @@ module subroutine collision_setup_fragments(self, n, param)
! Arguments
class(collision_fragments), intent(inout) :: self
integer(I4B), intent(in) :: n
class(swiftest_parameters), intent(in) :: param
class(swiftest_parameters), intent(in) :: param


call self%swiftest_pl%setup(n, param)
if (n < 0) return

call self%dealloc()

if (n == 0) return

! allocate(self%rotmag(n))
! allocate(self%v_r_mag(n))
! allocate(self%v_t_mag(n))
! allocate(self%v_n_mag(n))

call self%reset()
self%mtot = 0.0_DP
allocate(self%status(n))
allocate(self%rb(NDIM,n))
allocate(self%vb(NDIM,n))
allocate(self%mass(n))
allocate(self%rot(NDIM,n))
allocate(self%Ip(NDIM,n))

allocate(self%rc(NDIM,n))
allocate(self%vc(NDIM,n))
allocate(self%vmag(n))
allocate(self%rmag(n))
allocate(self%rotmag(n))
allocate(self%radius(n))
allocate(self%density(n))

self%status(:) = INACTIVE
self%rb(:,:) = 0.0_DP
self%vb(:,:) = 0.0_DP
self%rc(:,:) = 0.0_DP
self%vc(:,:) = 0.0_DP
self%vmag(:) = 0.0_DP
self%rmag(:) = 0.0_DP
self%rotmag(:) = 0.0_DP
self%radius(:) = 0.0_DP
self%density(:) = 0.0_DP

return
end subroutine collision_setup_fragments
Expand Down
Loading

0 comments on commit e031a2e

Please sign in to comment.