yade-users team mailing list archive
-
yade-users team
-
Mailing list archive
-
Message #07195
Re: [Question #223478]: Ball bouncing on the wall
Question #223478 on Yade changed:
https://answers.launchpad.net/yade/+question/223478
Status: Open => Answered
Jan Stránský proposed the following answer:
Ok, I was confused by
material=RpmMat
in wall definition..
replace
Law2_L3Geom_FrictPhys_ElPerfPl()
with
Law2_ScGeom_FrictPhys_CundallStrack()
or any other law beginning with Law2_ScGeom (as you defined ScGeom in
Ig2_Wall_Sphere_ScGeom()), see links in my previous mail and [1]
the material usage in Yade is usually as follows (see [2]):
mat1 = O.materials.append(FrictMat(...))
utils.wall(...,mat=mat1,...)
Jan
[1] https://yade-dem.org/doc/yade.wrapper.html#constitutive-laws
[2] https://yade-dem.org/doc/user.html#defining-materials
2013/3/7 Majid Ashraf <question223478@xxxxxxxxxxxxxxxxxxxxx>
> Question #223478 on Yade changed:
> https://answers.launchpad.net/yade/+question/223478
>
> Status: Answered => Open
>
> Majid Ashraf is still having a problem:
> Hello Jan,
> This is the complete script which i am using.
>
> O.bodies.append([
>
> utils.wall(position=Vector3(0,1,2),axis=2,sense=1,color=(1,0,0),material=RpmMat,mask=1),
> #utils._commonBodySetup(),
> utils.sphere((0,0,2),.5)
> ])
> O.engines=[
> ForceResetter(),
> InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Wall_Aabb()]),
> InteractionLoop(
> [Ig2_Wall_Sphere_ScGeom()],
> [Ip2_FrictMat_FrictMat_FrictPhys()], # collision "physics"
> [Law2_L3Geom_FrictPhys_ElPerfPl()], # contact law -- apply forces
> ),
> GravityEngine(gravity=(0,0,-9.81)),
> # damping: numerical dissipation of energy
> NewtonIntegrator(damping=0.1)
> ]
>
> # set timestep to a fraction of the critical timestep
> # the fraction is very small, so that the simulation is not too fast
> # and the motion can be observed
> O.dt=.5e-4*utils.PWaveTimeStep()
>
> # save the simulation, so that it can be reloaded later, for
> experimentation
> O.saveTmp()
>
> Thanks.
>
> Best Regards,
>
> Majid
>
>
> On Thu, Mar 7, 2013 at 11:01 AM, Jan Stránský <
> question223478@xxxxxxxxxxxxxxxxxxxxx> wrote:
>
> > Your question #223478 on Yade changed:
> > https://answers.launchpad.net/yade/+question/223478
> >
> > Status: Open => Answered
> >
> > Jan Stránský proposed the following answer:
> > Hello Majid,
> >
> > we are on the right way :-) now the problem is that you have incompatible
> > functors, see [1]. You used Ig2_Wall_Sphere_ScGeom (so ScGeom), but then
> > Law2_L3Geom_FrictPhys_ElPerfPl (law for L3Geom). To make it work properly
> > you will need to use Law2_ScGeom_Something...
> >
> > To tell you correct answer, we will need to see the compete sript (i.e.
> > what materials you are using). So please attach the whole script and
> > hopefully we will converge to the solution :-)
> > Jan
> >
> > [1] https://yade-dem.org/doc/user.html#functors-choice
> >
> > 2013/3/7 Majid Ashraf <question223478@xxxxxxxxxxxxxxxxxxxxx>
> >
> > > Question #223478 on Yade changed:
> > > https://answers.launchpad.net/yade/+question/223478
> > >
> > > Status: Answered => Open
> > >
> > > Majid Ashraf is still having a problem:
> > > Hey Jan,
> > > I tried incorporating the Aabb for wall in the insertion
> > > collider as you advised but now i am getting this when i run the
> > > simulation.
> > >
> > > FATAL /build/buildd/yade-0.70.0/pkg/common/InteractionLoop.cpp:156
> > action:
> > > None of given Law2 functors can handle interaction #0+1, types
> > > geom:ScGeom=1 and phys:FrictPhys=4 (LawDispatcher::getFunctor2D
> returned
> > > empty functor)
> > >
> > >
> > > Thanks.
> > >
> > > Best Regards,
> > >
> > > Majid
> > >
> > >
> > > On Tue, Mar 5, 2013 at 2:45 PM, Jan Stránský <
> > > question223478@xxxxxxxxxxxxxxxxxxxxx> wrote:
> > >
> > > > Question #223478 on Yade changed:
> > > > https://answers.launchpad.net/yade/+question/223478
> > > >
> > > > Status: Open => Answered
> > > >
> > > > Jan Stránský proposed the following answer:
> > > > Hello Majid,
> > > >
> > > > thanks for the info. The problems is, that there is no bounding
> > > dispatcher
> > > > for the wall, so it is not considered by colision detector. Modify
> you
> > > > InsrtionSortCollider to this:
> > > >
> > > > InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Wall_Aabb()]),
> > > >
> > > > now it should work.
> > > > in case of any other question, don't hesitate to ask :-)
> > > > cheers
> > > > Jan
> > > >
> > > >
> > > > 2013/3/5 Majid Ashraf <question223478@xxxxxxxxxxxxxxxxxxxxx>
> > > >
> > > > > Question #223478 on Yade changed:
> > > > > https://answers.launchpad.net/yade/+question/223478
> > > > >
> > > > > Status: Answered => Open
> > > > >
> > > > > Majid Ashraf is still having a problem:
> > > > > Hello Jan,
> > > > > Thanks for the thumbs up on my problem. I am using
> Yade
> > > > > 0.70.0 and my friend compiled it for me. I wrote the whole syntax
> in
> > > > > IPython and then used yade to recall that using .py extension. I am
> > not
> > > > > getting any syntax errors but the ball is passing through the wall
> > > > instead
> > > > > of bouncing. I have also attached a picture which will give you a
> > > better
> > > > > idea of what's going on.
> > > > >
> > > > > Best Regards,
> > > > >
> > > > > Majid
> > > > >
> > > > >
> > > > > On Tue, Mar 5, 2013 at 1:55 PM, Jan Stránský <
> > > > > question223478@xxxxxxxxxxxxxxxxxxxxx> wrote:
> > > > >
> > > > > > Your question #223478 on Yade changed:
> > > > > > https://answers.launchpad.net/yade/+question/223478
> > > > > >
> > > > > > Status: Open => Answered
> > > > > >
> > > > > > Jan Stránský proposed the following answer:
> > > > > > Hello Majid,
> > > > > >
> > > > > > from what you wrote, it is very hard to say what is the reason..
> To
> > > > help
> > > > > > you, we will need some more information. Firstly, what version of
> > > Yade
> > > > > you
> > > > > > are using and how you compiled it. Then how you run your code
> (from
> > > > > script
> > > > > > or from IPython). Also why it is not working - do you get some
> > errors
> > > > or
> > > > > > the program does something different from what you want?
> > > > > >
> > > > > > so please provide us with these information and hopefully we will
> > be
> > > > able
> > > > > > to help you :-)
> > > > > > Best regards
> > > > > > Jan
> > > > > >
> > > > > >
> > > > > > I run your script without any errors..
> > > > > >
> > > > > >
> > > > > > > This is what i am using.
> > > > > > >
> > > > > > > > O.bodies.append([
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> utils.wall(position=Vector3(0,1,2),axis=2,sense=1,color=(1,0,0),material=RpmMat,mask=1),
> > > > > > > > #utils._commonBodySetup(),
> > > > > > > > utils.sphere((0,0,2),.5)
> > > > > > > > ])
> > > > > > > > O.engines=[
> > > > > > > > ForceResetter(),
> > > > > > > > InsertionSortCollider([Bo1_Sphere_Aabb()]),
> > > > > > > > InteractionLoop(
> > > > > > > > [Ig2_Wall_Sphere_ScGeom()],
> > > > > > > > [Ip2_FrictMat_FrictMat_FrictPhys()], # collision "physics"
> > > > > > > > [Law2_L3Geom_FrictPhys_ElPerfPl()] # contact law -- apply
> > > forces
> > > > > > > > ),
> > > > > > > > GravityEngine(gravity=(0,0,-9.81)),
> > > > > > > > # damping: numerical dissipation of energy
> > > > > > > > NewtonIntegrator(damping=0.1)
> > > > > > > > ]
> > > > > > > >
> > > > > > > > # set timestep to a fraction of the critical timestep
> > > > > > > > # the fraction is very small, so that the simulation is not
> too
> > > > fast
> > > > > > > > # and the motion can be observed
> > > > > > > > O.dt=.5e-4*utils.PWaveTimeStep()
> > > > > > > >
> > > > > > > > # save the simulation, so that it can be reloaded later, for
> > > > > > > > experimentation
> > > > > > > > O.saveTmp()
> > > > > > > >
> > > > > > > > Can anyone please help me out in this regard? I will really
> > > > > appreciate
> > > > > > > your
> > > > > > > > concern. Thanks.
> > > > > > > >
> > > > > > > > Best Regards,
> > > > > > > >
> > > > > > > > Majid
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > You received this question notification because you are a
> member
> > of
> > > > > > > yade-users, which is an answer contact for Yade.
> > > > > > >
> > > > > > > _______________________________________________
> > > > > > > Mailing list: https://launchpad.net/~yade-users
> > > > > > > Post to : yade-users@xxxxxxxxxxxxxxxxxxx
> > > > > > > Unsubscribe : https://launchpad.net/~yade-users
> > > > > > > More help : https://help.launchpad.net/ListHelp
> > > > > > >
> > > > > >
> > > > > > --
> > > > > > If this answers your question, please go to the following page to
> > let
> > > > us
> > > > > > know that it is solved:
> > > > > >
> > > >
> > https://answers.launchpad.net/yade/+question/223478/+confirm?answer_id=0
> > > > > >
> > > > > > If you still need help, you can reply to this email or go to the
> > > > > > following page to enter your feedback:
> > > > > > https://answers.launchpad.net/yade/+question/223478
> > > > > >
> > > > > > You received this question notification because you asked the
> > > question.
> > > > > >
> > > > >
> > > > > --
> > > > > You received this question notification because you are a member of
> > > > > yade-users, which is an answer contact for Yade.
> > > > >
> > > > > _______________________________________________
> > > > > Mailing list: https://launchpad.net/~yade-users
> > > > > Post to : yade-users@xxxxxxxxxxxxxxxxxxx
> > > > > Unsubscribe : https://launchpad.net/~yade-users
> > > > > More help : https://help.launchpad.net/ListHelp
> > > > >
> > > >
> > > > --
> > > > You received this question notification because you are a member of
> > > > yade-users, which is an answer contact for Yade.
> > > >
> > > > _______________________________________________
> > > > Mailing list: https://launchpad.net/~yade-users
> > > > Post to : yade-users@xxxxxxxxxxxxxxxxxxx
> > > > Unsubscribe : https://launchpad.net/~yade-users
> > > > More help : https://help.launchpad.net/ListHelp
> > > >
> > >
> > > --
> > > You received this question notification because you are a member of
> > > yade-users, which is an answer contact for Yade.
> > >
> > > _______________________________________________
> > > Mailing list: https://launchpad.net/~yade-users
> > > Post to : yade-users@xxxxxxxxxxxxxxxxxxx
> > > Unsubscribe : https://launchpad.net/~yade-users
> > > More help : https://help.launchpad.net/ListHelp
> > >
> >
> > --
> > If this answers your question, please go to the following page to let us
> > know that it is solved:
> > https://answers.launchpad.net/yade/+question/223478/+confirm?answer_id=4
> >
> > If you still need help, you can reply to this email or go to the
> > following page to enter your feedback:
> > https://answers.launchpad.net/yade/+question/223478
> >
> > You received this question notification because you asked the question.
> >
>
> --
> You received this question notification because you are a member of
> yade-users, which is an answer contact for Yade.
>
> _______________________________________________
> Mailing list: https://launchpad.net/~yade-users
> Post to : yade-users@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~yade-users
> More help : https://help.launchpad.net/ListHelp
>
--
You received this question notification because you are a member of
yade-users, which is an answer contact for Yade.