-
-
January 18, 2025 at 2:14 am
2023020268
SubscriberFDTD中我定义了全局变h1想用其控制基底的高度和组成结构组四个圆形结构的参数,我应该怎样编写脚本,尝试过利用select先选择出结构组,再直接对结构组中的结构参数进行定义,报出无法找到该结构的错误,我应该怎样进行修改,谢谢老师!
-
January 23, 2025 at 3:36 am
olivia.liu
Subscriberselect结构组和其中参数的前提是你已经搭建好了结构,并且定义了这个参数。
举个例子,可以先设置好结构组,在结构组的properties中设置高度参数h1,在结构组的script中利用该参数(h1)设置基底和圆柱的具体结构。之后,在model的setup中设置变量H,在setup的script中select之前的结构组,并set(“h1”,H)。这样就可以使用model中的变量H对结构组中的h1进行调整。
同样的,如果涉及到多个结构组,比如结构组1的h1参数和结构组2的h2参数都希望通过model中的H控制,只需要在model中分别选中并set。
更多的脚本语言可以参考:Lumerical scripting language – By category – Ansys Optics
-
Viewing 1 reply thread
- You must be logged in to reply to this topic.
Ansys Innovation Space
Trending discussions
Top Contributors
-
1937
-
839
-
599
-
591
-
366
Top Rated Tags
© 2025 Copyright ANSYS, Inc. All rights reserved.
Ansys does not support the usage of unauthorized Ansys software. Please visit www.ansys.com to obtain an official distribution.