[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: LUA question on current density



Thank you, Dave and Keith.

This morning I tried Keith's suggestion but I couldn't get that to 
work. The delete_material , add_material sequence didn't seem to do 
anything. I still had the original material and the same J.

Then I tried the "setblockprop" command to change the copper region 
to one of several different copper-type materials, each with a 
different current density. This worked fine for a limited set of 
materials. This can also be used to select different kinds of steel. 
I did notice one little trick. (maybe old news to some). I had to 
deselect previously selected regions before operating on a new 
region, even when the group number is different. 

For example:

seteditmode("group")

selectgroup(2) -- program a new material type for group 2
setblockprop("CU488",0,0.02,0,0,2)

clearselected() -- have to clear last selection, 
-- else group 2 also gets translated by
-- the next command.

selectgroup(1)
move_translate(0,dz)	

clearselected() -- clear this selection before doing something else

-- end of example

I'll download the new goodies this afternoon. These new enhancements 
looks very exciting, Dave. 

Thanks again for your help, guys. 

-- Jim