Clear Screen (cls/clc)



I miss the ability to clear screen in lumerical script prompt.
Therefore I present a very simplistic version of it cls.lsf (60 Bytes)

You can add it to your scripts path (type “?getpath;” to find it).
It usually is on:
C:/Program Files/Lumerical/FDTD/scripts
C:/Program Files/Lumerical/MODE/scripts

Setting up simulation from script

Very useful script. Thanks for sharing. Here is one more option that I wanted to share:

  • If you have a few lines in your script prompt, another way to clear the screen is to use CTRL+Z. Keep the keys pressed until the screen is all clear.


I tend to be a heavy user of scripts. Therefore I created cls to be used before printing.
But I didn’t know about Ctrl+z. Nice one.

Do you know how to create a tab character line the endl one?
’\t’ doesn’t seems to work.
I generally use the awkward definition:

tab = replacestring(num2str([0, 0]), ‘0’, ‘’);


That is really cool! I had no idea that you can make a tab character like that. I am nor aware of any shortcut or commands to create a tab but this one is a very nice workaround. Thanks for sharing. I’ll use this one in my scripts now!