yade-users team mailing list archive
-
yade-users team
-
Mailing list archive
-
Message #03635
Re: String Argument Error
> I’m a new yade user & was experimenting with yade-0.50 when I ran into
> the following problem while trying to implement a variation of the
> examples in the user manual:
Hi Ken,
please do not contact me directly, use the
yade-users@xxxxxxxxxxxxxxxxxxx list for such questions so that other
people might reply or read the answer from archives later
(https://yade-dem.org/sphinx/user.html#mailing-lists)
> Yade [3]: for i in range(21):
>
> ...: O.bodies.append([utils.sphere([0,0,i],1)])
This is a shorter way:
O.bodies.append([utils.sphere([0,0,i],1) for i in range(21)])
> Yade [4]: intradius=1.5
>
> Yade [5]: O.engines=[ForceResetter()]
>
> Yade [6]: O.engines=O.engines
> +[BoundDispatcher(Bo1_Sphere_Aabb(aabbEnlargeFactor=intradius))]
Bound dispatcher takes _list_ of functors. That line must read
BoundDispatcher([Bo1_Sphere_Aabb(aabbEnlargeFactor=intradius)])
It is more efficient to assign O.engines at once:
O.engines=[ForceResetter(),BoundDispatcher([...]),...]
(See also simulations in the examples directory, for more complicated
stuff.)
> RuntimeError: First argument (if given) must be a string.
(This message is somewhat confusing (although true) and it was fixed in
the development version of yade.)
Cheers, Václav
> This email is confidential and may be privileged. If you are not the intended recipient, please delete it and notify us immediately.
> Please do not copy it or use it for any purpose, or disclose its contents to any other person. Thank you.
?!
Follow ups