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

Re: [femm] lua scripts



Robin Cornelius wrote:

2)

-- is the Lua comment

1)

The properties and materials :- you can currently only add new complete
materials or delete existing there is no way to edit so you have to live
with the add material command (have a look at 5.2.9 in the manual) :-
5.2.9 Object Properties
.
addmaterial("materialname", mu x, mu y, H c, Jr, Ji, Cduct, Lam d, Theta h,
lam fill, LamType)



Is that what you mean for 1) ?


Ah, i think i know what you mean. there is no way (currently!?) of loading
materials from the materials library into your model using lua on its own as
you would on the menu properties->materials library.


The way that I go about it is to create new model in the preprocessor that just has the materials that I want to eventually use in the lua script. I then save it to some filename like "materials.fem" At the beginning of the lua script, I then load the file (i.e. openfemmfile("materials.fem") ) , and all of the materials that I want are there and ready for use.

Dave.