Resource Menu


posted by Jean-Charles Mateo-Velez at Jan 25, 2016 10:29 AM
Quote
Hi, indeed the classical way of doing CAD and mesh with SPIS is to edit the CAd directly with gmsh. There are some current developments for importing extra formats but not available so far. So the best is to use gmsh editor and code line.

posted by T. at Jan 23, 2016 7:41 PM
Quote
Hmm, so after a lot of experimentation I think I was doing a couple things wrong. The biggest of which was not including the inner boundary when defining the physical volume group. This probably lead to some "out of bounds" errors I was seeing (?).

My goal was to edit geometries in solidworks, export them as an STL or STEP, then import that into Gmsh. I find that the imported files aren't really "complete", in that there are points defining the edges of the objects. For example, I make a cylinder by revolving a curve. Gmsh only sees the original curve.

How do most people edit geometries? Directly in the Gmsh editor? In code?

Thanks for any suggestions.

posted by T. at Jan 23, 2016 5:21 AM
Quote
Yikes, that came out ugly. Sorry.
posted by T. at Jan 23, 2016 5:16 AM
Quote
Hi,

I'm trying to make my own geo file by exporting a STEP file from CAD software. It's simply a cubic spacecraft in a cubic volume. Although I believe I made the geo file look like the example from the docs, I keep getting this error:

Ooops! There was an error while initializing the numerical kernel. Please report it to the development team or on SPIS bug tracker. Do not forget to include the debug.txt file at the root of the software. Stacktrace: java.lang.NullPointerException at spis.Vol.VolMesh.ThreeDUnstructVolMesh.mapToInternalNodeIndexing(ThreeDUnstructVolMesh.java:2293) at spis.Vol.VolMesh.ThreeDUnstructVolMesh.mapToInternalNodeIndexing(ThreeDUnstructVolMesh.java:2380) at spis.Vol.VolMesh.ThreeDUnstructVolMesh.setInternNodeNumbering(ThreeDUnstructVolMesh.java:2465) at spis.Solver.Poisson.ConjGrad3DUnstructPoissonSolver.init(ConjGrad3DUnstructPoissonSolver.java:341) at spis.Solver.Poisson.ConjGrad3DUnstructPoissonSolver.<init>(ConjGrad3DUnstructPoissonSolver.java:185) at spis.Top.Simulation.SimulationFromUIParams.init(SimulationFromUIParams.java:933) at spis.Top.Simulation.SimulationFromUIParams.<init>(SimulationFromUIParams.java:438) at spis.Top.Top.NumTopFromUI.<init>(NumTopFromUI.java:157) at org.spis.ui.ui2num.util.Ui2Num.buildNumTopFromUI(Ui2Num.java:355) at org.spis.ui.ui2num.command.NumTopFromUICommand.run(NumTopFromUICommand.java:162) at org.spis.ui.ui2num.command.NumTopFromUICommand.run(NumTopFromUICommand.java:52) at org.keridwen.core.messaging.AbstractCommand.execute(AbstractCommand.java:200) at org.keridwen.core.messaging.DefaultBundleController$CallableCommand.call(DefaultBundleController.java:260) at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) at java.util.concurrent.FutureTask.run(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) at java.lang.Thread.run(Unknown Source)

This is the geo file I made:

cl__1 = 1; cl__2 = 2;

// external boundary Point(1) = {-10, 10, -10, cl__2}; Point(2) = {-10, 10, 10, cl__2}; Point(3) = {-10, -10, -10, cl__2}; Point(4) = {-10, -10, 10, cl__2}; Point(5) = {10, -10, -10, cl__2}; Point(6) = {10, -10, 10, cl__2}; Point(7) = {10, 10, 10, cl__2}; Point(8) = {10, 10, -10, cl__2};

// spacecraft boundary Point(9) = {1, 2, -1, cl__1}; Point(10) = {-1, 2, -1, cl__1}; Point(11) = {1, -2, -1, cl__1}; Point(12) = {-1, -2, -1, cl__1}; Point(13) = {1, -2, 1, cl__1}; Point(14) = {-1, -2, 1, cl__1}; Point(15) = {-1, 2, 1, cl__1}; Point(16) = {1, 2, 1, cl__1}; Line(1) = {1, 2}; Line(2) = {3, 1}; Line(3) = {3, 4}; Line(4) = {4, 2}; Line(5) = {5, 3}; Line(6) = {5, 6}; Line(7) = {6, 4}; Line(8) = {7, 2}; Line(9) = {6, 7}; Line(10) = {8, 1}; Line(11) = {5, 8}; Line(12) = {8, 7}; Line(13) = {9, 10}; Line(14) = {11, 9}; Line(15) = {11, 12}; Line(16) = {12, 10}; Line(17) = {13, 11}; Line(18) = {13, 14}; Line(19) = {14, 12}; Line(20) = {15, 10}; Line(21) = {14, 15}; Line(22) = {16, 9}; Line(23) = {13, 16}; Line(24) = {16, 15}; Line Loop(1) = {1, -4, -3, 2}; Plane Surface(1) = {1}; Line Loop(2) = {5, 3, -7, -6}; Plane Surface(2) = {2}; Line Loop(3) = {8, -4, -7, 9}; Plane Surface(3) = {3}; Line Loop(4) = {10, -2, -5, 11}; Plane Surface(4) = {4}; Line Loop(5) = {12, -9, -6, 11}; Plane Surface(5) = {5}; Line Loop(6) = {10, 1, -8, -12}; Plane Surface(6) = {6}; Line Loop(7) = {13, -16, -15, 14}; Plane Surface(7) = {7}; Line Loop(8) = {17, 15, -19, -18}; Plane Surface(8) = {8}; Line Loop(9) = {20, -16, -19, 21}; Plane Surface(9) = {9}; Line Loop(10) = {22, -14, -17, 23}; Plane Surface(10) = {10}; Line Loop(11) = {24, -21, -18, 23}; Plane Surface(11) = {11}; Line Loop(12) = {22, 13, -20, -24}; Plane Surface(12) = {12};

//Surface Loop(1) = {1, 2, 3, 4, 5, 6}; //Volume(1) = {1}; //Surface Loop(2) = {7, 8, 9, 10, 11, 12}; //Volume(2) = {2};

Surface Loop(1) = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12}; Volume(1) = {1};

Physical Surface(25) = {1, 2, 3, 4, 5, 6}; Physical Surface(27) = {10, 7, 8, 9, 12, 11}; Physical Volume(26) = {1};

Thanks!