diff --git a/src/modules/init/moduleInput.f90 b/src/modules/init/moduleInput.f90 index 1b4ff21..bcf4dcc 100644 --- a/src/modules/init/moduleInput.f90 +++ b/src/modules/init/moduleInput.f90 @@ -493,6 +493,7 @@ MODULE moduleInput CALL config%get(object // '.numColl', collOutput, found) CALL config%get(object // '.EMField', emOutput, found) call config%get(object // '.boundariesParticle', boundaryParticleOutput, found) + call config%get(object // '.injects', injectOutput, found) CALL config%get(object // '.triggerCPUTime', triggerCPUTime, found) IF (.NOT. found) THEN diff --git a/src/modules/moduleInject.f90 b/src/modules/moduleInject.f90 index 003fd73..39de1ad 100644 --- a/src/modules/moduleInject.f90 +++ b/src/modules/moduleInject.f90 @@ -110,6 +110,7 @@ MODULE moduleInject allocate(injectQuasiNeutral:: self) self%update => updateQuasiNeutral + self%print => printQuasiNeutral case default call criticalError('No injection type ' // type // ' defined', 'initInject') @@ -304,8 +305,6 @@ MODULE moduleInject end if - print *, e, alpha - ! Adjust the weight of particles to match the new current self%weightPerEdge(e) = self%weightPerEdge(e) + 1.0d-1 * alpha @@ -476,6 +475,24 @@ MODULE moduleInject end subroutine writeInjects + ! Write information about quasiNeutral inject + subroutine printQuasiNeutral(self, fileID) + use moduleOutput, only: fmtColInt, fmtColReal + implicit none + + class(injectGeneric), intent(inout):: self + integer, intent(in):: fileID + integer:: e + + write(fileID, '(A)') self%name + write(fileID, '(A,",",A)') '"Edge id"', '"weight of particles"' + do e = 1, self%nEdges + write(fileID, '('//fmtColInt//','//fmtColReal//')') self%edges(e)%obj%n, self%weightPerEdge(e) + + end do + + end subroutine printQuasiNeutral + ! Inits for different velocity distribution functions SUBROUTINE initVelDistMaxwellian(velDist, temperature, m) IMPLICIT NONE diff --git a/src/modules/solver/moduleSolver.f90 b/src/modules/solver/moduleSolver.f90 index ed566e9..f951839 100644 --- a/src/modules/solver/moduleSolver.f90 +++ b/src/modules/solver/moduleSolver.f90 @@ -520,6 +520,7 @@ MODULE moduleSolver USE moduleSpecies USE moduleCompTime USE moduleProbe + use moduleInject, only: writeInjects USE moduleCaseParam, ONLY: timeStep IMPLICIT NONE @@ -539,6 +540,9 @@ MODULE moduleSolver ! Output of boundaries call boundariesParticle_write() + ! Output of inejcts + call writeInjects() + WRITE(*, "(5X,A21,I10,A1,I10)") "t/tFinal: ", timeStep, "/", tFinal WRITE(*, "(5X,A21,I10)") "Particles: ", nPartOld IF (timeStep == 0) THEN