← Back to team overview

yade-users team mailing list archive

Re: [Question #688822]: Exporting a packing geometry made in yade in a stl format

 

Question #688822 on Yade changed:
https://answers.launchpad.net/yade/+question/688822

Jan Stránský proposed the following answer:
> - How do you triangulate the spherical packing ??

depending on the meaning of a question:

1) triangulate it such that it suits your needs in comsol

2)
def triangulateOneSphere(b):
   ...
   return triangles
triangles = [triangulateOneSphere(b) for b in O.bodies]

triangulateOneSphere: google "sphere triangulation", depends on how fine
you want/need the triangulation

> - "save triangles": do you mean i have to build by hands the stl file
as explained in wikipedia i.e. save as a "built up" text file ???

yes. There might be some python stl library for easier processing

Before continuing:
- why do you want to use comsol (what is the background)? is there an alternative, like Paraview?
- is there another file format / method you can use more naturally (than triangulating spheres)? Like [1]?

cheers
Jan

https://www.comsol.com/forum/thread/211861/input-geometry-from-
coordinates

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.