How to Get Raw Data from a Simulation Object in Lumerical

Obtaining Raw Data from a Simulation Object in Lumerical

Lumerical – getdata – Script Command for Raw Data Pull

Need assistance in Ansys Lumerical obtaining raw data from a simulation object? The majority of the time, retrieving the entire dataset using getresult is more practical than getting individual data components using Lumerical’s getdata command script.

Prior to utilizing getdata, don’t forget to launch the simulation first.

For getdata Command Scripts in Lumerical MODE and FDTD:

Syntax Description


Function returns names of all objects with data.


Function returns list of of data within the simulation object.

out = getdata( “monitor”, “dataname”);

This function, however, pulls data from a monitor. For example, you can use

  • Ex = getdata(“monitor2″,”Ex”);

to get the Ex field data from monitor2.

out = getdata( “monitor”, “dataname”, option);

Option can be an optional parameter with a value of 1 or 2. If the answer is 2, the data is unfolded wherever possible in accordance with symmetry or anti-symmetry borders if it originates from a monitor that crosses such a barrier at x minimum, y minimum, or z minimum. Option’s default value is 2.

The user can also decide whether to expand the data to the appropriate size for dimensions when the field component is zero for propagator simulations in MODE using this option. For the field component in that dimension, option 1 will yield a singleton value of 0, while option 2 will produce a matrix (made up of zeros) that is the same size as the other field components.

For getdata Command Scripts in Lumerical CHARGE, HEAT, DGTD, FEEM:

Syntax Description


Function returns names of all objects with data.


Function returns list of of results within the simulation object.

?getdata( “monitor”, “result”);

Function returns list of of data within the simulation object result.

out = getdata( “monitor”, “result”, “dataname”);

Function pulls the simulation data.  (Note the differences here compared to MODE and FDTD).

For INTERCONNECT: Although INTERCONNECT offers the getdata command to be compatible with other Lumerical products, it is recommended that you use the getresult script function to obtain INTERCONNECT simulation data instead.

Practical getdata Lumerical Command Script Examples:

This example shows how to use getdata to check which data is available.

> monitor
> source
> x y z surface_normal dimension f Ex Ey Ez
> Hx Hy Hz power

From here, we’ll plot an image of Ex(x,y) using getdata. We also demonstrate how to generate the same figure using getresult.

# get raw data with getdata
# select first frequency point of Ex data, then create plot
Ex = pinch(Ex,4,1); 
image(x*1e6,y*1e6,Ex,"x (um)","y (um)","Ex");
# use getresult to get all of the E field data in a single command
# select first frequency point of Ex data, then create plot
Ex = pinch(E.Ex,4,1); # select first frequency point to plot
image(E.x*1e6,E.y*1e6,Ex,"x (um)","y (um)","Ex");

Obtain the “Device region” object’s data list before obtaining the information on the “n” carrier concentration.

?getdata("Device region");
?getdata("Device region","active");
n=getdata("Device region","active","n");
> active drain source
> n p Ei Ec Ev Efn Efp log10(N) mun mup 
> result: 
>  2826 1 9 1 





Ansys Lumerical Products

Lumerical software overview and core capabilities



Ansys Lumerical FDTD

Simulation of Nanophotonic Devices

  • Q-factor Analysis
  • Band Structure Analysis
  • Flexible Material Plug-ins
  • Cloud and HPC Capability
  • 2D or 3D Model Simulation
  • Full Vectoral Customization
  • Far-field Projection Analysis
  • Spatially Varying Anisotropy
  • Custom Surfaces and Volumes
  • Advanced Conformal Meshing
  • Automated S-parameter Extraction


Ansys Lumerical STACK

Optical Thin-Film Simulation

  • Plane-Wave Illumination
  • Capture Interference Effects
  • Capture Microactivity Effects
  • Optical Thin-Film Application
  • Accurate EM Simulation
  • Dipole/Dipole Off-Axis Illumination
  • Simulate Thin Film Multilayer Stacks
  • Macroscopic Human Perception Analysis
  • Rapid Photonics-Electronics Prototyping
  • Thick Layer Support ≥ Coherence Length



Photonic Integrated Circuit Simulator

  • Transient Block Analysis
  • Frequency Domain Analysis
  • GUI and Lumerical Scripting
  • Mixed Signal Representation
  • Travelling Wave Laser Model
  • Automatic Parameter Sweeps
  • Multi-Variant Statistical Analysis
  • Import Compact Libraries Models
  • Electronic-Photonic Co-Simulation
  • Transient Sample Model Simulator
  • Multimode and Multichannel Support






Ansys Lumerical CHARGE

3D Charge Transport Solver

  • Scriptable Material Properties
  • Automatic Finite Element Meshing
  • Electrical/Thermal Material Models
  • Parameterizable Simulation Objects
  • Geometry-Linked Sources/Monitors
  • Establishing Scripts in Ansys Lumerical
  • Comprehensive SoC Material Models
  • Small Signal Alternating Current analysis’
  • Isothermal, Non-Isothermal, Electro-Thermal


Ansys Lumerical HEAT

3D Heat Transport Solver

  • Joule (J) Heating Solver
  • Flexible Materials Database
  • Automatic Mesh Refinement
  • Finite-Element Meshing Automation
  • Finite-Element Heat Transport Solver
  • Steady-State and Transient Simulation
  • Rapid Transition from 2D & 3D Solvers
  • Self-Consistent Heat/Charge Transport
  • Conductive, Convection & Radiative Effects


Ansys Lumerical DGTD

3D Electromagnetic (EM) Simulator

  • Highly Interoperable
  • Object-Conformal Mesh
  • Material-Adaptive Mesh
  • Gaussian Vector Beams
  • Automation and Scripting
  • Bloch Boundary Conditions
  • Automatic Mesh Refinement
  • High Order Mesh Polynomials
  • Transitional 2D & 3D Modeling
  • Far-field and Grating Projections
  • Pixel EPDA through Speos Integration






Ansys Lumerical FEEM

Finite Element Waveguide Simulation

  • Frequency Domain Reflectometry
  • Higher-Order Polynomial Functions
  • Parallel Curved Meshing Adaptivity
  • Electro-Optic Modeling Simulation
  • Thermo-Optic Modeling Simulation
  • Spatially Varying Index Perturbations
  • Determine Effective Refractive Index’
  • Fourier analysis for Signal Processing
  • Material-adaptive Mesh Embedment
  • Waveguide Thermal Sensitivity Tuning


Ansys Lumerical MQW

Quantum Well Gain Simulation

  • Wavefunction Calculation
  • Band Diagram Calculation
  • Physics-Based Photonics Solver
  • Quantum Mechanical Analysis
  • Conduction Electron Scattering
  • Gain and Spontaneous Emission
  • Characterization of Band Structures
  • Multi-Quantum Well Stacks Simulator
  • Controllable Quantum States
  • Mesoscopic Superconductivity Analysis


Ansys Lumerical Suite

Electronics Photonics Design Automation (EPDA)

  • Lumerical MODE
  • Lumerical CHARGE
  • Lumerical HEAT
  • Lumerical DGTD
  • Lumerical STACK
  • Lumerical FEEM
  • Lumerical MQW
  • Lumerical VERILOG-A
  • Lumerical INTERCONNECT
  • Lumerical CML COMPILER




Most Recent Tips & Tricks