Aggregate Packing Generator 2 with STL File

Aggregate packing generator used for the simulation of aggregate in composites and creates STL file
6 Downloads
Updated 14 Nov 2023

View License

Aggregate packing generator used for the simulation of aggregate in composites. Then, STL file is created for the generated aggregate. It can be used especially for meso-scale analysis of concrete and asphalt composites .Example file is provided for the simulation of hollow cylinder "Example.m"
Important Notes:
1-This tool requires stlwrite function (tested with version 1.9.0.0). The user should download it and put the file in the same folder of this tool. The link for stlwrite function is:
2-Newer versions of matlab have builtin function stlwrite function introduced in R2018b. The user can use it instead of the function in mentioned above by replacing the following line in Aggregate2STL.m:
stlwrite(Filename,FF,VV);
with:
TR = triangulation(FF,VV); stlwrite(TR,Filename);
functions:
1-Classes=Particles_Generation2(x,y,z,x2,y2,z2,Classes_diameters,Classes_particle_ratios,m)
Generates aggregates according to defined volumetric ratios for each diameter.
2-function Ellipsoids=Particles_Distribution2(Classes,x,y,z,x2,y2,z2,er)
Generates aggregate with ellipsoids shapes
3-function Plot_Ellipsoids(Ellipsoids,x,y,z)
Plots ellipsoids
4-function Aggregate2STL(Ellipsoids,Filename)
Creates STL file
where the variables defined as:
input:
x,y,z: as vectors defining the specimen dimension. x and y are vectors defining a polygon section in xy plane and z=[zmin zmax] is boundaries of the extrusion of the polygon
x2,y2,z2: as vectors defining the hole dimension to be substracted from the shape of (x,y,z). x2 and y2 are vectors defining a polygon section in xy plane and z2=[zmin2 zmax2] is boundaries of the extrusion of the polygon
Classes_diameters: Particles classes diameters vector (descendingly)
Classes_particle_ratios: Particles volumetric ratio for each class (descendingly)
m: Particles shape distribution factor. m=1 for spheres and m>>1 for elongated ellipsoid shapes.
er: Spacing factor between particles to avoid contact [0.05-0.1].
Filename: name of the STL file with the extension.
Output:
Classes: A variable containing generated particles and not yet packed into specimen
Ellipsoids: (N*9) array. each column represent:
(:,1): radius of ellipsoids at direction 1
(:,2): radius of ellipsoids at direction 2
(:,3): radius of ellipsoids at direction 3
(:,4): x-cooridante of centroid
(:,5): y-coordinate of centroid
(:,6): z-coordinate of centroid
(:,7): Inclination angle 1
(:,8): Inclination angle 2
(:,9): Inclination angle 3
references
[1] Unger, Jörg F., and Stefan Eckardt. "Multiscale modeling of concrete." Archives of Computational Methods in Engineering18.3 (2011): 341.

Cite As

Ayad Al-Rumaithi (2024). Aggregate Packing Generator 2 with STL File (https://www.mathworks.com/matlabcentral/fileexchange/155102-aggregate-packing-generator-2-with-stl-file), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2023b
Compatible with any release
Platform Compatibility
Windows macOS Linux
Tags Add Tags

Community Treasure Hunt

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

Start Hunting!
Version Published Release Notes
1.0.0