Probes were not working properly
Issue in the output of probes and in the detection of particles inside the velocity grid.
This commit is contained in:
parent
e7ae4e13ff
commit
2ee6c1764e
2 changed files with 7 additions and 4 deletions
|
|
@ -95,7 +95,7 @@ MODULE moduleProbe
|
|||
|
||||
!Maximum radius
|
||||
!TODO: Make this an input parameter
|
||||
self%maxR = 1.D-1/L_ref
|
||||
self%maxR = 1.D0
|
||||
|
||||
!Init the probe lock
|
||||
CALL OMP_INIT_LOCK(self%lock)
|
||||
|
|
@ -110,6 +110,8 @@ MODULE moduleProbe
|
|||
INTEGER, INTENT(out):: i, j, k
|
||||
LOGICAL, INTENT(out):: inside
|
||||
|
||||
inside = .TRUE.
|
||||
|
||||
i = FLOOR((vp(1) - self%vi(1))/self%vrange(1)*(REAL(self%nv(1) - 1)) + 1.D0)
|
||||
IF (i >= self%nv(1) .OR. i < 1) inside = .FALSE.
|
||||
j = FLOOR((vp(2) - self%vj(1))/self%vrange(2)*(REAL(self%nv(2) - 1)) + 1.D0)
|
||||
|
|
@ -198,7 +200,7 @@ MODULE moduleProbe
|
|||
|
||||
WRITE(tstring, iterationFormat) t
|
||||
WRITE(pstring, "(I3.3)") self%id
|
||||
fileName='OUTPUT_' // tstring// '_f_' // pstring // '.dat'
|
||||
fileName='Probe_' // tstring// '_f_' // pstring // '.dat'
|
||||
WRITE(*, "(6X,A15,A)") "Creating file: ", fileName
|
||||
OPEN (10, file = path // folder // '/' // fileName)
|
||||
WRITE(10, "(A1, 1X, A)") "# ", self%species%name
|
||||
|
|
@ -268,7 +270,7 @@ MODULE moduleProbe
|
|||
|
||||
DO i = 1, nProbes
|
||||
probe(i)%f = 0.D0
|
||||
probe(i)%update = MOD(t, probe(i)%every) == 0 .OR. t == tFinal
|
||||
probe(i)%update = MOD(t, probe(i)%every) == 0 .OR. t == tFinal .OR. t == tInitial
|
||||
|
||||
END DO
|
||||
|
||||
|
|
|
|||
|
|
@ -523,6 +523,8 @@ MODULE moduleSolver
|
|||
|
||||
END IF
|
||||
|
||||
CALL outputProbes(t)
|
||||
|
||||
counterOutput = counterOutput + 1
|
||||
IF (counterOutput >= triggerOutput .OR. &
|
||||
t == tFinal .OR. t == tInitial) THEN
|
||||
|
|
@ -530,7 +532,6 @@ MODULE moduleSolver
|
|||
!Resets output counter
|
||||
counterOutput=0
|
||||
|
||||
CALL outputProbes(t)
|
||||
CALL mesh%printOutput(t)
|
||||
IF (ASSOCIATED(meshForMCC)) CALL meshForMCC%printColl(t)
|
||||
CALL mesh%printEM(t)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue