Obtaining imaginary fields from MODE


#1

Hi all,

I was wondering if anyone knows how to obtain both the real and imaginary data from MODE solutions? I have calculated and chosen the mode I am interested. I can then even see real and imaginary data in the Eigensolver analysis window. When I try to export in to .txt or matlab, however, the imaginary column is blank. Any help would be greatly appreciated.

Many thanks.


#2

Hi,

I tried exporting mode data using the “Data export” option in the Modal Analysis tab of the Eigensolver analysis window and I am able to see both real and imaginary parts of the fields for both text file and matlab formats. I used the latest version of MODE Solutions.

If it happens to be a problem with an older version of MODE Solutions and it’s not convenient for you to update the version of the software then an alternative method is to get the modal field data from the script, eg. the following code gets the imaginary part of Ex for the first mode in the mode list:
imag_Ex = imag(getdata("mode1","Ex"));

Matrix variables can then be written it to a text file using the “write” script command:
https://kb.lumerical.com/en/index.html?ref_scripts_write.html