Trying partial reflection
This commit is contained in:
parent
4747673d0a
commit
159f2e7620
6 changed files with 91 additions and 60 deletions
|
|
@ -387,9 +387,11 @@ MODULE moduleInject
|
|||
|
||||
partInj(n)%v = 0.D0
|
||||
|
||||
partInj(n)%v = self%vMod*direction + (/ self%v(1)%obj%randomVel(), &
|
||||
self%v(2)%obj%randomVel(), &
|
||||
self%v(3)%obj%randomVel() /)
|
||||
do while(dot_product(partInj(n)%v, direction) <= 0.d0)
|
||||
partInj(n)%v = self%vMod*direction + (/ self%v(1)%obj%randomVel(), &
|
||||
self%v(2)%obj%randomVel(), &
|
||||
self%v(3)%obj%randomVel() /)
|
||||
end do
|
||||
|
||||
!If injecting a no-drift distribution and velocity is negative, reflect
|
||||
if ((self%vMod == 0.D0) .and. &
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue