How to fill a volume with spheres?

조회 수: 4 (최근 30일)
bob
bob 2012년 11월 5일
편집: DGM 2025년 4월 6일
Hi,
I'd like to import *.stl files of different shapes and fill the volume with overlapping spheres. How can I do it. I already did this task for 2D shapes using bwdist. But for 3D shapes, I don't know how to do it. Thanks
  댓글 수: 4
Walter Roberson
Walter Roberson 2017년 3월 28일
chen xiaoyu: then I would put the same question to you: since the spheres are overlapping, what is your constraint that keeps the volume finite, or the number of spheres finite?
Are the spheres permitted to overlap the edges of the 3D area?
By the way, what will you do with the filled areas?
DGM
DGM 2025년 4월 5일
편집: DGM 2025년 4월 6일
This sounds like OP is (was) trying to do the equivalent of a morphological opening of the volume, but without actually saying so. I guess that'd be the Minkowski sum of the Minkowski difference, both with the same sphere.
If true, how would one do it? You'd either use external tools (perhaps through GPToolbox), or you'd reinvent that wheel on your own. I used OpenSCAD, which uses the same CGAL library that GPToolbox would use.
What information would this return? It would return a shape. It wouldn't tell us anything about an optimal sphere packing, just what portions of the volume could be occupied by a sphere.
EDIT: I went and read OP's other questions, and I'm half-convinced that this was the goal, and half-convinced that it certainly wasn't the goal. It's unclear whether it's the "irregularly-shaped volume" is the particle or the container (or whether there's even a container).

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by