Basic Materials and Objects#
In FDTDX, simulation objects can have a material, which defines the permittivity, permeability and conductivity of the object.
Currently neither dispersion nor non-linear materials are implemented. The implementation of dispersion is scheduled in the near-mid future and afterwards an implementation of non-linear materials will follow.
import fdtdx
material = fdtdx.Material()
print(material)
Material(
permittivity=#1.0,
permeability=#1.0,
electric_conductivity=#0.0,
magnetic_conductivity=#0.0
)
The default material above with no parameters represents free space with a relative permittivity and permeability of 1. These values can be freely set by a user.
material2 = fdtdx.Material(permittivity=2.5, permeability=1.7)
print(material2)
Material(
permittivity=#2.5,
permeability=#1.7,
electric_conductivity=#0.0,
magnetic_conductivity=#0.0
)
fdtdx.UniformMaterial#
The most basic and also probably most useful object is the UniformMaterialObject. As the name suggests, it has a single material. Importantly, every object in FDTDX needs to have a unique name! If no name is provided, then some name is chosen programmatically.
uniform_obj = fdtdx.UniformMaterialObject(
partial_real_shape=(0.6e-6, 0.6e-6, 0.6e-6), # size of the object in meters
material=material, # material
name="Uniform Material", # name of the object, optional
)
print(uniform_obj)
UniformMaterialObject(
partial_real_shape=#(6e-07, 6e-07, 6e-07),
partial_grid_shape=#(None, None, None),
color=#(0.8470588235294118, 0.8627450980392157, 0.8392156862745098),
name=#Uniform Material,
max_random_real_offsets=#(0, 0, 0),
max_random_grid_offsets=#(0, 0, 0),
_grid_slice_tuple=#((-1, -1), (-1, -1), (-1, -1)),
placement_order=#0,
material=Material(
permittivity=#1.0,
permeability=#1.0,
electric_conductivity=#0.0,
magnetic_conductivity=#0.0
)
)
There also exist Objects with more elaborate material distributions, but for the quickstart we will only cover this most basic material.