Step file import of trimmed NURBS surfaces

Reads geometries from .stp/.step files. The type of geometries are NURBS surfaces. Multiple patches and trimmed patches are recognized.
379 téléchargements
Mise à jour 19 nov. 2024

Afficher la licence

Get started
The easiest way to test the provided code is to run the script "test_step_import". Plotting functions are illustrating your import and help to check whether the import worked correctly. A set of really simple geometries is provided - they start with "geometry_". The import was also tested for more complex geometries. However, these files cannot be provided due to licensing reasons.
Import function
The main contribution is the step import function "import_STEP.m". It reads a geometry from a .stp/.step file. The type of geometry is limited to NURBS surfaces (including B-splines of course). Multiple patches and trimmed patches are recognized. The aim of the code is to make the NURBS description of geometries created in CAD available and usable in Matlab.
Plotting of imported geometry
When running the script "test_step_import", you see automatically plots in the parametric and physical space. Thereby, you can easily check whether your import worked correctly. You can change the resolution of the plots:
resolution_param = 10; % resolution of trimming curves in the parametric space
resolution_phys.surf = 2; % resolution of surfaces in the physical space
resolution_phys.curv = 10; % resolution of curves in the physical space
Creating a step file
I created my step files with Rhino 7, but hopefully every other CAD software should work as well. Important is that the parametric description of your trimming curves is included in the step file. In Rhino, this is an extra option in the export menu. Furthermore, I select the AP214 AutomativeDesign format when exporting my geometries.
Problems with your import
In case your geometry cannot be imported but is a NURBS surface, please contact me. I can try to extend the import function for your geometry.

Citation pour cette source

Michael Loibl (2024). Step file import of trimmed NURBS surfaces (https://www.mathworks.com/matlabcentral/fileexchange/123425-step-file-import-of-trimmed-nurbs-surfaces), MATLAB Central File Exchange. Extrait(e) le .

Compatibilité avec les versions de MATLAB
Créé avec R2022b
Compatible avec les versions R2006a à R2022b
Plateformes compatibles
Windows macOS Linux
Remerciements

Inspiré par : Plot 2D/3D Vector with Arrow

Community Treasure Hunt

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

Start Hunting!
Version Publié le Notes de version
1.1.1

More robust for different spacing between lines in step file.

1.1.0

Bug fix: The edges of closed cylinders were falsely detected.

New plotting features.

1.0.1

See release notes for this release on GitHub: https://github.com/MichaelLoibl/step_file_import/releases/tag/v1.0.1
See release notes for this release on GitHub: https://github.com/MichaelLoibl/step_file_import/releases/tag/v1.0.1

1.0.0