Import STL Geometry with a lattice Structure for tetmesher

Hi,

We are trying to tet mesh a union geometry that incorporates a large rectangle with a lattice structure, which I can share with you by email. This geometry is fixed and remeshed to a fine small equilateral triangles using Polygonica API. Then it’s imported into cubit and it imports just fine with feature angle 135 and stich and either quadratic/spline/linear interpolation. However, meshing keeps on failing.
Below is actually the log of cubit for this geometry case.

It seems that some of the surfaces generated are very small the size of triangles.

Journaled Command: set logging on file “sim3/submodel_Mon_Mar__6_13_02_00_2023/conformal_mesh/logfile.log”

Reading facets…
1261988 facets read.
Building facet-based geometry from 1261988 facets…
Body successfully created.
Number of new vertices = 1698
Number of new curves = 2165
Number of new surfaces = 709
Number of new shells = 1
Number of new volumes = 1
Number of new bodies = 1
Geometry engine set to: Facet Geometry Engine version 10.0.0
Journaled Command: import stl “/sim3/submodel_Mon_Mar__6_13_02_00_2023/conformal_mesh/remesh.stl” feature_angle 135 merge stitch

The maximum span for an interval on an arc is set to 90.000000 degrees.
Journaled Command: set maximum arc_span 90

Journaled Command: set trimesher geometry sizing off

Journaled Command: volume 1 size 0.4

Journaled Command: volume 1 scheme tetmesh

Added Volume 1 to block 1
Journaled Command: block 1 vol 1

Journaled Command: block 1 element type TETRA10

Matching intervals successful.
Begin tri meshing 709 surfaces 1 to 709
WARNING: MeshGems has problem meshing surfaces 551 695 635 414 638 374 378 210 601 440 519 607 441 634 393 439 431 379 535 491 550 134 373 504 536 432 642 480 417 392 658 499 1 404 494 43 628 355 657 387 700 386 484 482 529 328 543 424 633 208 538 696 537 209 706 641 637 699 247 685 517 708 553 329 259 199 476 692 709 86 531 676 458 549 672 593 465 686 691 533 485 510 636 541 479 552 684 515 509 548 707 532 693 505 488 326 126 325 516 407 372 368 21 250 579 129 644 571 87 344 646 701 623 166 608 96 68 398 413 420 198 9 200 151 645 622 350 694 568 493 349 566 327 647 399 412 128 421 600 354 697 471 627 630 20 312 651 648 165 95 435 534 271 678 557 688 451 311 518 511 513 483 15 380 5 698 590 544 575 337 303 139 10 323 351 539 570 7 598 671 366 613 477 256 524 705 616 321 358 565 67 363 585 559 540 213 666 664 201 680 606 687 345 434 438 24 50 604 528 679 348 567 470 285 530 377 430 229 195 3 294 283 120 340 558 626 186 629 656 248 677 594 654 18 174 371 681 184 101 454 130 131 660 164 138 683 661 667 605 609 702 132 191 463 51 577 665 394 478 395 224 376 469 542 437 429 317 653 260 612 639 603 388 588 591 619 617 690 466 592 673 449 614 587 460 264 486 481 503 66 218 409 100 347 569 502 467 196 416 12 25 547 180 655 183 159 382 103 98 99 22 620 610 523 450 589 525 188 446 447 343 236 375 618 258 143 652 643 621 584 468 204 663 364 170 78 631 341 301 574 116 249 674 578 367 649 448 257 560 396 142 23 6 545 182 189 659 455 406 11 381 157 4 145 167 173 135 73 94 178 436 245 155 339 650 675 365 298 281 114 33 320 640 185 121 359 546 136 58 595 56 599 122 270 123 586 19 107 235 49 602 225 272 362 527 512 275 302 342 333 228 292 632 39 255 277 42 582 689 109 562 400 422 411 192 370 221 498 65 93 90 241 119 60 472 442 521 405 148 462 269 262 310 315 453 554 308 556 31 313 330 251 360 361 244 508 144 89 322 265 682 428 44 464 443 522 217 473 216 576 71 704 296 77 168 489 703 403 171 45 203 662 230 16 419 496 324 487 624 625 500 14 357 335 300 573 28 384 115 106 227 280 110 233 61 295 179 252 8 187 97 181 104 238 55 243 57 297 279 474 29 113 108 226 234 48 456 70 205 266 59 239 30 284 117 293 211 54 242 240 669 286 356 346 352 287 457 391 190 223 193 334 91 64 88 615 219 197 215 152 319 445 369 520 444 153 459 146 214 263 267 353 237 253 597 175 53 670 156 426 160 158 385 220 318 82 596 668 202 172 79 169 76 232 47 161 418 83 163 212 149 490 507 526 177 254 75 290 338 246 46 231 62 336 291 276 32 383 611 102 278 423 514 492 506 118 127 84 162 74 401 194 222 92 63 415 425 268 261 147 461 36 41 583 563 495 299 572 497 410 390 206 433 140 501 427 124 141 125 13 475 402 397 207 309 555 331 314 408 389 37 52 564 581 452 307 316 305 26 274 112 288 282 561 580 111 273 27 289 306 332 17 304 176 154 150 133 137 80 85 72 34 81 38 105 69 35 40 2
WARNING: Warning : 42 intersection(s) may be still present in the resulting mesh
WARNING: You may have overlapping surfaces you are trying to mesh. Meshgems does not mesh overlapping surfaces in the same meshing operation. Consider doing a ‘find overlap’ check and meshing these surfaces separately.
Completed trimeshing 709 surfaces
WARNING: Found duplicate tri with nodes 1227 4 2530
ERROR: Unable to mesh boundary
ERROR: Volume 1 meshing unsuccessful using scheme: tetmesh
Meshing time: 207.010000

