PlatoManiac
PlatoManiac

Reputation: 1442

Parametrizing 3D geometry for shape optimization

I am trying to parametrize a 3D geometry for shape optimization. The structure looks like the following. Another real example is here.

enter image description here

Currently I am using BSplines to create the lower part and using symmetry to create the whole down part of the foil. Here is what I get. enter image description here enter image description here

Now I have many control points to take care in order to run a shape optimization. I also don't know how to join the upper part with the bottom hydrofoil part in a sensible way. I don't know how to design a good middle part of the foil (fat nose part of the foil) where the upper part is linked to. I also need to accompany a flap with in the geometry.

Please offer some suggestion for parametrization of such a surface so that we can manipulate the geometry from MMA. The less control points are there better the situation is for optimization. May be combination of some analytic function in 3D. But I doubt if that is possible.

BR

Upvotes: 3

Views: 772

Answers (1)

user1054186
user1054186

Reputation:

I think you have two choices: 1) create the second part of the geometry and then write a face-face intersection algorithm to merge them. 2) create the second part of the geometry and write two functions that return -1 if a query point is inside the geometry and +1 if it is out side (other values will do). Then use RegionPlot3D[ f1[x,y,z]<0 || f2[x,y,z]<0,....]. The idea is the to extract the GraphicsComplex and use that. The question is going to be how well you can approximate the corners with that. Here is an illustration of what I mean.

if1[x_, y_, z_] := If[x^2 + y^2 + z^2 <= 1, -1, 1]
if2[x_, y_, z_] := If[(x - 1)^2 + y^2 <= 1 && -1.5 <= z <= 1.5, -1, 1]

res = RegionPlot3D[
  if1[x, y, z] < 0 || if2[x, y, z] < 0, {x, -2, 2}, {y, -2, 
   2}, {z, -2, 2}, PlotPoints -> 100, Boxed -> False, Axes -> False]

Then extract the coords and the polygons.

coords = res[[1, 1]];
poly = Cases[res[[1]], _Polygon, Infinity];
Graphics3D[GraphicsComplex[coords, poly], Boxed -> False]

Hope this helps.

Upvotes: 2

Related Questions