Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/dev' into feature/alberto_updates
Browse files Browse the repository at this point in the history
  • Loading branch information
Alberto-o committed Nov 12, 2024
2 parents 4bd3439 + 918b185 commit 4c82aba
Show file tree
Hide file tree
Showing 31 changed files with 952 additions and 496 deletions.
9 changes: 2 additions & 7 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ if (SEMBA_FDTD_MAIN_LIB)
"src_main_pub/timestepping.F90"
"src_main_pub/observation.F90"
"src_main_pub/vtk.F90"
"src_main_pub/xdmf.F90"
"src_main_pub/xdmf_h5.F90"
"src_wires_pub/wires.F90"
"src_wires_pub/wires_mtln.F90"
)
Expand All @@ -140,13 +142,6 @@ add_definitions(
-DCompileWithInt2
-DCompileWithReal4
-DCompileWithOpenMP
-DCompileWithAnisotropic
-DCompileWithEDispersives
-DCompileWithNF2FF
-DCompileWithNodalSources
-DCompileWithDMMA
-DCompileWithSGBC
-DCompileWithWires
)


4 changes: 2 additions & 2 deletions doc/smbjson.md
Original file line number Diff line number Diff line change
Expand Up @@ -653,15 +653,15 @@ If not `magnitudeFile` is specified and only one `source` is defined, the `magni

Probes of type `movie` record a vector field in a volume region indicated by `elementIds`. `[field]` can be `electric`, `magnetic`, or `currentDensity`; defaults to `electric`.
`currentDensity` will store only the surface density currents on `pec` or lossy surfaces.
The stored values can be selected using `[components]`, which stores an array of the following labels `x`, `y`, `z`, or `magnitude`; if no components are specified, defaults to `magnitude`.
The stored values can be selected using the `[component]` entry, which stores one of the following labels `x`, `y`, `z`, or `magnitude`; if no component is specified, defaults to `magnitude`.

An example follows:
```json
{
"name": "electric_field_movie",
"type": "movie",
"field": "electric",
"components": ["x"],
"component": "x",
"elementIds": [4]
}
```
Expand Down
2 changes: 1 addition & 1 deletion src_json_parser/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ add_library (jsonfortran
)

add_library(smbjson
"labels_mod.F90"
"smbjson_labels.F90"
"cells.F90"
"smbjson.F90"
"idchildtable.F90"
Expand Down
2 changes: 1 addition & 1 deletion src_json_parser/idchildtable.F90
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ module idchildtable_mod

#ifdef CompileWithSMBJSON
use json_module
use smbjson_labels_mod, only: J_ID
use fhash, only: fhash_tbl_t, key=>fhash_key
use labels_mod
use parser_tools_mod, only: json_value_ptr

type :: IdChildTable_t
Expand Down
1 change: 0 additions & 1 deletion src_json_parser/parser_tools.F90
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
module parser_tools_mod

#ifdef CompileWithSMBJSON
use labels_mod
use mesh_mod
use cells_mod
use json_module
Expand Down
18 changes: 6 additions & 12 deletions src_json_parser/smbjson.F90
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ module smbjson
use NFDETypes

use NFDETypes_extension
use labels_mod
use smbjson_labels_mod
use mesh_mod
use parser_tools_mod
use idchildtable_mod
Expand Down Expand Up @@ -985,19 +985,13 @@ function readVolProbe(p) result(res)
cs = cellIntervalsToCoords(cRs(1)%intervals)

fieldType = this%getStrAt(p, J_FIELD, default=J_FIELD_ELECTRIC)
call this%core%get(p, J_PR_MOVIE_COMPONENTS, compsPtr, found=componentsFound)
call this%core%get(p, J_PR_MOVIE_COMPONENT, compsPtr, found=componentsFound)
allocate(res%cordinates(1))
if (componentsFound) then
numberOfComponents = this%core%count(compsPtr)
allocate(res%cordinates(numberOfComponents))
do i = 1, numberOfComponents
call this%core%get_child(compsPtr, i, compPtr)
call this%core%get(compPtr, component)
res%cordinates(i) = cs(1)
res%cordinates(i)%Or = buildVolProbeType(fieldType, component)
end do
else
allocate(res%cordinates(1))
call this%core%get(compsPtr, component)
res%cordinates(1) = cs(1)
res%cordinates(1)%Or = buildVolProbeType(fieldType, component)
else
component = J_DIR_M
res%cordinates(1)%Or = buildVolProbeType(fieldType, component)
endif
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module labels_mod
module smbjson_labels_mod

#ifdef CompileWithSMBJSON
! LABELS
Expand Down Expand Up @@ -161,7 +161,7 @@ module labels_mod

character (len=*), parameter :: J_PR_POINT_DIRECTIONS = "directions"

character (len=*), parameter :: J_PR_MOVIE_COMPONENTS = "components"
character (len=*), parameter :: J_PR_MOVIE_COMPONENT = "component"

character (len=*), parameter :: J_PR_FAR_FIELD_THETA = "theta"
character (len=*), parameter :: J_PR_FAR_FIELD_PHI = "phi"
Expand Down
5 changes: 0 additions & 5 deletions src_main_pub/anisotropic.F90
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,6 @@
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

module Anisotropic

#ifdef CompileWithAnisotropic

use fdetypes
implicit none
private
Expand Down Expand Up @@ -1581,6 +1578,4 @@ Subroutine CalculateCoeff(epr,mur,sigma,sigmam,dt,coeff)

end subroutine

#endif

end module Anisotropic
6 changes: 0 additions & 6 deletions src_main_pub/dmma_thin_slot.F90
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,6 @@
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

MODULE DMMA


#ifdef CompileWithDMMA

USE FDETYPES
IMPLICIT NONE
PRIVATE
Expand Down Expand Up @@ -162,6 +158,4 @@ END SUBROUTINE dmma_thin_Slot
!
!

#endif

END MODULE
3 changes: 0 additions & 3 deletions src_main_pub/electricdispersive.F90
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@

module EDispersives

#ifdef CompileWithEDispersives

use fdetypes
USE REPORT
Expand Down Expand Up @@ -442,6 +441,4 @@ subroutine DestroyEDispersives(sgg)

end subroutine

#endif

end module EDispersives
83 changes: 0 additions & 83 deletions src_main_pub/errorreport.F90
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@
Module Report
use FDETYPES

#ifdef CompileWithXDMF
use snapxdmf
#endif

implicit none
private
Expand Down Expand Up @@ -299,32 +297,7 @@ subroutine ReportExistence(sgg,layoutnumber,size,thereare,mur_second,MurAfterPML

call print11(layoutnumber,SEPARADOR//sEPARADOR//SEPARADOR)
!!!
if ((thereare%NodalE).or.(thereare%NodalH)) then
#ifdef CompileWithNodalSources
continue
#else
buff=trim(adjustl(whoami))//' Nodal sources unsupported. Recompile'
call stoponerror(layoutnumber,size,buff)
#endif
endif
!
IF (thereare%FarFields) then
#ifdef CompileWithNF2FF
continue
#else
buff=trim(adjustl(whoami))//' NF2FF unsupported. Recompile'
call stoponerror(layoutnumber,size,buff)
#endif
endif
!
IF (thereare%SGBCs) then
#ifdef CompileWithSGBC
continue
#else
buff=trim(adjustl(whoami))//' SGBC unsupported. Recompile'
call stoponerror(layoutnumber,size,buff)
#endif
endif
IF ((thereare%Multiports).or.(thereare%AnisMultiports)) then
#ifdef CompileWithNIBC
continue
Expand All @@ -333,52 +306,6 @@ subroutine ReportExistence(sgg,layoutnumber,size,thereare,mur_second,MurAfterPML
call stoponerror(layoutnumber,size,buff)
#endif
endif
!
!
IF (thereare%Anisotropic) then
#ifdef CompileWithAnisotropic
continue
#else
buff=trim(adjustl(whoami))//' Anisotropic unsupported. Recompile'
call stoponerror(layoutnumber,size,buff)
#endif
endif
!
IF (thereare%ThinSlot) then
#ifdef CompileWithDMMA
continue
#else
buff=trim(adjustl(whoami))//' Thin slots unsupported. Recompile'
call stoponerror(layoutnumber,size,buff)
#endif
endif
!
IF (thereare%EDispersives.or.thereare%MDispersives) then
#ifdef CompileWithEDispersives
continue
#else
buff=trim(adjustl(whoami))//' Dispersive materials unsupported. Recompile'
call stoponerror(layoutnumber,size,buff)
#endif
endif
!
If (thereare%Wires) then
#ifdef CompileWithWires
continue
#else
#ifdef CompileWithBerengerWires
continue
#else
#ifdef CompileWithSlantedWires
continue
#else
buff=trim(adjustl(whoami))//' WIREs unsupported. Recompile'
call stoponerror(layoutnumber,size,buff)
#endif
#endif
#endif
endif
!
!!!!!!!!!!!!!
if (thereAre%MagneticMedia) then
buff=' has special H-media'
Expand Down Expand Up @@ -416,20 +343,15 @@ subroutine ReportExistence(sgg,layoutnumber,size,thereare,mur_second,MurAfterPML
buff= ' has Thin metal Materials'
call warnerrreport(buff)
endif
#ifdef CompileWithAnisotropic
IF ((thereare%Anisotropic).and.(.not.thereare%ThinSlot)) then
buff= ' has pure anisotropic media'
call warnerrreport(buff)
endif
#ifdef CompileWithDMMA
IF (thereare%ThinSlot) then
buff= ' has Thin Slots'
call warnerrreport(buff)
endif
#endif
#endif
!
#ifdef CompileWithEDispersives
IF (thereare%EDispersives) then
buff= ' has electric dispersives'
call warnerrreport(buff)
Expand All @@ -438,13 +360,10 @@ subroutine ReportExistence(sgg,layoutnumber,size,thereare,mur_second,MurAfterPML
buff= ' has magnetic dispersives'
call warnerrreport(buff)
endif
#endif
#ifdef CompileWithWires
If (thereare%Wires) then
buff= ' has Holland WIREs'
call warnerrreport(buff)
endif
#endif
#ifdef CompileWithBerengerWires
If (thereare%Wires) then
buff= ' has Multi-WIREs'
Expand Down Expand Up @@ -1168,7 +1087,6 @@ subroutine Timing(sgg, b, n, n_info, layoutnumber, size, maxCPUtime,flushseconds
call MPI_Barrier(MPI_COMM_WORLD,ierr)
#endif

#ifdef CompileWithXDMF
if ((mustsnap.and.(lmaxval (layoutnumber+1)> snapLevel)).or.(countersnap > 0)) then
countersnap=countersnap + 1
!
Expand Down Expand Up @@ -1272,7 +1190,6 @@ subroutine Timing(sgg, b, n, n_info, layoutnumber, size, maxCPUtime,flushseconds
countersnap=0
endif
endif
#endif

#ifdef CompileWithMPI
call MPI_Barrier(MPI_COMM_WORLD,ierr) !TODOS STOCH O NO 060619
Expand Down
4 changes: 0 additions & 4 deletions src_main_pub/farfield.F90
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,6 @@
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

module farfield_m

#ifdef CompileWithNF2FF

use fdetypes
USE REPORT

Expand Down Expand Up @@ -3576,5 +3573,4 @@ function average (pasadas,z1,z2) result (z)
RETURN
END FUNCTION

#endif
END MODULE farfield_m
Loading

0 comments on commit 4c82aba

Please sign in to comment.