ERROR: 1 volume did not mesh : Volume 1

Although some entities failed to mesh, Cubit will log the command in the journal file anyway, for future use.
Journaled Command: mesh volume 1

Added Volume 1 to block 1
Set name of block 1 to “PartToPrint”
Journaled Command: block 1 add vol 1 name “PartToPrint”

WARNING: Could not find any entities matching input

This may be one problem.

Somehow the surfaces are overlapping and you are creating two triangles with the same nodes. This will cause the tetmesher to fail.

Try doing find surface overlap volume all. This command should work for facet based geometry as well as traditional ACIS geometry.

Thanks,
Karl

Hi Karl,

Thank you for your prompt reply. So, I tried the command and the command returned no surfaces. I uploaded the file to this link for you so you can download and take a look yourself here: Download files - Filemail
I hope you can help us resolve this as this is very important for FEA submodeling to better assess the possibility of crack in AM.

Thanks.

Hi Amir,

I tried just meshing the surfaces.

surface all scheme trimesh
mesh surface all

Cubit reported that surface 423 could not be meshed.

Looking down the +X axis (keyboard shortcut F11) surface 423 is a capped surface in the middle.
image

Zooming in on this surface it looks like there are some issues with the capping in that area.

In transparent mode I can see that there are some internal features there that don’t create a proper boundary.

image

Karl

Hi Amir,

It looks like the backside of that area may be the problem. It appears to me that there are two surfaces that extend from the surface into the volume creating a non-manifold geometry. Those likely need to be cleaned up in Polygonica.

Karl

Yeah, I see that. I am working on fixing it and trying it again thanks for the find.

Amir,

Just for fun I took you model as is and ran the sculpt algorithm on it. Using an auto size of 5 it created ~1.5M nodes and ~1.3M hex elements. The element quality is reasonable with a scaled jacobian of 0.25.

In a part without a lot of sharp features, this could also be an alternative way to generate a mesh. Note that the sharp edges do get lost at the base but I wouldn’t think that is a critical feature for you.

Karl

Hi,

Thanks very much. This looks very promising to us.

I have a few additional questions concerning this hex mesh you generated:

  1. How is this hex meshing algorithm called from python command and from the cubit GUI?
  2. What is the mesh size you used?
  3. Will this work all the time for any size or did you have to use a very small size?
  4. What happened to those foldover internal faces? Do they get approximated out or they also get meshed?

Thanks.

As far as your first question goes, you may be interested to see this previous post I made describing my preferred Sculpt workflow:

Hi Amir,

  1. I used an “Auto Cell Size” of 5 which corresponds to a size of ~0.04.
  2. The Sculpt algorithm will you give a mesh for different sizes. Doubling the original size, I still get a reasonable mesh. A very large mesh size may result in gaps or a mesh that doesn’t approximate the geometry well. The surfaces could get very “bumpy.”
  3. The algorithm works by calculating volume fractions on the volume and determining cells that are interior, exterior, boundary. Holes smaller than the mesh size or internal surfaces get washed out in the process.

Karl