Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when aux depends on block restricted aux #9734

Closed
tophmatthews opened this issue Aug 24, 2017 · 5 comments · Fixed by #21045
Closed

Error when aux depends on block restricted aux #9734

tophmatthews opened this issue Aug 24, 2017 · 5 comments · Fixed by #21045
Labels
C: Framework P: normal A defect affecting operation with a low possibility of significantly affects. T: defect An anomaly, which is anything that deviates from expectations.

Comments

@tophmatthews
Copy link
Contributor

Description of the enhancement or error report

When an aux depends on a block restricted aux, a moose assertion is thrown when executing in dbg:

Assertion `i < _size' failed
Access out of bounds in MooseArray (i: 0 size: 0)

Rationale for the enhancement or information for reproducing the error

The simplest input deck can be run with any dbg executable:

[Mesh]
  type = GeneratedMesh
  nx = 2
  ny = 2
  dim = 2
[]

[MeshModifiers]
  [./split]
    type = SubdomainBoundingBox
    block_id = 1
    bottom_left = '0 0 0'
    top_right = '0.5 0.5 0.5'
  [../]
[]

[Variables]
  [./var]
  [../]
[]

[AuxVariables]
  [./u]
    block = '0 1'
  [../]
  [./v]
    block = 1
  [../]
[]


[Kernels]
  [./var]
    type = TimeDerivative
    variable = var
  [../]
[]

[AuxKernels]
  [./u_aux]
    type = ParsedAux
    variable = u
    args = v
    function = v
  [../]
  [./v_aux]
    type = ConstantAux
    variable = v
  [../]
[]

[Executioner]
  type = Transient
[]

Identified impact

Is seems that this should throw a descriptive error, and perhaps not even work in opt? This will help prevent errors and help debugging.

@permcody
Copy link
Member

permcody commented Aug 25, 2017 via email

@permcody permcody added C: Framework P: normal A defect affecting operation with a low possibility of significantly affects. T: defect An anomaly, which is anything that deviates from expectations. labels Aug 28, 2017
@tophmatthews
Copy link
Contributor Author

tophmatthews commented Aug 22, 2019

Fixed somewhere along the way:

*** ERROR ***
The 'block' parameter of the object 'u_aux' must be a subset of the 'block' parameter of the variable 'v':
    Object 'u_aux': 0, 1
    Variable 'v': 1

@tophmatthews
Copy link
Contributor Author

this still happens in AD

Assertion `i < _size' failed
Access out of bounds in MooseArray (i: 0 size: 0)
at /Users/topher/projects/moose/framework/build/header_symlinks/MooseArray.h, line 268
Stack frames: 35
0: 0   libmesh_dbg.0.dylib                 0x000000011f26f07a libMesh::print_trace(std::__1::basic_ostream<char, std::__1::char_traits<char> >&) + 458
1: 1   libmoose-dbg.0.dylib                0x0000000111582ab7 MooseArray<libMesh::VectorValue<MetaPhysicL::DualNumber<double, MetaPhysicL::NumberArray<50ul, double> > > >::operator[](unsigned int) + 935
2: 2   libmoose-dbg.0.dylib                0x0000000111be5083 Assembly::computeSinglePointMapAD(libMesh::Elem const*, std::__1::vector<double, std::__1::allocator<double> > const&, unsigned int, libMesh::FEGenericBase<double>*) + 4179
3: 3   libmoose-dbg.0.dylib                0x0000000111be3392 Assembly::computeAffineMapAD(libMesh::Elem const*, std::__1::vector<double, std::__1::allocator<double> > const&, unsigned int, libMesh::FEGenericBase<double>*) + 82
4: 4   libmoose-dbg.0.dylib                0x0000000111bee103 Assembly::computeADFace(libMesh::Elem const*, unsigned int) + 691
5: 5   libmoose-dbg.0.dylib                0x0000000111bedddf Assembly::reinitFEFace(libMesh::Elem const*, unsigned int) + 1839
6: 6   libmoose-dbg.0.dylib                0x0000000111bf74e9 Assembly::reinit(libMesh::Elem const*, unsigned int) + 1385
7: 7   libmoose-dbg.0.dylib                0x00000001119f8393 GeometricSearchData::updateQuadratureNodes(unsigned int) + 339
8: 8   libmoose-dbg.0.dylib                0x00000001119f7cdf GeometricSearchData::update(GeometricSearchData::GeometricSearchType) + 463
9: 9   libmoose-dbg.0.dylib                0x000000011113c772 DisplacedProblem::updateMesh() + 1218
10: 10  libmoose-dbg.0.dylib                0x0000000111188402 FEProblemBase::computeJacobianTags(std::__1::set<unsigned int, std::__1::less<unsigned int>, std::__1::allocator<unsigned int> > const&) + 1506
11: 11  libmoose-dbg.0.dylib                0x0000000111187d89 FEProblemBase::computeJacobianInternal(libMesh::NumericVector<double> const&, libMesh::SparseMatrix<double>&, std::__1::set<unsigned int, std::__1::less<unsigned int>, std::__1::allocator<unsigned int> > const&) + 217
12: 12  libmoose-dbg.0.dylib                0x0000000111187ca2 FEProblemBase::computeJacobian(libMesh::NumericVector<double> const&, libMesh::SparseMatrix<double>&) + 258
13: 13  libmoose-dbg.0.dylib                0x0000000111187a78 FEProblemBase::computeJacobianSys(libMesh::NonlinearImplicitSystem&, libMesh::NumericVector<double> const&, libMesh::SparseMatrix<double>&) + 56
14: 14  libmoose-dbg.0.dylib                0x0000000111782d92 Moose::compute_jacobian(libMesh::NumericVector<double> const&, libMesh::SparseMatrix<double>&, libMesh::NonlinearImplicitSystem&) + 146
15: 15  libmesh_dbg.0.dylib                 0x000000011fdf38e3 libmesh_petsc_snes_jacobian + 2323
16: 16  libpetsc.3.10.dylib                 0x00000001170143fa SNESComputeJacobian + 874
17: 17  libpetsc.3.10.dylib                 0x0000000117047b3f SNESSolve_NEWTONLS + 1375
18: 18  libpetsc.3.10.dylib                 0x0000000117019205 SNESSolve + 1717
19: 19  libmesh_dbg.0.dylib                 0x000000011fdf2236 libMesh::PetscNonlinearSolver<double>::solve(libMesh::SparseMatrix<double>&, libMesh::NumericVector<double>&, libMesh::NumericVector<double>&, double, unsigned int) + 3462
20: 20  libmesh_dbg.0.dylib                 0x000000011fe7c59d libMesh::NonlinearImplicitSystem::solve() + 621
21: 21  libmoose-dbg.0.dylib                0x000000011199dead TimeIntegrator::solve() + 45
22: 22  libmoose-dbg.0.dylib                0x0000000111783f91 NonlinearSystem::solve() + 1073
23: 23  libmoose-dbg.0.dylib                0x000000011118422d FEProblemBase::solve() + 173
24: 24  libmoose-dbg.0.dylib                0x0000000110d6f7d4 FEProblemSolve::solve() + 36
25: 25  libmoose-dbg.0.dylib                0x0000000110d750d0 PicardSolve::solveStep(double, double&, double, double&, bool, std::__1::set<unsigned int, std::__1::less<unsigned int>, std::__1::allocator<unsigned int> > const&) + 1808
26: 26  libmoose-dbg.0.dylib                0x0000000110d73680 PicardSolve::solve() + 3360
27: 27  libmoose-dbg.0.dylib                0x00000001116045c4 TimeStepper::step() + 52
28: 28  libmoose-dbg.0.dylib                0x0000000110d7b0d3 Transient::takeStep(double) + 275
29: 29  libmoose-dbg.0.dylib                0x0000000110d7a824 Transient::execute() + 148
30: 30  libmoose-dbg.0.dylib                0x0000000111c3a82f MooseApp::executeExecutioner() + 239
31: 31  libmoose-dbg.0.dylib                0x0000000111c3b4f1 MooseApp::run() + 337
32: 32  bison-dbg                           0x000000010a6ec484 main + 372
33: 33  libdyld.dylib                       0x00007fff7002b3d5 start + 1
34: 34  ???                                 0x0000000000000005 0x0 + 5
[0] /Users/topher/projects/moose/framework/build/header_symlinks/MooseArray.h, line 268, compiled Aug 23 2019 at 14:26:08
application called MPI_Abort(MPI_COMM_WORLD, 1) - process 0
[unset]: write_line error; fd=-1 buf=:cmd=abort exitcode=1

