sim.applyForceToWall

Asked by Romain on 2017-09-18

Dear All,

I tried to make a computation with impose force on one wall. To do so, I tried with:
sim.applyForceToWall(wallName, Fplate);
print sim.getWallForce(wallName);

The print gives 0.0, 0.0, 0.0 but Fplate is no equal to 0 !

Should I use "sim.moveWallBy" instead of "sim.applyForceToWall" ?

KR
Romain

Question information

Language:
English Edit question
Status:
Answered
For:
ESyS-Particle Edit question
Assignee:
No assignee Edit question
Last query:
2017-09-18
Last reply:
2017-09-18
Dion Weatherley (d-weatherley) said : #1

Hi Romain,

LsmMpi.applyForceToWall(..) requires the particle-wall interaction group name to be passed as the first argument, rather than the wall name.

For example, suppose you have created a wall called "bottom_wall" this way:

sim.createWall(
  name = "bottom_wall",
  posn = Vec3 (0,0,0),
  normal = Vec3 (0,1,0)
)

then specified an NRotElasticWallPrms interaction group acting between particles and the wall in the following way:

sim.createInteractionGroup (
   NRotElasticWallPrms (
      name = "bottom_wall_IG",
      wallName = "bottom_wall",
      normalK = 10000.0
   )
)

To apply a prescribed force (e.g. Fplate) to this wall, use the following:

sim.applyForceToWall ("bottom_wall_IG", Fplate)

Note that "bottom_wall_IG" is passed as an argument, rather than "bottom_wall".

Cheers,

Dion

P.S. Please note that it is important that the net force acting on a wall is non-zero initially when using applyForceToWall(..). It is usually best to move the walls initially using moveWallBy(..) until the net wall force is non-zero, before commencing to use applyForceToWall(..). In any case, applyForceToWall(..) must always be supplied an interaction group name, rather than a wall name.

Can you help with this problem?

Provide an answer of your own, or ask Romain for more information if necessary.

To post a message you must log in.