Hi, I have successfully create 2D NACA airfoils using the help given below:
Now, I’m thinking of creating a 3D wing. For a start, I just want to do a simple wing with NACA profile. Also, the objective is to be able to do parametric analysis similar to the 3D fin case.
So if I’m importing STL thru pySDF, it may not be easy to parameterize later on.
For the 3D fin, it is using the box function to create the 3D fin. Is it feasible to create a new function for the 3D wing based on the box function? Or can the polygon function using in the 2D airfoil be used in a modified function to create a 3D wing?
Hope someone can help. Thanks!
Creating a parameterized CSG can be pretty challenging if the geometry strays far from the built in primitives. It’s theoretically possible yes, but can be very challenging to set up for shapes that stray aware from the built in primitives. Additionally, the polygon primitive has some limitations in terms of scaling to finer resolutions (sampling becomes slow).
Thus typically we suggest people use parameterization based a discrete set of STL files. The idea here is to create a set of STL files each representing a sample in your parameterization range. You can then import them all and set up the respective parameters for sampling. An example of this is found our examples repo.
Thanks for the tips. Btw, I found some equations for airfoils, defined parametrically. I understand that besides the parametric eqns, I have to provide the normal x/y, area, sdf and bounds. When you mention “challenging”, do you mean that it’s difficult to obtain the corresponding eqns? Or that it will be slow like the polygon primitive? Are normal x/y, area, sdf compulsory?
Nevertheless, I’ll check out the repo. Strange that I’m getting block at the moment:
Your account is blocked
We’ve detected suspicious activity on your account.
I will check again in the next few days.
When you mention “challenging”, do you mean that it’s difficult to obtain the corresponding eqns? Or that it will be slow like the polygon primitive? Are normal x/y, area, sdf compulsory?
If you can construct the geometry from a set of primitives (like spheres, rectangles, etc.) then CSG is a great approach, but this is the challenging part if you do not know this. But most 3D objects people tend want to try are complex in geometry. Even if it can be reconstructed with CSG but requires a lot of primitives, it can take a long time to sample training points. Additionally because its up to the user to essentially build the geometry in a python script (not a 3D Cad software) complex CSG can take a long time to setup/debug.
But it is possible. We have done it before. So its really depends on your priorities.
Nevertheless, I’ll check out the repo. Strange that I’m getting block at the moment
Hmmm, okay. If its specific to the Modulus repo let us know. If its related to your entire Gitlab account, I would seek help from Gitlab’s side of things.
I have managed to get the code thru Gitlab. Can I check if this code require pysdf? I have a hard time trying to get pysdf to work on the systems I use - school clusters, saturn cloud.
Most don’t allow the use of docker directly. And it seems that converting to singularity prevents pysdf from running correctly.
In this case, is there any other alternatives to import stl files?
Thanks and Merry Christmas!
Unfortunately that’s the only method we offer STL support right now for training points. There is some VTK support but we dont support creating training points from a VTK file like we do with STL files via pysdf.