moving stl files to certain positions

Submitted by knoe_ph on Mon, 05/21/2012 - 17:06

Hallo,

I'm wondering if there is a possibility to move a stl-file (which i included by the "fix mesh/gran/stressanalysis" command) in my simulation to a given position.

I know there's the possibility to move it with a certain velocity in a specific direction (with the fix move/mesh/gran command), but i couldnt find anything about how to move it to a certain position (in a given time or velocity). For example my stl file is a planar shaped layer which I want to move right on top of my highest inserted particle. I'm able to realise this by setting up a specific velocity and then run it for a specific amount of timesteps, but this is quite complicated since i have to do this procedure several times.

Also, is there a possibility to get the coordinates from my stl-file? (like i get it from my particles with a command like "variable zmax equal bound(all,zmax)" )

I appreciate any help and kind regards,

Philipp

Philippe's picture

Philippe | Tue, 05/22/2012 - 08:20

Dear Philipp,

I am not certain what you want to do: Do you want to just put an stl file that is created around the origin to some other location in space where it will remain? If so, the mesh/gran/stressanalysis command can do this for you:

fix ID group-ID mesh/gran filename walltype scalefactor xoff yoff zoff phix phiy phiz keyword values

xoff, yoff, zoff are the offsets in x,y,z directions. For more details, please consult the manual. If the mesh must move during the simulation, move/mesh/gran is the way to go as you described

However, I apologize in advance if I misunderstood your problem and you are looking for something more complicated ;)

best,
Philippe

knoe_ph | Tue, 05/22/2012 - 10:15

Hallo philippe,

I probably didnt express myself clearly.

I implement my stl file right at the biginning of simulation. Then I want it to move to a certain position.
Right now I'm using the "fix move/mesh/gran linear" command to do so. This means I move my stl file with a specific velocity for a specific amount of time steps. It works, but it would be simpler if i could set the position where my stl file should move to. Especially if, like in my case, the position where it should move to depends on the position of my integrated particles.
The Syntax should be something like this:

"move stl-file until z_coordinate_stl_file=z_coordinate_particle"

I can't just create the stl file at this position, because it has to interact with my particles on the way moving.

I'm not sure if this can be realised the way I described it though.

Kind regards,
Philipp

Philippe's picture

Philippe | Tue, 05/22/2012 - 10:43

ok, I start to get your case.

The former can not be realized with the current syntax.

For the latter, you could try something like

run 100000 every 100 'if [condition] unfix move'

perhaps with a more sophisticated if command, to make sure that [condition] is true exactly once (unfixing a previously unfixed fix will crash LIGGGHTS). Conditional fix move are not implemented, thought they would be a good idea....

best,
Philippe