]> https://gitweb.dealii.org/ - dealii.git/commit
Fix DoFHandler::n_boundary_dofs() in issue #8897 8901/head
authorDoug Shi-Dong <doug.shidong@gmail.com>
Fri, 11 Oct 2019 19:19:10 +0000 (15:19 -0400)
committerDoug Shi-Dong <doug.shidong@gmail.com>
Mon, 14 Oct 2019 15:12:23 +0000 (11:12 -0400)
commit6914b1ee04a1db5815cd662ac94cd0ac4e60f2d3
tree21a9eb681051ee296eee7efb3da4c7767ec55048
parentf538a13de76f5c9fb0f8744e036ec57c81cf6c79
Fix DoFHandler::n_boundary_dofs() in issue #8897

Only count locally owned dofs in the case of a parallel::distributed::Triangulation.

Use suggested syntax on cell iterator.

Co-Authored-By: Daniel Arndt <arndtd@ornl.gov>
Add test case for n_boundary_dofs in parallel

Fix n_boundary_dofs() for hp version.

Also implement suggested change

    Start 3212: dofs/n_boundary_dofs_01.mpirun=1.debug
1/8 Test # 3212: dofs/n_boundary_dofs_01.mpirun=1.debug .....   Passed    0.50 sec
    Start 3213: dofs/n_boundary_dofs_01.mpirun=1.release
2/8 Test # 3213: dofs/n_boundary_dofs_01.mpirun=1.release ...   Passed    0.49 sec
    Start 3214: dofs/n_boundary_dofs_01.mpirun=2.debug
3/8 Test # 3214: dofs/n_boundary_dofs_01.mpirun=2.debug .....   Passed    0.50 sec
    Start 3215: dofs/n_boundary_dofs_01.mpirun=2.release
4/8 Test # 3215: dofs/n_boundary_dofs_01.mpirun=2.release ...   Passed    0.51 sec
    Start 3216: dofs/n_boundary_dofs_02.debug
5/8 Test # 3216: dofs/n_boundary_dofs_02.debug ..............   Passed    0.51 sec
    Start 3217: dofs/n_boundary_dofs_02.release
6/8 Test # 3217: dofs/n_boundary_dofs_02.release ............   Passed    0.52 sec
    Start 3218: dofs/n_boundary_dofs_03.debug
7/8 Test # 3218: dofs/n_boundary_dofs_03.debug ..............   Passed    0.52 sec
    Start 3219: dofs/n_boundary_dofs_03.release
8/8 Test # 3219: dofs/n_boundary_dofs_03.release ............   Passed    0.54 sec

100% tests passed, 0 tests failed out of 8

Add hp n_boundary_dofs test.

Use unordered_set instead.
Fix a || to a && from switching the if-continue statement.

      Start 3212: dofs/n_boundary_dofs_01.mpirun=1.debug
 1/18 Test # 3212: dofs/n_boundary_dofs_01.mpirun=1.debug .....   Passed   51.27 sec
      Start 3213: dofs/n_boundary_dofs_01.mpirun=1.release
 2/18 Test # 3213: dofs/n_boundary_dofs_01.mpirun=1.release ...   Passed   17.03 sec
      Start 3214: dofs/n_boundary_dofs_01.mpirun=2.debug
 3/18 Test # 3214: dofs/n_boundary_dofs_01.mpirun=2.debug .....   Passed    1.90 sec
      Start 3215: dofs/n_boundary_dofs_01.mpirun=2.release
 4/18 Test # 3215: dofs/n_boundary_dofs_01.mpirun=2.release ...   Passed    1.45 sec
      Start 3216: dofs/n_boundary_dofs_02.debug
 5/18 Test # 3216: dofs/n_boundary_dofs_02.debug ..............   Passed   50.17 sec
      Start 3217: dofs/n_boundary_dofs_02.release
 6/18 Test # 3217: dofs/n_boundary_dofs_02.release ............   Passed   16.30 sec
      Start 3218: dofs/n_boundary_dofs_03.debug
 7/18 Test # 3218: dofs/n_boundary_dofs_03.debug ..............   Passed   50.67 sec
      Start 3219: dofs/n_boundary_dofs_03.release
 8/18 Test # 3219: dofs/n_boundary_dofs_03.release ............   Passed   16.71 sec
      Start 5498: hp/n_boundary_dofs.debug
 9/18 Test # 5498: hp/n_boundary_dofs.debug ...................   Passed   44.68 sec
      Start 5499: hp/n_boundary_dofs.release
10/18 Test # 5499: hp/n_boundary_dofs.release .................   Passed   11.83 sec
      Start 5500: hp/n_boundary_dofs_01.mpirun=1.debug
11/18 Test # 5500: hp/n_boundary_dofs_01.mpirun=1.debug .......   Passed   34.48 sec
      Start 5501: hp/n_boundary_dofs_01.mpirun=1.release
12/18 Test # 5501: hp/n_boundary_dofs_01.mpirun=1.release .....   Passed   12.46 sec
      Start 5502: hp/n_boundary_dofs_01.mpirun=2.debug
13/18 Test # 5502: hp/n_boundary_dofs_01.mpirun=2.debug .......   Passed    1.75 sec
      Start 5503: hp/n_boundary_dofs_01.mpirun=2.release
14/18 Test # 5503: hp/n_boundary_dofs_01.mpirun=2.release .....   Passed    1.36 sec
      Start 5504: hp/n_boundary_dofs_02.debug
15/18 Test # 5504: hp/n_boundary_dofs_02.debug ................   Passed   34.33 sec
      Start 5505: hp/n_boundary_dofs_02.release
16/18 Test # 5505: hp/n_boundary_dofs_02.release ..............   Passed   12.25 sec
      Start 5506: hp/n_boundary_dofs_03.debug
17/18 Test # 5506: hp/n_boundary_dofs_03.debug ................   Passed   41.88 sec
      Start 5507: hp/n_boundary_dofs_03.release
18/18 Test # 5507: hp/n_boundary_dofs_03.release ..............   Passed   15.45 sec

100% tests passed, 0 tests failed out of 18
doc/news/changes/minor/20191011DougShiDong [new file with mode: 0644]
include/deal.II/dofs/dof_handler.h
include/deal.II/hp/dof_handler.h
source/dofs/dof_handler.cc
source/hp/dof_handler.cc
tests/dofs/n_boundary_dofs_01.cc [new file with mode: 0644]
tests/dofs/n_boundary_dofs_01.with_p4est=true.mpirun=1.output [new file with mode: 0644]
tests/dofs/n_boundary_dofs_01.with_p4est=true.mpirun=2.output [new file with mode: 0644]
tests/hp/n_boundary_dofs_01.cc [new file with mode: 0644]
tests/hp/n_boundary_dofs_01.with_p4est=true.mpirun=1.output [new file with mode: 0644]
tests/hp/n_boundary_dofs_01.with_p4est=true.mpirun=2.output [new file with mode: 0644]

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.