@tophmatthews tophmatthews reopened this Aug 23, 2019
@tophmatthews
Copy link
Contributor Author

I'll try and figure out a good input file

@tophmatthews
Copy link
Contributor Author

It's something with GapHeatTransfer with quadrature=true...

lindsayad added a commit to lindsayad/moose that referenced this issue May 17, 2022
Makes sure that variable dependencies have degrees of freedom on
all nodes along the boundaries of a boundary restricted object

Closes idaholab#9734
lindsayad added a commit to lindsayad/moose that referenced this issue May 17, 2022
Makes sure that variable dependencies have degrees of freedom on
all nodes along the boundaries of a boundary restricted object

Closes idaholab#9734
lindsayad added a commit to lindsayad/moose that referenced this issue May 18, 2022
Makes sure that variable dependencies have degrees of freedom on
all nodes along the boundaries of a boundary restricted object

Closes idaholab#9734
lindsayad added a commit to lindsayad/moose that referenced this issue May 18, 2022
Makes sure that variable dependencies have degrees of freedom on
all nodes along the boundaries of a boundary restricted object

Closes idaholab#9734
lindsayad added a commit to lindsayad/moose that referenced this issue May 18, 2022
Makes sure that variable dependencies have degrees of freedom on
all nodes along the boundaries of a boundary restricted object

Closes idaholab#9734
lindsayad added a commit to lindsayad/moose that referenced this issue May 18, 2022
Makes sure that variable dependencies have degrees of freedom on
all nodes along the boundaries of a boundary restricted object

Closes idaholab#9734
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C: Framework P: normal A defect affecting operation with a low possibility of significantly affects. T: defect An anomaly, which is anything that deviates from expectations.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants