GithubHelp home page GithubHelp logo

Cut3d failed error about sparta HOT 12 CLOSED

aborner1 avatar aborner1 commented on May 24, 2024
Cut3d failed error

from sparta.

Comments (12)

stanmoore1 avatar stanmoore1 commented on May 24, 2024

@aborner1 thanks for the bug reports. We'll look into these.

from sparta.

stanmoore1 avatar stanmoore1 commented on May 24, 2024

@aborner1 I can reproduce this. I get a hang and this message: Cut3d failed in cell ID: 542217403. Using a printf statement I see that the error flag is:

    if (errflag == 2)
      error->one(FLERR,"EF: Singlet BPG edge not on cell face");

It is supposed to error out but it never makes it there because it hangs or segfaults in the failed_cell() function.

from sparta.

aborner1 avatar aborner1 commented on May 24, 2024

@stanmoore1 I just reproduced this bug with the latest master and it still hangs and returns the Cut3d message.

from sparta.

stanmoore1 avatar stanmoore1 commented on May 24, 2024

@sjplimp can you take a look?

from sparta.

stanmoore1 avatar stanmoore1 commented on May 24, 2024

@aborner1 did #97 fix this issue?

from sparta.

stanmoore1 avatar stanmoore1 commented on May 24, 2024

This still fails with latest master:

Step CPU Np 
       0            0        0 
     100 6.8187714e-05        0 
     200 0.00012922287        0 
     300 0.00018811226        0 
     400 0.00024700165        0 
     500 0.00030422211        0 
     600 0.0003631115        0 
     700 0.00042104721        0 
     800 0.00047922134        0 
     900 0.00053811073        0 
Cut3d failed on proc 0 in cell ID: 1073
  lo corner 0.084 0.04 0.02
  hi corner 0.0855 0.0425 0.0225
  # of surfs = 7 out of 606
  surfs: 533 0.0812961 534 0.0812961 537 0.0808713 574 0.0854356 577 0.0851887 578 0.0851887 605 0.0851887
ERROR on proc 0: EF: Singlet BPG edge not on cell face (../cut3d.cpp:611)

from sparta.

aborner1 avatar aborner1 commented on May 24, 2024

Can confirm this as well as "No positive volumes in cell" error (which I believe is related) still happen with the latest master. This is the easiest reproducer case I have ever created for this problem.

from sparta.

stanmoore1 avatar stanmoore1 commented on May 24, 2024

@aborner1 this appears to be a numerical precision issue. You are getting a triangle that is too small to be numerically meaningful. This seems to be from the sphere just barely touching the box bounds in the +/- y and z directions, which makes four minuscule triangles:

  1.96262e-17 min triangle edge length
  3.43546e-20 min triangle area

If I push out the box bounds by epsilon then it works fine:

create_box          0.06 0.09 0.01999999999999999 0.07000000000000001 0.01999999999999999 0.07000000000000001
  0.00251578 min triangle edge length
  2.74751e-06 min triangle area

from sparta.

sjplimp avatar sjplimp commented on May 24, 2024

@aborner1 @stanmoore1 Alternatively does the problem go away if the sphere is translated by an epsilon different amount so that the clipping does not produce any tiny triangles? I wonder if there is a better way to clip to avoid epsilon-size triangles?

from sparta.

stanmoore1 avatar stanmoore1 commented on May 24, 2024

@sjplimp yes translating the sphere by epsilon also works:

read_surf data.sphere scale 0.025 0.025 0.025 trans 0.09 0.04500000000000001 0.04500000000000001 clip
  0.00251578 min triangle edge length
  2.74751e-06 min triangle area

from sparta.

stanmoore1 avatar stanmoore1 commented on May 24, 2024

Translating the other way still makes tiny triangles but they are larger than epsilon, so it succeeds because it has enough numerical precision to do the calcs:

read_surf data.sphere scale 0.025 0.025 0.025 trans 0.09 0.04499999999999999 0.04499999999999999 clip
  7.37615e-17 min triangle edge length
  1.37243e-19 min triangle area

from sparta.

stanmoore1 avatar stanmoore1 commented on May 24, 2024

Fixed by #244. Closing #7.

from sparta.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.