tidy3d.BlochBoundary#

class tidy3d.BlochBoundary#

Specifies a Bloch boundary condition along a single dimension.

Parameters
  • name (Optional[str] = None) – Optional unique name for boundary.

  • bloch_vec (Union[tidycomplex, ComplexNumber] = None) – Normalized component of the Bloch vector in units of 2 * pi / (size along dimension) in the background medium, along the dimension in which the boundary is specified.

Example

>>> bloch = BlochBoundary(bloch_vec=1)

Show JSON schema
{
   "title": "BlochBoundary",
   "description": "Specifies a Bloch boundary condition along a single dimension.\n\nParameters\n----------\nname : Optional[str] = None\n    Optional unique name for boundary.\nbloch_vec : Union[tidycomplex, ComplexNumber] = None\n    Normalized component of the Bloch vector in units of 2 * pi / (size along dimension) in the background medium, along the dimension in which the boundary is specified.\n\nExample\n-------\n>>> bloch = BlochBoundary(bloch_vec=1)",
   "type": "object",
   "properties": {
      "name": {
         "title": "Name",
         "description": "Optional unique name for boundary.",
         "type": "string"
      },
      "type": {
         "title": "Type",
         "default": "BlochBoundary",
         "enum": [
            "BlochBoundary"
         ],
         "type": "string"
      },
      "bloch_vec": {
         "title": "Normalized Bloch vector component",
         "description": "Normalized component of the Bloch vector in units of 2 * pi / (size along dimension) in the background medium, along the dimension in which the boundary is specified.",
         "anyOf": [
            {
               "title": "ComplexNumber",
               "description": "Complex number with a well defined schema.",
               "type": "object",
               "properties": {
                  "real": {
                     "title": "Real",
                     "type": "number"
                  },
                  "imag": {
                     "title": "Imag",
                     "type": "number"
                  }
               },
               "required": [
                  "real",
                  "imag"
               ]
            },
            {
               "$ref": "#/definitions/ComplexNumber"
            }
         ]
      }
   },
   "required": [
      "bloch_vec"
   ],
   "additionalProperties": false,
   "definitions": {
      "ComplexNumber": {
         "title": "ComplexNumber",
         "description": "Complex number with a well defined schema.",
         "type": "object",
         "properties": {
            "real": {
               "title": "Real",
               "type": "number"
            },
            "imag": {
               "title": "Imag",
               "type": "number"
            }
         },
         "required": [
            "real",
            "imag"
         ]
      }
   }
}

Fields
  • bloch_vec (Union[tidy3d.components.types.tidycomplex, tidy3d.components.types.ComplexNumber])

attribute bloch_vec: Union[tidy3d.components.types.tidycomplex, tidy3d.components.types.ComplexNumber] [Required]#

Normalized component of the Bloch vector in units of 2 * pi / (size along dimension) in the background medium, along the dimension in which the boundary is specified.

Validated by
  • _zero_imaginary_part

classmethod from_source(source: Union[tidy3d.components.source.GaussianBeam, tidy3d.components.source.ModeSource, tidy3d.components.source.PlaneWave], domain_size: float, axis: Literal[0, 1, 2], medium: Optional[tidy3d.components.medium.Medium] = None) tidy3d.components.boundary.BlochBoundary#

Set the Bloch vector component based on a given angled source and its center frequency.

Parameters
  • source (Union[GaussianBeam, ModeSource, PlaneWave]) – Angled source.

  • domain_size (float) – Size of the domain (micron) in the direction normal to the Bloch boundary.

  • axis (int) – Axis normal to the Bloch boundary.

  • medium (Medium) – Background medium associated with the Bloch vector. Default: free space.

Returns

Bloch boundary condition with wave vector defined based on the source angles and center frequency.

Return type

BlochBoundary

Example

>>> from tidy3d import GaussianPulse, PlaneWave, inf
>>> pulse = GaussianPulse(freq0=200e12, fwidth=20e12)
>>> pw_source = PlaneWave(
...     size=(inf,inf,0), source_time=pulse, direction='+', angle_theta=1.5, angle_phi=0.3)
>>> bloch = BlochBoundary.from_source(source=pw_source, domain_size=5, axis=0)
property bloch_phase: Union[tidy3d.components.types.tidycomplex, tidy3d.components.types.ComplexNumber]#

Returns the forward phase factor associated with bloch_vec.