Ansys Learning Forum › Forums › Discuss Simulation › Photonics › readdata script not working in Lumerical 2024 R2.3 › Reply To: readdata script not working in Lumerical 2024 R2.3
October 31, 2024 at 7:05 am
johannes.haataja
Subscriber
Â
Much obliged Kirill for your help,Â
 I don’t know why I get different behavious. I’ve replicated the issue on Lumerical 2024 R2.2 and R2.3 on two different Ubuntu systems.
Manipulating elements of M inside Lumerical to haveÂ
Â
0 Â 3.2e-06 Â
1 Â 2.8e+10 Â
2 Â 410000 Â
3 Â 3.3Â
Â
then using write function
Â
write('writetest.txt',num2str(M),'overwrite');
M2 = readdata('writetest.txt');
?M2;
result:Â
0 Â 3 Â
1 Â 2 Â
2 Â 410000 Â
3 Â 3
Perhaps as temporary solution, I'll multiply the values of my data file by some large enough prefactor and then divide M by the same prefactor to get the desired outcome.