本帖最后由 GRRR 于 2022-9-26 13:54 编辑
LightTools自带的帮助手册就很有用啊,还有很多例子,不过你的这个实现起来很简单,MATLAB都用不上,我自己写过一个类似的,用LightTools宏语言写的,你可以参考下:
ReceiverList$ = LTDBLIST$("ILLUM_MANAGER[1].RECEIVERS[1]","SURFACE_RECEIVER")
index = 1
DO
Status = LTLISTSETPOS(ReceiverList$,index)
IF Status <> 0 THEN
EXIT DO
END IF
FirstReceiver$ = LTLISTNEXT$(ReceiverList$)
FirstReceiverName$ = LTDBKEYSTR$(FirstReceiver$)
print FirstReceiverName$
REM LENS_MANAGER[1].ILLUM_MANAGER[Illumination_Manager].RECEIVERS[Receiver_List].SURFACE_RECEIVER[Receiver_317].FORWARD_SIM_FUNCTION[Forward_Simulation].ILLUMINANCE_MESH[Illuminance_Mesh].TotalPower
REM LENS_MANAGER[1].ILLUM_MANAGER[Illumination_Manager].RECEIVERS[Receiver_List].SURFACE_RECEIVER[Receiver_2487].FORWARD_SIM_FUNCTION[Forward_Simulation].ILLUMINANCE_MESH[Illuminance_Mesh].Average
IllumMesh$ = FirstReceiverName$ + ".FORWARD_SIM_FUNCTION[Forward_Simulation].ILLUMINANCE_MESH[Illuminance_Mesh]"
TotalPower = LTDBGET(IllumMesh$,"TotalPower")
print "TotalPower :", TotalPower
index = index + 1
print "---------------------------------------------------------"
LOOP