3D voronoi structure with Polyhedral shape

237 views
Skip to first unread message

Tuan Nguyen

unread,
Aug 31, 2023, 3:36:16 AM8/31/23
to mumax2
Dear all, 

Recently, I would like to simulate a model that close to a polycrystalline magnet, i. e., 3D voronoi structure with irregular grain shape.
Do you think it is possible to simulate such model with hysteresis loop.

Thank everyone in advanced,
A++
Tuan NGUYEN

Josh Lauzier

unread,
Aug 31, 2023, 5:35:09 AM8/31/23
to mumax2
Hi,

The ext_make3dgrains() function sounds exactly what you're looking for, to set up the structure. As arguments, it takes grain size, starting region number, number of regions, shape, and seed. You would simply need to define your polyhedra using mumax's built in shape functions, and use it as the shape argument. Once that the geometry and material parameters are set, a hysteresis loop can be done as with any other script. There is an example of a hysteresis loop provided on the examples page.

You might also find the 'voronoi tessellation' example useful, it shows how to set material parameters for different grains. That procedure can be adapted straightforwardly to the 3D case.

Best,
Josh L.

Message has been deleted

Tuan Nguyen

unread,
Sep 11, 2023, 12:17:46 PM9/11/23
to mumax2
Dear Josh Lauzier,

I greatly appreciate your suggestion. I already got such interesting voronoi structure. I would like to insert the grain boundaries between grains in the voronoi tessellation. Could you please give me ideas/suggestion for that.

With Kindest Regards,
A++

Josh Lauzier

unread,
Sep 11, 2023, 1:32:36 PM9/11/23
to mumax2
Hi,

Unfortunately mumax does not have a good way to do that, that I know of. The easiest way to simulate grain boundaries is to e.g. weaken the exchange between grains using ext_ScaleExchange(). This would account for the grain boundaries implicitly.

In order to explicitly consider grain boundaries, when I did it, what I did was write a separate python/matlab script. You can save a copy of the regions.OVF with the voronoi tessellation done by mumax, and then import the OVF data as a matrix. Then you would want to write a script that looks for 2 cells with different region numbers (which indicates a grain boundary). When it does this, it replaces x cells in each direction with a new region value, and this new region can be set to act as a grain boundary. The number x of cells replaced would correspond to the thickness of the grain boundary. 

Instead of just going x cells in each direction, I replaced every cell in a circle (in 3-D, a sphere) around the grain boundary point. This probably isn't necessary, but it gave smoother edges, which seemed more realistic in my case.

The algorithm itself is pretty straightforward, but it can be difficult to restrict yourself to the 256 region limit. I had to use a lot of little tricks to reuse regions. Unfortunately the 256 limit is a hard limit, unless you're willing to recompile mumax.

Best,
Josh L.

Reply all
Reply to author
Forward
Message has been deleted
0 new messages