This project generates realistic wood (Birch, Spruce, etc.) microstructures from a set of given parameters
This project includes two parts:
- Birch microstructure generation;
- Spruce microstructure generation;
- Ray cells are included in the wood structure. For birch, each group includes two columns of ray cells. Regarding to spruce, each group includes a single column of ray cells.
- The ray cells will distort the fibers nearby, to mimic the real wood growth.
- The impact of the ray cells in constraint into a small region.
- Randomness is applied on fibers, vessels, and ray cells.
- Vessels can be involved in the microstructure. There could be isolated vessels, double-vessel clusters or triple-vessel cluster.
- The fibers and vessels are distorted by the distortion map, which influences only the fibers nearby.
- Of course, the structure without vessel or ray cell can be easily generated.
- In spruce, the difference between early wood and late wood is simulated. The late fibers are compressed more, with thicker cell walls.
The generation is time-consuming for large wood structure generation. Parallel computation using a multi-core CPU is used to speed up the computation. We tried to reduce the requirement of the memory size. In our application,
Download the project and save it into a selected folder.
Read the notation of the parameters in the Matlab scripts.
RUN MainBirch.m or MainSpruce.m after setting the parameters.
If you want to quickly run the projects. Here are some notes:
-
cellWallThickis should not be too small. We recommend using value larger than 3 -
sizeVolumeshould not be too small in order to include the ray cell features in the volume. I recommend to start with 1500$\times$ 1500$\times$ 750 as a start. -
cellRis an important variable. It is roughly the radius of the fiber.
extraSZworks well in most of the cases with the default values. If the obtained final structure in the final subfolderFinalVolumeSliceincludes some white boundary, you can increase this value a bit. -
isExistRayCellis used to control whether there is any ray cell in the structure. -
isExistVesselis used to control whether there is any vessel in the structure. -
Important parameters are the vector
k = [k1,k2,k3,k4].k1>k2andk1should also close tok2. These paramerter will govern the distortion extent of the structures. To visulize the impact of these parameters, please see the distortion map in scriptplot_distortionMap.m.
The generated structure is saved in subfolder FinalVolumeSlice. The 3D volume is save as a set of 2D slices.
Some tools can be used to display and render the generated wood microstructure, such as Matlab Volume Viewer app, Slicer, Image, Commerical software Avizo.
A generated microstructure of birch

A generated microstructure of Spruce

Email: [email protected]
The authors gratefully acknowledge the support from Knut and Alice Wallenberg foundation (KAW 2021.0311) and the EU HORIZON AI-TRANSPWOOD (AI-Driven Multiscale Methodology to Develop Transparent Wood as Sustainable Functional Material) project, Grant no. 101138191, co-funded by the European Union.
Please cite our work if you use any code in this project:
Chen, Bin, et al. "A distortion-map-based method for morphology generation in multi-phase materials-application to wood." Composites Science and Technology 244 (2023): 110262..