--- /srv/rebuilderd/tmp/rebuilderdEkycuG/inputs/libdune-common-doc_2.11.0-1_all.deb +++ /srv/rebuilderd/tmp/rebuilderdEkycuG/out/libdune-common-doc_2.11.0-1_all.deb ├── file list │ @@ -1,3 +1,3 @@ │ -rw-r--r-- 0 0 0 4 2026-02-06 14:44:21.000000 debian-binary │ --rw-r--r-- 0 0 0 31148 2026-02-06 14:44:21.000000 control.tar.xz │ --rw-r--r-- 0 0 0 6834292 2026-02-06 14:44:21.000000 data.tar.xz │ +-rw-r--r-- 0 0 0 31112 2026-02-06 14:44:21.000000 control.tar.xz │ +-rw-r--r-- 0 0 0 6836872 2026-02-06 14:44:21.000000 data.tar.xz ├── control.tar.xz │ ├── control.tar │ │ ├── ./md5sums │ │ │ ├── ./md5sums │ │ │ │┄ Files differ │ │ │ ├── line order │ │ │ │ @@ -21,15 +21,14 @@ │ │ │ │ usr/share/doc/libdune-common-doc/copyright │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00002.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00008.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00008_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00011.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00011_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00014.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00014_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00017.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00017_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00020.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00020_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00023.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00023_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00026.html │ │ │ │ @@ -37,35 +36,33 @@ │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00029.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00029_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00032.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00032_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00035.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00035_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00038.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00038_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00041.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00041_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00044.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00044_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00047.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00047_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00050.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00050_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00053.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00053_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00056.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00056_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00059.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00059_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00062.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00062_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00065.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00065_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00068.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00068_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00071.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00071_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00074.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00074_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00077.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00077_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00080.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00080_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00083.html │ │ │ │ @@ -80,16 +77,14 @@ │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00095_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00098.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00098_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00101.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00101_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00104.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00104_source.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00107.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00107_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00110.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00110_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00113.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00113_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00116.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00116_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00119.html │ │ │ │ @@ -110,63 +105,65 @@ │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00140_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00143.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00143_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00146.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00146_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00149.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00149_source.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00152.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00152_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00155.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00155_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00158.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00158_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00161.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00161_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00164.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00164_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00167.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00167_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00170.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00170_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00173.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00173_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00176.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00176_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00179.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00179_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00182.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00182_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00185.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00185_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00188.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00188_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00191.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00191_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00194.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00194_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00197.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00197_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00200.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00200_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00203.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00203_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00206.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00206_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00209.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00209_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00212.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00212_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00215.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00215_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00218.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00218_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00221.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00221_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00224.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00224_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00227.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00227_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00230.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00230_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00233.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00233_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00236.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00236_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00239.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00239_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00242.html │ │ │ │ @@ -180,20 +177,20 @@ │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00254.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00254_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00257.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00257_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00260.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00260_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00263.html │ │ │ │ -usr/share/doc/libdune-common-doc/doxygen/a00263_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00266.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00266_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00269.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00269_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00272.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00272_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00275.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00275_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00278.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00278_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00281.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00281_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00284.html │ │ │ │ @@ -207,14 +204,15 @@ │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00296.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00296_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00299.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00299_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00302.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00302_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00305.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00305_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00308.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00308_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00311.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00311_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00314.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00314_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00317.html │ │ │ │ @@ -236,25 +234,27 @@ │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00341.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00341_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00344.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00344_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00347.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00347_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00350.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00350_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00353.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00353_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00356.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00356_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00359.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00359_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00362.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00362_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00365.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00365_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00368.html │ │ │ │ +usr/share/doc/libdune-common-doc/doxygen/a00368_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00371.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00371_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00374.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00374_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00377.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00377_source.html │ │ │ │ usr/share/doc/libdune-common-doc/doxygen/a00380.html ├── data.tar.xz │ ├── data.tar │ │ ├── file list │ │ │ @@ -26,302 +26,302 @@ │ │ │ -rw-r--r-- 0 root (0) root (0) 2825 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/buildsystem/html/search.html │ │ │ -rw-r--r-- 0 root (0) root (0) 11498 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/buildsystem/html/searchindex.js │ │ │ -rw-r--r-- 0 root (0) root (0) 2907 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/changelog.Debian.gz │ │ │ -rw-r--r-- 0 root (0) root (0) 13225 2026-01-09 13:06:10.000000 ./usr/share/doc/libdune-common-doc/changelog.gz │ │ │ -rw-r--r-- 0 root (0) root (0) 9937 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/copyright │ │ │ drwxr-xr-x 0 root (0) root (0) 0 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/ │ │ │ -rw-r--r-- 0 root (0) root (0) 3050 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00002.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6657 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00008.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8122 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00008_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 39808 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00011.html │ │ │ --rw-r--r-- 0 root (0) root (0) 14691 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00011_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3823 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00014.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6388 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00014_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4403 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00017.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4998 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00017_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6641 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00020.html │ │ │ --rw-r--r-- 0 root (0) root (0) 13140 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00020_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 17070 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00023.html │ │ │ --rw-r--r-- 0 root (0) root (0) 22236 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00023_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8915 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00026.html │ │ │ --rw-r--r-- 0 root (0) root (0) 43638 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00026_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8200 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00029.html │ │ │ --rw-r--r-- 0 root (0) root (0) 28795 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00029_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7614 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00032.html │ │ │ --rw-r--r-- 0 root (0) root (0) 16491 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00032_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9339 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00035.html │ │ │ --rw-r--r-- 0 root (0) root (0) 27752 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00035_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 20710 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00038.html │ │ │ --rw-r--r-- 0 root (0) root (0) 73294 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00038_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 13720 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00041.html │ │ │ --rw-r--r-- 0 root (0) root (0) 28985 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00041_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7712 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00044.html │ │ │ --rw-r--r-- 0 root (0) root (0) 24942 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00044_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 18448 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00047.html │ │ │ --rw-r--r-- 0 root (0) root (0) 80020 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00047_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7871 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00050.html │ │ │ --rw-r--r-- 0 root (0) root (0) 47038 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00050_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4920 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00053.html │ │ │ --rw-r--r-- 0 root (0) root (0) 20624 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00053_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6915 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00056.html │ │ │ --rw-r--r-- 0 root (0) root (0) 18784 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00056_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6818 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00059.html │ │ │ --rw-r--r-- 0 root (0) root (0) 14090 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00059_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7447 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00062.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9767 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00062_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4757 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00065.html │ │ │ --rw-r--r-- 0 root (0) root (0) 13345 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00068.html │ │ │ --rw-r--r-- 0 root (0) root (0) 23683 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00068_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7660 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00071.html │ │ │ --rw-r--r-- 0 root (0) root (0) 11948 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00074.html │ │ │ --rw-r--r-- 0 root (0) root (0) 35544 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00074_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 11141 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00077.html │ │ │ --rw-r--r-- 0 root (0) root (0) 96136 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00077_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4714 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00080.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7977 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00080_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5606 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00083.html │ │ │ --rw-r--r-- 0 root (0) root (0) 12679 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00083_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 12012 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00086.html │ │ │ --rw-r--r-- 0 root (0) root (0) 88169 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00086_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6278 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00089.html │ │ │ --rw-r--r-- 0 root (0) root (0) 154425 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00089_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5700 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00092.html │ │ │ --rw-r--r-- 0 root (0) root (0) 52744 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00092_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5659 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00095.html │ │ │ --rw-r--r-- 0 root (0) root (0) 42114 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00095_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5653 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00098.html │ │ │ --rw-r--r-- 0 root (0) root (0) 41953 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00098_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5502 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00101.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7119 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00101_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6178 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00104.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10134 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00104_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4678 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00107.html │ │ │ --rw-r--r-- 0 root (0) root (0) 13014 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00107_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5243 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00110.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9310 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00110_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6989 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00113.html │ │ │ --rw-r--r-- 0 root (0) root (0) 55077 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00113_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5257 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00116.html │ │ │ --rw-r--r-- 0 root (0) root (0) 14807 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00116_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7799 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00119.html │ │ │ --rw-r--r-- 0 root (0) root (0) 21389 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00119_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5680 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00122.html │ │ │ --rw-r--r-- 0 root (0) root (0) 14731 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00122_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6428 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00125.html │ │ │ --rw-r--r-- 0 root (0) root (0) 11982 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00125_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5901 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00128.html │ │ │ --rw-r--r-- 0 root (0) root (0) 12933 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00128_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7822 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00131.html │ │ │ --rw-r--r-- 0 root (0) root (0) 129352 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00131_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5180 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00134.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10974 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00134_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 31510 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00137.html │ │ │ --rw-r--r-- 0 root (0) root (0) 373244 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00137_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 13338 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00140.html │ │ │ --rw-r--r-- 0 root (0) root (0) 20869 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00140_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 13449 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00143.html │ │ │ --rw-r--r-- 0 root (0) root (0) 86754 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00143_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 73429 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00146.html │ │ │ --rw-r--r-- 0 root (0) root (0) 148561 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00146_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7281 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00149.html │ │ │ --rw-r--r-- 0 root (0) root (0) 18746 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00149_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 21978 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00155.html │ │ │ --rw-r--r-- 0 root (0) root (0) 42826 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00155_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6598 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00158.html │ │ │ --rw-r--r-- 0 root (0) root (0) 11857 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00158_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7387 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00161.html │ │ │ --rw-r--r-- 0 root (0) root (0) 12164 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00161_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5008 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00164.html │ │ │ --rw-r--r-- 0 root (0) root (0) 30055 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00164_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5230 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00167.html │ │ │ --rw-r--r-- 0 root (0) root (0) 32230 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00167_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7036 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00170.html │ │ │ --rw-r--r-- 0 root (0) root (0) 96328 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00170_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8068 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00173.html │ │ │ --rw-r--r-- 0 root (0) root (0) 15106 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00173_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 19491 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00176.html │ │ │ --rw-r--r-- 0 root (0) root (0) 118142 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00176_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3355 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00179.html │ │ │ --rw-r--r-- 0 root (0) root (0) 88864 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00179_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5562 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00182.html │ │ │ --rw-r--r-- 0 root (0) root (0) 17524 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00182_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 11583 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00185.html │ │ │ --rw-r--r-- 0 root (0) root (0) 53843 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00185_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5563 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00188.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9298 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00188_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5971 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00191.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10732 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00191_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 12712 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00194.html │ │ │ --rw-r--r-- 0 root (0) root (0) 94543 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00194_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8078 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00197.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10473 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00197_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8407 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00200.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6427 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00203.html │ │ │ --rw-r--r-- 0 root (0) root (0) 18053 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00203_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3932 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00206.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8662 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00209.html │ │ │ --rw-r--r-- 0 root (0) root (0) 64355 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00209_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3882 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00212.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4978 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00215.html │ │ │ --rw-r--r-- 0 root (0) root (0) 31409 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00215_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6919 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00218.html │ │ │ --rw-r--r-- 0 root (0) root (0) 136941 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00218_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6737 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00221.html │ │ │ --rw-r--r-- 0 root (0) root (0) 59353 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00221_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 12222 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00224.html │ │ │ --rw-r--r-- 0 root (0) root (0) 302549 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00224_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9591 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00227.html │ │ │ --rw-r--r-- 0 root (0) root (0) 55273 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00227_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4187 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00230.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10023 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00230_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6250 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00233.html │ │ │ --rw-r--r-- 0 root (0) root (0) 35578 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00233_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6159 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00236.html │ │ │ --rw-r--r-- 0 root (0) root (0) 52291 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00236_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8350 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00239.html │ │ │ --rw-r--r-- 0 root (0) root (0) 41887 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00239_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6334 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00242.html │ │ │ --rw-r--r-- 0 root (0) root (0) 33840 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00242_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5650 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00245.html │ │ │ --rw-r--r-- 0 root (0) root (0) 39587 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00245_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7819 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00248.html │ │ │ --rw-r--r-- 0 root (0) root (0) 34936 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00248_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 11959 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00251.html │ │ │ --rw-r--r-- 0 root (0) root (0) 104320 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00251_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6396 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00254.html │ │ │ --rw-r--r-- 0 root (0) root (0) 20039 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00254_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 12238 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00257.html │ │ │ --rw-r--r-- 0 root (0) root (0) 177717 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00257_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 18442 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00260.html │ │ │ --rw-r--r-- 0 root (0) root (0) 189589 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00260_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6738 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00263.html │ │ │ --rw-r--r-- 0 root (0) root (0) 39127 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00263_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9273 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00266.html │ │ │ --rw-r--r-- 0 root (0) root (0) 178321 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00266_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7618 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00269.html │ │ │ --rw-r--r-- 0 root (0) root (0) 71165 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00269_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 22212 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00272.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5644 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00275.html │ │ │ --rw-r--r-- 0 root (0) root (0) 20750 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00275_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4078 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00278.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10233 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00278_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4880 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00281.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6839 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00281_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4173 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00284.html │ │ │ --rw-r--r-- 0 root (0) root (0) 18965 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00284_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 21685 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00287.html │ │ │ --rw-r--r-- 0 root (0) root (0) 57673 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00287_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7269 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00290.html │ │ │ --rw-r--r-- 0 root (0) root (0) 31260 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00290_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5293 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00293.html │ │ │ --rw-r--r-- 0 root (0) root (0) 41478 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00293_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4713 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00296.html │ │ │ --rw-r--r-- 0 root (0) root (0) 14711 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00296_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 36017 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00299.html │ │ │ --rw-r--r-- 0 root (0) root (0) 190775 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00299_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5156 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00302.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9915 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00302_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3988 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00305.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4961 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00308.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7757 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00308_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 19629 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00311.html │ │ │ --rw-r--r-- 0 root (0) root (0) 46256 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00311_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 21202 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00314.html │ │ │ --rw-r--r-- 0 root (0) root (0) 39473 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00314_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4974 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00317.html │ │ │ --rw-r--r-- 0 root (0) root (0) 23424 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00317_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5945 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00320.html │ │ │ --rw-r--r-- 0 root (0) root (0) 20411 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00320_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 18092 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00323.html │ │ │ --rw-r--r-- 0 root (0) root (0) 79163 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00323_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 23957 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00326.html │ │ │ --rw-r--r-- 0 root (0) root (0) 92404 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00326_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 16930 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00329.html │ │ │ --rw-r--r-- 0 root (0) root (0) 45391 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00329_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8011 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00332.html │ │ │ --rw-r--r-- 0 root (0) root (0) 31873 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00332_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8409 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00335.html │ │ │ --rw-r--r-- 0 root (0) root (0) 41785 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00335_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 13191 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00338.html │ │ │ --rw-r--r-- 0 root (0) root (0) 102695 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00338_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6234 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00341.html │ │ │ --rw-r--r-- 0 root (0) root (0) 17551 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00341_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6769 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00344.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8005 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00344_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10045 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00347.html │ │ │ --rw-r--r-- 0 root (0) root (0) 110786 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00347_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4888 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00350.html │ │ │ --rw-r--r-- 0 root (0) root (0) 17761 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00353.html │ │ │ --rw-r--r-- 0 root (0) root (0) 174928 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00353_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 16108 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00356.html │ │ │ --rw-r--r-- 0 root (0) root (0) 48960 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00356_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 25530 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00359.html │ │ │ --rw-r--r-- 0 root (0) root (0) 125898 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00359_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5400 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00362.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9281 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00362_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 11150 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00365.html │ │ │ --rw-r--r-- 0 root (0) root (0) 38429 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00365_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3991 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00368.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10009 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00371.html │ │ │ --rw-r--r-- 0 root (0) root (0) 33121 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00371_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6775 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00374.html │ │ │ --rw-r--r-- 0 root (0) root (0) 53348 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00374_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6047 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00377.html │ │ │ --rw-r--r-- 0 root (0) root (0) 21551 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00377_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6609 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00380.html │ │ │ --rw-r--r-- 0 root (0) root (0) 44786 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00380_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10921 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00383.html │ │ │ --rw-r--r-- 0 root (0) root (0) 16342 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00383_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5473 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00386.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7175 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00386_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10462 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00389.html │ │ │ --rw-r--r-- 0 root (0) root (0) 266800 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00389_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4947 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00392.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9440 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00392_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6986 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00395.html │ │ │ --rw-r--r-- 0 root (0) root (0) 160634 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00395_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 9566 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00398.html │ │ │ --rw-r--r-- 0 root (0) root (0) 249865 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00398_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8682 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00401.html │ │ │ --rw-r--r-- 0 root (0) root (0) 59514 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00401_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3367 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00404.html │ │ │ --rw-r--r-- 0 root (0) root (0) 51604 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00404_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 29643 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00407.html │ │ │ --rw-r--r-- 0 root (0) root (0) 112803 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00407_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6494 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00410.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5110 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00413.html │ │ │ --rw-r--r-- 0 root (0) root (0) 30095 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00413_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4818 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00416.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6720 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00416_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5259 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00419.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7186 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00419_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3444 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00422.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8947 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00422_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3446 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00425.html │ │ │ --rw-r--r-- 0 root (0) root (0) 13198 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00425_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 3355 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00428.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7479 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00428_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 13211 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00431.html │ │ │ --rw-r--r-- 0 root (0) root (0) 51598 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00431_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6068 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00434.html │ │ │ --rw-r--r-- 0 root (0) root (0) 15956 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00434_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 4597 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00437.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7309 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00437_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 8807 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00440.html │ │ │ --rw-r--r-- 0 root (0) root (0) 141849 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00440_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5102 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00443.html │ │ │ --rw-r--r-- 0 root (0) root (0) 12344 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00443_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 14016 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00446.html │ │ │ --rw-r--r-- 0 root (0) root (0) 168016 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00446_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 7678 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00449.html │ │ │ --rw-r--r-- 0 root (0) root (0) 10331 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00449_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 6879 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00452.html │ │ │ --rw-r--r-- 0 root (0) root (0) 112717 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00452_source.html │ │ │ --rw-r--r-- 0 root (0) root (0) 5344 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00455.html │ │ │ --rw-r--r-- 0 root (0) root (0) 25399 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00455_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8807 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00008.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 141849 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00008_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7822 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00011.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 129352 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00011_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3988 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00014.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4978 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00017.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 31409 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00017_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 14016 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00020.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 168016 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00020_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5008 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00023.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 30055 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00023_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3355 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00026.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7479 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00026_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6047 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00029.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 21551 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00029_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8068 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00032.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 15106 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00032_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9566 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00035.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 249865 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00035_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8407 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00038.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 11583 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00041.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 53843 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00041_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7660 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00044.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4173 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00047.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 18965 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00047_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7269 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00050.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 31260 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00050_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4888 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00053.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 12222 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00056.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 302549 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00056_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 22212 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00059.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7618 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00062.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 71165 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00062_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6396 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00065.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 20039 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00065_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 18442 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00068.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 189589 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00068_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6737 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00071.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 59353 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00071_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6250 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00074.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 35578 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00074_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6159 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00077.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 52291 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00077_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9273 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00080.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 178321 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00080_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6738 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00083.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 39127 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00083_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9591 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00086.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 55273 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00086_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8350 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00089.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 41887 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00089_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6334 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00092.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 33840 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00092_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5650 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00095.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 39587 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00095_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 11959 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00098.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 104320 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00098_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4187 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00101.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10023 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00101_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7819 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00104.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 34936 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00104_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 12238 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00110.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 177717 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00110_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6919 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00113.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 136941 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00113_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8662 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00116.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 64355 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00116_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3367 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00119.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 51604 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00119_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 13191 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00122.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 102695 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00122_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 36017 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00125.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 190775 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00125_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5102 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00128.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 12344 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00128_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4974 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00131.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 23424 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00131_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3446 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00134.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 13198 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00134_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3444 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00137.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8947 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00137_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5259 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00140.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7186 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00140_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3823 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00143.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6388 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00143_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6818 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00146.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 14090 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00146_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4403 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00149.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4998 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00149_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 13720 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00152.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 28985 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00152_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5230 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00155.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 32230 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00155_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 39808 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00158.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 14691 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00158_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6915 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00161.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 18784 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00161_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3932 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00164.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 12712 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00167.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 94543 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00167_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10045 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00170.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 110786 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00170_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6775 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00173.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 53348 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00173_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 16108 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00176.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 48960 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00176_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4757 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00179.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 16930 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00182.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 45391 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00182_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5400 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00185.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9281 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00185_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4078 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00188.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10233 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00188_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5293 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00191.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 41478 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00191_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5110 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00194.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 30095 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00194_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 19491 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00197.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 118142 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00197_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7712 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00200.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 24942 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00200_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4597 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00203.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7309 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00203_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7036 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00206.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 96328 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00206_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 23957 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00209.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 92404 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00209_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3355 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00212.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 88864 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00212_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6609 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00215.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 44786 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00215_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4818 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00218.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6720 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00218_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10921 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00221.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 16342 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00221_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6879 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00224.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 112717 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00224_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5945 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00227.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 20411 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00227_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3882 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00230.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 21978 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00233.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 42826 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00233_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 73429 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00236.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 148561 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00236_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 13338 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00239.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 20869 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00239_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 31510 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00242.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 373244 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00242_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 13449 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00245.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 86754 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00245_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7281 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00248.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 18746 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00248_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6598 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00251.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 11857 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00251_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 25530 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00254.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 125898 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00254_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4947 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00257.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9440 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00257_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5563 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00260.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9298 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00260_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6494 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00263.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5473 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00266.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7175 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00266_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10462 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00269.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 266800 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00269_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 19629 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00272.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 46256 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00272_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6657 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00275.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8122 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00275_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8078 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00278.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10473 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00278_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6769 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00281.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8005 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00281_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6427 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00284.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 18053 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00284_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8011 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00287.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 31873 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00287_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 21202 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00290.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 39473 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00290_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5180 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00293.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10974 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00293_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7447 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00296.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9767 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00296_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4961 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00299.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7757 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00299_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6986 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00302.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 160634 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00302_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10009 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00305.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 33121 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00305_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 21685 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00308.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 57673 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00308_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5562 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00311.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 17524 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00311_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4880 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00314.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6839 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00314_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5156 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00317.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9915 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00317_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7678 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00320.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10331 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00320_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 29643 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00323.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 112803 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00323_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 13211 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00326.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 51598 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00326_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4713 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00329.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 14711 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00329_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6641 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00332.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 13140 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00332_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 18092 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00335.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 79163 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00335_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 13345 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00338.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 23683 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00338_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 11150 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00341.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 38429 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00341_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6234 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00344.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 17551 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00344_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 18448 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00347.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 80020 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00347_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8409 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00350.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 41785 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00350_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5257 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00353.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 14807 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00353_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5243 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00356.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9310 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00356_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5700 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00359.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 52744 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00359_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5659 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00362.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 42114 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00362_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4714 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00365.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7977 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00365_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5680 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00368.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 14731 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00368_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6278 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00371.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 154425 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00371_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 11948 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00374.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 35544 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00374_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5606 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00377.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 12679 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00377_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5502 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00380.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7119 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00380_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 12012 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00383.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 88169 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00383_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6989 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00386.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 55077 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00386_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4678 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00389.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 13014 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00389_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6178 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00392.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10134 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00392_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 11141 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00395.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 96136 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00395_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6428 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00398.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 11982 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00398_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5653 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00401.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 41953 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00401_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7799 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00404.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 21389 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00404_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5901 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00407.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 12933 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00407_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 3991 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00410.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 17761 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00413.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 174928 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00413_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5971 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00416.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 10732 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00416_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5644 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00419.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 20750 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00419_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7871 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00422.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 47038 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00422_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 6068 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00425.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 15956 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00425_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 20710 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00428.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 73294 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00428_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 4920 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00431.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 20624 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00431_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8682 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00434.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 59514 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00434_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7387 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00437.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 12164 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00437_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 5344 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00440.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 25399 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00440_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8915 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00443.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 43638 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00443_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 17070 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00446.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 22236 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00446_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 9339 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00449.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 27752 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00449_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 7614 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00452.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 16491 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00452_source.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 8200 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00455.html │ │ │ +-rw-r--r-- 0 root (0) root (0) 28795 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00455_source.html │ │ │ -rw-r--r-- 0 root (0) root (0) 5022 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00458.html │ │ │ -rw-r--r-- 0 root (0) root (0) 49218 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00458_source.html │ │ │ -rw-r--r-- 0 root (0) root (0) 8287 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00461.html │ │ │ -rw-r--r-- 0 root (0) root (0) 3397 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00462.html │ │ │ -rw-r--r-- 0 root (0) root (0) 265116 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00463.html │ │ │ -rw-r--r-- 0 root (0) root (0) 27483 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00463.png │ │ │ -rw-r--r-- 0 root (0) root (0) 37642 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/a00464.html │ │ │ @@ -1343,15 +1343,15 @@ │ │ │ -rw-r--r-- 0 root (0) root (0) 6033 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/dir_cfefffc182b11139f3f3d047f813bd4d.html │ │ │ -rw-r--r-- 0 root (0) root (0) 3460 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/dir_cfefffc182b11139f3f3d047f813bd4d_dep.png │ │ │ -rw-r--r-- 0 root (0) root (0) 49906 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/dir_e151556194dc695299293609645e9437.html │ │ │ -rw-r--r-- 0 root (0) root (0) 14103 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/dir_e151556194dc695299293609645e9437_dep.png │ │ │ -rw-r--r-- 0 root (0) root (0) 3658 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/dir_e68e8157741866f444e17edd764ebbae.html │ │ │ -rw-r--r-- 0 root (0) root (0) 54624 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/doxygen.css │ │ │ -rw-r--r-- 0 root (0) root (0) 223030 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/doxygen_crawl.html │ │ │ --rw-r--r-- 0 root (0) root (0) 172075 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/dune-common.tag.gz │ │ │ +-rw-r--r-- 0 root (0) root (0) 172164 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/dune-common.tag.gz │ │ │ -rw-r--r-- 0 root (0) root (0) 7707 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/dynsections.js │ │ │ -rw-r--r-- 0 root (0) root (0) 65664 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/files.html │ │ │ -rw-r--r-- 0 root (0) root (0) 1145 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/form_0.png │ │ │ -rw-r--r-- 0 root (0) root (0) 1167 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/form_0_dark.png │ │ │ -rw-r--r-- 0 root (0) root (0) 1153 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/form_1.png │ │ │ -rw-r--r-- 0 root (0) root (0) 403 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/form_10.png │ │ │ -rw-r--r-- 0 root (0) root (0) 422 2026-02-06 14:44:21.000000 ./usr/share/doc/libdune-common-doc/doxygen/form_10_dark.png │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00008.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: visibility.hh File Reference │ │ │ +dune-common: bitsetvector.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -72,69 +72,53 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ -Macros
│ │ │ -
visibility.hh File Reference
│ │ │ +Classes | │ │ │ +Namespaces
│ │ │ +
bitsetvector.hh File Reference
│ │ │
│ │ │
│ │ │ │ │ │ -

Definition of macros controlling symbol visibility at the ABI level. │ │ │ +

Efficient implementation of a dynamic array of static arrays of booleans. │ │ │ More...

│ │ │ - │ │ │ +
#include <vector>
│ │ │ +#include <bitset>
│ │ │ +#include <iostream>
│ │ │ +#include <algorithm>
│ │ │ +#include <dune/common/boundschecking.hh>
│ │ │ +#include <dune/common/genericiterator.hh>
│ │ │ +#include <dune/common/exceptions.hh>
│ │ │ +
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ +

│ │ │ -Macros

#define DUNE_EXPORT   implementation_defined
 Export a symbol as part of the public ABI.
#define DUNE_PRIVATE   implementation_defined
 Mark a symbol as being for internal use within the current DSO only.

│ │ │ +Classes

class  Dune::BitSetVectorConstReference< block_size, Alloc >
 A proxy class that acts as a const reference to a single bitset in a BitSetVector. More...
class  Dune::BitSetVectorReference< block_size, Alloc >
 A proxy class that acts as a mutable reference to a single bitset in a BitSetVector. More...
struct  Dune::const_reference< BitSetVectorReference< block_size, Alloc > >
struct  Dune::const_reference< BitSetVectorConstReference< block_size, Alloc > >
struct  Dune::mutable_reference< BitSetVectorReference< block_size, Alloc > >
struct  Dune::mutable_reference< BitSetVectorConstReference< block_size, Alloc > >
class  Dune::BitSetVector< block_size, Allocator >
 A dynamic array of blocks of booleans. More...
│ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ +Namespaces

namespace  Dune
 Dune namespace
│ │ │

Detailed Description

│ │ │ -

Definition of macros controlling symbol visibility at the ABI level.

│ │ │ -

Macro Definition Documentation

│ │ │ - │ │ │ -

◆ DUNE_EXPORT

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_EXPORT   implementation_defined
│ │ │ -
│ │ │ - │ │ │ -

Export a symbol as part of the public ABI.

│ │ │ -

Mark a class, function or static variable as visible outside the current DSO. For now, this is mostly important for templated global variables and functions that contain static variables.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_PRIVATE

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_PRIVATE   implementation_defined
│ │ │ -
│ │ │ - │ │ │ -

Mark a symbol as being for internal use within the current DSO only.

│ │ │ -

Mark a class, function or static variable as inaccessible from outside the current DSO. Doing so will decrease the size of the symbol table, but you have to be sure that the symbol will never have to be accessed from another library or the main executable!

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ -
│ │ │ +

Efficient implementation of a dynamic array of static arrays of booleans.

│ │ │ +
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,33 +1,40 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -_M_a_c_r_o_s │ │ │ │ -visibility.hh File Reference │ │ │ │ -Definition of macros controlling symbol visibility at the ABI level. _M_o_r_e_._._. │ │ │ │ +_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ +bitsetvector.hh File Reference │ │ │ │ +Efficient implementation of a dynamic array of static arrays of booleans. │ │ │ │ +_M_o_r_e_._._. │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_b_o_u_n_d_s_c_h_e_c_k_i_n_g_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_g_e_n_e_r_i_c_i_t_e_r_a_t_o_r_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_e_x_c_e_p_t_i_o_n_s_._h_h> │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -MMaaccrrooss │ │ │ │ -#define  _D_U_N_E___E_X_P_O_R_T   implementation_defined │ │ │ │ -  Export a symbol as part of the public ABI. │ │ │ │ -#define  _D_U_N_E___P_R_I_V_A_T_E   implementation_defined │ │ │ │ -  Mark a symbol as being for internal use within the current DSO only. │ │ │ │ +CCllaasssseess │ │ │ │ + class   _D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _> │ │ │ │ +  A proxy class that acts as a const reference to a single bitset in a │ │ │ │ + _B_i_t_S_e_t_V_e_c_t_o_r. _M_o_r_e_._._. │ │ │ │ + class   _D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _> │ │ │ │ +  A proxy class that acts as a mutable reference to a single bitset in a │ │ │ │ + _B_i_t_S_e_t_V_e_c_t_o_r. _M_o_r_e_._._. │ │ │ │ +struct   _D_u_n_e_:_:_c_o_n_s_t___r_e_f_e_r_e_n_c_e_<_ _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_ _> │ │ │ │ +struct   _D_u_n_e_:_:_c_o_n_s_t___r_e_f_e_r_e_n_c_e_<_ _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _> │ │ │ │ + _> │ │ │ │ +struct   _D_u_n_e_:_:_m_u_t_a_b_l_e___r_e_f_e_r_e_n_c_e_<_ _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_ _> │ │ │ │ +struct   _D_u_n_e_:_:_m_u_t_a_b_l_e___r_e_f_e_r_e_n_c_e_<_ _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c │ │ │ │ + _>_ _> │ │ │ │ + class   _D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_a_t_o_r_ _> │ │ │ │ +  A dynamic array of blocks of booleans. _M_o_r_e_._._. │ │ │ │ +NNaammeessppaacceess │ │ │ │ +namespace   _D_u_n_e │ │ │ │ +  Dune namespace │ │ │ │ ********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ -Definition of macros controlling symbol visibility at the ABI level. │ │ │ │ -********** MMaaccrroo DDeeffiinniittiioonn DDooccuummeennttaattiioonn ********** │ │ │ │ -********** _?◆_? DDUUNNEE__EEXXPPOORRTT ********** │ │ │ │ -#define DUNE_EXPORT   implementation_defined │ │ │ │ -Export a symbol as part of the public ABI. │ │ │ │ -Mark a class, function or static variable as visible outside the current DSO. │ │ │ │ -For now, this is mostly important for templated global variables and functions │ │ │ │ -that contain static variables. │ │ │ │ -********** _?◆_? DDUUNNEE__PPRRIIVVAATTEE ********** │ │ │ │ -#define DUNE_PRIVATE   implementation_defined │ │ │ │ -Mark a symbol as being for internal use within the current DSO only. │ │ │ │ -Mark a class, function or static variable as inaccessible from outside the │ │ │ │ -current DSO. Doing so will decrease the size of the symbol table, but you have │ │ │ │ -to be sure that the symbol will never have to be accessed from another library │ │ │ │ -or the main executable! │ │ │ │ +Efficient implementation of a dynamic array of static arrays of booleans. │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00008_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: visibility.hh Source File │ │ │ +dune-common: bitsetvector.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -71,49 +71,744 @@ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
visibility.hh
│ │ │ +
bitsetvector.hh
│ │ │
│ │ │
│ │ │ Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │
2// vi: set et ts=4 sw=2 sts=2:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ -
5#ifndef DUNE_COMMON_VISIBILITY_HH
│ │ │ -
6#define DUNE_COMMON_VISIBILITY_HH
│ │ │ +
5#ifndef DUNE_BLOCK_BITFIELD_HH
│ │ │ +
6#define DUNE_BLOCK_BITFIELD_HH
│ │ │
7
│ │ │
11
│ │ │ -
12#ifdef DOXYGEN
│ │ │ -
13
│ │ │ -
15
│ │ │ -
20#define DUNE_EXPORT implementation_defined
│ │ │ -
21
│ │ │ -
23
│ │ │ -
28#define DUNE_PRIVATE implementation_defined
│ │ │ -
29
│ │ │ -
30#else // DOXYGEN
│ │ │ -
31
│ │ │ -
32#if __GNUC__ >= 4
│ │ │ -
33// GCC and Clang both define __GNUC__ to 4 and they both support the visibility
│ │ │ -
34// attribute
│ │ │ -
35#define DUNE_EXPORT __attribute__((visibility("default")))
│ │ │ -
36#define DUNE_PRIVATE __attribute__((visibility("hidden")))
│ │ │ -
37#else
│ │ │ -
38// We don't know about the active compiler, so just turn the visibility macros to no-ops.
│ │ │ -
39#define DUNE_EXPORT
│ │ │ -
40#define DUNE_PRIVATE
│ │ │ -
41#endif
│ │ │ -
42
│ │ │ -
43#endif // DOXYGEN
│ │ │ -
44
│ │ │ -
45#endif // DUNE_COMMON_VISIBILITY
│ │ │ +
12#include <vector>
│ │ │ +
13#include <bitset>
│ │ │ +
14#include <iostream>
│ │ │ +
15#include <algorithm>
│ │ │ +
16
│ │ │ + │ │ │ + │ │ │ + │ │ │ +
20
│ │ │ +
21namespace Dune {
│ │ │ +
22
│ │ │ +
23 template <int block_size, class Alloc> class BitSetVector;
│ │ │ +
24 template <int block_size, class Alloc> class BitSetVectorReference;
│ │ │ +
25
│ │ │ +
36 template <int block_size, class Alloc>
│ │ │ +
│ │ │ + │ │ │ +
38 {
│ │ │ +
39 protected:
│ │ │ +
40
│ │ │ + │ │ │ +
42 friend class Dune::BitSetVector<block_size, Alloc>;
│ │ │ +
43
│ │ │ +
│ │ │ +
44 BitSetVectorConstReference(const BitSetVector& blockBitField_, int block_number_) :
│ │ │ +
45 blockBitField(blockBitField_),
│ │ │ +
46 block_number(block_number_)
│ │ │ +
47 {
│ │ │ +
48 DUNE_ASSERT_BOUNDS(blockBitField_.size() > static_cast<size_t>(block_number_));
│ │ │ +
49 }
│ │ │ +
│ │ │ +
50
│ │ │ + │ │ │ +
53
│ │ │ +
54 public:
│ │ │ +
55
│ │ │ +
56 typedef std::bitset<block_size> bitset;
│ │ │ +
57
│ │ │ +
58 // bitset interface typedefs
│ │ │ +
59 typedef typename std::vector<bool, Alloc>::const_reference reference;
│ │ │ +
60 typedef typename std::vector<bool, Alloc>::const_reference const_reference;
│ │ │ +
61 typedef size_t size_type;
│ │ │ +
62
│ │ │ +
│ │ │ + │ │ │ +
65 {
│ │ │ +
66 bitset b = *this;
│ │ │ +
67 b <<= n;
│ │ │ +
68 return b;
│ │ │ +
69 }
│ │ │ +
│ │ │ +
70
│ │ │ +
│ │ │ + │ │ │ +
73 {
│ │ │ +
74 bitset b = *this;
│ │ │ +
75 b >>= n;
│ │ │ +
76 return b;
│ │ │ +
77 }
│ │ │ +
│ │ │ +
78
│ │ │ +
│ │ │ + │ │ │ +
81 {
│ │ │ +
82 bitset b = *this;
│ │ │ +
83 b.flip();
│ │ │ +
84 return b;
│ │ │ +
85 }
│ │ │ +
│ │ │ +
86
│ │ │ +
│ │ │ + │ │ │ +
89 {
│ │ │ +
90 return block_size;
│ │ │ +
91 }
│ │ │ +
│ │ │ +
92
│ │ │ +
│ │ │ + │ │ │ +
95 {
│ │ │ +
96 size_type n = 0;
│ │ │ +
97 for(size_type i=0; i<block_size; ++i)
│ │ │ +
98 n += getBit(i);
│ │ │ +
99 return n;
│ │ │ +
100 }
│ │ │ +
│ │ │ +
101
│ │ │ +
│ │ │ +
103 bool any() const
│ │ │ +
104 {
│ │ │ +
105 return count();
│ │ │ +
106 }
│ │ │ +
│ │ │ +
107
│ │ │ +
│ │ │ +
109 bool none() const
│ │ │ +
110 {
│ │ │ +
111 return ! any();
│ │ │ +
112 }
│ │ │ +
│ │ │ +
113
│ │ │ +
│ │ │ +
115 bool all() const
│ │ │ +
116 {
│ │ │ +
117 for(size_type i=0; i<block_size; ++i)
│ │ │ +
118 if(not test(i))
│ │ │ +
119 return false;
│ │ │ +
120 return true;
│ │ │ +
121 }
│ │ │ +
│ │ │ +
122
│ │ │ +
│ │ │ +
124 bool test(size_type n) const
│ │ │ +
125 {
│ │ │ +
126 return getBit(n);
│ │ │ +
127 }
│ │ │ +
│ │ │ +
128
│ │ │ +
│ │ │ + │ │ │ +
131 {
│ │ │ +
132 return getBit(i);
│ │ │ +
133 }
│ │ │ +
│ │ │ +
134
│ │ │ +
│ │ │ +
136 operator bitset() const
│ │ │ +
137 {
│ │ │ +
138 return blockBitField.getRepr(block_number);
│ │ │ +
139 }
│ │ │ +
│ │ │ +
140
│ │ │ +
│ │ │ +
142 bool operator== (const bitset& bs) const
│ │ │ +
143 {
│ │ │ +
144 return equals(bs);
│ │ │ +
145 }
│ │ │ +
│ │ │ +
146
│ │ │ +
│ │ │ + │ │ │ +
149 {
│ │ │ +
150 return equals(bs);
│ │ │ +
151 }
│ │ │ +
│ │ │ +
152
│ │ │ +
│ │ │ +
154 bool operator!= (const bitset& bs) const
│ │ │ +
155 {
│ │ │ +
156 return ! equals(bs);
│ │ │ +
157 }
│ │ │ +
│ │ │ +
158
│ │ │ +
│ │ │ + │ │ │ +
161 {
│ │ │ +
162 return ! equals(bs);
│ │ │ +
163 }
│ │ │ +
│ │ │ +
164
│ │ │ +
170
│ │ │ +
│ │ │ +
171 friend std::ostream& operator<< (std::ostream& s, const BitSetVectorConstReference& v)
│ │ │ +
172 {
│ │ │ +
173 s << "(";
│ │ │ +
174 for(int i=0; i<block_size; ++i)
│ │ │ +
175 s << v[i];
│ │ │ +
176 s << ")";
│ │ │ +
177 return s;
│ │ │ +
178 }
│ │ │ +
│ │ │ +
179
│ │ │ +
180 protected:
│ │ │ + │ │ │ + │ │ │ +
183
│ │ │ +
│ │ │ + │ │ │ +
185 {
│ │ │ +
186 return blockBitField.getBit(block_number,i);
│ │ │ +
187 }
│ │ │ +
│ │ │ +
188
│ │ │ +
189 template<class BS>
│ │ │ +
│ │ │ +
190 bool equals(const BS & bs) const
│ │ │ +
191 {
│ │ │ +
192 bool eq = true;
│ │ │ +
193 for(int i=0; i<block_size; ++i)
│ │ │ +
194 eq &= (getBit(i) == bs[i]);
│ │ │ +
195 return eq;
│ │ │ +
196 }
│ │ │ +
│ │ │ +
197
│ │ │ +
198 private:
│ │ │ +
203 void operator & () = delete;
│ │ │ +
204
│ │ │ +
205 friend class BitSetVectorReference<block_size, Alloc>;
│ │ │ +
206 };
│ │ │ +
│ │ │ +
207
│ │ │ +
220 template <int block_size, class Alloc>
│ │ │ +
│ │ │ +
221 class BitSetVectorReference : public BitSetVectorConstReference<block_size,Alloc>
│ │ │ +
222 {
│ │ │ +
223 protected:
│ │ │ +
224
│ │ │ + │ │ │ +
226 friend class Dune::BitSetVector<block_size, Alloc>;
│ │ │ +
227
│ │ │ + │ │ │ +
229
│ │ │ +
│ │ │ +
230 BitSetVectorReference(BitSetVector& blockBitField_, int block_number_) :
│ │ │ +
231 BitSetVectorConstReference(blockBitField_, block_number_),
│ │ │ +
232 blockBitField(blockBitField_)
│ │ │ +
233 {}
│ │ │ +
│ │ │ +
234
│ │ │ +
235 public:
│ │ │ +
236 typedef std::bitset<block_size> bitset;
│ │ │ +
237
│ │ │ +
241 typedef typename std::vector<bool, Alloc>::reference reference;
│ │ │ +
243 typedef typename std::vector<bool, Alloc>::const_reference const_reference;
│ │ │ +
245
│ │ │ +
247 typedef size_t size_type;
│ │ │ +
248
│ │ │ +
│ │ │ + │ │ │ +
251 {
│ │ │ +
252 for(int i=0; i<block_size; ++i)
│ │ │ +
253 getBit(i) = b;
│ │ │ +
254 return (*this);
│ │ │ +
255 }
│ │ │ +
│ │ │ +
256
│ │ │ +
│ │ │ + │ │ │ +
259 {
│ │ │ +
260 for(int i=0; i<block_size; ++i)
│ │ │ +
261 getBit(i) = b.test(i);
│ │ │ +
262 return (*this);
│ │ │ +
263 }
│ │ │ +
│ │ │ +
264
│ │ │ +
│ │ │ + │ │ │ +
267 {
│ │ │ +
268 for(int i=0; i<block_size; ++i)
│ │ │ +
269 getBit(i) = b.test(i);
│ │ │ +
270 return (*this);
│ │ │ +
271 }
│ │ │ +
│ │ │ +
272
│ │ │ +
│ │ │ + │ │ │ +
275 {
│ │ │ +
276 for(int i=0; i<block_size; ++i)
│ │ │ +
277 getBit(i) = b.test(i);
│ │ │ +
278 return (*this);
│ │ │ +
279 }
│ │ │ +
│ │ │ +
280
│ │ │ +
│ │ │ + │ │ │ +
283 {
│ │ │ +
284 return (*this) = bitset(*this) & x;
│ │ │ +
285 }
│ │ │ +
│ │ │ +
286
│ │ │ +
│ │ │ + │ │ │ +
289 {
│ │ │ +
290 return (*this) &= bitset(x);
│ │ │ +
291 }
│ │ │ +
│ │ │ +
292
│ │ │ +
│ │ │ + │ │ │ +
295 {
│ │ │ +
296 return (*this) = bitset(*this) | x;
│ │ │ +
297 }
│ │ │ +
│ │ │ +
298
│ │ │ +
│ │ │ + │ │ │ +
301 {
│ │ │ +
302 return (*this) |= bitset(x);
│ │ │ +
303 }
│ │ │ +
│ │ │ +
304
│ │ │ +
│ │ │ + │ │ │ +
307 {
│ │ │ +
308 return (*this) = bitset(*this) ^ x;
│ │ │ +
309 }
│ │ │ +
│ │ │ +
310
│ │ │ +
│ │ │ + │ │ │ +
313 {
│ │ │ +
314 return (*this) ^= bitset(x);
│ │ │ +
315 }
│ │ │ +
│ │ │ +
316
│ │ │ +
│ │ │ + │ │ │ +
319 {
│ │ │ +
320 return (*this) = bitset(*this) << n;
│ │ │ +
321 }
│ │ │ +
│ │ │ +
322
│ │ │ +
│ │ │ + │ │ │ +
325 {
│ │ │ +
326 return (*this) = bitset(*this) >> n;
│ │ │ +
327 }
│ │ │ +
│ │ │ +
328
│ │ │ +
│ │ │ + │ │ │ +
331 {
│ │ │ +
332 for (size_type i=0; i<block_size; i++)
│ │ │ +
333 set(i);
│ │ │ +
334 return *this;
│ │ │ +
335 }
│ │ │ +
│ │ │ +
336
│ │ │ +
│ │ │ + │ │ │ +
339 {
│ │ │ +
340 for (size_type i=0; i<block_size; i++)
│ │ │ +
341 flip(i);
│ │ │ +
342 return *this;
│ │ │ +
343 }
│ │ │ +
│ │ │ +
344
│ │ │ +
│ │ │ + │ │ │ +
347 {
│ │ │ +
348 *this = false;
│ │ │ +
349 return *this;
│ │ │ +
350 }
│ │ │ +
│ │ │ +
351
│ │ │ +
│ │ │ + │ │ │ +
354 {
│ │ │ +
355 getBit(n) = val;
│ │ │ +
356 return *this;
│ │ │ +
357 }
│ │ │ +
│ │ │ +
358
│ │ │ +
│ │ │ + │ │ │ +
361 {
│ │ │ +
362 set(n, false);
│ │ │ +
363 return *this;
│ │ │ +
364 }
│ │ │ +
│ │ │ +
365
│ │ │ +
│ │ │ + │ │ │ +
368 {
│ │ │ +
369 getBit(n).flip();
│ │ │ +
370 return *this;
│ │ │ +
371 }
│ │ │ +
│ │ │ +
372
│ │ │ + │ │ │ +
374 using BitSetVectorConstReference::operator[];
│ │ │ +
375
│ │ │ +
│ │ │ + │ │ │ +
378 {
│ │ │ +
379 return getBit(i);
│ │ │ +
380 }
│ │ │ +
│ │ │ +
381
│ │ │ +
382 protected:
│ │ │ + │ │ │ +
384
│ │ │ + │ │ │ +
386
│ │ │ +
│ │ │ + │ │ │ +
388 {
│ │ │ +
389 return blockBitField.getBit(this->block_number,i);
│ │ │ +
390 }
│ │ │ +
│ │ │ +
391 };
│ │ │ +
│ │ │ +
392
│ │ │ +
396 template<int block_size, class Alloc>
│ │ │ +
│ │ │ +
397 struct const_reference< BitSetVectorReference<block_size,Alloc> >
│ │ │ +
398 {
│ │ │ + │ │ │ +
400 };
│ │ │ +
│ │ │ +
401
│ │ │ +
402 template<int block_size, class Alloc>
│ │ │ +
│ │ │ +
403 struct const_reference< BitSetVectorConstReference<block_size,Alloc> >
│ │ │ +
404 {
│ │ │ + │ │ │ +
406 };
│ │ │ +
│ │ │ +
407
│ │ │ +
408 template<int block_size, class Alloc>
│ │ │ +
│ │ │ +
409 struct mutable_reference< BitSetVectorReference<block_size,Alloc> >
│ │ │ +
410 {
│ │ │ + │ │ │ +
412 };
│ │ │ +
│ │ │ +
413
│ │ │ +
414 template<int block_size, class Alloc>
│ │ │ +
│ │ │ + │ │ │ +
416 {
│ │ │ + │ │ │ +
418 };
│ │ │ +
│ │ │ +
419
│ │ │ +
423 template <int block_size, class Allocator=std::allocator<bool> >
│ │ │ +
│ │ │ +
424 class BitSetVector : private std::vector<bool, Allocator>
│ │ │ +
425 {
│ │ │ +
427 typedef std::vector<bool, Allocator> BlocklessBaseClass;
│ │ │ +
428
│ │ │ +
429 public:
│ │ │ +
432
│ │ │ +
434 typedef std::bitset<block_size> value_type;
│ │ │ +
435
│ │ │ + │ │ │ +
438
│ │ │ + │ │ │ +
441
│ │ │ + │ │ │ +
444
│ │ │ + │ │ │ +
447
│ │ │ +
449 typedef typename std::vector<bool, Allocator>::size_type size_type;
│ │ │ +
450
│ │ │ +
452 typedef Allocator allocator_type;
│ │ │ +
454
│ │ │ + │ │ │ + │ │ │ +
460
│ │ │ +
│ │ │ + │ │ │ +
463 return iterator(*this, 0);
│ │ │ +
464 }
│ │ │ +
│ │ │ +
465
│ │ │ +
│ │ │ + │ │ │ +
468 return const_iterator(*this, 0);
│ │ │ +
469 }
│ │ │ +
│ │ │ +
470
│ │ │ +
│ │ │ + │ │ │ +
473 return iterator(*this, size());
│ │ │ +
474 }
│ │ │ +
│ │ │ +
475
│ │ │ +
│ │ │ + │ │ │ +
478 return const_iterator(*this, size());
│ │ │ +
479 }
│ │ │ +
│ │ │ +
480
│ │ │ +
│ │ │ + │ │ │ +
483 BlocklessBaseClass()
│ │ │ +
484 {}
│ │ │ +
│ │ │ +
485
│ │ │ +
│ │ │ +
487 BitSetVector(const BlocklessBaseClass& blocklessBitField) :
│ │ │ +
488 BlocklessBaseClass(blocklessBitField)
│ │ │ +
489 {
│ │ │ +
490 if (blocklessBitField.size()%block_size != 0)
│ │ │ +
491 DUNE_THROW(RangeError, "Vector size is not a multiple of the block size!");
│ │ │ +
492 }
│ │ │ +
│ │ │ +
493
│ │ │ +
│ │ │ +
497 explicit BitSetVector(int n) :
│ │ │ +
498 BlocklessBaseClass(n*block_size)
│ │ │ +
499 {}
│ │ │ +
│ │ │ +
500
│ │ │ +
│ │ │ +
502 BitSetVector(int n, bool v) :
│ │ │ +
503 BlocklessBaseClass(n*block_size,v)
│ │ │ +
504 {}
│ │ │ +
│ │ │ +
505
│ │ │ +
│ │ │ +
507 void clear()
│ │ │ +
508 {
│ │ │ +
509 BlocklessBaseClass::clear();
│ │ │ +
510 }
│ │ │ +
│ │ │ +
511
│ │ │ +
│ │ │ +
513 void resize(int n, bool v = bool())
│ │ │ +
514 {
│ │ │ +
515 BlocklessBaseClass::resize(n*block_size, v);
│ │ │ +
516 }
│ │ │ +
│ │ │ +
517
│ │ │ +
│ │ │ + │ │ │ +
520 {
│ │ │ +
521 return BlocklessBaseClass::size()/block_size;
│ │ │ +
522 }
│ │ │ +
│ │ │ +
523
│ │ │ +
│ │ │ +
525 void setAll() {
│ │ │ +
526 this->assign(BlocklessBaseClass::size(), true);
│ │ │ +
527 }
│ │ │ +
│ │ │ +
528
│ │ │ +
│ │ │ +
530 void unsetAll() {
│ │ │ +
531 this->assign(BlocklessBaseClass::size(), false);
│ │ │ +
532 }
│ │ │ +
│ │ │ +
533
│ │ │ +
│ │ │ + │ │ │ +
536 {
│ │ │ +
537 return reference(*this, i);
│ │ │ +
538 }
│ │ │ +
│ │ │ +
539
│ │ │ +
│ │ │ + │ │ │ +
542 {
│ │ │ +
543 return const_reference(*this, i);
│ │ │ +
544 }
│ │ │ +
│ │ │ +
545
│ │ │ +
│ │ │ + │ │ │ +
548 {
│ │ │ +
549 return reference(*this, size()-1);
│ │ │ +
550 }
│ │ │ +
│ │ │ +
551
│ │ │ +
│ │ │ + │ │ │ +
554 {
│ │ │ +
555 return const_reference(*this, size()-1);
│ │ │ +
556 }
│ │ │ +
│ │ │ +
557
│ │ │ +
│ │ │ + │ │ │ +
560 {
│ │ │ +
561 return std::count(BlocklessBaseClass::begin(), BlocklessBaseClass::end(), true);
│ │ │ +
562 }
│ │ │ +
│ │ │ +
563
│ │ │ +
│ │ │ + │ │ │ +
566 {
│ │ │ +
567 size_type n = 0;
│ │ │ +
568 size_type blocks = size();
│ │ │ +
569 for(size_type i=0; i<blocks; ++i)
│ │ │ +
570 n += getBit(i,j);
│ │ │ +
571 return n;
│ │ │ +
572 }
│ │ │ +
│ │ │ +
573
│ │ │ +
│ │ │ +
575 friend std::ostream& operator<< (std::ostream& s, const BitSetVector& v)
│ │ │ +
576 {
│ │ │ +
577 for (size_t i=0; i<v.size(); i++)
│ │ │ +
578 s << v[i] << " ";
│ │ │ +
579 return s;
│ │ │ +
580 }
│ │ │ +
│ │ │ +
581
│ │ │ +
582 private:
│ │ │ +
583
│ │ │ +
585 value_type getRepr(int i) const
│ │ │ +
586 {
│ │ │ +
587 value_type bits;
│ │ │ +
588 for(int j=0; j<block_size; ++j)
│ │ │ +
589 bits.set(j, getBit(i,j));
│ │ │ +
590 return bits;
│ │ │ +
591 }
│ │ │ +
592
│ │ │ +
593 typename std::vector<bool>::reference getBit(size_type i, size_type j) {
│ │ │ +
594 DUNE_ASSERT_BOUNDS(j < block_size);
│ │ │ + │ │ │ +
596 return BlocklessBaseClass::operator[](i*block_size+j);
│ │ │ +
597 }
│ │ │ +
598
│ │ │ +
599 typename std::vector<bool>::const_reference getBit(size_type i, size_type j) const {
│ │ │ +
600 DUNE_ASSERT_BOUNDS(j < block_size);
│ │ │ + │ │ │ +
602 return BlocklessBaseClass::operator[](i*block_size+j);
│ │ │ +
603 }
│ │ │ +
604
│ │ │ +
605 friend class BitSetVectorReference<block_size,Allocator>;
│ │ │ +
606 friend class BitSetVectorConstReference<block_size,Allocator>;
│ │ │ +
607 };
│ │ │ +
│ │ │ +
608
│ │ │ +
609} // namespace Dune
│ │ │ +
610
│ │ │ +
611#endif
│ │ │ +
Macro for wrapping boundary checks.
│ │ │ +
A few common exception classes.
│ │ │ +
Implements a generic iterator class for writing stl conformant iterators.
│ │ │ +
#define DUNE_ASSERT_BOUNDS(cond)
If DUNE_CHECK_BOUNDS is defined: check if condition cond holds; otherwise, do nothing.
Definition boundschecking.hh:30
│ │ │ +
#define DUNE_THROW(E,...)
Definition exceptions.hh:314
│ │ │ +
Dune namespace
Definition alignedallocator.hh:13
│ │ │ +
void assign(T &dst, const T &src, bool mask)
masked Simd assignment (scalar version)
Definition simd.hh:447
│ │ │ +
A dynamic array of blocks of booleans.
Definition bitsetvector.hh:425
│ │ │ +
const_reference operator[](int i) const
Return const reference to i-th block.
Definition bitsetvector.hh:541
│ │ │ +
iterator begin()
Returns a iterator pointing to the beginning of the vector.
Definition bitsetvector.hh:462
│ │ │ +
BitSetVectorConstReference< block_size, Alloc > * const_pointer
Definition bitsetvector.hh:446
│ │ │ +
const_iterator end() const
Returns a const_iterator pointing to the end of the vector.
Definition bitsetvector.hh:477
│ │ │ +
BitSetVectorReference< block_size, Alloc > reference
Definition bitsetvector.hh:437
│ │ │ +
size_type countmasked(int j) const
Returns the number of set bits, while each block is masked with 1<<i.
Definition bitsetvector.hh:565
│ │ │ +
BitSetVectorConstReference< block_size, Alloc > const_reference
Definition bitsetvector.hh:440
│ │ │ +
iterator end()
Returns an iterator pointing to the end of the vector.
Definition bitsetvector.hh:472
│ │ │ +
size_type count() const
Returns the number of bits that are set.
Definition bitsetvector.hh:559
│ │ │ +
BitSetVector()
Default constructor.
Definition bitsetvector.hh:482
│ │ │ +
void setAll()
Sets all entries to true .
Definition bitsetvector.hh:525
│ │ │ +
Dune::GenericIterator< const BitSetVector< block_size, Alloc >, const value_type, const_reference, std::ptrdiff_t, ForwardIteratorFacade > const_iterator
Definition bitsetvector.hh:458
│ │ │ +
std::bitset< block_size > value_type
Definition bitsetvector.hh:434
│ │ │ +
reference back()
Return reference to last block.
Definition bitsetvector.hh:547
│ │ │ +
BitSetVector(const BlocklessBaseClass &blocklessBitField)
Construction from an unblocked bitfield.
Definition bitsetvector.hh:487
│ │ │ +
friend std::ostream & operator<<(std::ostream &s, const BitSetVector &v)
Send bitfield to an output stream.
Definition bitsetvector.hh:575
│ │ │ +
const_reference back() const
Return const reference to last block.
Definition bitsetvector.hh:553
│ │ │ +
void clear()
Erases all of the elements.
Definition bitsetvector.hh:507
│ │ │ +
BitSetVectorReference< block_size, Alloc > * pointer
Definition bitsetvector.hh:443
│ │ │ +
reference operator[](int i)
Return reference to i-th block.
Definition bitsetvector.hh:535
│ │ │ +
size_type size() const
Return the number of blocks.
Definition bitsetvector.hh:519
│ │ │ +
std::vector< bool, Alloc >::size_type size_type
Definition bitsetvector.hh:449
│ │ │ +
BitSetVector(int n, bool v)
Constructor which initializes the field with true or false.
Definition bitsetvector.hh:502
│ │ │ +
const_iterator begin() const
Returns a const_iterator pointing to the beginning of the vector.
Definition bitsetvector.hh:467
│ │ │ +
Dune::GenericIterator< BitSetVector< block_size, Alloc >, value_type, reference, std::ptrdiff_t, ForwardIteratorFacade > iterator
Definition bitsetvector.hh:457
│ │ │ +
void resize(int n, bool v=bool())
Resize field.
Definition bitsetvector.hh:513
│ │ │ +
Alloc allocator_type
Definition bitsetvector.hh:452
│ │ │ +
BitSetVector(int n)
Definition bitsetvector.hh:497
│ │ │ +
void unsetAll()
Sets all entries to false .
Definition bitsetvector.hh:530
│ │ │ +
A proxy class that acts as a mutable reference to a single bitset in a BitSetVector.
Definition bitsetvector.hh:222
│ │ │ +
bool test(size_type n) const
Returns true if bit n is set.
Definition bitsetvector.hh:124
│ │ │ +
BitSetVectorReference & operator=(const BitSetVectorConstReference &b)
Assignment from BitSetVectorConstReference.
Definition bitsetvector.hh:266
│ │ │ +
reference operator[](size_type i)
Return reference to the i-th bit.
Definition bitsetvector.hh:377
│ │ │ +
BitSetVectorReference & reset(size_type n)
Clears bit n.
Definition bitsetvector.hh:360
│ │ │ +
BitSetVectorReference & operator<<=(size_type n)
Left shift.
Definition bitsetvector.hh:318
│ │ │ +
Dune::BitSetVector< block_size, Alloc > BitSetVector
Definition bitsetvector.hh:225
│ │ │ +
std::vector< bool, Alloc >::const_reference const_reference
A proxy class that acts as a const reference to a single bit.
Definition bitsetvector.hh:243
│ │ │ +
BitSetVectorReference & operator=(const BitSetVectorReference &b)
Assignment from BitSetVectorReference.
Definition bitsetvector.hh:274
│ │ │ +
reference getBit(size_type i)
Definition bitsetvector.hh:387
│ │ │ +
BitSetVectorReference & operator&=(const BitSetVectorConstReference &x)
Bitwise and (for BitSetVectorConstReference and BitSetVectorReference).
Definition bitsetvector.hh:288
│ │ │ +
BitSetVectorReference(BitSetVector &blockBitField_, int block_number_)
Definition bitsetvector.hh:230
│ │ │ +
size_t size_type
size_type typedef (an unsigned integral type)
Definition bitsetvector.hh:247
│ │ │ +
BitSetVectorReference & operator=(const bitset &b)
Assignment from bitset.
Definition bitsetvector.hh:258
│ │ │ +
Dune::BitSetVectorConstReference< block_size, Alloc > BitSetVectorConstReference
Definition bitsetvector.hh:228
│ │ │ +
BitSetVectorReference & reset()
Clears every bit.
Definition bitsetvector.hh:346
│ │ │ +
BitSetVector & blockBitField
Definition bitsetvector.hh:383
│ │ │ +
BitSetVectorReference & operator|=(const BitSetVectorConstReference &x)
Bitwise inclusive or (for BitSetVectorConstReference and BitSetVectorReference).
Definition bitsetvector.hh:300
│ │ │ +
BitSetVectorReference & set(size_type n, int val=1)
Sets bit n if val is nonzero, and clears bit n if val is zero.
Definition bitsetvector.hh:353
│ │ │ +
std::bitset< block_size > bitset
Definition bitsetvector.hh:236
│ │ │ +
BitSetVectorReference & operator^=(const bitset &x)
Bitwise exclusive or (for bitset).
Definition bitsetvector.hh:306
│ │ │ +
std::vector< bool, Alloc >::reference reference
Definition bitsetvector.hh:241
│ │ │ +
BitSetVectorReference & operator|=(const bitset &x)
Bitwise inclusive or (for bitset).
Definition bitsetvector.hh:294
│ │ │ +
BitSetVectorReference & operator>>=(size_type n)
Right shift.
Definition bitsetvector.hh:324
│ │ │ +
BitSetVectorReference & operator^=(const BitSetVectorConstReference &x)
Bitwise exclusive or (for BitSetVectorConstReference and BitSetVectorReference).
Definition bitsetvector.hh:312
│ │ │ +
BitSetVectorReference & flip(size_type n)
Flips bit n.
Definition bitsetvector.hh:367
│ │ │ +
BitSetVectorReference & flip()
Flips the value of every bit.
Definition bitsetvector.hh:338
│ │ │ +
BitSetVectorReference & set()
Sets every bit.
Definition bitsetvector.hh:330
│ │ │ +
BitSetVectorReference & operator&=(const bitset &x)
Bitwise and (for bitset).
Definition bitsetvector.hh:282
│ │ │ +
BitSetVectorReference & operator=(bool b)
Assignment from bool, sets each bit in the bitset to b.
Definition bitsetvector.hh:250
│ │ │ +
A proxy class that acts as a const reference to a single bitset in a BitSetVector.
Definition bitsetvector.hh:38
│ │ │ +
bool operator==(const bitset &bs) const
Equality of reference and std::bitset.
Definition bitsetvector.hh:142
│ │ │ +
bool test(size_type n) const
Returns true if bit n is set.
Definition bitsetvector.hh:124
│ │ │ +
const_reference operator[](size_type i) const
Return reference to the i-th bit.
Definition bitsetvector.hh:130
│ │ │ +
bitset operator<<(size_type n) const
Returns a copy of *this shifted left by n bits.
Definition bitsetvector.hh:64
│ │ │ +
BitSetVectorConstReference(const BitSetVector &blockBitField_, int block_number_)
Definition bitsetvector.hh:44
│ │ │ +
const BitSetVector & blockBitField
Definition bitsetvector.hh:181
│ │ │ +
bitset operator>>(size_type n) const
Returns a copy of *this shifted right by n bits.
Definition bitsetvector.hh:72
│ │ │ +
const_reference getBit(size_type i) const
Definition bitsetvector.hh:184
│ │ │ +
bool operator!=(const bitset &bs) const
Inequality of reference and std::bitset.
Definition bitsetvector.hh:154
│ │ │ +
bool equals(const BS &bs) const
Definition bitsetvector.hh:190
│ │ │ +
Dune::BitSetVector< block_size, Alloc > BitSetVector
Definition bitsetvector.hh:41
│ │ │ +
std::bitset< block_size > bitset
Definition bitsetvector.hh:56
│ │ │ +
bool all() const
Returns true if all bits are set.
Definition bitsetvector.hh:115
│ │ │ +
size_t size_type
Definition bitsetvector.hh:61
│ │ │ +
bitset operator~() const
Returns a copy of *this with all of its bits flipped.
Definition bitsetvector.hh:80
│ │ │ +
std::vector< bool, Alloc >::const_reference reference
Definition bitsetvector.hh:59
│ │ │ +
size_type size() const
Returns block_size.
Definition bitsetvector.hh:88
│ │ │ +
size_type count() const
Returns the number of bits that are set.
Definition bitsetvector.hh:94
│ │ │ +
bool none() const
Returns true if no bits are set.
Definition bitsetvector.hh:109
│ │ │ +
bool any() const
Returns true if any bits are set.
Definition bitsetvector.hh:103
│ │ │ + │ │ │ +
std::vector< bool, Alloc >::const_reference const_reference
Definition bitsetvector.hh:60
│ │ │ +
BitSetVectorConstReference & operator=(const BitSetVectorConstReference &b)=delete
disable assignment operator
│ │ │ +
BitSetVectorConstReference< block_size, Alloc > type
Definition bitsetvector.hh:399
│ │ │ +
BitSetVectorConstReference< block_size, Alloc > type
Definition bitsetvector.hh:405
│ │ │ +
BitSetVectorReference< block_size, Alloc > type
Definition bitsetvector.hh:411
│ │ │ +
BitSetVectorReference< block_size, Alloc > type
Definition bitsetvector.hh:417
│ │ │ +
Default exception class for range errors.
Definition exceptions.hh:348
│ │ │ +
Get the 'const' version of a reference to a mutable object.
Definition genericiterator.hh:87
│ │ │ +
get the 'mutable' version of a reference to a const object
Definition genericiterator.hh:116
│ │ │ +
Generic class for stl-conforming iterators for container classes with operator[].
Definition genericiterator.hh:153
│ │ │ +
Base class for stl conformant forward iterators.
Definition iteratorfacades.hh:142
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,45 +1,880 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -visibility.hh │ │ │ │ +bitsetvector.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ 1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ 2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ 4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ -5#ifndef DUNE_COMMON_VISIBILITY_HH │ │ │ │ -6#define DUNE_COMMON_VISIBILITY_HH │ │ │ │ +5#ifndef DUNE_BLOCK_BITFIELD_HH │ │ │ │ +6#define DUNE_BLOCK_BITFIELD_HH │ │ │ │ 7 │ │ │ │ 11 │ │ │ │ -12#ifdef DOXYGEN │ │ │ │ -13 │ │ │ │ -15 │ │ │ │ -_2_0#define DUNE_EXPORT implementation_defined │ │ │ │ -21 │ │ │ │ -23 │ │ │ │ -_2_8#define DUNE_PRIVATE implementation_defined │ │ │ │ -29 │ │ │ │ -30#else // DOXYGEN │ │ │ │ -31 │ │ │ │ -32#if __GNUC__ >= 4 │ │ │ │ -33// GCC and Clang both define __GNUC__ to 4 and they both support the │ │ │ │ -visibility │ │ │ │ -34// attribute │ │ │ │ -35#define DUNE_EXPORT __attribute__((visibility("default"))) │ │ │ │ -36#define DUNE_PRIVATE __attribute__((visibility("hidden"))) │ │ │ │ -37#else │ │ │ │ -38// We don't know about the active compiler, so just turn the visibility │ │ │ │ -macros to no-ops. │ │ │ │ -39#define DUNE_EXPORT │ │ │ │ -40#define DUNE_PRIVATE │ │ │ │ -41#endif │ │ │ │ -42 │ │ │ │ -43#endif // DOXYGEN │ │ │ │ -44 │ │ │ │ -45#endif // DUNE_COMMON_VISIBILITY │ │ │ │ +12#include │ │ │ │ +13#include │ │ │ │ +14#include │ │ │ │ +15#include │ │ │ │ +16 │ │ │ │ +17#include <_d_u_n_e_/_c_o_m_m_o_n_/_b_o_u_n_d_s_c_h_e_c_k_i_n_g_._h_h> │ │ │ │ +18#include <_d_u_n_e_/_c_o_m_m_o_n_/_g_e_n_e_r_i_c_i_t_e_r_a_t_o_r_._h_h> │ │ │ │ +19#include <_d_u_n_e_/_c_o_m_m_o_n_/_e_x_c_e_p_t_i_o_n_s_._h_h> │ │ │ │ +20 │ │ │ │ +21namespace _D_u_n_e { │ │ │ │ +22 │ │ │ │ +23 template class _B_i_t_S_e_t_V_e_c_t_o_r; │ │ │ │ +24 template class _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e; │ │ │ │ +25 │ │ │ │ +36 template │ │ │ │ +_3_7 class _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e │ │ │ │ +38 { │ │ │ │ +39 protected: │ │ │ │ +40 │ │ │ │ +_4_1 typedef _D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_> _B_i_t_S_e_t_V_e_c_t_o_r; │ │ │ │ +42 friend class _D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r; │ │ │ │ +43 │ │ │ │ +_4_4 _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e(const _B_i_t_S_e_t_V_e_c_t_o_r& blockBitField_, int │ │ │ │ +block_number_) : │ │ │ │ +45 _b_l_o_c_k_B_i_t_F_i_e_l_d(blockBitField_), │ │ │ │ +46 _b_l_o_c_k___n_u_m_b_e_r(block_number_) │ │ │ │ +47 { │ │ │ │ +48 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(blockBitField_._s_i_z_e() > static_cast │ │ │ │ +(block_number_)); │ │ │ │ +49 } │ │ │ │ +50 │ │ │ │ +_5_2 _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e& _o_p_e_r_a_t_o_r_=(const _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e & b) │ │ │ │ += delete; │ │ │ │ +53 │ │ │ │ +54 public: │ │ │ │ +55 │ │ │ │ +_5_6 typedef std::bitset _b_i_t_s_e_t; │ │ │ │ +57 │ │ │ │ +58 // bitset interface typedefs │ │ │ │ +_5_9 typedef typename std::vector::const_reference _r_e_f_e_r_e_n_c_e; │ │ │ │ +_6_0 typedef typename std::vector::const_reference _c_o_n_s_t___r_e_f_e_r_e_n_c_e; │ │ │ │ +_6_1 typedef size_t _s_i_z_e___t_y_p_e; │ │ │ │ +62 │ │ │ │ +_6_4 _b_i_t_s_e_t _o_p_e_r_a_t_o_r_<_<(_s_i_z_e___t_y_p_e n) const │ │ │ │ +65 { │ │ │ │ +66 _b_i_t_s_e_t b = *this; │ │ │ │ +67 b <<= n; │ │ │ │ +68 return b; │ │ │ │ +69 } │ │ │ │ +70 │ │ │ │ +_7_2 _b_i_t_s_e_t _o_p_e_r_a_t_o_r_>_>(_s_i_z_e___t_y_p_e n) const │ │ │ │ +73 { │ │ │ │ +74 _b_i_t_s_e_t b = *this; │ │ │ │ +75 b >>= n; │ │ │ │ +76 return b; │ │ │ │ +77 } │ │ │ │ +78 │ │ │ │ +_8_0 _b_i_t_s_e_t _o_p_e_r_a_t_o_r_~() const │ │ │ │ +81 { │ │ │ │ +82 _b_i_t_s_e_t b = *this; │ │ │ │ +83 b.flip(); │ │ │ │ +84 return b; │ │ │ │ +85 } │ │ │ │ +86 │ │ │ │ +_8_8 _s_i_z_e___t_y_p_e _s_i_z_e() const │ │ │ │ +89 { │ │ │ │ +90 return block_size; │ │ │ │ +91 } │ │ │ │ +92 │ │ │ │ +_9_4 _s_i_z_e___t_y_p_e _c_o_u_n_t() const │ │ │ │ +95 { │ │ │ │ +96 _s_i_z_e___t_y_p_e n = 0; │ │ │ │ +97 for(_s_i_z_e___t_y_p_e i=0; i │ │ │ │ +_1_9_0 bool _e_q_u_a_l_s(const BS & bs) const │ │ │ │ +191 { │ │ │ │ +192 bool eq = true; │ │ │ │ +193 for(int i=0; i; │ │ │ │ +206 }; │ │ │ │ +207 │ │ │ │ +220 template │ │ │ │ +_2_2_1 class _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e : public │ │ │ │ +_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e │ │ │ │ +222 { │ │ │ │ +223 protected: │ │ │ │ +224 │ │ │ │ +_2_2_5 typedef _D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_> _B_i_t_S_e_t_V_e_c_t_o_r; │ │ │ │ +226 friend class _D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r; │ │ │ │ +227 │ │ │ │ +_2_2_8 typedef _D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_> │ │ │ │ +_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e; │ │ │ │ +229 │ │ │ │ +_2_3_0 _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e(_B_i_t_S_e_t_V_e_c_t_o_r& blockBitField_, int block_number_) : │ │ │ │ +231 _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e(blockBitField_, block_number_), │ │ │ │ +232 _b_l_o_c_k_B_i_t_F_i_e_l_d(blockBitField_) │ │ │ │ +233 {} │ │ │ │ +234 │ │ │ │ +235 public: │ │ │ │ +_2_3_6 typedef std::bitset _b_i_t_s_e_t; │ │ │ │ +237 │ │ │ │ +_2_4_1 typedef typename std::vector::reference _r_e_f_e_r_e_n_c_e; │ │ │ │ +_2_4_3 typedef typename std::vector::const_reference _c_o_n_s_t___r_e_f_e_r_e_n_c_e; │ │ │ │ +245 │ │ │ │ +_2_4_7 typedef size_t _s_i_z_e___t_y_p_e; │ │ │ │ +248 │ │ │ │ +_2_5_0 _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e& _o_p_e_r_a_t_o_r_=(bool b) │ │ │ │ +251 { │ │ │ │ +252 for(int i=0; i_>_=(_s_i_z_e___t_y_p_e n) │ │ │ │ +325 { │ │ │ │ +326 return (*this) = _b_i_t_s_e_t(*this) >> n; │ │ │ │ +327 } │ │ │ │ +328 │ │ │ │ +_3_3_0 _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e& _s_e_t() │ │ │ │ +331 { │ │ │ │ +332 for (_s_i_z_e___t_y_p_e i=0; i_b_l_o_c_k___n_u_m_b_e_r,i); │ │ │ │ +390 } │ │ │ │ +391 }; │ │ │ │ +392 │ │ │ │ +396 template │ │ │ │ +_3_9_7 struct _c_o_n_s_t___r_e_f_e_r_e_n_c_e< _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e > │ │ │ │ +398 { │ │ │ │ +_3_9_9 typedef _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_> _t_y_p_e; │ │ │ │ +400 }; │ │ │ │ +401 │ │ │ │ +402 template │ │ │ │ +_4_0_3 struct _c_o_n_s_t___r_e_f_e_r_e_n_c_e< _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e > │ │ │ │ +404 { │ │ │ │ +_4_0_5 typedef _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_> _t_y_p_e; │ │ │ │ +406 }; │ │ │ │ +407 │ │ │ │ +408 template │ │ │ │ +_4_0_9 struct _m_u_t_a_b_l_e___r_e_f_e_r_e_n_c_e< _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e > │ │ │ │ +410 { │ │ │ │ +_4_1_1 typedef _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_> _t_y_p_e; │ │ │ │ +412 }; │ │ │ │ +413 │ │ │ │ +414 template │ │ │ │ +_4_1_5 struct _m_u_t_a_b_l_e___r_e_f_e_r_e_n_c_e< _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e > │ │ │ │ +416 { │ │ │ │ +_4_1_7 typedef _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_> _t_y_p_e; │ │ │ │ +418 }; │ │ │ │ +419 │ │ │ │ +423 template > │ │ │ │ +_4_2_4 class _B_i_t_S_e_t_V_e_c_t_o_r : private std::vector │ │ │ │ +425 { │ │ │ │ +427 typedef std::vector BlocklessBaseClass; │ │ │ │ +428 │ │ │ │ +429 public: │ │ │ │ +432 │ │ │ │ +_4_3_4 typedef std::bitset _v_a_l_u_e___t_y_p_e; │ │ │ │ +435 │ │ │ │ +_4_3_7 typedef _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_a_t_o_r_> _r_e_f_e_r_e_n_c_e; │ │ │ │ +438 │ │ │ │ +_4_4_0 typedef _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_a_t_o_r_> _c_o_n_s_t___r_e_f_e_r_e_n_c_e; │ │ │ │ +441 │ │ │ │ +_4_4_3 typedef _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_a_t_o_r_>* _p_o_i_n_t_e_r; │ │ │ │ +444 │ │ │ │ +_4_4_6 typedef _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_a_t_o_r_>* _c_o_n_s_t___p_o_i_n_t_e_r; │ │ │ │ +447 │ │ │ │ +_4_4_9 typedef typename std::vector::size_type _s_i_z_e___t_y_p_e; │ │ │ │ +450 │ │ │ │ +_4_5_2 typedef Allocator _a_l_l_o_c_a_t_o_r___t_y_p_e; │ │ │ │ +454 │ │ │ │ +_4_5_7 typedef _D_u_n_e_:_:_G_e_n_e_r_i_c_I_t_e_r_a_t_o_r_<_B_i_t_S_e_t_V_e_c_t_o_r_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_a_t_o_r_>, │ │ │ │ +_v_a_l_u_e___t_y_p_e, _r_e_f_e_r_e_n_c_e, std::ptrdiff_t, _F_o_r_w_a_r_d_I_t_e_r_a_t_o_r_F_a_c_a_d_e> _i_t_e_r_a_t_o_r; │ │ │ │ +_4_5_8 typedef _D_u_n_e_:_:_G_e_n_e_r_i_c_I_t_e_r_a_t_o_r_<_c_o_n_s_t_ _B_i_t_S_e_t_V_e_c_t_o_r_<_b_l_o_c_k___s_i_z_e_,_A_l_l_o_c_a_t_o_r_>, │ │ │ │ +const _v_a_l_u_e___t_y_p_e, _c_o_n_s_t___r_e_f_e_r_e_n_c_e, std::ptrdiff_t, _F_o_r_w_a_r_d_I_t_e_r_a_t_o_r_F_a_c_a_d_e> │ │ │ │ +_c_o_n_s_t___i_t_e_r_a_t_o_r; │ │ │ │ +460 │ │ │ │ +_4_6_2 _i_t_e_r_a_t_o_r _b_e_g_i_n(){ │ │ │ │ +463 return _i_t_e_r_a_t_o_r(*this, 0); │ │ │ │ +464 } │ │ │ │ +465 │ │ │ │ +_4_6_7 _c_o_n_s_t___i_t_e_r_a_t_o_r _b_e_g_i_n() const { │ │ │ │ +468 return _c_o_n_s_t___i_t_e_r_a_t_o_r(*this, 0); │ │ │ │ +469 } │ │ │ │ +470 │ │ │ │ +_4_7_2 _i_t_e_r_a_t_o_r _e_n_d(){ │ │ │ │ +473 return _i_t_e_r_a_t_o_r(*this, _s_i_z_e()); │ │ │ │ +474 } │ │ │ │ +475 │ │ │ │ +_4_7_7 _c_o_n_s_t___i_t_e_r_a_t_o_r _e_n_d() const { │ │ │ │ +478 return _c_o_n_s_t___i_t_e_r_a_t_o_r(*this, _s_i_z_e()); │ │ │ │ +479 } │ │ │ │ +480 │ │ │ │ +_4_8_2 _B_i_t_S_e_t_V_e_c_t_o_r() : │ │ │ │ +483 BlocklessBaseClass() │ │ │ │ +484 {} │ │ │ │ +485 │ │ │ │ +_4_8_7 _B_i_t_S_e_t_V_e_c_t_o_r(const BlocklessBaseClass& blocklessBitField) : │ │ │ │ +488 BlocklessBaseClass(blocklessBitField) │ │ │ │ +489 { │ │ │ │ +490 if (blocklessBitField.size()%block_size != 0) │ │ │ │ +491 _D_U_N_E___T_H_R_O_W(_R_a_n_g_e_E_r_r_o_r, "Vector size is not a multiple of the block size!"); │ │ │ │ +492 } │ │ │ │ +493 │ │ │ │ +_4_9_7 explicit _B_i_t_S_e_t_V_e_c_t_o_r(int n) : │ │ │ │ +498 BlocklessBaseClass(n*block_size) │ │ │ │ +499 {} │ │ │ │ +500 │ │ │ │ +_5_0_2 _B_i_t_S_e_t_V_e_c_t_o_r(int n, bool v) : │ │ │ │ +503 BlocklessBaseClass(n*block_size,v) │ │ │ │ +504 {} │ │ │ │ +505 │ │ │ │ +_5_0_7 void _c_l_e_a_r() │ │ │ │ +508 { │ │ │ │ +509 BlocklessBaseClass::clear(); │ │ │ │ +510 } │ │ │ │ +511 │ │ │ │ +_5_1_3 void _r_e_s_i_z_e(int n, bool v = bool()) │ │ │ │ +514 { │ │ │ │ +515 BlocklessBaseClass::resize(n*block_size, v); │ │ │ │ +516 } │ │ │ │ +517 │ │ │ │ +_5_1_9 _s_i_z_e___t_y_p_e _s_i_z_e() const │ │ │ │ +520 { │ │ │ │ +521 return BlocklessBaseClass::size()/block_size; │ │ │ │ +522 } │ │ │ │ +523 │ │ │ │ +_5_2_5 void _s_e_t_A_l_l() { │ │ │ │ +526 this->_a_s_s_i_g_n(BlocklessBaseClass::size(), true); │ │ │ │ +527 } │ │ │ │ +528 │ │ │ │ +_5_3_0 void _u_n_s_e_t_A_l_l() { │ │ │ │ +531 this->_a_s_s_i_g_n(BlocklessBaseClass::size(), false); │ │ │ │ +532 } │ │ │ │ +533 │ │ │ │ +_5_3_5 _r_e_f_e_r_e_n_c_e _o_p_e_r_a_t_o_r_[_](int i) │ │ │ │ +536 { │ │ │ │ +537 return _r_e_f_e_r_e_n_c_e(*this, i); │ │ │ │ +538 } │ │ │ │ +539 │ │ │ │ +_5_4_1 _c_o_n_s_t___r_e_f_e_r_e_n_c_e _o_p_e_r_a_t_o_r_[_](int i) const │ │ │ │ +542 { │ │ │ │ +543 return _c_o_n_s_t___r_e_f_e_r_e_n_c_e(*this, i); │ │ │ │ +544 } │ │ │ │ +545 │ │ │ │ +_5_4_7 _r_e_f_e_r_e_n_c_e _b_a_c_k() │ │ │ │ +548 { │ │ │ │ +549 return _r_e_f_e_r_e_n_c_e(*this, _s_i_z_e()-1); │ │ │ │ +550 } │ │ │ │ +551 │ │ │ │ +_5_5_3 _c_o_n_s_t___r_e_f_e_r_e_n_c_e _b_a_c_k() const │ │ │ │ +554 { │ │ │ │ +555 return _c_o_n_s_t___r_e_f_e_r_e_n_c_e(*this, _s_i_z_e()-1); │ │ │ │ +556 } │ │ │ │ +557 │ │ │ │ +_5_5_9 _s_i_z_e___t_y_p_e _c_o_u_n_t() const │ │ │ │ +560 { │ │ │ │ +561 return std::count(BlocklessBaseClass::begin(), BlocklessBaseClass::end(), │ │ │ │ +true); │ │ │ │ +562 } │ │ │ │ +563 │ │ │ │ +_5_6_5 _s_i_z_e___t_y_p_e _c_o_u_n_t_m_a_s_k_e_d(int j) const │ │ │ │ +566 { │ │ │ │ +567 _s_i_z_e___t_y_p_e n = 0; │ │ │ │ +568 _s_i_z_e___t_y_p_e blocks = _s_i_z_e(); │ │ │ │ +569 for(_s_i_z_e___t_y_p_e i=0; i::reference getBit(_s_i_z_e___t_y_p_e i, _s_i_z_e___t_y_p_e j) { │ │ │ │ +594 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(j < block_size); │ │ │ │ +595 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(i < _s_i_z_e()); │ │ │ │ +596 return BlocklessBaseClass::operator[](i*block_size+j); │ │ │ │ +597 } │ │ │ │ +598 │ │ │ │ +_5_9_9 typename std::vector::const_reference getBit(_s_i_z_e___t_y_p_e i, _s_i_z_e___t_y_p_e │ │ │ │ +j) const { │ │ │ │ +600 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(j < block_size); │ │ │ │ +601 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(i < _s_i_z_e()); │ │ │ │ +602 return BlocklessBaseClass::operator[](i*block_size+j); │ │ │ │ +603 } │ │ │ │ +604 │ │ │ │ +605 friend class _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e; │ │ │ │ +606 friend class _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e; │ │ │ │ +607 }; │ │ │ │ +608 │ │ │ │ +609} // namespace Dune │ │ │ │ +610 │ │ │ │ +611#endif │ │ │ │ +_b_o_u_n_d_s_c_h_e_c_k_i_n_g_._h_h │ │ │ │ +Macro for wrapping boundary checks. │ │ │ │ +_e_x_c_e_p_t_i_o_n_s_._h_h │ │ │ │ +A few common exception classes. │ │ │ │ +_g_e_n_e_r_i_c_i_t_e_r_a_t_o_r_._h_h │ │ │ │ +Implements a generic iterator class for writing stl conformant iterators. │ │ │ │ +_D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S │ │ │ │ +#define DUNE_ASSERT_BOUNDS(cond) │ │ │ │ +If DUNE_CHECK_BOUNDS is defined: check if condition cond holds; otherwise, do │ │ │ │ +nothing. │ │ │ │ +DDeeffiinniittiioonn boundschecking.hh:30 │ │ │ │ +_D_U_N_E___T_H_R_O_W │ │ │ │ +#define DUNE_THROW(E,...) │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:314 │ │ │ │ +_D_u_n_e │ │ │ │ +Dune namespace │ │ │ │ +DDeeffiinniittiioonn alignedallocator.hh:13 │ │ │ │ +_D_u_n_e_:_:_a_s_s_i_g_n │ │ │ │ +void assign(T &dst, const T &src, bool mask) │ │ │ │ +masked Simd assignment (scalar version) │ │ │ │ +DDeeffiinniittiioonn simd.hh:447 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r │ │ │ │ +A dynamic array of blocks of booleans. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:425 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ +const_reference operator[](int i) const │ │ │ │ +Return const reference to i-th block. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:541 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_b_e_g_i_n │ │ │ │ +iterator begin() │ │ │ │ +Returns a iterator pointing to the beginning of the vector. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:462 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_:_:_c_o_n_s_t___p_o_i_n_t_e_r │ │ │ │ +BitSetVectorConstReference< block_size, Alloc > * const_pointer │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:446 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_e_n_d │ │ │ │ +const_iterator end() const │ │ │ │ +Returns a const_iterator pointing to the end of the vector. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:477 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_:_:_r_e_f_e_r_e_n_c_e │ │ │ │ +BitSetVectorReference< block_size, Alloc > reference │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:437 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_c_o_u_n_t_m_a_s_k_e_d │ │ │ │ +size_type countmasked(int j) const │ │ │ │ +Returns the number of set bits, while each block is masked with 1<_:_:_c_o_n_s_t___r_e_f_e_r_e_n_c_e │ │ │ │ +BitSetVectorConstReference< block_size, Alloc > const_reference │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:440 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_e_n_d │ │ │ │ +iterator end() │ │ │ │ +Returns an iterator pointing to the end of the vector. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:472 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_c_o_u_n_t │ │ │ │ +size_type count() const │ │ │ │ +Returns the number of bits that are set. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:559 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_B_i_t_S_e_t_V_e_c_t_o_r │ │ │ │ +BitSetVector() │ │ │ │ +Default constructor. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:482 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_s_e_t_A_l_l │ │ │ │ +void setAll() │ │ │ │ +Sets all entries to true . │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:525 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_:_:_c_o_n_s_t___i_t_e_r_a_t_o_r │ │ │ │ +Dune::GenericIterator< const BitSetVector< block_size, Alloc >, const │ │ │ │ +value_type, const_reference, std::ptrdiff_t, ForwardIteratorFacade > │ │ │ │ +const_iterator │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:458 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_:_:_v_a_l_u_e___t_y_p_e │ │ │ │ +std::bitset< block_size > value_type │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:434 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_b_a_c_k │ │ │ │ +reference back() │ │ │ │ +Return reference to last block. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:547 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_B_i_t_S_e_t_V_e_c_t_o_r │ │ │ │ +BitSetVector(const BlocklessBaseClass &blocklessBitField) │ │ │ │ +Construction from an unblocked bitfield. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:487 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_o_p_e_r_a_t_o_r_<_< │ │ │ │ +friend std::ostream & operator<<(std::ostream &s, const BitSetVector &v) │ │ │ │ +Send bitfield to an output stream. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:575 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_b_a_c_k │ │ │ │ +const_reference back() const │ │ │ │ +Return const reference to last block. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:553 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_c_l_e_a_r │ │ │ │ +void clear() │ │ │ │ +Erases all of the elements. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:507 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_:_:_p_o_i_n_t_e_r │ │ │ │ +BitSetVectorReference< block_size, Alloc > * pointer │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:443 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ +reference operator[](int i) │ │ │ │ +Return reference to i-th block. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:535 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_s_i_z_e │ │ │ │ +size_type size() const │ │ │ │ +Return the number of blocks. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:519 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_:_:_s_i_z_e___t_y_p_e │ │ │ │ +std::vector< bool, Alloc >::size_type size_type │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:449 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_B_i_t_S_e_t_V_e_c_t_o_r │ │ │ │ +BitSetVector(int n, bool v) │ │ │ │ +Constructor which initializes the field with true or false. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:502 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_b_e_g_i_n │ │ │ │ +const_iterator begin() const │ │ │ │ +Returns a const_iterator pointing to the beginning of the vector. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:467 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_:_:_i_t_e_r_a_t_o_r │ │ │ │ +Dune::GenericIterator< BitSetVector< block_size, Alloc >, value_type, │ │ │ │ +reference, std::ptrdiff_t, ForwardIteratorFacade > iterator │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:457 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_r_e_s_i_z_e │ │ │ │ +void resize(int n, bool v=bool()) │ │ │ │ +Resize field. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:513 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_:_:_a_l_l_o_c_a_t_o_r___t_y_p_e │ │ │ │ +Alloc allocator_type │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:452 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_B_i_t_S_e_t_V_e_c_t_o_r │ │ │ │ +BitSetVector(int n) │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:497 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_:_:_u_n_s_e_t_A_l_l │ │ │ │ +void unsetAll() │ │ │ │ +Sets all entries to false . │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:530 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e │ │ │ │ +A proxy class that acts as a mutable reference to a single bitset in a │ │ │ │ +BitSetVector. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:222 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_t_e_s_t │ │ │ │ +bool test(size_type n) const │ │ │ │ +Returns true if bit n is set. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:124 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ +BitSetVectorReference & operator=(const BitSetVectorConstReference &b) │ │ │ │ +Assignment from BitSetVectorConstReference. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:266 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ +reference operator[](size_type i) │ │ │ │ +Return reference to the i-th bit. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:377 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_r_e_s_e_t │ │ │ │ +BitSetVectorReference & reset(size_type n) │ │ │ │ +Clears bit n. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:360 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_<_<_= │ │ │ │ +BitSetVectorReference & operator<<=(size_type n) │ │ │ │ +Left shift. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:318 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r │ │ │ │ +Dune::BitSetVector< block_size, Alloc > BitSetVector │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:225 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_c_o_n_s_t___r_e_f_e_r_e_n_c_e │ │ │ │ +std::vector< bool, Alloc >::const_reference const_reference │ │ │ │ +A proxy class that acts as a const reference to a single bit. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:243 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ +BitSetVectorReference & operator=(const BitSetVectorReference &b) │ │ │ │ +Assignment from BitSetVectorReference. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:274 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_g_e_t_B_i_t │ │ │ │ +reference getBit(size_type i) │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:387 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_&_= │ │ │ │ +BitSetVectorReference & operator&=(const BitSetVectorConstReference &x) │ │ │ │ +Bitwise and (for BitSetVectorConstReference and BitSetVectorReference). │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:288 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e │ │ │ │ +BitSetVectorReference(BitSetVector &blockBitField_, int block_number_) │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:230 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_s_i_z_e___t_y_p_e │ │ │ │ +size_t size_type │ │ │ │ +size_type typedef (an unsigned integral type) │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:247 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ +BitSetVectorReference & operator=(const bitset &b) │ │ │ │ +Assignment from bitset. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:258 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e │ │ │ │ +Dune::BitSetVectorConstReference< block_size, Alloc > │ │ │ │ +BitSetVectorConstReference │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:228 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_r_e_s_e_t │ │ │ │ +BitSetVectorReference & reset() │ │ │ │ +Clears every bit. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:346 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_a_t_o_r_ _>_:_:_b_l_o_c_k_B_i_t_F_i_e_l_d │ │ │ │ +BitSetVector & blockBitField │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:383 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_|_= │ │ │ │ +BitSetVectorReference & operator|=(const BitSetVectorConstReference &x) │ │ │ │ +Bitwise inclusive or (for BitSetVectorConstReference and │ │ │ │ +BitSetVectorReference). │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:300 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_s_e_t │ │ │ │ +BitSetVectorReference & set(size_type n, int val=1) │ │ │ │ +Sets bit n if val is nonzero, and clears bit n if val is zero. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:353 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_b_i_t_s_e_t │ │ │ │ +std::bitset< block_size > bitset │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:236 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_^_= │ │ │ │ +BitSetVectorReference & operator^=(const bitset &x) │ │ │ │ +Bitwise exclusive or (for bitset). │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:306 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_r_e_f_e_r_e_n_c_e │ │ │ │ +std::vector< bool, Alloc >::reference reference │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:241 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_|_= │ │ │ │ +BitSetVectorReference & operator|=(const bitset &x) │ │ │ │ +Bitwise inclusive or (for bitset). │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:294 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_>_>_= │ │ │ │ +BitSetVectorReference & operator>>=(size_type n) │ │ │ │ +Right shift. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:324 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_^_= │ │ │ │ +BitSetVectorReference & operator^=(const BitSetVectorConstReference &x) │ │ │ │ +Bitwise exclusive or (for BitSetVectorConstReference and │ │ │ │ +BitSetVectorReference). │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:312 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_f_l_i_p │ │ │ │ +BitSetVectorReference & flip(size_type n) │ │ │ │ +Flips bit n. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:367 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_f_l_i_p │ │ │ │ +BitSetVectorReference & flip() │ │ │ │ +Flips the value of every bit. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:338 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_s_e_t │ │ │ │ +BitSetVectorReference & set() │ │ │ │ +Sets every bit. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:330 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_&_= │ │ │ │ +BitSetVectorReference & operator&=(const bitset &x) │ │ │ │ +Bitwise and (for bitset). │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:282 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ +BitSetVectorReference & operator=(bool b) │ │ │ │ +Assignment from bool, sets each bit in the bitset to b. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:250 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e │ │ │ │ +A proxy class that acts as a const reference to a single bitset in a │ │ │ │ +BitSetVector. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:38 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_=_= │ │ │ │ +bool operator==(const bitset &bs) const │ │ │ │ +Equality of reference and std::bitset. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:142 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_t_e_s_t │ │ │ │ +bool test(size_type n) const │ │ │ │ +Returns true if bit n is set. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:124 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ +const_reference operator[](size_type i) const │ │ │ │ +Return reference to the i-th bit. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:130 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_<_< │ │ │ │ +bitset operator<<(size_type n) const │ │ │ │ +Returns a copy of *this shifted left by n bits. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:64 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e │ │ │ │ +BitSetVectorConstReference(const BitSetVector &blockBitField_, int │ │ │ │ +block_number_) │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:44 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_a_t_o_r_ _>_:_:_b_l_o_c_k_B_i_t_F_i_e_l_d │ │ │ │ +const BitSetVector & blockBitField │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:181 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_>_> │ │ │ │ +bitset operator>>(size_type n) const │ │ │ │ +Returns a copy of *this shifted right by n bits. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:72 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_g_e_t_B_i_t │ │ │ │ +const_reference getBit(size_type i) const │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:184 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_!_= │ │ │ │ +bool operator!=(const bitset &bs) const │ │ │ │ +Inequality of reference and std::bitset. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:154 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_e_q_u_a_l_s │ │ │ │ +bool equals(const BS &bs) const │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:190 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r │ │ │ │ +Dune::BitSetVector< block_size, Alloc > BitSetVector │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:41 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_b_i_t_s_e_t │ │ │ │ +std::bitset< block_size > bitset │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:56 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_a_l_l │ │ │ │ +bool all() const │ │ │ │ +Returns true if all bits are set. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:115 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_s_i_z_e___t_y_p_e │ │ │ │ +size_t size_type │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:61 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_~ │ │ │ │ +bitset operator~() const │ │ │ │ +Returns a copy of *this with all of its bits flipped. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:80 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_r_e_f_e_r_e_n_c_e │ │ │ │ +std::vector< bool, Alloc >::const_reference reference │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:59 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_s_i_z_e │ │ │ │ +size_type size() const │ │ │ │ +Returns block_size. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:88 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_c_o_u_n_t │ │ │ │ +size_type count() const │ │ │ │ +Returns the number of bits that are set. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:94 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_n_o_n_e │ │ │ │ +bool none() const │ │ │ │ +Returns true if no bits are set. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:109 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_a_n_y │ │ │ │ +bool any() const │ │ │ │ +Returns true if any bits are set. │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:103 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_a_t_o_r_ _>_:_:_b_l_o_c_k___n_u_m_b_e_r │ │ │ │ +int block_number │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:182 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_c_o_n_s_t___r_e_f_e_r_e_n_c_e │ │ │ │ +std::vector< bool, Alloc >::const_reference const_reference │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:60 │ │ │ │ +_D_u_n_e_:_:_B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ +BitSetVectorConstReference & operator=(const BitSetVectorConstReference │ │ │ │ +&b)=delete │ │ │ │ +disable assignment operator │ │ │ │ +_D_u_n_e_:_:_c_o_n_s_t___r_e_f_e_r_e_n_c_e_<_ _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_ _>_:_:_t_y_p_e │ │ │ │ +BitSetVectorConstReference< block_size, Alloc > type │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:399 │ │ │ │ +_D_u_n_e_:_:_c_o_n_s_t___r_e_f_e_r_e_n_c_e_<_ _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_ _>_:_:_t_y_p_e │ │ │ │ +BitSetVectorConstReference< block_size, Alloc > type │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:405 │ │ │ │ +_D_u_n_e_:_:_m_u_t_a_b_l_e___r_e_f_e_r_e_n_c_e_<_ _B_i_t_S_e_t_V_e_c_t_o_r_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_ _>_:_:_t_y_p_e │ │ │ │ +BitSetVectorReference< block_size, Alloc > type │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:411 │ │ │ │ +_D_u_n_e_:_:_m_u_t_a_b_l_e___r_e_f_e_r_e_n_c_e_<_ _B_i_t_S_e_t_V_e_c_t_o_r_C_o_n_s_t_R_e_f_e_r_e_n_c_e_<_ _b_l_o_c_k___s_i_z_e_,_ _A_l_l_o_c_ _>_ _>_:_: │ │ │ │ +_t_y_p_e │ │ │ │ +BitSetVectorReference< block_size, Alloc > type │ │ │ │ +DDeeffiinniittiioonn bitsetvector.hh:417 │ │ │ │ +_D_u_n_e_:_:_R_a_n_g_e_E_r_r_o_r │ │ │ │ +Default exception class for range errors. │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:348 │ │ │ │ +_D_u_n_e_:_:_c_o_n_s_t___r_e_f_e_r_e_n_c_e │ │ │ │ +Get the 'const' version of a reference to a mutable object. │ │ │ │ +DDeeffiinniittiioonn genericiterator.hh:87 │ │ │ │ +_D_u_n_e_:_:_m_u_t_a_b_l_e___r_e_f_e_r_e_n_c_e │ │ │ │ +get the 'mutable' version of a reference to a const object │ │ │ │ +DDeeffiinniittiioonn genericiterator.hh:116 │ │ │ │ +_D_u_n_e_:_:_G_e_n_e_r_i_c_I_t_e_r_a_t_o_r │ │ │ │ +Generic class for stl-conforming iterators for container classes with operator │ │ │ │ +[]. │ │ │ │ +DDeeffiinniittiioonn genericiterator.hh:153 │ │ │ │ +_D_u_n_e_:_:_F_o_r_w_a_r_d_I_t_e_r_a_t_o_r_F_a_c_a_d_e │ │ │ │ +Base class for stl conformant forward iterators. │ │ │ │ +DDeeffiinniittiioonn iteratorfacades.hh:142 │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00011.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: version.hh File Reference │ │ │ +dune-common: sllist.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -72,574 +72,55 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ -Macros
│ │ │ -
version.hh File Reference
│ │ │ +Classes | │ │ │ +Namespaces | │ │ │ +Functions
│ │ │ +
sllist.hh File Reference
│ │ │
│ │ │
│ │ │ │ │ │ -

Various macros to work with Dune module version numbers. │ │ │ +

Implements a singly linked list together with the necessary iterators. │ │ │ More...

│ │ │ -
#include <dune-common-config.hh>
│ │ │ +
#include <memory>
│ │ │ +#include <cassert>
│ │ │ +#include "iteratorfacades.hh"
│ │ │ +#include <ostream>
│ │ │
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ +

│ │ │ -Macros

#define DUNE_VERSION_JOIN(module, type)
 Constructs the preprocessor name used in config.h to hold version numbers.
#define DUNE_VERSION_EQUAL(module, major, minor)
 True if 'module' has the version major.minor.
#define DUNE_VERSION_EQUAL_REV(module, major, minor, revision)
 True if 'module' has the version major.minor.revision.
#define DUNE_VERSION_GTE(module, major, minor)
 True if 'module' has the version major.minor or greater.
#define DUNE_VERSION_LT(module, major, minor)
 True if 'module' has a version less than major.minor.
#define DUNE_VERSION_GT(module, major, minor)
 True if 'module' has a version greater than major.minor.
#define DUNE_VERSION_LTE(module, major, minor)
 True if 'module' has a version less than or equal to major.minor.
#define DUNE_VERSION_GTE_REV(module, major, minor, revision)
 True if 'module' has the version major.minor.revision or greater.
#define DUNE_VERSION_LT_REV(module, major, minor, revision)
 True if 'module' has a version lower than major.minor.revision.
#define DUNE_VERSION_GT_REV(module, major, minor, revision)
 True if 'module' has a greater version than major.minor.revision.
#define DUNE_VERSION_LTE_REV(module, major, minor, revision)
 True if 'module' has a version lower or equal to major.minor.revision.
#define DUNE_VERSION_ID(major, minor, revision)
 Compute a unique uint id from the major, minor, and revision numbers.
#define DUNE_MODULE_VERSION_ID(module)
 Compute a unique uint id for the given module.

│ │ │ +Classes

class  Dune::SLList< T, A >
 A single linked list. More...
class  Dune::SLListIterator< T, A >
 A mutable iterator for the SLList. More...
class  Dune::SLListConstIterator< T, A >
 A constant iterator for the SLList. More...
class  Dune::SLListModifyIterator< T, A >
 A mutable iterator for the SLList. More...
│ │ │ + │ │ │ + │ │ │ + │ │ │ +

│ │ │ +Namespaces

namespace  Dune
 Dune namespace
│ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ +Functions

template<typename T, typename A>
std::ostream & Dune::operator<< (std::ostream &os, const SLList< T, A > &sllist)
│ │ │

Detailed Description

│ │ │ -

Various macros to work with Dune module version numbers.

│ │ │ -

Macro Definition Documentation

│ │ │ - │ │ │ -

◆ DUNE_MODULE_VERSION_ID

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_MODULE_VERSION_ID( module)
│ │ │ -
│ │ │ -Value:
DUNE_VERSION_ID( DUNE_VERSION_JOIN(module,MAJOR), DUNE_VERSION_JOIN(module,MINOR), DUNE_VERSION_JOIN(module,REVISION) )
│ │ │ -
#define DUNE_VERSION_JOIN(module, type)
Constructs the preprocessor name used in config.h to hold version numbers.
Definition version.hh:30
│ │ │ -
#define DUNE_VERSION_ID(major, minor, revision)
Compute a unique uint id from the major, minor, and revision numbers.
Definition version.hh:226
│ │ │ -
│ │ │ -

Compute a unique uint id for the given module.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_EQUAL

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_EQUAL( module,
major,
minor )
│ │ │ -
│ │ │ -Value:
((DUNE_VERSION_JOIN(module,MAJOR) == major) && \
│ │ │ -
(DUNE_VERSION_JOIN(module,MINOR) == minor))
│ │ │ -
│ │ │ -

True if 'module' has the version major.minor.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_EQUAL_REV

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_EQUAL_REV( module,
major,
minor,
revision )
│ │ │ -
│ │ │ -Value:
( DUNE_VERSION_EQUAL(module,major,minor) && \
│ │ │ -
(DUNE_VERSION_JOIN(module,REVISION) == revision))
│ │ │ -
#define DUNE_VERSION_EQUAL(module, major, minor)
True if 'module' has the version major.minor.
Definition version.hh:46
│ │ │ -
│ │ │ -

True if 'module' has the version major.minor.revision.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_GT

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_GT( module,
major,
minor )
│ │ │ -
│ │ │ -Value:
((DUNE_VERSION_JOIN(module,MAJOR) > major) \
│ │ │ -
|| ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) > minor)))
│ │ │ -
│ │ │ -

True if 'module' has a version greater than major.minor.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_GT_REV

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_GT_REV( module,
major,
minor,
revision )
│ │ │ -
│ │ │ -Value:
((DUNE_VERSION_JOIN(module,MAJOR) > major) \
│ │ │ -
|| ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) > minor)) \
│ │ │ -
|| ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) == minor) \
│ │ │ -
&& (DUNE_VERSION_JOIN(module,REVISION) > revision)))
│ │ │ -
│ │ │ -

True if 'module' has a greater version than major.minor.revision.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_GTE

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_GTE( module,
major,
minor )
│ │ │ -
│ │ │ -Value:
((DUNE_VERSION_JOIN(module,MAJOR) > major) \
│ │ │ -
|| ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) >= minor)))
│ │ │ -
│ │ │ -

True if 'module' has the version major.minor or greater.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_GTE_REV

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_GTE_REV( module,
major,
minor,
revision )
│ │ │ -
│ │ │ -Value:
((DUNE_VERSION_JOIN(module,MAJOR) > major) \
│ │ │ -
|| ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) > minor)) \
│ │ │ -
|| ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) == minor) \
│ │ │ -
&& (DUNE_VERSION_JOIN(module,REVISION) >= revision)))
│ │ │ -
│ │ │ -

True if 'module' has the version major.minor.revision or greater.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_ID

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_ID( major,
minor,
revision )
│ │ │ -
│ │ │ -Value:
((unsigned int)((major << 24) + (minor << 16) + revision))
│ │ │ -
│ │ │ -

Compute a unique uint id from the major, minor, and revision numbers.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_JOIN

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_JOIN( module,
type )
│ │ │ -
│ │ │ -Value:
module ## _VERSION_ ## type
│ │ │ -
│ │ │ -

Constructs the preprocessor name used in config.h to hold version numbers.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ -
Parameters
│ │ │ - │ │ │ - │ │ │ - │ │ │ -
moduleThe name of the Dune module
typeThe version number type, one of MAJOR, MINOR, or REVISION
│ │ │ -
│ │ │ -
│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_LT

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_LT( module,
major,
minor )
│ │ │ -
│ │ │ -Value:
! DUNE_VERSION_GTE(module,major,minor)
│ │ │ -
#define DUNE_VERSION_GTE(module, major, minor)
True if 'module' has the version major.minor or greater.
Definition version.hh:82
│ │ │ -
│ │ │ -

True if 'module' has a version less than major.minor.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_LT_REV

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_LT_REV( module,
major,
minor,
revision )
│ │ │ -
│ │ │ -Value:
! DUNE_VERSION_GTE_REV(module,major,minor,revision)
│ │ │ -
#define DUNE_VERSION_GTE_REV(module, major, minor, revision)
True if 'module' has the version major.minor.revision or greater.
Definition version.hh:152
│ │ │ -
│ │ │ -

True if 'module' has a version lower than major.minor.revision.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_LTE

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_LTE( module,
major,
minor )
│ │ │ -
│ │ │ -Value:
! DUNE_VERSION_GT(module,major,minor)
│ │ │ -
#define DUNE_VERSION_GT(module, major, minor)
True if 'module' has a version greater than major.minor.
Definition version.hh:117
│ │ │ -
│ │ │ -

True if 'module' has a version less than or equal to major.minor.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ -

◆ DUNE_VERSION_LTE_REV

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
#define DUNE_VERSION_LTE_REV( module,
major,
minor,
revision )
│ │ │ -
│ │ │ -Value:
! DUNE_VERSION_GT_REV(module,major,minor,revision)
│ │ │ -
#define DUNE_VERSION_GT_REV(module, major, minor, revision)
True if 'module' has a greater version than major.minor.revision.
Definition version.hh:189
│ │ │ -
│ │ │ -

True if 'module' has a version lower or equal to major.minor.revision.

│ │ │ -

For the DUNE core modules you need to use the following module names:

    │ │ │ -
  • DUNE_COMMON for dune-common
  • │ │ │ -
  • DUNE_GRID for dune-grid
  • │ │ │ -
  • DUNE_GEOMETRY for dune-geometry
  • │ │ │ -
  • DUNE_ISTL for dune-istl
  • │ │ │ -
  • DUNE_LOCALFUNCTIONS for dune-localfunctions
  • │ │ │ -
│ │ │ -

For external DUNE modules, you should capitalize the name and replace '-' by underscores. For example for the module foo-bar you need to use FOO_BAR as module name in the context of this macro.

│ │ │ - │ │ │ -
│ │ │ -
│ │ │ -
│ │ │ +

Implements a singly linked list together with the necessary iterators.

│ │ │ +
Author
Markus Blatt
│ │ │ +
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,302 +1,37 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -_M_a_c_r_o_s │ │ │ │ -version.hh File Reference │ │ │ │ -Various macros to work with Dune module version numbers. _M_o_r_e_._._. │ │ │ │ -#include │ │ │ │ +_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _F_u_n_c_t_i_o_n_s │ │ │ │ +sllist.hh File Reference │ │ │ │ +_C_o_m_m_o_n │ │ │ │ +Implements a singly linked list together with the necessary iterators. _M_o_r_e_._._. │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include "_i_t_e_r_a_t_o_r_f_a_c_a_d_e_s_._h_h" │ │ │ │ +#include │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -MMaaccrrooss │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module, type) │ │ │ │ -  Constructs the preprocessor name used in config.h to hold version │ │ │ │ - numbers. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___E_Q_U_A_L(module, major, minor) │ │ │ │ -  True if 'module' has the version major.minor. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___E_Q_U_A_L___R_E_V(module, major, minor, revision) │ │ │ │ -  True if 'module' has the version major.minor.revision. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___G_T_E(module, major, minor) │ │ │ │ -  True if 'module' has the version major.minor or greater. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___L_T(module, major, minor) │ │ │ │ -  True if 'module' has a version less than major.minor. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___G_T(module, major, minor) │ │ │ │ -  True if 'module' has a version greater than major.minor. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___L_T_E(module, major, minor) │ │ │ │ -  True if 'module' has a version less than or equal to major.minor. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___G_T_E___R_E_V(module, major, minor, revision) │ │ │ │ -  True if 'module' has the version major.minor.revision or greater. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___L_T___R_E_V(module, major, minor, revision) │ │ │ │ -  True if 'module' has a version lower than major.minor.revision. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___G_T___R_E_V(module, major, minor, revision) │ │ │ │ -  True if 'module' has a greater version than major.minor.revision. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___L_T_E___R_E_V(module, major, minor, revision) │ │ │ │ -  True if 'module' has a version lower or equal to major.minor.revision. │ │ │ │ -#define  _D_U_N_E___V_E_R_S_I_O_N___I_D(major, minor, revision) │ │ │ │ -  Compute a unique uint id from the major, minor, and revision numbers. │ │ │ │ -#define  _D_U_N_E___M_O_D_U_L_E___V_E_R_S_I_O_N___I_D(module) │ │ │ │ -  Compute a unique uint id for the given module. │ │ │ │ +CCllaasssseess │ │ │ │ +class   _D_u_n_e_:_:_S_L_L_i_s_t_<_ _T_,_ _A_ _> │ │ │ │ +  A single linked list. _M_o_r_e_._._. │ │ │ │ +class   _D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_ _T_,_ _A_ _> │ │ │ │ +  A mutable iterator for the _S_L_L_i_s_t. _M_o_r_e_._._. │ │ │ │ +class   _D_u_n_e_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_<_ _T_,_ _A_ _> │ │ │ │ +  A constant iterator for the _S_L_L_i_s_t. _M_o_r_e_._._. │ │ │ │ +class   _D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_ _T_,_ _A_ _> │ │ │ │ +  A mutable iterator for the _S_L_L_i_s_t. _M_o_r_e_._._. │ │ │ │ +NNaammeessppaacceess │ │ │ │ +namespace   _D_u_n_e │ │ │ │ +  Dune namespace │ │ │ │ +FFuunnccttiioonnss │ │ │ │ +template │ │ │ │ +std::ostream &  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_<_< (std::ostream &os, const _S_L_L_i_s_t< T, A > │ │ │ │ + &sllist) │ │ │ │ ********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ -Various macros to work with Dune module version numbers. │ │ │ │ -********** MMaaccrroo DDeeffiinniittiioonn DDooccuummeennttaattiioonn ********** │ │ │ │ -********** _?◆_? DDUUNNEE__MMOODDUULLEE__VVEERRSSIIOONN__IIDD ********** │ │ │ │ -#define DUNE_MODULE_VERSION_ID ( mmoodduullee ) │ │ │ │ -VVaalluuee:: │ │ │ │ -_D_U_N_E___V_E_R_S_I_O_N___I_D( _D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR), _D_U_N_E___V_E_R_S_I_O_N___J_O_I_N │ │ │ │ -(module,MINOR), _D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,REVISION) ) │ │ │ │ -_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N │ │ │ │ -#define DUNE_VERSION_JOIN(module, type) │ │ │ │ -Constructs the preprocessor name used in config.h to hold version numbers. │ │ │ │ -DDeeffiinniittiioonn version.hh:30 │ │ │ │ -_D_U_N_E___V_E_R_S_I_O_N___I_D │ │ │ │ -#define DUNE_VERSION_ID(major, minor, revision) │ │ │ │ -Compute a unique uint id from the major, minor, and revision numbers. │ │ │ │ -DDeeffiinniittiioonn version.hh:226 │ │ │ │ -Compute a unique uint id for the given module. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__EEQQUUAALL ********** │ │ │ │ -#define DUNE_VERSION_EQUAL ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr ) │ │ │ │ -VVaalluuee:: │ │ │ │ -((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) == major) && \ │ │ │ │ -(_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MINOR) == minor)) │ │ │ │ -True if 'module' has the version major.minor. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__EEQQUUAALL__RREEVV ********** │ │ │ │ -#define DUNE_VERSION_EQUAL_REV ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr, │ │ │ │ - rreevviissiioonn ) │ │ │ │ -VVaalluuee:: │ │ │ │ -( _D_U_N_E___V_E_R_S_I_O_N___E_Q_U_A_L(module,major,minor) && \ │ │ │ │ -(_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,REVISION) == revision)) │ │ │ │ -_D_U_N_E___V_E_R_S_I_O_N___E_Q_U_A_L │ │ │ │ -#define DUNE_VERSION_EQUAL(module, major, minor) │ │ │ │ -True if 'module' has the version major.minor. │ │ │ │ -DDeeffiinniittiioonn version.hh:46 │ │ │ │ -True if 'module' has the version major.minor.revision. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__GGTT ********** │ │ │ │ -#define DUNE_VERSION_GT ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr ) │ │ │ │ -VVaalluuee:: │ │ │ │ -((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) > major) \ │ │ │ │ -|| ((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) == major) && (_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N │ │ │ │ -(module,MINOR) > minor))) │ │ │ │ -True if 'module' has a version greater than major.minor. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__GGTT__RREEVV ********** │ │ │ │ -#define DUNE_VERSION_GT_REV ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr, │ │ │ │ - rreevviissiioonn ) │ │ │ │ -VVaalluuee:: │ │ │ │ -((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) > major) \ │ │ │ │ -|| ((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) == major) && (_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N │ │ │ │ -(module,MINOR) > minor)) \ │ │ │ │ -|| ((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) == major) && (_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N │ │ │ │ -(module,MINOR) == minor) \ │ │ │ │ -&& (_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,REVISION) > revision))) │ │ │ │ -True if 'module' has a greater version than major.minor.revision. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__GGTTEE ********** │ │ │ │ -#define DUNE_VERSION_GTE ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr ) │ │ │ │ -VVaalluuee:: │ │ │ │ -((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) > major) \ │ │ │ │ -|| ((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) == major) && (_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N │ │ │ │ -(module,MINOR) >= minor))) │ │ │ │ -True if 'module' has the version major.minor or greater. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__GGTTEE__RREEVV ********** │ │ │ │ -#define DUNE_VERSION_GTE_REV ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr, │ │ │ │ - rreevviissiioonn ) │ │ │ │ -VVaalluuee:: │ │ │ │ -((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) > major) \ │ │ │ │ -|| ((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) == major) && (_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N │ │ │ │ -(module,MINOR) > minor)) \ │ │ │ │ -|| ((_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,MAJOR) == major) && (_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N │ │ │ │ -(module,MINOR) == minor) \ │ │ │ │ -&& (_D_U_N_E___V_E_R_S_I_O_N___J_O_I_N(module,REVISION) >= revision))) │ │ │ │ -True if 'module' has the version major.minor.revision or greater. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__IIDD ********** │ │ │ │ -#define DUNE_VERSION_ID ( mmaajjoorr, │ │ │ │ - mmiinnoorr, │ │ │ │ - rreevviissiioonn ) │ │ │ │ -VVaalluuee:: │ │ │ │ -((unsigned int)((major << 24) + (minor << 16) + revision)) │ │ │ │ -Compute a unique uint id from the major, minor, and revision numbers. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__JJOOIINN ********** │ │ │ │ -#define DUNE_VERSION_JOIN ( mmoodduullee, │ │ │ │ - ttyyppee ) │ │ │ │ -VVaalluuee:: │ │ │ │ -module ## _VERSION_ ## type │ │ │ │ -Constructs the preprocessor name used in config.h to hold version numbers. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ - Parameters │ │ │ │ - module The name of the _D_u_n_e module │ │ │ │ - type The version number type, one of MAJOR, MINOR, or REVISION │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__LLTT ********** │ │ │ │ -#define DUNE_VERSION_LT ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr ) │ │ │ │ -VVaalluuee:: │ │ │ │ -! _D_U_N_E___V_E_R_S_I_O_N___G_T_E(module,major,minor) │ │ │ │ -_D_U_N_E___V_E_R_S_I_O_N___G_T_E │ │ │ │ -#define DUNE_VERSION_GTE(module, major, minor) │ │ │ │ -True if 'module' has the version major.minor or greater. │ │ │ │ -DDeeffiinniittiioonn version.hh:82 │ │ │ │ -True if 'module' has a version less than major.minor. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__LLTT__RREEVV ********** │ │ │ │ -#define DUNE_VERSION_LT_REV ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr, │ │ │ │ - rreevviissiioonn ) │ │ │ │ -VVaalluuee:: │ │ │ │ -! _D_U_N_E___V_E_R_S_I_O_N___G_T_E___R_E_V(module,major,minor,revision) │ │ │ │ -_D_U_N_E___V_E_R_S_I_O_N___G_T_E___R_E_V │ │ │ │ -#define DUNE_VERSION_GTE_REV(module, major, minor, revision) │ │ │ │ -True if 'module' has the version major.minor.revision or greater. │ │ │ │ -DDeeffiinniittiioonn version.hh:152 │ │ │ │ -True if 'module' has a version lower than major.minor.revision. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__LLTTEE ********** │ │ │ │ -#define DUNE_VERSION_LTE ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr ) │ │ │ │ -VVaalluuee:: │ │ │ │ -! _D_U_N_E___V_E_R_S_I_O_N___G_T(module,major,minor) │ │ │ │ -_D_U_N_E___V_E_R_S_I_O_N___G_T │ │ │ │ -#define DUNE_VERSION_GT(module, major, minor) │ │ │ │ -True if 'module' has a version greater than major.minor. │ │ │ │ -DDeeffiinniittiioonn version.hh:117 │ │ │ │ -True if 'module' has a version less than or equal to major.minor. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ -********** _?◆_? DDUUNNEE__VVEERRSSIIOONN__LLTTEE__RREEVV ********** │ │ │ │ -#define DUNE_VERSION_LTE_REV ( mmoodduullee, │ │ │ │ - mmaajjoorr, │ │ │ │ - mmiinnoorr, │ │ │ │ - rreevviissiioonn ) │ │ │ │ -VVaalluuee:: │ │ │ │ -! _D_U_N_E___V_E_R_S_I_O_N___G_T___R_E_V(module,major,minor,revision) │ │ │ │ -_D_U_N_E___V_E_R_S_I_O_N___G_T___R_E_V │ │ │ │ -#define DUNE_VERSION_GT_REV(module, major, minor, revision) │ │ │ │ -True if 'module' has a greater version than major.minor.revision. │ │ │ │ -DDeeffiinniittiioonn version.hh:189 │ │ │ │ -True if 'module' has a version lower or equal to major.minor.revision. │ │ │ │ -For the DUNE core modules you need to use the following module names: │ │ │ │ - * DUNE_COMMON for dune-common │ │ │ │ - * DUNE_GRID for dune-grid │ │ │ │ - * DUNE_GEOMETRY for dune-geometry │ │ │ │ - * DUNE_ISTL for dune-istl │ │ │ │ - * DUNE_LOCALFUNCTIONS for dune-localfunctions │ │ │ │ -For external DUNE modules, you should capitalize the name and replace '-' by │ │ │ │ -underscores. For example for the module foo-bar you need to use FOO_BAR as │ │ │ │ -module name in the context of this macro. │ │ │ │ +Implements a singly linked list together with the necessary iterators. │ │ │ │ + Author │ │ │ │ + Markus Blatt │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00011_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: version.hh Source File │ │ │ +dune-common: sllist.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -71,100 +71,741 @@ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
version.hh
│ │ │ +
sllist.hh
│ │ │
│ │ │
│ │ │ Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │
2// vi: set et ts=4 sw=2 sts=2:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ -
5#ifndef DUNE_VERSION_HH
│ │ │ -
6#define DUNE_VERSION_HH
│ │ │ +
5#ifndef DUNE_SLLIST_HH
│ │ │ +
6#define DUNE_SLLIST_HH
│ │ │
7
│ │ │ -
8#include <dune-common-config.hh> // DUNE_[MODULE]_VERSION_[TYPE]
│ │ │ -
9
│ │ │ -
13
│ │ │ -
30#define DUNE_VERSION_JOIN(module,type) module ## _VERSION_ ## type
│ │ │ -
31
│ │ │ -
│ │ │ -
46#define DUNE_VERSION_EQUAL(module,major,minor) \
│ │ │ -
47 ((DUNE_VERSION_JOIN(module,MAJOR) == major) && \
│ │ │ -
48 (DUNE_VERSION_JOIN(module,MINOR) == minor))
│ │ │ -
│ │ │ -
49
│ │ │ -
│ │ │ -
64#define DUNE_VERSION_EQUAL_REV(module,major,minor,revision) \
│ │ │ -
65 ( DUNE_VERSION_EQUAL(module,major,minor) && \
│ │ │ -
66 (DUNE_VERSION_JOIN(module,REVISION) == revision))
│ │ │ -
│ │ │ -
67
│ │ │ -
│ │ │ -
82#define DUNE_VERSION_GTE(module,major,minor) \
│ │ │ -
83 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \
│ │ │ -
84 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) >= minor)))
│ │ │ -
│ │ │ -
85
│ │ │ -
│ │ │ -
100#define DUNE_VERSION_LT(module,major,minor) \
│ │ │ -
101 ! DUNE_VERSION_GTE(module,major,minor)
│ │ │ -
│ │ │ -
102
│ │ │ -
│ │ │ -
117#define DUNE_VERSION_GT(module,major,minor) \
│ │ │ -
118 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \
│ │ │ -
119 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) > minor)))
│ │ │ -
│ │ │ -
120
│ │ │ -
│ │ │ -
135#define DUNE_VERSION_LTE(module,major,minor) \
│ │ │ -
136 ! DUNE_VERSION_GT(module,major,minor)
│ │ │ -
│ │ │ -
137
│ │ │ -
│ │ │ -
152#define DUNE_VERSION_GTE_REV(module,major,minor,revision) \
│ │ │ -
153 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \
│ │ │ -
154 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) > minor)) \
│ │ │ -
155 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) == minor) \
│ │ │ -
156 && (DUNE_VERSION_JOIN(module,REVISION) >= revision)))
│ │ │ -
│ │ │ +
8#include <memory>
│ │ │ +
9#include <cassert>
│ │ │ +
10#include "iteratorfacades.hh"
│ │ │ +
11#include <ostream>
│ │ │ +
12
│ │ │ +
13namespace Dune
│ │ │ +
14{
│ │ │ +
26 template<typename T, class A>
│ │ │ +
27 class SLListIterator;
│ │ │ +
28
│ │ │ +
29 template<typename T, class A>
│ │ │ + │ │ │ +
31
│ │ │ +
32 template<typename T, class A>
│ │ │ + │ │ │ +
34
│ │ │ +
42 template<typename T, class A=std::allocator<T> >
│ │ │ +
│ │ │ +
43 class SLList
│ │ │ +
44 {
│ │ │ +
45 struct Element;
│ │ │ +
46 friend class SLListIterator<T,A>;
│ │ │ +
47 friend class SLListConstIterator<T,A>;
│ │ │ +
48
│ │ │ +
49 public:
│ │ │ +
50
│ │ │ +
54 typedef typename A::size_type size_type;
│ │ │ +
55
│ │ │ +
59 typedef T MemberType;
│ │ │ +
60
│ │ │ +
64 using Allocator = typename std::allocator_traits<A>::template rebind_alloc<Element>;
│ │ │ +
65
│ │ │ + │ │ │ +
70
│ │ │ + │ │ │ +
75
│ │ │ + │ │ │ +
80
│ │ │ +
84 template<typename T1, typename A1>
│ │ │ +
85 SLList(const SLList<T1,A1>& other);
│ │ │ +
86
│ │ │ +
90 SLList(const SLList<T,A>& other);
│ │ │ +
91
│ │ │ + │ │ │ +
98
│ │ │ + │ │ │ +
104
│ │ │ + │ │ │ +
109
│ │ │ +
110
│ │ │ +
115 inline void push_back(const MemberType& item);
│ │ │ +
116
│ │ │ +
121 inline void push_front(const MemberType& item);
│ │ │ +
122
│ │ │ +
126 inline void pop_front();
│ │ │ +
127
│ │ │ +
129 inline void clear();
│ │ │ +
130
│ │ │ +
138 inline iterator begin();
│ │ │ +
139
│ │ │ +
147 inline const_iterator begin() const;
│ │ │ +
148
│ │ │ + │ │ │
157
│ │ │ -
│ │ │ -
172#define DUNE_VERSION_LT_REV(module,major,minor,revision) \
│ │ │ -
173 ! DUNE_VERSION_GTE_REV(module,major,minor,revision)
│ │ │ -
│ │ │ + │ │ │ +
166
│ │ │ +
173 inline iterator end();
│ │ │
174
│ │ │ -
│ │ │ -
189#define DUNE_VERSION_GT_REV(module,major,minor,revision) \
│ │ │ -
190 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \
│ │ │ -
191 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) > minor)) \
│ │ │ -
192 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN(module,MINOR) == minor) \
│ │ │ -
193 && (DUNE_VERSION_JOIN(module,REVISION) > revision)))
│ │ │ -
│ │ │ -
194
│ │ │ -
│ │ │ -
209#define DUNE_VERSION_LTE_REV(module,major,minor,revision) \
│ │ │ -
210 ! DUNE_VERSION_GT_REV(module,major,minor,revision)
│ │ │ -
│ │ │ -
211
│ │ │ -
│ │ │ -
226#define DUNE_VERSION_ID(major,minor,revision) \
│ │ │ -
227 ((unsigned int)((major << 24) + (minor << 16) + revision))
│ │ │ -
│ │ │ -
228
│ │ │ -
│ │ │ -
243#define DUNE_MODULE_VERSION_ID(module) \
│ │ │ -
244 DUNE_VERSION_ID( DUNE_VERSION_JOIN(module,MAJOR), DUNE_VERSION_JOIN(module,MINOR), DUNE_VERSION_JOIN(module,REVISION) )
│ │ │ -
│ │ │ -
245
│ │ │ -
246#endif
│ │ │ +
181 inline const_iterator end() const;
│ │ │ +
182
│ │ │ +
188 inline bool empty() const;
│ │ │ +
189
│ │ │ +
194 inline int size() const;
│ │ │ +
195
│ │ │ +
196 bool operator==(const SLList& sl) const;
│ │ │ +
197
│ │ │ +
198
│ │ │ +
199 bool operator!=(const SLList& sl) const;
│ │ │ +
200
│ │ │ +
201 private:
│ │ │ +
203 struct Element
│ │ │ +
204 {
│ │ │ + │ │ │ + │ │ │ +
213
│ │ │ +
│ │ │ +
214 Element(const MemberType& item, Element* next_=0);
│ │ │ +
215
│ │ │ +
216 Element();
│ │ │ +
217
│ │ │ + │ │ │ +
219 };
│ │ │ +
220
│ │ │ +
225 void deleteNext(Element* current);
│ │ │ +
226
│ │ │ +
231 void copyElements(const SLList<T,A>& other);
│ │ │ +
232
│ │ │ +
240 template<bool watchForTail>
│ │ │ +
241 void deleteNext(Element* current);
│ │ │ +
247 void insertAfter(Element* current, const T& item);
│ │ │ +
248
│ │ │ +
250 Element beforeHead_;
│ │ │ +
251
│ │ │ +
257 Element* tail_;
│ │ │ +
258
│ │ │ +
260 Allocator allocator_;
│ │ │ +
261
│ │ │ +
263 int size_;
│ │ │ +
264 };
│ │ │ +
265
│ │ │ +
269 template<typename T, class A>
│ │ │ +
│ │ │ +
270 class SLListIterator : public Dune::ForwardIteratorFacade<SLListIterator<T,A>, T, T&, std::size_t>
│ │ │ +
271 {
│ │ │ +
272 friend class SLListConstIterator<T,A>;
│ │ │ +
273 friend class SLListModifyIterator<T,A>;
│ │ │ +
274 friend class SLList<T,A>;
│ │ │ +
275
│ │ │ +
276 public:
│ │ │ +
│ │ │ +
277 inline SLListIterator(typename SLList<T,A>::Element* item,
│ │ │ +
278 SLList<T,A>* sllist)
│ │ │ +
279 : current_(item), list_(sllist)
│ │ │ +
280 {}
│ │ │ +
│ │ │ +
281
│ │ │ +
│ │ │ + │ │ │ +
283 : current_(0), list_(0)
│ │ │ +
284 {}
│ │ │ +
│ │ │ +
285
│ │ │ +
│ │ │ + │ │ │ +
287 : current_(other.iterator_.current_), list_(other.iterator_.list_)
│ │ │ +
288 {}
│ │ │ +
│ │ │ +
289
│ │ │ +
│ │ │ +
294 inline T& dereference() const
│ │ │ +
295 {
│ │ │ +
296 return current_->item_;
│ │ │ +
297 }
│ │ │ +
│ │ │ +
298
│ │ │ +
│ │ │ +
304 inline bool equals(const SLListConstIterator<T,A>& other) const
│ │ │ +
305 {
│ │ │ +
306 return current_==other.current_;
│ │ │ +
307 }
│ │ │ +
│ │ │ +
308
│ │ │ +
│ │ │ +
314 inline bool equals(const SLListIterator<T,A>& other) const
│ │ │ +
315 {
│ │ │ +
316 return current_==other.current_;
│ │ │ +
317 }
│ │ │ +
│ │ │ +
318
│ │ │ +
│ │ │ +
324 inline bool equals(const SLListModifyIterator<T,A>& other) const
│ │ │ +
325 {
│ │ │ +
326 return current_==other.iterator_.current_;
│ │ │ +
327 }
│ │ │ +
│ │ │ +
328
│ │ │ +
│ │ │ +
332 inline void increment()
│ │ │ +
333 {
│ │ │ +
334 current_ = current_->next_;
│ │ │ +
335 }
│ │ │ +
│ │ │ +
336
│ │ │ +
│ │ │ +
342 inline void insertAfter(const T& v) const
│ │ │ +
343 {
│ │ │ +
344 assert(list_ );
│ │ │ +
345 list_->insertAfter(current_, v);
│ │ │ +
346 }
│ │ │ +
│ │ │ +
347
│ │ │ +
│ │ │ +
353 inline void deleteNext() const
│ │ │ +
354 {
│ │ │ +
355 assert(list_);
│ │ │ +
356 list_->deleteNext(current_);
│ │ │ +
357 }
│ │ │ +
│ │ │ +
358
│ │ │ +
359 private:
│ │ │ +
361 typename SLList<T,A>::Element* current_;
│ │ │ + │ │ │ +
364 };
│ │ │ +
│ │ │ +
365
│ │ │ +
369 template<class T, class A>
│ │ │ +
│ │ │ +
370 class SLListConstIterator : public Dune::ForwardIteratorFacade<SLListConstIterator<T,A>, const T, const T&, std::size_t>
│ │ │ +
371 {
│ │ │ +
372 friend class SLListIterator<T,A>;
│ │ │ +
373 friend class SLList<T,A>;
│ │ │ +
374
│ │ │ +
375 public:
│ │ │ +
│ │ │ + │ │ │ +
377 : current_(0)
│ │ │ +
378 {}
│ │ │ +
│ │ │ +
379
│ │ │ +
│ │ │ +
380 inline SLListConstIterator(typename SLList<T,A>::Element* item)
│ │ │ +
381 : current_(item)
│ │ │ +
382 {}
│ │ │ +
│ │ │ +
383
│ │ │ +
│ │ │ + │ │ │ +
385 : current_(other.current_)
│ │ │ +
386 {}
│ │ │ +
│ │ │ +
387
│ │ │ +
│ │ │ + │ │ │ +
389 : current_(other.iterator_.current_)
│ │ │ +
390 {}
│ │ │ +
│ │ │ +
391
│ │ │ +
│ │ │ +
396 inline const T& dereference() const
│ │ │ +
397 {
│ │ │ +
398 return current_->item_;
│ │ │ +
399 }
│ │ │ +
│ │ │ +
400
│ │ │ +
│ │ │ +
406 inline bool equals(const SLListConstIterator<T,A>& other) const
│ │ │ +
407 {
│ │ │ +
408 return current_==other.current_;
│ │ │ +
409 }
│ │ │ +
│ │ │ +
410
│ │ │ +
│ │ │ +
414 inline void increment()
│ │ │ +
415 {
│ │ │ +
416 current_ = current_->next_;
│ │ │ +
417 }
│ │ │ +
│ │ │ +
418
│ │ │ +
419 private:
│ │ │ +
421 typename SLList<T,A>::Element* current_;
│ │ │ +
422 };
│ │ │ +
│ │ │ +
423
│ │ │ +
427 template<typename T, class A>
│ │ │ +
│ │ │ +
428 class SLListModifyIterator : public Dune::ForwardIteratorFacade<SLListModifyIterator<T,A>, T, T&, std::size_t>
│ │ │ +
429 {
│ │ │ +
430 friend class SLListConstIterator<T,A>;
│ │ │ +
431 friend class SLListIterator<T,A>;
│ │ │ +
432 public:
│ │ │ +
│ │ │ + │ │ │ +
434 SLListIterator<T,A> _iterator)
│ │ │ +
435 : beforeIterator_(beforeIterator), iterator_(_iterator)
│ │ │ +
436 {}
│ │ │ +
│ │ │ +
437
│ │ │ +
│ │ │ + │ │ │ +
439 : beforeIterator_(), iterator_()
│ │ │ +
440 {}
│ │ │ +
│ │ │ +
441
│ │ │ +
│ │ │ +
446 inline T& dereference() const
│ │ │ +
447 {
│ │ │ +
448 return *iterator_;
│ │ │ +
449 }
│ │ │ +
│ │ │ +
450
│ │ │ +
│ │ │ +
456 inline bool equals(const SLListConstIterator<T,A>& other) const
│ │ │ +
457 {
│ │ │ +
458 return iterator_== other;
│ │ │ +
459 }
│ │ │ +
│ │ │ +
460
│ │ │ +
461
│ │ │ +
│ │ │ +
467 inline bool equals(const SLListIterator<T,A>& other) const
│ │ │ +
468 {
│ │ │ +
469 return iterator_== other;
│ │ │ +
470 }
│ │ │ +
│ │ │ +
471
│ │ │ +
472
│ │ │ +
│ │ │ +
478 inline bool equals(const SLListModifyIterator<T,A>& other) const
│ │ │ +
479 {
│ │ │ +
480 return iterator_== other.iterator_;
│ │ │ +
481 }
│ │ │ +
│ │ │ +
482
│ │ │ +
│ │ │ +
486 inline void increment()
│ │ │ +
487 {
│ │ │ +
488 ++iterator_;
│ │ │ +
489 ++beforeIterator_;
│ │ │ +
490 }
│ │ │ +
│ │ │ +
491
│ │ │ +
│ │ │ +
505 inline void insert(const T& v)
│ │ │ +
506 {
│ │ │ +
507 beforeIterator_.insertAfter(v);
│ │ │ +
508 ++beforeIterator_;
│ │ │ +
509 }
│ │ │ +
│ │ │ +
510
│ │ │ +
│ │ │ +
518 inline void remove()
│ │ │ +
519 {
│ │ │ +
520 ++iterator_;
│ │ │ +
521 beforeIterator_.deleteNext();
│ │ │ +
522 }
│ │ │ +
│ │ │ +
523
│ │ │ +
524 private:
│ │ │ +
526 SLListIterator<T,A> beforeIterator_;
│ │ │ +
528 SLListIterator<T,A> iterator_;
│ │ │ +
529 };
│ │ │ +
│ │ │ +
530
│ │ │ +
531 template<typename T, typename A>
│ │ │ +
│ │ │ +
532 std::ostream& operator<<(std::ostream& os, const SLList<T,A>& sllist)
│ │ │ +
533 {
│ │ │ +
534 typedef typename SLList<T,A>::const_iterator Iterator;
│ │ │ +
535 Iterator end = sllist.end();
│ │ │ +
536 Iterator current= sllist.begin();
│ │ │ +
537
│ │ │ +
538 os << "{ ";
│ │ │ +
539
│ │ │ +
540 if(current!=end) {
│ │ │ +
541 os<<*current<<" ("<<static_cast<const void*>(&(*current))<<")";
│ │ │ +
542 ++current;
│ │ │ +
543
│ │ │ +
544 for(; current != end; ++current)
│ │ │ +
545 os<<", "<<*current<<" ("<<static_cast<const void*>(&(*current))<<")";
│ │ │ +
546 }
│ │ │ +
547 os<<"} ";
│ │ │ +
548 return os;
│ │ │ +
549 }
│ │ │ +
│ │ │ +
550
│ │ │ +
551 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
553 : next_(next), item_(item)
│ │ │ +
554 {}
│ │ │ +
│ │ │ +
│ │ │ +
555
│ │ │ +
556 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
558 : next_(0), item_()
│ │ │ +
559 {}
│ │ │ +
│ │ │ +
560
│ │ │ +
561 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
563 {
│ │ │ +
564 next_=0;
│ │ │ +
565 }
│ │ │ +
│ │ │ +
566
│ │ │ +
567 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
569 : beforeHead_(), tail_(&beforeHead_), allocator_(), size_(0)
│ │ │ +
570 {
│ │ │ +
571 beforeHead_.next_=0;
│ │ │ +
572 assert(&beforeHead_==tail_);
│ │ │ +
573 assert(tail_->next_==0);
│ │ │ +
574 }
│ │ │ +
│ │ │ +
575
│ │ │ +
576 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
578 : beforeHead_(), tail_(&beforeHead_), allocator_(), size_(0)
│ │ │ +
579 {
│ │ │ +
580 copyElements(other);
│ │ │ +
581 }
│ │ │ +
│ │ │ +
582
│ │ │ +
583 template<typename T, class A>
│ │ │ +
584 template<typename T1, class A1>
│ │ │ +
│ │ │ + │ │ │ +
586 : beforeHead_(), tail_(&beforeHead_), allocator_(), size_(0)
│ │ │ +
587 {
│ │ │ +
588 copyElements(other);
│ │ │ +
589 }
│ │ │ +
│ │ │ +
590
│ │ │ +
591 template<typename T, typename A>
│ │ │ +
592 void SLList<T,A>::copyElements(const SLList<T,A>& other)
│ │ │ +
593 {
│ │ │ +
594 assert(tail_==&beforeHead_);
│ │ │ +
595 assert(size_==0);
│ │ │ +
596 typedef typename SLList<T,A>::const_iterator Iterator;
│ │ │ +
597 Iterator iend = other.end();
│ │ │ +
598 for(Iterator element=other.begin(); element != iend; ++element)
│ │ │ +
599 push_back(*element);
│ │ │ +
600
│ │ │ +
601 assert(other.size()==size());
│ │ │ +
602 }
│ │ │ +
603
│ │ │ +
604 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
606 {
│ │ │ +
607 clear();
│ │ │ +
608 }
│ │ │ +
│ │ │ +
609
│ │ │ +
610 template<typename T, class A>
│ │ │ +
│ │ │ +
611 bool SLList<T,A>::operator==(const SLList& other) const
│ │ │ +
612 {
│ │ │ +
613 if(size()!=other.size())
│ │ │ +
614 return false;
│ │ │ +
615 for(const_iterator iter=begin(), oiter=other.begin();
│ │ │ +
616 iter != end(); ++iter, ++oiter)
│ │ │ +
617 if(*iter!=*oiter)
│ │ │ +
618 return false;
│ │ │ +
619 return true;
│ │ │ +
620 }
│ │ │ +
│ │ │ +
621
│ │ │ +
622 template<typename T, class A>
│ │ │ +
│ │ │ +
623 bool SLList<T,A>::operator!=(const SLList& other) const
│ │ │ +
624 {
│ │ │ +
625 if(size()==other.size()) {
│ │ │ +
626 for(const_iterator iter=begin(), oiter=other.begin();
│ │ │ +
627 iter != end(); ++iter, ++oiter)
│ │ │ +
628 if(*iter!=*oiter)
│ │ │ +
629 return true;
│ │ │ +
630 return false;
│ │ │ +
631 }else
│ │ │ +
632 return true;
│ │ │ +
633 }
│ │ │ +
│ │ │ +
634 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
636 {
│ │ │ +
637 clear();
│ │ │ +
638 copyElements(other);
│ │ │ +
639 return *this;
│ │ │ +
640 }
│ │ │ +
│ │ │ +
641
│ │ │ +
642 template<typename T, class A>
│ │ │ +
│ │ │ +
643 inline void SLList<T,A>::push_back(const MemberType& item)
│ │ │ +
644 {
│ │ │ +
645 assert(size_>0 || tail_==&beforeHead_);
│ │ │ +
646 tail_->next_ = allocator_.allocate(1);
│ │ │ +
647 assert(size_>0 || tail_==&beforeHead_);
│ │ │ +
648 tail_ = tail_->next_;
│ │ │ +
649 ::new (static_cast<void*>(&(tail_->item_)))T(item);
│ │ │ +
650 tail_->next_=0;
│ │ │ +
651 assert(tail_->next_==0);
│ │ │ +
652 ++size_;
│ │ │ +
653 }
│ │ │ +
│ │ │ +
654
│ │ │ +
655 template<typename T, class A>
│ │ │ +
656 inline void SLList<T,A>::insertAfter(Element* current, const T& item)
│ │ │ +
657 {
│ │ │ +
658 assert(current);
│ │ │ +
659
│ │ │ +
660#ifndef NDEBUG
│ │ │ +
661 bool changeTail = (current == tail_);
│ │ │ +
662#endif
│ │ │ +
663
│ │ │ +
664 // Save old next element
│ │ │ +
665 Element* tmp = current->next_;
│ │ │ +
666
│ │ │ +
667 assert(!changeTail || !tmp);
│ │ │ +
668
│ │ │ +
669 // Allocate space
│ │ │ +
670 current->next_ = allocator_.allocate(1);
│ │ │ +
671
│ │ │ +
672 // Use copy constructor to initialize memory
│ │ │ +
673 std::allocator_traits<Allocator>::construct(allocator_, current->next_, Element(item,tmp));
│ │ │ +
674
│ │ │ +
675 //::new(static_cast<void*>(&(current->next_->item_))) T(item);
│ │ │ +
676
│ │ │ +
677 if(!current->next_->next_) {
│ │ │ +
678 // Update tail
│ │ │ +
679 assert(changeTail);
│ │ │ +
680 tail_ = current->next_;
│ │ │ +
681 }
│ │ │ +
682 ++size_;
│ │ │ +
683 assert(!tail_->next_);
│ │ │ +
684 }
│ │ │ +
685
│ │ │ +
686 template<typename T, class A>
│ │ │ +
│ │ │ +
687 inline void SLList<T,A>::push_front(const MemberType& item)
│ │ │ +
688 {
│ │ │ +
689 if(tail_ == &beforeHead_) {
│ │ │ +
690 // list was empty
│ │ │ +
691 beforeHead_.next_ = tail_ = allocator_.allocate(1, 0);
│ │ │ +
692 ::new(static_cast<void*>(&beforeHead_.next_->item_))T(item);
│ │ │ +
693 beforeHead_.next_->next_=0;
│ │ │ +
694 }else{
│ │ │ +
695 Element* added = allocator_.allocate(1, 0);
│ │ │ +
696 ::new(static_cast<void*>(&added->item_))T(item);
│ │ │ +
697 added->next_=beforeHead_.next_;
│ │ │ +
698 beforeHead_.next_=added;
│ │ │ +
699 }
│ │ │ +
700 assert(tail_->next_==0);
│ │ │ +
701 ++size_;
│ │ │ +
702 }
│ │ │ +
│ │ │ +
703
│ │ │ +
704
│ │ │ +
705 template<typename T, class A>
│ │ │ +
706 inline void SLList<T,A>::deleteNext(Element* current)
│ │ │ +
707 {
│ │ │ +
708 this->template deleteNext<true>(current);
│ │ │ +
709 }
│ │ │ +
710
│ │ │ +
711 template<typename T, class A>
│ │ │ +
712 template<bool watchForTail>
│ │ │ +
713 inline void SLList<T,A>::deleteNext(Element* current)
│ │ │ +
714 {
│ │ │ +
715 assert(current->next_);
│ │ │ +
716 Element* next = current->next_;
│ │ │ +
717
│ │ │ +
718 if(watchForTail)
│ │ │ +
719 if(next == tail_) {
│ │ │ +
720 // deleting last element changes tail!
│ │ │ +
721 tail_ = current;
│ │ │ +
722 }
│ │ │ +
723
│ │ │ +
724 current->next_ = next->next_;
│ │ │ +
725 std::allocator_traits<Allocator>::destroy(allocator_, next);
│ │ │ +
726 allocator_.deallocate(next, 1);
│ │ │ +
727 --size_;
│ │ │ +
728 assert(!watchForTail || &beforeHead_ != tail_ || size_==0);
│ │ │ +
729 }
│ │ │ +
730
│ │ │ +
731 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
733 {
│ │ │ +
734 deleteNext(&beforeHead_);
│ │ │ +
735 }
│ │ │ +
│ │ │ +
736
│ │ │ +
737 template<typename T, class A>
│ │ │ +
│ │ │ +
738 inline void SLList<T,A>::clear()
│ │ │ +
739 {
│ │ │ +
740 while(beforeHead_.next_ ) {
│ │ │ +
741 this->template deleteNext<false>(&beforeHead_);
│ │ │ +
742 }
│ │ │ +
743
│ │ │ +
744 assert(size_==0);
│ │ │ +
745 // update the tail!
│ │ │ +
746 tail_ = &beforeHead_;
│ │ │ +
747 }
│ │ │ +
│ │ │ +
748
│ │ │ +
749 template<typename T, class A>
│ │ │ +
│ │ │ +
750 inline bool SLList<T,A>::empty() const
│ │ │ +
751 {
│ │ │ +
752 return (&beforeHead_ == tail_);
│ │ │ +
753 }
│ │ │ +
│ │ │ +
754
│ │ │ +
755 template<typename T, class A>
│ │ │ +
│ │ │ +
756 inline int SLList<T,A>::size() const
│ │ │ +
757 {
│ │ │ +
758 return size_;
│ │ │ +
759 }
│ │ │ +
│ │ │ +
760
│ │ │ +
761 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
763 {
│ │ │ +
764 return iterator(beforeHead_.next_, this);
│ │ │ +
765 }
│ │ │ +
│ │ │ +
766
│ │ │ +
767 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
769 {
│ │ │ +
770 return const_iterator(beforeHead_.next_);
│ │ │ +
771 }
│ │ │ +
│ │ │ +
772
│ │ │ +
773 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
775 {
│ │ │ +
776 return iterator();
│ │ │ +
777 }
│ │ │ +
│ │ │ +
778
│ │ │ +
779 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
781 {
│ │ │ +
782 return SLListModifyIterator<T,A>(iterator(tail_, this),iterator());
│ │ │ +
783 }
│ │ │ +
│ │ │ +
784
│ │ │ +
785
│ │ │ +
786 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
788 {
│ │ │ +
789 return SLListModifyIterator<T,A>(iterator(&beforeHead_, this),
│ │ │ +
790 iterator(beforeHead_.next_, this));
│ │ │ +
791 }
│ │ │ +
│ │ │ +
792
│ │ │ +
793 template<typename T, class A>
│ │ │ +
│ │ │ + │ │ │ +
795 {
│ │ │ +
796 return const_iterator();
│ │ │ +
797 }
│ │ │ +
│ │ │ +
798
│ │ │ +
800}
│ │ │ +
801#endif
│ │ │ +
│ │ │ +
This file implements iterator facade classes for writing stl conformant iterators.
│ │ │ +
void push_front(const MemberType &item)
Add a new entry to the beginning of the list.
Definition sllist.hh:687
│ │ │ +
bool equals(const SLListConstIterator< T, A > &other) const
Equality test for the iterator facade.
Definition sllist.hh:406
│ │ │ +
void push_back(const MemberType &item)
Add a new entry to the end of the list.
Definition sllist.hh:643
│ │ │ +
ModifyIterator endModify()
Get an iterator capable of deleting and inserting elements.
Definition sllist.hh:780
│ │ │ +
SLListModifyIterator()
Definition sllist.hh:438
│ │ │ +
Element()
Definition sllist.hh:557
│ │ │ +
T & dereference() const
Dereferencing function for the iterator facade.
Definition sllist.hh:294
│ │ │ +
bool operator!=(const SLList &sl) const
Definition sllist.hh:623
│ │ │ +
MemberType item_
The element we hold.
Definition sllist.hh:212
│ │ │ +
SLListConstIterator(typename SLList< T, A >::Element *item)
Definition sllist.hh:380
│ │ │ +
typename std::allocator_traits< typename RemoteIndices::Allocator >::template rebind_alloc< Element > Allocator
Definition sllist.hh:64
│ │ │ +
void insertAfter(const T &v) const
Insert an element in the underlying list after the current position.
Definition sllist.hh:342
│ │ │ +
SLListIterator< std::pair< GlobalIndex, Attribute >, typename RemoteIndices::Allocator > iterator
Definition sllist.hh:69
│ │ │ +
SLListConstIterator(const SLListModifyIterator< T, A > &other)
Definition sllist.hh:388
│ │ │ +
SLListIterator()
Definition sllist.hh:282
│ │ │ +
Element(const MemberType &item, Element *next_=0)
Definition sllist.hh:552
│ │ │ +
~Element()
Definition sllist.hh:562
│ │ │ +
bool operator==(const SLList &sl) const
Definition sllist.hh:611
│ │ │ +
void deleteNext() const
Delete the entry after the current position.
Definition sllist.hh:353
│ │ │ +
SLList(const SLList< T, A > &other)
Copy constructor.
Definition sllist.hh:577
│ │ │ +
bool equals(const SLListModifyIterator< T, A > &other) const
Equality test for the iterator facade.
Definition sllist.hh:324
│ │ │ +
T & dereference() const
Dereferencing function for the iterator facade.
Definition sllist.hh:446
│ │ │ +
int size() const
Get the number of elements the list contains.
Definition sllist.hh:756
│ │ │ +
const_iterator begin() const
Get an iterator pointing to the first element in the list.
Definition sllist.hh:768
│ │ │ +
iterator end()
Get an iterator pointing to the end of the list.
Definition sllist.hh:774
│ │ │ +
void clear()
Remove all elements from the list.
Definition sllist.hh:738
│ │ │ +
SLList(const SLList< T1, A1 > &other)
Copy constructor with type conversion.
Definition sllist.hh:585
│ │ │ +
std::pair< GlobalIndex, Attribute > MemberType
Definition sllist.hh:59
│ │ │ +
bool equals(const SLListModifyIterator< T, A > &other) const
Test whether another iterator is equal.
Definition sllist.hh:478
│ │ │ +
ModifyIterator beginModify()
Get an iterator capable of deleting and inserting elements.
Definition sllist.hh:787
│ │ │ +
SLList< T, A > & operator=(const SLList< T, A > &other)
Assignment operator.
Definition sllist.hh:635
│ │ │ +
SLListConstIterator(const SLListIterator< T, A > &other)
Definition sllist.hh:384
│ │ │ +
SLListConstIterator< std::pair< GlobalIndex, Attribute >, typename RemoteIndices::Allocator > const_iterator
Definition sllist.hh:74
│ │ │ +
bool empty() const
Check whether the list is empty.
Definition sllist.hh:750
│ │ │ +
SLListConstIterator()
Definition sllist.hh:376
│ │ │ +
bool equals(const SLListConstIterator< T, A > &other) const
Equality test for the iterator facade.
Definition sllist.hh:304
│ │ │ +
bool equals(const SLListConstIterator< T, A > &other) const
Test whether another iterator is equal.
Definition sllist.hh:456
│ │ │ +
SLListModifyIterator< std::pair< GlobalIndex, Attribute >, typename RemoteIndices::Allocator > ModifyIterator
Definition sllist.hh:103
│ │ │ +
const_iterator end() const
Get an iterator pointing to the end of the list.
Definition sllist.hh:794
│ │ │ +
SLList()
Constructor.
Definition sllist.hh:568
│ │ │ +
void insert(const T &v)
Insert an element at the current position.
Definition sllist.hh:505
│ │ │ +
SLListIterator(typename SLList< T, A >::Element *item, SLList< T, A > *sllist)
Definition sllist.hh:277
│ │ │ +
SLListModifyIterator(SLListIterator< T, A > beforeIterator, SLListIterator< T, A > _iterator)
Definition sllist.hh:433
│ │ │ +
void pop_front()
Remove the first item in the list.
Definition sllist.hh:732
│ │ │ +
void increment()
Increment function for the iterator facade.
Definition sllist.hh:332
│ │ │ +
SLListIterator(const SLListModifyIterator< T, A > &other)
Definition sllist.hh:286
│ │ │ +
typename RemoteIndices::Allocator::size_type size_type
Definition sllist.hh:54
│ │ │ +
void remove()
Delete the entry at the current position.
Definition sllist.hh:518
│ │ │ +
const T & dereference() const
Dereferencing function for the facade.
Definition sllist.hh:396
│ │ │ +
Element * next_
The next element in the list.
Definition sllist.hh:208
│ │ │ +
void increment()
Increment function for the iterator facade.
Definition sllist.hh:486
│ │ │ +
void increment()
Increment function for the iterator facade.
Definition sllist.hh:414
│ │ │ +
~SLList()
Destructor.
Definition sllist.hh:605
│ │ │ +
bool equals(const SLListIterator< T, A > &other) const
Test whether another iterator is equal.
Definition sllist.hh:467
│ │ │ +
iterator begin()
Get an iterator pointing to the first element in the list.
Definition sllist.hh:762
│ │ │ +
bool equals(const SLListIterator< T, A > &other) const
Equality test for the iterator facade.
Definition sllist.hh:314
│ │ │ +
std::ostream & operator<<(std::ostream &s, const bigunsignedint< k > &x)
Definition bigunsignedint.hh:301
│ │ │ +
Dune namespace
Definition alignedallocator.hh:13
│ │ │ +
constexpr std::integral_constant< std::size_t, sizeof...(II)> size(std::integer_sequence< T, II... >)
Return the size of the sequence.
Definition integersequence.hh:75
│ │ │ +
constexpr HybridMultiIndex< T..., std::size_t > push_back(const HybridMultiIndex< T... > &tp, std::size_t i)
Appends a run time index to a HybridMultiIndex.
Definition hybridmultiindex.hh:249
│ │ │ +
Base class for stl conformant forward iterators.
Definition iteratorfacades.hh:142
│ │ │ +
A mutable iterator for the SLList.
Definition sllist.hh:271
│ │ │ +
A constant iterator for the SLList.
Definition sllist.hh:371
│ │ │ +
A mutable iterator for the SLList.
Definition sllist.hh:429
│ │ │ +
A single linked list.
Definition sllist.hh:44
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,77 +1,815 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -version.hh │ │ │ │ +sllist.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ 1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ 2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ 4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ -5#ifndef DUNE_VERSION_HH │ │ │ │ -6#define DUNE_VERSION_HH │ │ │ │ +5#ifndef DUNE_SLLIST_HH │ │ │ │ +6#define DUNE_SLLIST_HH │ │ │ │ 7 │ │ │ │ -8#include // DUNE_[MODULE]_VERSION_[TYPE] │ │ │ │ -9 │ │ │ │ -13 │ │ │ │ -_3_0#define DUNE_VERSION_JOIN(module,type) module ## _VERSION_ ## type │ │ │ │ +8#include │ │ │ │ +9#include │ │ │ │ +10#include "_i_t_e_r_a_t_o_r_f_a_c_a_d_e_s_._h_h" │ │ │ │ +11#include │ │ │ │ +12 │ │ │ │ +13namespace _D_u_n_e │ │ │ │ +14{ │ │ │ │ +26 template │ │ │ │ +27 class _S_L_L_i_s_t_I_t_e_r_a_t_o_r; │ │ │ │ +28 │ │ │ │ +29 template │ │ │ │ +30 class _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r; │ │ │ │ 31 │ │ │ │ -_4_6#define DUNE_VERSION_EQUAL(module,major,minor) \ │ │ │ │ -47 ((DUNE_VERSION_JOIN(module,MAJOR) == major) && \ │ │ │ │ -48 (DUNE_VERSION_JOIN(module,MINOR) == minor)) │ │ │ │ -49 │ │ │ │ -_6_4#define DUNE_VERSION_EQUAL_REV(module,major,minor,revision) \ │ │ │ │ -65 ( DUNE_VERSION_EQUAL(module,major,minor) && \ │ │ │ │ -66 (DUNE_VERSION_JOIN(module,REVISION) == revision)) │ │ │ │ -67 │ │ │ │ -_8_2#define DUNE_VERSION_GTE(module,major,minor) \ │ │ │ │ -83 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \ │ │ │ │ -84 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN │ │ │ │ -(module,MINOR) >= minor))) │ │ │ │ -85 │ │ │ │ -_1_0_0#define DUNE_VERSION_LT(module,major,minor) \ │ │ │ │ -101 ! DUNE_VERSION_GTE(module,major,minor) │ │ │ │ -102 │ │ │ │ -_1_1_7#define DUNE_VERSION_GT(module,major,minor) \ │ │ │ │ -118 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \ │ │ │ │ -119 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN │ │ │ │ -(module,MINOR) > minor))) │ │ │ │ -120 │ │ │ │ -_1_3_5#define DUNE_VERSION_LTE(module,major,minor) \ │ │ │ │ -136 ! DUNE_VERSION_GT(module,major,minor) │ │ │ │ -137 │ │ │ │ -_1_5_2#define DUNE_VERSION_GTE_REV(module,major,minor,revision) \ │ │ │ │ -153 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \ │ │ │ │ -154 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN │ │ │ │ -(module,MINOR) > minor)) \ │ │ │ │ -155 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN │ │ │ │ -(module,MINOR) == minor) \ │ │ │ │ -156 && (DUNE_VERSION_JOIN(module,REVISION) >= revision))) │ │ │ │ +32 template │ │ │ │ +33 class _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r; │ │ │ │ +34 │ │ │ │ +42 template > │ │ │ │ +_4_3 class _S_L_L_i_s_t │ │ │ │ +44 { │ │ │ │ +45 struct Element; │ │ │ │ +46 friend class _S_L_L_i_s_t_I_t_e_r_a_t_o_r; │ │ │ │ +47 friend class _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r; │ │ │ │ +48 │ │ │ │ +49 public: │ │ │ │ +50 │ │ │ │ +_5_4 typedef typename A::size_type _s_i_z_e___t_y_p_e; │ │ │ │ +55 │ │ │ │ +_5_9 typedef T _M_e_m_b_e_r_T_y_p_e; │ │ │ │ +60 │ │ │ │ +_6_4 using _A_l_l_o_c_a_t_o_r = typename std::allocator_traits::template │ │ │ │ +rebind_alloc; │ │ │ │ +65 │ │ │ │ +_6_9 typedef _S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> _i_t_e_r_a_t_o_r; │ │ │ │ +70 │ │ │ │ +_7_4 typedef _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> _c_o_n_s_t___i_t_e_r_a_t_o_r; │ │ │ │ +75 │ │ │ │ +_7_9 _S_L_L_i_s_t(); │ │ │ │ +80 │ │ │ │ +84 template │ │ │ │ +_8_5 _S_L_L_i_s_t(const _S_L_L_i_s_t_<_T_1_,_A_1_>& other); │ │ │ │ +86 │ │ │ │ +_9_0 _S_L_L_i_s_t(const _S_L_L_i_s_t_<_T_,_A_>& other); │ │ │ │ +91 │ │ │ │ +_9_7 _~_S_L_L_i_s_t(); │ │ │ │ +98 │ │ │ │ +_1_0_3 typedef _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_T_,_A_> _M_o_d_i_f_y_I_t_e_r_a_t_o_r; │ │ │ │ +104 │ │ │ │ +_1_0_8 _S_L_L_i_s_t_<_T_,_A_>& _o_p_e_r_a_t_o_r_=(const _S_L_L_i_s_t_<_T_,_A_>& other); │ │ │ │ +109 │ │ │ │ +110 │ │ │ │ +_1_1_5 inline void _p_u_s_h___b_a_c_k(const _M_e_m_b_e_r_T_y_p_e& item); │ │ │ │ +116 │ │ │ │ +_1_2_1 inline void _p_u_s_h___f_r_o_n_t(const _M_e_m_b_e_r_T_y_p_e& item); │ │ │ │ +122 │ │ │ │ +_1_2_6 inline void _p_o_p___f_r_o_n_t(); │ │ │ │ +127 │ │ │ │ +_1_2_9 inline void _c_l_e_a_r(); │ │ │ │ +130 │ │ │ │ +_1_3_8 inline _i_t_e_r_a_t_o_r _b_e_g_i_n(); │ │ │ │ +139 │ │ │ │ +_1_4_7 inline _c_o_n_s_t___i_t_e_r_a_t_o_r _b_e_g_i_n() const; │ │ │ │ +148 │ │ │ │ +_1_5_6 inline _M_o_d_i_f_y_I_t_e_r_a_t_o_r _b_e_g_i_n_M_o_d_i_f_y(); │ │ │ │ 157 │ │ │ │ -_1_7_2#define DUNE_VERSION_LT_REV(module,major,minor,revision) \ │ │ │ │ -173 ! DUNE_VERSION_GTE_REV(module,major,minor,revision) │ │ │ │ +_1_6_5 inline _M_o_d_i_f_y_I_t_e_r_a_t_o_r _e_n_d_M_o_d_i_f_y(); │ │ │ │ +166 │ │ │ │ +_1_7_3 inline _i_t_e_r_a_t_o_r _e_n_d(); │ │ │ │ 174 │ │ │ │ -_1_8_9#define DUNE_VERSION_GT_REV(module,major,minor,revision) \ │ │ │ │ -190 ((DUNE_VERSION_JOIN(module,MAJOR) > major) \ │ │ │ │ -191 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN │ │ │ │ -(module,MINOR) > minor)) \ │ │ │ │ -192 || ((DUNE_VERSION_JOIN(module,MAJOR) == major) && (DUNE_VERSION_JOIN │ │ │ │ -(module,MINOR) == minor) \ │ │ │ │ -193 && (DUNE_VERSION_JOIN(module,REVISION) > revision))) │ │ │ │ -194 │ │ │ │ -_2_0_9#define DUNE_VERSION_LTE_REV(module,major,minor,revision) \ │ │ │ │ -210 ! DUNE_VERSION_GT_REV(module,major,minor,revision) │ │ │ │ -211 │ │ │ │ -_2_2_6#define DUNE_VERSION_ID(major,minor,revision) \ │ │ │ │ -227 ((unsigned int)((major << 24) + (minor << 16) + revision)) │ │ │ │ -228 │ │ │ │ -_2_4_3#define DUNE_MODULE_VERSION_ID(module) \ │ │ │ │ -244 DUNE_VERSION_ID( DUNE_VERSION_JOIN(module,MAJOR), DUNE_VERSION_JOIN │ │ │ │ -(module,MINOR), DUNE_VERSION_JOIN(module,REVISION) ) │ │ │ │ -245 │ │ │ │ -246#endif │ │ │ │ +_1_8_1 inline _c_o_n_s_t___i_t_e_r_a_t_o_r _e_n_d() const; │ │ │ │ +182 │ │ │ │ +_1_8_8 inline bool _e_m_p_t_y() const; │ │ │ │ +189 │ │ │ │ +_1_9_4 inline int _s_i_z_e() const; │ │ │ │ +195 │ │ │ │ +_1_9_6 bool _o_p_e_r_a_t_o_r_=_=(const _S_L_L_i_s_t& sl) const; │ │ │ │ +197 │ │ │ │ +198 │ │ │ │ +_1_9_9 bool _o_p_e_r_a_t_o_r_!_=(const _S_L_L_i_s_t& sl) const; │ │ │ │ +200 │ │ │ │ +201 private: │ │ │ │ +203 struct Element │ │ │ │ +204 { │ │ │ │ +_2_0_8 _E_l_e_m_e_n_t* _n_e_x_t__; │ │ │ │ +_2_1_2 _M_e_m_b_e_r_T_y_p_e _i_t_e_m__; │ │ │ │ +213 │ │ │ │ +_2_1_4 _E_l_e_m_e_n_t(const _M_e_m_b_e_r_T_y_p_e& item, _E_l_e_m_e_n_t* _n_e_x_t__=0); │ │ │ │ +215 │ │ │ │ +216 _E_l_e_m_e_n_t(); │ │ │ │ +217 │ │ │ │ +_2_1_8 _~_E_l_e_m_e_n_t(); │ │ │ │ +219 }; │ │ │ │ +220 │ │ │ │ +225 void deleteNext(Element* current); │ │ │ │ +226 │ │ │ │ +231 void copyElements(const _S_L_L_i_s_t_<_T_,_A_>& other); │ │ │ │ +232 │ │ │ │ +240 template │ │ │ │ +241 void deleteNext(Element* current); │ │ │ │ +247 void insertAfter(Element* current, const T& item); │ │ │ │ +248 │ │ │ │ +250 Element beforeHead_; │ │ │ │ +251 │ │ │ │ +257 Element* tail_; │ │ │ │ +258 │ │ │ │ +260 _A_l_l_o_c_a_t_o_r allocator_; │ │ │ │ +261 │ │ │ │ +263 int size_; │ │ │ │ +264 }; │ │ │ │ +265 │ │ │ │ +269 template │ │ │ │ +_2_7_0 class _S_L_L_i_s_t_I_t_e_r_a_t_o_r : public _D_u_n_e_:_: │ │ │ │ +_F_o_r_w_a_r_d_I_t_e_r_a_t_o_r_F_a_c_a_d_e, T, T&, std::size_t> │ │ │ │ +271 { │ │ │ │ +272 friend class _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r; │ │ │ │ +273 friend class _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r; │ │ │ │ +274 friend class _S_L_L_i_s_t; │ │ │ │ +275 │ │ │ │ +276 public: │ │ │ │ +_2_7_7 inline _S_L_L_i_s_t_I_t_e_r_a_t_o_r(typename SLList::Element* item, │ │ │ │ +278 _S_L_L_i_s_t_<_T_,_A_>* sllist) │ │ │ │ +279 : current_(item), list_(sllist) │ │ │ │ +280 {} │ │ │ │ +281 │ │ │ │ +_2_8_2 inline _S_L_L_i_s_t_I_t_e_r_a_t_o_r() │ │ │ │ +283 : current_(0), list_(0) │ │ │ │ +284 {} │ │ │ │ +285 │ │ │ │ +_2_8_6 inline _S_L_L_i_s_t_I_t_e_r_a_t_o_r(const _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_T_,_A_>& other) │ │ │ │ +287 : current_(other.iterator_.current_), list_(other.iterator_.list_) │ │ │ │ +288 {} │ │ │ │ +289 │ │ │ │ +_2_9_4 inline T& _d_e_r_e_f_e_r_e_n_c_e() const │ │ │ │ +295 { │ │ │ │ +296 return current_->item_; │ │ │ │ +297 } │ │ │ │ +298 │ │ │ │ +_3_0_4 inline bool _e_q_u_a_l_s(const _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_<_T_,_A_>& other) const │ │ │ │ +305 { │ │ │ │ +306 return current_==other.current_; │ │ │ │ +307 } │ │ │ │ +308 │ │ │ │ +_3_1_4 inline bool _e_q_u_a_l_s(const _S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_>& other) const │ │ │ │ +315 { │ │ │ │ +316 return current_==other.current_; │ │ │ │ +317 } │ │ │ │ +318 │ │ │ │ +_3_2_4 inline bool _e_q_u_a_l_s(const _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_T_,_A_>& other) const │ │ │ │ +325 { │ │ │ │ +326 return current_==other.iterator_.current_; │ │ │ │ +327 } │ │ │ │ +328 │ │ │ │ +_3_3_2 inline void _i_n_c_r_e_m_e_n_t() │ │ │ │ +333 { │ │ │ │ +334 current_ = current_->next_; │ │ │ │ +335 } │ │ │ │ +336 │ │ │ │ +_3_4_2 inline void _i_n_s_e_r_t_A_f_t_e_r(const T& v) const │ │ │ │ +343 { │ │ │ │ +344 assert(list_ ); │ │ │ │ +345 list_->insertAfter(current_, v); │ │ │ │ +346 } │ │ │ │ +347 │ │ │ │ +_3_5_3 inline void _d_e_l_e_t_e_N_e_x_t() const │ │ │ │ +354 { │ │ │ │ +355 assert(list_); │ │ │ │ +356 list_->deleteNext(current_); │ │ │ │ +357 } │ │ │ │ +358 │ │ │ │ +359 private: │ │ │ │ +361 typename SLList::Element* current_; │ │ │ │ +_3_6_3 _S_L_L_i_s_t_<_T_,_A_>* list_; │ │ │ │ +364 }; │ │ │ │ +365 │ │ │ │ +369 template │ │ │ │ +_3_7_0 class _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r : public _D_u_n_e_:_: │ │ │ │ +_F_o_r_w_a_r_d_I_t_e_r_a_t_o_r_F_a_c_a_d_e, const T, const T&, std::size_t> │ │ │ │ +371 { │ │ │ │ +372 friend class _S_L_L_i_s_t_I_t_e_r_a_t_o_r; │ │ │ │ +373 friend class _S_L_L_i_s_t; │ │ │ │ +374 │ │ │ │ +375 public: │ │ │ │ +_3_7_6 inline _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r() │ │ │ │ +377 : current_(0) │ │ │ │ +378 {} │ │ │ │ +379 │ │ │ │ +_3_8_0 inline _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r(typename SLList::Element* item) │ │ │ │ +381 : current_(item) │ │ │ │ +382 {} │ │ │ │ +383 │ │ │ │ +_3_8_4 inline _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r(const _S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_>& other) │ │ │ │ +385 : current_(other.current_) │ │ │ │ +386 {} │ │ │ │ +387 │ │ │ │ +_3_8_8 inline _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r(const _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_T_,_A_>& other) │ │ │ │ +389 : current_(other.iterator_.current_) │ │ │ │ +390 {} │ │ │ │ +391 │ │ │ │ +_3_9_6 inline const T& _d_e_r_e_f_e_r_e_n_c_e() const │ │ │ │ +397 { │ │ │ │ +398 return current_->item_; │ │ │ │ +399 } │ │ │ │ +400 │ │ │ │ +_4_0_6 inline bool _e_q_u_a_l_s(const _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_<_T_,_A_>& other) const │ │ │ │ +407 { │ │ │ │ +408 return current_==other.current_; │ │ │ │ +409 } │ │ │ │ +410 │ │ │ │ +_4_1_4 inline void _i_n_c_r_e_m_e_n_t() │ │ │ │ +415 { │ │ │ │ +416 current_ = current_->next_; │ │ │ │ +417 } │ │ │ │ +418 │ │ │ │ +419 private: │ │ │ │ +_4_2_1 typename SLList::Element* current_; │ │ │ │ +422 }; │ │ │ │ +423 │ │ │ │ +427 template │ │ │ │ +_4_2_8 class _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r : public _D_u_n_e_:_: │ │ │ │ +_F_o_r_w_a_r_d_I_t_e_r_a_t_o_r_F_a_c_a_d_e, T, T&, std::size_t> │ │ │ │ +429 { │ │ │ │ +430 friend class _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r; │ │ │ │ +431 friend class _S_L_L_i_s_t_I_t_e_r_a_t_o_r; │ │ │ │ +432 public: │ │ │ │ +_4_3_3 inline _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r(_S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> beforeIterator, │ │ │ │ +434 _S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> _iterator) │ │ │ │ +435 : beforeIterator_(beforeIterator), iterator_(_iterator) │ │ │ │ +436 {} │ │ │ │ +437 │ │ │ │ +_4_3_8 inline _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r() │ │ │ │ +439 : beforeIterator_(), iterator_() │ │ │ │ +440 {} │ │ │ │ +441 │ │ │ │ +_4_4_6 inline T& _d_e_r_e_f_e_r_e_n_c_e() const │ │ │ │ +447 { │ │ │ │ +448 return *iterator_; │ │ │ │ +449 } │ │ │ │ +450 │ │ │ │ +_4_5_6 inline bool _e_q_u_a_l_s(const _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_<_T_,_A_>& other) const │ │ │ │ +457 { │ │ │ │ +458 return iterator_== other; │ │ │ │ +459 } │ │ │ │ +460 │ │ │ │ +461 │ │ │ │ +_4_6_7 inline bool _e_q_u_a_l_s(const _S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_>& other) const │ │ │ │ +468 { │ │ │ │ +469 return iterator_== other; │ │ │ │ +470 } │ │ │ │ +471 │ │ │ │ +472 │ │ │ │ +_4_7_8 inline bool _e_q_u_a_l_s(const _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_T_,_A_>& other) const │ │ │ │ +479 { │ │ │ │ +480 return iterator_== other.iterator_; │ │ │ │ +481 } │ │ │ │ +482 │ │ │ │ +_4_8_6 inline void _i_n_c_r_e_m_e_n_t() │ │ │ │ +487 { │ │ │ │ +488 ++iterator_; │ │ │ │ +489 ++beforeIterator_; │ │ │ │ +490 } │ │ │ │ +491 │ │ │ │ +_5_0_5 inline void _i_n_s_e_r_t(const T& v) │ │ │ │ +506 { │ │ │ │ +507 beforeIterator_.insertAfter(v); │ │ │ │ +508 ++beforeIterator_; │ │ │ │ +509 } │ │ │ │ +510 │ │ │ │ +_5_1_8 inline void _r_e_m_o_v_e() │ │ │ │ +519 { │ │ │ │ +520 ++iterator_; │ │ │ │ +521 beforeIterator_.deleteNext(); │ │ │ │ +522 } │ │ │ │ +523 │ │ │ │ +524 private: │ │ │ │ +526 _S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> beforeIterator_; │ │ │ │ +528 _S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> iterator_; │ │ │ │ +529 }; │ │ │ │ +530 │ │ │ │ +531 template │ │ │ │ +_5_3_2 std::ostream& _o_p_e_r_a_t_o_r_<_<(std::ostream& os, const _S_L_L_i_s_t_<_T_,_A_>& sllist) │ │ │ │ +533 { │ │ │ │ +534 typedef typename _S_L_L_i_s_t_<_T_,_A_>_:_:_c_o_n_s_t___i_t_e_r_a_t_o_r Iterator; │ │ │ │ +535 Iterator end = sllist._e_n_d(); │ │ │ │ +536 Iterator current= sllist._b_e_g_i_n(); │ │ │ │ +537 │ │ │ │ +538 os << "{ "; │ │ │ │ +539 │ │ │ │ +540 if(current!=end) { │ │ │ │ +541 os<<*current<<" ("<(&(*current))<<")"; │ │ │ │ +542 ++current; │ │ │ │ +543 │ │ │ │ +544 for(; current != end; ++current) │ │ │ │ +545 os<<", "<<*current<<" ("<(&(*current))<<")"; │ │ │ │ +546 } │ │ │ │ +547 os<<"} "; │ │ │ │ +548 return os; │ │ │ │ +549 } │ │ │ │ +550 │ │ │ │ +551 template │ │ │ │ +_5_5_2 _S_L_L_i_s_t_<_T_,_A_>_:_:_E_l_e_m_e_n_t_:_:_E_l_e_m_e_n_t(const _M_e_m_b_e_r_T_y_p_e& item, _E_l_e_m_e_n_t* next) │ │ │ │ +553 : _n_e_x_t__(next), _i_t_e_m__(item) │ │ │ │ +554 {} │ │ │ │ +555 │ │ │ │ +556 template │ │ │ │ +_5_5_7 _S_L_L_i_s_t_<_T_,_A_>_:_:_E_l_e_m_e_n_t_:_:_E_l_e_m_e_n_t() │ │ │ │ +558 : _n_e_x_t__(0), _i_t_e_m__() │ │ │ │ +559 {} │ │ │ │ +560 │ │ │ │ +561 template │ │ │ │ +_5_6_2 _S_L_L_i_s_t_<_T_,_A_>_:_:_E_l_e_m_e_n_t_:_:_~_E_l_e_m_e_n_t() │ │ │ │ +563 { │ │ │ │ +564 _n_e_x_t__=0; │ │ │ │ +565 } │ │ │ │ +566 │ │ │ │ +567 template │ │ │ │ +_5_6_8 _S_L_L_i_s_t_<_T_,_A_>_:_:_S_L_L_i_s_t() │ │ │ │ +569 : beforeHead_(), tail_(&beforeHead_), allocator_(), size_(0) │ │ │ │ +570 { │ │ │ │ +571 beforeHead_.next_=0; │ │ │ │ +572 assert(&beforeHead_==tail_); │ │ │ │ +573 assert(tail_->next_==0); │ │ │ │ +574 } │ │ │ │ +575 │ │ │ │ +576 template │ │ │ │ +_5_7_7 _S_L_L_i_s_t_<_T_,_A_>_:_:_S_L_L_i_s_t(const _S_L_L_i_s_t_<_T_,_A_>& other) │ │ │ │ +578 : beforeHead_(), tail_(&beforeHead_), allocator_(), size_(0) │ │ │ │ +579 { │ │ │ │ +580 copyElements(other); │ │ │ │ +581 } │ │ │ │ +582 │ │ │ │ +583 template │ │ │ │ +584 template │ │ │ │ +_5_8_5 _S_L_L_i_s_t_<_T_,_A_>_:_:_S_L_L_i_s_t(const _S_L_L_i_s_t_<_T_1_,_A_1_>& other) │ │ │ │ +586 : beforeHead_(), tail_(&beforeHead_), allocator_(), size_(0) │ │ │ │ +587 { │ │ │ │ +588 copyElements(other); │ │ │ │ +589 } │ │ │ │ +590 │ │ │ │ +591 template │ │ │ │ +592 void SLList::copyElements(const _S_L_L_i_s_t_<_T_,_A_>& other) │ │ │ │ +593 { │ │ │ │ +594 assert(tail_==&beforeHead_); │ │ │ │ +595 assert(size_==0); │ │ │ │ +596 typedef typename _S_L_L_i_s_t_<_T_,_A_>_:_:_c_o_n_s_t___i_t_e_r_a_t_o_r Iterator; │ │ │ │ +597 Iterator iend = other._e_n_d(); │ │ │ │ +598 for(Iterator element=other._b_e_g_i_n(); element != iend; ++element) │ │ │ │ +599 _p_u_s_h___b_a_c_k(*element); │ │ │ │ +600 │ │ │ │ +601 assert(other._s_i_z_e()==_s_i_z_e()); │ │ │ │ +602 } │ │ │ │ +603 │ │ │ │ +604 template │ │ │ │ +_6_0_5 _S_L_L_i_s_t_<_T_,_A_>_:_:_~_S_L_L_i_s_t() │ │ │ │ +606 { │ │ │ │ +607 _c_l_e_a_r(); │ │ │ │ +608 } │ │ │ │ +609 │ │ │ │ +610 template │ │ │ │ +_6_1_1 bool _S_L_L_i_s_t_<_T_,_A_>_:_:_o_p_e_r_a_t_o_r_=_=(const _S_L_L_i_s_t& other) const │ │ │ │ +612 { │ │ │ │ +613 if(_s_i_z_e()!=other._s_i_z_e()) │ │ │ │ +614 return false; │ │ │ │ +615 for(_c_o_n_s_t___i_t_e_r_a_t_o_r iter=_b_e_g_i_n(), oiter=other._b_e_g_i_n(); │ │ │ │ +616 iter != _e_n_d(); ++iter, ++oiter) │ │ │ │ +617 if(*iter!=*oiter) │ │ │ │ +618 return false; │ │ │ │ +619 return true; │ │ │ │ +620 } │ │ │ │ +621 │ │ │ │ +622 template │ │ │ │ +_6_2_3 bool _S_L_L_i_s_t_<_T_,_A_>_:_:_o_p_e_r_a_t_o_r_!_=(const _S_L_L_i_s_t& other) const │ │ │ │ +624 { │ │ │ │ +625 if(_s_i_z_e()==other._s_i_z_e()) { │ │ │ │ +626 for(_c_o_n_s_t___i_t_e_r_a_t_o_r iter=_b_e_g_i_n(), oiter=other._b_e_g_i_n(); │ │ │ │ +627 iter != _e_n_d(); ++iter, ++oiter) │ │ │ │ +628 if(*iter!=*oiter) │ │ │ │ +629 return true; │ │ │ │ +630 return false; │ │ │ │ +631 }else │ │ │ │ +632 return true; │ │ │ │ +633 } │ │ │ │ +634 template │ │ │ │ +_6_3_5 _S_L_L_i_s_t_<_T_,_A_>& _S_L_L_i_s_t_<_T_,_A_>_:_:_o_p_e_r_a_t_o_r_=(const _S_L_L_i_s_t_<_T_,_A_>& other) │ │ │ │ +636 { │ │ │ │ +637 _c_l_e_a_r(); │ │ │ │ +638 copyElements(other); │ │ │ │ +639 return *this; │ │ │ │ +640 } │ │ │ │ +641 │ │ │ │ +642 template │ │ │ │ +_6_4_3 inline void _S_L_L_i_s_t_<_T_,_A_>_:_:_p_u_s_h___b_a_c_k(const _M_e_m_b_e_r_T_y_p_e& item) │ │ │ │ +644 { │ │ │ │ +645 assert(size_>0 || tail_==&beforeHead_); │ │ │ │ +646 tail_->next_ = allocator_.allocate(1); │ │ │ │ +647 assert(size_>0 || tail_==&beforeHead_); │ │ │ │ +648 tail_ = tail_->next_; │ │ │ │ +649 ::new (static_cast(&(tail_->item_)))T(item); │ │ │ │ +650 tail_->next_=0; │ │ │ │ +651 assert(tail_->next_==0); │ │ │ │ +652 ++size_; │ │ │ │ +653 } │ │ │ │ +654 │ │ │ │ +655 template │ │ │ │ +656 inline void SLList::insertAfter(Element* current, const T& item) │ │ │ │ +657 { │ │ │ │ +658 assert(current); │ │ │ │ +659 │ │ │ │ +660#ifndef NDEBUG │ │ │ │ +661 bool changeTail = (current == tail_); │ │ │ │ +662#endif │ │ │ │ +663 │ │ │ │ +664 // Save old next element │ │ │ │ +665 Element* tmp = current->next_; │ │ │ │ +666 │ │ │ │ +667 assert(!changeTail || !tmp); │ │ │ │ +668 │ │ │ │ +669 // Allocate space │ │ │ │ +670 current->next_ = allocator_.allocate(1); │ │ │ │ +671 │ │ │ │ +672 // Use copy constructor to initialize memory │ │ │ │ +673 std::allocator_traits::construct(allocator_, current->next_, │ │ │ │ +Element(item,tmp)); │ │ │ │ +674 │ │ │ │ +675 //::new(static_cast(&(current->next_->item_))) T(item); │ │ │ │ +676 │ │ │ │ +677 if(!current->next_->next_) { │ │ │ │ +678 // Update tail │ │ │ │ +679 assert(changeTail); │ │ │ │ +680 tail_ = current->next_; │ │ │ │ +681 } │ │ │ │ +682 ++size_; │ │ │ │ +683 assert(!tail_->next_); │ │ │ │ +684 } │ │ │ │ +685 │ │ │ │ +686 template │ │ │ │ +_6_8_7 inline void _S_L_L_i_s_t_<_T_,_A_>_:_:_p_u_s_h___f_r_o_n_t(const _M_e_m_b_e_r_T_y_p_e& item) │ │ │ │ +688 { │ │ │ │ +689 if(tail_ == &beforeHead_) { │ │ │ │ +690 // list was empty │ │ │ │ +691 beforeHead_.next_ = tail_ = allocator_.allocate(1, 0); │ │ │ │ +692 ::new(static_cast(&beforeHead_.next_->item_))T(item); │ │ │ │ +693 beforeHead_.next_->next_=0; │ │ │ │ +694 }else{ │ │ │ │ +695 Element* added = allocator_.allocate(1, 0); │ │ │ │ +696 ::new(static_cast(&added->_i_t_e_m__))T(item); │ │ │ │ +697 added->_n_e_x_t__=beforeHead_._n_e_x_t__; │ │ │ │ +698 beforeHead_._n_e_x_t__=added; │ │ │ │ +699 } │ │ │ │ +700 assert(tail_->next_==0); │ │ │ │ +701 ++size_; │ │ │ │ +702 } │ │ │ │ +703 │ │ │ │ +704 │ │ │ │ +705 template │ │ │ │ +706 inline void SLList::deleteNext(Element* current) │ │ │ │ +707 { │ │ │ │ +708 this->template deleteNext(current); │ │ │ │ +709 } │ │ │ │ +710 │ │ │ │ +711 template │ │ │ │ +712 template │ │ │ │ +713 inline void SLList::deleteNext(Element* current) │ │ │ │ +714 { │ │ │ │ +715 assert(current->next_); │ │ │ │ +716 Element* next = current->next_; │ │ │ │ +717 │ │ │ │ +718 if(watchForTail) │ │ │ │ +719 if(next == tail_) { │ │ │ │ +720 // deleting last element changes tail! │ │ │ │ +721 tail_ = current; │ │ │ │ +722 } │ │ │ │ +723 │ │ │ │ +724 current->next_ = next->next_; │ │ │ │ +725 std::allocator_traits::destroy(allocator_, next); │ │ │ │ +726 allocator_.deallocate(next, 1); │ │ │ │ +727 --size_; │ │ │ │ +728 assert(!watchForTail || &beforeHead_ != tail_ || size_==0); │ │ │ │ +729 } │ │ │ │ +730 │ │ │ │ +731 template │ │ │ │ +_7_3_2 inline void _S_L_L_i_s_t_<_T_,_A_>_:_:_p_o_p___f_r_o_n_t() │ │ │ │ +733 { │ │ │ │ +734 deleteNext(&beforeHead_); │ │ │ │ +735 } │ │ │ │ +736 │ │ │ │ +737 template │ │ │ │ +_7_3_8 inline void _S_L_L_i_s_t_<_T_,_A_>_:_:_c_l_e_a_r() │ │ │ │ +739 { │ │ │ │ +740 while(beforeHead_.next_ ) { │ │ │ │ +741 this->template deleteNext(&beforeHead_); │ │ │ │ +742 } │ │ │ │ +743 │ │ │ │ +744 assert(size_==0); │ │ │ │ +745 // update the tail! │ │ │ │ +746 tail_ = &beforeHead_; │ │ │ │ +747 } │ │ │ │ +748 │ │ │ │ +749 template │ │ │ │ +_7_5_0 inline bool _S_L_L_i_s_t_<_T_,_A_>_:_:_e_m_p_t_y() const │ │ │ │ +751 { │ │ │ │ +752 return (&beforeHead_ == tail_); │ │ │ │ +753 } │ │ │ │ +754 │ │ │ │ +755 template │ │ │ │ +_7_5_6 inline int _S_L_L_i_s_t_<_T_,_A_>_:_:_s_i_z_e() const │ │ │ │ +757 { │ │ │ │ +758 return size_; │ │ │ │ +759 } │ │ │ │ +760 │ │ │ │ +761 template │ │ │ │ +_7_6_2 inline _S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> _S_L_L_i_s_t_<_T_,_A_>_:_:_b_e_g_i_n() │ │ │ │ +763 { │ │ │ │ +764 return _i_t_e_r_a_t_o_r(beforeHead_.next_, this); │ │ │ │ +765 } │ │ │ │ +766 │ │ │ │ +767 template │ │ │ │ +_7_6_8 inline _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> _S_L_L_i_s_t_<_T_,_A_>_:_:_b_e_g_i_n() const │ │ │ │ +769 { │ │ │ │ +770 return _c_o_n_s_t___i_t_e_r_a_t_o_r(beforeHead_.next_); │ │ │ │ +771 } │ │ │ │ +772 │ │ │ │ +773 template │ │ │ │ +_7_7_4 inline _S_L_L_i_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> _S_L_L_i_s_t_<_T_,_A_>_:_:_e_n_d() │ │ │ │ +775 { │ │ │ │ +776 return _i_t_e_r_a_t_o_r(); │ │ │ │ +777 } │ │ │ │ +778 │ │ │ │ +779 template │ │ │ │ +_7_8_0 inline _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_T_,_A_> _S_L_L_i_s_t_<_T_,_A_>_:_:_e_n_d_M_o_d_i_f_y() │ │ │ │ +781 { │ │ │ │ +782 return _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_T_,_A_>(_i_t_e_r_a_t_o_r(tail_, this),_i_t_e_r_a_t_o_r()); │ │ │ │ +783 } │ │ │ │ +784 │ │ │ │ +785 │ │ │ │ +786 template │ │ │ │ +_7_8_7 inline _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_T_,_A_> _S_L_L_i_s_t_<_T_,_A_>_:_:_b_e_g_i_n_M_o_d_i_f_y() │ │ │ │ +788 { │ │ │ │ +789 return _S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_<_T_,_A_>(_i_t_e_r_a_t_o_r(&beforeHead_, this), │ │ │ │ +790 _i_t_e_r_a_t_o_r(beforeHead_.next_, this)); │ │ │ │ +791 } │ │ │ │ +792 │ │ │ │ +793 template │ │ │ │ +_7_9_4 inline _S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_<_T_,_A_> _S_L_L_i_s_t_<_T_,_A_>_:_:_e_n_d() const │ │ │ │ +795 { │ │ │ │ +796 return _c_o_n_s_t___i_t_e_r_a_t_o_r(); │ │ │ │ +797 } │ │ │ │ +798 │ │ │ │ +800} │ │ │ │ +801#endif │ │ │ │ +_i_t_e_r_a_t_o_r_f_a_c_a_d_e_s_._h_h │ │ │ │ +This file implements iterator facade classes for writing stl conformant │ │ │ │ +iterators. │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_p_u_s_h___f_r_o_n_t │ │ │ │ +void push_front(const MemberType &item) │ │ │ │ +Add a new entry to the beginning of the list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:687 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_:_:_e_q_u_a_l_s │ │ │ │ +bool equals(const SLListConstIterator< T, A > &other) const │ │ │ │ +Equality test for the iterator facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:406 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_p_u_s_h___b_a_c_k │ │ │ │ +void push_back(const MemberType &item) │ │ │ │ +Add a new entry to the end of the list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:643 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_e_n_d_M_o_d_i_f_y │ │ │ │ +ModifyIterator endModify() │ │ │ │ +Get an iterator capable of deleting and inserting elements. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:780 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r │ │ │ │ +SLListModifyIterator() │ │ │ │ +DDeeffiinniittiioonn sllist.hh:438 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_E_l_e_m_e_n_t_:_:_E_l_e_m_e_n_t │ │ │ │ +Element() │ │ │ │ +DDeeffiinniittiioonn sllist.hh:557 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_d_e_r_e_f_e_r_e_n_c_e │ │ │ │ +T & dereference() const │ │ │ │ +Dereferencing function for the iterator facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:294 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_o_p_e_r_a_t_o_r_!_= │ │ │ │ +bool operator!=(const SLList &sl) const │ │ │ │ +DDeeffiinniittiioonn sllist.hh:623 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_E_l_e_m_e_n_t_:_:_i_t_e_m__ │ │ │ │ +MemberType item_ │ │ │ │ +The element we hold. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:212 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r │ │ │ │ +SLListConstIterator(typename SLList< T, A >::Element *item) │ │ │ │ +DDeeffiinniittiioonn sllist.hh:380 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_<_ _s_t_d_:_:_p_a_i_r_<_ _G_l_o_b_a_l_I_n_d_e_x_,_ _A_t_t_r_i_b_u_t_e_ _>_,_ _t_y_p_e_n_a_m_e_ _R_e_m_o_t_e_I_n_d_i_c_e_s_:_: │ │ │ │ +_A_l_l_o_c_a_t_o_r_ _>_:_:_A_l_l_o_c_a_t_o_r │ │ │ │ +typename std::allocator_traits< typename RemoteIndices::Allocator >::template │ │ │ │ +rebind_alloc< Element > Allocator │ │ │ │ +DDeeffiinniittiioonn sllist.hh:64 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_i_n_s_e_r_t_A_f_t_e_r │ │ │ │ +void insertAfter(const T &v) const │ │ │ │ +Insert an element in the underlying list after the current position. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:342 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_<_ _s_t_d_:_:_p_a_i_r_<_ _G_l_o_b_a_l_I_n_d_e_x_,_ _A_t_t_r_i_b_u_t_e_ _>_,_ _t_y_p_e_n_a_m_e_ _R_e_m_o_t_e_I_n_d_i_c_e_s_:_: │ │ │ │ +_A_l_l_o_c_a_t_o_r_ _>_:_:_i_t_e_r_a_t_o_r │ │ │ │ +SLListIterator< std::pair< GlobalIndex, Attribute >, typename RemoteIndices:: │ │ │ │ +Allocator > iterator │ │ │ │ +DDeeffiinniittiioonn sllist.hh:69 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r │ │ │ │ +SLListConstIterator(const SLListModifyIterator< T, A > &other) │ │ │ │ +DDeeffiinniittiioonn sllist.hh:388 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r │ │ │ │ +SLListIterator() │ │ │ │ +DDeeffiinniittiioonn sllist.hh:282 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_E_l_e_m_e_n_t_:_:_E_l_e_m_e_n_t │ │ │ │ +Element(const MemberType &item, Element *next_=0) │ │ │ │ +DDeeffiinniittiioonn sllist.hh:552 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_E_l_e_m_e_n_t_:_:_~_E_l_e_m_e_n_t │ │ │ │ +~Element() │ │ │ │ +DDeeffiinniittiioonn sllist.hh:562 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_o_p_e_r_a_t_o_r_=_= │ │ │ │ +bool operator==(const SLList &sl) const │ │ │ │ +DDeeffiinniittiioonn sllist.hh:611 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_d_e_l_e_t_e_N_e_x_t │ │ │ │ +void deleteNext() const │ │ │ │ +Delete the entry after the current position. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:353 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_S_L_L_i_s_t │ │ │ │ +SLList(const SLList< T, A > &other) │ │ │ │ +Copy constructor. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:577 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_e_q_u_a_l_s │ │ │ │ +bool equals(const SLListModifyIterator< T, A > &other) const │ │ │ │ +Equality test for the iterator facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:324 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_:_:_d_e_r_e_f_e_r_e_n_c_e │ │ │ │ +T & dereference() const │ │ │ │ +Dereferencing function for the iterator facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:446 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_s_i_z_e │ │ │ │ +int size() const │ │ │ │ +Get the number of elements the list contains. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:756 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_b_e_g_i_n │ │ │ │ +const_iterator begin() const │ │ │ │ +Get an iterator pointing to the first element in the list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:768 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_e_n_d │ │ │ │ +iterator end() │ │ │ │ +Get an iterator pointing to the end of the list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:774 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_c_l_e_a_r │ │ │ │ +void clear() │ │ │ │ +Remove all elements from the list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:738 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_S_L_L_i_s_t │ │ │ │ +SLList(const SLList< T1, A1 > &other) │ │ │ │ +Copy constructor with type conversion. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:585 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_<_ _s_t_d_:_:_p_a_i_r_<_ _G_l_o_b_a_l_I_n_d_e_x_,_ _A_t_t_r_i_b_u_t_e_ _>_,_ _t_y_p_e_n_a_m_e_ _R_e_m_o_t_e_I_n_d_i_c_e_s_:_: │ │ │ │ +_A_l_l_o_c_a_t_o_r_ _>_:_:_M_e_m_b_e_r_T_y_p_e │ │ │ │ +std::pair< GlobalIndex, Attribute > MemberType │ │ │ │ +DDeeffiinniittiioonn sllist.hh:59 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_:_:_e_q_u_a_l_s │ │ │ │ +bool equals(const SLListModifyIterator< T, A > &other) const │ │ │ │ +Test whether another iterator is equal. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:478 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_b_e_g_i_n_M_o_d_i_f_y │ │ │ │ +ModifyIterator beginModify() │ │ │ │ +Get an iterator capable of deleting and inserting elements. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:787 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ +SLList< T, A > & operator=(const SLList< T, A > &other) │ │ │ │ +Assignment operator. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:635 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r │ │ │ │ +SLListConstIterator(const SLListIterator< T, A > &other) │ │ │ │ +DDeeffiinniittiioonn sllist.hh:384 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_<_ _s_t_d_:_:_p_a_i_r_<_ _G_l_o_b_a_l_I_n_d_e_x_,_ _A_t_t_r_i_b_u_t_e_ _>_,_ _t_y_p_e_n_a_m_e_ _R_e_m_o_t_e_I_n_d_i_c_e_s_:_: │ │ │ │ +_A_l_l_o_c_a_t_o_r_ _>_:_:_c_o_n_s_t___i_t_e_r_a_t_o_r │ │ │ │ +SLListConstIterator< std::pair< GlobalIndex, Attribute >, typename │ │ │ │ +RemoteIndices::Allocator > const_iterator │ │ │ │ +DDeeffiinniittiioonn sllist.hh:74 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_e_m_p_t_y │ │ │ │ +bool empty() const │ │ │ │ +Check whether the list is empty. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:750 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r │ │ │ │ +SLListConstIterator() │ │ │ │ +DDeeffiinniittiioonn sllist.hh:376 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_e_q_u_a_l_s │ │ │ │ +bool equals(const SLListConstIterator< T, A > &other) const │ │ │ │ +Equality test for the iterator facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:304 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_:_:_e_q_u_a_l_s │ │ │ │ +bool equals(const SLListConstIterator< T, A > &other) const │ │ │ │ +Test whether another iterator is equal. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:456 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_<_ _s_t_d_:_:_p_a_i_r_<_ _G_l_o_b_a_l_I_n_d_e_x_,_ _A_t_t_r_i_b_u_t_e_ _>_,_ _t_y_p_e_n_a_m_e_ _R_e_m_o_t_e_I_n_d_i_c_e_s_:_: │ │ │ │ +_A_l_l_o_c_a_t_o_r_ _>_:_:_M_o_d_i_f_y_I_t_e_r_a_t_o_r │ │ │ │ +SLListModifyIterator< std::pair< GlobalIndex, Attribute >, typename │ │ │ │ +RemoteIndices::Allocator > ModifyIterator │ │ │ │ +DDeeffiinniittiioonn sllist.hh:103 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_e_n_d │ │ │ │ +const_iterator end() const │ │ │ │ +Get an iterator pointing to the end of the list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:794 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_S_L_L_i_s_t │ │ │ │ +SLList() │ │ │ │ +Constructor. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:568 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_:_:_i_n_s_e_r_t │ │ │ │ +void insert(const T &v) │ │ │ │ +Insert an element at the current position. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:505 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r │ │ │ │ +SLListIterator(typename SLList< T, A >::Element *item, SLList< T, A > *sllist) │ │ │ │ +DDeeffiinniittiioonn sllist.hh:277 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r │ │ │ │ +SLListModifyIterator(SLListIterator< T, A > beforeIterator, SLListIterator< T, │ │ │ │ +A > _iterator) │ │ │ │ +DDeeffiinniittiioonn sllist.hh:433 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_p_o_p___f_r_o_n_t │ │ │ │ +void pop_front() │ │ │ │ +Remove the first item in the list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:732 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_i_n_c_r_e_m_e_n_t │ │ │ │ +void increment() │ │ │ │ +Increment function for the iterator facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:332 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r │ │ │ │ +SLListIterator(const SLListModifyIterator< T, A > &other) │ │ │ │ +DDeeffiinniittiioonn sllist.hh:286 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_<_ _s_t_d_:_:_p_a_i_r_<_ _G_l_o_b_a_l_I_n_d_e_x_,_ _A_t_t_r_i_b_u_t_e_ _>_,_ _t_y_p_e_n_a_m_e_ _R_e_m_o_t_e_I_n_d_i_c_e_s_:_: │ │ │ │ +_A_l_l_o_c_a_t_o_r_ _>_:_:_s_i_z_e___t_y_p_e │ │ │ │ +typename RemoteIndices::Allocator::size_type size_type │ │ │ │ +DDeeffiinniittiioonn sllist.hh:54 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_:_:_r_e_m_o_v_e │ │ │ │ +void remove() │ │ │ │ +Delete the entry at the current position. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:518 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_:_:_d_e_r_e_f_e_r_e_n_c_e │ │ │ │ +const T & dereference() const │ │ │ │ +Dereferencing function for the facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:396 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_E_l_e_m_e_n_t_:_:_n_e_x_t__ │ │ │ │ +Element * next_ │ │ │ │ +The next element in the list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:208 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_:_:_i_n_c_r_e_m_e_n_t │ │ │ │ +void increment() │ │ │ │ +Increment function for the iterator facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:486 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r_:_:_i_n_c_r_e_m_e_n_t │ │ │ │ +void increment() │ │ │ │ +Increment function for the iterator facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:414 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_~_S_L_L_i_s_t │ │ │ │ +~SLList() │ │ │ │ +Destructor. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:605 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r_:_:_e_q_u_a_l_s │ │ │ │ +bool equals(const SLListIterator< T, A > &other) const │ │ │ │ +Test whether another iterator is equal. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:467 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_:_:_b_e_g_i_n │ │ │ │ +iterator begin() │ │ │ │ +Get an iterator pointing to the first element in the list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:762 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r_:_:_e_q_u_a_l_s │ │ │ │ +bool equals(const SLListIterator< T, A > &other) const │ │ │ │ +Equality test for the iterator facade. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:314 │ │ │ │ +_D_u_n_e_:_:_o_p_e_r_a_t_o_r_<_< │ │ │ │ +std::ostream & operator<<(std::ostream &s, const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:301 │ │ │ │ +_D_u_n_e │ │ │ │ +Dune namespace │ │ │ │ +DDeeffiinniittiioonn alignedallocator.hh:13 │ │ │ │ +_D_u_n_e_:_:_s_i_z_e │ │ │ │ +constexpr std::integral_constant< std::size_t, sizeof...(II)> size(std:: │ │ │ │ +integer_sequence< T, II... >) │ │ │ │ +Return the size of the sequence. │ │ │ │ +DDeeffiinniittiioonn integersequence.hh:75 │ │ │ │ +_D_u_n_e_:_:_p_u_s_h___b_a_c_k │ │ │ │ +constexpr HybridMultiIndex< T..., std::size_t > push_back(const │ │ │ │ +HybridMultiIndex< T... > &tp, std::size_t i) │ │ │ │ +Appends a run time index to a HybridMultiIndex. │ │ │ │ +DDeeffiinniittiioonn hybridmultiindex.hh:249 │ │ │ │ +_D_u_n_e_:_:_F_o_r_w_a_r_d_I_t_e_r_a_t_o_r_F_a_c_a_d_e │ │ │ │ +Base class for stl conformant forward iterators. │ │ │ │ +DDeeffiinniittiioonn iteratorfacades.hh:142 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_I_t_e_r_a_t_o_r │ │ │ │ +A mutable iterator for the SLList. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:271 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_C_o_n_s_t_I_t_e_r_a_t_o_r │ │ │ │ +A constant iterator for the SLList. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:371 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t_M_o_d_i_f_y_I_t_e_r_a_t_o_r │ │ │ │ +A mutable iterator for the SLList. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:429 │ │ │ │ +_D_u_n_e_:_:_S_L_L_i_s_t │ │ │ │ +A single linked list. │ │ │ │ +DDeeffiinniittiioonn sllist.hh:44 │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00014.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: vc.hh File Reference │ │ │ +dune-common: ios_state.cc File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -71,26 +71,27 @@ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
vc.hh File Reference
│ │ │ +
│ │ │ +Namespaces
│ │ │ +
ios_state.cc File Reference
│ │ │
│ │ │
│ │ │ - │ │ │ -

Compatibility header for including <Vc/Vc>. │ │ │ -More...

│ │ │ - │ │ │ -

Go to the source code of this file.

│ │ │ -

Detailed Description

│ │ │ -

Compatibility header for including <Vc/Vc>.

│ │ │ -

Certain versions (1.3.2) of Vc (https://github.com/VcDevel/Vc) have a problem with certain compiler versions (g++ 7.2.0) in c++17 mode, see #88.

│ │ │ -
│ │ │ +
#include <dune/common/ios_state.hh>
│ │ │ +
│ │ │ + │ │ │ + │ │ │ + │ │ │ +

│ │ │ +Namespaces

namespace  Dune
 Dune namespace
│ │ │ +
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,15 +1,14 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -vc.hh File Reference │ │ │ │ -Compatibility header for including . _M_o_r_e_._._. │ │ │ │ -_G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ -Compatibility header for including . │ │ │ │ -Certain versions (1.3.2) of Vc (_h_t_t_p_s_:_/_/_g_i_t_h_u_b_._c_o_m_/_V_c_D_e_v_e_l_/_V_c) have a problem │ │ │ │ -with certain compiler versions (g++ 7.2.0) in c++17 mode, see #88. │ │ │ │ +_N_a_m_e_s_p_a_c_e_s │ │ │ │ +ios_state.cc File Reference │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_o_s___s_t_a_t_e_._h_h> │ │ │ │ +NNaammeessppaacceess │ │ │ │ +namespace   _D_u_n_e │ │ │ │ +  Dune namespace │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00017.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: unused.hh File Reference │ │ │ +dune-common: parameterizedobject.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -72,31 +72,37 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ -Macros
│ │ │ -
unused.hh File Reference
│ │ │ +Classes | │ │ │ +Namespaces
│ │ │ +
parameterizedobject.hh File Reference
│ │ │
│ │ │
│ │ │ - │ │ │ -

Definition of the DUNE_UNUSED_PARAMETER macro. │ │ │ -More...

│ │ │ - │ │ │ +
#include <functional>
│ │ │ +#include <map>
│ │ │ +#include <memory>
│ │ │ +#include <dune/common/exceptions.hh>
│ │ │ +#include <dune/common/typeutilities.hh>
│ │ │ +
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ +

│ │ │ -Macros

#define DUNE_UNUSED_PARAMETER(param)

│ │ │ +Classes

class  Dune::ParameterizedObjectFactory< TypeT(Args...), KeyT >
│ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ +Namespaces

namespace  Dune
 Dune namespace
│ │ │ -

Detailed Description

│ │ │ -

Definition of the DUNE_UNUSED_PARAMETER macro.

│ │ │ -
│ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,16 +1,21 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -_M_a_c_r_o_s │ │ │ │ -unused.hh File Reference │ │ │ │ -Definition of the _D_U_N_E___U_N_U_S_E_D___P_A_R_A_M_E_T_E_R macro. _M_o_r_e_._._. │ │ │ │ +_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s │ │ │ │ +parameterizedobject.hh File Reference │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_e_x_c_e_p_t_i_o_n_s_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -MMaaccrrooss │ │ │ │ -#define  _D_U_N_E___U_N_U_S_E_D___P_A_R_A_M_E_T_E_R(param) │ │ │ │ -********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ -Definition of the _D_U_N_E___U_N_U_S_E_D___P_A_R_A_M_E_T_E_R macro. │ │ │ │ +CCllaasssseess │ │ │ │ +class   _D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _> │ │ │ │ +NNaammeessppaacceess │ │ │ │ +namespace   _D_u_n_e │ │ │ │ +  Dune namespace │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00017_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: unused.hh Source File │ │ │ +dune-common: parameterizedobject.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -71,27 +71,179 @@ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
unused.hh
│ │ │ +
parameterizedobject.hh
│ │ │
│ │ │
│ │ │ -Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │ -
2// vi: set et ts=4 sw=2 sts=2:
│ │ │ +Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
│ │ │ +
2// vi: set et ts=4 sw=4 sts=4:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ -
5#ifndef DUNE_COMMON_UNUSED_HH
│ │ │ -
6#define DUNE_COMMON_UNUSED_HH
│ │ │ -
7
│ │ │ -
11
│ │ │ -
21#define DUNE_UNUSED_PARAMETER(param) static_cast<void>(param)
│ │ │ -
22#endif
│ │ │ +
5#ifndef DUNE_COMMON_PARAMETERIZEDOBJECT_HH
│ │ │ +
6#define DUNE_COMMON_PARAMETERIZEDOBJECT_HH
│ │ │ +
7
│ │ │ +
8#include <functional>
│ │ │ +
9#include <map>
│ │ │ +
10#include <memory>
│ │ │ +
11
│ │ │ + │ │ │ + │ │ │ +
14
│ │ │ +
15namespace Dune {
│ │ │ +
16
│ │ │ +
34template<typename Signature,
│ │ │ +
35 typename KeyT = std::string>
│ │ │ + │ │ │ +
37
│ │ │ +
38template<typename TypeT,
│ │ │ +
39 typename KeyT,
│ │ │ +
40 typename... Args>
│ │ │ +
│ │ │ +
41class ParameterizedObjectFactory<TypeT(Args...), KeyT>
│ │ │ +
42{
│ │ │ +
43 public:
│ │ │ +
44
│ │ │ +
46 typedef KeyT Key;
│ │ │ +
47
│ │ │ +
49 using Type = TypeT;
│ │ │ +
50
│ │ │ +
51 protected:
│ │ │ +
52
│ │ │ +
53 using Creator = std::function<Type(Args...)>;
│ │ │ +
54
│ │ │ +
55 template<class F>
│ │ │ +
│ │ │ + │ │ │ +
57 -> decltype( std::declval<F>()(std::declval<Args>()...), std::true_type())
│ │ │ +
58 {
│ │ │ +
59 return {};
│ │ │ +
60 }
│ │ │ +
│ │ │ +
61
│ │ │ +
62 template<class F>
│ │ │ +
│ │ │ +
63 static constexpr std::false_type has_proper_signature(Dune::PriorityTag<0>)
│ │ │ +
64 {
│ │ │ +
65 return {};
│ │ │ +
66 }
│ │ │ +
│ │ │ +
67
│ │ │ +
68 public:
│ │ │ +
69
│ │ │ +
│ │ │ +
77 Type create(Key const& key, Args ... args) const {
│ │ │ +
78 typename Registry::const_iterator i = registry_.find(key);
│ │ │ +
79 if (i == registry_.end()) {
│ │ │ + │ │ │ +
81 "ParametrizedObjectFactory: key ``" <<
│ │ │ +
82 key << "'' not registered");
│ │ │ +
83 }
│ │ │ +
84 else return i->second(args...);
│ │ │ +
85 }
│ │ │ +
│ │ │ +
86
│ │ │ +
100 template<class Impl>
│ │ │ +
│ │ │ +
101 void define(Key const& key)
│ │ │ +
102 {
│ │ │ +
103 registry_[key] = DefaultCreator<Impl>();
│ │ │ +
104 }
│ │ │ +
│ │ │ +
105
│ │ │ +
119 template<class F,
│ │ │ +
120 typename std::enable_if<has_proper_signature<F>(PriorityTag<42>()), int>::type = 0>
│ │ │ +
│ │ │ +
121 void define(Key const& key, F&& f)
│ │ │ +
122 {
│ │ │ +
123 registry_[key] = f;
│ │ │ +
124 }
│ │ │ +
│ │ │ +
125
│ │ │ +
140 template<class Impl,
│ │ │ +
141 typename std::enable_if<
│ │ │ +
142 std::is_convertible<Impl, Type>::value
│ │ │ +
143 and not std::is_convertible<Impl, Creator>::value,
│ │ │ +
144 int>::type = 0>
│ │ │ +
│ │ │ +
145 void define(Key const& key, Impl&& t)
│ │ │ +
146 {
│ │ │ +
147 registry_[key] = [=](Args...) { return t;};
│ │ │ +
148 }
│ │ │ +
│ │ │ +
149
│ │ │ +
│ │ │ +
150 bool contains(Key const& key) const
│ │ │ +
151 {
│ │ │ +
152 return registry_.count(key);
│ │ │ +
153 }
│ │ │ +
│ │ │ +
154
│ │ │ +
155 private:
│ │ │ +
156
│ │ │ +
157 template<class T>
│ │ │ +
158 struct Tag{};
│ │ │ +
159
│ │ │ +
160 template<class Impl>
│ │ │ +
161 struct DefaultCreator
│ │ │ +
162 {
│ │ │ +
163 template<class... T>
│ │ │ +
164 Type operator()(T&&... args) const
│ │ │ +
165 {
│ │ │ +
166 return DefaultCreator::create(Tag<Type>(), PriorityTag<42>(), std::forward<T>(args)...);
│ │ │ +
167 }
│ │ │ +
168
│ │ │ +
169 template<class Target, class... T>
│ │ │ +
170 static Type create(Tag<Target>, PriorityTag<1>, T&& ... args) {
│ │ │ +
171 return Impl(std::forward<T>(args)...);
│ │ │ +
172 }
│ │ │ +
173
│ │ │ +
174 template<class Target, class... T>
│ │ │ +
175 static Type create(Tag<std::unique_ptr<Target>>, PriorityTag<2>, T&& ... args) {
│ │ │ +
176 return std::make_unique<Impl>(std::forward<T>(args)...);
│ │ │ +
177 }
│ │ │ +
178
│ │ │ +
179 template<class Target, class... T>
│ │ │ +
180 static Type create(Tag<std::shared_ptr<Target>>, PriorityTag<3>, T&& ... args) {
│ │ │ +
181 return std::make_shared<Impl>(std::forward<T>(args)...);
│ │ │ +
182 }
│ │ │ +
183
│ │ │ +
184 };
│ │ │ +
185
│ │ │ +
186 typedef std::map<Key, Creator> Registry;
│ │ │ +
187 Registry registry_;
│ │ │ +
188};
│ │ │ +
│ │ │ +
189
│ │ │ +
190
│ │ │ +
191
│ │ │ +
192} // end namespace Dune
│ │ │ +
193
│ │ │ +
194#endif // DUNE_COMMON_PARAMETERIZEDOBJECT_HH
│ │ │ +
Utilities for type computations, constraining overloads, ...
│ │ │ +
A few common exception classes.
│ │ │ +
#define DUNE_THROW(E,...)
Definition exceptions.hh:314
│ │ │ +
Dune namespace
Definition alignedallocator.hh:13
│ │ │ +
Default exception if a function was called while the object is not in a valid state for that function...
Definition exceptions.hh:375
│ │ │ +
A factory class for parameterized objects.
Definition parameterizedobject.hh:36
│ │ │ +
std::function< Type(Args...)> Creator
Definition parameterizedobject.hh:53
│ │ │ +
static constexpr auto has_proper_signature(Dune::PriorityTag< 1 >) -> decltype(std::declval< F >()(std::declval< Args >()...), std::true_type())
Definition parameterizedobject.hh:56
│ │ │ +
TypeT Type
The type of objects created by the factory.
Definition parameterizedobject.hh:49
│ │ │ +
void define(Key const &key, Impl &&t)
Registers a new type with a key.
Definition parameterizedobject.hh:145
│ │ │ +
KeyT Key
The typ of the keys.
Definition parameterizedobject.hh:46
│ │ │ +
Type create(Key const &key, Args ... args) const
Creates an object identified by a key from given parameters.
Definition parameterizedobject.hh:77
│ │ │ +
void define(Key const &key)
Registers a new type with a key.
Definition parameterizedobject.hh:101
│ │ │ +
void define(Key const &key, F &&f)
Registers a new creator with a key.
Definition parameterizedobject.hh:121
│ │ │ +
static constexpr std::false_type has_proper_signature(Dune::PriorityTag< 0 >)
Definition parameterizedobject.hh:63
│ │ │ +
bool contains(Key const &key) const
Definition parameterizedobject.hh:150
│ │ │ + │ │ │ +
Helper class for tagging priorities.
Definition typeutilities.hh:73
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,21 +1,201 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -unused.hh │ │ │ │ +parameterizedobject.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ -2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ +1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- │ │ │ │ +2// vi: set et ts=4 sw=4 sts=4: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ 4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ -5#ifndef DUNE_COMMON_UNUSED_HH │ │ │ │ -6#define DUNE_COMMON_UNUSED_HH │ │ │ │ +5#ifndef DUNE_COMMON_PARAMETERIZEDOBJECT_HH │ │ │ │ +6#define DUNE_COMMON_PARAMETERIZEDOBJECT_HH │ │ │ │ 7 │ │ │ │ +8#include │ │ │ │ +9#include │ │ │ │ +10#include │ │ │ │ 11 │ │ │ │ -_2_1#define DUNE_UNUSED_PARAMETER(param) static_cast(param) │ │ │ │ -22#endif │ │ │ │ +12#include <_d_u_n_e_/_c_o_m_m_o_n_/_e_x_c_e_p_t_i_o_n_s_._h_h> │ │ │ │ +13#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ +14 │ │ │ │ +15namespace _D_u_n_e { │ │ │ │ +16 │ │ │ │ +34template │ │ │ │ +_3_6class _P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y; │ │ │ │ +37 │ │ │ │ +38template │ │ │ │ +_4_1class _P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y │ │ │ │ +42{ │ │ │ │ +43 public: │ │ │ │ +44 │ │ │ │ +_4_6 typedef KeyT _K_e_y; │ │ │ │ +47 │ │ │ │ +_4_9 using _T_y_p_e = TypeT; │ │ │ │ +50 │ │ │ │ +51 protected: │ │ │ │ +52 │ │ │ │ +_5_3 using _C_r_e_a_t_o_r = std::function<_T_y_p_e(Args...)>; │ │ │ │ +54 │ │ │ │ +55 template │ │ │ │ +_5_6 static constexpr auto _h_a_s___p_r_o_p_e_r___s_i_g_n_a_t_u_r_e(_D_u_n_e_:_:_P_r_i_o_r_i_t_y_T_a_g_<_1_>) │ │ │ │ +57 -> decltype( std::declval()(std::declval()...), std::true_type()) │ │ │ │ +58 { │ │ │ │ +59 return {}; │ │ │ │ +60 } │ │ │ │ +61 │ │ │ │ +62 template │ │ │ │ +_6_3 static constexpr std::false_type _h_a_s___p_r_o_p_e_r___s_i_g_n_a_t_u_r_e(_D_u_n_e_:_:_P_r_i_o_r_i_t_y_T_a_g_<_0_>) │ │ │ │ +64 { │ │ │ │ +65 return {}; │ │ │ │ +66 } │ │ │ │ +67 │ │ │ │ +68 public: │ │ │ │ +69 │ │ │ │ +_7_7 _T_y_p_e _c_r_e_a_t_e(_K_e_y const& key, Args ... args) const { │ │ │ │ +78 typename Registry::const_iterator i = registry_.find(key); │ │ │ │ +79 if (i == registry_.end()) { │ │ │ │ +80 _D_U_N_E___T_H_R_O_W(_D_u_n_e_:_:_I_n_v_a_l_i_d_S_t_a_t_e_E_x_c_e_p_t_i_o_n, │ │ │ │ +81 "ParametrizedObjectFactory: key ``" << │ │ │ │ +82 key << "'' not registered"); │ │ │ │ +83 } │ │ │ │ +84 else return i->second(args...); │ │ │ │ +85 } │ │ │ │ +86 │ │ │ │ +100 template │ │ │ │ +_1_0_1 void _d_e_f_i_n_e(_K_e_y const& key) │ │ │ │ +102 { │ │ │ │ +103 registry_[key] = DefaultCreator(); │ │ │ │ +104 } │ │ │ │ +105 │ │ │ │ +119 template(_P_r_i_o_r_i_t_y_T_a_g_<_4_2_>()), int>_:_: │ │ │ │ +_t_y_p_e = 0> │ │ │ │ +_1_2_1 void _d_e_f_i_n_e(_K_e_y const& key, F&& f) │ │ │ │ +122 { │ │ │ │ +123 registry_[key] = f; │ │ │ │ +124 } │ │ │ │ +125 │ │ │ │ +140 template::value │ │ │ │ +143 and not std::is_convertible::value, │ │ │ │ +144 int>_:_:_t_y_p_e = 0> │ │ │ │ +_1_4_5 void _d_e_f_i_n_e(_K_e_y const& key, Impl&& t) │ │ │ │ +146 { │ │ │ │ +147 registry_[key] = [=](Args...) { return t;}; │ │ │ │ +148 } │ │ │ │ +149 │ │ │ │ +_1_5_0 bool _c_o_n_t_a_i_n_s(_K_e_y const& key) const │ │ │ │ +151 { │ │ │ │ +152 return registry_.count(key); │ │ │ │ +153 } │ │ │ │ +154 │ │ │ │ +155 private: │ │ │ │ +156 │ │ │ │ +157 template │ │ │ │ +158 struct Tag{}; │ │ │ │ +159 │ │ │ │ +160 template │ │ │ │ +161 struct DefaultCreator │ │ │ │ +162 { │ │ │ │ +163 template │ │ │ │ +164 Type operator()(T&&... args) const │ │ │ │ +165 { │ │ │ │ +166 return DefaultCreator::create(Tag(), PriorityTag<42>(), std:: │ │ │ │ +forward(args)...); │ │ │ │ +167 } │ │ │ │ +168 │ │ │ │ +169 template │ │ │ │ +170 static Type create(Tag, PriorityTag<1>, T&& ... args) { │ │ │ │ +171 return Impl(std::forward(args)...); │ │ │ │ +172 } │ │ │ │ +173 │ │ │ │ +174 template │ │ │ │ +175 static Type create(Tag>, PriorityTag<2>, T&& ... │ │ │ │ +args) { │ │ │ │ +176 return std::make_unique(std::forward(args)...); │ │ │ │ +177 } │ │ │ │ +178 │ │ │ │ +179 template │ │ │ │ +180 static Type create(Tag>, PriorityTag<3>, T&& ... │ │ │ │ +args) { │ │ │ │ +181 return std::make_shared(std::forward(args)...); │ │ │ │ +182 } │ │ │ │ +183 │ │ │ │ +184 }; │ │ │ │ +185 │ │ │ │ +186 typedef std::map Registry; │ │ │ │ +187 Registry registry_; │ │ │ │ +188}; │ │ │ │ +189 │ │ │ │ +190 │ │ │ │ +191 │ │ │ │ +192} // end namespace Dune │ │ │ │ +193 │ │ │ │ +194#endif // DUNE_COMMON_PARAMETERIZEDOBJECT_HH │ │ │ │ +_t_y_p_e_u_t_i_l_i_t_i_e_s_._h_h │ │ │ │ +Utilities for type computations, constraining overloads, ... │ │ │ │ +_e_x_c_e_p_t_i_o_n_s_._h_h │ │ │ │ +A few common exception classes. │ │ │ │ +_D_U_N_E___T_H_R_O_W │ │ │ │ +#define DUNE_THROW(E,...) │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:314 │ │ │ │ +_D_u_n_e │ │ │ │ +Dune namespace │ │ │ │ +DDeeffiinniittiioonn alignedallocator.hh:13 │ │ │ │ +_D_u_n_e_:_:_I_n_v_a_l_i_d_S_t_a_t_e_E_x_c_e_p_t_i_o_n │ │ │ │ +Default exception if a function was called while the object is not in a valid │ │ │ │ +state for that function... │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:375 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y │ │ │ │ +A factory class for parameterized objects. │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:36 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_C_r_e_a_t_o_r │ │ │ │ +std::function< Type(Args...)> Creator │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:53 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_h_a_s___p_r_o_p_e_r___s_i_g_n_a_t_u_r_e │ │ │ │ +static constexpr auto has_proper_signature(Dune::PriorityTag< 1 >) -> decltype │ │ │ │ +(std::declval< F >()(std::declval< Args >()...), std::true_type()) │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:56 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_T_y_p_e │ │ │ │ +TypeT Type │ │ │ │ +The type of objects created by the factory. │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:49 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_d_e_f_i_n_e │ │ │ │ +void define(Key const &key, Impl &&t) │ │ │ │ +Registers a new type with a key. │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:145 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_K_e_y │ │ │ │ +KeyT Key │ │ │ │ +The typ of the keys. │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:46 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_c_r_e_a_t_e │ │ │ │ +Type create(Key const &key, Args ... args) const │ │ │ │ +Creates an object identified by a key from given parameters. │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:77 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_d_e_f_i_n_e │ │ │ │ +void define(Key const &key) │ │ │ │ +Registers a new type with a key. │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:101 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_d_e_f_i_n_e │ │ │ │ +void define(Key const &key, F &&f) │ │ │ │ +Registers a new creator with a key. │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:121 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_h_a_s___p_r_o_p_e_r___s_i_g_n_a_t_u_r_e │ │ │ │ +static constexpr std::false_type has_proper_signature(Dune::PriorityTag< 0 >) │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:63 │ │ │ │ +_D_u_n_e_:_:_P_a_r_a_m_e_t_e_r_i_z_e_d_O_b_j_e_c_t_F_a_c_t_o_r_y_<_ _T_y_p_e_T_(_A_r_g_s_._._._)_,_ _K_e_y_T_ _>_:_:_c_o_n_t_a_i_n_s │ │ │ │ +bool contains(Key const &key) const │ │ │ │ +DDeeffiinniittiioonn parameterizedobject.hh:150 │ │ │ │ +_D_u_n_e_:_:_t_y_p_e │ │ │ │ +_D_u_n_e_:_:_P_r_i_o_r_i_t_y_T_a_g │ │ │ │ +Helper class for tagging priorities. │ │ │ │ +DDeeffiinniittiioonn typeutilities.hh:73 │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00020.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: typeutilities.hh File Reference │ │ │ +dune-common: bigunsignedint.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -74,48 +74,81 @@ │ │ │
│ │ │ │ │ │
│ │ │
│ │ │
│ │ │ Classes | │ │ │ Namespaces | │ │ │ -Typedefs
│ │ │ -
typeutilities.hh File Reference
│ │ │ +Macros | │ │ │ +Functions
│ │ │ +
bigunsignedint.hh File Reference
│ │ │
│ │ │
│ │ │ │ │ │ -

Utilities for type computations, constraining overloads, ... │ │ │ +

Portable very large unsigned integers. │ │ │ More...

│ │ │ -
#include <cstddef>
│ │ │ +
#include <algorithm>
│ │ │ +#include <bit>
│ │ │ +#include <iostream>
│ │ │ +#include <limits>
│ │ │ +#include <cstdint>
│ │ │ +#include <cstdlib>
│ │ │ #include <type_traits>
│ │ │ -#include <tuple>
│ │ │ +#include <dune/common/exceptions.hh>
│ │ │ +#include <dune/common/hash.hh>
│ │ │
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ Classes

struct  Dune::PriorityTag< priority >
 Helper class for tagging priorities. More...
struct  Dune::PriorityTag< 0 >
 Helper class for tagging priorities. More...
class  Dune::bigunsignedint< k >
 Portable very large unsigned integers. More...
struct  Dune::IsNumber< bigunsignedint< k > >
 Declare big unsigned int is a number. More...
struct  std::numeric_limits< Dune::bigunsignedint< k > >
│ │ │ │ │ │ │ │ │ │ │ │ + │ │ │ + │ │ │

│ │ │ Namespaces

namespace  Dune
 Dune namespace
namespace  std
 STL namespace.
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ +

│ │ │ -Typedefs

template<class This, class... T>
using Dune::disableCopyMove = std::enable_if_t< not Impl::disableCopyMoveHelper<This, T...>::value, int>
 Helper to disable constructor as copy and move constructor.

│ │ │ +Macros

#define DUNE_BINOP(OP)
│ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ +Functions

template<int k>
std::ostream & Dune::operator<< (std::ostream &s, const bigunsignedint< k > &x)
template<int k>
bigunsignedint< k > Dune::operator+ (const bigunsignedint< k > &x, std::uintmax_t y)
template<int k>
bigunsignedint< k > Dune::operator- (const bigunsignedint< k > &x, std::uintmax_t y)
template<int k>
bigunsignedint< k > Dune::operator* (const bigunsignedint< k > &x, std::uintmax_t y)
template<int k>
bigunsignedint< k > Dune::operator/ (const bigunsignedint< k > &x, std::uintmax_t y)
template<int k>
bigunsignedint< k > Dune::operator% (const bigunsignedint< k > &x, std::uintmax_t y)
template<int k>
bigunsignedint< k > Dune::operator+ (std::uintmax_t x, const bigunsignedint< k > &y)
template<int k>
bigunsignedint< k > Dune::operator- (std::uintmax_t x, const bigunsignedint< k > &y)
template<int k>
bigunsignedint< k > Dune::operator* (std::uintmax_t x, const bigunsignedint< k > &y)
template<int k>
bigunsignedint< k > Dune::operator/ (std::uintmax_t x, const bigunsignedint< k > &y)
template<int k>
bigunsignedint< k > Dune::operator% (std::uintmax_t x, const bigunsignedint< k > &y)
│ │ │

Detailed Description

│ │ │ -

Utilities for type computations, constraining overloads, ...

│ │ │ -
Author
Carsten Gräser
│ │ │ +

Portable very large unsigned integers.

│ │ │ +
Author
Peter Bastian
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── encoding │ │ │ │ @@ -1 +1 @@ │ │ │ │ -utf-8 │ │ │ │ +us-ascii │ │ │ ├── html2text {} │ │ │ │ @@ -1,32 +1,72 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s │ │ │ │ -typeutilities.hh File Reference │ │ │ │ -Utilities for type computations, constraining overloads, ... _M_o_r_e_._._. │ │ │ │ -#include │ │ │ │ +_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _M_a_c_r_o_s | _F_u_n_c_t_i_o_n_s │ │ │ │ +bigunsignedint.hh File Reference │ │ │ │ +Portable very large unsigned integers. _M_o_r_e_._._. │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ #include │ │ │ │ -#include │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_e_x_c_e_p_t_i_o_n_s_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_a_s_h_._h_h> │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ CCllaasssseess │ │ │ │ -struct   _D_u_n_e_:_:_P_r_i_o_r_i_t_y_T_a_g_<_ _p_r_i_o_r_i_t_y_ _> │ │ │ │ -  Helper class for tagging priorities. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_P_r_i_o_r_i_t_y_T_a_g_<_ _0_ _> │ │ │ │ -  Helper class for tagging priorities. _M_o_r_e_._._. │ │ │ │ + class   _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _> │ │ │ │ +  Portable very large unsigned integers. _M_o_r_e_._._. │ │ │ │ +struct   _D_u_n_e_:_:_I_s_N_u_m_b_e_r_<_ _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _> │ │ │ │ +  Declare big unsigned int is a number. _M_o_r_e_._._. │ │ │ │ +struct   _s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _> │ │ │ │ NNaammeessppaacceess │ │ │ │ namespace   _D_u_n_e │ │ │ │   Dune namespace │ │ │ │ -TTyyppeeddeeffss │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_d_i_s_a_b_l_e_C_o_p_y_M_o_v_e = std::enable_if_t< not Impl:: │ │ │ │ - disableCopyMoveHelper::value, int> │ │ │ │ -  Helper to disable constructor as copy and move constructor. │ │ │ │ +namespace   _s_t_d │ │ │ │ +  STL namespace. │ │ │ │ +MMaaccrrooss │ │ │ │ +#define  _D_U_N_E___B_I_N_O_P(OP) │ │ │ │ +FFuunnccttiioonnss │ │ │ │ +template │ │ │ │ + std::ostream &  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_<_< (std::ostream &s, const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k │ │ │ │ + > &x) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_+ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k > &x, std:: │ │ │ │ + uintmax_t y) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_- (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k > &x, std:: │ │ │ │ + uintmax_t y) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_* (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k > &x, std:: │ │ │ │ + uintmax_t y) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_/ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k > &x, std:: │ │ │ │ + uintmax_t y) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_% (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k > &x, std:: │ │ │ │ + uintmax_t y) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_+ (std::uintmax_t x, const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k │ │ │ │ + > &y) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_- (std::uintmax_t x, const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k │ │ │ │ + > &y) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_* (std::uintmax_t x, const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k │ │ │ │ + > &y) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_/ (std::uintmax_t x, const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k │ │ │ │ + > &y) │ │ │ │ +template │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t< k >  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_% (std::uintmax_t x, const _b_i_g_u_n_s_i_g_n_e_d_i_n_t< k │ │ │ │ + > &y) │ │ │ │ ********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ -Utilities for type computations, constraining overloads, ... │ │ │ │ +Portable very large unsigned integers. │ │ │ │ Author │ │ │ │ - Carsten Gräser │ │ │ │ + Peter Bastian │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00020_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: typeutilities.hh Source File │ │ │ +dune-common: bigunsignedint.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -71,80 +71,869 @@ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ -
typeutilities.hh
│ │ │ +
bigunsignedint.hh
│ │ │
│ │ │
│ │ │ Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │
2// vi: set et ts=4 sw=2 sts=2:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ -
5#ifndef DUNE_COMMON_TYPEUTILITIES_HH
│ │ │ -
6#define DUNE_COMMON_TYPEUTILITIES_HH
│ │ │ -
7
│ │ │ -
8#include <cstddef>
│ │ │ -
9#include <type_traits>
│ │ │ -
10#include <tuple>
│ │ │ -
11
│ │ │ -
12
│ │ │ -
13namespace Dune {
│ │ │ -
14
│ │ │ -
20
│ │ │ -
21
│ │ │ -
22 namespace Impl
│ │ │ -
23 {
│ │ │ +
5
│ │ │ +
6#ifndef DUNE_BIGUNSIGNEDINT_HH
│ │ │ +
7#define DUNE_BIGUNSIGNEDINT_HH
│ │ │ +
8
│ │ │ +
9#include <algorithm>
│ │ │ +
10#include <bit>
│ │ │ +
11#include <iostream>
│ │ │ +
12#include <limits>
│ │ │ +
13#include <cstdint>
│ │ │ +
14#include <cstdlib>
│ │ │ +
15#include <type_traits>
│ │ │ + │ │ │ +
17#include <dune/common/hash.hh>
│ │ │ +
18
│ │ │
24
│ │ │ -
25 template<class This, class... T>
│ │ │ -
26 struct disableCopyMoveHelper : public std::is_base_of<This, std::tuple_element_t<0, std::tuple<std::decay_t<T>...>>>
│ │ │ -
27 {};
│ │ │ -
28
│ │ │ -
29 template<class This>
│ │ │ -
30 struct disableCopyMoveHelper<This> : public std::false_type
│ │ │ -
31 {};
│ │ │ -
32
│ │ │ -
33 } // namespace Impl
│ │ │ -
34
│ │ │ -
35
│ │ │ -
44 template<class This, class... T>
│ │ │ -
45 using disableCopyMove = std::enable_if_t< not Impl::disableCopyMoveHelper<This, T...>::value, int>;
│ │ │ -
46
│ │ │ -
47
│ │ │ -
48
│ │ │ -
71 template<std::size_t priority>
│ │ │ -
│ │ │ -
72 struct PriorityTag : public PriorityTag<priority-1>
│ │ │ -
73 {
│ │ │ -
74 static constexpr std::size_t value = priority;
│ │ │ -
75 };
│ │ │ -
│ │ │ -
76
│ │ │ -
85 template<>
│ │ │ -
│ │ │ -
86 struct PriorityTag<0>
│ │ │ -
87 {
│ │ │ -
88 static constexpr std::size_t value = 0;
│ │ │ -
89 };
│ │ │ -
│ │ │ -
90
│ │ │ -
91
│ │ │ -
92
│ │ │ -
93} // namespace Dune
│ │ │ -
94
│ │ │ -
95
│ │ │ -
96
│ │ │ -
97#endif // DUNE_COMMON_TYPEUTILITIES_HH
│ │ │ -
std::enable_if_t< not Impl::disableCopyMoveHelper< This, T... >::value, int > disableCopyMove
Helper to disable constructor as copy and move constructor.
Definition typeutilities.hh:45
│ │ │ +
25namespace Dune
│ │ │ +
26{
│ │ │ +
27#if HAVE_MPI
│ │ │ +
28 template<class K>
│ │ │ +
29 struct MPITraits;
│ │ │ +
30#endif
│ │ │ +
31
│ │ │ +
36
│ │ │ +
37 namespace Impl {
│ │ │ +
38
│ │ │ +
39 // numeric_limits_helper provides std::numeric_limits access to the internals
│ │ │ +
40 // of bigunsignedint. Previously, the correct specialization of std::numeric_limits
│ │ │ +
41 // was a friend of bigunsignedint, but that creates problems on recent versions
│ │ │ +
42 // of clang with the alternative libc++ library, because that library declares the
│ │ │ +
43 // base template of std::numeric_limits as a class and clang subsequently complains
│ │ │ +
44 // if the friend declaration uses 'struct'. Unfortunately, libstdc++ uses a struct,
│ │ │ +
45 // making it impossible to keep clang happy for both standard libraries.
│ │ │ +
46 // So we move the access helper functionality into a custom struct and simply let
│ │ │ +
47 // the numeric_limits specialization inherit from the helper.
│ │ │ +
48
│ │ │ +
49 template<typename T>
│ │ │ +
50 struct numeric_limits_helper
│ │ │ +
51 {
│ │ │ +
52
│ │ │ +
53 protected:
│ │ │ +
54
│ │ │ +
55 static std::uint16_t& digit(T& big_unsigned_int, std::size_t i)
│ │ │ +
56 {
│ │ │ +
57 return big_unsigned_int.digit[i];
│ │ │ +
58 }
│ │ │ +
59
│ │ │ +
60 };
│ │ │ +
61
│ │ │ +
62 }
│ │ │ +
63
│ │ │ +
72
│ │ │ +
73 template<int k>
│ │ │ +
│ │ │ + │ │ │ +
75 public:
│ │ │ +
76
│ │ │ +
77 // unsigned short is 16 bits wide, n is the number of digits needed
│ │ │ +
78 constexpr static int bits = std::numeric_limits<std::uint16_t>::digits;
│ │ │ +
79 constexpr static int n = k/bits+(k%bits!=0);
│ │ │ +
80 constexpr static int hexdigits = 4;
│ │ │ +
81 constexpr static int bitmask = 0xFFFF;
│ │ │ +
82 constexpr static int compbitmask = 0xFFFF0000;
│ │ │ +
83 constexpr static int overflowmask = 0x1;
│ │ │ +
84
│ │ │ + │ │ │ +
87
│ │ │ +
89 template<typename Signed>
│ │ │ +
90 bigunsignedint (Signed x, typename std::enable_if<std::is_integral<Signed>::value && std::is_signed<Signed>::value>::type* = 0);
│ │ │ +
91
│ │ │ +
93 bigunsignedint (std::uintmax_t x);
│ │ │ +
94
│ │ │ +
96 void print (std::ostream& s) const ;
│ │ │ +
97
│ │ │ + │ │ │ + │ │ │ +
101
│ │ │ + │ │ │ + │ │ │ +
105
│ │ │ + │ │ │ + │ │ │ +
109
│ │ │ + │ │ │ +
112
│ │ │ + │ │ │ + │ │ │ +
118
│ │ │ + │ │ │ + │ │ │ +
124
│ │ │ + │ │ │ + │ │ │ +
128
│ │ │ + │ │ │ + │ │ │ +
132
│ │ │ + │ │ │ + │ │ │ +
136
│ │ │ + │ │ │ +
139
│ │ │ +
140
│ │ │ +
142 bigunsignedint<k> operator<< (int i) const;
│ │ │ +
143
│ │ │ +
145 bigunsignedint<k> operator>> (int i) const;
│ │ │ +
146
│ │ │ +
147
│ │ │ +
149 bool operator< (const bigunsignedint<k>& x) const;
│ │ │ +
150
│ │ │ +
152 bool operator<= (const bigunsignedint<k>& x) const;
│ │ │ +
153
│ │ │ +
155 bool operator> (const bigunsignedint<k>& x) const;
│ │ │ +
156
│ │ │ +
158 bool operator>= (const bigunsignedint<k>& x) const;
│ │ │ +
159
│ │ │ +
161 bool operator== (const bigunsignedint<k>& x) const;
│ │ │ +
162
│ │ │ +
164 bool operator!= (const bigunsignedint<k>& x) const;
│ │ │ +
165
│ │ │ +
166
│ │ │ +
168 // operator unsigned int () const;
│ │ │ +
169 std::uint_least32_t touint() const;
│ │ │ +
175 double todouble() const;
│ │ │ +
176
│ │ │ +
177 friend class bigunsignedint<k/2>;
│ │ │ +
178 friend struct Impl::numeric_limits_helper< bigunsignedint<k> >;
│ │ │ +
179
│ │ │ +
│ │ │ +
184 friend int bit_width(const bigunsignedint& arg)
│ │ │ +
185 {
│ │ │ +
186 int width = bits * std::size(arg.digit);
│ │ │ +
187 auto it = std::rbegin(arg.digit);
│ │ │ +
188 do {
│ │ │ +
189 width -= (bits - std::bit_width(*it));
│ │ │ +
190 } while ((*it == 0) and ((++it) != std::rend(arg.digit)));
│ │ │ +
191 return width;
│ │ │ +
192 }
│ │ │ +
│ │ │ +
193
│ │ │ +
│ │ │ +
198 friend int countl_zero(const bigunsignedint& arg)
│ │ │ +
199 {
│ │ │ +
200 return bits*n - bit_width(arg);
│ │ │ +
201 }
│ │ │ +
│ │ │ +
202
│ │ │ +
│ │ │ +
203 inline friend std::size_t hash_value(const bigunsignedint& arg)
│ │ │ +
204 {
│ │ │ +
205 return hash_range(arg.digit,arg.digit + arg.n);
│ │ │ +
206 }
│ │ │ +
│ │ │ +
207
│ │ │ +
208 private:
│ │ │ +
209 std::uint16_t digit[n];
│ │ │ +
210#if HAVE_MPI
│ │ │ +
211 friend struct MPITraits<bigunsignedint<k> >;
│ │ │ +
212#endif
│ │ │ +
213 inline void assign(std::uintmax_t x);
│ │ │ +
214
│ │ │ +
215
│ │ │ +
216 } ;
│ │ │ +
│ │ │ +
217
│ │ │ +
218 // Constructors
│ │ │ +
219 template<int k>
│ │ │ +
│ │ │ + │ │ │ +
221 {
│ │ │ +
222 assign(0u);
│ │ │ +
223 }
│ │ │ +
│ │ │ +
224
│ │ │ +
225 template<int k>
│ │ │ +
226 template<typename Signed>
│ │ │ +
│ │ │ +
227 bigunsignedint<k>::bigunsignedint (Signed y, typename std::enable_if<std::is_integral<Signed>::value && std::is_signed<Signed>::value>::type*)
│ │ │ +
228 {
│ │ │ +
229 if (y < 0)
│ │ │ +
230 DUNE_THROW(Dune::Exception, "Trying to construct a Dune::bigunsignedint from a negative integer: " << y);
│ │ │ +
231 assign(y);
│ │ │ +
232 }
│ │ │ +
│ │ │ +
233
│ │ │ +
234 template<int k>
│ │ │ +
│ │ │ + │ │ │ +
236 {
│ │ │ +
237 assign(x);
│ │ │ +
238 }
│ │ │ +
│ │ │ +
239 template<int k>
│ │ │ +
240 void bigunsignedint<k>::assign(std::uintmax_t x)
│ │ │ +
241 {
│ │ │ +
242 static const int no=std::min<int>(n, std::numeric_limits<std::uintmax_t>::digits/bits);
│ │ │ +
243
│ │ │ +
244 for(int i=0; i<no; ++i) {
│ │ │ +
245 digit[i] = (x&bitmask);
│ │ │ +
246 x=x>>bits;
│ │ │ +
247 }
│ │ │ +
248 for (unsigned int i=no; i<n; i++) digit[i]=0;
│ │ │ +
249 }
│ │ │ +
250
│ │ │ +
251 // export
│ │ │ +
252 template<int k>
│ │ │ +
│ │ │ +
253 inline std::uint_least32_t bigunsignedint<k>::touint () const
│ │ │ +
254 {
│ │ │ +
255 return (digit[1]<<bits)+digit[0];
│ │ │ +
256 }
│ │ │ +
│ │ │ +
257
│ │ │ +
258 template<int k>
│ │ │ +
│ │ │ +
259 inline double bigunsignedint<k>::todouble() const
│ │ │ +
260 {
│ │ │ +
261 int firstInZeroRange=n;
│ │ │ +
262 for(int i=n-1; i>=0; --i)
│ │ │ +
263 if(digit[i]!=0)
│ │ │ +
264 break;
│ │ │ +
265 else
│ │ │ +
266 --firstInZeroRange;
│ │ │ +
267 int representableDigits=std::numeric_limits<double>::digits/bits;
│ │ │ +
268 int lastInRepresentableRange=0;
│ │ │ +
269 if(representableDigits<firstInZeroRange)
│ │ │ +
270 lastInRepresentableRange=firstInZeroRange-representableDigits;
│ │ │ +
271 double val=0;
│ │ │ +
272 for(int i=firstInZeroRange-1; i>=lastInRepresentableRange; --i)
│ │ │ +
273 val =val*(1<<bits)+digit[i];
│ │ │ +
274 return val*(1<<(bits*lastInRepresentableRange));
│ │ │ +
275 }
│ │ │ +
│ │ │ +
276 // print
│ │ │ +
277 template<int k>
│ │ │ +
│ │ │ +
278 inline void bigunsignedint<k>::print (std::ostream& s) const
│ │ │ +
279 {
│ │ │ +
280 bool leading=false;
│ │ │ +
281
│ │ │ +
282 // print from left to right
│ │ │ +
283 for (int i=n-1; i>=0; i--)
│ │ │ +
284 for (int d=hexdigits-1; d>=0; d--)
│ │ │ +
285 {
│ │ │ +
286 // extract one hex digit
│ │ │ +
287 int current = (digit[i]>>(d*4))&0xF;
│ │ │ +
288 if (current!=0)
│ │ │ +
289 {
│ │ │ +
290 // s.setf(std::ios::noshowbase);
│ │ │ +
291 s << std::hex << current;
│ │ │ +
292 leading = false;
│ │ │ +
293 }
│ │ │ +
294 else if (!leading) s << std::hex << current;
│ │ │ +
295 }
│ │ │ +
296 if (leading) s << "0";
│ │ │ +
297 s << std::dec;
│ │ │ +
298 }
│ │ │ +
│ │ │ +
299
│ │ │ +
300 template <int k>
│ │ │ +
│ │ │ +
301 inline std::ostream& operator<< (std::ostream& s, const bigunsignedint<k>& x)
│ │ │ +
302 {
│ │ │ +
303 x.print(s);
│ │ │ +
304 return s;
│ │ │ +
305 }
│ │ │ +
│ │ │ +
306
│ │ │ +
│ │ │ +
307 #define DUNE_BINOP(OP) \
│ │ │ +
308 template <int k> \
│ │ │ +
309 inline bigunsignedint<k> bigunsignedint<k>::operator OP (const bigunsignedint<k> &x) const \
│ │ │ +
310 { \
│ │ │ +
311 auto temp = *this; \
│ │ │ +
312 temp OP##= x; \
│ │ │ +
313 return temp; \
│ │ │ +
314 }
│ │ │ +
│ │ │ +
315
│ │ │ +
316 DUNE_BINOP(+)
│ │ │ +
317 DUNE_BINOP(-)
│ │ │ +
318 DUNE_BINOP(*)
│ │ │ +
319 DUNE_BINOP(/)
│ │ │ +
320 DUNE_BINOP(%)
│ │ │ +
321 DUNE_BINOP(&)
│ │ │ +
322 DUNE_BINOP(^)
│ │ │ +
323 DUNE_BINOP(|)
│ │ │ +
324
│ │ │ +
325 #undef DUNE_BINOP
│ │ │ +
326
│ │ │ +
327 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
329 {
│ │ │ +
330 std::uint_fast32_t overflow=0;
│ │ │ +
331
│ │ │ +
332 for (unsigned int i=0; i<n; i++)
│ │ │ +
333 {
│ │ │ +
334 std::uint_fast32_t sum = static_cast<std::uint_fast32_t>(digit[i]) + static_cast<std::uint_fast32_t>(x.digit[i]) + overflow;
│ │ │ +
335 digit[i] = sum&bitmask;
│ │ │ +
336 overflow = (sum>>bits)&overflowmask;
│ │ │ +
337 }
│ │ │ +
338 return *this;
│ │ │ +
339 }
│ │ │ +
│ │ │ +
340
│ │ │ +
341 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
343 {
│ │ │ +
344 std::int_fast32_t overflow=0;
│ │ │ +
345
│ │ │ +
346 for (unsigned int i=0; i<n; i++)
│ │ │ +
347 {
│ │ │ +
348 std::int_fast32_t diff = static_cast<std::int_fast32_t>(digit[i]) - static_cast<std::int_fast32_t>(x.digit[i]) - overflow;
│ │ │ +
349 if (diff>=0)
│ │ │ +
350 {
│ │ │ +
351 digit[i] = static_cast<std::uint16_t>(diff);
│ │ │ +
352 overflow = 0;
│ │ │ +
353 }
│ │ │ +
354 else
│ │ │ +
355 {
│ │ │ +
356 digit[i] = static_cast<std::uint16_t>(diff+bitmask+1);
│ │ │ +
357 overflow = 1;
│ │ │ +
358 }
│ │ │ +
359 }
│ │ │ +
360 return *this;
│ │ │ +
361 }
│ │ │ +
│ │ │ +
362
│ │ │ +
363 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
365 {
│ │ │ +
366 bigunsignedint<2*k> finalproduct(0);
│ │ │ +
367
│ │ │ +
368 for (unsigned int m=0; m<n; m++) // digit in right factor
│ │ │ +
369 {
│ │ │ +
370 bigunsignedint<2*k> singleproduct(0);
│ │ │ +
371 std::uint_fast32_t overflow(0);
│ │ │ +
372 for (unsigned int i=0; i<n; i++)
│ │ │ +
373 {
│ │ │ +
374 std::uint_fast32_t digitproduct = static_cast<std::uint_fast32_t>(digit[i])*static_cast<std::uint_fast32_t>(x.digit[m])+overflow;
│ │ │ +
375 singleproduct.digit[i+m] = static_cast<std::uint16_t>(digitproduct&bitmask);
│ │ │ +
376 overflow = (digitproduct>>bits)&bitmask;
│ │ │ +
377 }
│ │ │ +
378 finalproduct = finalproduct+singleproduct;
│ │ │ +
379 }
│ │ │ +
380
│ │ │ +
381 for (unsigned int i=0; i<n; i++) digit[i] = finalproduct.digit[i];
│ │ │ +
382 return *this;
│ │ │ +
383 }
│ │ │ +
│ │ │ +
384
│ │ │ +
385 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
387 {
│ │ │ +
388 std::uint_fast32_t overflow=1;
│ │ │ +
389
│ │ │ +
390 for (unsigned int i=0; i<n; i++)
│ │ │ +
391 {
│ │ │ +
392 std::uint_fast32_t sum = static_cast<std::uint_fast32_t>(digit[i]) + overflow;
│ │ │ +
393 digit[i] = sum&bitmask;
│ │ │ +
394 overflow = (sum>>bits)&overflowmask;
│ │ │ +
395 }
│ │ │ +
396 return *this;
│ │ │ +
397 }
│ │ │ +
│ │ │ +
398
│ │ │ +
399 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
401 {
│ │ │ +
402 if(x==0)
│ │ │ +
403 DUNE_THROW(Dune::MathError, "division by zero!");
│ │ │ +
404
│ │ │ +
405 // better slow than nothing
│ │ │ +
406 bigunsignedint<k> result(0);
│ │ │ +
407
│ │ │ +
408 while (*this>=x)
│ │ │ +
409 {
│ │ │ +
410 ++result;
│ │ │ +
411 *this -= x;
│ │ │ +
412 }
│ │ │ +
413
│ │ │ +
414 *this = result;
│ │ │ +
415 return *this;
│ │ │ +
416 }
│ │ │ +
│ │ │ +
417
│ │ │ +
418 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
420 {
│ │ │ +
421 // better slow than nothing
│ │ │ +
422 while (*this>=x)
│ │ │ +
423 {
│ │ │ +
424 *this -= x;
│ │ │ +
425 }
│ │ │ +
426
│ │ │ +
427 return *this;
│ │ │ +
428 }
│ │ │ +
│ │ │ +
429
│ │ │ +
430 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
432 {
│ │ │ +
433 for (unsigned int i=0; i<n; i++)
│ │ │ +
434 digit[i] = digit[i]&x.digit[i];
│ │ │ +
435 return *this;
│ │ │ +
436 }
│ │ │ +
│ │ │ +
437
│ │ │ +
438 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
440 {
│ │ │ +
441 for (unsigned int i=0; i<n; i++)
│ │ │ +
442 digit[i] = digit[i]^x.digit[i];
│ │ │ +
443 return *this;
│ │ │ +
444 }
│ │ │ +
│ │ │ +
445
│ │ │ +
446 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
448 {
│ │ │ +
449 for (unsigned int i=0; i<n; i++)
│ │ │ +
450 digit[i] = digit[i]|x.digit[i];
│ │ │ +
451 return *this;
│ │ │ +
452 }
│ │ │ +
│ │ │ +
453
│ │ │ +
454 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
456 {
│ │ │ +
457 bigunsignedint<k> result;
│ │ │ +
458 for (unsigned int i=0; i<n; i++)
│ │ │ +
459 result.digit[i] = ~digit[i];
│ │ │ +
460 return result;
│ │ │ +
461 }
│ │ │ +
462
│ │ │ +
463 template <int k>
│ │ │ + │ │ │ +
465 {
│ │ │ +
466 bigunsignedint<k> result(0);
│ │ │ +
467
│ │ │ +
468 // multiples of bits
│ │ │ +
469 int j=shift/bits;
│ │ │ +
470 for (int i=n-1-j; i>=0; i--)
│ │ │ +
471 result.digit[i+j] = digit[i];
│ │ │ +
472
│ │ │ +
473 // remainder
│ │ │ +
474 j=shift%bits;
│ │ │ +
475 for (int i=n-1; i>=0; i--)
│ │ │ +
476 {
│ │ │ +
477 unsigned int temp = result.digit[i];
│ │ │ +
478 temp = temp<<j;
│ │ │ +
479 result.digit[i] = static_cast<std::uint16_t>(temp&bitmask);
│ │ │ +
480 temp = temp>>bits;
│ │ │ +
481 if (i+1<(int)n)
│ │ │ +
482 result.digit[i+1] = result.digit[i+1]|temp;
│ │ │ +
483 }
│ │ │ +
484
│ │ │ +
485 return result;
│ │ │ +
486 }
│ │ │ +
│ │ │ +
487
│ │ │ +
488 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
490 {
│ │ │ +
491 bigunsignedint<k> result(0);
│ │ │ +
492
│ │ │ +
493 // multiples of bits
│ │ │ +
494 int j=shift/bits;
│ │ │ +
495 for (unsigned int i=0; i<n-j; i++)
│ │ │ +
496 result.digit[i] = digit[i+j];
│ │ │ +
497
│ │ │ +
498 // remainder
│ │ │ +
499 j=shift%bits;
│ │ │ +
500 for (unsigned int i=0; i<n; i++)
│ │ │ +
501 {
│ │ │ +
502 std::uint_fast32_t temp = result.digit[i];
│ │ │ +
503 temp = temp<<(bits-j);
│ │ │ +
504 result.digit[i] = static_cast<std::uint16_t>((temp&compbitmask)>>bits);
│ │ │ +
505 if (i>0)
│ │ │ +
506 result.digit[i-1] = result.digit[i-1] | (temp&bitmask);
│ │ │ +
507 }
│ │ │ +
508
│ │ │ +
509 return result;
│ │ │ +
510 }
│ │ │ +
│ │ │ +
511
│ │ │ +
512 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
514 {
│ │ │ +
515 for (unsigned int i=0; i<n; i++)
│ │ │ +
516 if (digit[i]!=x.digit[i]) return true;
│ │ │ +
517 return false;
│ │ │ +
518 }
│ │ │ +
│ │ │ +
519
│ │ │ +
520 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
522 {
│ │ │ +
523 return !((*this)!=x);
│ │ │ +
524 }
│ │ │ +
│ │ │ +
525
│ │ │ +
526 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
528 {
│ │ │ +
529 for (int i=n-1; i>=0; i--)
│ │ │ +
530 if (digit[i]<x.digit[i]) return true;
│ │ │ +
531 else if (digit[i]>x.digit[i]) return false;
│ │ │ +
532 return false;
│ │ │ +
533 }
│ │ │ +
│ │ │ +
534
│ │ │ +
535 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
537 {
│ │ │ +
538 for (int i=n-1; i>=0; i--)
│ │ │ +
539 if (digit[i]<x.digit[i]) return true;
│ │ │ +
540 else if (digit[i]>x.digit[i]) return false;
│ │ │ +
541 return true;
│ │ │ +
542 }
│ │ │ +
│ │ │ +
543
│ │ │ +
544 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
546 {
│ │ │ +
547 return !((*this)<=x);
│ │ │ +
548 }
│ │ │ +
│ │ │ +
549
│ │ │ +
550 template <int k>
│ │ │ +
│ │ │ + │ │ │ +
552 {
│ │ │ +
553 return !((*this)<x);
│ │ │ +
554 }
│ │ │ +
│ │ │ +
555
│ │ │ +
556
│ │ │ +
557 template <int k>
│ │ │ +
│ │ │ +
558 inline bigunsignedint<k> operator+ (const bigunsignedint<k>& x, std::uintmax_t y)
│ │ │ +
559 {
│ │ │ +
560 bigunsignedint<k> temp(y);
│ │ │ +
561 return x+temp;
│ │ │ +
562 }
│ │ │ +
│ │ │ +
563
│ │ │ +
564 template <int k>
│ │ │ +
│ │ │ +
565 inline bigunsignedint<k> operator- (const bigunsignedint<k>& x, std::uintmax_t y)
│ │ │ +
566 {
│ │ │ +
567 bigunsignedint<k> temp(y);
│ │ │ +
568 return x-temp;
│ │ │ +
569 }
│ │ │ +
│ │ │ +
570
│ │ │ +
571 template <int k>
│ │ │ +
│ │ │ +
572 inline bigunsignedint<k> operator* (const bigunsignedint<k>& x, std::uintmax_t y)
│ │ │ +
573 {
│ │ │ +
574 bigunsignedint<k> temp(y);
│ │ │ +
575 return x*temp;
│ │ │ +
576 }
│ │ │ +
│ │ │ +
577
│ │ │ +
578 template <int k>
│ │ │ +
│ │ │ +
579 inline bigunsignedint<k> operator/ (const bigunsignedint<k>& x, std::uintmax_t y)
│ │ │ +
580 {
│ │ │ +
581 bigunsignedint<k> temp(y);
│ │ │ +
582 return x/temp;
│ │ │ +
583 }
│ │ │ +
│ │ │ +
584
│ │ │ +
585 template <int k>
│ │ │ +
│ │ │ +
586 inline bigunsignedint<k> operator% (const bigunsignedint<k>& x, std::uintmax_t y)
│ │ │ +
587 {
│ │ │ +
588 bigunsignedint<k> temp(y);
│ │ │ +
589 return x%temp;
│ │ │ +
590 }
│ │ │ +
│ │ │ +
591
│ │ │ +
592 template <int k>
│ │ │ +
│ │ │ +
593 inline bigunsignedint<k> operator+ (std::uintmax_t x, const bigunsignedint<k>& y)
│ │ │ +
594 {
│ │ │ +
595 bigunsignedint<k> temp(x);
│ │ │ +
596 return temp+y;
│ │ │ +
597 }
│ │ │ +
│ │ │ +
598
│ │ │ +
599 template <int k>
│ │ │ +
│ │ │ +
600 inline bigunsignedint<k> operator- (std::uintmax_t x, const bigunsignedint<k>& y)
│ │ │ +
601 {
│ │ │ +
602 bigunsignedint<k> temp(x);
│ │ │ +
603 return temp-y;
│ │ │ +
604 }
│ │ │ +
│ │ │ +
605
│ │ │ +
606 template <int k>
│ │ │ +
│ │ │ +
607 inline bigunsignedint<k> operator* (std::uintmax_t x, const bigunsignedint<k>& y)
│ │ │ +
608 {
│ │ │ +
609 bigunsignedint<k> temp(x);
│ │ │ +
610 return temp*y;
│ │ │ +
611 }
│ │ │ +
│ │ │ +
612
│ │ │ +
613 template <int k>
│ │ │ +
│ │ │ +
614 inline bigunsignedint<k> operator/ (std::uintmax_t x, const bigunsignedint<k>& y)
│ │ │ +
615 {
│ │ │ +
616 bigunsignedint<k> temp(x);
│ │ │ +
617 return temp/y;
│ │ │ +
618 }
│ │ │ +
│ │ │ +
619
│ │ │ +
620 template <int k>
│ │ │ +
│ │ │ +
621 inline bigunsignedint<k> operator% (std::uintmax_t x, const bigunsignedint<k>& y)
│ │ │ +
622 {
│ │ │ +
623 bigunsignedint<k> temp(x);
│ │ │ +
624 return temp%y;
│ │ │ +
625 }
│ │ │ +
│ │ │ +
626
│ │ │ +
627 // Forward declare type-trait for numbers
│ │ │ +
628 template<class T> struct IsNumber;
│ │ │ +
629
│ │ │ +
631 template <int k>
│ │ │ +
632 struct IsNumber<bigunsignedint<k>> : public std::true_type {};
│ │ │ +
633
│ │ │ +
635}
│ │ │ +
636
│ │ │ +
637namespace std
│ │ │ +
638{
│ │ │ +
639 template<int k>
│ │ │ +
│ │ │ +
640 struct numeric_limits<Dune::bigunsignedint<k> >
│ │ │ +
641 : private Dune::Impl::numeric_limits_helper<Dune::bigunsignedint<k> > // for access to internal state of bigunsignedint
│ │ │ +
642 {
│ │ │ +
643 public:
│ │ │ +
644 static const bool is_specialized = true;
│ │ │ +
645
│ │ │ +
│ │ │ + │ │ │ +
647 {
│ │ │ +
648 return static_cast<Dune::bigunsignedint<k> >(0);
│ │ │ +
649 }
│ │ │ +
│ │ │ +
650
│ │ │ +
│ │ │ + │ │ │ +
652 {
│ │ │ + │ │ │ +
654 for(std::size_t i=0; i < Dune::bigunsignedint<k>::n; ++i)
│ │ │ +
655 // access internal state via the helper base class
│ │ │ +
656 Dune::Impl::numeric_limits_helper<Dune::bigunsignedint<k> >::
│ │ │ +
657 digit(max_,i)=std::numeric_limits<std::uint16_t>::max();
│ │ │ +
658 return max_;
│ │ │ +
659 }
│ │ │ +
│ │ │ +
660
│ │ │ +
661
│ │ │ + │ │ │ + │ │ │ +
664 static const bool is_signed = false;
│ │ │ +
665 static const bool is_integer = true;
│ │ │ +
666 static const bool is_exact = true;
│ │ │ +
667 static const int radix = 2;
│ │ │ +
668
│ │ │ +
│ │ │ + │ │ │ +
670 {
│ │ │ +
671 return static_cast<Dune::bigunsignedint<k> >(0);
│ │ │ +
672 }
│ │ │ +
│ │ │ +
673
│ │ │ +
│ │ │ + │ │ │ +
675 {
│ │ │ +
676 return static_cast<Dune::bigunsignedint<k> >(0);
│ │ │ +
677 }
│ │ │ +
│ │ │ +
678
│ │ │ +
679 static const int min_exponent = 0;
│ │ │ +
680 static const int min_exponent10 = 0;
│ │ │ +
681 static const int max_exponent = 0;
│ │ │ +
682 static const int max_exponent10 = 0;
│ │ │ +
683
│ │ │ +
684 static const bool has_infinity = false;
│ │ │ +
685 static const bool has_quiet_NaN = false;
│ │ │ +
686 static const bool has_signaling_NaN = false;
│ │ │ +
687
│ │ │ +
688 static const float_denorm_style has_denorm = denorm_absent;
│ │ │ +
689 static const bool has_denorm_loss = false;
│ │ │ +
690
│ │ │ +
│ │ │ + │ │ │ +
692 {
│ │ │ +
693 return static_cast<Dune::bigunsignedint<k> >(0);
│ │ │ +
694 }
│ │ │ +
│ │ │ +
695
│ │ │ +
│ │ │ + │ │ │ +
697 {
│ │ │ +
698 return static_cast<Dune::bigunsignedint<k> >(0);
│ │ │ +
699 }
│ │ │ +
│ │ │ +
700
│ │ │ +
│ │ │ + │ │ │ +
702 {
│ │ │ +
703 return static_cast<Dune::bigunsignedint<k> >(0);
│ │ │ +
704 }
│ │ │ +
│ │ │ +
705
│ │ │ +
│ │ │ + │ │ │ +
707 {
│ │ │ +
708 return static_cast<Dune::bigunsignedint<k> >(0);
│ │ │ +
709 }
│ │ │ +
│ │ │ +
710
│ │ │ +
711 static const bool is_iec559 = false;
│ │ │ +
712 static const bool is_bounded = true;
│ │ │ +
713 static const bool is_modulo = true;
│ │ │ +
714
│ │ │ +
715 static const bool traps = false;
│ │ │ +
716 static const bool tinyness_before = false;
│ │ │ +
717 static const float_round_style round_style = round_toward_zero;
│ │ │ +
718
│ │ │ +
719 };
│ │ │ +
│ │ │ +
720
│ │ │ +
721}
│ │ │ +
722
│ │ │ + │ │ │ +
724
│ │ │ +
725#endif
│ │ │ +
Support for calculating hash values of objects.
│ │ │ +
#define DUNE_DEFINE_HASH(template_args, type)
Defines the required struct specialization to make type hashable via Dune::hash.
Definition hash.hh:100
│ │ │ +
#define DUNE_HASH_TYPE(...)
Wrapper macro for the type to be hashed in DUNE_DEFINE_HASH.
Definition hash.hh:117
│ │ │ +
#define DUNE_HASH_TEMPLATE_ARGS(...)
Wrapper macro for the template arguments in DUNE_DEFINE_HASH.
Definition hash.hh:109
│ │ │ +
A few common exception classes.
│ │ │ +
bigunsignedint< k > & operator/=(const bigunsignedint< k > &x)
Definition bigunsignedint.hh:400
│ │ │ +
bigunsignedint< k > operator<<(int i) const
left shift
Definition bigunsignedint.hh:464
│ │ │ +
bigunsignedint< k > & operator+=(const bigunsignedint< k > &x)
Definition bigunsignedint.hh:328
│ │ │ +
bigunsignedint< k > & operator^=(const bigunsignedint< k > &x)
Definition bigunsignedint.hh:439
│ │ │ +
std::ostream & operator<<(std::ostream &s, const bigunsignedint< k > &x)
Definition bigunsignedint.hh:301
│ │ │ +
bool operator<=(const bigunsignedint< k > &x) const
less than or equal
Definition bigunsignedint.hh:536
│ │ │ +
void print(std::ostream &s) const
Print number in hex notation.
Definition bigunsignedint.hh:278
│ │ │ +
bool operator<(const bigunsignedint< k > &x) const
less than
Definition bigunsignedint.hh:527
│ │ │ +
bigunsignedint< k > operator/(const bigunsignedint< k > &x, std::uintmax_t y)
Definition bigunsignedint.hh:579
│ │ │ +
bool operator==(const bigunsignedint< k > &x) const
equal
Definition bigunsignedint.hh:521
│ │ │ +
bool operator!=(const bigunsignedint< k > &x) const
not equal
Definition bigunsignedint.hh:513
│ │ │ +
bigunsignedint()
Construct uninitialized.
Definition bigunsignedint.hh:220
│ │ │ +
bigunsignedint< k > & operator&=(const bigunsignedint< k > &x)
Definition bigunsignedint.hh:431
│ │ │ +
bigunsignedint< k > operator-(const bigunsignedint< k > &x, std::uintmax_t y)
Definition bigunsignedint.hh:565
│ │ │ +
bool operator>=(const bigunsignedint< k > &x) const
greater or equal
Definition bigunsignedint.hh:551
│ │ │ +
bigunsignedint< k > operator>>(int i) const
right shift
Definition bigunsignedint.hh:489
│ │ │ +
bigunsignedint< k > operator+(const bigunsignedint< k > &x, std::uintmax_t y)
Definition bigunsignedint.hh:558
│ │ │ +
bigunsignedint< k > operator~() const
bitwise complement
Definition bigunsignedint.hh:455
│ │ │ +
bigunsignedint< k > & operator++()
prefix increment
Definition bigunsignedint.hh:386
│ │ │ +
bigunsignedint< k > & operator|=(const bigunsignedint< k > &x)
Definition bigunsignedint.hh:447
│ │ │ +
bigunsignedint< k > operator%(const bigunsignedint< k > &x, std::uintmax_t y)
Definition bigunsignedint.hh:586
│ │ │ +
bigunsignedint< k > & operator%=(const bigunsignedint< k > &x)
Definition bigunsignedint.hh:419
│ │ │ +
double todouble() const
Convert to a double.
Definition bigunsignedint.hh:259
│ │ │ +
bigunsignedint< k > & operator-=(const bigunsignedint< k > &x)
Definition bigunsignedint.hh:342
│ │ │ +
bool operator>(const bigunsignedint< k > &x) const
greater than
Definition bigunsignedint.hh:545
│ │ │ +
bigunsignedint< k > & operator*=(const bigunsignedint< k > &x)
Definition bigunsignedint.hh:364
│ │ │ +
std::uint_least32_t touint() const
export to other types
Definition bigunsignedint.hh:253
│ │ │ +
#define DUNE_BINOP(OP)
Definition bigunsignedint.hh:307
│ │ │ +
#define DUNE_THROW(E,...)
Definition exceptions.hh:314
│ │ │ +
constexpr decltype(auto) operator*() const
Dereferencing operator.
Definition iteratorfacades.hh:1119
│ │ │ +
STL namespace.
│ │ │
Dune namespace
Definition alignedallocator.hh:13
│ │ │ -
Helper class for tagging priorities.
Definition typeutilities.hh:73
│ │ │ -
static constexpr std::size_t value
Definition typeutilities.hh:74
│ │ │ -
static constexpr std::size_t value
Definition typeutilities.hh:88
│ │ │ +
std::size_t hash_range(It first, It last)
Hashes all elements in the range [first,last) and returns the combined hash.
Definition hash.hh:322
│ │ │ +
void assign(T &dst, const T &src, bool mask)
masked Simd assignment (scalar version)
Definition simd.hh:447
│ │ │ +
A traits class describing the mapping of types onto MPI_Datatypes.
Definition mpitraits.hh:41
│ │ │ +
Portable very large unsigned integers.
Definition bigunsignedint.hh:74
│ │ │ +
static constexpr int overflowmask
Definition bigunsignedint.hh:83
│ │ │ +
bigunsignedint< k > operator|(const bigunsignedint< k > &x) const
bitwise or
│ │ │ +
static constexpr int hexdigits
Definition bigunsignedint.hh:80
│ │ │ +
bigunsignedint< k > operator^(const bigunsignedint< k > &x) const
bitwise exor
│ │ │ +
bigunsignedint< k > operator%(const bigunsignedint< k > &x) const
│ │ │ +
static constexpr int n
Definition bigunsignedint.hh:79
│ │ │ +
friend int bit_width(const bigunsignedint &arg)
Bit width.
Definition bigunsignedint.hh:184
│ │ │ +
bigunsignedint< k > operator-(const bigunsignedint< k > &x) const
subtract
│ │ │ +
static constexpr int compbitmask
Definition bigunsignedint.hh:82
│ │ │ +
bigunsignedint< k > operator&(const bigunsignedint< k > &x) const
bitwise and
│ │ │ +
static constexpr int bits
Definition bigunsignedint.hh:78
│ │ │ +
bigunsignedint< k > operator/(const bigunsignedint< k > &x) const
│ │ │ +
bigunsignedint< k > operator+(const bigunsignedint< k > &x) const
add
│ │ │ +
friend std::size_t hash_value(const bigunsignedint &arg)
Definition bigunsignedint.hh:203
│ │ │ +
static constexpr int bitmask
Definition bigunsignedint.hh:81
│ │ │ +
friend int countl_zero(const bigunsignedint &arg)
Count left zero bits.
Definition bigunsignedint.hh:198
│ │ │ +
Whether this type acts as a scalar in the context of (hierarchically blocked) containers.
Definition typetraits.hh:194
│ │ │ +
static const bool is_iec559
Definition bigunsignedint.hh:711
│ │ │ +
static const int min_exponent
Definition bigunsignedint.hh:679
│ │ │ +
static const int radix
Definition bigunsignedint.hh:667
│ │ │ +
static const bool is_specialized
Definition bigunsignedint.hh:644
│ │ │ +
static const bool has_quiet_NaN
Definition bigunsignedint.hh:685
│ │ │ +
static const bool is_signed
Definition bigunsignedint.hh:664
│ │ │ +
static const bool is_integer
Definition bigunsignedint.hh:665
│ │ │ +
static const bool is_bounded
Definition bigunsignedint.hh:712
│ │ │ +
static Dune::bigunsignedint< k > denorm_min() noexcept
Definition bigunsignedint.hh:706
│ │ │ +
static const bool is_modulo
Definition bigunsignedint.hh:713
│ │ │ +
static const int digits
Definition bigunsignedint.hh:662
│ │ │ +
static const bool traps
Definition bigunsignedint.hh:715
│ │ │ +
static const bool tinyness_before
Definition bigunsignedint.hh:716
│ │ │ +
static const int min_exponent10
Definition bigunsignedint.hh:680
│ │ │ +
static Dune::bigunsignedint< k > max()
Definition bigunsignedint.hh:651
│ │ │ +
static Dune::bigunsignedint< k > min()
Definition bigunsignedint.hh:646
│ │ │ +
static Dune::bigunsignedint< k > epsilon()
Definition bigunsignedint.hh:669
│ │ │ +
static const float_round_style round_style
Definition bigunsignedint.hh:717
│ │ │ +
static const bool has_denorm_loss
Definition bigunsignedint.hh:689
│ │ │ +
static Dune::bigunsignedint< k > signaling_NaN() noexcept
Definition bigunsignedint.hh:701
│ │ │ +
static const int max_exponent10
Definition bigunsignedint.hh:682
│ │ │ +
static const bool is_exact
Definition bigunsignedint.hh:666
│ │ │ +
static const float_denorm_style has_denorm
Definition bigunsignedint.hh:688
│ │ │ +
static const bool has_signaling_NaN
Definition bigunsignedint.hh:686
│ │ │ +
static Dune::bigunsignedint< k > infinity() noexcept
Definition bigunsignedint.hh:691
│ │ │ +
static const int max_exponent
Definition bigunsignedint.hh:681
│ │ │ +
static Dune::bigunsignedint< k > quiet_NaN() noexcept
Definition bigunsignedint.hh:696
│ │ │ +
static const bool has_infinity
Definition bigunsignedint.hh:684
│ │ │ +
static Dune::bigunsignedint< k > round_error()
Definition bigunsignedint.hh:674
│ │ │ +
Base class for Dune-Exceptions.
Definition exceptions.hh:98
│ │ │ +
Default exception class for mathematical errors.
Definition exceptions.hh:335
│ │ │ + │ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,84 +1,1006 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -typeutilities.hh │ │ │ │ +bigunsignedint.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ 1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ 2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ 4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ -5#ifndef DUNE_COMMON_TYPEUTILITIES_HH │ │ │ │ -6#define DUNE_COMMON_TYPEUTILITIES_HH │ │ │ │ -7 │ │ │ │ -8#include │ │ │ │ -9#include │ │ │ │ -10#include │ │ │ │ -11 │ │ │ │ -12 │ │ │ │ -13namespace _D_u_n_e { │ │ │ │ -14 │ │ │ │ -20 │ │ │ │ -21 │ │ │ │ -22 namespace Impl │ │ │ │ -23 { │ │ │ │ +5 │ │ │ │ +6#ifndef DUNE_BIGUNSIGNEDINT_HH │ │ │ │ +7#define DUNE_BIGUNSIGNEDINT_HH │ │ │ │ +8 │ │ │ │ +9#include │ │ │ │ +10#include │ │ │ │ +11#include │ │ │ │ +12#include │ │ │ │ +13#include │ │ │ │ +14#include │ │ │ │ +15#include │ │ │ │ +16#include <_d_u_n_e_/_c_o_m_m_o_n_/_e_x_c_e_p_t_i_o_n_s_._h_h> │ │ │ │ +17#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_a_s_h_._h_h> │ │ │ │ +18 │ │ │ │ 24 │ │ │ │ -25 template │ │ │ │ -26 struct disableCopyMoveHelper : public std::is_base_of...>>> │ │ │ │ -27 {}; │ │ │ │ -28 │ │ │ │ -29 template │ │ │ │ -30 struct disableCopyMoveHelper : public std::false_type │ │ │ │ -31 {}; │ │ │ │ -32 │ │ │ │ -33 } // namespace Impl │ │ │ │ -34 │ │ │ │ -35 │ │ │ │ -44 template │ │ │ │ -_4_5 using _d_i_s_a_b_l_e_C_o_p_y_M_o_v_e = std::enable_if_t< not Impl:: │ │ │ │ -disableCopyMoveHelper::value, int>; │ │ │ │ -46 │ │ │ │ -47 │ │ │ │ +25namespace _D_u_n_e │ │ │ │ +26{ │ │ │ │ +27#if HAVE_MPI │ │ │ │ +28 template │ │ │ │ +29 struct _M_P_I_T_r_a_i_t_s; │ │ │ │ +30#endif │ │ │ │ +31 │ │ │ │ +36 │ │ │ │ +37 namespace Impl { │ │ │ │ +38 │ │ │ │ +39 // numeric_limits_helper provides std::numeric_limits access to the │ │ │ │ +internals │ │ │ │ +40 // of bigunsignedint. Previously, the correct specialization of std:: │ │ │ │ +numeric_limits │ │ │ │ +41 // was a friend of bigunsignedint, but that creates problems on recent │ │ │ │ +versions │ │ │ │ +42 // of clang with the alternative libc++ library, because that library │ │ │ │ +declares the │ │ │ │ +43 // base template of std::numeric_limits as a class and clang subsequently │ │ │ │ +complains │ │ │ │ +44 // if the friend declaration uses 'struct'. Unfortunately, libstdc++ uses a │ │ │ │ +struct, │ │ │ │ +45 // making it impossible to keep clang happy for both standard libraries. │ │ │ │ +46 // So we move the access helper functionality into a custom struct and │ │ │ │ +simply let │ │ │ │ +47 // the numeric_limits specialization inherit from the helper. │ │ │ │ 48 │ │ │ │ -71 template │ │ │ │ -_7_2 struct _P_r_i_o_r_i_t_y_T_a_g : public _P_r_i_o_r_i_t_y_T_a_g │ │ │ │ -73 { │ │ │ │ -_7_4 static constexpr std::size_t _v_a_l_u_e = priority; │ │ │ │ -75 }; │ │ │ │ +49 template │ │ │ │ +50 struct numeric_limits_helper │ │ │ │ +51 { │ │ │ │ +52 │ │ │ │ +53 protected: │ │ │ │ +54 │ │ │ │ +55 static std::uint16_t& digit(T& big_unsigned_int, std::size_t i) │ │ │ │ +56 { │ │ │ │ +57 return big_unsigned_int.digit[i]; │ │ │ │ +58 } │ │ │ │ +59 │ │ │ │ +60 }; │ │ │ │ +61 │ │ │ │ +62 } │ │ │ │ +63 │ │ │ │ +72 │ │ │ │ +73 template │ │ │ │ +_7_4 class _b_i_g_u_n_s_i_g_n_e_d_i_n_t { │ │ │ │ +75 public: │ │ │ │ 76 │ │ │ │ -85 template<> │ │ │ │ -_8_6 struct _P_r_i_o_r_i_t_y_T_a_g<0> │ │ │ │ -87 { │ │ │ │ -_8_8 static constexpr std::size_t _v_a_l_u_e = 0; │ │ │ │ -89 }; │ │ │ │ -90 │ │ │ │ +77 // unsigned short is 16 bits wide, n is the number of digits needed │ │ │ │ +_7_8 constexpr static int _b_i_t_s = std::numeric_limits::digits; │ │ │ │ +_7_9 constexpr static int _n = k/_b_i_t_s+(k%_b_i_t_s!=0); │ │ │ │ +_8_0 constexpr static int _h_e_x_d_i_g_i_t_s = 4; │ │ │ │ +_8_1 constexpr static int _b_i_t_m_a_s_k = 0xFFFF; │ │ │ │ +_8_2 constexpr static int _c_o_m_p_b_i_t_m_a_s_k = 0xFFFF0000; │ │ │ │ +_8_3 constexpr static int _o_v_e_r_f_l_o_w_m_a_s_k = 0x1; │ │ │ │ +84 │ │ │ │ +86 _b_i_g_u_n_s_i_g_n_e_d_i_n_t (); │ │ │ │ +87 │ │ │ │ +89 template │ │ │ │ +90 _b_i_g_u_n_s_i_g_n_e_d_i_n_t (Signed x, typename std::enable_if:: │ │ │ │ +value && std::is_signed::value>_:_:_t_y_p_e* = 0); │ │ │ │ 91 │ │ │ │ -92 │ │ │ │ -93} // namespace Dune │ │ │ │ +93 _b_i_g_u_n_s_i_g_n_e_d_i_n_t (std::uintmax_t x); │ │ │ │ 94 │ │ │ │ -95 │ │ │ │ -96 │ │ │ │ -97#endif // DUNE_COMMON_TYPEUTILITIES_HH │ │ │ │ -_D_u_n_e_:_:_d_i_s_a_b_l_e_C_o_p_y_M_o_v_e │ │ │ │ -std::enable_if_t< not Impl::disableCopyMoveHelper< This, T... >::value, int > │ │ │ │ -disableCopyMove │ │ │ │ -Helper to disable constructor as copy and move constructor. │ │ │ │ -DDeeffiinniittiioonn typeutilities.hh:45 │ │ │ │ +96 void _p_r_i_n_t (std::ostream& s) const ; │ │ │ │ +97 │ │ │ │ +_9_9 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_+_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +100 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _o_p_e_r_a_t_o_r_+_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x); │ │ │ │ +101 │ │ │ │ +_1_0_3 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_-_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +104 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _o_p_e_r_a_t_o_r_-_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x); │ │ │ │ +105 │ │ │ │ +_1_0_7 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_*_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +108 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _o_p_e_r_a_t_o_r_*_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x); │ │ │ │ +109 │ │ │ │ +111 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _o_p_e_r_a_t_o_r_+_+_ (); │ │ │ │ +112 │ │ │ │ +_1_1_6 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_/_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +117 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _o_p_e_r_a_t_o_r_/_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x); │ │ │ │ +118 │ │ │ │ +_1_2_2 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_%_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +123 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _o_p_e_r_a_t_o_r_%_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x); │ │ │ │ +124 │ │ │ │ +_1_2_6 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_&_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +127 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _o_p_e_r_a_t_o_r_&_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x); │ │ │ │ +128 │ │ │ │ +_1_3_0 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_^_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +131 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _o_p_e_r_a_t_o_r_^_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x); │ │ │ │ +132 │ │ │ │ +_1_3_4 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_|_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +135 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _o_p_e_r_a_t_o_r_|_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x); │ │ │ │ +136 │ │ │ │ +138 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_~_ () const; │ │ │ │ +139 │ │ │ │ +140 │ │ │ │ +142 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_<_<_ (int i) const; │ │ │ │ +143 │ │ │ │ +145 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_>_>_ (int i) const; │ │ │ │ +146 │ │ │ │ +147 │ │ │ │ +149 bool _o_p_e_r_a_t_o_r_<_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +150 │ │ │ │ +152 bool _o_p_e_r_a_t_o_r_<_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +153 │ │ │ │ +155 bool _o_p_e_r_a_t_o_r_>_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +156 │ │ │ │ +158 bool _o_p_e_r_a_t_o_r_>_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +159 │ │ │ │ +161 bool _o_p_e_r_a_t_o_r_=_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +162 │ │ │ │ +164 bool _o_p_e_r_a_t_o_r_!_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const; │ │ │ │ +165 │ │ │ │ +166 │ │ │ │ +168 // operator unsigned int () const; │ │ │ │ +169 std::uint_least32_t _t_o_u_i_n_t() const; │ │ │ │ +_1_7_5 double _t_o_d_o_u_b_l_e() const; │ │ │ │ +176 │ │ │ │ +177 friend class _b_i_g_u_n_s_i_g_n_e_d_i_n_t; │ │ │ │ +178 friend struct Impl::numeric_limits_helper< _b_i_g_u_n_s_i_g_n_e_d_i_n_t >; │ │ │ │ +179 │ │ │ │ +_1_8_4 friend int _b_i_t___w_i_d_t_h(const _b_i_g_u_n_s_i_g_n_e_d_i_n_t& arg) │ │ │ │ +185 { │ │ │ │ +186 int width = _b_i_t_s * std::size(arg.digit); │ │ │ │ +187 auto it = std::rbegin(arg.digit); │ │ │ │ +188 do { │ │ │ │ +189 width -= (_b_i_t_s - std::bit_width(*it)); │ │ │ │ +190 } while ((*it == 0) and ((++it) != std::rend(arg.digit))); │ │ │ │ +191 return width; │ │ │ │ +192 } │ │ │ │ +193 │ │ │ │ +_1_9_8 friend int _c_o_u_n_t_l___z_e_r_o(const _b_i_g_u_n_s_i_g_n_e_d_i_n_t& arg) │ │ │ │ +199 { │ │ │ │ +200 return _b_i_t_s*_n - _b_i_t___w_i_d_t_h(arg); │ │ │ │ +201 } │ │ │ │ +202 │ │ │ │ +_2_0_3 inline friend std::size_t _h_a_s_h___v_a_l_u_e(const _b_i_g_u_n_s_i_g_n_e_d_i_n_t& arg) │ │ │ │ +204 { │ │ │ │ +205 return _h_a_s_h___r_a_n_g_e(arg.digit,arg.digit + arg._n); │ │ │ │ +206 } │ │ │ │ +207 │ │ │ │ +208 private: │ │ │ │ +_2_0_9 std::uint16_t digit[_n]; │ │ │ │ +210#if HAVE_MPI │ │ │ │ +211 friend struct _M_P_I_T_r_a_i_t_s<_b_i_g_u_n_s_i_g_n_e_d_i_n_t >; │ │ │ │ +212#endif │ │ │ │ +213 inline void assign(std::uintmax_t x); │ │ │ │ +214 │ │ │ │ +215 │ │ │ │ +216 } ; │ │ │ │ +217 │ │ │ │ +218 // Constructors │ │ │ │ +219 template │ │ │ │ +_2_2_0 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t () │ │ │ │ +221 { │ │ │ │ +222 _a_s_s_i_g_n(0u); │ │ │ │ +223 } │ │ │ │ +224 │ │ │ │ +225 template │ │ │ │ +226 template │ │ │ │ +_2_2_7 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t (Signed y, typename std::enable_if::value && std::is_signed::value>_:_:_t_y_p_e*) │ │ │ │ +228 { │ │ │ │ +229 if (y < 0) │ │ │ │ +230 _D_U_N_E___T_H_R_O_W(_D_u_n_e_:_:_E_x_c_e_p_t_i_o_n, "Trying to construct a Dune::bigunsignedint │ │ │ │ +from a negative integer: " << y); │ │ │ │ +231 _a_s_s_i_g_n(y); │ │ │ │ +232 } │ │ │ │ +233 │ │ │ │ +234 template │ │ │ │ +_2_3_5 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t (std::uintmax_t x) │ │ │ │ +236 { │ │ │ │ +237 _a_s_s_i_g_n(x); │ │ │ │ +238 } │ │ │ │ +239 template │ │ │ │ +240 void bigunsignedint::assign(std::uintmax_t x) │ │ │ │ +241 { │ │ │ │ +242 static const int no=std::min(n, std::numeric_limits:: │ │ │ │ +digits/bits); │ │ │ │ +243 │ │ │ │ +244 for(int i=0; i>bits; │ │ │ │ +247 } │ │ │ │ +248 for (unsigned int i=no; i │ │ │ │ +_2_5_3 inline std::uint_least32_t _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_t_o_u_i_n_t () const │ │ │ │ +254 { │ │ │ │ +255 return (digit[1]<<_b_i_t_s)+digit[0]; │ │ │ │ +256 } │ │ │ │ +257 │ │ │ │ +258 template │ │ │ │ +_2_5_9 inline double _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_t_o_d_o_u_b_l_e() const │ │ │ │ +260 { │ │ │ │ +261 int firstInZeroRange=_n; │ │ │ │ +262 for(int i=_n-1; i>=0; --i) │ │ │ │ +263 if(digit[i]!=0) │ │ │ │ +264 break; │ │ │ │ +265 else │ │ │ │ +266 --firstInZeroRange; │ │ │ │ +267 int representableDigits=std::numeric_limits::digits/_b_i_t_s; │ │ │ │ +268 int lastInRepresentableRange=0; │ │ │ │ +269 if(representableDigits=lastInRepresentableRange; --i) │ │ │ │ +273 val =val*(1<<_b_i_t_s)+digit[i]; │ │ │ │ +274 return val*(1<<(_b_i_t_s*lastInRepresentableRange)); │ │ │ │ +275 } │ │ │ │ +276 // print │ │ │ │ +277 template │ │ │ │ +_2_7_8 inline void _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_p_r_i_n_t (std::ostream& s) const │ │ │ │ +279 { │ │ │ │ +280 bool leading=false; │ │ │ │ +281 │ │ │ │ +282 // print from left to right │ │ │ │ +283 for (int i=_n-1; i>=0; i--) │ │ │ │ +284 for (int d=_h_e_x_d_i_g_i_t_s-1; d>=0; d--) │ │ │ │ +285 { │ │ │ │ +286 // extract one hex digit │ │ │ │ +287 int current = (digit[i]>>(d*4))&0xF; │ │ │ │ +288 if (current!=0) │ │ │ │ +289 { │ │ │ │ +290 // s.setf(std::ios::noshowbase); │ │ │ │ +291 s << std::hex << current; │ │ │ │ +292 leading = false; │ │ │ │ +293 } │ │ │ │ +294 else if (!leading) s << std::hex << current; │ │ │ │ +295 } │ │ │ │ +296 if (leading) s << "0"; │ │ │ │ +297 s << std::dec; │ │ │ │ +298 } │ │ │ │ +299 │ │ │ │ +300 template │ │ │ │ +_3_0_1 inline std::ostream& _o_p_e_r_a_t_o_r_<_<_ (std::ostream& s, const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& │ │ │ │ +x) │ │ │ │ +302 { │ │ │ │ +303 x._p_r_i_n_t(s); │ │ │ │ +304 return s; │ │ │ │ +305 } │ │ │ │ +306 │ │ │ │ +_3_0_7 #define DUNE_BINOP(OP) \ │ │ │ │ +308 template \ │ │ │ │ +309 inline bigunsignedint bigunsignedint::operator OP (const │ │ │ │ +bigunsignedint &x) const \ │ │ │ │ +310 { \ │ │ │ │ +311 auto temp = *this; \ │ │ │ │ +312 temp OP##= x; \ │ │ │ │ +313 return temp; \ │ │ │ │ +314 } │ │ │ │ +315 │ │ │ │ +316 _D_U_N_E___B_I_N_O_P(+) │ │ │ │ +317 _D_U_N_E___B_I_N_O_P(-) │ │ │ │ +318 _D_U_N_E___B_I_N_O_P(*) │ │ │ │ +319 _D_U_N_E___B_I_N_O_P(/) │ │ │ │ +320 _D_U_N_E___B_I_N_O_P(%) │ │ │ │ +321 _D_U_N_E___B_I_N_O_P(&) │ │ │ │ +322 _D_U_N_E___B_I_N_O_P(^) │ │ │ │ +323 _D_U_N_E___B_I_N_O_P(|) │ │ │ │ +324 │ │ │ │ +325 #undef DUNE_BINOP │ │ │ │ +326 │ │ │ │ +327 template │ │ │ │ +_3_2_8 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_+_=_ (const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +329 { │ │ │ │ +330 std::uint_fast32_t overflow=0; │ │ │ │ +331 │ │ │ │ +332 for (unsigned int i=0; i<_n; i++) │ │ │ │ +333 { │ │ │ │ +334 std::uint_fast32_t sum = static_cast(digit[i]) + │ │ │ │ +static_cast(x.digit[i]) + overflow; │ │ │ │ +335 digit[i] = sum&_b_i_t_m_a_s_k; │ │ │ │ +336 overflow = (sum>>_b_i_t_s)&_o_v_e_r_f_l_o_w_m_a_s_k; │ │ │ │ +337 } │ │ │ │ +338 return *this; │ │ │ │ +339 } │ │ │ │ +340 │ │ │ │ +341 template │ │ │ │ +_3_4_2 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_-_=_ (const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +343 { │ │ │ │ +344 std::int_fast32_t overflow=0; │ │ │ │ +345 │ │ │ │ +346 for (unsigned int i=0; i<_n; i++) │ │ │ │ +347 { │ │ │ │ +348 std::int_fast32_t diff = static_cast(digit[i]) - │ │ │ │ +static_cast(x.digit[i]) - overflow; │ │ │ │ +349 if (diff>=0) │ │ │ │ +350 { │ │ │ │ +351 digit[i] = static_cast(diff); │ │ │ │ +352 overflow = 0; │ │ │ │ +353 } │ │ │ │ +354 else │ │ │ │ +355 { │ │ │ │ +356 digit[i] = static_cast(diff+_b_i_t_m_a_s_k+1); │ │ │ │ +357 overflow = 1; │ │ │ │ +358 } │ │ │ │ +359 } │ │ │ │ +360 return *this; │ │ │ │ +361 } │ │ │ │ +362 │ │ │ │ +363 template │ │ │ │ +_3_6_4 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_*_=_ (const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +365 { │ │ │ │ +366 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_2_*_k_> finalproduct(0); │ │ │ │ +367 │ │ │ │ +368 for (unsigned int m=0; m<_n; m++) // digit in right factor │ │ │ │ +369 { │ │ │ │ +370 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_2_*_k_> singleproduct(0); │ │ │ │ +371 std::uint_fast32_t overflow(0); │ │ │ │ +372 for (unsigned int i=0; i<_n; i++) │ │ │ │ +373 { │ │ │ │ +374 std::uint_fast32_t digitproduct = static_cast(digit │ │ │ │ +[i])*static_cast(x.digit[m])+overflow; │ │ │ │ +375 singleproduct.digit[i+m] = static_cast │ │ │ │ +(digitproduct&_b_i_t_m_a_s_k); │ │ │ │ +376 overflow = (digitproduct>>_b_i_t_s)&_b_i_t_m_a_s_k; │ │ │ │ +377 } │ │ │ │ +378 finalproduct = finalproduct+singleproduct; │ │ │ │ +379 } │ │ │ │ +380 │ │ │ │ +381 for (unsigned int i=0; i<_n; i++) digit[i] = finalproduct.digit[i]; │ │ │ │ +382 return *this; │ │ │ │ +383 } │ │ │ │ +384 │ │ │ │ +385 template │ │ │ │ +_3_8_6 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_+_+_ () │ │ │ │ +387 { │ │ │ │ +388 std::uint_fast32_t overflow=1; │ │ │ │ +389 │ │ │ │ +390 for (unsigned int i=0; i<_n; i++) │ │ │ │ +391 { │ │ │ │ +392 std::uint_fast32_t sum = static_cast(digit[i]) + │ │ │ │ +overflow; │ │ │ │ +393 digit[i] = sum&_b_i_t_m_a_s_k; │ │ │ │ +394 overflow = (sum>>_b_i_t_s)&_o_v_e_r_f_l_o_w_m_a_s_k; │ │ │ │ +395 } │ │ │ │ +396 return *this; │ │ │ │ +397 } │ │ │ │ +398 │ │ │ │ +399 template │ │ │ │ +_4_0_0 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_/_=_ (const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +401 { │ │ │ │ +402 if(x==0) │ │ │ │ +403 _D_U_N_E___T_H_R_O_W(_D_u_n_e_:_:_M_a_t_h_E_r_r_o_r, "division by zero!"); │ │ │ │ +404 │ │ │ │ +405 // better slow than nothing │ │ │ │ +406 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> result(0); │ │ │ │ +407 │ │ │ │ +408 while (*this>=x) │ │ │ │ +409 { │ │ │ │ +410 ++result; │ │ │ │ +411 *this -= x; │ │ │ │ +412 } │ │ │ │ +413 │ │ │ │ +414 *this = result; │ │ │ │ +415 return *this; │ │ │ │ +416 } │ │ │ │ +417 │ │ │ │ +418 template │ │ │ │ +_4_1_9 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_%_=_ (const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +420 { │ │ │ │ +421 // better slow than nothing │ │ │ │ +422 while (*this>=x) │ │ │ │ +423 { │ │ │ │ +424 *this -= x; │ │ │ │ +425 } │ │ │ │ +426 │ │ │ │ +427 return *this; │ │ │ │ +428 } │ │ │ │ +429 │ │ │ │ +430 template │ │ │ │ +_4_3_1 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_&_=_ (const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +432 { │ │ │ │ +433 for (unsigned int i=0; i<_n; i++) │ │ │ │ +434 digit[i] = digit[i]&x.digit[i]; │ │ │ │ +435 return *this; │ │ │ │ +436 } │ │ │ │ +437 │ │ │ │ +438 template │ │ │ │ +_4_3_9 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_^_=_ (const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +440 { │ │ │ │ +441 for (unsigned int i=0; i<_n; i++) │ │ │ │ +442 digit[i] = digit[i]^x.digit[i]; │ │ │ │ +443 return *this; │ │ │ │ +444 } │ │ │ │ +445 │ │ │ │ +446 template │ │ │ │ +_4_4_7 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_|_=_ (const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +448 { │ │ │ │ +449 for (unsigned int i=0; i<_n; i++) │ │ │ │ +450 digit[i] = digit[i]|x.digit[i]; │ │ │ │ +451 return *this; │ │ │ │ +452 } │ │ │ │ +453 │ │ │ │ +454 template │ │ │ │ +_4_5_5 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_~_ () const │ │ │ │ +456 { │ │ │ │ +457 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> result; │ │ │ │ +458 for (unsigned int i=0; i<_n; i++) │ │ │ │ +459 result.digit[i] = ~digit[i]; │ │ │ │ +460 return result; │ │ │ │ +461 } │ │ │ │ +462 │ │ │ │ +463 template │ │ │ │ +464 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_<_<_ (int shift) const │ │ │ │ +465 { │ │ │ │ +466 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> result(0); │ │ │ │ +467 │ │ │ │ +468 // multiples of bits │ │ │ │ +469 int j=shift/bits; │ │ │ │ +470 for (int i=n-1-j; i>=0; i--) │ │ │ │ +471 result.digit[i+j] = digit[i]; │ │ │ │ +472 │ │ │ │ +473 // remainder │ │ │ │ +474 j=shift%bits; │ │ │ │ +475 for (int i=n-1; i>=0; i--) │ │ │ │ +476 { │ │ │ │ +477 unsigned int temp = result.digit[i]; │ │ │ │ +478 temp = temp<(temp&bitmask); │ │ │ │ +480 temp = temp>>bits; │ │ │ │ +481 if (i+1<(int)n) │ │ │ │ +482 result.digit[i+1] = result.digit[i+1]|temp; │ │ │ │ +483 } │ │ │ │ +484 │ │ │ │ +485 return result; │ │ │ │ +486 } │ │ │ │ +487 │ │ │ │ +488 template │ │ │ │ +_4_8_9 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_>_>_ (int shift) const │ │ │ │ +490 { │ │ │ │ +491 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> result(0); │ │ │ │ +492 │ │ │ │ +493 // multiples of bits │ │ │ │ +494 int j=shift/_b_i_t_s; │ │ │ │ +495 for (unsigned int i=0; i<_n-j; i++) │ │ │ │ +496 result.digit[i] = digit[i+j]; │ │ │ │ +497 │ │ │ │ +498 // remainder │ │ │ │ +499 j=shift%_b_i_t_s; │ │ │ │ +500 for (unsigned int i=0; i<_n; i++) │ │ │ │ +501 { │ │ │ │ +502 std::uint_fast32_t temp = result.digit[i]; │ │ │ │ +503 temp = temp<<(_b_i_t_s-j); │ │ │ │ +504 result.digit[i] = static_cast((temp&_c_o_m_p_b_i_t_m_a_s_k)>>_b_i_t_s); │ │ │ │ +505 if (i>0) │ │ │ │ +506 result.digit[i-1] = result.digit[i-1] | (temp&_b_i_t_m_a_s_k); │ │ │ │ +507 } │ │ │ │ +508 │ │ │ │ +509 return result; │ │ │ │ +510 } │ │ │ │ +511 │ │ │ │ +512 template │ │ │ │ +_5_1_3 inline bool _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_!_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +const │ │ │ │ +514 { │ │ │ │ +515 for (unsigned int i=0; i<_n; i++) │ │ │ │ +516 if (digit[i]!=x.digit[i]) return true; │ │ │ │ +517 return false; │ │ │ │ +518 } │ │ │ │ +519 │ │ │ │ +520 template │ │ │ │ +_5_2_1 inline bool _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_=_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +const │ │ │ │ +522 { │ │ │ │ +523 return !((*this)!=x); │ │ │ │ +524 } │ │ │ │ +525 │ │ │ │ +526 template │ │ │ │ +_5_2_7 inline bool _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_<_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const │ │ │ │ +528 { │ │ │ │ +529 for (int i=_n-1; i>=0; i--) │ │ │ │ +530 if (digit[i]x.digit[i]) return false; │ │ │ │ +532 return false; │ │ │ │ +533 } │ │ │ │ +534 │ │ │ │ +535 template │ │ │ │ +_5_3_6 inline bool _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_<_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +const │ │ │ │ +537 { │ │ │ │ +538 for (int i=_n-1; i>=0; i--) │ │ │ │ +539 if (digit[i]x.digit[i]) return false; │ │ │ │ +541 return true; │ │ │ │ +542 } │ │ │ │ +543 │ │ │ │ +544 template │ │ │ │ +_5_4_5 inline bool _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_>_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) const │ │ │ │ +546 { │ │ │ │ +547 return !((*this)<=x); │ │ │ │ +548 } │ │ │ │ +549 │ │ │ │ +550 template │ │ │ │ +_5_5_1 inline bool _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_o_p_e_r_a_t_o_r_>_=_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x) │ │ │ │ +const │ │ │ │ +552 { │ │ │ │ +553 return !((*this) │ │ │ │ +_5_5_8 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_+_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x, std:: │ │ │ │ +uintmax_t y) │ │ │ │ +559 { │ │ │ │ +560 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(y); │ │ │ │ +561 return x+temp; │ │ │ │ +562 } │ │ │ │ +563 │ │ │ │ +564 template │ │ │ │ +_5_6_5 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_-_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x, std:: │ │ │ │ +uintmax_t y) │ │ │ │ +566 { │ │ │ │ +567 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(y); │ │ │ │ +568 return x-temp; │ │ │ │ +569 } │ │ │ │ +570 │ │ │ │ +571 template │ │ │ │ +_5_7_2 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_*_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x, std:: │ │ │ │ +uintmax_t y) │ │ │ │ +573 { │ │ │ │ +574 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(y); │ │ │ │ +575 return x*temp; │ │ │ │ +576 } │ │ │ │ +577 │ │ │ │ +578 template │ │ │ │ +_5_7_9 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_/_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x, std:: │ │ │ │ +uintmax_t y) │ │ │ │ +580 { │ │ │ │ +581 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(y); │ │ │ │ +582 return x/temp; │ │ │ │ +583 } │ │ │ │ +584 │ │ │ │ +585 template │ │ │ │ +_5_8_6 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_%_ (const _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& x, std:: │ │ │ │ +uintmax_t y) │ │ │ │ +587 { │ │ │ │ +588 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(y); │ │ │ │ +589 return x%temp; │ │ │ │ +590 } │ │ │ │ +591 │ │ │ │ +592 template │ │ │ │ +_5_9_3 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_+_ (std::uintmax_t x, const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& y) │ │ │ │ +594 { │ │ │ │ +595 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(x); │ │ │ │ +596 return temp+y; │ │ │ │ +597 } │ │ │ │ +598 │ │ │ │ +599 template │ │ │ │ +_6_0_0 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_-_ (std::uintmax_t x, const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& y) │ │ │ │ +601 { │ │ │ │ +602 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(x); │ │ │ │ +603 return temp-y; │ │ │ │ +604 } │ │ │ │ +605 │ │ │ │ +606 template │ │ │ │ +_6_0_7 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_*_ (std::uintmax_t x, const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& y) │ │ │ │ +608 { │ │ │ │ +609 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(x); │ │ │ │ +610 return temp*y; │ │ │ │ +611 } │ │ │ │ +612 │ │ │ │ +613 template │ │ │ │ +_6_1_4 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_/_ (std::uintmax_t x, const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& y) │ │ │ │ +615 { │ │ │ │ +616 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(x); │ │ │ │ +617 return temp/y; │ │ │ │ +618 } │ │ │ │ +619 │ │ │ │ +620 template │ │ │ │ +_6_2_1 inline _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _o_p_e_r_a_t_o_r_%_ (std::uintmax_t x, const │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>& y) │ │ │ │ +622 { │ │ │ │ +623 _b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> temp(x); │ │ │ │ +624 return temp%y; │ │ │ │ +625 } │ │ │ │ +626 │ │ │ │ +627 // Forward declare type-trait for numbers │ │ │ │ +628 template struct IsNumber; │ │ │ │ +629 │ │ │ │ +631 template │ │ │ │ +_6_3_2 struct _I_s_N_u_m_b_e_r<_b_i_g_u_n_s_i_g_n_e_d_i_n_t> : public std::true_type {}; │ │ │ │ +633 │ │ │ │ +635} │ │ │ │ +636 │ │ │ │ +637namespace _s_t_d │ │ │ │ +638{ │ │ │ │ +639 template │ │ │ │ +_6_4_0 struct numeric_limits<_D_u_n_e::bigunsignedint > │ │ │ │ +641 : private Dune::Impl::numeric_limits_helper > / │ │ │ │ +/ for access to internal state of bigunsignedint │ │ │ │ +642 { │ │ │ │ +643 public: │ │ │ │ +_6_4_4 static const bool _i_s___s_p_e_c_i_a_l_i_z_e_d = true; │ │ │ │ +645 │ │ │ │ +_6_4_6 static _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _m_i_n() │ │ │ │ +647 { │ │ │ │ +648 return static_cast<_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> >(0); │ │ │ │ +649 } │ │ │ │ +650 │ │ │ │ +_6_5_1 static _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _m_a_x() │ │ │ │ +652 { │ │ │ │ +653 _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> max_; │ │ │ │ +654 for(std::size_t i=0; i < Dune::bigunsignedint::n; ++i) │ │ │ │ +655 // access internal state via the helper base class │ │ │ │ +656 Dune::Impl::numeric_limits_helper<_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> >:: │ │ │ │ +657 digit(max_,i)=std::numeric_limits::max(); │ │ │ │ +658 return max_; │ │ │ │ +659 } │ │ │ │ +660 │ │ │ │ +661 │ │ │ │ +_6_6_2 static const int _d_i_g_i_t_s = _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_b_i_t_s * │ │ │ │ +663 _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>_:_:_n; │ │ │ │ +_6_6_4 static const bool _i_s___s_i_g_n_e_d = false; │ │ │ │ +_6_6_5 static const bool _i_s___i_n_t_e_g_e_r = true; │ │ │ │ +_6_6_6 static const bool _i_s___e_x_a_c_t = true; │ │ │ │ +_6_6_7 static const int _r_a_d_i_x = 2; │ │ │ │ +668 │ │ │ │ +_6_6_9 static _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _e_p_s_i_l_o_n() │ │ │ │ +670 { │ │ │ │ +671 return static_cast<_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> >(0); │ │ │ │ +672 } │ │ │ │ +673 │ │ │ │ +_6_7_4 static _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _r_o_u_n_d___e_r_r_o_r() │ │ │ │ +675 { │ │ │ │ +676 return static_cast<_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> >(0); │ │ │ │ +677 } │ │ │ │ +678 │ │ │ │ +_6_7_9 static const int _m_i_n___e_x_p_o_n_e_n_t = 0; │ │ │ │ +_6_8_0 static const int _m_i_n___e_x_p_o_n_e_n_t_1_0 = 0; │ │ │ │ +_6_8_1 static const int _m_a_x___e_x_p_o_n_e_n_t = 0; │ │ │ │ +_6_8_2 static const int _m_a_x___e_x_p_o_n_e_n_t_1_0 = 0; │ │ │ │ +683 │ │ │ │ +_6_8_4 static const bool _h_a_s___i_n_f_i_n_i_t_y = false; │ │ │ │ +_6_8_5 static const bool _h_a_s___q_u_i_e_t___N_a_N = false; │ │ │ │ +_6_8_6 static const bool _h_a_s___s_i_g_n_a_l_i_n_g___N_a_N = false; │ │ │ │ +687 │ │ │ │ +_6_8_8 static const float_denorm_style _h_a_s___d_e_n_o_r_m = denorm_absent; │ │ │ │ +_6_8_9 static const bool _h_a_s___d_e_n_o_r_m___l_o_s_s = false; │ │ │ │ +690 │ │ │ │ +_6_9_1 static _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _i_n_f_i_n_i_t_y() noexcept │ │ │ │ +692 { │ │ │ │ +693 return static_cast<_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> >(0); │ │ │ │ +694 } │ │ │ │ +695 │ │ │ │ +_6_9_6 static _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _q_u_i_e_t___N_a_N() noexcept │ │ │ │ +697 { │ │ │ │ +698 return static_cast<_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> >(0); │ │ │ │ +699 } │ │ │ │ +700 │ │ │ │ +_7_0_1 static _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _s_i_g_n_a_l_i_n_g___N_a_N() noexcept │ │ │ │ +702 { │ │ │ │ +703 return static_cast<_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> >(0); │ │ │ │ +704 } │ │ │ │ +705 │ │ │ │ +_7_0_6 static _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> _d_e_n_o_r_m___m_i_n() noexcept │ │ │ │ +707 { │ │ │ │ +708 return static_cast<_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_> >(0); │ │ │ │ +709 } │ │ │ │ +710 │ │ │ │ +_7_1_1 static const bool _i_s___i_e_c_5_5_9 = false; │ │ │ │ +_7_1_2 static const bool _i_s___b_o_u_n_d_e_d = true; │ │ │ │ +_7_1_3 static const bool _i_s___m_o_d_u_l_o = true; │ │ │ │ +714 │ │ │ │ +_7_1_5 static const bool _t_r_a_p_s = false; │ │ │ │ +_7_1_6 static const bool _t_i_n_y_n_e_s_s___b_e_f_o_r_e = false; │ │ │ │ +_7_1_7 static const float_round_style _r_o_u_n_d___s_t_y_l_e = round_toward_zero; │ │ │ │ +718 │ │ │ │ +719 }; │ │ │ │ +720 │ │ │ │ +721} │ │ │ │ +722 │ │ │ │ +723_D_U_N_E___D_E_F_I_N_E___H_A_S_H(_D_U_N_E___H_A_S_H___T_E_M_P_L_A_T_E___A_R_G_S(int k),_D_U_N_E___H_A_S_H___T_Y_P_E(_D_u_n_e_:_: │ │ │ │ +_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_k_>)) │ │ │ │ +724 │ │ │ │ +725#endif │ │ │ │ +_h_a_s_h_._h_h │ │ │ │ +Support for calculating hash values of objects. │ │ │ │ +_D_U_N_E___D_E_F_I_N_E___H_A_S_H │ │ │ │ +#define DUNE_DEFINE_HASH(template_args, type) │ │ │ │ +Defines the required struct specialization to make type hashable via Dune:: │ │ │ │ +hash. │ │ │ │ +DDeeffiinniittiioonn hash.hh:100 │ │ │ │ +_D_U_N_E___H_A_S_H___T_Y_P_E │ │ │ │ +#define DUNE_HASH_TYPE(...) │ │ │ │ +Wrapper macro for the type to be hashed in DUNE_DEFINE_HASH. │ │ │ │ +DDeeffiinniittiioonn hash.hh:117 │ │ │ │ +_D_U_N_E___H_A_S_H___T_E_M_P_L_A_T_E___A_R_G_S │ │ │ │ +#define DUNE_HASH_TEMPLATE_ARGS(...) │ │ │ │ +Wrapper macro for the template arguments in DUNE_DEFINE_HASH. │ │ │ │ +DDeeffiinniittiioonn hash.hh:109 │ │ │ │ +_e_x_c_e_p_t_i_o_n_s_._h_h │ │ │ │ +A few common exception classes. │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_/_= │ │ │ │ +bigunsignedint< k > & operator/=(const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:400 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_<_< │ │ │ │ +bigunsignedint< k > operator<<(int i) const │ │ │ │ +left shift │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:464 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_+_= │ │ │ │ +bigunsignedint< k > & operator+=(const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:328 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_^_= │ │ │ │ +bigunsignedint< k > & operator^=(const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:439 │ │ │ │ +_D_u_n_e_:_:_o_p_e_r_a_t_o_r_<_< │ │ │ │ +std::ostream & operator<<(std::ostream &s, const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:301 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_<_= │ │ │ │ +bool operator<=(const bigunsignedint< k > &x) const │ │ │ │ +less than or equal │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:536 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_p_r_i_n_t │ │ │ │ +void print(std::ostream &s) const │ │ │ │ +Print number in hex notation. │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:278 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_< │ │ │ │ +bool operator<(const bigunsignedint< k > &x) const │ │ │ │ +less than │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:527 │ │ │ │ +_D_u_n_e_:_:_o_p_e_r_a_t_o_r_/ │ │ │ │ +bigunsignedint< k > operator/(const bigunsignedint< k > &x, std::uintmax_t y) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:579 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_=_= │ │ │ │ +bool operator==(const bigunsignedint< k > &x) const │ │ │ │ +equal │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:521 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_!_= │ │ │ │ +bool operator!=(const bigunsignedint< k > &x) const │ │ │ │ +not equal │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:513 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t │ │ │ │ +bigunsignedint() │ │ │ │ +Construct uninitialized. │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:220 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_&_= │ │ │ │ +bigunsignedint< k > & operator&=(const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:431 │ │ │ │ +_D_u_n_e_:_:_o_p_e_r_a_t_o_r_- │ │ │ │ +bigunsignedint< k > operator-(const bigunsignedint< k > &x, std::uintmax_t y) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:565 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_>_= │ │ │ │ +bool operator>=(const bigunsignedint< k > &x) const │ │ │ │ +greater or equal │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:551 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_>_> │ │ │ │ +bigunsignedint< k > operator>>(int i) const │ │ │ │ +right shift │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:489 │ │ │ │ +_D_u_n_e_:_:_o_p_e_r_a_t_o_r_+ │ │ │ │ +bigunsignedint< k > operator+(const bigunsignedint< k > &x, std::uintmax_t y) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:558 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_~ │ │ │ │ +bigunsignedint< k > operator~() const │ │ │ │ +bitwise complement │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:455 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_+_+ │ │ │ │ +bigunsignedint< k > & operator++() │ │ │ │ +prefix increment │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:386 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_|_= │ │ │ │ +bigunsignedint< k > & operator|=(const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:447 │ │ │ │ +_D_u_n_e_:_:_o_p_e_r_a_t_o_r_% │ │ │ │ +bigunsignedint< k > operator%(const bigunsignedint< k > &x, std::uintmax_t y) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:586 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_%_= │ │ │ │ +bigunsignedint< k > & operator%=(const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:419 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_t_o_d_o_u_b_l_e │ │ │ │ +double todouble() const │ │ │ │ +Convert to a double. │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:259 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_-_= │ │ │ │ +bigunsignedint< k > & operator-=(const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:342 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_> │ │ │ │ +bool operator>(const bigunsignedint< k > &x) const │ │ │ │ +greater than │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:545 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_*_= │ │ │ │ +bigunsignedint< k > & operator*=(const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:364 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_t_o_u_i_n_t │ │ │ │ +std::uint_least32_t touint() const │ │ │ │ +export to other types │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:253 │ │ │ │ +_D_U_N_E___B_I_N_O_P │ │ │ │ +#define DUNE_BINOP(OP) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:307 │ │ │ │ +_D_U_N_E___T_H_R_O_W │ │ │ │ +#define DUNE_THROW(E,...) │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:314 │ │ │ │ +_D_u_n_e_:_:_o_p_e_r_a_t_o_r_* │ │ │ │ +constexpr decltype(auto) operator*() const │ │ │ │ +Dereferencing operator. │ │ │ │ +DDeeffiinniittiioonn iteratorfacades.hh:1119 │ │ │ │ +_s_t_d │ │ │ │ +STL namespace. │ │ │ │ _D_u_n_e │ │ │ │ Dune namespace │ │ │ │ DDeeffiinniittiioonn alignedallocator.hh:13 │ │ │ │ -_D_u_n_e_:_:_P_r_i_o_r_i_t_y_T_a_g │ │ │ │ -Helper class for tagging priorities. │ │ │ │ -DDeeffiinniittiioonn typeutilities.hh:73 │ │ │ │ -_D_u_n_e_:_:_P_r_i_o_r_i_t_y_T_a_g_:_:_v_a_l_u_e │ │ │ │ -static constexpr std::size_t value │ │ │ │ -DDeeffiinniittiioonn typeutilities.hh:74 │ │ │ │ -_D_u_n_e_:_:_P_r_i_o_r_i_t_y_T_a_g_<_ _0_ _>_:_:_v_a_l_u_e │ │ │ │ -static constexpr std::size_t value │ │ │ │ -DDeeffiinniittiioonn typeutilities.hh:88 │ │ │ │ +_D_u_n_e_:_:_h_a_s_h___r_a_n_g_e │ │ │ │ +std::size_t hash_range(It first, It last) │ │ │ │ +Hashes all elements in the range [first,last) and returns the combined hash. │ │ │ │ +DDeeffiinniittiioonn hash.hh:322 │ │ │ │ +_D_u_n_e_:_:_a_s_s_i_g_n │ │ │ │ +void assign(T &dst, const T &src, bool mask) │ │ │ │ +masked Simd assignment (scalar version) │ │ │ │ +DDeeffiinniittiioonn simd.hh:447 │ │ │ │ +_D_u_n_e_:_:_M_P_I_T_r_a_i_t_s │ │ │ │ +A traits class describing the mapping of types onto MPI_Datatypes. │ │ │ │ +DDeeffiinniittiioonn mpitraits.hh:41 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t │ │ │ │ +Portable very large unsigned integers. │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:74 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_v_e_r_f_l_o_w_m_a_s_k │ │ │ │ +static constexpr int overflowmask │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:83 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_| │ │ │ │ +bigunsignedint< k > operator|(const bigunsignedint< k > &x) const │ │ │ │ +bitwise or │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_h_e_x_d_i_g_i_t_s │ │ │ │ +static constexpr int hexdigits │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:80 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_^ │ │ │ │ +bigunsignedint< k > operator^(const bigunsignedint< k > &x) const │ │ │ │ +bitwise exor │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_% │ │ │ │ +bigunsignedint< k > operator%(const bigunsignedint< k > &x) const │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_n │ │ │ │ +static constexpr int n │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:79 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_b_i_t___w_i_d_t_h │ │ │ │ +friend int bit_width(const bigunsignedint &arg) │ │ │ │ +Bit width. │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:184 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_- │ │ │ │ +bigunsignedint< k > operator-(const bigunsignedint< k > &x) const │ │ │ │ +subtract │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_c_o_m_p_b_i_t_m_a_s_k │ │ │ │ +static constexpr int compbitmask │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:82 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_& │ │ │ │ +bigunsignedint< k > operator&(const bigunsignedint< k > &x) const │ │ │ │ +bitwise and │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_b_i_t_s │ │ │ │ +static constexpr int bits │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:78 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_/ │ │ │ │ +bigunsignedint< k > operator/(const bigunsignedint< k > &x) const │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_o_p_e_r_a_t_o_r_+ │ │ │ │ +bigunsignedint< k > operator+(const bigunsignedint< k > &x) const │ │ │ │ +add │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_h_a_s_h___v_a_l_u_e │ │ │ │ +friend std::size_t hash_value(const bigunsignedint &arg) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:203 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_b_i_t_m_a_s_k │ │ │ │ +static constexpr int bitmask │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:81 │ │ │ │ +_D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_:_:_c_o_u_n_t_l___z_e_r_o │ │ │ │ +friend int countl_zero(const bigunsignedint &arg) │ │ │ │ +Count left zero bits. │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:198 │ │ │ │ +_D_u_n_e_:_:_I_s_N_u_m_b_e_r │ │ │ │ +Whether this type acts as a scalar in the context of (hierarchically blocked) │ │ │ │ +containers. │ │ │ │ +DDeeffiinniittiioonn typetraits.hh:194 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_i_s___i_e_c_5_5_9 │ │ │ │ +static const bool is_iec559 │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:711 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_m_i_n___e_x_p_o_n_e_n_t │ │ │ │ +static const int min_exponent │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:679 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_r_a_d_i_x │ │ │ │ +static const int radix │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:667 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_i_s___s_p_e_c_i_a_l_i_z_e_d │ │ │ │ +static const bool is_specialized │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:644 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_h_a_s___q_u_i_e_t___N_a_N │ │ │ │ +static const bool has_quiet_NaN │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:685 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_i_s___s_i_g_n_e_d │ │ │ │ +static const bool is_signed │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:664 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_i_s___i_n_t_e_g_e_r │ │ │ │ +static const bool is_integer │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:665 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_i_s___b_o_u_n_d_e_d │ │ │ │ +static const bool is_bounded │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:712 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_d_e_n_o_r_m___m_i_n │ │ │ │ +static Dune::bigunsignedint< k > denorm_min() noexcept │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:706 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_i_s___m_o_d_u_l_o │ │ │ │ +static const bool is_modulo │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:713 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_d_i_g_i_t_s │ │ │ │ +static const int digits │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:662 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_t_r_a_p_s │ │ │ │ +static const bool traps │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:715 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_t_i_n_y_n_e_s_s___b_e_f_o_r_e │ │ │ │ +static const bool tinyness_before │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:716 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_m_i_n___e_x_p_o_n_e_n_t_1_0 │ │ │ │ +static const int min_exponent10 │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:680 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_m_a_x │ │ │ │ +static Dune::bigunsignedint< k > max() │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:651 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_m_i_n │ │ │ │ +static Dune::bigunsignedint< k > min() │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:646 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_e_p_s_i_l_o_n │ │ │ │ +static Dune::bigunsignedint< k > epsilon() │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:669 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_r_o_u_n_d___s_t_y_l_e │ │ │ │ +static const float_round_style round_style │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:717 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_h_a_s___d_e_n_o_r_m___l_o_s_s │ │ │ │ +static const bool has_denorm_loss │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:689 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_s_i_g_n_a_l_i_n_g___N_a_N │ │ │ │ +static Dune::bigunsignedint< k > signaling_NaN() noexcept │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:701 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_m_a_x___e_x_p_o_n_e_n_t_1_0 │ │ │ │ +static const int max_exponent10 │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:682 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_i_s___e_x_a_c_t │ │ │ │ +static const bool is_exact │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:666 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_h_a_s___d_e_n_o_r_m │ │ │ │ +static const float_denorm_style has_denorm │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:688 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_h_a_s___s_i_g_n_a_l_i_n_g___N_a_N │ │ │ │ +static const bool has_signaling_NaN │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:686 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_i_n_f_i_n_i_t_y │ │ │ │ +static Dune::bigunsignedint< k > infinity() noexcept │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:691 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_m_a_x___e_x_p_o_n_e_n_t │ │ │ │ +static const int max_exponent │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:681 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_q_u_i_e_t___N_a_N │ │ │ │ +static Dune::bigunsignedint< k > quiet_NaN() noexcept │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:696 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_h_a_s___i_n_f_i_n_i_t_y │ │ │ │ +static const bool has_infinity │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:684 │ │ │ │ +_s_t_d_:_:_n_u_m_e_r_i_c___l_i_m_i_t_s_<_ _D_u_n_e_:_:_b_i_g_u_n_s_i_g_n_e_d_i_n_t_<_ _k_ _>_ _>_:_:_r_o_u_n_d___e_r_r_o_r │ │ │ │ +static Dune::bigunsignedint< k > round_error() │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:674 │ │ │ │ +_D_u_n_e_:_:_E_x_c_e_p_t_i_o_n │ │ │ │ +Base class for Dune-Exceptions. │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:98 │ │ │ │ +_D_u_n_e_:_:_M_a_t_h_E_r_r_o_r │ │ │ │ +Default exception class for mathematical errors. │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:335 │ │ │ │ +_D_u_n_e_:_:_t_y_p_e │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00023.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: treepath.hh File Reference │ │ │ +dune-common: scalarvectorview.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,94 +66,45 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ -Namespaces | │ │ │ -Typedefs | │ │ │ -Functions
│ │ │ -
treepath.hh File Reference
│ │ │ +Namespaces
│ │ │ +
scalarvectorview.hh File Reference
│ │ │
│ │ │
│ │ │ + │ │ │ +

Implements a scalar vector view wrapper around an existing scalar. │ │ │ +More...

│ │ │
#include <cstddef>
│ │ │ -#include <cassert>
│ │ │ #include <type_traits>
│ │ │ -#include <dune/common/documentation.hh>
│ │ │ -#include <dune/common/typetraits.hh>
│ │ │ -#include <dune/common/indices.hh>
│ │ │ -#include <dune/common/hybridmultiindex.hh>
│ │ │ +#include <istream>
│ │ │ +#include <dune/common/densevector.hh>
│ │ │ +#include <dune/common/fvector.hh>
│ │ │ +#include <dune/common/typetraits.hh>
│ │ │ +#include <dune/common/matvectraits.hh>
│ │ │
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ - │ │ │ -

│ │ │ Namespaces

namespace  Dune
 Dune namespace
namespace  Dune::TypeTree
namespace  Dune::TypeTree::Literals
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -

│ │ │ -Typedefs

template<typename... T>
using Dune::TypeTree::TreePath = Dune::HybridMultiIndex<T...>
 A type for representing tree paths that supports both compile time and run time indices.
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │

│ │ │ -Functions

template<typename... T>
│ │ │ -requires (((std::is_integral_v<T> or Dune::IsIntegralConstant<T>::value) && ...))
constexpr auto Dune::TypeTree::treePath (const T &... t)
 Constructs a new TreePath from the given indices.
template<char... digits>
constexpr auto Dune::TypeTree::Literals::operator""_tp ()
 Literal to create treepath.
template<typename... T>
constexpr auto Dune::TypeTree::back (const HybridMultiIndex< T... > &tp) -> decltype(tp.back())
 Returns a copy of the last element of the HybridMultiIndex.
template<typename... T>
constexpr auto Dune::TypeTree::front (const HybridMultiIndex< T... > &tp) -> decltype(tp.front())
 Returns a copy of the first element of the HybridMultiIndex.
template<typename... T>
constexpr HybridMultiIndex< T..., std::size_t > Dune::TypeTree::push_back (const HybridMultiIndex< T... > &tp, std::size_t i)
 Appends a run time index to a HybridMultiIndex.
template<typename... T>
constexpr HybridMultiIndex< std::size_t, T... > Dune::TypeTree::push_front (const HybridMultiIndex< T... > &tp, std::size_t i)
 Prepends a run time index to a HybridMultiIndex.
template<typename I, typename... T>
│ │ │ -requires (sizeof...(T) > 0)
constexpr auto Dune::TypeTree::accumulate_back (const HybridMultiIndex< T... > &tp, I i)
 Hybrid utility that accumulates to the back of a multi-index.
template<typename I, typename... T>
│ │ │ -requires (sizeof...(T) > 0)
constexpr auto Dune::TypeTree::accumulate_front (const HybridMultiIndex< T... > &tp, I i)
 Hybrid utility that accumulates to the front of a multi-index.
template<class... Head, class... Other>
constexpr auto Dune::TypeTree::join (const HybridMultiIndex< Head... > &head, const Other &... tail)
 Join two hybrid multi-indices into one.
template<class... T>
constexpr auto Dune::TypeTree::reverse (const HybridMultiIndex< T... > &tp)
 Reverses the order of the elements in the multi-index.
template<class... T>
│ │ │ -requires (sizeof...(T) > 0)
constexpr auto Dune::TypeTree::pop_front (const HybridMultiIndex< T... > &tp)
 Removes first index on a HybridMultiIndex.
template<class... T>
│ │ │ -requires (sizeof...(T) > 0)
constexpr auto Dune::TypeTree::pop_back (const HybridMultiIndex< T... > &tp)
 Removes last index on a HybridMultiIndex.
│ │ │ -
│ │ │ +

Detailed Description

│ │ │ +

Implements a scalar vector view wrapper around an existing scalar.

│ │ │ +
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,99 +1,25 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ -_N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s | _F_u_n_c_t_i_o_n_s │ │ │ │ -treepath.hh File Reference │ │ │ │ +_N_a_m_e_s_p_a_c_e_s │ │ │ │ +scalarvectorview.hh File Reference │ │ │ │ +_C_o_m_m_o_n » _D_e_n_s_e_ _M_a_t_r_i_x_ _a_n_d_ _V_e_c_t_o_r_ _T_e_m_p_l_a_t_e_ _L_i_b_r_a_r_y │ │ │ │ +Implements a scalar vector view wrapper around an existing scalar. _M_o_r_e_._._. │ │ │ │ #include │ │ │ │ -#include │ │ │ │ #include │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_d_o_c_u_m_e_n_t_a_t_i_o_n_._h_h> │ │ │ │ +#include │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_d_e_n_s_e_v_e_c_t_o_r_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_f_v_e_c_t_o_r_._h_h> │ │ │ │ #include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_m_u_l_t_i_i_n_d_e_x_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_m_a_t_v_e_c_t_r_a_i_t_s_._h_h> │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ NNaammeessppaacceess │ │ │ │ namespace   _D_u_n_e │ │ │ │   Dune namespace │ │ │ │ -namespace   _D_u_n_e_:_:_T_y_p_e_T_r_e_e │ │ │ │ -namespace   _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_L_i_t_e_r_a_l_s │ │ │ │ -TTyyppeeddeeffss │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_T_r_e_e_P_a_t_h = _D_u_n_e_:_:_H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x │ │ │ │ -  A type for representing tree paths that supports both compile time and │ │ │ │ - run time indices. │ │ │ │ -FFuunnccttiioonnss │ │ │ │ -template │ │ │ │ -requires (((std::is_integral_v or _D_u_n_e_:_:_I_s_I_n_t_e_g_r_a_l_C_o_n_s_t_a_n_t::value) && │ │ │ │ -...)) │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_t_r_e_e_P_a_t_h (const T &... │ │ │ │ - t) │ │ │ │ -  Constructs a new _T_r_e_e_P_a_t_h from the │ │ │ │ - given indices. │ │ │ │ -template │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_L_i_t_e_r_a_l_s_:_:_o_p_e_r_a_t_o_r_"_"___t_p │ │ │ │ - () │ │ │ │ -  Literal to create treepath. │ │ │ │ -template │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_b_a_c_k (const │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T... > &tp) - │ │ │ │ - > decltype(tp.back()) │ │ │ │ -  Returns a copy of the last element of │ │ │ │ - the _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x. │ │ │ │ -template │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_f_r_o_n_t (const │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T... > &tp) - │ │ │ │ - > decltype(tp.front()) │ │ │ │ -  Returns a copy of the first element of │ │ │ │ - the _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x. │ │ │ │ -template │ │ │ │ -constexpr _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T..., std:: _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_p_u_s_h___b_a_c_k (const │ │ │ │ - size_t >  _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T... > &tp, std:: │ │ │ │ - size_t i) │ │ │ │ -  Appends a run time index to a │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x. │ │ │ │ -template │ │ │ │ - constexpr _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< std:: _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_p_u_s_h___f_r_o_n_t (const │ │ │ │ - size_t, T... >  _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T... > &tp, std:: │ │ │ │ - size_t i) │ │ │ │ -  Prepends a run time index to a │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x. │ │ │ │ -template │ │ │ │ -requires (sizeof...(T) > 0) │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_a_c_c_u_m_u_l_a_t_e___b_a_c_k (const │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T... > &tp, I i) │ │ │ │ -  _H_y_b_r_i_d utility that accumulates to the │ │ │ │ - back of a multi-index. │ │ │ │ -template │ │ │ │ -requires (sizeof...(T) > 0) │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_a_c_c_u_m_u_l_a_t_e___f_r_o_n_t (const │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T... > &tp, I i) │ │ │ │ -  _H_y_b_r_i_d utility that accumulates to the │ │ │ │ - front of a multi-index. │ │ │ │ -template │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_j_o_i_n (const │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< Head... > &_h_e_a_d, │ │ │ │ - const Other &... _t_a_i_l) │ │ │ │ -  Join two hybrid multi-indices into one. │ │ │ │ -template │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_r_e_v_e_r_s_e (const │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T... > &tp) │ │ │ │ -  Reverses the order of the elements in │ │ │ │ - the multi-index. │ │ │ │ -template │ │ │ │ -requires (sizeof...(T) > 0) │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_p_o_p___f_r_o_n_t (const │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T... > &tp) │ │ │ │ -  Removes first index on a │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x. │ │ │ │ -template │ │ │ │ -requires (sizeof...(T) > 0) │ │ │ │ - constexpr auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_p_o_p___b_a_c_k (const │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x< T... > &tp) │ │ │ │ -  Removes last index on a │ │ │ │ - _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x. │ │ │ │ +********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ +Implements a scalar vector view wrapper around an existing scalar. │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00023_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: treepath.hh Source File │ │ │ +dune-common: scalarvectorview.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,118 +66,204 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
treepath.hh
│ │ │ +
scalarvectorview.hh
│ │ │
│ │ │
│ │ │ -Go to the documentation of this file.
1// -*- tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │ -
2// vi: set et ts=8 sw=2 sts=2:
│ │ │ +Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │ +
2// vi: set et ts=4 sw=2 sts=2:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │ -
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR LGPL-3.0-or-later
│ │ │ -
5
│ │ │ -
6#ifndef DUNE_COMMON_TYPETREE_TREEPATH_HH
│ │ │ -
7#define DUNE_COMMON_TYPETREE_TREEPATH_HH
│ │ │ -
8
│ │ │ -
9#include <cstddef>
│ │ │ -
10#include <cassert>
│ │ │ -
11#include <type_traits>
│ │ │ -
12
│ │ │ - │ │ │ - │ │ │ - │ │ │ +
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ +
5#ifndef DUNE_COMMON_SCALARVECTORVIEW_HH
│ │ │ +
6#define DUNE_COMMON_SCALARVECTORVIEW_HH
│ │ │ +
7
│ │ │ +
8#include <cstddef>
│ │ │ +
9#include <type_traits>
│ │ │ +
10#include <istream>
│ │ │ +
11
│ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │
16
│ │ │ - │ │ │ +
17namespace Dune {
│ │ │
18
│ │ │ -
19
│ │ │ -
20namespace Dune::TypeTree {
│ │ │ -
21
│ │ │ -
25
│ │ │ -
27
│ │ │ -
42 template<typename... T>
│ │ │ - │ │ │ -
44
│ │ │ -
46
│ │ │ -
53 template<typename... T>
│ │ │ -
54 requires (((std::is_integral_v<T> or Dune::IsIntegralConstant<T>::value) && ...))
│ │ │ -
│ │ │ -
55 [[nodiscard]] constexpr auto treePath(const T&... t)
│ │ │ -
56 {
│ │ │ -
57 return HybridMultiIndex(t...);
│ │ │ -
58 }
│ │ │ -
│ │ │ -
59
│ │ │ -
60 // Pull in the free utility function for HybridMultiIndex/TreePath
│ │ │ -
61 // We cannot add forwarding functions of the same name here, since this
│ │ │ -
62 // leads to ambiguous overloads.
│ │ │ -
63 // Unfortunately doxygen ignores documentation for using statements.
│ │ │ -
64 using Dune::back;
│ │ │ -
65 using Dune::front;
│ │ │ -
66 using Dune::push_back;
│ │ │ -
67 using Dune::push_front;
│ │ │ - │ │ │ - │ │ │ -
70 using Dune::join;
│ │ │ -
71 using Dune::reverse;
│ │ │ -
72 using Dune::pop_front;
│ │ │ -
73 using Dune::pop_back;
│ │ │ -
74
│ │ │ -
│ │ │ -
75 inline namespace Literals {
│ │ │ -
76
│ │ │ -
78
│ │ │ -
82 template <char... digits>
│ │ │ -
│ │ │ -
83 constexpr auto operator""_tp()
│ │ │ -
84 {
│ │ │ -
85 using namespace Dune::Indices::Literals;
│ │ │ -
86 return treePath(operator""_ic<digits...>());
│ │ │ -
87 }
│ │ │ -
│ │ │ -
88
│ │ │ -
89 } // end namespace Literals
│ │ │ -
│ │ │ +
19namespace Impl {
│ │ │ +
20
│ │ │ +
24
│ │ │ +
28
│ │ │ +
35 template<class K>
│ │ │ +
36 class ScalarVectorView :
│ │ │ +
37 public DenseVector<ScalarVectorView<K>>
│ │ │ +
38 {
│ │ │ +
39 K* dataP_;
│ │ │ + │ │ │ +
41
│ │ │ +
42 template <class>
│ │ │ +
43 friend class ScalarVectorView;
│ │ │ +
44 public:
│ │ │ +
45
│ │ │ +
47 constexpr static int dimension = 1;
│ │ │ +
48
│ │ │ +
50 using size_type = typename Base::size_type;
│ │ │ +
51
│ │ │ +
53 using reference = std::decay_t<K>&;
│ │ │ +
54
│ │ │ +
56 using const_reference = const K&;
│ │ │ +
57
│ │ │ +
58 //===== construction
│ │ │ +
59
│ │ │ +
61 constexpr ScalarVectorView ()
│ │ │ +
62 : dataP_(nullptr)
│ │ │ +
63 {}
│ │ │ +
64
│ │ │ +
66 ScalarVectorView (K* p) :
│ │ │ +
67 dataP_(p)
│ │ │ +
68 {}
│ │ │ +
69
│ │ │ +
71 ScalarVectorView (const ScalarVectorView &other) :
│ │ │ +
72 Base(),
│ │ │ +
73 dataP_(other.dataP_)
│ │ │ +
74 {}
│ │ │ +
75
│ │ │ +
77 ScalarVectorView (ScalarVectorView &&other) :
│ │ │ +
78 Base(),
│ │ │ +
79 dataP_( other.dataP_ )
│ │ │ +
80 {}
│ │ │ +
81
│ │ │ +
83 ScalarVectorView& operator= (const ScalarVectorView& other)
│ │ │ +
84 {
│ │ │ +
85 assert(dataP_);
│ │ │ +
86 assert(other.dataP_);
│ │ │ +
87 *dataP_ = *(other.dataP_);
│ │ │ +
88 return *this;
│ │ │ +
89 }
│ │ │
90
│ │ │ -
91
│ │ │ -
93
│ │ │ -
94} //namespace Dune::TypeTree
│ │ │ -
95
│ │ │ -
96
│ │ │ -
97
│ │ │ -
98#endif // DUNE_TYPETREE_TREEPATH_HH
│ │ │ -
Traits for type conversions and type information.
│ │ │ - │ │ │ - │ │ │ -
Documentation related stuff.
│ │ │ -
Dune::HybridMultiIndex< T... > TreePath
A type for representing tree paths that supports both compile time and run time indices.
Definition treepath.hh:43
│ │ │ -
constexpr auto treePath(const T &... t)
Constructs a new TreePath from the given indices.
Definition treepath.hh:55
│ │ │ -
HybridMultiIndex(I... i) -> HybridMultiIndex< decltype(Impl::castToHybridSizeT(i))... >
│ │ │ -
constexpr auto join(const HybridMultiIndex< Head... > &head, const Other &... tail)
Join two hybrid multi-indices into one.
Definition hybridmultiindex.hh:355
│ │ │ -
constexpr auto reverse(const HybridMultiIndex< T... > &tp)
Reverses the order of the elements in the multi-index.
Definition hybridmultiindex.hh:361
│ │ │ -
constexpr auto pop_back(const HybridMultiIndex< T... > &tp)
Removes last index on a HybridMultiIndex.
Definition hybridmultiindex.hh:387
│ │ │ -
constexpr auto pop_front(const HybridMultiIndex< T... > &tp)
Removes first index on a HybridMultiIndex.
Definition hybridmultiindex.hh:374
│ │ │ -
constexpr auto accumulate_back(const HybridMultiIndex< T... > &tp, I i)
Hybrid utility that accumulates to the back of a multi-index.
Definition hybridmultiindex.hh:328
│ │ │ -
constexpr auto back(const HybridMultiIndex< T... > &tp) -> decltype(tp.back())
Returns a copy of the last element of the HybridMultiIndex.
Definition hybridmultiindex.hh:225
│ │ │ -
constexpr HybridMultiIndex< std::size_t, T... > push_front(const HybridMultiIndex< T... > &tp, std::size_t i)
Prepends a run time index to a HybridMultiIndex.
Definition hybridmultiindex.hh:284
│ │ │ -
constexpr auto accumulate_front(const HybridMultiIndex< T... > &tp, I i)
Hybrid utility that accumulates to the front of a multi-index.
Definition hybridmultiindex.hh:348
│ │ │ -
constexpr HybridMultiIndex< T..., std::size_t > push_back(const HybridMultiIndex< T... > &tp, std::size_t i)
Appends a run time index to a HybridMultiIndex.
Definition hybridmultiindex.hh:249
│ │ │ -
constexpr auto front(const HybridMultiIndex< T... > &tp) -> decltype(tp.front())
Returns a copy of the first element of the HybridMultiIndex.
Definition hybridmultiindex.hh:238
│ │ │ -
Definition indices.hh:131
│ │ │ -
Definition childaccess.hh:23
│ │ │ -
Definition treepath.hh:75
│ │ │ -
A hybrid multi-index class that supports both compile time and run time indices.
Definition hybridmultiindex.hh:81
│ │ │ -
Check if T is an std::integral_constant<I, i>.
Definition typetraits.hh:384
│ │ │ +
91 template<class KK>
│ │ │ +
92 ScalarVectorView& operator= (const ScalarVectorView<KK>& other)
│ │ │ +
93 {
│ │ │ +
94 assert(dataP_);
│ │ │ +
95 assert(other.dataP_);
│ │ │ +
96 *dataP_ = *(other.dataP_);
│ │ │ +
97 return *this;
│ │ │ +
98 }
│ │ │ +
99
│ │ │ +
101 template<typename T,
│ │ │ +
102 std::enable_if_t<std::is_convertible<T, K>::value, int> = 0>
│ │ │ +
103 inline ScalarVectorView& operator= (const T& k)
│ │ │ +
104 {
│ │ │ +
105 *dataP_ = k;
│ │ │ +
106 return *this;
│ │ │ +
107 }
│ │ │ +
108
│ │ │ +
110 static constexpr size_type size ()
│ │ │ +
111 {
│ │ │ +
112 return 1;
│ │ │ +
113 }
│ │ │ +
114
│ │ │ +
116 K& operator[] ([[maybe_unused]] size_type i)
│ │ │ +
117 {
│ │ │ +
118 DUNE_ASSERT_BOUNDS(i == 0);
│ │ │ +
119 return *dataP_;
│ │ │ +
120 }
│ │ │ +
121
│ │ │ +
123 const K& operator[] ([[maybe_unused]] size_type i) const
│ │ │ +
124 {
│ │ │ +
125 DUNE_ASSERT_BOUNDS(i == 0);
│ │ │ +
126 return *dataP_;
│ │ │ +
127 }
│ │ │ +
128 }; // class ScalarVectorView
│ │ │ +
129
│ │ │ +
130} // namespace Impl
│ │ │ +
131
│ │ │ +
132
│ │ │ +
133 template< class K>
│ │ │ +
134 struct DenseMatVecTraits< Impl::ScalarVectorView<K> >
│ │ │ +
135 {
│ │ │ +
136 using derived_type = Impl::ScalarVectorView<K>;
│ │ │ +
137 using value_type = std::remove_const_t<K>;
│ │ │ +
138 using size_type = std::size_t;
│ │ │ +
139 };
│ │ │ +
140
│ │ │ +
141 template< class K >
│ │ │ +
142 struct FieldTraits< Impl::ScalarVectorView<K> > : public FieldTraits<std::remove_const_t<K>> {};
│ │ │ +
143
│ │ │ +
144 template<class K>
│ │ │ +
145 struct AutonomousValueType<Impl::ScalarVectorView<K>>
│ │ │ +
146 {
│ │ │ +
147 using type = FieldVector<std::remove_const_t<K>,1>;
│ │ │ +
148 };
│ │ │ +
149
│ │ │ +
150namespace Impl {
│ │ │ +
151
│ │ │ +
163 template<class K>
│ │ │ +
164 inline std::istream &operator>> ( std::istream &in, ScalarVectorView<K> &v )
│ │ │ +
165 {
│ │ │ +
166 K w;
│ │ │ +
167 if(in >> w)
│ │ │ +
168 v = w;
│ │ │ +
169 return in;
│ │ │ +
170 }
│ │ │ +
171
│ │ │ +
172
│ │ │ +
174 template<class T,
│ │ │ +
175 std::enable_if_t<IsNumber<T>::value, int> = 0>
│ │ │ +
176 auto asVector(T& t)
│ │ │ +
177 {
│ │ │ +
178 return ScalarVectorView<T>{&t};
│ │ │ +
179 }
│ │ │ +
180
│ │ │ +
182 template<class T,
│ │ │ +
183 std::enable_if_t<IsNumber<T>::value, int> = 0>
│ │ │ +
184 auto asVector(const T& t)
│ │ │ +
185 {
│ │ │ +
186 return ScalarVectorView<const T>{&t};
│ │ │ +
187 }
│ │ │ +
188
│ │ │ +
190 template<class T,
│ │ │ +
191 std::enable_if_t<not IsNumber<T>::value, int> = 0>
│ │ │ +
192 T& asVector(T& t)
│ │ │ +
193 {
│ │ │ +
194 return t;
│ │ │ +
195 }
│ │ │ +
196
│ │ │ +
198 template<class T,
│ │ │ +
199 std::enable_if_t<not IsNumber<T>::value, int> = 0>
│ │ │ +
200 const T& asVector(const T& t)
│ │ │ +
201 {
│ │ │ +
202 return t;
│ │ │ +
203 }
│ │ │ +
204
│ │ │ +
205} // end namespace Impl
│ │ │ +
206
│ │ │ +
207} // end namespace Dune
│ │ │ +
208
│ │ │ +
209#endif // DUNE_COMMON_SCALARVECTORVIEW_HH
│ │ │ +
Implements a vector constructed from a given type representing a field and a compile-time given size.
│ │ │ +
Implements the dense vector interface, with an exchangeable storage class.
│ │ │ +
Documentation of the traits classes you need to write for each implementation of DenseVector or Dense...
│ │ │ +
Traits for type conversions and type information.
│ │ │ +
#define DUNE_ASSERT_BOUNDS(cond)
If DUNE_CHECK_BOUNDS is defined: check if condition cond holds; otherwise, do nothing.
Definition boundschecking.hh:30
│ │ │ +
Dune namespace
Definition alignedallocator.hh:13
│ │ │ +
Traits::size_type size_type
Definition densevector.hh:274
│ │ │ + │ │ │ +
constexpr size_type size() const
Definition densevector.hh:351
│ │ │ +
Definition ftraits.hh:26
│ │ │ +
Definition matvectraits.hh:31
│ │ │ +
Type free of internal references that T can be converted to.
Definition typetraits.hh:509
│ │ │ +
T type
Definition typetraits.hh:509
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,157 +1,218 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ -treepath.hh │ │ │ │ +scalarvectorview.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -1// -*- tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ -2// vi: set et ts=8 sw=2 sts=2: │ │ │ │ +1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ +2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ -4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR │ │ │ │ -LGPL-3.0-or-later │ │ │ │ -5 │ │ │ │ -6#ifndef DUNE_COMMON_TYPETREE_TREEPATH_HH │ │ │ │ -7#define DUNE_COMMON_TYPETREE_TREEPATH_HH │ │ │ │ -8 │ │ │ │ -9#include │ │ │ │ -10#include │ │ │ │ -11#include │ │ │ │ -12 │ │ │ │ -13#include <_d_u_n_e_/_c_o_m_m_o_n_/_d_o_c_u_m_e_n_t_a_t_i_o_n_._h_h> │ │ │ │ +4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ +5#ifndef DUNE_COMMON_SCALARVECTORVIEW_HH │ │ │ │ +6#define DUNE_COMMON_SCALARVECTORVIEW_HH │ │ │ │ +7 │ │ │ │ +8#include │ │ │ │ +9#include │ │ │ │ +10#include │ │ │ │ +11 │ │ │ │ +12#include <_d_u_n_e_/_c_o_m_m_o_n_/_d_e_n_s_e_v_e_c_t_o_r_._h_h> │ │ │ │ +13#include <_d_u_n_e_/_c_o_m_m_o_n_/_f_v_e_c_t_o_r_._h_h> │ │ │ │ 14#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ -15#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ +15#include <_d_u_n_e_/_c_o_m_m_o_n_/_m_a_t_v_e_c_t_r_a_i_t_s_._h_h> │ │ │ │ 16 │ │ │ │ -17#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_m_u_l_t_i_i_n_d_e_x_._h_h> │ │ │ │ +17namespace _D_u_n_e { │ │ │ │ 18 │ │ │ │ -19 │ │ │ │ -20namespace _D_u_n_e_:_:_T_y_p_e_T_r_e_e { │ │ │ │ -21 │ │ │ │ -25 │ │ │ │ -27 │ │ │ │ -42 template │ │ │ │ -_4_3 using _T_r_e_e_P_a_t_h = _D_u_n_e_:_:_H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x; │ │ │ │ -44 │ │ │ │ -46 │ │ │ │ -53 template │ │ │ │ -54 requires (((std::is_integral_v or _D_u_n_e_:_:_I_s_I_n_t_e_g_r_a_l_C_o_n_s_t_a_n_t_<_T_>_:_:_v_a_l_u_e) && │ │ │ │ -...)) │ │ │ │ -_5_5 [[nodiscard]] constexpr auto _t_r_e_e_P_a_t_h(const T&... t) │ │ │ │ -56 { │ │ │ │ -57 return _H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x(t...); │ │ │ │ -58 } │ │ │ │ +19namespace Impl { │ │ │ │ +20 │ │ │ │ +24 │ │ │ │ +28 │ │ │ │ +35 template │ │ │ │ +36 class ScalarVectorView : │ │ │ │ +37 public DenseVector> │ │ │ │ +38 { │ │ │ │ +39 K* dataP_; │ │ │ │ +40 using Base = _D_e_n_s_e_V_e_c_t_o_r_<_S_c_a_l_a_r_V_e_c_t_o_r_V_i_e_w_<_K_>>; │ │ │ │ +41 │ │ │ │ +42 template │ │ │ │ +43 friend class ScalarVectorView; │ │ │ │ +44 public: │ │ │ │ +45 │ │ │ │ +47 constexpr static int dimension = 1; │ │ │ │ +48 │ │ │ │ +50 using size_type = typename _B_a_s_e_:_:_s_i_z_e___t_y_p_e; │ │ │ │ +51 │ │ │ │ +53 using reference = std::decay_t&; │ │ │ │ +54 │ │ │ │ +56 using const_reference = const K&; │ │ │ │ +57 │ │ │ │ +58 //===== construction │ │ │ │ 59 │ │ │ │ -60 // Pull in the free utility function for HybridMultiIndex/TreePath │ │ │ │ -61 // We cannot add forwarding functions of the same name here, since this │ │ │ │ -62 // leads to ambiguous overloads. │ │ │ │ -63 // Unfortunately doxygen ignores documentation for using statements. │ │ │ │ -64 using _D_u_n_e_:_:_b_a_c_k; │ │ │ │ -65 using _D_u_n_e_:_:_f_r_o_n_t; │ │ │ │ -66 using _D_u_n_e_:_:_p_u_s_h___b_a_c_k; │ │ │ │ -67 using _D_u_n_e_:_:_p_u_s_h___f_r_o_n_t; │ │ │ │ -68 using _D_u_n_e_:_:_a_c_c_u_m_u_l_a_t_e___b_a_c_k; │ │ │ │ -69 using _D_u_n_e_:_:_a_c_c_u_m_u_l_a_t_e___f_r_o_n_t; │ │ │ │ -70 using _D_u_n_e_:_:_j_o_i_n; │ │ │ │ -71 using _D_u_n_e_:_:_r_e_v_e_r_s_e; │ │ │ │ -72 using _D_u_n_e_:_:_p_o_p___f_r_o_n_t; │ │ │ │ -73 using _D_u_n_e_:_:_p_o_p___b_a_c_k; │ │ │ │ -74 │ │ │ │ -_7_5 inline namespace _L_i_t_e_r_a_l_s { │ │ │ │ -76 │ │ │ │ -78 │ │ │ │ -82 template │ │ │ │ -_8_3 constexpr auto operator""_tp() │ │ │ │ +61 constexpr ScalarVectorView () │ │ │ │ +62 : dataP_(nullptr) │ │ │ │ +63 {} │ │ │ │ +64 │ │ │ │ +66 ScalarVectorView (K* p) : │ │ │ │ +67 dataP_(p) │ │ │ │ +68 {} │ │ │ │ +69 │ │ │ │ +71 ScalarVectorView (const ScalarVectorView &other) : │ │ │ │ +72 Base(), │ │ │ │ +73 dataP_(other.dataP_) │ │ │ │ +74 {} │ │ │ │ +75 │ │ │ │ +77 ScalarVectorView (ScalarVectorView &&other) : │ │ │ │ +78 Base(), │ │ │ │ +79 dataP_( other.dataP_ ) │ │ │ │ +80 {} │ │ │ │ +81 │ │ │ │ +83 ScalarVectorView& operator= (const ScalarVectorView& other) │ │ │ │ 84 { │ │ │ │ -85 using namespace _D_u_n_e_:_:_I_n_d_i_c_e_s_:_:_L_i_t_e_r_a_l_s; │ │ │ │ -86 return _t_r_e_e_P_a_t_h(operator""_ic()); │ │ │ │ -87 } │ │ │ │ -88 │ │ │ │ -89 } // end namespace Literals │ │ │ │ +85 assert(dataP_); │ │ │ │ +86 assert(other.dataP_); │ │ │ │ +87 *dataP_ = *(other.dataP_); │ │ │ │ +88 return *this; │ │ │ │ +89 } │ │ │ │ 90 │ │ │ │ -91 │ │ │ │ -93 │ │ │ │ -94} //namespace Dune::TypeTree │ │ │ │ -95 │ │ │ │ -96 │ │ │ │ -97 │ │ │ │ -98#endif // DUNE_TYPETREE_TREEPATH_HH │ │ │ │ +91 template │ │ │ │ +92 ScalarVectorView& operator= (const ScalarVectorView& other) │ │ │ │ +93 { │ │ │ │ +94 assert(dataP_); │ │ │ │ +95 assert(other.dataP_); │ │ │ │ +96 *dataP_ = *(other.dataP_); │ │ │ │ +97 return *this; │ │ │ │ +98 } │ │ │ │ +99 │ │ │ │ +101 template::value, int> = 0> │ │ │ │ +103 inline ScalarVectorView& operator= (const T& k) │ │ │ │ +104 { │ │ │ │ +105 *dataP_ = k; │ │ │ │ +106 return *this; │ │ │ │ +107 } │ │ │ │ +108 │ │ │ │ +110 static constexpr size_type _s_i_z_e () │ │ │ │ +111 { │ │ │ │ +112 return 1; │ │ │ │ +113 } │ │ │ │ +114 │ │ │ │ +116 K& operator[] ([[maybe_unused]] size_type i) │ │ │ │ +117 { │ │ │ │ +118 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(i == 0); │ │ │ │ +119 return *dataP_; │ │ │ │ +120 } │ │ │ │ +121 │ │ │ │ +123 const K& operator[] ([[maybe_unused]] size_type i) const │ │ │ │ +124 { │ │ │ │ +125 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(i == 0); │ │ │ │ +126 return *dataP_; │ │ │ │ +127 } │ │ │ │ +128 }; // class ScalarVectorView │ │ │ │ +129 │ │ │ │ +130} // namespace Impl │ │ │ │ +131 │ │ │ │ +132 │ │ │ │ +133 template< class K> │ │ │ │ +134 struct _D_e_n_s_e_M_a_t_V_e_c_T_r_a_i_t_s< Impl::ScalarVectorView > │ │ │ │ +135 { │ │ │ │ +136 using derived_type = Impl::ScalarVectorView; │ │ │ │ +137 using value_type = std::remove_const_t; │ │ │ │ +138 using size_type = std::size_t; │ │ │ │ +139 }; │ │ │ │ +140 │ │ │ │ +141 template< class K > │ │ │ │ +142 struct _F_i_e_l_d_T_r_a_i_t_s< Impl::ScalarVectorView > : public _F_i_e_l_d_T_r_a_i_t_s> {}; │ │ │ │ +143 │ │ │ │ +144 template │ │ │ │ +145 struct _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e> │ │ │ │ +146 { │ │ │ │ +147 using _t_y_p_e = FieldVector,1>; │ │ │ │ +148 }; │ │ │ │ +149 │ │ │ │ +150namespace Impl { │ │ │ │ +151 │ │ │ │ +163 template │ │ │ │ +164 inline std::istream &operator>> ( std::istream &in, ScalarVectorView &v │ │ │ │ +) │ │ │ │ +165 { │ │ │ │ +166 K w; │ │ │ │ +167 if(in >> w) │ │ │ │ +168 v = w; │ │ │ │ +169 return in; │ │ │ │ +170 } │ │ │ │ +171 │ │ │ │ +172 │ │ │ │ +174 template::value, int> = 0> │ │ │ │ +176 auto asVector(T& t) │ │ │ │ +177 { │ │ │ │ +178 return ScalarVectorView{&t}; │ │ │ │ +179 } │ │ │ │ +180 │ │ │ │ +182 template::value, int> = 0> │ │ │ │ +184 auto asVector(const T& t) │ │ │ │ +185 { │ │ │ │ +186 return ScalarVectorView{&t}; │ │ │ │ +187 } │ │ │ │ +188 │ │ │ │ +190 template::value, int> = 0> │ │ │ │ +192 T& asVector(T& t) │ │ │ │ +193 { │ │ │ │ +194 return t; │ │ │ │ +195 } │ │ │ │ +196 │ │ │ │ +198 template::value, int> = 0> │ │ │ │ +200 const T& asVector(const T& t) │ │ │ │ +201 { │ │ │ │ +202 return t; │ │ │ │ +203 } │ │ │ │ +204 │ │ │ │ +205} // end namespace Impl │ │ │ │ +206 │ │ │ │ +207} // end namespace Dune │ │ │ │ +208 │ │ │ │ +209#endif // DUNE_COMMON_SCALARVECTORVIEW_HH │ │ │ │ +_f_v_e_c_t_o_r_._h_h │ │ │ │ +Implements a vector constructed from a given type representing a field and a │ │ │ │ +compile-time given size. │ │ │ │ +_d_e_n_s_e_v_e_c_t_o_r_._h_h │ │ │ │ +Implements the dense vector interface, with an exchangeable storage class. │ │ │ │ +_m_a_t_v_e_c_t_r_a_i_t_s_._h_h │ │ │ │ +Documentation of the traits classes you need to write for each implementation │ │ │ │ +of DenseVector or Dense... │ │ │ │ _t_y_p_e_t_r_a_i_t_s_._h_h │ │ │ │ Traits for type conversions and type information. │ │ │ │ -_i_n_d_i_c_e_s_._h_h │ │ │ │ -_h_y_b_r_i_d_m_u_l_t_i_i_n_d_e_x_._h_h │ │ │ │ -_d_o_c_u_m_e_n_t_a_t_i_o_n_._h_h │ │ │ │ -Documentation related stuff. │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_T_r_e_e_P_a_t_h │ │ │ │ -Dune::HybridMultiIndex< T... > TreePath │ │ │ │ -A type for representing tree paths that supports both compile time and run time │ │ │ │ -indices. │ │ │ │ -DDeeffiinniittiioonn treepath.hh:43 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_t_r_e_e_P_a_t_h │ │ │ │ -constexpr auto treePath(const T &... t) │ │ │ │ -Constructs a new TreePath from the given indices. │ │ │ │ -DDeeffiinniittiioonn treepath.hh:55 │ │ │ │ -_D_u_n_e_:_:_H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x │ │ │ │ -HybridMultiIndex(I... i) -> HybridMultiIndex< decltype(Impl::castToHybridSizeT │ │ │ │ -(i))... > │ │ │ │ -_D_u_n_e_:_:_j_o_i_n │ │ │ │ -constexpr auto join(const HybridMultiIndex< Head... > &head, const Other &... │ │ │ │ -tail) │ │ │ │ -Join two hybrid multi-indices into one. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:355 │ │ │ │ -_D_u_n_e_:_:_r_e_v_e_r_s_e │ │ │ │ -constexpr auto reverse(const HybridMultiIndex< T... > &tp) │ │ │ │ -Reverses the order of the elements in the multi-index. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:361 │ │ │ │ -_D_u_n_e_:_:_p_o_p___b_a_c_k │ │ │ │ -constexpr auto pop_back(const HybridMultiIndex< T... > &tp) │ │ │ │ -Removes last index on a HybridMultiIndex. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:387 │ │ │ │ -_D_u_n_e_:_:_p_o_p___f_r_o_n_t │ │ │ │ -constexpr auto pop_front(const HybridMultiIndex< T... > &tp) │ │ │ │ -Removes first index on a HybridMultiIndex. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:374 │ │ │ │ -_D_u_n_e_:_:_a_c_c_u_m_u_l_a_t_e___b_a_c_k │ │ │ │ -constexpr auto accumulate_back(const HybridMultiIndex< T... > &tp, I i) │ │ │ │ -Hybrid utility that accumulates to the back of a multi-index. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:328 │ │ │ │ -_D_u_n_e_:_:_b_a_c_k │ │ │ │ -constexpr auto back(const HybridMultiIndex< T... > &tp) -> decltype(tp.back()) │ │ │ │ -Returns a copy of the last element of the HybridMultiIndex. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:225 │ │ │ │ -_D_u_n_e_:_:_p_u_s_h___f_r_o_n_t │ │ │ │ -constexpr HybridMultiIndex< std::size_t, T... > push_front(const │ │ │ │ -HybridMultiIndex< T... > &tp, std::size_t i) │ │ │ │ -Prepends a run time index to a HybridMultiIndex. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:284 │ │ │ │ -_D_u_n_e_:_:_a_c_c_u_m_u_l_a_t_e___f_r_o_n_t │ │ │ │ -constexpr auto accumulate_front(const HybridMultiIndex< T... > &tp, I i) │ │ │ │ -Hybrid utility that accumulates to the front of a multi-index. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:348 │ │ │ │ -_D_u_n_e_:_:_p_u_s_h___b_a_c_k │ │ │ │ -constexpr HybridMultiIndex< T..., std::size_t > push_back(const │ │ │ │ -HybridMultiIndex< T... > &tp, std::size_t i) │ │ │ │ -Appends a run time index to a HybridMultiIndex. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:249 │ │ │ │ -_D_u_n_e_:_:_f_r_o_n_t │ │ │ │ -constexpr auto front(const HybridMultiIndex< T... > &tp) -> decltype(tp.front │ │ │ │ -()) │ │ │ │ -Returns a copy of the first element of the HybridMultiIndex. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:238 │ │ │ │ -_D_u_n_e_:_:_I_n_d_i_c_e_s_:_:_L_i_t_e_r_a_l_s │ │ │ │ -DDeeffiinniittiioonn indices.hh:131 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e │ │ │ │ -DDeeffiinniittiioonn childaccess.hh:23 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_L_i_t_e_r_a_l_s │ │ │ │ -DDeeffiinniittiioonn treepath.hh:75 │ │ │ │ -_D_u_n_e_:_:_H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x │ │ │ │ -A hybrid multi-index class that supports both compile time and run time │ │ │ │ -indices. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:81 │ │ │ │ -_D_u_n_e_:_:_I_s_I_n_t_e_g_r_a_l_C_o_n_s_t_a_n_t │ │ │ │ -Check if T is an std::integral_constant. │ │ │ │ -DDeeffiinniittiioonn typetraits.hh:384 │ │ │ │ +_D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S │ │ │ │ +#define DUNE_ASSERT_BOUNDS(cond) │ │ │ │ +If DUNE_CHECK_BOUNDS is defined: check if condition cond holds; otherwise, do │ │ │ │ +nothing. │ │ │ │ +DDeeffiinniittiioonn boundschecking.hh:30 │ │ │ │ +_D_u_n_e │ │ │ │ +Dune namespace │ │ │ │ +DDeeffiinniittiioonn alignedallocator.hh:13 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_V_e_c_t_o_r_<_ _S_c_a_l_a_r_V_e_c_t_o_r_V_i_e_w_<_ _K_ _>_ _>_:_:_s_i_z_e___t_y_p_e │ │ │ │ +Traits::size_type size_type │ │ │ │ +DDeeffiinniittiioonn densevector.hh:274 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_V_e_c_t_o_r_<_ _S_c_a_l_a_r_V_e_c_t_o_r_V_i_e_w_<_ _K_ _>_ _>_:_:_D_e_n_s_e_V_e_c_t_o_r │ │ │ │ +constexpr DenseVector()=default │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_V_e_c_t_o_r_<_ _S_c_a_l_a_r_V_e_c_t_o_r_V_i_e_w_<_ _K_ _>_ _>_:_:_s_i_z_e │ │ │ │ +constexpr size_type size() const │ │ │ │ +DDeeffiinniittiioonn densevector.hh:351 │ │ │ │ +_D_u_n_e_:_:_F_i_e_l_d_T_r_a_i_t_s │ │ │ │ +DDeeffiinniittiioonn ftraits.hh:26 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_V_e_c_T_r_a_i_t_s │ │ │ │ +DDeeffiinniittiioonn matvectraits.hh:31 │ │ │ │ +_D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e │ │ │ │ +Type free of internal references that T can be converted to. │ │ │ │ +DDeeffiinniittiioonn typetraits.hh:509 │ │ │ │ +_D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e_:_:_t_y_p_e │ │ │ │ +T type │ │ │ │ +DDeeffiinniittiioonn typetraits.hh:509 │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00026.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: treecontainer.hh File Reference │ │ │ +dune-common: concepts.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,63 +66,24 @@ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
│ │ │ -Namespaces | │ │ │ -Typedefs | │ │ │ -Functions
│ │ │ -
treecontainer.hh File Reference
│ │ │ +
concepts.hh File Reference
│ │ │
│ │ │
│ │ │ -
#include <type_traits>
│ │ │ -#include <utility>
│ │ │ -#include <functional>
│ │ │ -#include <array>
│ │ │ -#include <dune/common/indices.hh>
│ │ │ -#include <dune/common/hybridutilities.hh>
│ │ │ -#include <dune/common/rangeutilities.hh>
│ │ │ -#include <dune/common/tuplevector.hh>
│ │ │ -#include <dune/common/typetree/nodeconcepts.hh>
│ │ │ -#include <dune/common/typetree/treepath.hh>
│ │ │ -
│ │ │ + │ │ │

Go to the source code of this file.

│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -

│ │ │ -Namespaces

namespace  Dune
 Dune namespace
namespace  Dune::TypeTree
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -

│ │ │ -Typedefs

template<class Value, class Tree>
using Dune::TypeTree::UniformTreeContainer = std::decay_t<decltype(makeTreeContainer<Value>(std::declval<const Tree&>()))>
 Alias to container type generated by makeTreeContainer for given tree type and uniform value type.
template<template< class Node > class LeafToValue, class Tree>
using Dune::TypeTree::TreeContainer = std::decay_t<decltype(makeTreeContainer(std::declval<const Tree&>(), std::declval<Impl::LeafToDefaultConstructibleValue<LeafToValue>>()))>
 Alias to container type generated by makeTreeContainer for give tree type and when using LeafToValue to create values.
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -

│ │ │ -Functions

template<class Tree, class LeafToValue>
auto Dune::TypeTree::makeTreeContainer (const Tree &tree, LeafToValue &&leafToValue)
 Create container having the same structure as the given tree.
template<class Value, class Tree>
auto Dune::TypeTree::makeTreeContainer (const Tree &tree)
 Create container having the same structure as the given tree.
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,46 +1,10 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ -_N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s | _F_u_n_c_t_i_o_n_s │ │ │ │ -treecontainer.hh File Reference │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_r_a_n_g_e_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_u_p_l_e_v_e_c_t_o_r_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_n_o_d_e_c_o_n_c_e_p_t_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_t_r_e_e_p_a_t_h_._h_h> │ │ │ │ +concepts.hh File Reference │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -NNaammeessppaacceess │ │ │ │ -namespace   _D_u_n_e │ │ │ │ -  Dune namespace │ │ │ │ -namespace   _D_u_n_e_:_:_T_y_p_e_T_r_e_e │ │ │ │ -TTyyppeeddeeffss │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_U_n_i_f_o_r_m_T_r_e_e_C_o_n_t_a_i_n_e_r = std::decay_t(std::declval()))> │ │ │ │ -  Alias to container type generated by makeTreeContainer for given tree │ │ │ │ - type and uniform value type. │ │ │ │ -template class LeafToValue, class Tree> │ │ │ │ -using  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_T_r_e_e_C_o_n_t_a_i_n_e_r = std::decay_t(), std::declval>()))> │ │ │ │ -  Alias to container type generated by makeTreeContainer for give tree │ │ │ │ - type and when using LeafToValue to create values. │ │ │ │ -FFuunnccttiioonnss │ │ │ │ -template │ │ │ │ -auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_m_a_k_e_T_r_e_e_C_o_n_t_a_i_n_e_r (const Tree &tree, LeafToValue │ │ │ │ - &&leafToValue) │ │ │ │ -  Create container having the same structure as the given tree. │ │ │ │ -template │ │ │ │ -auto  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_m_a_k_e_T_r_e_e_C_o_n_t_a_i_n_e_r (const Tree &tree) │ │ │ │ -  Create container having the same structure as the given tree. │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00026_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: treecontainer.hh Source File │ │ │ +dune-common: concepts.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,257 +66,49 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
treecontainer.hh
│ │ │ +
concepts.hh
│ │ │
│ │ │
│ │ │ -Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │ -
2// vi: set et ts=4 sw=2 sts=2:
│ │ │ -
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │ -
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR LGPL-3.0-or-later
│ │ │ -
5
│ │ │ -
6#ifndef DUNE_COMMON_TYPETREE_TREECONTAINER_HH
│ │ │ -
7#define DUNE_COMMON_TYPETREE_TREECONTAINER_HH
│ │ │ -
8
│ │ │ -
9#include <type_traits>
│ │ │ -
10#include <utility>
│ │ │ -
11#include <functional>
│ │ │ -
12#include <array>
│ │ │ -
13
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
18
│ │ │ - │ │ │ - │ │ │ -
21
│ │ │ -
22namespace Dune::TypeTree {
│ │ │ -
23
│ │ │ -
24 namespace Impl {
│ │ │ -
25
│ │ │ -
37 template<class LeafToValue>
│ │ │ -
38 class ContainerFactory
│ │ │ -
39 {
│ │ │ -
40 public:
│ │ │ -
41
│ │ │ -
49 ContainerFactory(LeafToValue leafToValue) :
│ │ │ -
50 leafToValue_(leafToValue)
│ │ │ -
51 {}
│ │ │ -
52
│ │ │ -
53 template<class Node>
│ │ │ -
54 requires Dune::TypeTree::Concept::TreeNode<Node>
│ │ │ -
55 auto operator()(const Node& node)
│ │ │ -
56 {
│ │ │ -
57 if constexpr (Dune::TypeTree::Concept::LeafTreeNode<Node>)
│ │ │ -
58 return leafToValue_(node);
│ │ │ -
59 else
│ │ │ -
60 {
│ │ │ -
61 if constexpr (Dune::TypeTree::Concept::UniformInnerTreeNode<Node>)
│ │ │ -
62 {
│ │ │ -
63 if constexpr (Dune::TypeTree::Concept::StaticDegreeInnerTreeNode<Node>)
│ │ │ -
64 {
│ │ │ -
65 return Dune::unpackIntegerSequence([&](auto... indices) {
│ │ │ -
66 return std::array{(*this)(node.child(indices))...};
│ │ │ -
67 }, std::make_index_sequence<std::size_t(Node::degree())>());
│ │ │ -
68 }
│ │ │ -
69 else
│ │ │ -
70 {
│ │ │ -
71 using TransformedChild = decltype((*this)(node.child(0)));
│ │ │ -
72 std::vector<TransformedChild> container;
│ │ │ -
73 container.reserve(node.degree());
│ │ │ -
74 for (std::size_t i = 0; i < node.degree(); ++i)
│ │ │ -
75 container.emplace_back((*this)(node.child(i)));
│ │ │ -
76 return container;
│ │ │ -
77 }
│ │ │ -
78 }
│ │ │ -
79 else
│ │ │ -
80 {
│ │ │ -
81 return Dune::unpackIntegerSequence([&](auto... indices) {
│ │ │ -
82 return Dune::makeTupleVector((*this)(node.child(indices))...);
│ │ │ -
83 }, std::make_index_sequence<std::size_t(Node::degree())>());
│ │ │ -
84 }
│ │ │ -
85 }
│ │ │ -
86 }
│ │ │ -
87
│ │ │ -
88 private:
│ │ │ -
89 LeafToValue leafToValue_;
│ │ │ -
90 };
│ │ │ -
91
│ │ │ -
92
│ │ │ -
93 /*
│ │ │ -
94 * \brief Wrap nested container to provide a VectorBackend
│ │ │ -
95 */
│ │ │ -
96 template<class Container>
│ │ │ -
97 class TreeContainerVectorBackend
│ │ │ -
98 {
│ │ │ -
99 template<class C>
│ │ │ -
100 static constexpr decltype(auto) accessByTreePath(C&& container, const TreePath<>& path)
│ │ │ -
101 {
│ │ │ -
102 return container;
│ │ │ -
103 }
│ │ │ -
104
│ │ │ -
105 template<class C, class... T>
│ │ │ -
106 static constexpr decltype(auto) accessByTreePath(C&& container, const TreePath<T...>& path)
│ │ │ -
107 {
│ │ │ -
108 auto head = path[Dune::Indices::_0];
│ │ │ -
109 auto tailPath = Dune::unpackIntegerSequence([&](auto... i){
│ │ │ -
110 return treePath(path[Dune::index_constant<i+1>{}]...);
│ │ │ -
111 }, std::make_index_sequence<sizeof...(T)-1>());
│ │ │ -
112 return accessByTreePath(container[head], tailPath);
│ │ │ -
113 }
│ │ │ -
114
│ │ │ -
115
│ │ │ -
116 template<class C, class Tree>
│ │ │ -
117 static void recursiveResize(C& container, const Tree& tree)
│ │ │ -
118 {
│ │ │ -
119 if constexpr (not Dune::TypeTree::Concept::LeafTreeNode<Tree>)
│ │ │ -
120 {
│ │ │ -
121 if constexpr (requires { container.resize(0u); })
│ │ │ -
122 container.resize(tree.degree());
│ │ │ -
123 Dune::Hybrid::forEach(Dune::range(tree.degree()), [&](auto i) {
│ │ │ -
124 recursiveResize(container[i], tree.child(i));
│ │ │ -
125 });
│ │ │ -
126 }
│ │ │ -
127 }
│ │ │ -
128
│ │ │ -
129 public:
│ │ │ -
131 TreeContainerVectorBackend(Container&& container) :
│ │ │ -
132 container_(std::move(container))
│ │ │ -
133 {}
│ │ │ -
134
│ │ │ -
136 template <class Tree>
│ │ │ -
137 requires Dune::TypeTree::Concept::TreeNode<Tree>
│ │ │ -
138 TreeContainerVectorBackend(const Tree& tree) :
│ │ │ -
139 TreeContainerVectorBackend()
│ │ │ -
140 {
│ │ │ -
141 this->resize(tree);
│ │ │ -
142 }
│ │ │ -
143
│ │ │ -
145 template <class C = Container,
│ │ │ -
146 std::enable_if_t<std::is_default_constructible_v<C>, bool> = true>
│ │ │ -
147 TreeContainerVectorBackend() :
│ │ │ -
148 container_()
│ │ │ -
149 {}
│ │ │ -
150
│ │ │ -
151 template<class... T>
│ │ │ -
152 decltype(auto) operator[](const TreePath<T...>& path) const
│ │ │ -
153 {
│ │ │ -
154 return accessByTreePath(container_, path);
│ │ │ -
155 }
│ │ │ -
156
│ │ │ -
157 template<class... T>
│ │ │ -
158 decltype(auto) operator[](const TreePath<T...>& path)
│ │ │ -
159 {
│ │ │ -
160 return accessByTreePath(container_, path);
│ │ │ -
161 }
│ │ │ -
162
│ │ │ -
164 template<class Tree>
│ │ │ -
165 requires Dune::TypeTree::Concept::TreeNode<Tree>
│ │ │ -
166 void resize(const Tree& tree)
│ │ │ -
167 {
│ │ │ -
168 recursiveResize(container_, tree);
│ │ │ -
169 }
│ │ │ -
170
│ │ │ -
171 const Container& data() const
│ │ │ -
172 {
│ │ │ -
173 return container_;
│ │ │ -
174 }
│ │ │ -
175
│ │ │ -
176 Container& data()
│ │ │ -
177 {
│ │ │ -
178 return container_;
│ │ │ -
179 }
│ │ │ -
180
│ │ │ -
181 private:
│ │ │ -
182 Container container_;
│ │ │ -
183 };
│ │ │ -
184
│ │ │ -
185 template<class Container>
│ │ │ -
186 auto makeTreeContainerVectorBackend(Container&& container)
│ │ │ -
187 {
│ │ │ -
188 return TreeContainerVectorBackend<std::decay_t<Container>>(std::forward<Container>(container));
│ │ │ -
189 }
│ │ │ -
190
│ │ │ -
191 /*
│ │ │ -
192 * \brief A simple lambda for creating default constructible values from a node
│ │ │ -
193 *
│ │ │ -
194 * This simply returns LeafToValue<Node>{} for a given Node. It's needed
│ │ │ -
195 * because using a lambda expression in a using declaration is not allowed
│ │ │ -
196 * because it's an unevaluated context.
│ │ │ -
197 */
│ │ │ -
198 template<template<class Node> class LeafToValue>
│ │ │ -
199 struct LeafToDefaultConstructibleValue
│ │ │ -
200 {
│ │ │ -
201 template<class Node>
│ │ │ -
202 auto operator()(const Node& node) const
│ │ │ -
203 {
│ │ │ -
204 return LeafToValue<Node>{};
│ │ │ -
205 }
│ │ │ -
206 };
│ │ │ -
207
│ │ │ -
208 } // namespace Impl
│ │ │ -
209
│ │ │ -
213
│ │ │ -
229 template<class Tree, class LeafToValue>
│ │ │ -
│ │ │ -
230 auto makeTreeContainer(const Tree& tree, LeafToValue&& leafToValue)
│ │ │ -
231 {
│ │ │ -
232 auto f = std::ref(leafToValue);
│ │ │ -
233 auto factory = Impl::ContainerFactory<decltype(f)>(f);
│ │ │ -
234 return Impl::makeTreeContainerVectorBackend(factory(tree));
│ │ │ -
235 }
│ │ │ -
│ │ │ -
236
│ │ │ -
252 template<class Value, class Tree>
│ │ │ -
│ │ │ -
253 auto makeTreeContainer(const Tree& tree)
│ │ │ -
254 {
│ │ │ -
255 return makeTreeContainer(tree, [](const auto&) {return Value{};});
│ │ │ -
256 }
│ │ │ -
│ │ │ -
257
│ │ │ -
261 template<class Value, class Tree>
│ │ │ -
262 using UniformTreeContainer = std::decay_t<decltype(makeTreeContainer<Value>(std::declval<const Tree&>()))>;
│ │ │ -
263
│ │ │ -
267 template<template<class Node> class LeafToValue, class Tree>
│ │ │ -
268 using TreeContainer = std::decay_t<decltype(makeTreeContainer(std::declval<const Tree&>(), std::declval<Impl::LeafToDefaultConstructibleValue<LeafToValue>>()))>;
│ │ │ -
269
│ │ │ -
271
│ │ │ -
272} //namespace Dune::TypeTree
│ │ │ -
273
│ │ │ -
274#endif // DUNE_COMMON_TYPETREE_TREECONTAINER_HH
│ │ │ - │ │ │ - │ │ │ -
Provides the TupleVector class that augments std::tuple by operator[].
│ │ │ -
Utilities for reduction like operations on ranges.
│ │ │ - │ │ │ - │ │ │ -
constexpr index_constant< 0 > _0
Compile time index with value 0.
Definition indices.hh:52
│ │ │ -
decltype(auto) constexpr unpackIntegerSequence(F &&f, std::integer_sequence< I, i... > sequence)
Unpack an std::integer_sequence<I,i...> to std::integral_constant<I,i>...
Definition indices.hh:124
│ │ │ -
std::integral_constant< std::size_t, i > index_constant
An index constant with value i.
Definition indices.hh:29
│ │ │ -
static constexpr IntegralRange< std::decay_t< T > > range(T &&from, U &&to) noexcept
free standing function for setting up a range based for loop over an integer range for (auto i: range...
Definition rangeutilities.hh:288
│ │ │ -
constexpr void forEach(Range &&range, F &&f)
Range based for loop.
Definition hybridutilities.hh:261
│ │ │ -
auto makeTreeContainer(const Tree &tree, LeafToValue &&leafToValue)
Create container having the same structure as the given tree.
Definition treecontainer.hh:230
│ │ │ -
std::decay_t< decltype(makeTreeContainer< Value >(std::declval< const Tree & >()))> UniformTreeContainer
Alias to container type generated by makeTreeContainer for given tree type and uniform value type.
Definition treecontainer.hh:262
│ │ │ -
std::decay_t< decltype(makeTreeContainer(std::declval< const Tree & >(), std::declval< Impl::LeafToDefaultConstructibleValue< LeafToValue > >()))> TreeContainer
Alias to container type generated by makeTreeContainer for give tree type and when using LeafToValue ...
Definition treecontainer.hh:268
│ │ │ -
Dune::HybridMultiIndex< T... > TreePath
A type for representing tree paths that supports both compile time and run time indices.
Definition treepath.hh:43
│ │ │ -
constexpr auto treePath(const T &... t)
Constructs a new TreePath from the given indices.
Definition treepath.hh:55
│ │ │ -
constexpr std::integral_constant< T, I0 > head(std::integer_sequence< T, I0, II... >)
For a sequence [head,tail...) return the single head element.
Definition integersequence.hh:53
│ │ │ -
constexpr auto makeTupleVector(T &&... t)
Definition tuplevector.hh:108
│ │ │ -
Definition childaccess.hh:23
│ │ │ +Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │ +
2// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ +
3// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │ +
4// vi: set et ts=4 sw=2 sts=2:
│ │ │ +
5#ifndef DUNE_COMMON_CONCEPTS_HH
│ │ │ +
6#define DUNE_COMMON_CONCEPTS_HH
│ │ │ +
7
│ │ │ +
8// check whether c++20 concept can be used
│ │ │ +
9#if __has_include(<version>) && __has_include(<concepts>)
│ │ │ +
10 #include <version>
│ │ │ +
11 #if __cpp_concepts >= 201907L && __cpp_lib_concepts >= 202002L
│ │ │ +
12 #ifndef DUNE_ENABLE_CONCEPTS
│ │ │ +
13 #define DUNE_ENABLE_CONCEPTS 1
│ │ │ +
14 #endif
│ │ │ +
15 #endif
│ │ │ +
16#endif
│ │ │ +
17
│ │ │ +
18#if DUNE_ENABLE_CONCEPTS
│ │ │ +
19
│ │ │ + │ │ │ + │ │ │ +
22
│ │ │ +
23#endif // DUNE_ENABLE_CONCEPTS
│ │ │ +
24
│ │ │ +
25#endif // DUNE_COMMON_CONCEPTS_HH
│ │ │ + │ │ │ + │ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,299 +1,38 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ -treecontainer.hh │ │ │ │ +concepts.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ -2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ -3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ +1// SPDX-FileCopyrightText: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ -4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR │ │ │ │ -LGPL-3.0-or-later │ │ │ │ -5 │ │ │ │ -6#ifndef DUNE_COMMON_TYPETREE_TREECONTAINER_HH │ │ │ │ -7#define DUNE_COMMON_TYPETREE_TREECONTAINER_HH │ │ │ │ -8 │ │ │ │ -9#include │ │ │ │ -10#include │ │ │ │ -11#include │ │ │ │ -12#include │ │ │ │ -13 │ │ │ │ -14#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ -15#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ -16#include <_d_u_n_e_/_c_o_m_m_o_n_/_r_a_n_g_e_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ -17#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_u_p_l_e_v_e_c_t_o_r_._h_h> │ │ │ │ -18 │ │ │ │ -19#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_n_o_d_e_c_o_n_c_e_p_t_s_._h_h> │ │ │ │ -20#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_t_r_e_e_p_a_t_h_._h_h> │ │ │ │ -21 │ │ │ │ -22namespace _D_u_n_e_:_:_T_y_p_e_T_r_e_e { │ │ │ │ -23 │ │ │ │ -24 namespace Impl { │ │ │ │ -25 │ │ │ │ -37 template │ │ │ │ -38 class ContainerFactory │ │ │ │ -39 { │ │ │ │ -40 public: │ │ │ │ -41 │ │ │ │ -49 ContainerFactory(LeafToValue leafToValue) : │ │ │ │ -50 leafToValue_(leafToValue) │ │ │ │ -51 {} │ │ │ │ -52 │ │ │ │ -53 template │ │ │ │ -54 requires Dune::TypeTree::Concept::TreeNode │ │ │ │ -55 auto operator()(const Node& node) │ │ │ │ -56 { │ │ │ │ -57 if constexpr (Dune::TypeTree::Concept::LeafTreeNode) │ │ │ │ -58 return leafToValue_(node); │ │ │ │ -59 else │ │ │ │ -60 { │ │ │ │ -61 if constexpr (Dune::TypeTree::Concept::UniformInnerTreeNode) │ │ │ │ -62 { │ │ │ │ -63 if constexpr (Dune::TypeTree::Concept::StaticDegreeInnerTreeNode) │ │ │ │ -64 { │ │ │ │ -65 return _D_u_n_e_:_:_u_n_p_a_c_k_I_n_t_e_g_e_r_S_e_q_u_e_n_c_e([&](auto... indices) { │ │ │ │ -66 return std::array{(*this)(node.child(indices))...}; │ │ │ │ -67 }, std::make_index_sequence()); │ │ │ │ -68 } │ │ │ │ -69 else │ │ │ │ -70 { │ │ │ │ -71 using TransformedChild = decltype((*this)(node.child(0))); │ │ │ │ -72 std::vector container; │ │ │ │ -73 container.reserve(node.degree()); │ │ │ │ -74 for (std::size_t i = 0; i < node.degree(); ++i) │ │ │ │ -75 container.emplace_back((*this)(node.child(i))); │ │ │ │ -76 return container; │ │ │ │ -77 } │ │ │ │ -78 } │ │ │ │ -79 else │ │ │ │ -80 { │ │ │ │ -81 return _D_u_n_e_:_:_u_n_p_a_c_k_I_n_t_e_g_e_r_S_e_q_u_e_n_c_e([&](auto... indices) { │ │ │ │ -82 return _D_u_n_e_:_:_m_a_k_e_T_u_p_l_e_V_e_c_t_o_r((*this)(node.child(indices))...); │ │ │ │ -83 }, std::make_index_sequence()); │ │ │ │ -84 } │ │ │ │ -85 } │ │ │ │ -86 } │ │ │ │ -87 │ │ │ │ -88 private: │ │ │ │ -89 LeafToValue leafToValue_; │ │ │ │ -90 }; │ │ │ │ -91 │ │ │ │ -92 │ │ │ │ -93 /* │ │ │ │ -94 * \brief Wrap nested container to provide a VectorBackend │ │ │ │ -95 */ │ │ │ │ -96 template │ │ │ │ -97 class TreeContainerVectorBackend │ │ │ │ -98 { │ │ │ │ -99 template │ │ │ │ -100 static constexpr decltype(auto) accessByTreePath(C&& container, const │ │ │ │ -_T_r_e_e_P_a_t_h_<_>& path) │ │ │ │ -101 { │ │ │ │ -102 return container; │ │ │ │ -103 } │ │ │ │ -104 │ │ │ │ -105 template │ │ │ │ -106 static constexpr decltype(auto) accessByTreePath(C&& container, const │ │ │ │ -_T_r_e_e_P_a_t_h_<_T_._._._>& path) │ │ │ │ -107 { │ │ │ │ -108 auto _h_e_a_d = path[_D_u_n_e_:_:_I_n_d_i_c_e_s_:_:___0]; │ │ │ │ -109 auto tailPath = _D_u_n_e_:_:_u_n_p_a_c_k_I_n_t_e_g_e_r_S_e_q_u_e_n_c_e([&](auto... i){ │ │ │ │ -110 return _t_r_e_e_P_a_t_h(path[_D_u_n_e_:_:_i_n_d_e_x___c_o_n_s_t_a_n_t_<_i_+_1_>{}]...); │ │ │ │ -111 }, std::make_index_sequence()); │ │ │ │ -112 return accessByTreePath(container[_h_e_a_d], tailPath); │ │ │ │ -113 } │ │ │ │ -114 │ │ │ │ -115 │ │ │ │ -116 template │ │ │ │ -117 static void recursiveResize(C& container, const Tree& tree) │ │ │ │ -118 { │ │ │ │ -119 if constexpr (not Dune::TypeTree::Concept::LeafTreeNode) │ │ │ │ -120 { │ │ │ │ -121 if constexpr (requires { container.resize(0u); }) │ │ │ │ -122 container.resize(tree.degree()); │ │ │ │ -123 _D_u_n_e_:_:_H_y_b_r_i_d_:_:_f_o_r_E_a_c_h(_D_u_n_e_:_:_r_a_n_g_e(tree.degree()), [&](auto i) { │ │ │ │ -124 recursiveResize(container[i], tree.child(i)); │ │ │ │ -125 }); │ │ │ │ -126 } │ │ │ │ -127 } │ │ │ │ -128 │ │ │ │ -129 public: │ │ │ │ -131 TreeContainerVectorBackend(Container&& container) : │ │ │ │ -132 container_(std::move(container)) │ │ │ │ -133 {} │ │ │ │ -134 │ │ │ │ -136 template │ │ │ │ -137 requires Dune::TypeTree::Concept::TreeNode │ │ │ │ -138 TreeContainerVectorBackend(const Tree& tree) : │ │ │ │ -139 TreeContainerVectorBackend() │ │ │ │ -140 { │ │ │ │ -141 this->resize(tree); │ │ │ │ -142 } │ │ │ │ -143 │ │ │ │ -145 template , bool> = true> │ │ │ │ -147 TreeContainerVectorBackend() : │ │ │ │ -148 container_() │ │ │ │ -149 {} │ │ │ │ -150 │ │ │ │ -151 template │ │ │ │ -152 decltype(auto) operator[](const _T_r_e_e_P_a_t_h_<_T_._._._>& path) const │ │ │ │ -153 { │ │ │ │ -154 return accessByTreePath(container_, path); │ │ │ │ -155 } │ │ │ │ -156 │ │ │ │ -157 template │ │ │ │ -158 decltype(auto) operator[](const _T_r_e_e_P_a_t_h_<_T_._._._>& path) │ │ │ │ -159 { │ │ │ │ -160 return accessByTreePath(container_, path); │ │ │ │ -161 } │ │ │ │ -162 │ │ │ │ -164 template │ │ │ │ -165 requires Dune::TypeTree::Concept::TreeNode │ │ │ │ -166 void resize(const Tree& tree) │ │ │ │ -167 { │ │ │ │ -168 recursiveResize(container_, tree); │ │ │ │ -169 } │ │ │ │ -170 │ │ │ │ -171 const Container& data() const │ │ │ │ -172 { │ │ │ │ -173 return container_; │ │ │ │ -174 } │ │ │ │ -175 │ │ │ │ -176 Container& data() │ │ │ │ -177 { │ │ │ │ -178 return container_; │ │ │ │ -179 } │ │ │ │ -180 │ │ │ │ -181 private: │ │ │ │ -182 Container container_; │ │ │ │ -183 }; │ │ │ │ -184 │ │ │ │ -185 template │ │ │ │ -186 auto makeTreeContainerVectorBackend(Container&& container) │ │ │ │ -187 { │ │ │ │ -188 return TreeContainerVectorBackend>(std:: │ │ │ │ -forward(container)); │ │ │ │ -189 } │ │ │ │ -190 │ │ │ │ -191 /* │ │ │ │ -192 * \brief A simple lambda for creating default constructible values from a │ │ │ │ -node │ │ │ │ -193 * │ │ │ │ -194 * This simply returns LeafToValue{} for a given Node. It's needed │ │ │ │ -195 * because using a lambda expression in a using declaration is not allowed │ │ │ │ -196 * because it's an unevaluated context. │ │ │ │ -197 */ │ │ │ │ -198 template class LeafToValue> │ │ │ │ -199 struct LeafToDefaultConstructibleValue │ │ │ │ -200 { │ │ │ │ -201 template │ │ │ │ -202 auto operator()(const Node& node) const │ │ │ │ -203 { │ │ │ │ -204 return LeafToValue{}; │ │ │ │ -205 } │ │ │ │ -206 }; │ │ │ │ -207 │ │ │ │ -208 } // namespace Impl │ │ │ │ -209 │ │ │ │ -213 │ │ │ │ -229 template │ │ │ │ -_2_3_0 auto _m_a_k_e_T_r_e_e_C_o_n_t_a_i_n_e_r(const Tree& tree, LeafToValue&& leafToValue) │ │ │ │ -231 { │ │ │ │ -232 auto f = std::ref(leafToValue); │ │ │ │ -233 auto factory = Impl::ContainerFactory(f); │ │ │ │ -234 return Impl::makeTreeContainerVectorBackend(factory(tree)); │ │ │ │ -235 } │ │ │ │ -236 │ │ │ │ -252 template │ │ │ │ -_2_5_3 auto _m_a_k_e_T_r_e_e_C_o_n_t_a_i_n_e_r(const Tree& tree) │ │ │ │ -254 { │ │ │ │ -255 return _m_a_k_e_T_r_e_e_C_o_n_t_a_i_n_e_r(tree, [](const auto&) {return Value{};}); │ │ │ │ -256 } │ │ │ │ -257 │ │ │ │ -261 template │ │ │ │ -_2_6_2 using _U_n_i_f_o_r_m_T_r_e_e_C_o_n_t_a_i_n_e_r = std::decay_t │ │ │ │ -(std::declval()))>; │ │ │ │ -263 │ │ │ │ -267 template class LeafToValue, class Tree> │ │ │ │ -_2_6_8 using _T_r_e_e_C_o_n_t_a_i_n_e_r = std::decay_t(), std::declval>()))>; │ │ │ │ -269 │ │ │ │ -271 │ │ │ │ -272} //namespace Dune::TypeTree │ │ │ │ -273 │ │ │ │ -274#endif // DUNE_COMMON_TYPETREE_TREECONTAINER_HH │ │ │ │ -_t_r_e_e_p_a_t_h_._h_h │ │ │ │ -_n_o_d_e_c_o_n_c_e_p_t_s_._h_h │ │ │ │ -_t_u_p_l_e_v_e_c_t_o_r_._h_h │ │ │ │ -Provides the TupleVector class that augments std::tuple by operator[]. │ │ │ │ -_r_a_n_g_e_u_t_i_l_i_t_i_e_s_._h_h │ │ │ │ -Utilities for reduction like operations on ranges. │ │ │ │ -_i_n_d_i_c_e_s_._h_h │ │ │ │ -_h_y_b_r_i_d_u_t_i_l_i_t_i_e_s_._h_h │ │ │ │ -_D_u_n_e_:_:_I_n_d_i_c_e_s_:_:___0 │ │ │ │ -constexpr index_constant< 0 > _0 │ │ │ │ -Compile time index with value 0. │ │ │ │ -DDeeffiinniittiioonn indices.hh:52 │ │ │ │ -_D_u_n_e_:_:_u_n_p_a_c_k_I_n_t_e_g_e_r_S_e_q_u_e_n_c_e │ │ │ │ -decltype(auto) constexpr unpackIntegerSequence(F &&f, std::integer_sequence< I, │ │ │ │ -i... > sequence) │ │ │ │ -Unpack an std::integer_sequence to std::integral_constant... │ │ │ │ -DDeeffiinniittiioonn indices.hh:124 │ │ │ │ -_D_u_n_e_:_:_i_n_d_e_x___c_o_n_s_t_a_n_t │ │ │ │ -std::integral_constant< std::size_t, i > index_constant │ │ │ │ -An index constant with value i. │ │ │ │ -DDeeffiinniittiioonn indices.hh:29 │ │ │ │ -_D_u_n_e_:_:_r_a_n_g_e │ │ │ │ -static constexpr IntegralRange< std::decay_t< T > > range(T &&from, U &&to) │ │ │ │ -noexcept │ │ │ │ -free standing function for setting up a range based for loop over an integer │ │ │ │ -range for (auto i: range... │ │ │ │ -DDeeffiinniittiioonn rangeutilities.hh:288 │ │ │ │ -_D_u_n_e_:_:_H_y_b_r_i_d_:_:_f_o_r_E_a_c_h │ │ │ │ -constexpr void forEach(Range &&range, F &&f) │ │ │ │ -Range based for loop. │ │ │ │ -DDeeffiinniittiioonn hybridutilities.hh:261 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_m_a_k_e_T_r_e_e_C_o_n_t_a_i_n_e_r │ │ │ │ -auto makeTreeContainer(const Tree &tree, LeafToValue &&leafToValue) │ │ │ │ -Create container having the same structure as the given tree. │ │ │ │ -DDeeffiinniittiioonn treecontainer.hh:230 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_U_n_i_f_o_r_m_T_r_e_e_C_o_n_t_a_i_n_e_r │ │ │ │ -std::decay_t< decltype(makeTreeContainer< Value >(std::declval< const Tree & > │ │ │ │ -()))> UniformTreeContainer │ │ │ │ -Alias to container type generated by makeTreeContainer for given tree type and │ │ │ │ -uniform value type. │ │ │ │ -DDeeffiinniittiioonn treecontainer.hh:262 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_T_r_e_e_C_o_n_t_a_i_n_e_r │ │ │ │ -std::decay_t< decltype(makeTreeContainer(std::declval< const Tree & >(), std:: │ │ │ │ -declval< Impl::LeafToDefaultConstructibleValue< LeafToValue > >()))> │ │ │ │ -TreeContainer │ │ │ │ -Alias to container type generated by makeTreeContainer for give tree type and │ │ │ │ -when using LeafToValue ... │ │ │ │ -DDeeffiinniittiioonn treecontainer.hh:268 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_T_r_e_e_P_a_t_h │ │ │ │ -Dune::HybridMultiIndex< T... > TreePath │ │ │ │ -A type for representing tree paths that supports both compile time and run time │ │ │ │ -indices. │ │ │ │ -DDeeffiinniittiioonn treepath.hh:43 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_t_r_e_e_P_a_t_h │ │ │ │ -constexpr auto treePath(const T &... t) │ │ │ │ -Constructs a new TreePath from the given indices. │ │ │ │ -DDeeffiinniittiioonn treepath.hh:55 │ │ │ │ -_D_u_n_e_:_:_h_e_a_d │ │ │ │ -constexpr std::integral_constant< T, I0 > head(std::integer_sequence< T, I0, │ │ │ │ -II... >) │ │ │ │ -For a sequence [head,tail...) return the single head element. │ │ │ │ -DDeeffiinniittiioonn integersequence.hh:53 │ │ │ │ -_D_u_n_e_:_:_m_a_k_e_T_u_p_l_e_V_e_c_t_o_r │ │ │ │ -constexpr auto makeTupleVector(T &&... t) │ │ │ │ -DDeeffiinniittiioonn tuplevector.hh:108 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e │ │ │ │ -DDeeffiinniittiioonn childaccess.hh:23 │ │ │ │ +2// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ +3// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ +4// vi: set et ts=4 sw=2 sts=2: │ │ │ │ +5#ifndef DUNE_COMMON_CONCEPTS_HH │ │ │ │ +6#define DUNE_COMMON_CONCEPTS_HH │ │ │ │ +7 │ │ │ │ +8// check whether c++20 concept can be used │ │ │ │ +9#if __has_include() && __has_include() │ │ │ │ +10 #include │ │ │ │ +11 #if __cpp_concepts >= 201907L && __cpp_lib_concepts >= 202002L │ │ │ │ +12 #ifndef DUNE_ENABLE_CONCEPTS │ │ │ │ +13 #define DUNE_ENABLE_CONCEPTS 1 │ │ │ │ +14 #endif │ │ │ │ +15 #endif │ │ │ │ +16#endif │ │ │ │ +17 │ │ │ │ +18#if DUNE_ENABLE_CONCEPTS │ │ │ │ +19 │ │ │ │ +20#include <_d_u_n_e_/_c_o_m_m_o_n_/_c_o_n_c_e_p_t_s_/_c_o_n_t_a_i_n_e_r_._h_h> │ │ │ │ +21#include <_d_u_n_e_/_c_o_m_m_o_n_/_c_o_n_c_e_p_t_s_/_h_a_s_h_a_b_l_e_._h_h> │ │ │ │ +22 │ │ │ │ +23#endif // DUNE_ENABLE_CONCEPTS │ │ │ │ +24 │ │ │ │ +25#endif // DUNE_COMMON_CONCEPTS_HH │ │ │ │ +_c_o_n_t_a_i_n_e_r_._h_h │ │ │ │ +_h_a_s_h_a_b_l_e_._h_h │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00029.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: traversal.hh File Reference │ │ │ +dune-common: dynmatrixev.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,57 +66,51 @@ │ │ │
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ Namespaces | │ │ │ Functions
│ │ │ -
traversal.hh File Reference
│ │ │ +
dynmatrixev.hh File Reference
│ │ │
│ │ │
│ │ │ -
#include <utility>
│ │ │ -#include <dune/common/hybridutilities.hh>
│ │ │ -#include <dune/common/indices.hh>
│ │ │ -#include <dune/common/std/type_traits.hh>
│ │ │ -#include <dune/common/typetree/nodeconcepts.hh>
│ │ │ -#include <dune/common/typetree/childaccess.hh>
│ │ │ -#include <dune/common/typetree/treepath.hh>
│ │ │ + │ │ │ +

utility functions to compute eigenvalues for dense matrices. │ │ │ +More...

│ │ │ +
#include <algorithm>
│ │ │ +#include <memory>
│ │ │ +#include <dune-common-config.hh>
│ │ │ +#include "dynmatrix.hh"
│ │ │ +#include "fmatrixev.hh"
│ │ │
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ + │ │ │

│ │ │ Namespaces

namespace  Dune
 Dune namespace
namespace  Dune::TypeTree
namespace  Dune::DynamicMatrixHelp
│ │ │ │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ Functions

template<Concept::InnerTreeNode Tree, class Callable>
constexpr void Dune::TypeTree::forEachChild (Tree &&container, Callable &&at_value)
 Traverse each child of a tree and apply a callable function.
template<class Tree, class PreNodeFunc, class LeafNodeFunc, class PostNodeFunc>
void Dune::TypeTree::forEachNode (Tree &&tree, PreNodeFunc &&preNodeFunc, LeafNodeFunc &&leafNodeFunc, PostNodeFunc &&postNodeFunc)
 Traverse tree and visit each node.
template<Concept::TreeNode Tree, class NodeFunc>
void Dune::TypeTree::forEachNode (Tree &&tree, NodeFunc &&nodeFunc)
 Traverse tree and visit each node.
template<Concept::TreeNode Tree, class LeafFunc>
void Dune::TypeTree::forEachLeafNode (Tree &&tree, LeafFunc &&leafFunc)
 Traverse tree and visit each leaf node.
template<typename K, class C>
static void Dune::DynamicMatrixHelp::eigenValuesNonSym (const DynamicMatrix< K > &matrix, DynamicVector< C > &eigenValues, std::vector< DynamicVector< K > > *eigenVectors=nullptr)
 calculates the eigenvalues of a symmetric field matrix
│ │ │ -
│ │ │ +

Detailed Description

│ │ │ +

utility functions to compute eigenvalues for dense matrices.

│ │ │ +
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,41 +1,29 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ _N_a_m_e_s_p_a_c_e_s | _F_u_n_c_t_i_o_n_s │ │ │ │ -traversal.hh File Reference │ │ │ │ -#include │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_t_d_/_t_y_p_e___t_r_a_i_t_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_n_o_d_e_c_o_n_c_e_p_t_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_c_h_i_l_d_a_c_c_e_s_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_t_r_e_e_p_a_t_h_._h_h> │ │ │ │ +dynmatrixev.hh File Reference │ │ │ │ +utility functions to compute eigenvalues for dense matrices. _M_o_r_e_._._. │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include "_d_y_n_m_a_t_r_i_x_._h_h" │ │ │ │ +#include "_f_m_a_t_r_i_x_e_v_._h_h" │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ NNaammeessppaacceess │ │ │ │ namespace   _D_u_n_e │ │ │ │   Dune namespace │ │ │ │ -namespace   _D_u_n_e_:_:_T_y_p_e_T_r_e_e │ │ │ │ +namespace   _D_u_n_e_:_:_D_y_n_a_m_i_c_M_a_t_r_i_x_H_e_l_p │ │ │ │ FFuunnccttiioonnss │ │ │ │ -template │ │ │ │ -constexpr void  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_f_o_r_E_a_c_h_C_h_i_l_d (Tree &&container, Callable │ │ │ │ - &&at_value) │ │ │ │ -  Traverse each child of a tree and apply a callable function. │ │ │ │ -template │ │ │ │ - void  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_f_o_r_E_a_c_h_N_o_d_e (Tree &&tree, PreNodeFunc │ │ │ │ - &&preNodeFunc, LeafNodeFunc &&leafNodeFunc, PostNodeFunc │ │ │ │ - &&postNodeFunc) │ │ │ │ -  Traverse tree and visit each node. │ │ │ │ -template │ │ │ │ - void  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_f_o_r_E_a_c_h_N_o_d_e (Tree &&tree, NodeFunc &&nodeFunc) │ │ │ │ -  Traverse tree and visit each node. │ │ │ │ -template │ │ │ │ - void  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_f_o_r_E_a_c_h_L_e_a_f_N_o_d_e (Tree &&tree, LeafFunc │ │ │ │ - &&leafFunc) │ │ │ │ -  Traverse tree and visit each leaf node. │ │ │ │ +template │ │ │ │ +static void  _D_u_n_e_:_:_D_y_n_a_m_i_c_M_a_t_r_i_x_H_e_l_p_:_:_e_i_g_e_n_V_a_l_u_e_s_N_o_n_S_y_m (const _D_y_n_a_m_i_c_M_a_t_r_i_x< K │ │ │ │ + > &matrix, _D_y_n_a_m_i_c_V_e_c_t_o_r< C > &eigenValues, std::vector< │ │ │ │ + _D_y_n_a_m_i_c_V_e_c_t_o_r< K > > *eigenVectors=nullptr) │ │ │ │ +  calculates the eigenvalues of a symmetric field matrix │ │ │ │ +********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ +utility functions to compute eigenvalues for dense matrices. │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00029_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: traversal.hh Source File │ │ │ +dune-common: dynmatrixev.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,162 +66,132 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
traversal.hh
│ │ │ +
dynmatrixev.hh
│ │ │
│ │ │
│ │ │ Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │
2// vi: set et ts=4 sw=2 sts=2:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │ -
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR LGPL-3.0-or-later
│ │ │ -
5
│ │ │ -
6#ifndef DUNE_COMMON_TYPETREE_TRAVERSAL_HH
│ │ │ -
7#define DUNE_COMMON_TYPETREE_TRAVERSAL_HH
│ │ │ -
8
│ │ │ -
9#include <utility>
│ │ │ +
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ +
5#ifndef DUNE_DYNMATRIXEIGENVALUES_HH
│ │ │ +
6#define DUNE_DYNMATRIXEIGENVALUES_HH
│ │ │ +
7
│ │ │ +
8#include <algorithm>
│ │ │ +
9#include <memory>
│ │ │
10
│ │ │ - │ │ │ - │ │ │ - │ │ │ -
14
│ │ │ - │ │ │ - │ │ │ - │ │ │ -
18
│ │ │ -
19namespace Dune::TypeTree {
│ │ │ -
20
│ │ │ -
21 namespace Impl {
│ │ │ -
22
│ │ │ -
23 template<class Callable, class Arg0, class Arg1>
│ │ │ -
24 constexpr void invokeWithTwoOrOneArg(Callable&& callable, Arg0&& arg0, Arg1&& arg1) {
│ │ │ -
25 static_assert(std::invocable<Callable&&, Arg0&&, Arg1&&> || std::invocable<Callable&&, Arg0&&>);
│ │ │ -
26 if constexpr (std::invocable<Callable&&, Arg0&&, Arg1&&>)
│ │ │ -
27 callable(arg0, arg1);
│ │ │ -
28 else if constexpr (std::invocable<Callable&&, Arg0&&>)
│ │ │ -
29 callable(arg0);
│ │ │ -
30 };
│ │ │ -
31
│ │ │ -
32 } // namespace Impl
│ │ │ -
33
│ │ │ -
38
│ │ │ -
39#ifndef DOXYGEN
│ │ │ -
41 struct NoOp
│ │ │ -
42 {
│ │ │ -
43 template<class... T>
│ │ │ -
44 constexpr void operator()(T&&...) const { /* do nothing */ }
│ │ │ -
45 };
│ │ │ -
46#endif
│ │ │ -
47
│ │ │ -
66 template<Concept::InnerTreeNode Tree, class Callable>
│ │ │ -
│ │ │ -
67 constexpr void forEachChild(Tree&& container, Callable&& at_value)
│ │ │ -
68 {
│ │ │ - │ │ │ -
70 for (std::size_t i = 0; i != container.degree(); ++i)
│ │ │ -
71 Impl::invokeWithTwoOrOneArg(at_value, std::forward<Tree>(container).child(i), i);
│ │ │ -
72 else
│ │ │ - │ │ │ -
74 [&](auto... i) { (Impl::invokeWithTwoOrOneArg(at_value, std::forward<Tree>(container).child(i), i), ...); },
│ │ │ -
75 std::make_index_sequence<std::remove_cvref_t<Tree>::degree()>{});
│ │ │ -
76 }
│ │ │ -
│ │ │ +
11#include <dune-common-config.hh> // HAVE_LAPACK
│ │ │ +
12
│ │ │ +
13#include "dynmatrix.hh"
│ │ │ +
14#include "fmatrixev.hh"
│ │ │ +
15
│ │ │ +
23
│ │ │ +
24namespace Dune {
│ │ │ +
25
│ │ │ +
│ │ │ + │ │ │ +
27
│ │ │ +
28#if HAVE_LAPACK
│ │ │ +
29 using Dune::FMatrixHelp::eigenValuesNonsymLapackCall;
│ │ │ +
30#endif
│ │ │ +
31
│ │ │ +
40 template <typename K, class C>
│ │ │ +
│ │ │ +
41 static void eigenValuesNonSym(const DynamicMatrix<K>& matrix,
│ │ │ +
42 DynamicVector<C>& eigenValues,
│ │ │ +
43 std::vector<DynamicVector<K>>* eigenVectors = nullptr
│ │ │ +
44 )
│ │ │ +
45 {
│ │ │ +
46
│ │ │ +
47#if HAVE_LAPACK
│ │ │ +
48 {
│ │ │ +
49 const long int N = matrix.rows();
│ │ │ +
50 const char jobvl = 'n';
│ │ │ +
51 const char jobvr = eigenVectors ? 'v' : 'n';
│ │ │ +
52
│ │ │ +
53
│ │ │ +
54 // matrix to put into dgeev
│ │ │ +
55 auto matrixVector = std::make_unique<double[]>(N*N);
│ │ │ +
56
│ │ │ +
57 // copy matrix
│ │ │ +
58 int row = 0;
│ │ │ +
59 for(int i=0; i<N; ++i)
│ │ │ +
60 {
│ │ │ +
61 for(int j=0; j<N; ++j, ++row)
│ │ │ +
62 {
│ │ │ +
63 matrixVector[ row ] = matrix[ i ][ j ];
│ │ │ +
64 }
│ │ │ +
65 }
│ │ │ +
66
│ │ │ +
67 // working memory
│ │ │ +
68 auto eigenR = std::make_unique<double[]>(N);
│ │ │ +
69 auto eigenI = std::make_unique<double[]>(N);
│ │ │ +
70
│ │ │ +
71 const long int lwork = eigenVectors ? 4*N : 3*N;
│ │ │ +
72 auto work = std::make_unique<double[]>(lwork);
│ │ │ +
73 auto vr = eigenVectors ? std::make_unique<double[]>(N*N) : std::unique_ptr<double[]>{};
│ │ │ +
74
│ │ │ +
75 // return value information
│ │ │ +
76 long int info = 0;
│ │ │
77
│ │ │ -
78 namespace Impl {
│ │ │ -
79
│ │ │ -
80 /* Traverse tree and visit each node. The signature is the same
│ │ │ -
81 * as for the public forEachNode function in Dune::Typtree,
│ │ │ -
82 * despite the additionally passed treePath argument. The path
│ │ │ -
83 * passed here is associated to the tree and the relative
│ │ │ -
84 * paths of the children (wrt. to tree) are appended to this.
│ │ │ -
85 * Hence the behavior of the public function is resembled
│ │ │ -
86 * by passing an empty treePath.
│ │ │ -
87 */
│ │ │ -
88 template<Concept::TreeNode Tree, class TreePath, class PreFunc, class LeafFunc, class PostFunc>
│ │ │ -
89 void forEachNode(Tree&& tree, TreePath treePath, PreFunc&& preFunc, LeafFunc&& leafFunc, PostFunc&& postFunc)
│ │ │ -
90 {
│ │ │ -
91 if constexpr(Concept::LeafTreeNode<std::decay_t<Tree>>) {
│ │ │ -
92 Impl::invokeWithTwoOrOneArg(leafFunc, tree, treePath);
│ │ │ -
93 } else {
│ │ │ -
94 Impl::invokeWithTwoOrOneArg(preFunc, tree, treePath);
│ │ │ - │ │ │ -
96 tree,
│ │ │ -
97 [&]<class Child>(Child&& child, auto i) {
│ │ │ -
98 forEachNode(
│ │ │ -
99 std::forward<Child>(child),
│ │ │ - │ │ │ -
101 preFunc,
│ │ │ -
102 leafFunc,
│ │ │ -
103 postFunc
│ │ │ -
104 );
│ │ │ -
105 });
│ │ │ -
106 Impl::invokeWithTwoOrOneArg(postFunc, tree, treePath);
│ │ │ -
107 }
│ │ │ -
108 }
│ │ │ -
109
│ │ │ -
110 } // namespace Impl
│ │ │ -
111
│ │ │ -
112
│ │ │ -
113 // ********************************************************************************
│ │ │ -
114 // Public Interface
│ │ │ -
115 // ********************************************************************************
│ │ │ -
116
│ │ │ -
132 template<class Tree, class PreNodeFunc, class LeafNodeFunc, class PostNodeFunc>
│ │ │ -
│ │ │ -
133 void forEachNode(Tree&& tree, PreNodeFunc&& preNodeFunc, LeafNodeFunc&& leafNodeFunc, PostNodeFunc&& postNodeFunc)
│ │ │ -
134 {
│ │ │ -
135 Impl::forEachNode(tree, treePath(), preNodeFunc, leafNodeFunc, postNodeFunc);
│ │ │ -
136 }
│ │ │ -
│ │ │ -
137
│ │ │ -
147 template<Concept::TreeNode Tree, class NodeFunc>
│ │ │ -
│ │ │ -
148 void forEachNode(Tree&& tree, NodeFunc&& nodeFunc)
│ │ │ -
149 {
│ │ │ -
150 forEachNode(tree, nodeFunc, nodeFunc, NoOp{});
│ │ │ -
151 }
│ │ │ -
│ │ │ -
152
│ │ │ -
162 template<Concept::TreeNode Tree, class LeafFunc>
│ │ │ -
│ │ │ -
163 void forEachLeafNode(Tree&& tree, LeafFunc&& leafFunc)
│ │ │ -
164 {
│ │ │ -
165 forEachNode(tree, NoOp{}, leafFunc, NoOp{});
│ │ │ -
166 }
│ │ │ -
│ │ │ -
167
│ │ │ -
169
│ │ │ -
170} //namespace Dune::TypeTree
│ │ │ -
171
│ │ │ -
172#endif // DUNE_COMMON_TYPETREE_TRAVERSAL_HH
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -
decltype(auto) constexpr unpackIntegerSequence(F &&f, std::integer_sequence< I, i... > sequence)
Unpack an std::integer_sequence<I,i...> to std::integral_constant<I,i>...
Definition indices.hh:124
│ │ │ -
decltype(auto) child(Node &&node, TreePath< Indices... > treePath)
Extracts the child of a node given by a TreePath object.
Definition childaccess.hh:55
│ │ │ -
typename Impl::ChildTraits< Node, indices... >::type Child
Template alias for the type of a child node given by a list of child indices.
Definition childaccess.hh:129
│ │ │ -
void forEachNode(Tree &&tree, PreNodeFunc &&preNodeFunc, LeafNodeFunc &&leafNodeFunc, PostNodeFunc &&postNodeFunc)
Traverse tree and visit each node.
Definition traversal.hh:133
│ │ │ -
constexpr void forEachChild(Tree &&container, Callable &&at_value)
Traverse each child of a tree and apply a callable function.
Definition traversal.hh:67
│ │ │ -
void forEachLeafNode(Tree &&tree, LeafFunc &&leafFunc)
Traverse tree and visit each leaf node.
Definition traversal.hh:163
│ │ │ -
Dune::HybridMultiIndex< T... > TreePath
A type for representing tree paths that supports both compile time and run time indices.
Definition treepath.hh:43
│ │ │ -
constexpr auto treePath(const T &... t)
Constructs a new TreePath from the given indices.
Definition treepath.hh:55
│ │ │ -
Definition childaccess.hh:23
│ │ │ -
constexpr HybridMultiIndex< T..., std::size_t > push_back(const HybridMultiIndex< T... > &tp, std::size_t i)
Appends a run time index to a HybridMultiIndex.
Definition hybridmultiindex.hh:249
│ │ │ -
Model of an inner node of a typetree with uniform nodes accessible via runtime index.
Definition nodeconcepts.hh:52
│ │ │ +
78 // call LAPACK routine (see fmatrixev_ext.cc)
│ │ │ +
79 eigenValuesNonsymLapackCall(&jobvl, &jobvr, &N, matrixVector.get(), &N,
│ │ │ +
80 eigenR.get(), eigenI.get(), nullptr, &N, vr.get(), &N, work.get(),
│ │ │ +
81 &lwork, &info);
│ │ │ +
82
│ │ │ +
83 if( info != 0 )
│ │ │ +
84 {
│ │ │ +
85 std::cerr << "For matrix " << matrix << " eigenvalue calculation failed! " << std::endl;
│ │ │ +
86 DUNE_THROW(InvalidStateException,"eigenValues: Eigenvalue calculation failed!");
│ │ │ +
87 }
│ │ │ +
88
│ │ │ +
89 eigenValues.resize(N);
│ │ │ +
90 for (int i=0; i<N; ++i)
│ │ │ +
91 eigenValues[i] = std::complex<double>(eigenR[i], eigenI[i]);
│ │ │ +
92
│ │ │ +
93 if (eigenVectors) {
│ │ │ +
94 eigenVectors->resize(N);
│ │ │ +
95 for (int i = 0; i < N; ++i) {
│ │ │ +
96 auto& v = (*eigenVectors)[i];
│ │ │ +
97 v.resize(N);
│ │ │ +
98 std::copy(vr.get() + N*i, vr.get() + N*(i+1), &v[0]);
│ │ │ +
99 }
│ │ │ +
100 }
│ │ │ +
101 }
│ │ │ +
102#else // #if HAVE_LAPACK
│ │ │ +
103 DUNE_THROW(NotImplemented,"LAPACK not found!");
│ │ │ +
104#endif
│ │ │ +
105 }
│ │ │ +
│ │ │ +
106 }
│ │ │ +
│ │ │ +
107
│ │ │ +
108}
│ │ │ +
110#endif
│ │ │ +
Eigenvalue computations for the FieldMatrix class.
│ │ │ +
This file implements a dense matrix with dynamic numbers of rows and columns.
│ │ │ +
#define DUNE_THROW(E,...)
Definition exceptions.hh:314
│ │ │ +
Dune namespace
Definition alignedallocator.hh:13
│ │ │ +
Definition dynmatrixev.hh:26
│ │ │ +
static void eigenValuesNonSym(const DynamicMatrix< K > &matrix, DynamicVector< C > &eigenValues, std::vector< DynamicVector< K > > *eigenVectors=nullptr)
calculates the eigenvalues of a symmetric field matrix
Definition dynmatrixev.hh:41
│ │ │ +
constexpr size_type rows() const
number of rows
Definition densematrix.hh:714
│ │ │ +
Construct a matrix with a dynamic size.
Definition dynmatrix.hh:61
│ │ │ +
Construct a vector with a dynamic size.
Definition dynvector.hh:59
│ │ │ +
void resize(size_type n, value_type c=value_type())
Definition dynvector.hh:141
│ │ │ +
Default exception for dummy implementations.
Definition exceptions.hh:357
│ │ │ +
Default exception if a function was called while the object is not in a valid state for that function...
Definition exceptions.hh:375
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,193 +1,145 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ -traversal.hh │ │ │ │ +dynmatrixev.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ 1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ 2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ -4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR │ │ │ │ -LGPL-3.0-or-later │ │ │ │ -5 │ │ │ │ -6#ifndef DUNE_COMMON_TYPETREE_TRAVERSAL_HH │ │ │ │ -7#define DUNE_COMMON_TYPETREE_TRAVERSAL_HH │ │ │ │ -8 │ │ │ │ -9#include │ │ │ │ +4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ +5#ifndef DUNE_DYNMATRIXEIGENVALUES_HH │ │ │ │ +6#define DUNE_DYNMATRIXEIGENVALUES_HH │ │ │ │ +7 │ │ │ │ +8#include │ │ │ │ +9#include │ │ │ │ 10 │ │ │ │ -11#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ -12#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ -13#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_t_d_/_t_y_p_e___t_r_a_i_t_s_._h_h> │ │ │ │ -14 │ │ │ │ -15#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_n_o_d_e_c_o_n_c_e_p_t_s_._h_h> │ │ │ │ -16#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_c_h_i_l_d_a_c_c_e_s_s_._h_h> │ │ │ │ -17#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_t_r_e_e_p_a_t_h_._h_h> │ │ │ │ -18 │ │ │ │ -19namespace _D_u_n_e_:_:_T_y_p_e_T_r_e_e { │ │ │ │ -20 │ │ │ │ -21 namespace Impl { │ │ │ │ -22 │ │ │ │ -23 template │ │ │ │ -24 constexpr void invokeWithTwoOrOneArg(Callable&& callable, Arg0&& arg0, │ │ │ │ -Arg1&& arg1) { │ │ │ │ -25 static_assert(std::invocable || std:: │ │ │ │ -invocable); │ │ │ │ -26 if constexpr (std::invocable) │ │ │ │ -27 callable(arg0, arg1); │ │ │ │ -28 else if constexpr (std::invocable) │ │ │ │ -29 callable(arg0); │ │ │ │ -30 }; │ │ │ │ +11#include // HAVE_LAPACK │ │ │ │ +12 │ │ │ │ +13#include "_d_y_n_m_a_t_r_i_x_._h_h" │ │ │ │ +14#include "_f_m_a_t_r_i_x_e_v_._h_h" │ │ │ │ +15 │ │ │ │ +23 │ │ │ │ +24namespace _D_u_n_e { │ │ │ │ +25 │ │ │ │ +_2_6 namespace _D_y_n_a_m_i_c_M_a_t_r_i_x_H_e_l_p { │ │ │ │ +27 │ │ │ │ +28#if HAVE_LAPACK │ │ │ │ +29 using Dune::FMatrixHelp::eigenValuesNonsymLapackCall; │ │ │ │ +30#endif │ │ │ │ 31 │ │ │ │ -32 } // namespace Impl │ │ │ │ -33 │ │ │ │ -38 │ │ │ │ -39#ifndef DOXYGEN │ │ │ │ -41 struct NoOp │ │ │ │ -42 { │ │ │ │ -43 template │ │ │ │ -44 constexpr void operator()(T&&...) const { /* do nothing */ } │ │ │ │ -45 }; │ │ │ │ -46#endif │ │ │ │ -47 │ │ │ │ -66 template │ │ │ │ -_6_7 constexpr void _f_o_r_E_a_c_h_C_h_i_l_d(Tree&& container, Callable&& at_value) │ │ │ │ -68 { │ │ │ │ -69 if constexpr (_C_o_n_c_e_p_t_:_:_U_n_i_f_o_r_m_I_n_n_e_r_T_r_e_e_N_o_d_e_<_T_r_e_e_>) │ │ │ │ -70 for (std::size_t i = 0; i != container.degree(); ++i) │ │ │ │ -71 Impl::invokeWithTwoOrOneArg(at_value, std::forward(container)._c_h_i_l_d │ │ │ │ -(i), i); │ │ │ │ -72 else │ │ │ │ -73 _D_u_n_e_:_:_u_n_p_a_c_k_I_n_t_e_g_e_r_S_e_q_u_e_n_c_e( │ │ │ │ -74 [&](auto... i) { (Impl::invokeWithTwoOrOneArg(at_value, std::forward │ │ │ │ -(container)._c_h_i_l_d(i), i), ...); }, │ │ │ │ -75 std::make_index_sequence::degree()>{}); │ │ │ │ -76 } │ │ │ │ +40 template │ │ │ │ +_4_1 static void _e_i_g_e_n_V_a_l_u_e_s_N_o_n_S_y_m(const _D_y_n_a_m_i_c_M_a_t_r_i_x_<_K_>& matrix, │ │ │ │ +42 _D_y_n_a_m_i_c_V_e_c_t_o_r_<_C_>& eigenValues, │ │ │ │ +43 std::vector<_D_y_n_a_m_i_c_V_e_c_t_o_r_<_K_>>* eigenVectors = nullptr │ │ │ │ +44 ) │ │ │ │ +45 { │ │ │ │ +46 │ │ │ │ +47#if HAVE_LAPACK │ │ │ │ +48 { │ │ │ │ +49 const long int N = matrix._r_o_w_s(); │ │ │ │ +50 const char jobvl = 'n'; │ │ │ │ +51 const char jobvr = eigenVectors ? 'v' : 'n'; │ │ │ │ +52 │ │ │ │ +53 │ │ │ │ +54 // matrix to put into dgeev │ │ │ │ +55 auto matrixVector = std::make_unique(N*N); │ │ │ │ +56 │ │ │ │ +57 // copy matrix │ │ │ │ +58 int row = 0; │ │ │ │ +59 for(int i=0; i(N); │ │ │ │ +69 auto eigenI = std::make_unique(N); │ │ │ │ +70 │ │ │ │ +71 const long int lwork = eigenVectors ? 4*N : 3*N; │ │ │ │ +72 auto work = std::make_unique(lwork); │ │ │ │ +73 auto vr = eigenVectors ? std::make_unique(N*N) : std:: │ │ │ │ +unique_ptr{}; │ │ │ │ +74 │ │ │ │ +75 // return value information │ │ │ │ +76 long int info = 0; │ │ │ │ 77 │ │ │ │ -78 namespace Impl { │ │ │ │ -79 │ │ │ │ -80 /* Traverse tree and visit each node. The signature is the same │ │ │ │ -81 * as for the public forEachNode function in Dune::Typtree, │ │ │ │ -82 * despite the additionally passed treePath argument. The path │ │ │ │ -83 * passed here is associated to the tree and the relative │ │ │ │ -84 * paths of the children (wrt. to tree) are appended to this. │ │ │ │ -85 * Hence the behavior of the public function is resembled │ │ │ │ -86 * by passing an empty treePath. │ │ │ │ -87 */ │ │ │ │ -88 template │ │ │ │ -89 void forEachNode(Tree&& tree, _T_r_e_e_P_a_t_h _t_r_e_e_P_a_t_h, PreFunc&& preFunc, │ │ │ │ -LeafFunc&& leafFunc, PostFunc&& postFunc) │ │ │ │ -90 { │ │ │ │ -91 if constexpr(Concept::LeafTreeNode>) { │ │ │ │ -92 Impl::invokeWithTwoOrOneArg(leafFunc, tree, _t_r_e_e_P_a_t_h); │ │ │ │ -93 } else { │ │ │ │ -94 Impl::invokeWithTwoOrOneArg(preFunc, tree, _t_r_e_e_P_a_t_h); │ │ │ │ -95 _f_o_r_E_a_c_h_C_h_i_l_d( │ │ │ │ -96 tree, │ │ │ │ -97 [&](_C_h_i_l_d&& _c_h_i_l_d, auto i) { │ │ │ │ -98 forEachNode( │ │ │ │ -99 std::forward(_c_h_i_l_d), │ │ │ │ -100 _p_u_s_h___b_a_c_k(_t_r_e_e_P_a_t_h, i), │ │ │ │ -101 preFunc, │ │ │ │ -102 leafFunc, │ │ │ │ -103 postFunc │ │ │ │ -104 ); │ │ │ │ -105 }); │ │ │ │ -106 Impl::invokeWithTwoOrOneArg(postFunc, tree, _t_r_e_e_P_a_t_h); │ │ │ │ -107 } │ │ │ │ -108 } │ │ │ │ -109 │ │ │ │ -110 } // namespace Impl │ │ │ │ -111 │ │ │ │ -112 │ │ │ │ -113 / │ │ │ │ -/ │ │ │ │ -******************************************************************************** │ │ │ │ -114 // Public Interface │ │ │ │ -115 / │ │ │ │ -/ │ │ │ │ -******************************************************************************** │ │ │ │ -116 │ │ │ │ -132 template │ │ │ │ -_1_3_3 void _f_o_r_E_a_c_h_N_o_d_e(Tree&& tree, PreNodeFunc&& preNodeFunc, LeafNodeFunc&& │ │ │ │ -leafNodeFunc, PostNodeFunc&& postNodeFunc) │ │ │ │ -134 { │ │ │ │ -135 Impl::forEachNode(tree, _t_r_e_e_P_a_t_h(), preNodeFunc, leafNodeFunc, │ │ │ │ -postNodeFunc); │ │ │ │ -136 } │ │ │ │ -137 │ │ │ │ -147 template │ │ │ │ -_1_4_8 void _f_o_r_E_a_c_h_N_o_d_e(Tree&& tree, NodeFunc&& nodeFunc) │ │ │ │ -149 { │ │ │ │ -150 _f_o_r_E_a_c_h_N_o_d_e(tree, nodeFunc, nodeFunc, NoOp{}); │ │ │ │ -151 } │ │ │ │ -152 │ │ │ │ -162 template │ │ │ │ -_1_6_3 void _f_o_r_E_a_c_h_L_e_a_f_N_o_d_e(Tree&& tree, LeafFunc&& leafFunc) │ │ │ │ -164 { │ │ │ │ -165 _f_o_r_E_a_c_h_N_o_d_e(tree, NoOp{}, leafFunc, NoOp{}); │ │ │ │ -166 } │ │ │ │ -167 │ │ │ │ -169 │ │ │ │ -170} //namespace Dune::TypeTree │ │ │ │ -171 │ │ │ │ -172#endif // DUNE_COMMON_TYPETREE_TRAVERSAL_HH │ │ │ │ -_t_r_e_e_p_a_t_h_._h_h │ │ │ │ -_n_o_d_e_c_o_n_c_e_p_t_s_._h_h │ │ │ │ -_c_h_i_l_d_a_c_c_e_s_s_._h_h │ │ │ │ -_t_y_p_e___t_r_a_i_t_s_._h_h │ │ │ │ -_i_n_d_i_c_e_s_._h_h │ │ │ │ -_h_y_b_r_i_d_u_t_i_l_i_t_i_e_s_._h_h │ │ │ │ -_D_u_n_e_:_:_u_n_p_a_c_k_I_n_t_e_g_e_r_S_e_q_u_e_n_c_e │ │ │ │ -decltype(auto) constexpr unpackIntegerSequence(F &&f, std::integer_sequence< I, │ │ │ │ -i... > sequence) │ │ │ │ -Unpack an std::integer_sequence to std::integral_constant... │ │ │ │ -DDeeffiinniittiioonn indices.hh:124 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_c_h_i_l_d │ │ │ │ -decltype(auto) child(Node &&node, TreePath< Indices... > treePath) │ │ │ │ -Extracts the child of a node given by a TreePath object. │ │ │ │ -DDeeffiinniittiioonn childaccess.hh:55 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_h_i_l_d │ │ │ │ -typename Impl::ChildTraits< Node, indices... >::type Child │ │ │ │ -Template alias for the type of a child node given by a list of child indices. │ │ │ │ -DDeeffiinniittiioonn childaccess.hh:129 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_f_o_r_E_a_c_h_N_o_d_e │ │ │ │ -void forEachNode(Tree &&tree, PreNodeFunc &&preNodeFunc, LeafNodeFunc │ │ │ │ -&&leafNodeFunc, PostNodeFunc &&postNodeFunc) │ │ │ │ -Traverse tree and visit each node. │ │ │ │ -DDeeffiinniittiioonn traversal.hh:133 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_f_o_r_E_a_c_h_C_h_i_l_d │ │ │ │ -constexpr void forEachChild(Tree &&container, Callable &&at_value) │ │ │ │ -Traverse each child of a tree and apply a callable function. │ │ │ │ -DDeeffiinniittiioonn traversal.hh:67 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_f_o_r_E_a_c_h_L_e_a_f_N_o_d_e │ │ │ │ -void forEachLeafNode(Tree &&tree, LeafFunc &&leafFunc) │ │ │ │ -Traverse tree and visit each leaf node. │ │ │ │ -DDeeffiinniittiioonn traversal.hh:163 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_T_r_e_e_P_a_t_h │ │ │ │ -Dune::HybridMultiIndex< T... > TreePath │ │ │ │ -A type for representing tree paths that supports both compile time and run time │ │ │ │ -indices. │ │ │ │ -DDeeffiinniittiioonn treepath.hh:43 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_t_r_e_e_P_a_t_h │ │ │ │ -constexpr auto treePath(const T &... t) │ │ │ │ -Constructs a new TreePath from the given indices. │ │ │ │ -DDeeffiinniittiioonn treepath.hh:55 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e │ │ │ │ -DDeeffiinniittiioonn childaccess.hh:23 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_p_u_s_h___b_a_c_k │ │ │ │ -constexpr HybridMultiIndex< T..., std::size_t > push_back(const │ │ │ │ -HybridMultiIndex< T... > &tp, std::size_t i) │ │ │ │ -Appends a run time index to a HybridMultiIndex. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:249 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_U_n_i_f_o_r_m_I_n_n_e_r_T_r_e_e_N_o_d_e │ │ │ │ -Model of an inner node of a typetree with uniform nodes accessible via runtime │ │ │ │ -index. │ │ │ │ -DDeeffiinniittiioonn nodeconcepts.hh:52 │ │ │ │ +78 // call LAPACK routine (see fmatrixev_ext.cc) │ │ │ │ +79 eigenValuesNonsymLapackCall(&jobvl, &jobvr, &N, matrixVector.get(), &N, │ │ │ │ +80 eigenR.get(), eigenI.get(), nullptr, &N, vr.get(), &N, work.get(), │ │ │ │ +81 &lwork, &info); │ │ │ │ +82 │ │ │ │ +83 if( info != 0 ) │ │ │ │ +84 { │ │ │ │ +85 std::cerr << "For matrix " << matrix << " eigenvalue calculation failed! " │ │ │ │ +<< std::endl; │ │ │ │ +86 _D_U_N_E___T_H_R_O_W(_I_n_v_a_l_i_d_S_t_a_t_e_E_x_c_e_p_t_i_o_n,"eigenValues: Eigenvalue calculation │ │ │ │ +failed!"); │ │ │ │ +87 } │ │ │ │ +88 │ │ │ │ +89 eigenValues._r_e_s_i_z_e(N); │ │ │ │ +90 for (int i=0; i(eigenR[i], eigenI[i]); │ │ │ │ +92 │ │ │ │ +93 if (eigenVectors) { │ │ │ │ +94 eigenVectors->resize(N); │ │ │ │ +95 for (int i = 0; i < N; ++i) { │ │ │ │ +96 auto& v = (*eigenVectors)[i]; │ │ │ │ +97 v.resize(N); │ │ │ │ +98 std::copy(vr.get() + N*i, vr.get() + N*(i+1), &v[0]); │ │ │ │ +99 } │ │ │ │ +100 } │ │ │ │ +101 } │ │ │ │ +102#else // #if HAVE_LAPACK │ │ │ │ +103 _D_U_N_E___T_H_R_O_W(_N_o_t_I_m_p_l_e_m_e_n_t_e_d,"LAPACK not found!"); │ │ │ │ +104#endif │ │ │ │ +105 } │ │ │ │ +106 } │ │ │ │ +107 │ │ │ │ +108} │ │ │ │ +110#endif │ │ │ │ +_f_m_a_t_r_i_x_e_v_._h_h │ │ │ │ +Eigenvalue computations for the FieldMatrix class. │ │ │ │ +_d_y_n_m_a_t_r_i_x_._h_h │ │ │ │ +This file implements a dense matrix with dynamic numbers of rows and columns. │ │ │ │ +_D_U_N_E___T_H_R_O_W │ │ │ │ +#define DUNE_THROW(E,...) │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:314 │ │ │ │ +_D_u_n_e │ │ │ │ +Dune namespace │ │ │ │ +DDeeffiinniittiioonn alignedallocator.hh:13 │ │ │ │ +_D_u_n_e_:_:_D_y_n_a_m_i_c_M_a_t_r_i_x_H_e_l_p │ │ │ │ +DDeeffiinniittiioonn dynmatrixev.hh:26 │ │ │ │ +_D_u_n_e_:_:_D_y_n_a_m_i_c_M_a_t_r_i_x_H_e_l_p_:_:_e_i_g_e_n_V_a_l_u_e_s_N_o_n_S_y_m │ │ │ │ +static void eigenValuesNonSym(const DynamicMatrix< K > &matrix, DynamicVector< │ │ │ │ +C > &eigenValues, std::vector< DynamicVector< K > > *eigenVectors=nullptr) │ │ │ │ +calculates the eigenvalues of a symmetric field matrix │ │ │ │ +DDeeffiinniittiioonn dynmatrixev.hh:41 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_r_o_w_s │ │ │ │ +constexpr size_type rows() const │ │ │ │ +number of rows │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:714 │ │ │ │ +_D_u_n_e_:_:_D_y_n_a_m_i_c_M_a_t_r_i_x │ │ │ │ +Construct a matrix with a dynamic size. │ │ │ │ +DDeeffiinniittiioonn dynmatrix.hh:61 │ │ │ │ +_D_u_n_e_:_:_D_y_n_a_m_i_c_V_e_c_t_o_r │ │ │ │ +Construct a vector with a dynamic size. │ │ │ │ +DDeeffiinniittiioonn dynvector.hh:59 │ │ │ │ +_D_u_n_e_:_:_D_y_n_a_m_i_c_V_e_c_t_o_r_:_:_r_e_s_i_z_e │ │ │ │ +void resize(size_type n, value_type c=value_type()) │ │ │ │ +DDeeffiinniittiioonn dynvector.hh:141 │ │ │ │ +_D_u_n_e_:_:_N_o_t_I_m_p_l_e_m_e_n_t_e_d │ │ │ │ +Default exception for dummy implementations. │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:357 │ │ │ │ +_D_u_n_e_:_:_I_n_v_a_l_i_d_S_t_a_t_e_E_x_c_e_p_t_i_o_n │ │ │ │ +Default exception if a function was called while the object is not in a valid │ │ │ │ +state for that function... │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:375 │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00032.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: nodeconcepts.hh File Reference │ │ │ +dune-common: referencehelper.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,52 +66,59 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ Namespaces | │ │ │ -Concepts
│ │ │ -
nodeconcepts.hh File Reference
│ │ │ +Typedefs | │ │ │ +Functions | │ │ │ +Variables
│ │ │ +
referencehelper.hh File Reference
│ │ │
│ │ │
│ │ │ -
#include <dune/common/typetraits.hh>
│ │ │ -#include <dune/common/indices.hh>
│ │ │ -#include <concepts>
│ │ │ -#include <type_traits>
│ │ │ -#include <utility>
│ │ │ +
#include <type_traits>
│ │ │ +#include <functional>
│ │ │
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ - │ │ │

│ │ │ Namespaces

namespace  Dune
 Dune namespace
namespace  Dune::TypeTree
namespace  Dune::TypeTree::Concept
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ +

│ │ │ -Concepts

concept  Dune::TypeTree::Concept::TreeNode
 Model of a node of a typetree.
concept  Dune::TypeTree::Concept::StaticDegreeInnerTreeNode
 Model of an inner node of a typetree with compile time known degree and child access via index_constant.
concept  Dune::TypeTree::Concept::UniformInnerTreeNode
 Model of an inner node of a typetree with uniform nodes accessible via runtime index.
concept  Dune::TypeTree::Concept::InnerTreeNode
 Model of an inner tree node of a typetree (either static degree or uniform).
concept  Dune::TypeTree::Concept::LeafTreeNode
 Model of a leaf tree node of a typetree.

│ │ │ +Typedefs

template<class T>
using Dune::ResolveRef_t = std::remove_reference_t<decltype(Dune::resolveRef(std::declval<T&>()))>
 Type trait to resolve std::reference_wrapper.
│ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ +

│ │ │ +Functions

template<class T>
constexpr T & Dune::resolveRef (T &gf) noexcept
 Helper function to resolve std::reference_wrapper.
template<class T>
const auto & Dune::resolveRef (T &&gf)=delete
template<class T>
constexpr T & Dune::resolveRef (std::reference_wrapper< T > gf) noexcept
 Helper function to resolve std::reference_wrapper.
│ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ +Variables

template<class T>
constexpr bool Dune::IsReferenceWrapper_v = Impl::IsReferenceWrapper<T>::value
 Helper to detect if given type is a std::reference_wrapper.
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ ├── html2text {} │ │ │ │ @@ -1,36 +1,34 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ -_N_a_m_e_s_p_a_c_e_s | _C_o_n_c_e_p_t_s │ │ │ │ -nodeconcepts.hh File Reference │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ -#include │ │ │ │ +_N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s | _F_u_n_c_t_i_o_n_s | _V_a_r_i_a_b_l_e_s │ │ │ │ +referencehelper.hh File Reference │ │ │ │ #include │ │ │ │ -#include │ │ │ │ +#include │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ NNaammeessppaacceess │ │ │ │ namespace   _D_u_n_e │ │ │ │   Dune namespace │ │ │ │ -namespace   _D_u_n_e_:_:_T_y_p_e_T_r_e_e │ │ │ │ -namespace   _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t │ │ │ │ -CCoonncceeppttss │ │ │ │ -concept   _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_T_r_e_e_N_o_d_e │ │ │ │ -  Model of a node of a typetree. │ │ │ │ -concept   _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_S_t_a_t_i_c_D_e_g_r_e_e_I_n_n_e_r_T_r_e_e_N_o_d_e │ │ │ │ -  Model of an inner node of a typetree with compile time known degree │ │ │ │ - and child access via index_constant. │ │ │ │ -concept   _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_U_n_i_f_o_r_m_I_n_n_e_r_T_r_e_e_N_o_d_e │ │ │ │ -  Model of an inner node of a typetree with uniform nodes accessible │ │ │ │ - via runtime index. │ │ │ │ -concept   _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_I_n_n_e_r_T_r_e_e_N_o_d_e │ │ │ │ -  Model of an inner tree node of a typetree (either static degree or │ │ │ │ - uniform). │ │ │ │ -concept   _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_L_e_a_f_T_r_e_e_N_o_d_e │ │ │ │ -  Model of a leaf tree node of a typetree. │ │ │ │ +TTyyppeeddeeffss │ │ │ │ +template │ │ │ │ +using  _D_u_n_e_:_:_R_e_s_o_l_v_e_R_e_f___t = std::remove_reference_t()))> │ │ │ │ +  Type trait to resolve std::reference_wrapper. │ │ │ │ +FFuunnccttiioonnss │ │ │ │ +template │ │ │ │ +constexpr T &  _D_u_n_e_:_:_r_e_s_o_l_v_e_R_e_f (T &gf) noexcept │ │ │ │ +  Helper function to resolve std::reference_wrapper. │ │ │ │ +template │ │ │ │ + const auto &  _D_u_n_e_:_:_r_e_s_o_l_v_e_R_e_f (T &&gf)=delete │ │ │ │ +template │ │ │ │ +constexpr T &  _D_u_n_e_:_:_r_e_s_o_l_v_e_R_e_f (std::reference_wrapper< T > gf) noexcept │ │ │ │ +  Helper function to resolve std::reference_wrapper. │ │ │ │ +VVaarriiaabblleess │ │ │ │ +template │ │ │ │ +constexpr bool  _D_u_n_e_:_:_I_s_R_e_f_e_r_e_n_c_e_W_r_a_p_p_e_r___v = Impl::IsReferenceWrapper::value │ │ │ │ +  Helper to detect if given type is a std::reference_wrapper. │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00032_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: nodeconcepts.hh Source File │ │ │ +dune-common: referencehelper.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,102 +66,96 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
nodeconcepts.hh
│ │ │ +
referencehelper.hh
│ │ │
│ │ │
│ │ │ Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │
2// vi: set et ts=4 sw=2 sts=2:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │ -
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR LGPL-3.0-or-later
│ │ │ -
5
│ │ │ -
6#ifndef DUNE_COMMON_TYPETREE_NODECONCEPTS_HH
│ │ │ -
7#define DUNE_COMMON_TYPETREE_NODECONCEPTS_HH
│ │ │ -
8
│ │ │ - │ │ │ - │ │ │ +
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ +
5#ifndef DUNE_COMMON_REFERENCE_HELPER_HH
│ │ │ +
6#define DUNE_COMMON_REFERENCE_HELPER_HH
│ │ │ +
7
│ │ │ +
8#include <type_traits>
│ │ │ +
9#include <functional>
│ │ │ +
10
│ │ │
11
│ │ │ -
12#include <concepts>
│ │ │ -
13#include <type_traits>
│ │ │ -
14#include <utility>
│ │ │ -
15
│ │ │ +
12
│ │ │ +
13namespace Dune {
│ │ │ +
14
│ │ │ +
15namespace Impl {
│ │ │
16
│ │ │ -
│ │ │ - │ │ │ -
18
│ │ │ -
19 namespace Impl {
│ │ │ -
20
│ │ │ -
21 template<class Node>
│ │ │ -
22 concept HasConstExprDegree = requires(Node node)
│ │ │ -
23 {
│ │ │ -
24 std::bool_constant<(std::remove_cvref_t<Node>::degree(), true)>();
│ │ │ -
25 };
│ │ │ -
26
│ │ │ -
27 template<class Node>
│ │ │ -
28 concept HasPositiveDegree = ( std::remove_cvref_t<Node>::degree() > 0);
│ │ │ -
29
│ │ │ -
30 }
│ │ │ -
31
│ │ │ -
33 template<class Node>
│ │ │ -
│ │ │ -
34 concept TreeNode = requires(Node node)
│ │ │ -
35 {
│ │ │ -
36 { std::as_const(node).degree() } -> std::convertible_to<std::size_t>;
│ │ │ -
37 };
│ │ │ -
│ │ │ -
38
│ │ │ -
40 template<class Node>
│ │ │ -
│ │ │ -
41 concept StaticDegreeInnerTreeNode = TreeNode<Node> && requires(Node node)
│ │ │ -
42 {
│ │ │ -
43 std::remove_cvref_t<Node>::degree();
│ │ │ -
44 requires IsCompileTimeConstant<decltype(std::remove_cvref_t<Node>::degree())>::value;
│ │ │ -
45 requires Impl::HasConstExprDegree<Node> and Impl::HasPositiveDegree<Node>;
│ │ │ -
46 node.child(index_constant<0>());
│ │ │ -
47 node.child(index_constant<(std::remove_cvref_t<Node>::degree()-1)>());
│ │ │ -
48 };
│ │ │ -
│ │ │ -
49
│ │ │ -
51 template<class Node>
│ │ │ -
│ │ │ -
52 concept UniformInnerTreeNode = TreeNode<Node> && requires(Node node, std::size_t index)
│ │ │ -
53 {
│ │ │ -
54 node.child(index);
│ │ │ -
55 };
│ │ │ -
│ │ │ -
56
│ │ │ -
58 template<class Node>
│ │ │ - │ │ │ -
60
│ │ │ -
62 template<class Node>
│ │ │ - │ │ │ -
64
│ │ │ -
65} // namespace Dune::TypeTree::Concept
│ │ │ -
│ │ │ -
66
│ │ │ -
67#endif // DUNE_COMMON_TYPETREE_NODECONCEPTS_HH
│ │ │ -
Traits for type conversions and type information.
│ │ │ - │ │ │ -
std::integral_constant< std::size_t, i > index_constant
An index constant with value i.
Definition indices.hh:29
│ │ │ -
Definition nodeconcepts.hh:17
│ │ │ -
Check if T is an integral constant or any type derived from std::integral_constant.
Definition typetraits.hh:411
│ │ │ -
Model of a node of a typetree.
Definition nodeconcepts.hh:34
│ │ │ -
Model of an inner node of a typetree with compile time known degree and child access via index_consta...
Definition nodeconcepts.hh:41
│ │ │ -
Model of an inner node of a typetree with uniform nodes accessible via runtime index.
Definition nodeconcepts.hh:52
│ │ │ -
Model of an inner tree node of a typetree (either static degree or uniform).
Definition nodeconcepts.hh:59
│ │ │ -
Model of a leaf tree node of a typetree.
Definition nodeconcepts.hh:63
│ │ │ +
17 template<class T>
│ │ │ +
18 class IsReferenceWrapper : public std::false_type {};
│ │ │ +
19
│ │ │ +
20 template<class T>
│ │ │ +
21 class IsReferenceWrapper<std::reference_wrapper<T>> : public std::true_type {};
│ │ │ +
22
│ │ │ +
23 template<class T>
│ │ │ +
24 class IsReferenceWrapper<const std::reference_wrapper<T>> : public std::true_type {};
│ │ │ +
25
│ │ │ +
26} // namespace Dune::Impl
│ │ │ +
27
│ │ │ +
28
│ │ │ +
34template<class T>
│ │ │ +
35constexpr bool IsReferenceWrapper_v = Impl::IsReferenceWrapper<T>::value;
│ │ │ +
36
│ │ │ +
37
│ │ │ +
46template<class T>
│ │ │ +
│ │ │ +
47constexpr T& resolveRef(T& gf) noexcept
│ │ │ +
48{
│ │ │ +
49 return gf;
│ │ │ +
50}
│ │ │ +
│ │ │ +
51
│ │ │ +
52
│ │ │ +
53// There's no overload for non std::reference_wrapper r-values,
│ │ │ +
54// because this may lead to undefined behavior whenever the
│ │ │ +
55// return value is stored.
│ │ │ +
56// Notice that deleting the overload is not necessary, but
│ │ │ +
57// helps to document that it is missing on purpose. It also
│ │ │ +
58// leads to nicer error messages.
│ │ │ +
59template<class T>
│ │ │ +
60const auto& resolveRef(T&& gf) = delete;
│ │ │ +
61
│ │ │ +
62
│ │ │ +
81template<class T>
│ │ │ +
│ │ │ +
82constexpr T& resolveRef(std::reference_wrapper<T> gf) noexcept
│ │ │ +
83{
│ │ │ +
84 return gf.get();
│ │ │ +
85}
│ │ │ +
│ │ │ +
86
│ │ │ +
87
│ │ │ +
88
│ │ │ +
99template<class T>
│ │ │ +
100using ResolveRef_t = std::remove_reference_t<decltype(Dune::resolveRef(std::declval<T&>()))>;
│ │ │ +
101
│ │ │ +
102
│ │ │ +
103} // namespace Dune
│ │ │ +
104
│ │ │ +
105
│ │ │ +
106
│ │ │ +
107#endif // DUNE_COMMON_REFERENCE_HELPER_HH
│ │ │ +
std::remove_reference_t< decltype(Dune::resolveRef(std::declval< T & >()))> ResolveRef_t
Type trait to resolve std::reference_wrapper.
Definition referencehelper.hh:100
│ │ │ +
constexpr bool IsReferenceWrapper_v
Helper to detect if given type is a std::reference_wrapper.
Definition referencehelper.hh:35
│ │ │ +
constexpr T & resolveRef(T &gf) noexcept
Helper function to resolve std::reference_wrapper.
Definition referencehelper.hh:47
│ │ │ +
Dune namespace
Definition alignedallocator.hh:13
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,108 +1,96 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ -nodeconcepts.hh │ │ │ │ +referencehelper.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ 1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ 2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ -4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR │ │ │ │ -LGPL-3.0-or-later │ │ │ │ -5 │ │ │ │ -6#ifndef DUNE_COMMON_TYPETREE_NODECONCEPTS_HH │ │ │ │ -7#define DUNE_COMMON_TYPETREE_NODECONCEPTS_HH │ │ │ │ -8 │ │ │ │ -9#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ -10#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ +4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ +5#ifndef DUNE_COMMON_REFERENCE_HELPER_HH │ │ │ │ +6#define DUNE_COMMON_REFERENCE_HELPER_HH │ │ │ │ +7 │ │ │ │ +8#include │ │ │ │ +9#include │ │ │ │ +10 │ │ │ │ 11 │ │ │ │ -12#include │ │ │ │ -13#include │ │ │ │ -14#include │ │ │ │ -15 │ │ │ │ +12 │ │ │ │ +13namespace _D_u_n_e { │ │ │ │ +14 │ │ │ │ +15namespace Impl { │ │ │ │ 16 │ │ │ │ -_1_7namespace _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t { │ │ │ │ -18 │ │ │ │ -19 namespace Impl { │ │ │ │ -20 │ │ │ │ -21 template │ │ │ │ -22 concept HasConstExprDegree = requires(Node node) │ │ │ │ -23 { │ │ │ │ -24 std::bool_constant<(std::remove_cvref_t::degree(), true)>(); │ │ │ │ -25 }; │ │ │ │ -26 │ │ │ │ -27 template │ │ │ │ -28 concept HasPositiveDegree = ( std::remove_cvref_t::degree() > 0); │ │ │ │ -29 │ │ │ │ -30 } │ │ │ │ -31 │ │ │ │ -33 template │ │ │ │ -_3_4 concept _T_r_e_e_N_o_d_e = requires(Node node) │ │ │ │ -35 { │ │ │ │ -36 { std::as_const(node).degree() } -> std::convertible_to; │ │ │ │ -37 }; │ │ │ │ -38 │ │ │ │ -40 template │ │ │ │ -_4_1 concept _S_t_a_t_i_c_D_e_g_r_e_e_I_n_n_e_r_T_r_e_e_N_o_d_e = _T_r_e_e_N_o_d_e_<_N_o_d_e_> && requires(Node node) │ │ │ │ -42 { │ │ │ │ -43 std::remove_cvref_t::degree(); │ │ │ │ -44 requires _I_s_C_o_m_p_i_l_e_T_i_m_e_C_o_n_s_t_a_n_t::degree │ │ │ │ -())>::value; │ │ │ │ -45 requires Impl::HasConstExprDegree and Impl::HasPositiveDegree; │ │ │ │ -46 node.child(_i_n_d_e_x___c_o_n_s_t_a_n_t_<_0_>()); │ │ │ │ -47 node.child(_i_n_d_e_x___c_o_n_s_t_a_n_t<(std::remove_cvref_t::degree()-1)>()); │ │ │ │ -48 }; │ │ │ │ -49 │ │ │ │ -51 template │ │ │ │ -_5_2 concept _U_n_i_f_o_r_m_I_n_n_e_r_T_r_e_e_N_o_d_e = _T_r_e_e_N_o_d_e_<_N_o_d_e_> && requires(Node node, std:: │ │ │ │ -size_t index) │ │ │ │ -53 { │ │ │ │ -54 node.child(index); │ │ │ │ -55 }; │ │ │ │ -56 │ │ │ │ -58 template │ │ │ │ -_5_9 concept _I_n_n_e_r_T_r_e_e_N_o_d_e = _S_t_a_t_i_c_D_e_g_r_e_e_I_n_n_e_r_T_r_e_e_N_o_d_e_<_N_o_d_e_> || │ │ │ │ -_U_n_i_f_o_r_m_I_n_n_e_r_T_r_e_e_N_o_d_e_<_N_o_d_e_>; │ │ │ │ -60 │ │ │ │ -62 template │ │ │ │ -_6_3 concept _L_e_a_f_T_r_e_e_N_o_d_e = _T_r_e_e_N_o_d_e_<_N_o_d_e_> && not _I_n_n_e_r_T_r_e_e_N_o_d_e_<_N_o_d_e_>; │ │ │ │ -64 │ │ │ │ -65} // namespace Dune::TypeTree::Concept │ │ │ │ -66 │ │ │ │ -67#endif // DUNE_COMMON_TYPETREE_NODECONCEPTS_HH │ │ │ │ -_t_y_p_e_t_r_a_i_t_s_._h_h │ │ │ │ -Traits for type conversions and type information. │ │ │ │ -_i_n_d_i_c_e_s_._h_h │ │ │ │ -_D_u_n_e_:_:_i_n_d_e_x___c_o_n_s_t_a_n_t │ │ │ │ -std::integral_constant< std::size_t, i > index_constant │ │ │ │ -An index constant with value i. │ │ │ │ -DDeeffiinniittiioonn indices.hh:29 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t │ │ │ │ -DDeeffiinniittiioonn nodeconcepts.hh:17 │ │ │ │ -_D_u_n_e_:_:_I_s_C_o_m_p_i_l_e_T_i_m_e_C_o_n_s_t_a_n_t │ │ │ │ -Check if T is an integral constant or any type derived from std:: │ │ │ │ -integral_constant. │ │ │ │ -DDeeffiinniittiioonn typetraits.hh:411 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_T_r_e_e_N_o_d_e │ │ │ │ -Model of a node of a typetree. │ │ │ │ -DDeeffiinniittiioonn nodeconcepts.hh:34 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_S_t_a_t_i_c_D_e_g_r_e_e_I_n_n_e_r_T_r_e_e_N_o_d_e │ │ │ │ -Model of an inner node of a typetree with compile time known degree and child │ │ │ │ -access via index_consta... │ │ │ │ -DDeeffiinniittiioonn nodeconcepts.hh:41 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_U_n_i_f_o_r_m_I_n_n_e_r_T_r_e_e_N_o_d_e │ │ │ │ -Model of an inner node of a typetree with uniform nodes accessible via runtime │ │ │ │ -index. │ │ │ │ -DDeeffiinniittiioonn nodeconcepts.hh:52 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_I_n_n_e_r_T_r_e_e_N_o_d_e │ │ │ │ -Model of an inner tree node of a typetree (either static degree or uniform). │ │ │ │ -DDeeffiinniittiioonn nodeconcepts.hh:59 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_L_e_a_f_T_r_e_e_N_o_d_e │ │ │ │ -Model of a leaf tree node of a typetree. │ │ │ │ -DDeeffiinniittiioonn nodeconcepts.hh:63 │ │ │ │ +17 template │ │ │ │ +18 class IsReferenceWrapper : public std::false_type {}; │ │ │ │ +19 │ │ │ │ +20 template │ │ │ │ +21 class IsReferenceWrapper> : public std::true_type │ │ │ │ +{}; │ │ │ │ +22 │ │ │ │ +23 template │ │ │ │ +24 class IsReferenceWrapper> : public std:: │ │ │ │ +true_type {}; │ │ │ │ +25 │ │ │ │ +26} // namespace Dune::Impl │ │ │ │ +27 │ │ │ │ +28 │ │ │ │ +34template │ │ │ │ +_3_5constexpr bool _I_s_R_e_f_e_r_e_n_c_e_W_r_a_p_p_e_r___v = Impl::IsReferenceWrapper::value; │ │ │ │ +36 │ │ │ │ +37 │ │ │ │ +46template │ │ │ │ +_4_7constexpr T& _r_e_s_o_l_v_e_R_e_f(T& gf) noexcept │ │ │ │ +48{ │ │ │ │ +49 return gf; │ │ │ │ +50} │ │ │ │ +51 │ │ │ │ +52 │ │ │ │ +53// There's no overload for non std::reference_wrapper r-values, │ │ │ │ +54// because this may lead to undefined behavior whenever the │ │ │ │ +55// return value is stored. │ │ │ │ +56// Notice that deleting the overload is not necessary, but │ │ │ │ +57// helps to document that it is missing on purpose. It also │ │ │ │ +58// leads to nicer error messages. │ │ │ │ +59template │ │ │ │ +_6_0const auto& _r_e_s_o_l_v_e_R_e_f(T&& gf) = delete; │ │ │ │ +61 │ │ │ │ +62 │ │ │ │ +81template │ │ │ │ +_8_2constexpr T& _r_e_s_o_l_v_e_R_e_f(std::reference_wrapper gf) noexcept │ │ │ │ +83{ │ │ │ │ +84 return gf.get(); │ │ │ │ +85} │ │ │ │ +86 │ │ │ │ +87 │ │ │ │ +88 │ │ │ │ +99template │ │ │ │ +_1_0_0using _R_e_s_o_l_v_e_R_e_f___t = std::remove_reference_t()))>; │ │ │ │ +101 │ │ │ │ +102 │ │ │ │ +103} // namespace Dune │ │ │ │ +104 │ │ │ │ +105 │ │ │ │ +106 │ │ │ │ +107#endif // DUNE_COMMON_REFERENCE_HELPER_HH │ │ │ │ +_D_u_n_e_:_:_R_e_s_o_l_v_e_R_e_f___t │ │ │ │ +std::remove_reference_t< decltype(Dune::resolveRef(std::declval< T & >()))> │ │ │ │ +ResolveRef_t │ │ │ │ +Type trait to resolve std::reference_wrapper. │ │ │ │ +DDeeffiinniittiioonn referencehelper.hh:100 │ │ │ │ +_D_u_n_e_:_:_I_s_R_e_f_e_r_e_n_c_e_W_r_a_p_p_e_r___v │ │ │ │ +constexpr bool IsReferenceWrapper_v │ │ │ │ +Helper to detect if given type is a std::reference_wrapper. │ │ │ │ +DDeeffiinniittiioonn referencehelper.hh:35 │ │ │ │ +_D_u_n_e_:_:_r_e_s_o_l_v_e_R_e_f │ │ │ │ +constexpr T & resolveRef(T &gf) noexcept │ │ │ │ +Helper function to resolve std::reference_wrapper. │ │ │ │ +DDeeffiinniittiioonn referencehelper.hh:47 │ │ │ │ +_D_u_n_e │ │ │ │ +Dune namespace │ │ │ │ +DDeeffiinniittiioonn alignedallocator.hh:13 │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00035.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: childaccess.hh File Reference │ │ │ +dune-common: densematrix.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,64 +66,75 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ +Classes | │ │ │ Namespaces | │ │ │ -Typedefs | │ │ │ Functions
│ │ │ -
childaccess.hh File Reference
│ │ │ +
densematrix.hh File Reference
│ │ │
│ │ │
│ │ │ -
#include <cstddef>
│ │ │ + │ │ │ +

Implements a matrix constructed from a given type representing a field and a compile-time given number of rows and columns. │ │ │ +More...

│ │ │ +
#include <cmath>
│ │ │ +#include <cstddef>
│ │ │ +#include <iostream>
│ │ │ +#include <iterator>
│ │ │ #include <type_traits>
│ │ │ #include <utility>
│ │ │ -#include <tuple>
│ │ │ -#include <dune/common/indices.hh>
│ │ │ -#include <dune/common/typelist.hh>
│ │ │ -#include <dune/common/typetraits.hh>
│ │ │ -#include <dune/common/hybridmultiindex.hh>
│ │ │ -#include <dune/common/typetree/nodeconcepts.hh>
│ │ │ -#include <dune/common/typetree/treepath.hh>
│ │ │ +#include <vector>
│ │ │ +#include <dune/common/boundschecking.hh>
│ │ │ +#include <dune/common/classname.hh>
│ │ │ +#include <dune/common/exceptions.hh>
│ │ │ +#include <dune/common/fvector.hh>
│ │ │ +#include <dune/common/math.hh>
│ │ │ +#include <dune/common/precision.hh>
│ │ │ +#include <dune/common/simd/simd.hh>
│ │ │ +#include <dune/common/typetraits.hh>
│ │ │ +#include <dune/common/scalarvectorview.hh>
│ │ │ +#include <dune/common/std/iterator.hh>
│ │ │
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ +

│ │ │ +Classes

struct  Dune::FieldTraits< DenseMatrix< M > >
class  Dune::FMatrixError
 Error thrown if operations of a FieldMatrix fail. More...
class  Dune::DenseMatrix< MAT >
 A dense n x m matrix. More...
│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ -

│ │ │ Namespaces

namespace  Dune
 Dune namespace
namespace  Dune::TypeTree
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │

│ │ │ -Typedefs

template<typename Node, std::size_t... indices>
using Dune::TypeTree::Child = typename Impl::ChildTraits<Node, indices...>::type
 Template alias for the type of a child node given by a list of child indices.
template<typename Node, typename TreePath>
using Dune::TypeTree::ChildForTreePath = std::decay_t<decltype(child(std::declval<Node>(), std::declval<TreePath>()))>
 Template alias for the type of a child node given by a TreePath type.
namespace  Dune::DenseMatrixHelp
│ │ │ │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ Functions

template<typename Node, typename... Indices>
decltype(auto) Dune::TypeTree::child (Node &&node, TreePath< Indices... > treePath)
 Extracts the child of a node given by a TreePath object.
template<typename Node, typename... Indices>
decltype(auto) Dune::TypeTree::child (Node &&node, Indices... indices)
 Extracts the child of a node given by a sequence of compile-time and run-time indices.
template<typename MAT, typename V1, typename V2>
static void Dune::DenseMatrixHelp::multAssign (const DenseMatrix< MAT > &matrix, const DenseVector< V1 > &x, DenseVector< V2 > &ret)
 calculates ret = matrix * x
template<typename MAT>
std::ostream & Dune::operator<< (std::ostream &s, const DenseMatrix< MAT > &a)
 Sends the matrix to an output stream.
│ │ │ -
│ │ │ +

Detailed Description

│ │ │ +

Implements a matrix constructed from a given type representing a field and a compile-time given number of rows and columns.

│ │ │ +
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,45 +1,52 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ -_N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s | _F_u_n_c_t_i_o_n_s │ │ │ │ -childaccess.hh File Reference │ │ │ │ +_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _F_u_n_c_t_i_o_n_s │ │ │ │ +densematrix.hh File Reference │ │ │ │ +_C_o_m_m_o_n » _D_e_n_s_e_ _M_a_t_r_i_x_ _a_n_d_ _V_e_c_t_o_r_ _T_e_m_p_l_a_t_e_ _L_i_b_r_a_r_y │ │ │ │ +Implements a matrix constructed from a given type representing a field and a │ │ │ │ +compile-time given number of rows and columns. _M_o_r_e_._._. │ │ │ │ +#include │ │ │ │ #include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ #include │ │ │ │ #include │ │ │ │ -#include │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_l_i_s_t_._h_h> │ │ │ │ +#include │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_b_o_u_n_d_s_c_h_e_c_k_i_n_g_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_c_l_a_s_s_n_a_m_e_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_e_x_c_e_p_t_i_o_n_s_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_f_v_e_c_t_o_r_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_m_a_t_h_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_p_r_e_c_i_s_i_o_n_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_i_m_d_/_s_i_m_d_._h_h> │ │ │ │ #include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_m_u_l_t_i_i_n_d_e_x_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_n_o_d_e_c_o_n_c_e_p_t_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_t_r_e_e_p_a_t_h_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_c_a_l_a_r_v_e_c_t_o_r_v_i_e_w_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_t_d_/_i_t_e_r_a_t_o_r_._h_h> │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ +CCllaasssseess │ │ │ │ +struct   _D_u_n_e_:_:_F_i_e_l_d_T_r_a_i_t_s_<_ _D_e_n_s_e_M_a_t_r_i_x_<_ _M_ _>_ _> │ │ │ │ + class   _D_u_n_e_:_:_F_M_a_t_r_i_x_E_r_r_o_r │ │ │ │ +  Error thrown if operations of a _F_i_e_l_d_M_a_t_r_i_x fail. _M_o_r_e_._._. │ │ │ │ + class   _D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_<_ _M_A_T_ _> │ │ │ │ +  A dense n x m matrix. _M_o_r_e_._._. │ │ │ │ NNaammeessppaacceess │ │ │ │ namespace   _D_u_n_e │ │ │ │   Dune namespace │ │ │ │ -namespace   _D_u_n_e_:_:_T_y_p_e_T_r_e_e │ │ │ │ -TTyyppeeddeeffss │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_h_i_l_d = typename Impl::ChildTraits_:_: │ │ │ │ - _t_y_p_e │ │ │ │ -  Template alias for the type of a child node given by a list of child │ │ │ │ - indices. │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_h_i_l_d_F_o_r_T_r_e_e_P_a_t_h = std::decay_t(), std::declval<_T_r_e_e_P_a_t_h>()))> │ │ │ │ -  Template alias for the type of a child node given by a _T_r_e_e_P_a_t_h type. │ │ │ │ +namespace   _D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_H_e_l_p │ │ │ │ FFuunnccttiioonnss │ │ │ │ -template │ │ │ │ -decltype(auto)  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_c_h_i_l_d (Node &&node, _T_r_e_e_P_a_t_h< Indices... > │ │ │ │ - _t_r_e_e_P_a_t_h) │ │ │ │ -  Extracts the child of a node given by a _T_r_e_e_P_a_t_h object. │ │ │ │ -template │ │ │ │ -decltype(auto)  _D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_c_h_i_l_d (Node &&node, Indices... indices) │ │ │ │ -  Extracts the child of a node given by a sequence of compile- │ │ │ │ - time and run-time indices. │ │ │ │ +template │ │ │ │ + static void  _D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_H_e_l_p_:_:_m_u_l_t_A_s_s_i_g_n (const _D_e_n_s_e_M_a_t_r_i_x< MAT > │ │ │ │ + &matrix, const _D_e_n_s_e_V_e_c_t_o_r< V1 > &x, _D_e_n_s_e_V_e_c_t_o_r< V2 > &ret) │ │ │ │ +  calculates ret = matrix * x │ │ │ │ +template │ │ │ │ +std::ostream &  _D_u_n_e_:_:_o_p_e_r_a_t_o_r_<_< (std::ostream &s, const _D_e_n_s_e_M_a_t_r_i_x< MAT > &a) │ │ │ │ +  Sends the matrix to an output stream. │ │ │ │ +********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ +Implements a matrix constructed from a given type representing a field and a │ │ │ │ +compile-time given number of rows and columns. │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00035_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: childaccess.hh Source File │ │ │ +dune-common: densematrix.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -66,154 +66,1327 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
childaccess.hh
│ │ │ +
densematrix.hh
│ │ │
│ │ │
│ │ │ -Go to the documentation of this file.
1// -*- tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │ -
2// vi: set et ts=8 sw=2 sts=2:
│ │ │ +Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │ +
2// vi: set et ts=4 sw=2 sts=2:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │ -
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR LGPL-3.0-or-later
│ │ │ -
5
│ │ │ -
6#ifndef DUNE_COMMON_TYPETREE_CHILDACCESS_HH
│ │ │ -
7#define DUNE_COMMON_TYPETREE_CHILDACCESS_HH
│ │ │ -
8
│ │ │ +
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ +
5#ifndef DUNE_DENSEMATRIX_HH
│ │ │ +
6#define DUNE_DENSEMATRIX_HH
│ │ │ +
7
│ │ │ +
8#include <cmath>
│ │ │
9#include <cstddef>
│ │ │ -
10#include <type_traits>
│ │ │ -
11#include <utility>
│ │ │ -
12#include <tuple>
│ │ │ -
13
│ │ │ - │ │ │ - │ │ │ - │ │ │ -
17
│ │ │ - │ │ │ - │ │ │ - │ │ │ -
21
│ │ │ -
22
│ │ │ -
│ │ │ -
23namespace Dune::TypeTree {
│ │ │ -
24
│ │ │ -
29
│ │ │ -
31
│ │ │ -
54 template<typename Node, typename... Indices>
│ │ │ -
│ │ │ -
55 decltype(auto) child (Node&& node, TreePath<Indices...> treePath)
│ │ │ -
56 {
│ │ │ -
57 if constexpr (sizeof...(Indices) == 0)
│ │ │ -
58 return std::forward<Node>(node);
│ │ │ -
59 else
│ │ │ -
60 {
│ │ │ -
61 using I0 = std::tuple_element_t<0, TreePath<Indices...>>;
│ │ │ - │ │ │ -
63 static_assert(I0::value < std::decay_t<Node>::degree(), "Child index out of range");
│ │ │ -
64 else
│ │ │ -
65 assert(std::size_t(treePath.front()) < node.degree() && "Child index out of range");
│ │ │ -
66 if constexpr (sizeof...(Indices) == 1)
│ │ │ -
67 return node.child(treePath.front());
│ │ │ -
68 else
│ │ │ -
69 return child(node.child(treePath.front()), pop_front(treePath));
│ │ │ -
70 }
│ │ │ -
71 }
│ │ │ -
│ │ │ -
72
│ │ │ -
74
│ │ │ -
96 template<typename Node, typename... Indices>
│ │ │ -
│ │ │ -
97 decltype(auto) child (Node&& node, Indices... indices)
│ │ │ -
98 {
│ │ │ -
99 return child(node, Dune::HybridMultiIndex{indices...});
│ │ │ -
100 }
│ │ │ +
10#include <iostream>
│ │ │ +
11#include <iterator>
│ │ │ +
12#include <type_traits>
│ │ │ +
13#include <utility>
│ │ │ +
14#include <vector>
│ │ │ +
15
│ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ +
20#include <dune/common/math.hh>
│ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ +
26
│ │ │ +
27namespace Dune
│ │ │ +
28{
│ │ │ +
29
│ │ │ +
30 template<typename M> class DenseMatrix;
│ │ │ +
31
│ │ │ +
32 template<typename M>
│ │ │ +
│ │ │ + │ │ │ +
34 {
│ │ │ + │ │ │ + │ │ │ +
37 };
│ │ │
│ │ │ -
101
│ │ │ -
102 namespace Impl {
│ │ │ +
38
│ │ │ +
39 template<class K, int N, int M> class FieldMatrix;
│ │ │ +
40 template<class K, int N> class FieldVector;
│ │ │ +
41
│ │ │ +
46
│ │ │ +
52
│ │ │ +
53
│ │ │ +
54
│ │ │ +
60 template< class DenseMatrix, class RHS >
│ │ │ + │ │ │ +
62
│ │ │ +
63#ifndef DOXYGEN
│ │ │ +
64 namespace Impl
│ │ │ +
65 {
│ │ │ +
66
│ │ │ +
67 template< class DenseMatrix, class RHS >
│ │ │ + │ │ │ +
69 {};
│ │ │ +
70
│ │ │ +
71 template< class DenseMatrix, class RHS >
│ │ │ + │ │ │ + │ │ │ +
74 {
│ │ │ +
75 public:
│ │ │ +
76 constexpr static void apply ( DenseMatrix &denseMatrix, const RHS &rhs )
│ │ │ +
77 {
│ │ │ +
78 typedef typename DenseMatrix::field_type field_type;
│ │ │ +
79 std::fill( denseMatrix.begin(), denseMatrix.end(), static_cast< field_type >( rhs ) );
│ │ │ +
80 }
│ │ │ +
81 };
│ │ │ +
82
│ │ │ +
83 template< class DenseMatrix, class RHS >
│ │ │ +
84 requires Std::indirectly_copyable<
│ │ │ +
85 decltype(std::begin(*std::declval<typename RHS::const_iterator>())),
│ │ │ +
86 decltype(std::begin(*std::declval<typename DenseMatrix::iterator>()))>
│ │ │ +
87 class DenseMatrixAssigner<DenseMatrix, RHS>
│ │ │ +
88 {
│ │ │ +
89 public:
│ │ │ +
90 constexpr static void apply ( DenseMatrix &denseMatrix, const RHS &rhs )
│ │ │ +
91 {
│ │ │ +
92 DUNE_ASSERT_BOUNDS(rhs.N() == denseMatrix.N());
│ │ │ +
93 DUNE_ASSERT_BOUNDS(rhs.M() == denseMatrix.M());
│ │ │ +
94 typename DenseMatrix::iterator tIt = std::begin(denseMatrix);
│ │ │ +
95 typename RHS::const_iterator sIt = std::begin(rhs);
│ │ │ +
96 for(; sIt != std::end(rhs); ++tIt, ++sIt)
│ │ │ +
97 std::copy(std::begin(*sIt), std::end(*sIt), std::begin(*tIt));
│ │ │ +
98 }
│ │ │ +
99 };
│ │ │ +
100
│ │ │ +
101 } // namespace Impl
│ │ │ +
102
│ │ │
103
│ │ │ -
104 // We could directly implement Child as
│ │ │ -
105 //
│ │ │ -
106 // using Child = std::decay_t<decltype(child(std::declval<Node>(), Dune::index_constant<indices>()...))>;
│ │ │ -
107 //
│ │ │ -
108 // but this triggers an internal compiler error in
│ │ │ -
109 // gcc 11, 12, and 13 while it does work with gcc 10
│ │ │ -
110 // and 14 and clang. This can be avoided by extracting
│ │ │ -
111 // this into a traits class.
│ │ │ -
112 template<typename Node, std::size_t... indices>
│ │ │ -
113 struct ChildTraits
│ │ │ -
114 {
│ │ │ -
115 using type = std::decay_t<decltype(child(std::declval<Node>(), Dune::index_constant<indices>()...))>;
│ │ │ -
116 };
│ │ │ -
117
│ │ │ -
118 }
│ │ │ -
119
│ │ │ -
121
│ │ │ -
128 template<typename Node, std::size_t... indices>
│ │ │ -
129 using Child = typename Impl::ChildTraits<Node, indices...>::type;
│ │ │ -
130
│ │ │ +
104
│ │ │ +
105 template< class DenseMatrix, class RHS >
│ │ │ + │ │ │ +
107 : public Impl::DenseMatrixAssigner< DenseMatrix, RHS >
│ │ │ +
108 {};
│ │ │ +
109
│ │ │ +
110
│ │ │ +
111 namespace Impl
│ │ │ +
112 {
│ │ │ +
113
│ │ │ +
114 template< class DenseMatrix, class RHS >
│ │ │ +
115 std::true_type hasDenseMatrixAssigner ( DenseMatrix &, const RHS &, decltype( Dune::DenseMatrixAssigner< DenseMatrix, RHS >::apply( std::declval< DenseMatrix & >(), std::declval< const RHS & >() ) ) * = nullptr );
│ │ │ +
116
│ │ │ +
117 std::false_type hasDenseMatrixAssigner ( ... );
│ │ │ +
118
│ │ │ +
119 } // namespace Impl
│ │ │ +
120
│ │ │ +
121 template< class DenseMatrix, class RHS >
│ │ │ +
122 struct HasDenseMatrixAssigner
│ │ │ +
123 : public decltype( Impl::hasDenseMatrixAssigner( std::declval< DenseMatrix & >(), std::declval< const RHS & >() ) )
│ │ │ +
124 {};
│ │ │ +
125
│ │ │ +
126#endif // #ifndef DOXYGEN
│ │ │ +
127
│ │ │ +
128
│ │ │ +
129
│ │ │ +
131 class FMatrixError : public MathError {};
│ │ │
132
│ │ │ -
139 template<typename Node, typename TreePath>
│ │ │ -
140 using ChildForTreePath = std::decay_t<decltype(child(std::declval<Node>(), std::declval<TreePath>()))>;
│ │ │ -
141
│ │ │ -
142
│ │ │ -
143
│ │ │ -
144 namespace Impl {
│ │ │ -
145
│ │ │ -
146 template<class N>
│ │ │ -
147 static constexpr auto childTypes()
│ │ │ -
148 {
│ │ │ - │ │ │ -
150 {
│ │ │ -
151 return Dune::unpackIntegerSequence([&](auto... i) {
│ │ │ - │ │ │ -
153 }, std::make_index_sequence<N::degree()>{});
│ │ │ -
154 }
│ │ │ -
155 else
│ │ │ -
156 return Dune::MetaType<void>{};
│ │ │ -
157 }
│ │ │ -
158
│ │ │ +
143 template<typename MAT>
│ │ │ +
│ │ │ + │ │ │ +
145 {
│ │ │ +
146 typedef DenseMatVecTraits<MAT> Traits;
│ │ │ +
147
│ │ │ +
148 // Curiously recurring template pattern
│ │ │ +
149 constexpr MAT & asImp() { return static_cast<MAT&>(*this); }
│ │ │ +
150 constexpr const MAT & asImp() const { return static_cast<const MAT&>(*this); }
│ │ │ +
151
│ │ │ +
152 template <class>
│ │ │ +
153 friend class DenseMatrix;
│ │ │ +
154
│ │ │ +
155 public:
│ │ │ +
156 //===== type definitions and constants
│ │ │ +
157
│ │ │ +
159 typedef typename Traits::derived_type derived_type;
│ │ │
160
│ │ │ -
170 template<class N>
│ │ │ -
171 using Children = typename decltype(Impl::childTypes<N>())::type;
│ │ │ -
172
│ │ │ -
173 }
│ │ │ -
174
│ │ │ -
176
│ │ │ -
177} //namespace Dune::TypeTree
│ │ │ -
│ │ │ -
178
│ │ │ -
179#endif // DUNE_COMMON_TYPETREE_CHILDACCESS_HH
│ │ │ - │ │ │ - │ │ │ -
Traits for type conversions and type information.
│ │ │ - │ │ │ - │ │ │ - │ │ │ -
decltype(auto) constexpr unpackIntegerSequence(F &&f, std::integer_sequence< I, i... > sequence)
Unpack an std::integer_sequence<I,i...> to std::integral_constant<I,i>...
Definition indices.hh:124
│ │ │ -
std::integral_constant< std::size_t, i > index_constant
An index constant with value i.
Definition indices.hh:29
│ │ │ -
decltype(auto) child(Node &&node, TreePath< Indices... > treePath)
Extracts the child of a node given by a TreePath object.
Definition childaccess.hh:55
│ │ │ -
typename Impl::ChildTraits< Node, indices... >::type Child
Template alias for the type of a child node given by a list of child indices.
Definition childaccess.hh:129
│ │ │ -
std::decay_t< decltype(child(std::declval< Node >(), std::declval< TreePath >()))> ChildForTreePath
Template alias for the type of a child node given by a TreePath type.
Definition childaccess.hh:140
│ │ │ -
Dune::HybridMultiIndex< T... > TreePath
A type for representing tree paths that supports both compile time and run time indices.
Definition treepath.hh:43
│ │ │ -
constexpr auto treePath(const T &... t)
Constructs a new TreePath from the given indices.
Definition treepath.hh:55
│ │ │ -
Namespace with predefined compile time indices for the range [0,19].
Definition indices.hh:50
│ │ │ -
Definition childaccess.hh:23
│ │ │ -
constexpr auto pop_front(const HybridMultiIndex< T... > &tp)
Removes first index on a HybridMultiIndex.
Definition hybridmultiindex.hh:374
│ │ │ -
A hybrid multi-index class that supports both compile time and run time indices.
Definition hybridmultiindex.hh:81
│ │ │ +
162 typedef typename Traits::value_type value_type;
│ │ │ +
163
│ │ │ +
165 typedef typename Traits::value_type field_type;
│ │ │ +
166
│ │ │ +
168 typedef typename Traits::value_type block_type;
│ │ │ +
169
│ │ │ +
171 typedef typename Traits::size_type size_type;
│ │ │ +
172
│ │ │ +
174 typedef typename Traits::row_type row_type;
│ │ │ +
175
│ │ │ +
177 typedef typename Traits::row_reference row_reference;
│ │ │ +
178
│ │ │ +
180 typedef typename Traits::const_row_reference const_row_reference;
│ │ │ +
181
│ │ │ +
183 constexpr static int blocklevel = 1;
│ │ │ +
184
│ │ │ +
185 private:
│ │ │ +
188 using simd_index_type = Simd::Rebind<std::size_t, value_type>;
│ │ │ +
189
│ │ │ +
190 public:
│ │ │ +
191 //===== access to components
│ │ │ +
192
│ │ │ +
│ │ │ + │ │ │ +
195 {
│ │ │ +
196 return asImp().mat_access(i);
│ │ │ +
197 }
│ │ │ +
│ │ │ +
198
│ │ │ +
│ │ │ + │ │ │ +
200 {
│ │ │ +
201 return asImp().mat_access(i);
│ │ │ +
202 }
│ │ │ +
│ │ │ +
203
│ │ │ +
│ │ │ +
205 constexpr size_type size() const
│ │ │ +
206 {
│ │ │ +
207 return rows();
│ │ │ +
208 }
│ │ │ +
│ │ │ +
209
│ │ │ +
210 //===== iterator interface to rows of the matrix
│ │ │ + │ │ │ + │ │ │ + │ │ │ +
218 typedef typename std::remove_reference<row_reference>::type::Iterator ColIterator;
│ │ │ +
219
│ │ │ +
│ │ │ +
221 constexpr Iterator begin ()
│ │ │ +
222 {
│ │ │ +
223 return Iterator(*this,0);
│ │ │ +
224 }
│ │ │ +
│ │ │ +
225
│ │ │ +
│ │ │ +
227 constexpr Iterator end ()
│ │ │ +
228 {
│ │ │ +
229 return Iterator(*this,rows());
│ │ │ +
230 }
│ │ │ +
│ │ │ +
231
│ │ │ +
│ │ │ +
234 constexpr Iterator beforeEnd ()
│ │ │ +
235 {
│ │ │ +
236 return Iterator(*this,rows()-1);
│ │ │ +
237 }
│ │ │ +
│ │ │ +
238
│ │ │ +
│ │ │ + │ │ │ +
242 {
│ │ │ +
243 return Iterator(*this,-1);
│ │ │ +
244 }
│ │ │ +
│ │ │ +
245
│ │ │ + │ │ │ + │ │ │ + │ │ │ +
253 typedef typename std::remove_reference<const_row_reference>::type::ConstIterator ConstColIterator;
│ │ │ +
254
│ │ │ +
│ │ │ +
256 constexpr ConstIterator begin () const
│ │ │ +
257 {
│ │ │ +
258 return ConstIterator(*this,0);
│ │ │ +
259 }
│ │ │ +
│ │ │ +
260
│ │ │ +
│ │ │ +
262 constexpr ConstIterator end () const
│ │ │ +
263 {
│ │ │ +
264 return ConstIterator(*this,rows());
│ │ │ +
265 }
│ │ │ +
│ │ │ +
266
│ │ │ +
│ │ │ +
269 constexpr ConstIterator beforeEnd () const
│ │ │ +
270 {
│ │ │ +
271 return ConstIterator(*this,rows()-1);
│ │ │ +
272 }
│ │ │ +
│ │ │ +
273
│ │ │ +
│ │ │ +
276 constexpr ConstIterator beforeBegin () const
│ │ │ +
277 {
│ │ │ +
278 return ConstIterator(*this,-1);
│ │ │ +
279 }
│ │ │ +
│ │ │ +
280
│ │ │ +
281 //===== assignment
│ │ │ +
282
│ │ │ +
283 template< class RHS, class = std::enable_if_t< HasDenseMatrixAssigner< MAT, RHS >::value > >
│ │ │ +
│ │ │ +
284 constexpr derived_type &operator= ( const RHS &rhs )
│ │ │ +
285 {
│ │ │ + │ │ │ +
287 return asImp();
│ │ │ +
288 }
│ │ │ +
│ │ │ +
289
│ │ │ +
290 //===== vector space arithmetic
│ │ │ +
291
│ │ │ +
293 template <class Other>
│ │ │ +
│ │ │ + │ │ │ +
295 {
│ │ │ +
296 DUNE_ASSERT_BOUNDS(rows() == x.rows());
│ │ │ +
297 for (size_type i=0; i<rows(); i++)
│ │ │ +
298 (*this)[i] += x[i];
│ │ │ +
299 return asImp();
│ │ │ +
300 }
│ │ │ +
│ │ │ +
301
│ │ │ +
│ │ │ +
303 constexpr derived_type operator- () const
│ │ │ +
304 {
│ │ │ +
305 MAT result;
│ │ │ +
306 using idx_type = typename decltype(result)::size_type;
│ │ │ +
307
│ │ │ +
308 for (idx_type i = 0; i < rows(); ++i)
│ │ │ +
309 for (idx_type j = 0; j < cols(); ++j)
│ │ │ +
310 result[i][j] = - asImp()[i][j];
│ │ │ +
311
│ │ │ +
312 return result;
│ │ │ +
313 }
│ │ │ +
│ │ │ +
314
│ │ │ +
316 template <class Other>
│ │ │ +
│ │ │ + │ │ │ +
318 {
│ │ │ +
319 DUNE_ASSERT_BOUNDS(rows() == x.rows());
│ │ │ +
320 for (size_type i=0; i<rows(); i++)
│ │ │ +
321 (*this)[i] -= x[i];
│ │ │ +
322 return asImp();
│ │ │ +
323 }
│ │ │ +
│ │ │ +
324
│ │ │ +
│ │ │ + │ │ │ +
327 {
│ │ │ +
328 for (size_type i=0; i<rows(); i++)
│ │ │ +
329 (*this)[i] *= k;
│ │ │ +
330 return asImp();
│ │ │ +
331 }
│ │ │ +
│ │ │ +
332
│ │ │ +
│ │ │ + │ │ │ +
335 {
│ │ │ +
336 for (size_type i=0; i<rows(); i++)
│ │ │ +
337 (*this)[i] /= k;
│ │ │ +
338 return asImp();
│ │ │ +
339 }
│ │ │ +
│ │ │ +
340
│ │ │ +
342 template <class Other>
│ │ │ +
│ │ │ +
343 constexpr derived_type &axpy (const field_type &a, const DenseMatrix<Other> &x )
│ │ │ +
344 {
│ │ │ +
345 DUNE_ASSERT_BOUNDS(rows() == x.rows());
│ │ │ +
346 for( size_type i = 0; i < rows(); ++i )
│ │ │ +
347 (*this)[ i ].axpy( a, x[ i ] );
│ │ │ +
348 return asImp();
│ │ │ +
349 }
│ │ │ +
│ │ │ +
350
│ │ │ +
352 template <class Other>
│ │ │ +
│ │ │ +
353 constexpr bool operator== (const DenseMatrix<Other>& x) const
│ │ │ +
354 {
│ │ │ +
355 DUNE_ASSERT_BOUNDS(rows() == x.rows());
│ │ │ +
356 for (size_type i=0; i<rows(); i++)
│ │ │ +
357 if ((*this)[i]!=x[i])
│ │ │ +
358 return false;
│ │ │ +
359 return true;
│ │ │ +
360 }
│ │ │ +
│ │ │ +
361
│ │ │ +
362 template <class Other>
│ │ │ +
│ │ │ +
363 constexpr bool operator!= (const DenseMatrix<Other>& x) const
│ │ │ +
364 {
│ │ │ +
365 return !operator==(x);
│ │ │ +
366 }
│ │ │ +
│ │ │ +
367
│ │ │ +
368
│ │ │ +
369 //===== linear maps
│ │ │ +
370
│ │ │ +
372 template<class X, class Y>
│ │ │ +
│ │ │ +
373 constexpr void mv (const X& x, Y& y) const
│ │ │ +
374 {
│ │ │ +
375 auto&& xx = Impl::asVector(x);
│ │ │ +
376 auto&& yy = Impl::asVector(y);
│ │ │ +
377 DUNE_ASSERT_BOUNDS((void*)(&x) != (void*)(&y));
│ │ │ +
378 DUNE_ASSERT_BOUNDS(xx.N() == M());
│ │ │ +
379 DUNE_ASSERT_BOUNDS(yy.N() == N());
│ │ │ +
380
│ │ │ +
381 using y_field_type = typename FieldTraits<Y>::field_type;
│ │ │ +
382 for (size_type i=0; i<rows(); ++i)
│ │ │ +
383 {
│ │ │ +
384 yy[i] = y_field_type(0);
│ │ │ +
385 for (size_type j=0; j<cols(); j++)
│ │ │ +
386 yy[i] += (*this)[i][j] * xx[j];
│ │ │ +
387 }
│ │ │ +
388 }
│ │ │ +
│ │ │ +
389
│ │ │ +
391 template< class X, class Y >
│ │ │ +
│ │ │ +
392 constexpr void mtv ( const X &x, Y &y ) const
│ │ │ +
393 {
│ │ │ +
394 auto&& xx = Impl::asVector(x);
│ │ │ +
395 auto&& yy = Impl::asVector(y);
│ │ │ +
396 DUNE_ASSERT_BOUNDS((void*)(&x) != (void*)(&y));
│ │ │ +
397 DUNE_ASSERT_BOUNDS(xx.N() == N());
│ │ │ +
398 DUNE_ASSERT_BOUNDS(yy.N() == M());
│ │ │ +
399
│ │ │ +
400 using y_field_type = typename FieldTraits<Y>::field_type;
│ │ │ +
401 for(size_type i = 0; i < cols(); ++i)
│ │ │ +
402 {
│ │ │ +
403 yy[i] = y_field_type(0);
│ │ │ +
404 for(size_type j = 0; j < rows(); ++j)
│ │ │ +
405 yy[i] += (*this)[j][i] * xx[j];
│ │ │ +
406 }
│ │ │ +
407 }
│ │ │ +
│ │ │ +
408
│ │ │ +
410 template<class X, class Y>
│ │ │ +
│ │ │ +
411 constexpr void umv (const X& x, Y& y) const
│ │ │ +
412 {
│ │ │ +
413 auto&& xx = Impl::asVector(x);
│ │ │ +
414 auto&& yy = Impl::asVector(y);
│ │ │ +
415 DUNE_ASSERT_BOUNDS(xx.N() == M());
│ │ │ +
416 DUNE_ASSERT_BOUNDS(yy.N() == N());
│ │ │ +
417 for (size_type i=0; i<rows(); ++i)
│ │ │ +
418 for (size_type j=0; j<cols(); j++)
│ │ │ +
419 yy[i] += (*this)[i][j] * xx[j];
│ │ │ +
420 }
│ │ │ +
│ │ │ +
421
│ │ │ +
423 template<class X, class Y>
│ │ │ +
│ │ │ +
424 constexpr void umtv (const X& x, Y& y) const
│ │ │ +
425 {
│ │ │ +
426 auto&& xx = Impl::asVector(x);
│ │ │ +
427 auto&& yy = Impl::asVector(y);
│ │ │ +
428 DUNE_ASSERT_BOUNDS(xx.N() == N());
│ │ │ +
429 DUNE_ASSERT_BOUNDS(yy.N() == M());
│ │ │ +
430 for(size_type i = 0; i<rows(); ++i)
│ │ │ +
431 for (size_type j=0; j<cols(); j++)
│ │ │ +
432 yy[j] += (*this)[i][j]*xx[i];
│ │ │ +
433 }
│ │ │ +
│ │ │ +
434
│ │ │ +
436 template<class X, class Y>
│ │ │ +
│ │ │ +
437 constexpr void umhv (const X& x, Y& y) const
│ │ │ +
438 {
│ │ │ +
439 auto&& xx = Impl::asVector(x);
│ │ │ +
440 auto&& yy = Impl::asVector(y);
│ │ │ +
441 DUNE_ASSERT_BOUNDS(xx.N() == N());
│ │ │ +
442 DUNE_ASSERT_BOUNDS(yy.N() == M());
│ │ │ +
443 for (size_type i=0; i<rows(); i++)
│ │ │ +
444 for (size_type j=0; j<cols(); j++)
│ │ │ +
445 yy[j] += conjugateComplex((*this)[i][j])*xx[i];
│ │ │ +
446 }
│ │ │ +
│ │ │ +
447
│ │ │ +
449 template<class X, class Y>
│ │ │ +
│ │ │ +
450 constexpr void mmv (const X& x, Y& y) const
│ │ │ +
451 {
│ │ │ +
452 auto&& xx = Impl::asVector(x);
│ │ │ +
453 auto&& yy = Impl::asVector(y);
│ │ │ +
454 DUNE_ASSERT_BOUNDS(xx.N() == M());
│ │ │ +
455 DUNE_ASSERT_BOUNDS(yy.N() == N());
│ │ │ +
456 for (size_type i=0; i<rows(); i++)
│ │ │ +
457 for (size_type j=0; j<cols(); j++)
│ │ │ +
458 yy[i] -= (*this)[i][j] * xx[j];
│ │ │ +
459 }
│ │ │ +
│ │ │ +
460
│ │ │ +
462 template<class X, class Y>
│ │ │ +
│ │ │ +
463 constexpr void mmtv (const X& x, Y& y) const
│ │ │ +
464 {
│ │ │ +
465 auto&& xx = Impl::asVector(x);
│ │ │ +
466 auto&& yy = Impl::asVector(y);
│ │ │ +
467 DUNE_ASSERT_BOUNDS(xx.N() == N());
│ │ │ +
468 DUNE_ASSERT_BOUNDS(yy.N() == M());
│ │ │ +
469 for (size_type i=0; i<rows(); i++)
│ │ │ +
470 for (size_type j=0; j<cols(); j++)
│ │ │ +
471 yy[j] -= (*this)[i][j]*xx[i];
│ │ │ +
472 }
│ │ │ +
│ │ │ +
473
│ │ │ +
475 template<class X, class Y>
│ │ │ +
│ │ │ +
476 constexpr void mmhv (const X& x, Y& y) const
│ │ │ +
477 {
│ │ │ +
478 auto&& xx = Impl::asVector(x);
│ │ │ +
479 auto&& yy = Impl::asVector(y);
│ │ │ +
480 DUNE_ASSERT_BOUNDS(xx.N() == N());
│ │ │ +
481 DUNE_ASSERT_BOUNDS(yy.N() == M());
│ │ │ +
482 for (size_type i=0; i<rows(); i++)
│ │ │ +
483 for (size_type j=0; j<cols(); j++)
│ │ │ +
484 yy[j] -= conjugateComplex((*this)[i][j])*xx[i];
│ │ │ +
485 }
│ │ │ +
│ │ │ +
486
│ │ │ +
488 template<class X, class Y>
│ │ │ +
│ │ │ +
489 constexpr void usmv (const typename FieldTraits<Y>::field_type & alpha,
│ │ │ +
490 const X& x, Y& y) const
│ │ │ +
491 {
│ │ │ +
492 auto&& xx = Impl::asVector(x);
│ │ │ +
493 auto&& yy = Impl::asVector(y);
│ │ │ +
494 DUNE_ASSERT_BOUNDS(xx.N() == M());
│ │ │ +
495 DUNE_ASSERT_BOUNDS(yy.N() == N());
│ │ │ +
496 for (size_type i=0; i<rows(); i++)
│ │ │ +
497 for (size_type j=0; j<cols(); j++)
│ │ │ +
498 yy[i] += alpha * (*this)[i][j] * xx[j];
│ │ │ +
499 }
│ │ │ +
│ │ │ +
500
│ │ │ +
502 template<class X, class Y>
│ │ │ +
│ │ │ +
503 constexpr void usmtv (const typename FieldTraits<Y>::field_type & alpha,
│ │ │ +
504 const X& x, Y& y) const
│ │ │ +
505 {
│ │ │ +
506 auto&& xx = Impl::asVector(x);
│ │ │ +
507 auto&& yy = Impl::asVector(y);
│ │ │ +
508 DUNE_ASSERT_BOUNDS(xx.N() == N());
│ │ │ +
509 DUNE_ASSERT_BOUNDS(yy.N() == M());
│ │ │ +
510 for (size_type i=0; i<rows(); i++)
│ │ │ +
511 for (size_type j=0; j<cols(); j++)
│ │ │ +
512 yy[j] += alpha*(*this)[i][j]*xx[i];
│ │ │ +
513 }
│ │ │ +
│ │ │ +
514
│ │ │ +
516 template<class X, class Y>
│ │ │ +
│ │ │ +
517 constexpr void usmhv (const typename FieldTraits<Y>::field_type & alpha,
│ │ │ +
518 const X& x, Y& y) const
│ │ │ +
519 {
│ │ │ +
520 auto&& xx = Impl::asVector(x);
│ │ │ +
521 auto&& yy = Impl::asVector(y);
│ │ │ +
522 DUNE_ASSERT_BOUNDS(xx.N() == N());
│ │ │ +
523 DUNE_ASSERT_BOUNDS(yy.N() == M());
│ │ │ +
524 for (size_type i=0; i<rows(); i++)
│ │ │ +
525 for (size_type j=0; j<cols(); j++)
│ │ │ +
526 yy[j] +=
│ │ │ +
527 alpha*conjugateComplex((*this)[i][j])*xx[i];
│ │ │ +
528 }
│ │ │ +
│ │ │ +
529
│ │ │ +
530 //===== norms
│ │ │ +
531
│ │ │ +
│ │ │ + │ │ │ +
534 {
│ │ │ +
535 typename FieldTraits<value_type>::real_type sum=(0.0);
│ │ │ +
536 for (size_type i=0; i<rows(); ++i) sum += (*this)[i].two_norm2();
│ │ │ +
537 return fvmeta::sqrt(sum);
│ │ │ +
538 }
│ │ │ +
│ │ │ +
539
│ │ │ +
│ │ │ + │ │ │ +
542 {
│ │ │ +
543 typename FieldTraits<value_type>::real_type sum=(0.0);
│ │ │ +
544 for (size_type i=0; i<rows(); ++i) sum += (*this)[i].two_norm2();
│ │ │ +
545 return sum;
│ │ │ +
546 }
│ │ │ +
│ │ │ +
547
│ │ │ +
549 template <typename vt = value_type,
│ │ │ +
550 typename std::enable_if<!HasNaN<vt>::value, int>::type = 0>
│ │ │ +
│ │ │ +
551 constexpr typename FieldTraits<vt>::real_type infinity_norm() const {
│ │ │ +
552 using real_type = typename FieldTraits<vt>::real_type;
│ │ │ +
553 using std::max;
│ │ │ +
554
│ │ │ +
555 real_type norm = 0;
│ │ │ +
556 for (auto const &x : *this) {
│ │ │ +
557 real_type const a = x.one_norm();
│ │ │ +
558 norm = max(a, norm);
│ │ │ +
559 }
│ │ │ +
560 return norm;
│ │ │ +
561 }
│ │ │ +
│ │ │ +
562
│ │ │ +
564 template <typename vt = value_type,
│ │ │ +
565 typename std::enable_if<!HasNaN<vt>::value, int>::type = 0>
│ │ │ +
│ │ │ + │ │ │ +
567 using real_type = typename FieldTraits<vt>::real_type;
│ │ │ +
568 using std::max;
│ │ │ +
569
│ │ │ +
570 real_type norm = 0;
│ │ │ +
571 for (auto const &x : *this) {
│ │ │ +
572 real_type const a = x.one_norm_real();
│ │ │ +
573 norm = max(a, norm);
│ │ │ +
574 }
│ │ │ +
575 return norm;
│ │ │ +
576 }
│ │ │ +
│ │ │ +
577
│ │ │ +
579 template <typename vt = value_type,
│ │ │ +
580 typename std::enable_if<HasNaN<vt>::value, int>::type = 0>
│ │ │ +
│ │ │ +
581 constexpr typename FieldTraits<vt>::real_type infinity_norm() const {
│ │ │ +
582 using real_type = typename FieldTraits<vt>::real_type;
│ │ │ +
583 using std::max;
│ │ │ +
584
│ │ │ +
585 real_type norm = 0;
│ │ │ +
586 real_type is_nan = 1;
│ │ │ +
587 for (auto const &x : *this) {
│ │ │ +
588 real_type const a = x.one_norm();
│ │ │ +
589 norm = max(a, norm);
│ │ │ +
590 is_nan += a;
│ │ │ +
591 }
│ │ │ +
592 return norm * (is_nan / is_nan);
│ │ │ +
593 }
│ │ │ +
│ │ │ +
594
│ │ │ +
596 template <typename vt = value_type,
│ │ │ +
597 typename std::enable_if<HasNaN<vt>::value, int>::type = 0>
│ │ │ +
│ │ │ + │ │ │ +
599 using real_type = typename FieldTraits<vt>::real_type;
│ │ │ +
600 using std::max;
│ │ │ +
601
│ │ │ +
602 real_type norm = 0;
│ │ │ +
603 real_type is_nan = 1;
│ │ │ +
604 for (auto const &x : *this) {
│ │ │ +
605 real_type const a = x.one_norm_real();
│ │ │ +
606 norm = max(a, norm);
│ │ │ +
607 is_nan += a;
│ │ │ +
608 }
│ │ │ +
609 return norm * (is_nan / is_nan);
│ │ │ +
610 }
│ │ │ +
│ │ │ +
611
│ │ │ +
612 //===== solve
│ │ │ +
613
│ │ │ +
618 template <class V1, class V2>
│ │ │ +
619 void solve (V1& x, const V2& b, bool doPivoting = true) const;
│ │ │ +
620
│ │ │ +
625 void invert(bool doPivoting = true);
│ │ │ +
626
│ │ │ +
628 field_type determinant (bool doPivoting = true) const;
│ │ │ +
629
│ │ │ +
631 template<typename M2>
│ │ │ +
│ │ │ + │ │ │ +
633 {
│ │ │ +
634 DUNE_ASSERT_BOUNDS(M.rows() == M.cols());
│ │ │ +
635 DUNE_ASSERT_BOUNDS(M.rows() == rows());
│ │ │ +
636 AutonomousValue<MAT> C(asImp());
│ │ │ +
637
│ │ │ +
638 for (size_type i=0; i<rows(); i++)
│ │ │ +
639 for (size_type j=0; j<cols(); j++) {
│ │ │ +
640 (*this)[i][j] = 0;
│ │ │ +
641 for (size_type k=0; k<rows(); k++)
│ │ │ +
642 (*this)[i][j] += M[i][k]*C[k][j];
│ │ │ +
643 }
│ │ │ +
644
│ │ │ +
645 return asImp();
│ │ │ +
646 }
│ │ │ +
│ │ │ +
647
│ │ │ +
649 template<typename M2>
│ │ │ +
│ │ │ + │ │ │ +
651 {
│ │ │ +
652 DUNE_ASSERT_BOUNDS(M.rows() == M.cols());
│ │ │ +
653 DUNE_ASSERT_BOUNDS(M.cols() == cols());
│ │ │ +
654 AutonomousValue<MAT> C(asImp());
│ │ │ +
655
│ │ │ +
656 for (size_type i=0; i<rows(); i++)
│ │ │ +
657 for (size_type j=0; j<cols(); j++) {
│ │ │ +
658 (*this)[i][j] = 0;
│ │ │ +
659 for (size_type k=0; k<cols(); k++)
│ │ │ +
660 (*this)[i][j] += C[i][k]*M[k][j];
│ │ │ +
661 }
│ │ │ +
662 return asImp();
│ │ │ +
663 }
│ │ │ +
│ │ │ +
664
│ │ │ +
665#if 0
│ │ │ +
667 template<int l>
│ │ │ +
668 DenseMatrix<K,l,cols> leftmultiplyany (const FieldMatrix<K,l,rows>& M) const
│ │ │ +
669 {
│ │ │ + │ │ │ +
671
│ │ │ +
672 for (size_type i=0; i<l; i++) {
│ │ │ +
673 for (size_type j=0; j<cols(); j++) {
│ │ │ +
674 C[i][j] = 0;
│ │ │ +
675 for (size_type k=0; k<rows(); k++)
│ │ │ +
676 C[i][j] += M[i][k]*(*this)[k][j];
│ │ │ +
677 }
│ │ │ +
678 }
│ │ │ +
679 return C;
│ │ │ +
680 }
│ │ │ +
681
│ │ │ +
683 template<int l>
│ │ │ +
684 FieldMatrix<K,rows,l> rightmultiplyany (const FieldMatrix<K,cols,l>& M) const
│ │ │ +
685 {
│ │ │ +
686 FieldMatrix<K,rows,l> C;
│ │ │ +
687
│ │ │ +
688 for (size_type i=0; i<rows(); i++) {
│ │ │ +
689 for (size_type j=0; j<l; j++) {
│ │ │ +
690 C[i][j] = 0;
│ │ │ +
691 for (size_type k=0; k<cols(); k++)
│ │ │ +
692 C[i][j] += (*this)[i][k]*M[k][j];
│ │ │ +
693 }
│ │ │ +
694 }
│ │ │ +
695 return C;
│ │ │ +
696 }
│ │ │ +
697#endif
│ │ │ +
698
│ │ │ +
699 //===== sizes
│ │ │ +
700
│ │ │ +
│ │ │ +
702 constexpr size_type N () const
│ │ │ +
703 {
│ │ │ +
704 return rows();
│ │ │ +
705 }
│ │ │ +
│ │ │ +
706
│ │ │ +
│ │ │ +
708 constexpr size_type M () const
│ │ │ +
709 {
│ │ │ +
710 return cols();
│ │ │ +
711 }
│ │ │ +
│ │ │ +
712
│ │ │ +
│ │ │ +
714 constexpr size_type rows() const
│ │ │ +
715 {
│ │ │ +
716 return asImp().mat_rows();
│ │ │ +
717 }
│ │ │ +
│ │ │ +
718
│ │ │ +
│ │ │ +
720 constexpr size_type cols() const
│ │ │ +
721 {
│ │ │ +
722 return asImp().mat_cols();
│ │ │ +
723 }
│ │ │ +
│ │ │ +
724
│ │ │ +
725 //===== query
│ │ │ +
726
│ │ │ +
│ │ │ +
728 constexpr bool exists ([[maybe_unused]] size_type i, [[maybe_unused]] size_type j) const
│ │ │ +
729 {
│ │ │ +
730 DUNE_ASSERT_BOUNDS(i >= 0 && i < rows());
│ │ │ +
731 DUNE_ASSERT_BOUNDS(j >= 0 && j < cols());
│ │ │ +
732 return true;
│ │ │ +
733 }
│ │ │ +
│ │ │ +
734
│ │ │ +
735 protected:
│ │ │ +
736
│ │ │ +
737#ifndef DOXYGEN
│ │ │ +
738 struct ElimPivot
│ │ │ +
739 {
│ │ │ +
740 ElimPivot(std::vector<simd_index_type> & pivot);
│ │ │ +
741
│ │ │ +
742 void swap(std::size_t i, simd_index_type j);
│ │ │ +
743
│ │ │ +
744 template<typename T>
│ │ │ +
745 void operator()(const T&, int, int)
│ │ │ +
746 {}
│ │ │ +
747
│ │ │ +
748 std::vector<simd_index_type> & pivot_;
│ │ │ +
749 };
│ │ │ +
750
│ │ │ +
751 template<typename V>
│ │ │ +
752 struct Elim
│ │ │ +
753 {
│ │ │ +
754 Elim(V& rhs);
│ │ │ +
755
│ │ │ +
756 void swap(std::size_t i, simd_index_type j);
│ │ │ +
757
│ │ │ +
758 void operator()(const typename V::field_type& factor, int k, int i);
│ │ │ +
759
│ │ │ +
760 V* rhs_;
│ │ │ +
761 };
│ │ │ +
762
│ │ │ +
763 struct ElimDet
│ │ │ +
764 {
│ │ │ +
765 ElimDet(field_type& sign) : sign_(sign)
│ │ │ +
766 { sign_ = 1; }
│ │ │ +
767
│ │ │ +
768 void swap(std::size_t i, simd_index_type j)
│ │ │ +
769 {
│ │ │ +
770 sign_ *=
│ │ │ +
771 Simd::cond(simd_index_type(i) == j, field_type(1), field_type(-1));
│ │ │ +
772 }
│ │ │ +
773
│ │ │ +
774 void operator()(const field_type&, int, int)
│ │ │ +
775 {}
│ │ │ +
776
│ │ │ +
777 field_type& sign_;
│ │ │ +
778 };
│ │ │ +
779#endif // DOXYGEN
│ │ │ +
780
│ │ │ +
782
│ │ │ +
820 template<class Func, class Mask>
│ │ │ +
821 static void luDecomposition(DenseMatrix<MAT>& A, Func func,
│ │ │ +
822 Mask &nonsingularLanes, bool throwEarly, bool doPivoting);
│ │ │ +
823 };
│ │ │ +
│ │ │ +
824
│ │ │ +
825#ifndef DOXYGEN
│ │ │ +
826 template<typename MAT>
│ │ │ +
827 DenseMatrix<MAT>::ElimPivot::ElimPivot(std::vector<simd_index_type> & pivot)
│ │ │ +
828 : pivot_(pivot)
│ │ │ +
829 {
│ │ │ +
830 for(typename std::vector<size_type>::size_type i=0; i < pivot_.size(); ++i)
│ │ │ +
831 pivot_[i]=i;
│ │ │ +
832 }
│ │ │ +
833
│ │ │ +
834 template<typename MAT>
│ │ │ +
835 void DenseMatrix<MAT>::ElimPivot::swap(std::size_t i, simd_index_type j)
│ │ │ +
836 {
│ │ │ +
837 pivot_[i] =
│ │ │ +
838 Simd::cond(Simd::Scalar<simd_index_type>(i) == j, pivot_[i], j);
│ │ │ +
839 }
│ │ │ +
840
│ │ │ +
841 template<typename MAT>
│ │ │ +
842 template<typename V>
│ │ │ + │ │ │ +
844 : rhs_(&rhs)
│ │ │ +
845 {}
│ │ │ +
846
│ │ │ +
847 template<typename MAT>
│ │ │ +
848 template<typename V>
│ │ │ +
849 void DenseMatrix<MAT>::Elim<V>::swap(std::size_t i, simd_index_type j)
│ │ │ +
850 {
│ │ │ +
851 using std::swap;
│ │ │ +
852
│ │ │ +
853 // see the comment in luDecomposition()
│ │ │ +
854 for(std::size_t l = 0; l < Simd::lanes(j); ++l)
│ │ │ +
855 swap(Simd::lane(l, (*rhs_)[ i ]),
│ │ │ +
856 Simd::lane(l, (*rhs_)[Simd::lane(l, j)]));
│ │ │ +
857 }
│ │ │ +
858
│ │ │ +
859 template<typename MAT>
│ │ │ +
860 template<typename V>
│ │ │ + │ │ │ +
862 Elim<V>::operator()(const typename V::field_type& factor, int k, int i)
│ │ │ +
863 {
│ │ │ +
864 (*rhs_)[k] -= factor*(*rhs_)[i];
│ │ │ +
865 }
│ │ │ +
866
│ │ │ +
867 template<typename MAT>
│ │ │ +
868 template<typename Func, class Mask>
│ │ │ +
869 inline void DenseMatrix<MAT>::
│ │ │ +
870 luDecomposition(DenseMatrix<MAT>& A, Func func, Mask &nonsingularLanes,
│ │ │ +
871 bool throwEarly, bool doPivoting)
│ │ │ +
872 {
│ │ │ +
873 using std::max;
│ │ │ +
874 using std::swap;
│ │ │ +
875
│ │ │ + │ │ │ +
877
│ │ │ +
878 // LU decomposition of A in A
│ │ │ +
879 for (size_type i=0; i<A.rows(); i++) // loop over all rows
│ │ │ +
880 {
│ │ │ +
881 real_type pivmax = fvmeta::absreal(A[i][i]);
│ │ │ +
882
│ │ │ +
883 if (doPivoting)
│ │ │ +
884 {
│ │ │ +
885 // compute maximum of column
│ │ │ +
886 simd_index_type imax=i;
│ │ │ +
887 for (size_type k=i+1; k<A.rows(); k++)
│ │ │ +
888 {
│ │ │ +
889 auto abs = fvmeta::absreal(A[k][i]);
│ │ │ +
890 auto mask = abs > pivmax;
│ │ │ +
891 pivmax = Simd::cond(mask, abs, pivmax);
│ │ │ +
892 imax = Simd::cond(mask, simd_index_type(k), imax);
│ │ │ +
893 }
│ │ │ +
894 // swap rows
│ │ │ +
895 for (size_type j=0; j<A.rows(); j++)
│ │ │ +
896 {
│ │ │ +
897 // This is a swap operation where the second operand is scattered,
│ │ │ +
898 // and on top of that is also extracted from deep within a
│ │ │ +
899 // moderately complicated data structure (a DenseMatrix), where we
│ │ │ +
900 // can't assume much on the memory layout. On intel processors,
│ │ │ +
901 // the only instruction that might help us here is vgather, but it
│ │ │ +
902 // is unclear whether that is even faster than a software
│ │ │ +
903 // implementation, and we would also need vscatter which does not
│ │ │ +
904 // exist. So break vectorization here and do it manually.
│ │ │ +
905 for(std::size_t l = 0; l < Simd::lanes(A[i][j]); ++l)
│ │ │ +
906 swap(Simd::lane(l, A[i][j]),
│ │ │ +
907 Simd::lane(l, A[Simd::lane(l, imax)][j]));
│ │ │ +
908 }
│ │ │ +
909 func.swap(i, imax); // swap the pivot or rhs
│ │ │ +
910 }
│ │ │ +
911
│ │ │ +
912 // singular ?
│ │ │ +
913 nonsingularLanes = nonsingularLanes && (pivmax != real_type(0));
│ │ │ +
914 if (throwEarly) {
│ │ │ +
915 if(!Simd::allTrue(nonsingularLanes))
│ │ │ +
916 DUNE_THROW(FMatrixError, "matrix is singular");
│ │ │ +
917 }
│ │ │ +
918 else { // !throwEarly
│ │ │ +
919 if(!Simd::anyTrue(nonsingularLanes))
│ │ │ +
920 return;
│ │ │ +
921 }
│ │ │ +
922
│ │ │ +
923 // eliminate
│ │ │ +
924 for (size_type k=i+1; k<A.rows(); k++)
│ │ │ +
925 {
│ │ │ +
926 // in the simd case, A[i][i] may be close to zero in some lanes. Pray
│ │ │ +
927 // that the result is no worse than a quiet NaN.
│ │ │ +
928 field_type factor = A[k][i]/A[i][i];
│ │ │ +
929 A[k][i] = factor;
│ │ │ +
930 for (size_type j=i+1; j<A.rows(); j++)
│ │ │ +
931 A[k][j] -= factor*A[i][j];
│ │ │ +
932 func(factor, k, i);
│ │ │ +
933 }
│ │ │ +
934 }
│ │ │ +
935 }
│ │ │ +
936
│ │ │ +
937 template<typename MAT>
│ │ │ +
938 template <class V1, class V2>
│ │ │ +
939 inline void DenseMatrix<MAT>::solve(V1& x, const V2& b, bool doPivoting) const
│ │ │ +
940 {
│ │ │ + │ │ │ +
942 // never mind those ifs, because they get optimized away
│ │ │ +
943 if (rows()!=cols())
│ │ │ +
944 DUNE_THROW(FMatrixError, "Can't solve for a " << rows() << "x" << cols() << " matrix!");
│ │ │ +
945
│ │ │ +
946 if (rows()==1) {
│ │ │ +
947
│ │ │ +
948#ifdef DUNE_FMatrix_WITH_CHECKING
│ │ │ +
949 if (Simd::anyTrue(fvmeta::absreal((*this)[0][0])
│ │ │ + │ │ │ +
951 DUNE_THROW(FMatrixError,"matrix is singular");
│ │ │ +
952#endif
│ │ │ +
953 x[0] = b[0]/(*this)[0][0];
│ │ │ +
954
│ │ │ +
955 }
│ │ │ +
956 else if (rows()==2) {
│ │ │ +
957
│ │ │ +
958 field_type detinv = (*this)[0][0]*(*this)[1][1]-(*this)[0][1]*(*this)[1][0];
│ │ │ +
959#ifdef DUNE_FMatrix_WITH_CHECKING
│ │ │ +
960 if (Simd::anyTrue(fvmeta::absreal(detinv)
│ │ │ + │ │ │ +
962 DUNE_THROW(FMatrixError,"matrix is singular");
│ │ │ +
963#endif
│ │ │ +
964 detinv = real_type(1.0)/detinv;
│ │ │ +
965
│ │ │ +
966 x[0] = detinv*((*this)[1][1]*b[0]-(*this)[0][1]*b[1]);
│ │ │ +
967 x[1] = detinv*((*this)[0][0]*b[1]-(*this)[1][0]*b[0]);
│ │ │ +
968
│ │ │ +
969 }
│ │ │ +
970 else if (rows()==3) {
│ │ │ +
971
│ │ │ +
972 field_type d = determinant(doPivoting);
│ │ │ +
973#ifdef DUNE_FMatrix_WITH_CHECKING
│ │ │ +
974 if (Simd::anyTrue(fvmeta::absreal(d)
│ │ │ + │ │ │ +
976 DUNE_THROW(FMatrixError,"matrix is singular");
│ │ │ +
977#endif
│ │ │ +
978
│ │ │ +
979 x[0] = (b[0]*(*this)[1][1]*(*this)[2][2] - b[0]*(*this)[2][1]*(*this)[1][2]
│ │ │ +
980 - b[1] *(*this)[0][1]*(*this)[2][2] + b[1]*(*this)[2][1]*(*this)[0][2]
│ │ │ +
981 + b[2] *(*this)[0][1]*(*this)[1][2] - b[2]*(*this)[1][1]*(*this)[0][2]) / d;
│ │ │ +
982
│ │ │ +
983 x[1] = ((*this)[0][0]*b[1]*(*this)[2][2] - (*this)[0][0]*b[2]*(*this)[1][2]
│ │ │ +
984 - (*this)[1][0] *b[0]*(*this)[2][2] + (*this)[1][0]*b[2]*(*this)[0][2]
│ │ │ +
985 + (*this)[2][0] *b[0]*(*this)[1][2] - (*this)[2][0]*b[1]*(*this)[0][2]) / d;
│ │ │ +
986
│ │ │ +
987 x[2] = ((*this)[0][0]*(*this)[1][1]*b[2] - (*this)[0][0]*(*this)[2][1]*b[1]
│ │ │ +
988 - (*this)[1][0] *(*this)[0][1]*b[2] + (*this)[1][0]*(*this)[2][1]*b[0]
│ │ │ +
989 + (*this)[2][0] *(*this)[0][1]*b[1] - (*this)[2][0]*(*this)[1][1]*b[0]) / d;
│ │ │ +
990
│ │ │ +
991 }
│ │ │ +
992 else {
│ │ │ +
993
│ │ │ +
994 V1& rhs = x; // use x to store rhs
│ │ │ +
995 rhs = b; // copy data
│ │ │ +
996 Elim<V1> elim(rhs);
│ │ │ +
997 AutonomousValue<MAT> A(asImp());
│ │ │ + │ │ │ +
999 nonsingularLanes(true);
│ │ │ +
1000
│ │ │ +
1001 AutonomousValue<MAT>::luDecomposition(A, elim, nonsingularLanes, true, doPivoting);
│ │ │ +
1002
│ │ │ +
1003 // backsolve
│ │ │ +
1004 for(int i=rows()-1; i>=0; i--) {
│ │ │ +
1005 for (size_type j=i+1; j<rows(); j++)
│ │ │ +
1006 rhs[i] -= A[i][j]*x[j];
│ │ │ +
1007 x[i] = rhs[i]/A[i][i];
│ │ │ +
1008 }
│ │ │ +
1009 }
│ │ │ +
1010 }
│ │ │ +
1011
│ │ │ +
1012 template<typename MAT>
│ │ │ +
1013 inline void DenseMatrix<MAT>::invert(bool doPivoting)
│ │ │ +
1014 {
│ │ │ +
1015 using real_type = typename FieldTraits<MAT>::real_type;
│ │ │ +
1016 using std::swap;
│ │ │ +
1017
│ │ │ +
1018 // never mind those ifs, because they get optimized away
│ │ │ +
1019 if (rows()!=cols())
│ │ │ +
1020 DUNE_THROW(FMatrixError, "Can't invert a " << rows() << "x" << cols() << " matrix!");
│ │ │ +
1021
│ │ │ +
1022 if (rows()==1) {
│ │ │ +
1023
│ │ │ +
1024#ifdef DUNE_FMatrix_WITH_CHECKING
│ │ │ +
1025 if (Simd::anyTrue(fvmeta::absreal((*this)[0][0])
│ │ │ + │ │ │ +
1027 DUNE_THROW(FMatrixError,"matrix is singular");
│ │ │ +
1028#endif
│ │ │ +
1029 (*this)[0][0] = real_type( 1 ) / (*this)[0][0];
│ │ │ +
1030
│ │ │ +
1031 }
│ │ │ +
1032 else if (rows()==2) {
│ │ │ +
1033
│ │ │ +
1034 field_type detinv = (*this)[0][0]*(*this)[1][1]-(*this)[0][1]*(*this)[1][0];
│ │ │ +
1035#ifdef DUNE_FMatrix_WITH_CHECKING
│ │ │ +
1036 if (Simd::anyTrue(fvmeta::absreal(detinv)
│ │ │ + │ │ │ +
1038 DUNE_THROW(FMatrixError,"matrix is singular");
│ │ │ +
1039#endif
│ │ │ +
1040 detinv = real_type( 1 ) / detinv;
│ │ │ +
1041
│ │ │ +
1042 field_type temp=(*this)[0][0];
│ │ │ +
1043 (*this)[0][0] = (*this)[1][1]*detinv;
│ │ │ +
1044 (*this)[0][1] = -(*this)[0][1]*detinv;
│ │ │ +
1045 (*this)[1][0] = -(*this)[1][0]*detinv;
│ │ │ +
1046 (*this)[1][1] = temp*detinv;
│ │ │ +
1047
│ │ │ +
1048 }
│ │ │ +
1049 else if (rows()==3)
│ │ │ +
1050 {
│ │ │ +
1051 using K = field_type;
│ │ │ +
1052 // code generated by maple
│ │ │ +
1053 K t4 = (*this)[0][0] * (*this)[1][1];
│ │ │ +
1054 K t6 = (*this)[0][0] * (*this)[1][2];
│ │ │ +
1055 K t8 = (*this)[0][1] * (*this)[1][0];
│ │ │ +
1056 K t10 = (*this)[0][2] * (*this)[1][0];
│ │ │ +
1057 K t12 = (*this)[0][1] * (*this)[2][0];
│ │ │ +
1058 K t14 = (*this)[0][2] * (*this)[2][0];
│ │ │ +
1059
│ │ │ +
1060 K det = (t4*(*this)[2][2]-t6*(*this)[2][1]-t8*(*this)[2][2]+
│ │ │ +
1061 t10*(*this)[2][1]+t12*(*this)[1][2]-t14*(*this)[1][1]);
│ │ │ +
1062 K t17 = K(1.0)/det;
│ │ │ +
1063
│ │ │ +
1064 K matrix01 = (*this)[0][1];
│ │ │ +
1065 K matrix00 = (*this)[0][0];
│ │ │ +
1066 K matrix10 = (*this)[1][0];
│ │ │ +
1067 K matrix11 = (*this)[1][1];
│ │ │ +
1068
│ │ │ +
1069 (*this)[0][0] = ((*this)[1][1] * (*this)[2][2] - (*this)[1][2] * (*this)[2][1])*t17;
│ │ │ +
1070 (*this)[0][1] = -((*this)[0][1] * (*this)[2][2] - (*this)[0][2] * (*this)[2][1])*t17;
│ │ │ +
1071 (*this)[0][2] = (matrix01 * (*this)[1][2] - (*this)[0][2] * (*this)[1][1])*t17;
│ │ │ +
1072 (*this)[1][0] = -((*this)[1][0] * (*this)[2][2] - (*this)[1][2] * (*this)[2][0])*t17;
│ │ │ +
1073 (*this)[1][1] = (matrix00 * (*this)[2][2] - t14) * t17;
│ │ │ +
1074 (*this)[1][2] = -(t6-t10) * t17;
│ │ │ +
1075 (*this)[2][0] = (matrix10 * (*this)[2][1] - matrix11 * (*this)[2][0]) * t17;
│ │ │ +
1076 (*this)[2][1] = -(matrix00 * (*this)[2][1] - t12) * t17;
│ │ │ +
1077 (*this)[2][2] = (t4-t8) * t17;
│ │ │ +
1078 }
│ │ │ +
1079 else {
│ │ │ +
1080 using std::swap;
│ │ │ +
1081
│ │ │ +
1082 AutonomousValue<MAT> A(asImp());
│ │ │ +
1083 std::vector<simd_index_type> pivot(rows());
│ │ │ + │ │ │ +
1085 nonsingularLanes(true);
│ │ │ +
1086 AutonomousValue<MAT>::luDecomposition(A, ElimPivot(pivot), nonsingularLanes, true, doPivoting);
│ │ │ +
1087 auto& L=A;
│ │ │ +
1088 auto& U=A;
│ │ │ +
1089
│ │ │ +
1090 // initialize inverse
│ │ │ +
1091 *this=field_type();
│ │ │ +
1092
│ │ │ +
1093 for(size_type i=0; i<rows(); ++i)
│ │ │ +
1094 (*this)[i][i]=1;
│ │ │ +
1095
│ │ │ +
1096 // L Y = I; multiple right hand sides
│ │ │ +
1097 for (size_type i=0; i<rows(); i++)
│ │ │ +
1098 for (size_type j=0; j<i; j++)
│ │ │ +
1099 for (size_type k=0; k<rows(); k++)
│ │ │ +
1100 (*this)[i][k] -= L[i][j]*(*this)[j][k];
│ │ │ +
1101
│ │ │ +
1102 // U A^{-1} = Y
│ │ │ +
1103 for (size_type i=rows(); i>0;) {
│ │ │ +
1104 --i;
│ │ │ +
1105 for (size_type k=0; k<rows(); k++) {
│ │ │ +
1106 for (size_type j=i+1; j<rows(); j++)
│ │ │ +
1107 (*this)[i][k] -= U[i][j]*(*this)[j][k];
│ │ │ +
1108 (*this)[i][k] /= U[i][i];
│ │ │ +
1109 }
│ │ │ +
1110 }
│ │ │ +
1111
│ │ │ +
1112 for(size_type i=rows(); i>0; ) {
│ │ │ +
1113 --i;
│ │ │ +
1114 for(std::size_t l = 0; l < Simd::lanes((*this)[0][0]); ++l)
│ │ │ +
1115 {
│ │ │ +
1116 std::size_t pi = Simd::lane(l, pivot[i]);
│ │ │ +
1117 if(i!=pi)
│ │ │ +
1118 for(size_type j=0; j<rows(); ++j)
│ │ │ +
1119 swap(Simd::lane(l, (*this)[j][pi]),
│ │ │ +
1120 Simd::lane(l, (*this)[j][ i]));
│ │ │ +
1121 }
│ │ │ +
1122 }
│ │ │ +
1123 }
│ │ │ +
1124 }
│ │ │ +
1125
│ │ │ +
1126 // implementation of the determinant
│ │ │ +
1127 template<typename MAT>
│ │ │ +
1128 inline typename DenseMatrix<MAT>::field_type
│ │ │ +
1129 DenseMatrix<MAT>::determinant(bool doPivoting) const
│ │ │ +
1130 {
│ │ │ +
1131 // never mind those ifs, because they get optimized away
│ │ │ +
1132 if (rows()!=cols())
│ │ │ +
1133 DUNE_THROW(FMatrixError, "There is no determinant for a " << rows() << "x" << cols() << " matrix!");
│ │ │ +
1134
│ │ │ +
1135 if (rows()==1)
│ │ │ +
1136 return (*this)[0][0];
│ │ │ +
1137
│ │ │ +
1138 if (rows()==2)
│ │ │ +
1139 return (*this)[0][0]*(*this)[1][1] - (*this)[0][1]*(*this)[1][0];
│ │ │ +
1140
│ │ │ +
1141 if (rows()==3) {
│ │ │ +
1142 // code generated by maple
│ │ │ +
1143 field_type t4 = (*this)[0][0] * (*this)[1][1];
│ │ │ +
1144 field_type t6 = (*this)[0][0] * (*this)[1][2];
│ │ │ +
1145 field_type t8 = (*this)[0][1] * (*this)[1][0];
│ │ │ +
1146 field_type t10 = (*this)[0][2] * (*this)[1][0];
│ │ │ +
1147 field_type t12 = (*this)[0][1] * (*this)[2][0];
│ │ │ +
1148 field_type t14 = (*this)[0][2] * (*this)[2][0];
│ │ │ +
1149
│ │ │ +
1150 return (t4*(*this)[2][2]-t6*(*this)[2][1]-t8*(*this)[2][2]+
│ │ │ +
1151 t10*(*this)[2][1]+t12*(*this)[1][2]-t14*(*this)[1][1]);
│ │ │ +
1152
│ │ │ +
1153 }
│ │ │ +
1154
│ │ │ +
1155 AutonomousValue<MAT> A(asImp());
│ │ │ +
1156 field_type det;
│ │ │ + │ │ │ +
1158 nonsingularLanes(true);
│ │ │ +
1159
│ │ │ +
1160 AutonomousValue<MAT>::luDecomposition(A, ElimDet(det), nonsingularLanes, false, doPivoting);
│ │ │ +
1161 det = Simd::cond(nonsingularLanes, det, field_type(0));
│ │ │ +
1162
│ │ │ +
1163 for (size_type i = 0; i < rows(); ++i)
│ │ │ +
1164 det *= A[i][i];
│ │ │ +
1165 return det;
│ │ │ +
1166 }
│ │ │ +
1167
│ │ │ +
1168#endif // DOXYGEN
│ │ │ +
1169
│ │ │ +
│ │ │ + │ │ │ +
1171
│ │ │ +
1173 template <typename MAT, typename V1, typename V2>
│ │ │ +
│ │ │ +
1174 static inline void multAssign(const DenseMatrix<MAT> &matrix, const DenseVector<V1> & x, DenseVector<V2> & ret)
│ │ │ +
1175 {
│ │ │ +
1176 DUNE_ASSERT_BOUNDS(x.size() == matrix.cols());
│ │ │ +
1177 DUNE_ASSERT_BOUNDS(ret.size() == matrix.rows());
│ │ │ +
1178 typedef typename DenseMatrix<MAT>::size_type size_type;
│ │ │ +
1179
│ │ │ +
1180 for(size_type i=0; i<matrix.rows(); ++i)
│ │ │ +
1181 {
│ │ │ +
1182 ret[i] = 0.0;
│ │ │ +
1183 for(size_type j=0; j<matrix.cols(); ++j)
│ │ │ +
1184 {
│ │ │ +
1185 ret[i] += matrix[i][j]*x[j];
│ │ │ +
1186 }
│ │ │ +
1187 }
│ │ │ +
1188 }
│ │ │ +
│ │ │ +
1189
│ │ │ +
1190#if 0
│ │ │ +
1192 template <typename K, int rows, int cols>
│ │ │ +
1193 static inline void multAssignTransposed( const FieldMatrix<K,rows,cols> &matrix, const FieldVector<K,rows> & x, FieldVector<K,cols> & ret)
│ │ │ +
1194 {
│ │ │ +
1195 typedef typename FieldMatrix<K,rows,cols>::size_type size_type;
│ │ │ +
1196
│ │ │ +
1197 for(size_type i=0; i<cols(); ++i)
│ │ │ +
1198 {
│ │ │ +
1199 ret[i] = 0.0;
│ │ │ +
1200 for(size_type j=0; j<rows(); ++j)
│ │ │ +
1201 ret[i] += matrix[j][i]*x[j];
│ │ │ +
1202 }
│ │ │ +
1203 }
│ │ │ +
1204
│ │ │ +
1206 template <typename K, int rows, int cols>
│ │ │ +
1207 static inline FieldVector<K,rows> mult(const FieldMatrix<K,rows,cols> &matrix, const FieldVector<K,cols> & x)
│ │ │ +
1208 {
│ │ │ +
1209 FieldVector<K,rows> ret;
│ │ │ +
1210 multAssign(matrix,x,ret);
│ │ │ +
1211 return ret;
│ │ │ +
1212 }
│ │ │ +
1213
│ │ │ +
1215 template <typename K, int rows, int cols>
│ │ │ +
1216 static inline FieldVector<K,cols> multTransposed(const FieldMatrix<K,rows,cols> &matrix, const FieldVector<K,rows> & x)
│ │ │ +
1217 {
│ │ │ +
1218 FieldVector<K,cols> ret;
│ │ │ +
1219 multAssignTransposed( matrix, x, ret );
│ │ │ +
1220 return ret;
│ │ │ +
1221 }
│ │ │ +
1222#endif
│ │ │ +
1223
│ │ │ +
1224 } // end namespace DenseMatrixHelp
│ │ │ +
│ │ │ +
1225
│ │ │ +
1227 template<typename MAT>
│ │ │ +
│ │ │ +
1228 std::ostream& operator<< (std::ostream& s, const DenseMatrix<MAT>& a)
│ │ │ +
1229 {
│ │ │ +
1230 for (typename DenseMatrix<MAT>::size_type i=0; i<a.rows(); i++)
│ │ │ +
1231 s << a[i] << std::endl;
│ │ │ +
1232 return s;
│ │ │ +
1233 }
│ │ │ +
│ │ │ +
1234
│ │ │ +
1236
│ │ │ +
1237} // end namespace Dune
│ │ │ +
1238
│ │ │ +
1239#endif
│ │ │ +
Implements a scalar vector view wrapper around an existing scalar.
│ │ │ +
Implements a vector constructed from a given type representing a field and a compile-time given size.
│ │ │ +
Macro for wrapping boundary checks.
│ │ │ +
Some useful basic math stuff.
│ │ │ +
A few common exception classes.
│ │ │ + │ │ │ +
Various precision settings for calculations with FieldMatrix and FieldVector.
│ │ │ +
A free function to provide the demangled class name of a given object or type as a string.
│ │ │ +
Traits for type conversions and type information.
│ │ │ +
#define DUNE_ASSERT_BOUNDS(cond)
If DUNE_CHECK_BOUNDS is defined: check if condition cond holds; otherwise, do nothing.
Definition boundschecking.hh:30
│ │ │ +
typename AutonomousValueType< T >::type AutonomousValue
Type free of internal references that T can be converted to.
Definition typetraits.hh:566
│ │ │ +
std::ostream & operator<<(std::ostream &s, const bigunsignedint< k > &x)
Definition bigunsignedint.hh:301
│ │ │ +
#define DUNE_THROW(E,...)
Definition exceptions.hh:314
│ │ │ +
bool anyTrue(const Mask &mask)
Whether any entry is true.
Definition simd/interface.hh:429
│ │ │ +
V cond(M &&mask, const V &ifTrue, const V &ifFalse)
Like the ?: operator.
Definition simd/interface.hh:386
│ │ │ +
bool allTrue(const Mask &mask)
Whether all entries are true.
Definition simd/interface.hh:439
│ │ │ +
typename Overloads::ScalarType< std::decay_t< V > >::type Scalar
Element type of some SIMD type.
Definition simd/interface.hh:235
│ │ │ +
Rebind< bool, V > Mask
Mask type type of some SIMD type.
Definition simd/interface.hh:289
│ │ │ +
typename Overloads::RebindType< std::decay_t< S >, std::decay_t< V > >::type Rebind
Construct SIMD type with different scalar type.
Definition simd/interface.hh:252
│ │ │ +
constexpr std::size_t lanes()
Number of lanes in a SIMD type.
Definition simd/interface.hh:305
│ │ │ +
decltype(auto) lane(std::size_t l, V &&v)
Extract an element of a SIMD type.
Definition simd/interface.hh:324
│ │ │ +
Mask< V > mask(ADLTag< 0, std::is_same< V, Mask< V > >::value >, const V &v)
implements Simd::mask()
Definition defaults.hh:153
│ │ │ +
Dune namespace
Definition alignedallocator.hh:13
│ │ │ +
constexpr int sign(const T &val)
Return the sign of the value.
Definition math.hh:162
│ │ │ +
void swap(T &v1, T &v2, bool mask)
Definition simd.hh:472
│ │ │ +
constexpr K conjugateComplex(const K &x)
compute conjugate complex of x
Definition math.hh:146
│ │ │ +
Definition densematrix.hh:1170
│ │ │ +
static void multAssign(const DenseMatrix< MAT > &matrix, const DenseVector< V1 > &x, DenseVector< V2 > &ret)
calculates ret = matrix * x
Definition densematrix.hh:1174
│ │ │ +
constexpr T abs(T t)
Definition cmath.hh:27
│ │ │ +
Whether this type acts as a scalar in the context of (hierarchically blocked) containers.
Definition typetraits.hh:194
│ │ │ +
A dense n x m matrix.
Definition densematrix.hh:145
│ │ │ +
ConstIterator const_iterator
typedef for stl compliant access
Definition densematrix.hh:249
│ │ │ +
constexpr derived_type & operator+=(const DenseMatrix< Other > &x)
vector space addition
Definition densematrix.hh:294
│ │ │ +
constexpr Iterator beforeBegin()
Definition densematrix.hh:241
│ │ │ +
constexpr void umhv(const X &x, Y &y) const
y += A^H x
Definition densematrix.hh:437
│ │ │ +
constexpr derived_type & operator*=(const field_type &k)
vector space multiplication with scalar
Definition densematrix.hh:326
│ │ │ +
constexpr void usmhv(const typename FieldTraits< Y >::field_type &alpha, const X &x, Y &y) const
y += alpha A^H x
Definition densematrix.hh:517
│ │ │ +
constexpr derived_type & operator-=(const DenseMatrix< Other > &x)
vector space subtraction
Definition densematrix.hh:317
│ │ │ +
void solve(V1 &x, const V2 &b, bool doPivoting=true) const
Solve system A x = b.
│ │ │ +
Traits::value_type field_type
export the type representing the field
Definition densematrix.hh:165
│ │ │ +
constexpr ConstIterator beforeEnd() const
Definition densematrix.hh:269
│ │ │ +
constexpr bool operator!=(const DenseMatrix< Other > &x) const
Binary matrix incomparison.
Definition densematrix.hh:363
│ │ │ +
constexpr derived_type & axpy(const field_type &a, const DenseMatrix< Other > &x)
vector space axpy operation (*this += a x)
Definition densematrix.hh:343
│ │ │ +
std::remove_reference< const_row_reference >::type::ConstIterator ConstColIterator
rename the iterators for easier access
Definition densematrix.hh:253
│ │ │ +
void invert(bool doPivoting=true)
Compute inverse.
│ │ │ +
constexpr void usmtv(const typename FieldTraits< Y >::field_type &alpha, const X &x, Y &y) const
y += alpha A^T x
Definition densematrix.hh:503
│ │ │ +
static void luDecomposition(DenseMatrix< MAT > &A, Func func, Mask &nonsingularLanes, bool throwEarly, bool doPivoting)
do an LU-Decomposition on matrix A
│ │ │ +
Traits::value_type block_type
export the type representing the components
Definition densematrix.hh:168
│ │ │ +
constexpr size_type cols() const
number of columns
Definition densematrix.hh:720
│ │ │ +
constexpr size_type size() const
size method (number of rows)
Definition densematrix.hh:205
│ │ │ +
constexpr size_type M() const
Definition densematrix.hh:708
│ │ │ +
constexpr void mmhv(const X &x, Y &y) const
y -= A^H x
Definition densematrix.hh:476
│ │ │ +
MAT & rightmultiply(const DenseMatrix< M2 > &M)
Multiplies M from the right to this matrix.
Definition densematrix.hh:650
│ │ │ +
constexpr Iterator beforeEnd()
Definition densematrix.hh:234
│ │ │ +
constexpr ConstIterator beforeBegin() const
Definition densematrix.hh:276
│ │ │ +
constexpr FieldTraits< value_type >::real_type frobenius_norm() const
frobenius norm: sqrt(sum over squared values of entries)
Definition densematrix.hh:533
│ │ │ +
Traits::value_type value_type
export the type representing the field
Definition densematrix.hh:162
│ │ │ +
constexpr Iterator end()
end iterator
Definition densematrix.hh:227
│ │ │ +
constexpr derived_type & operator/=(const field_type &k)
vector space division by scalar
Definition densematrix.hh:334
│ │ │ +
constexpr derived_type operator-() const
Matrix negation.
Definition densematrix.hh:303
│ │ │ +
constexpr size_type rows() const
number of rows
Definition densematrix.hh:714
│ │ │ +
constexpr void mv(const X &x, Y &y) const
y = A x
Definition densematrix.hh:373
│ │ │ +
MAT & leftmultiply(const DenseMatrix< M2 > &M)
Multiplies M from the left to this matrix.
Definition densematrix.hh:632
│ │ │ +
constexpr void mtv(const X &x, Y &y) const
y = A^T x
Definition densematrix.hh:392
│ │ │ +
constexpr FieldTraits< vt >::real_type infinity_norm() const
infinity norm (row sum norm, how to generalize for blocks?)
Definition densematrix.hh:551
│ │ │ +
constexpr row_reference operator[](size_type i)
random access
Definition densematrix.hh:194
│ │ │ +
constexpr void umv(const X &x, Y &y) const
y += A x
Definition densematrix.hh:411
│ │ │ +
Traits::derived_type derived_type
type of derived matrix class
Definition densematrix.hh:159
│ │ │ +
constexpr bool exists(size_type i, size_type j) const
return true when (i,j) is in pattern
Definition densematrix.hh:728
│ │ │ +
constexpr void usmv(const typename FieldTraits< Y >::field_type &alpha, const X &x, Y &y) const
y += alpha A x
Definition densematrix.hh:489
│ │ │ +
Iterator RowIterator
rename the iterators for easier access
Definition densematrix.hh:216
│ │ │ +
static constexpr int blocklevel
Definition densematrix.hh:183
│ │ │ +
constexpr ConstIterator begin() const
begin iterator
Definition densematrix.hh:256
│ │ │ +
constexpr void umtv(const X &x, Y &y) const
y += A^T x
Definition densematrix.hh:424
│ │ │ +
DenseIterator< const DenseMatrix, const row_type, const_row_reference > ConstIterator
Iterator class for sequential access.
Definition densematrix.hh:247
│ │ │ +
constexpr void mmtv(const X &x, Y &y) const
y -= A^T x
Definition densematrix.hh:463
│ │ │ +
constexpr ConstIterator end() const
end iterator
Definition densematrix.hh:262
│ │ │ +
constexpr FieldTraits< value_type >::real_type frobenius_norm2() const
square of frobenius norm, need for block recursion
Definition densematrix.hh:541
│ │ │ +
Traits::row_type row_type
The type used to represent a row (must fulfill the Dune::DenseVector interface).
Definition densematrix.hh:174
│ │ │ +
constexpr size_type N() const
Definition densematrix.hh:702
│ │ │ +
constexpr bool operator==(const DenseMatrix< Other > &x) const
Binary matrix comparison.
Definition densematrix.hh:353
│ │ │ +
Traits::size_type size_type
The type used for the index access and size operation.
Definition densematrix.hh:171
│ │ │ +
Traits::const_row_reference const_row_reference
The type used to represent a reference to a constant row (usually const row_type &).
Definition densematrix.hh:180
│ │ │ +
std::remove_reference< row_reference >::type::Iterator ColIterator
rename the iterators for easier access
Definition densematrix.hh:218
│ │ │ +
Traits::row_reference row_reference
The type used to represent a reference to a row (usually row_type &).
Definition densematrix.hh:177
│ │ │ +
friend class DenseMatrix
Definition densematrix.hh:153
│ │ │ +
constexpr void mmv(const X &x, Y &y) const
y -= A x
Definition densematrix.hh:450
│ │ │ +
Iterator iterator
typedef for stl compliant access
Definition densematrix.hh:214
│ │ │ +
constexpr FieldTraits< vt >::real_type infinity_norm_real() const
simplified infinity norm (uses Manhattan norm for complex values)
Definition densematrix.hh:566
│ │ │ +
ConstIterator ConstRowIterator
rename the iterators for easier access
Definition densematrix.hh:251
│ │ │ +
constexpr Iterator begin()
begin iterator
Definition densematrix.hh:221
│ │ │ +
constexpr derived_type & operator=(const RHS &rhs)
Definition densematrix.hh:284
│ │ │ +
DenseIterator< DenseMatrix, row_type, row_reference > Iterator
Iterator class for sequential access.
Definition densematrix.hh:212
│ │ │ +
field_type determinant(bool doPivoting=true) const
calculates the determinant of this matrix
│ │ │ +
const FieldTraits< typenameDenseMatVecTraits< M >::value_type >::real_type real_type
Definition densematrix.hh:36
│ │ │ +
const FieldTraits< typenameDenseMatVecTraits< M >::value_type >::field_type field_type
Definition densematrix.hh:35
│ │ │ +
A dense n x m matrix.
Definition fmatrix.hh:117
│ │ │ +
Base::size_type size_type
Definition fmatrix.hh:128
│ │ │ +
vector space out of a tensor product of fields.
Definition fvector.hh:97
│ │ │ +
you have to specialize this structure for any type that should be assignable to a DenseMatrix
Definition densematrix.hh:61
│ │ │ +
Error thrown if operations of a FieldMatrix fail.
Definition densematrix.hh:131
│ │ │ +
Interface for a class of dense vectors over a given field.
Definition densevector.hh:244
│ │ │ +
constexpr size_type size() const
size method
Definition densevector.hh:351
│ │ │ +
Generic iterator class for dense vector and matrix implementations.
Definition densevector.hh:132
│ │ │ +
Default exception class for mathematical errors.
Definition exceptions.hh:335
│ │ │ +
Definition ftraits.hh:26
│ │ │ +
T field_type
export the type representing the field
Definition ftraits.hh:28
│ │ │ +
T real_type
export the type representing the real type of the field
Definition ftraits.hh:30
│ │ │ +
Definition matvectraits.hh:31
│ │ │ +
static ctype absolute_limit()
return threshold to declare matrix singular
Definition precision.hh:28
│ │ │ │ │ │ -
A type that refers to another type.
Definition typelist.hh:33
│ │ │ -
Check if T is an std::integral_constant<I, i>.
Definition typetraits.hh:384
│ │ │ -
Model of an inner node of a typetree with compile time known degree and child access via index_consta...
Definition nodeconcepts.hh:41
│ │ │ +
Include file for users of the SIMD abstraction layer.
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,186 +1,1551 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ - * _t_y_p_e_t_r_e_e │ │ │ │ -childaccess.hh │ │ │ │ +densematrix.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -1// -*- tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ -2// vi: set et ts=8 sw=2 sts=2: │ │ │ │ +1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ +2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ -4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception OR │ │ │ │ -LGPL-3.0-or-later │ │ │ │ -5 │ │ │ │ -6#ifndef DUNE_COMMON_TYPETREE_CHILDACCESS_HH │ │ │ │ -7#define DUNE_COMMON_TYPETREE_CHILDACCESS_HH │ │ │ │ -8 │ │ │ │ +4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ +5#ifndef DUNE_DENSEMATRIX_HH │ │ │ │ +6#define DUNE_DENSEMATRIX_HH │ │ │ │ +7 │ │ │ │ +8#include │ │ │ │ 9#include │ │ │ │ -10#include │ │ │ │ -11#include │ │ │ │ -12#include │ │ │ │ -13 │ │ │ │ -14#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ -15#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_l_i_s_t_._h_h> │ │ │ │ -16#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ -17 │ │ │ │ -18#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_m_u_l_t_i_i_n_d_e_x_._h_h> │ │ │ │ -19#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_n_o_d_e_c_o_n_c_e_p_t_s_._h_h> │ │ │ │ -20#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_e_e_/_t_r_e_e_p_a_t_h_._h_h> │ │ │ │ -21 │ │ │ │ -22 │ │ │ │ -_2_3namespace _D_u_n_e_:_:_T_y_p_e_T_r_e_e { │ │ │ │ -24 │ │ │ │ +10#include │ │ │ │ +11#include │ │ │ │ +12#include │ │ │ │ +13#include │ │ │ │ +14#include │ │ │ │ +15 │ │ │ │ +16#include <_d_u_n_e_/_c_o_m_m_o_n_/_b_o_u_n_d_s_c_h_e_c_k_i_n_g_._h_h> │ │ │ │ +17#include <_d_u_n_e_/_c_o_m_m_o_n_/_c_l_a_s_s_n_a_m_e_._h_h> │ │ │ │ +18#include <_d_u_n_e_/_c_o_m_m_o_n_/_e_x_c_e_p_t_i_o_n_s_._h_h> │ │ │ │ +19#include <_d_u_n_e_/_c_o_m_m_o_n_/_f_v_e_c_t_o_r_._h_h> │ │ │ │ +20#include <_d_u_n_e_/_c_o_m_m_o_n_/_m_a_t_h_._h_h> │ │ │ │ +21#include <_d_u_n_e_/_c_o_m_m_o_n_/_p_r_e_c_i_s_i_o_n_._h_h> │ │ │ │ +22#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_i_m_d_/_s_i_m_d_._h_h> │ │ │ │ +23#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ +24#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_c_a_l_a_r_v_e_c_t_o_r_v_i_e_w_._h_h> │ │ │ │ +25#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_t_d_/_i_t_e_r_a_t_o_r_._h_h> │ │ │ │ +26 │ │ │ │ +27namespace _D_u_n_e │ │ │ │ +28{ │ │ │ │ 29 │ │ │ │ +30 template class _D_e_n_s_e_M_a_t_r_i_x; │ │ │ │ 31 │ │ │ │ -54 template │ │ │ │ -_5_5 decltype(auto) _c_h_i_l_d (Node&& node, _T_r_e_e_P_a_t_h_<_I_n_d_i_c_e_s_._._._> _t_r_e_e_P_a_t_h) │ │ │ │ -56 { │ │ │ │ -57 if constexpr (sizeof...(Indices) == 0) │ │ │ │ -58 return std::forward(node); │ │ │ │ -59 else │ │ │ │ -60 { │ │ │ │ -61 using I0 = std::tuple_element_t<0, _T_r_e_e_P_a_t_h<_I_n_d_i_c_e_s...>>; │ │ │ │ -62 if constexpr (_D_u_n_e_:_:_I_s_I_n_t_e_g_r_a_l_C_o_n_s_t_a_n_t_<_I_0_>_:_:_v_a_l_u_e and _C_o_n_c_e_p_t_:_: │ │ │ │ -_S_t_a_t_i_c_D_e_g_r_e_e_I_n_n_e_r_T_r_e_e_N_o_d_e_<_N_o_d_e_>) │ │ │ │ -63 static_assert(I0::value < std::decay_t::degree(), "Child index out of │ │ │ │ -range"); │ │ │ │ -64 else │ │ │ │ -65 assert(std::size_t(_t_r_e_e_P_a_t_h.front()) < node.degree() && "Child index out of │ │ │ │ -range"); │ │ │ │ -66 if constexpr (sizeof...(Indices) == 1) │ │ │ │ -67 return node.child(_t_r_e_e_P_a_t_h.front()); │ │ │ │ -68 else │ │ │ │ -69 return _c_h_i_l_d(node.child(_t_r_e_e_P_a_t_h.front()), _p_o_p___f_r_o_n_t(_t_r_e_e_P_a_t_h)); │ │ │ │ -70 } │ │ │ │ -71 } │ │ │ │ -72 │ │ │ │ -74 │ │ │ │ -96 template │ │ │ │ -_9_7 decltype(auto) _c_h_i_l_d (Node&& node, _I_n_d_i_c_e_s... indices) │ │ │ │ -98 { │ │ │ │ -99 return _c_h_i_l_d(node, _D_u_n_e_:_:_H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x{indices...}); │ │ │ │ -100 } │ │ │ │ -101 │ │ │ │ -102 namespace Impl { │ │ │ │ +32 template │ │ │ │ +_3_3 struct _F_i_e_l_d_T_r_a_i_t_s< _D_e_n_s_e_M_a_t_r_i_x > │ │ │ │ +34 { │ │ │ │ +_3_5 typedef const typename _F_i_e_l_d_T_r_a_i_t_s_<_ _t_y_p_e_n_a_m_e_ _D_e_n_s_e_M_a_t_V_e_c_T_r_a_i_t_s_<_M_>_:_: │ │ │ │ +_v_a_l_u_e___t_y_p_e >_:_:_f_i_e_l_d___t_y_p_e _f_i_e_l_d___t_y_p_e; │ │ │ │ +_3_6 typedef const typename _F_i_e_l_d_T_r_a_i_t_s_<_ _t_y_p_e_n_a_m_e_ _D_e_n_s_e_M_a_t_V_e_c_T_r_a_i_t_s_<_M_>_:_: │ │ │ │ +_v_a_l_u_e___t_y_p_e >_:_:_r_e_a_l___t_y_p_e _r_e_a_l___t_y_p_e; │ │ │ │ +37 }; │ │ │ │ +38 │ │ │ │ +39 template class _F_i_e_l_d_M_a_t_r_i_x; │ │ │ │ +40 template class _F_i_e_l_d_V_e_c_t_o_r; │ │ │ │ +41 │ │ │ │ +46 │ │ │ │ +52 │ │ │ │ +53 │ │ │ │ +54 │ │ │ │ +60 template< class DenseMatrix, class RHS > │ │ │ │ +_6_1 struct _D_e_n_s_e_M_a_t_r_i_x_A_s_s_i_g_n_e_r; │ │ │ │ +62 │ │ │ │ +63#ifndef DOXYGEN │ │ │ │ +64 namespace Impl │ │ │ │ +65 { │ │ │ │ +66 │ │ │ │ +67 template< class DenseMatrix, class RHS > │ │ │ │ +68 class _D_e_n_s_e_M_a_t_r_i_x_A_s_s_i_g_n_e_r │ │ │ │ +69 {}; │ │ │ │ +70 │ │ │ │ +71 template< class DenseMatrix, class RHS > │ │ │ │ +72 requires (_D_u_n_e_:_:_I_s_N_u_m_b_e_r_<_ _R_H_S_ _>_:_:_v_a_l_u_e) │ │ │ │ +73 class _D_e_n_s_e_M_a_t_r_i_x_A_s_s_i_g_n_e_r_<_D_e_n_s_e_M_a_t_r_i_x_,_ _R_H_S_> │ │ │ │ +74 { │ │ │ │ +75 public: │ │ │ │ +76 constexpr static void apply ( _D_e_n_s_e_M_a_t_r_i_x &denseMatrix, const RHS &rhs ) │ │ │ │ +77 { │ │ │ │ +78 typedef typename _D_e_n_s_e_M_a_t_r_i_x_:_:_f_i_e_l_d___t_y_p_e _f_i_e_l_d___t_y_p_e; │ │ │ │ +79 std::fill( denseMatrix._b_e_g_i_n(), denseMatrix._e_n_d(), static_cast< _f_i_e_l_d___t_y_p_e > │ │ │ │ +( rhs ) ); │ │ │ │ +80 } │ │ │ │ +81 }; │ │ │ │ +82 │ │ │ │ +83 template< class DenseMatrix, class RHS > │ │ │ │ +84 requires Std::indirectly_copyable< │ │ │ │ +85 decltype(std::begin(*std::declval())), │ │ │ │ +86 decltype(std::begin(*std::declval()))> │ │ │ │ +87 class DenseMatrixAssigner │ │ │ │ +88 { │ │ │ │ +89 public: │ │ │ │ +90 constexpr static void apply ( DenseMatrix &denseMatrix, const RHS &rhs ) │ │ │ │ +91 { │ │ │ │ +92 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(rhs.N() == denseMatrix.N()); │ │ │ │ +93 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(rhs.M() == denseMatrix.M()); │ │ │ │ +94 typename DenseMatrix::iterator tIt = std::begin(denseMatrix); │ │ │ │ +95 typename RHS::const_iterator sIt = std::begin(rhs); │ │ │ │ +96 for(; sIt != std::end(rhs); ++tIt, ++sIt) │ │ │ │ +97 std::copy(std::begin(*sIt), std::end(*sIt), std::begin(*tIt)); │ │ │ │ +98 } │ │ │ │ +99 }; │ │ │ │ +100 │ │ │ │ +101 } // namespace Impl │ │ │ │ +102 │ │ │ │ 103 │ │ │ │ -104 // We could directly implement Child as │ │ │ │ -105 // │ │ │ │ -106 // using Child = std::decay_t(), Dune:: │ │ │ │ -index_constant()...))>; │ │ │ │ -107 // │ │ │ │ -108 // but this triggers an internal compiler error in │ │ │ │ -109 // gcc 11, 12, and 13 while it does work with gcc 10 │ │ │ │ -110 // and 14 and clang. This can be avoided by extracting │ │ │ │ -111 // this into a traits class. │ │ │ │ -112 template │ │ │ │ -113 struct ChildTraits │ │ │ │ -114 { │ │ │ │ -115 using _t_y_p_e = std::decay_t(), _D_u_n_e_:_: │ │ │ │ -_i_n_d_e_x___c_o_n_s_t_a_n_t_<_i_n_d_i_c_e_s_>()...))>; │ │ │ │ -116 }; │ │ │ │ -117 │ │ │ │ -118 } │ │ │ │ -119 │ │ │ │ -121 │ │ │ │ -128 template │ │ │ │ -_1_2_9 using _C_h_i_l_d = typename Impl::ChildTraits_:_:_t_y_p_e; │ │ │ │ -130 │ │ │ │ +104 │ │ │ │ +105 template< class DenseMatrix, class RHS > │ │ │ │ +106 struct _D_e_n_s_e_M_a_t_r_i_x_A_s_s_i_g_n_e_r │ │ │ │ +107 : public Impl::DenseMatrixAssigner< DenseMatrix, RHS > │ │ │ │ +108 {}; │ │ │ │ +109 │ │ │ │ +110 │ │ │ │ +111 namespace Impl │ │ │ │ +112 { │ │ │ │ +113 │ │ │ │ +114 template< class DenseMatrix, class RHS > │ │ │ │ +115 std::true_type hasDenseMatrixAssigner ( DenseMatrix &, const RHS &, │ │ │ │ +decltype( Dune::DenseMatrixAssigner< DenseMatrix, RHS >::apply( std::declval< │ │ │ │ +DenseMatrix & >(), std::declval< const RHS & >() ) ) * = nullptr ); │ │ │ │ +116 │ │ │ │ +117 std::false_type hasDenseMatrixAssigner ( ... ); │ │ │ │ +118 │ │ │ │ +119 } // namespace Impl │ │ │ │ +120 │ │ │ │ +121 template< class DenseMatrix, class RHS > │ │ │ │ +122 struct HasDenseMatrixAssigner │ │ │ │ +123 : public decltype( Impl::hasDenseMatrixAssigner( std::declval< DenseMatrix │ │ │ │ +& >(), std::declval< const RHS & >() ) ) │ │ │ │ +124 {}; │ │ │ │ +125 │ │ │ │ +126#endif // #ifndef DOXYGEN │ │ │ │ +127 │ │ │ │ +128 │ │ │ │ +129 │ │ │ │ +_1_3_1 class _F_M_a_t_r_i_x_E_r_r_o_r : public _M_a_t_h_E_r_r_o_r {}; │ │ │ │ 132 │ │ │ │ -139 template │ │ │ │ -_1_4_0 using _C_h_i_l_d_F_o_r_T_r_e_e_P_a_t_h = std::decay_t(), │ │ │ │ -std::declval()))>; │ │ │ │ -141 │ │ │ │ -142 │ │ │ │ -143 │ │ │ │ -144 namespace Impl { │ │ │ │ -145 │ │ │ │ -146 template │ │ │ │ -147 static constexpr auto childTypes() │ │ │ │ -148 { │ │ │ │ -149 if constexpr (_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_S_t_a_t_i_c_D_e_g_r_e_e_I_n_n_e_r_T_r_e_e_N_o_d_e_<_N_>) │ │ │ │ -150 { │ │ │ │ -151 return _D_u_n_e_:_:_u_n_p_a_c_k_I_n_t_e_g_e_r_S_e_q_u_e_n_c_e([&](auto... i) { │ │ │ │ -152 return _D_u_n_e_:_:_M_e_t_a_T_y_p_e_<_s_t_d_:_:_t_u_p_l_e_<_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_h_i_l_d_<_N_,_ _i_>...>>{}; │ │ │ │ -153 }, std::make_index_sequence{}); │ │ │ │ -154 } │ │ │ │ -155 else │ │ │ │ -156 return _D_u_n_e_:_:_M_e_t_a_T_y_p_e_<_v_o_i_d_>{}; │ │ │ │ -157 } │ │ │ │ -158 │ │ │ │ +143 template │ │ │ │ +_1_4_4 class _D_e_n_s_e_M_a_t_r_i_x │ │ │ │ +145 { │ │ │ │ +146 typedef _D_e_n_s_e_M_a_t_V_e_c_T_r_a_i_t_s_<_M_A_T_> Traits; │ │ │ │ +147 │ │ │ │ +148 // Curiously recurring template pattern │ │ │ │ +149 constexpr MAT & asImp() { return static_cast(*this); } │ │ │ │ +150 constexpr const MAT & asImp() const { return static_cast │ │ │ │ +(*this); } │ │ │ │ +151 │ │ │ │ +152 template │ │ │ │ +_1_5_3 friend class _D_e_n_s_e_M_a_t_r_i_x; │ │ │ │ +154 │ │ │ │ +155 public: │ │ │ │ +156 //===== type definitions and constants │ │ │ │ +157 │ │ │ │ +_1_5_9 typedef typename Traits::derived_type _d_e_r_i_v_e_d___t_y_p_e; │ │ │ │ 160 │ │ │ │ -170 template │ │ │ │ -171 using Children = typename decltype(Impl::childTypes())_:_:_t_y_p_e; │ │ │ │ +_1_6_2 typedef typename Traits::value_type _v_a_l_u_e___t_y_p_e; │ │ │ │ +163 │ │ │ │ +_1_6_5 typedef typename Traits::value_type _f_i_e_l_d___t_y_p_e; │ │ │ │ +166 │ │ │ │ +_1_6_8 typedef typename Traits::value_type _b_l_o_c_k___t_y_p_e; │ │ │ │ +169 │ │ │ │ +_1_7_1 typedef typename Traits::size_type _s_i_z_e___t_y_p_e; │ │ │ │ 172 │ │ │ │ -173 } │ │ │ │ -174 │ │ │ │ -176 │ │ │ │ -177} //namespace Dune::TypeTree │ │ │ │ +_1_7_4 typedef typename Traits::row_type _r_o_w___t_y_p_e; │ │ │ │ +175 │ │ │ │ +_1_7_7 typedef typename Traits::row_reference _r_o_w___r_e_f_e_r_e_n_c_e; │ │ │ │ 178 │ │ │ │ -179#endif // DUNE_COMMON_TYPETREE_CHILDACCESS_HH │ │ │ │ -_t_r_e_e_p_a_t_h_._h_h │ │ │ │ -_n_o_d_e_c_o_n_c_e_p_t_s_._h_h │ │ │ │ +_1_8_0 typedef typename Traits::const_row_reference _c_o_n_s_t___r_o_w___r_e_f_e_r_e_n_c_e; │ │ │ │ +181 │ │ │ │ +_1_8_3 constexpr static int _b_l_o_c_k_l_e_v_e_l = 1; │ │ │ │ +184 │ │ │ │ +185 private: │ │ │ │ +188 using simd_index_type = _S_i_m_d_:_:_R_e_b_i_n_d_<_s_t_d_:_:_s_i_z_e___t_,_ _v_a_l_u_e___t_y_p_e_>; │ │ │ │ +189 │ │ │ │ +190 public: │ │ │ │ +191 //===== access to components │ │ │ │ +192 │ │ │ │ +_1_9_4 constexpr _r_o_w___r_e_f_e_r_e_n_c_e _o_p_e_r_a_t_o_r_[_]_ ( _s_i_z_e___t_y_p_e i ) │ │ │ │ +195 { │ │ │ │ +196 return asImp().mat_access(i); │ │ │ │ +197 } │ │ │ │ +198 │ │ │ │ +_1_9_9 constexpr _c_o_n_s_t___r_o_w___r_e_f_e_r_e_n_c_e _o_p_e_r_a_t_o_r_[_]_ ( _s_i_z_e___t_y_p_e i ) const │ │ │ │ +200 { │ │ │ │ +201 return asImp().mat_access(i); │ │ │ │ +202 } │ │ │ │ +203 │ │ │ │ +_2_0_5 constexpr _s_i_z_e___t_y_p_e _s_i_z_e() const │ │ │ │ +206 { │ │ │ │ +207 return _r_o_w_s(); │ │ │ │ +208 } │ │ │ │ +209 │ │ │ │ +210 //===== iterator interface to rows of the matrix │ │ │ │ +_2_1_2 typedef _D_e_n_s_e_I_t_e_r_a_t_o_r_<_D_e_n_s_e_M_a_t_r_i_x_,_r_o_w___t_y_p_e_,_r_o_w___r_e_f_e_r_e_n_c_e_> _I_t_e_r_a_t_o_r; │ │ │ │ +_2_1_4 typedef _I_t_e_r_a_t_o_r _i_t_e_r_a_t_o_r; │ │ │ │ +_2_1_6 typedef _I_t_e_r_a_t_o_r _R_o_w_I_t_e_r_a_t_o_r; │ │ │ │ +_2_1_8 typedef typename std::remove_reference::type::Iterator │ │ │ │ +_C_o_l_I_t_e_r_a_t_o_r; │ │ │ │ +219 │ │ │ │ +_2_2_1 constexpr _I_t_e_r_a_t_o_r _b_e_g_i_n () │ │ │ │ +222 { │ │ │ │ +223 return _I_t_e_r_a_t_o_r(*this,0); │ │ │ │ +224 } │ │ │ │ +225 │ │ │ │ +_2_2_7 constexpr _I_t_e_r_a_t_o_r _e_n_d () │ │ │ │ +228 { │ │ │ │ +229 return _I_t_e_r_a_t_o_r(*this,_r_o_w_s()); │ │ │ │ +230 } │ │ │ │ +231 │ │ │ │ +_2_3_4 constexpr _I_t_e_r_a_t_o_r _b_e_f_o_r_e_E_n_d () │ │ │ │ +235 { │ │ │ │ +236 return _I_t_e_r_a_t_o_r(*this,_r_o_w_s()-1); │ │ │ │ +237 } │ │ │ │ +238 │ │ │ │ +_2_4_1 constexpr _I_t_e_r_a_t_o_r _b_e_f_o_r_e_B_e_g_i_n () │ │ │ │ +242 { │ │ │ │ +243 return _I_t_e_r_a_t_o_r(*this,-1); │ │ │ │ +244 } │ │ │ │ +245 │ │ │ │ +_2_4_7 typedef _D_e_n_s_e_I_t_e_r_a_t_o_r_<_c_o_n_s_t_ _D_e_n_s_e_M_a_t_r_i_x_,_c_o_n_s_t_ _r_o_w___t_y_p_e_,_c_o_n_s_t___r_o_w___r_e_f_e_r_e_n_c_e_> │ │ │ │ +_C_o_n_s_t_I_t_e_r_a_t_o_r; │ │ │ │ +_2_4_9 typedef _C_o_n_s_t_I_t_e_r_a_t_o_r _c_o_n_s_t___i_t_e_r_a_t_o_r; │ │ │ │ +_2_5_1 typedef _C_o_n_s_t_I_t_e_r_a_t_o_r _C_o_n_s_t_R_o_w_I_t_e_r_a_t_o_r; │ │ │ │ +_2_5_3 typedef typename std::remove_reference::type:: │ │ │ │ +ConstIterator _C_o_n_s_t_C_o_l_I_t_e_r_a_t_o_r; │ │ │ │ +254 │ │ │ │ +_2_5_6 constexpr _C_o_n_s_t_I_t_e_r_a_t_o_r _b_e_g_i_n () const │ │ │ │ +257 { │ │ │ │ +258 return _C_o_n_s_t_I_t_e_r_a_t_o_r(*this,0); │ │ │ │ +259 } │ │ │ │ +260 │ │ │ │ +_2_6_2 constexpr _C_o_n_s_t_I_t_e_r_a_t_o_r _e_n_d () const │ │ │ │ +263 { │ │ │ │ +264 return _C_o_n_s_t_I_t_e_r_a_t_o_r(*this,_r_o_w_s()); │ │ │ │ +265 } │ │ │ │ +266 │ │ │ │ +_2_6_9 constexpr _C_o_n_s_t_I_t_e_r_a_t_o_r _b_e_f_o_r_e_E_n_d () const │ │ │ │ +270 { │ │ │ │ +271 return _C_o_n_s_t_I_t_e_r_a_t_o_r(*this,_r_o_w_s()-1); │ │ │ │ +272 } │ │ │ │ +273 │ │ │ │ +_2_7_6 constexpr _C_o_n_s_t_I_t_e_r_a_t_o_r _b_e_f_o_r_e_B_e_g_i_n () const │ │ │ │ +277 { │ │ │ │ +278 return _C_o_n_s_t_I_t_e_r_a_t_o_r(*this,-1); │ │ │ │ +279 } │ │ │ │ +280 │ │ │ │ +281 //===== assignment │ │ │ │ +282 │ │ │ │ +283 template< class RHS, class = std::enable_if_t< HasDenseMatrixAssigner< MAT, │ │ │ │ +RHS >::value > > │ │ │ │ +_2_8_4 constexpr _d_e_r_i_v_e_d___t_y_p_e &_o_p_e_r_a_t_o_r_=_ ( const RHS &rhs ) │ │ │ │ +285 { │ │ │ │ +286 _D_e_n_s_e_M_a_t_r_i_x_A_s_s_i_g_n_e_r_<_ _M_A_T_,_ _R_H_S_ _>_:_:_a_p_p_l_y( asImp(), rhs ); │ │ │ │ +287 return asImp(); │ │ │ │ +288 } │ │ │ │ +289 │ │ │ │ +290 //===== vector space arithmetic │ │ │ │ +291 │ │ │ │ +293 template │ │ │ │ +_2_9_4 constexpr _d_e_r_i_v_e_d___t_y_p_e &_o_p_e_r_a_t_o_r_+_=_ (const _D_e_n_s_e_M_a_t_r_i_x_<_O_t_h_e_r_>& x) │ │ │ │ +295 { │ │ │ │ +296 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(_r_o_w_s() == x._r_o_w_s()); │ │ │ │ +297 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +298 (*this)[i] += x[i]; │ │ │ │ +299 return asImp(); │ │ │ │ +300 } │ │ │ │ +301 │ │ │ │ +_3_0_3 constexpr _d_e_r_i_v_e_d___t_y_p_e _o_p_e_r_a_t_o_r_-_ () const │ │ │ │ +304 { │ │ │ │ +305 MAT result; │ │ │ │ +306 using idx_type = typename decltype(result)_:_:_s_i_z_e___t_y_p_e; │ │ │ │ +307 │ │ │ │ +308 for (idx_type i = 0; i < _r_o_w_s(); ++i) │ │ │ │ +309 for (idx_type j = 0; j < _c_o_l_s(); ++j) │ │ │ │ +310 result[i][j] = - asImp()[i][j]; │ │ │ │ +311 │ │ │ │ +312 return result; │ │ │ │ +313 } │ │ │ │ +314 │ │ │ │ +316 template │ │ │ │ +_3_1_7 constexpr _d_e_r_i_v_e_d___t_y_p_e &_o_p_e_r_a_t_o_r_-_=_ (const _D_e_n_s_e_M_a_t_r_i_x_<_O_t_h_e_r_>& x) │ │ │ │ +318 { │ │ │ │ +319 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(_r_o_w_s() == x._r_o_w_s()); │ │ │ │ +320 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +321 (*this)[i] -= x[i]; │ │ │ │ +322 return asImp(); │ │ │ │ +323 } │ │ │ │ +324 │ │ │ │ +_3_2_6 constexpr _d_e_r_i_v_e_d___t_y_p_e &_o_p_e_r_a_t_o_r_*_=_ (const _f_i_e_l_d___t_y_p_e& k) │ │ │ │ +327 { │ │ │ │ +328 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +329 (*this)[i] *= k; │ │ │ │ +330 return asImp(); │ │ │ │ +331 } │ │ │ │ +332 │ │ │ │ +_3_3_4 constexpr _d_e_r_i_v_e_d___t_y_p_e &_o_p_e_r_a_t_o_r_/_=_ (const _f_i_e_l_d___t_y_p_e& k) │ │ │ │ +335 { │ │ │ │ +336 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +337 (*this)[i] /= k; │ │ │ │ +338 return asImp(); │ │ │ │ +339 } │ │ │ │ +340 │ │ │ │ +342 template │ │ │ │ +_3_4_3 constexpr _d_e_r_i_v_e_d___t_y_p_e &_a_x_p_y (const _f_i_e_l_d___t_y_p_e &a, const _D_e_n_s_e_M_a_t_r_i_x_<_O_t_h_e_r_> │ │ │ │ +&x ) │ │ │ │ +344 { │ │ │ │ +345 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(_r_o_w_s() == x._r_o_w_s()); │ │ │ │ +346 for( _s_i_z_e___t_y_p_e i = 0; i < _r_o_w_s(); ++i ) │ │ │ │ +347 (*this)[ i ].axpy( a, x[ i ] ); │ │ │ │ +348 return asImp(); │ │ │ │ +349 } │ │ │ │ +350 │ │ │ │ +352 template │ │ │ │ +_3_5_3 constexpr bool _o_p_e_r_a_t_o_r_=_=_ (const _D_e_n_s_e_M_a_t_r_i_x_<_O_t_h_e_r_>& x) const │ │ │ │ +354 { │ │ │ │ +355 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(_r_o_w_s() == x._r_o_w_s()); │ │ │ │ +356 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +357 if ((*this)[i]!=x[i]) │ │ │ │ +358 return false; │ │ │ │ +359 return true; │ │ │ │ +360 } │ │ │ │ +361 │ │ │ │ +362 template │ │ │ │ +_3_6_3 constexpr bool _o_p_e_r_a_t_o_r_!_=_ (const _D_e_n_s_e_M_a_t_r_i_x_<_O_t_h_e_r_>& x) const │ │ │ │ +364 { │ │ │ │ +365 return !_o_p_e_r_a_t_o_r_=_=(x); │ │ │ │ +366 } │ │ │ │ +367 │ │ │ │ +368 │ │ │ │ +369 //===== linear maps │ │ │ │ +370 │ │ │ │ +372 template │ │ │ │ +_3_7_3 constexpr void _m_v (const X& x, Y& y) const │ │ │ │ +374 { │ │ │ │ +375 auto&& xx = Impl::asVector(x); │ │ │ │ +376 auto&& yy = Impl::asVector(y); │ │ │ │ +377 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S((void*)(&x) != (void*)(&y)); │ │ │ │ +378 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _M()); │ │ │ │ +379 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _N()); │ │ │ │ +380 │ │ │ │ +381 using y_field_type = typename _F_i_e_l_d_T_r_a_i_t_s_<_Y_>_:_:_f_i_e_l_d___t_y_p_e; │ │ │ │ +382 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); ++i) │ │ │ │ +383 { │ │ │ │ +384 yy[i] = y_field_type(0); │ │ │ │ +385 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +386 yy[i] += (*this)[i][j] * xx[j]; │ │ │ │ +387 } │ │ │ │ +388 } │ │ │ │ +389 │ │ │ │ +391 template< class X, class Y > │ │ │ │ +_3_9_2 constexpr void _m_t_v ( const X &x, Y &y ) const │ │ │ │ +393 { │ │ │ │ +394 auto&& xx = Impl::asVector(x); │ │ │ │ +395 auto&& yy = Impl::asVector(y); │ │ │ │ +396 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S((void*)(&x) != (void*)(&y)); │ │ │ │ +397 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _N()); │ │ │ │ +398 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _M()); │ │ │ │ +399 │ │ │ │ +400 using y_field_type = typename _F_i_e_l_d_T_r_a_i_t_s_<_Y_>_:_:_f_i_e_l_d___t_y_p_e; │ │ │ │ +401 for(_s_i_z_e___t_y_p_e i = 0; i < _c_o_l_s(); ++i) │ │ │ │ +402 { │ │ │ │ +403 yy[i] = y_field_type(0); │ │ │ │ +404 for(_s_i_z_e___t_y_p_e j = 0; j < _r_o_w_s(); ++j) │ │ │ │ +405 yy[i] += (*this)[j][i] * xx[j]; │ │ │ │ +406 } │ │ │ │ +407 } │ │ │ │ +408 │ │ │ │ +410 template │ │ │ │ +_4_1_1 constexpr void _u_m_v (const X& x, Y& y) const │ │ │ │ +412 { │ │ │ │ +413 auto&& xx = Impl::asVector(x); │ │ │ │ +414 auto&& yy = Impl::asVector(y); │ │ │ │ +415 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _M()); │ │ │ │ +416 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _N()); │ │ │ │ +417 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); ++i) │ │ │ │ +418 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +419 yy[i] += (*this)[i][j] * xx[j]; │ │ │ │ +420 } │ │ │ │ +421 │ │ │ │ +423 template │ │ │ │ +_4_2_4 constexpr void _u_m_t_v (const X& x, Y& y) const │ │ │ │ +425 { │ │ │ │ +426 auto&& xx = Impl::asVector(x); │ │ │ │ +427 auto&& yy = Impl::asVector(y); │ │ │ │ +428 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _N()); │ │ │ │ +429 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _M()); │ │ │ │ +430 for(_s_i_z_e___t_y_p_e i = 0; i<_r_o_w_s(); ++i) │ │ │ │ +431 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +432 yy[j] += (*this)[i][j]*xx[i]; │ │ │ │ +433 } │ │ │ │ +434 │ │ │ │ +436 template │ │ │ │ +_4_3_7 constexpr void _u_m_h_v (const X& x, Y& y) const │ │ │ │ +438 { │ │ │ │ +439 auto&& xx = Impl::asVector(x); │ │ │ │ +440 auto&& yy = Impl::asVector(y); │ │ │ │ +441 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _N()); │ │ │ │ +442 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _M()); │ │ │ │ +443 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +444 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +445 yy[j] += _c_o_n_j_u_g_a_t_e_C_o_m_p_l_e_x((*this)[i][j])*xx[i]; │ │ │ │ +446 } │ │ │ │ +447 │ │ │ │ +449 template │ │ │ │ +_4_5_0 constexpr void _m_m_v (const X& x, Y& y) const │ │ │ │ +451 { │ │ │ │ +452 auto&& xx = Impl::asVector(x); │ │ │ │ +453 auto&& yy = Impl::asVector(y); │ │ │ │ +454 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _M()); │ │ │ │ +455 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _N()); │ │ │ │ +456 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +457 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +458 yy[i] -= (*this)[i][j] * xx[j]; │ │ │ │ +459 } │ │ │ │ +460 │ │ │ │ +462 template │ │ │ │ +_4_6_3 constexpr void _m_m_t_v (const X& x, Y& y) const │ │ │ │ +464 { │ │ │ │ +465 auto&& xx = Impl::asVector(x); │ │ │ │ +466 auto&& yy = Impl::asVector(y); │ │ │ │ +467 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _N()); │ │ │ │ +468 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _M()); │ │ │ │ +469 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +470 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +471 yy[j] -= (*this)[i][j]*xx[i]; │ │ │ │ +472 } │ │ │ │ +473 │ │ │ │ +475 template │ │ │ │ +_4_7_6 constexpr void _m_m_h_v (const X& x, Y& y) const │ │ │ │ +477 { │ │ │ │ +478 auto&& xx = Impl::asVector(x); │ │ │ │ +479 auto&& yy = Impl::asVector(y); │ │ │ │ +480 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _N()); │ │ │ │ +481 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _M()); │ │ │ │ +482 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +483 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +484 yy[j] -= _c_o_n_j_u_g_a_t_e_C_o_m_p_l_e_x((*this)[i][j])*xx[i]; │ │ │ │ +485 } │ │ │ │ +486 │ │ │ │ +488 template │ │ │ │ +_4_8_9 constexpr void _u_s_m_v (const typename _F_i_e_l_d_T_r_a_i_t_s_<_Y_>_:_:_f_i_e_l_d___t_y_p_e & alpha, │ │ │ │ +490 const X& x, Y& y) const │ │ │ │ +491 { │ │ │ │ +492 auto&& xx = Impl::asVector(x); │ │ │ │ +493 auto&& yy = Impl::asVector(y); │ │ │ │ +494 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _M()); │ │ │ │ +495 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _N()); │ │ │ │ +496 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +497 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +498 yy[i] += alpha * (*this)[i][j] * xx[j]; │ │ │ │ +499 } │ │ │ │ +500 │ │ │ │ +502 template │ │ │ │ +_5_0_3 constexpr void _u_s_m_t_v (const typename _F_i_e_l_d_T_r_a_i_t_s_<_Y_>_:_:_f_i_e_l_d___t_y_p_e & alpha, │ │ │ │ +504 const X& x, Y& y) const │ │ │ │ +505 { │ │ │ │ +506 auto&& xx = Impl::asVector(x); │ │ │ │ +507 auto&& yy = Impl::asVector(y); │ │ │ │ +508 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _N()); │ │ │ │ +509 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _M()); │ │ │ │ +510 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +511 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +512 yy[j] += alpha*(*this)[i][j]*xx[i]; │ │ │ │ +513 } │ │ │ │ +514 │ │ │ │ +516 template │ │ │ │ +_5_1_7 constexpr void _u_s_m_h_v (const typename _F_i_e_l_d_T_r_a_i_t_s_<_Y_>_:_:_f_i_e_l_d___t_y_p_e & alpha, │ │ │ │ +518 const X& x, Y& y) const │ │ │ │ +519 { │ │ │ │ +520 auto&& xx = Impl::asVector(x); │ │ │ │ +521 auto&& yy = Impl::asVector(y); │ │ │ │ +522 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(xx.N() == _N()); │ │ │ │ +523 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(yy.N() == _M()); │ │ │ │ +524 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +525 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) │ │ │ │ +526 yy[j] += │ │ │ │ +527 alpha*_c_o_n_j_u_g_a_t_e_C_o_m_p_l_e_x((*this)[i][j])*xx[i]; │ │ │ │ +528 } │ │ │ │ +529 │ │ │ │ +530 //===== norms │ │ │ │ +531 │ │ │ │ +_5_3_3 constexpr typename _F_i_e_l_d_T_r_a_i_t_s_<_v_a_l_u_e___t_y_p_e_>_:_:_r_e_a_l___t_y_p_e _f_r_o_b_e_n_i_u_s___n_o_r_m () │ │ │ │ +const │ │ │ │ +534 { │ │ │ │ +535 typename _F_i_e_l_d_T_r_a_i_t_s_<_v_a_l_u_e___t_y_p_e_>_:_:_r_e_a_l___t_y_p_e sum=(0.0); │ │ │ │ +536 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); ++i) sum += (*this)[i].two_norm2(); │ │ │ │ +537 return fvmeta::sqrt(sum); │ │ │ │ +538 } │ │ │ │ +539 │ │ │ │ +_5_4_1 constexpr typename _F_i_e_l_d_T_r_a_i_t_s_<_v_a_l_u_e___t_y_p_e_>_:_:_r_e_a_l___t_y_p_e _f_r_o_b_e_n_i_u_s___n_o_r_m_2 () │ │ │ │ +const │ │ │ │ +542 { │ │ │ │ +543 typename _F_i_e_l_d_T_r_a_i_t_s_<_v_a_l_u_e___t_y_p_e_>_:_:_r_e_a_l___t_y_p_e sum=(0.0); │ │ │ │ +544 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); ++i) sum += (*this)[i].two_norm2(); │ │ │ │ +545 return sum; │ │ │ │ +546 } │ │ │ │ +547 │ │ │ │ +549 template ::value, int>_:_:_t_y_p_e = 0> │ │ │ │ +_5_5_1 constexpr typename _F_i_e_l_d_T_r_a_i_t_s_<_v_t_>_:_:_r_e_a_l___t_y_p_e _i_n_f_i_n_i_t_y___n_o_r_m() const { │ │ │ │ +552 using _r_e_a_l___t_y_p_e = typename _F_i_e_l_d_T_r_a_i_t_s_<_v_t_>_:_:_r_e_a_l___t_y_p_e; │ │ │ │ +553 using std::max; │ │ │ │ +554 │ │ │ │ +555 _r_e_a_l___t_y_p_e norm = 0; │ │ │ │ +556 for (auto const &x : *this) { │ │ │ │ +557 _r_e_a_l___t_y_p_e const a = x.one_norm(); │ │ │ │ +558 norm = max(a, norm); │ │ │ │ +559 } │ │ │ │ +560 return norm; │ │ │ │ +561 } │ │ │ │ +562 │ │ │ │ +564 template ::value, int>_:_:_t_y_p_e = 0> │ │ │ │ +_5_6_6 constexpr typename _F_i_e_l_d_T_r_a_i_t_s_<_v_t_>_:_:_r_e_a_l___t_y_p_e _i_n_f_i_n_i_t_y___n_o_r_m___r_e_a_l() const { │ │ │ │ +567 using _r_e_a_l___t_y_p_e = typename _F_i_e_l_d_T_r_a_i_t_s_<_v_t_>_:_:_r_e_a_l___t_y_p_e; │ │ │ │ +568 using std::max; │ │ │ │ +569 │ │ │ │ +570 _r_e_a_l___t_y_p_e norm = 0; │ │ │ │ +571 for (auto const &x : *this) { │ │ │ │ +572 _r_e_a_l___t_y_p_e const a = x.one_norm_real(); │ │ │ │ +573 norm = max(a, norm); │ │ │ │ +574 } │ │ │ │ +575 return norm; │ │ │ │ +576 } │ │ │ │ +577 │ │ │ │ +579 template ::value, int>_:_:_t_y_p_e = 0> │ │ │ │ +_5_8_1 constexpr typename _F_i_e_l_d_T_r_a_i_t_s_<_v_t_>_:_:_r_e_a_l___t_y_p_e _i_n_f_i_n_i_t_y___n_o_r_m() const { │ │ │ │ +582 using _r_e_a_l___t_y_p_e = typename _F_i_e_l_d_T_r_a_i_t_s_<_v_t_>_:_:_r_e_a_l___t_y_p_e; │ │ │ │ +583 using std::max; │ │ │ │ +584 │ │ │ │ +585 _r_e_a_l___t_y_p_e norm = 0; │ │ │ │ +586 _r_e_a_l___t_y_p_e is_nan = 1; │ │ │ │ +587 for (auto const &x : *this) { │ │ │ │ +588 _r_e_a_l___t_y_p_e const a = x.one_norm(); │ │ │ │ +589 norm = max(a, norm); │ │ │ │ +590 is_nan += a; │ │ │ │ +591 } │ │ │ │ +592 return norm * (is_nan / is_nan); │ │ │ │ +593 } │ │ │ │ +594 │ │ │ │ +596 template ::value, int>_:_:_t_y_p_e = 0> │ │ │ │ +_5_9_8 constexpr typename _F_i_e_l_d_T_r_a_i_t_s_<_v_t_>_:_:_r_e_a_l___t_y_p_e _i_n_f_i_n_i_t_y___n_o_r_m___r_e_a_l() const { │ │ │ │ +599 using _r_e_a_l___t_y_p_e = typename _F_i_e_l_d_T_r_a_i_t_s_<_v_t_>_:_:_r_e_a_l___t_y_p_e; │ │ │ │ +600 using std::max; │ │ │ │ +601 │ │ │ │ +602 _r_e_a_l___t_y_p_e norm = 0; │ │ │ │ +603 _r_e_a_l___t_y_p_e is_nan = 1; │ │ │ │ +604 for (auto const &x : *this) { │ │ │ │ +605 _r_e_a_l___t_y_p_e const a = x.one_norm_real(); │ │ │ │ +606 norm = max(a, norm); │ │ │ │ +607 is_nan += a; │ │ │ │ +608 } │ │ │ │ +609 return norm * (is_nan / is_nan); │ │ │ │ +610 } │ │ │ │ +611 │ │ │ │ +612 //===== solve │ │ │ │ +613 │ │ │ │ +618 template │ │ │ │ +_6_1_9 void _s_o_l_v_e (V1& x, const V2& b, bool doPivoting = true) const; │ │ │ │ +620 │ │ │ │ +_6_2_5 void _i_n_v_e_r_t(bool doPivoting = true); │ │ │ │ +626 │ │ │ │ +_6_2_8 _f_i_e_l_d___t_y_p_e _d_e_t_e_r_m_i_n_a_n_t (bool doPivoting = true) const; │ │ │ │ +629 │ │ │ │ +631 template │ │ │ │ +_6_3_2 MAT& _l_e_f_t_m_u_l_t_i_p_l_y (const _D_e_n_s_e_M_a_t_r_i_x_<_M_2_>& _M) │ │ │ │ +633 { │ │ │ │ +634 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(_M.rows() == _M.cols()); │ │ │ │ +635 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(_M.rows() == _r_o_w_s()); │ │ │ │ +636 _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_<_M_A_T_> C(asImp()); │ │ │ │ +637 │ │ │ │ +638 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +639 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) { │ │ │ │ +640 (*this)[i][j] = 0; │ │ │ │ +641 for (_s_i_z_e___t_y_p_e k=0; k<_r_o_w_s(); k++) │ │ │ │ +642 (*this)[i][j] += _M[i][k]*C[k][j]; │ │ │ │ +643 } │ │ │ │ +644 │ │ │ │ +645 return asImp(); │ │ │ │ +646 } │ │ │ │ +647 │ │ │ │ +649 template │ │ │ │ +_6_5_0 MAT& _r_i_g_h_t_m_u_l_t_i_p_l_y (const _D_e_n_s_e_M_a_t_r_i_x_<_M_2_>& _M) │ │ │ │ +651 { │ │ │ │ +652 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(_M.rows() == _M.cols()); │ │ │ │ +653 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(_M.cols() == _c_o_l_s()); │ │ │ │ +654 _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_<_M_A_T_> C(asImp()); │ │ │ │ +655 │ │ │ │ +656 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) │ │ │ │ +657 for (_s_i_z_e___t_y_p_e j=0; j<_c_o_l_s(); j++) { │ │ │ │ +658 (*this)[i][j] = 0; │ │ │ │ +659 for (_s_i_z_e___t_y_p_e k=0; k<_c_o_l_s(); k++) │ │ │ │ +660 (*this)[i][j] += C[i][k]*_M[k][j]; │ │ │ │ +661 } │ │ │ │ +662 return asImp(); │ │ │ │ +663 } │ │ │ │ +664 │ │ │ │ +665#if 0 │ │ │ │ +667 template │ │ │ │ +668 _D_e_n_s_e_M_a_t_r_i_x_<_K_,_l_,_c_o_l_s_> leftmultiplyany (const _F_i_e_l_d_M_a_t_r_i_x_<_K_,_l_,_r_o_w_s_>& _M) │ │ │ │ +const │ │ │ │ +669 { │ │ │ │ +670 _F_i_e_l_d_M_a_t_r_i_x_<_K_,_l_,_c_o_l_s_> C; │ │ │ │ +671 │ │ │ │ +672 for (_s_i_z_e___t_y_p_e i=0; i │ │ │ │ +684 FieldMatrix rightmultiplyany (const FieldMatrix& _M) │ │ │ │ +const │ │ │ │ +685 { │ │ │ │ +686 FieldMatrix C; │ │ │ │ +687 │ │ │ │ +688 for (_s_i_z_e___t_y_p_e i=0; i<_r_o_w_s(); i++) { │ │ │ │ +689 for (_s_i_z_e___t_y_p_e j=0; j= 0 && i < _r_o_w_s()); │ │ │ │ +731 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(j >= 0 && j < _c_o_l_s()); │ │ │ │ +732 return true; │ │ │ │ +733 } │ │ │ │ +734 │ │ │ │ +735 protected: │ │ │ │ +736 │ │ │ │ +737#ifndef DOXYGEN │ │ │ │ +738 struct ElimPivot │ │ │ │ +739 { │ │ │ │ +740 ElimPivot(std::vector & pivot); │ │ │ │ +741 │ │ │ │ +742 void _s_w_a_p(std::size_t i, simd_index_type j); │ │ │ │ +743 │ │ │ │ +744 template │ │ │ │ +745 void operator()(const T&, int, int) │ │ │ │ +746 {} │ │ │ │ +747 │ │ │ │ +748 std::vector & pivot_; │ │ │ │ +749 }; │ │ │ │ +750 │ │ │ │ +751 template │ │ │ │ +752 struct Elim │ │ │ │ +753 { │ │ │ │ +754 Elim(V& rhs); │ │ │ │ +755 │ │ │ │ +756 void _s_w_a_p(std::size_t i, simd_index_type j); │ │ │ │ +757 │ │ │ │ +758 void operator()(const typename V::field_type& factor, int k, int i); │ │ │ │ +759 │ │ │ │ +760 V* rhs_; │ │ │ │ +761 }; │ │ │ │ +762 │ │ │ │ +763 struct ElimDet │ │ │ │ +764 { │ │ │ │ +765 ElimDet(field_type& sign) : sign_(_s_i_g_n) │ │ │ │ +766 { sign_ = 1; } │ │ │ │ +767 │ │ │ │ +768 void _s_w_a_p(std::size_t i, simd_index_type j) │ │ │ │ +769 { │ │ │ │ +770 sign_ *= │ │ │ │ +771 Simd::cond(simd_index_type(i) == j, field_type(1), field_type(-1)); │ │ │ │ +772 } │ │ │ │ +773 │ │ │ │ +774 void operator()(const field_type&, int, int) │ │ │ │ +775 {} │ │ │ │ +776 │ │ │ │ +777 field_type& sign_; │ │ │ │ +778 }; │ │ │ │ +779#endif // DOXYGEN │ │ │ │ +780 │ │ │ │ +782 │ │ │ │ +820 template │ │ │ │ +_8_2_1 static void _l_u_D_e_c_o_m_p_o_s_i_t_i_o_n(_D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>& A, Func func, │ │ │ │ +822 Mask &nonsingularLanes, bool throwEarly, bool doPivoting); │ │ │ │ +823 }; │ │ │ │ +824 │ │ │ │ +825#ifndef DOXYGEN │ │ │ │ +826 template │ │ │ │ +827 _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_:_E_l_i_m_P_i_v_o_t_:_:_E_l_i_m_P_i_v_o_t(std::vector & │ │ │ │ +pivot) │ │ │ │ +828 : pivot_(pivot) │ │ │ │ +829 { │ │ │ │ +830 for(typename std::vector::size_type i=0; i < pivot_.size(); ++i) │ │ │ │ +831 pivot_[i]=i; │ │ │ │ +832 } │ │ │ │ +833 │ │ │ │ +834 template │ │ │ │ +835 void DenseMatrix::ElimPivot::swap(std::size_t i, simd_index_type j) │ │ │ │ +836 { │ │ │ │ +837 pivot_[i] = │ │ │ │ +838 _S_i_m_d_:_:_c_o_n_d(_S_i_m_d_:_:_S_c_a_l_a_r_<_s_i_m_d___i_n_d_e_x___t_y_p_e_>(i) == j, pivot_[i], j); │ │ │ │ +839 } │ │ │ │ +840 │ │ │ │ +841 template │ │ │ │ +842 template │ │ │ │ +843 _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_:_E_l_i_m_<_V_>_:_:_E_l_i_m(V& rhs) │ │ │ │ +844 : rhs_(&rhs) │ │ │ │ +845 {} │ │ │ │ +846 │ │ │ │ +847 template │ │ │ │ +848 template │ │ │ │ +849 void _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_:_E_l_i_m_<_V_>_:_:_s_w_a_p(std::size_t i, simd_index_type j) │ │ │ │ +850 { │ │ │ │ +851 using std::swap; │ │ │ │ +852 │ │ │ │ +853 // see the comment in luDecomposition() │ │ │ │ +854 for(std::size_t l = 0; l < _S_i_m_d_:_:_l_a_n_e_s(j); ++l) │ │ │ │ +855 _s_w_a_p(_S_i_m_d_:_:_l_a_n_e(l, (*rhs_)[ i ]), │ │ │ │ +856 _S_i_m_d_:_:_l_a_n_e(l, (*rhs_)[_S_i_m_d_:_:_l_a_n_e(l, j)])); │ │ │ │ +857 } │ │ │ │ +858 │ │ │ │ +859 template │ │ │ │ +860 template │ │ │ │ +861 void _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_: │ │ │ │ +862_ _E_l_i_m_<_V_>_:_:_o_p_e_r_a_t_o_r_(_)(const typename V::field_type& factor, int k, int i) │ │ │ │ +863 { │ │ │ │ +864 (*rhs_)[k] -= factor*(*rhs_)[i]; │ │ │ │ +865 } │ │ │ │ +866 │ │ │ │ +867 template │ │ │ │ +868 template │ │ │ │ +869 inline void _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_: │ │ │ │ +870_ _l_u_D_e_c_o_m_p_o_s_i_t_i_o_n(_D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>& A, Func func, Mask &nonsingularLanes, │ │ │ │ +871 bool throwEarly, bool doPivoting) │ │ │ │ +872 { │ │ │ │ +873 using std::max; │ │ │ │ +874 using std::swap; │ │ │ │ +875 │ │ │ │ +876 typedef typename _F_i_e_l_d_T_r_a_i_t_s_<_v_a_l_u_e___t_y_p_e_>_:_:_r_e_a_l___t_y_p_e _r_e_a_l___t_y_p_e; │ │ │ │ +877 │ │ │ │ +878 // LU decomposition of A in A │ │ │ │ +879 for (size_type i=0; i pivmax; │ │ │ │ +891 pivmax = _S_i_m_d_:_:_c_o_n_d(mask, abs, pivmax); │ │ │ │ +892 imax = _S_i_m_d_:_:_c_o_n_d(mask, simd_index_type(k), imax); │ │ │ │ +893 } │ │ │ │ +894 // swap rows │ │ │ │ +895 for (size_type j=0; j │ │ │ │ +938 template │ │ │ │ +939 inline void _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_:_s_o_l_v_e(V1& x, const V2& b, bool doPivoting) │ │ │ │ +const │ │ │ │ +940 { │ │ │ │ +941 using _r_e_a_l___t_y_p_e = typename _F_i_e_l_d_T_r_a_i_t_s_<_v_a_l_u_e___t_y_p_e_>_:_:_r_e_a_l___t_y_p_e; │ │ │ │ +942 // never mind those ifs, because they get optimized away │ │ │ │ +943 if (rows()!=cols()) │ │ │ │ +944 _D_U_N_E___T_H_R_O_W(_F_M_a_t_r_i_x_E_r_r_o_r, "Can't solve for a " << rows() << "x" << cols() << │ │ │ │ +" matrix!"); │ │ │ │ +945 │ │ │ │ +946 if (rows()==1) { │ │ │ │ +947 │ │ │ │ +948#ifdef DUNE_FMatrix_WITH_CHECKING │ │ │ │ +949 if (_S_i_m_d_:_:_a_n_y_T_r_u_e(fvmeta::absreal((*this)[0][0]) │ │ │ │ +950 < _F_M_a_t_r_i_x_P_r_e_c_i_s_i_o_n_<_>_:_:_a_b_s_o_l_u_t_e___l_i_m_i_t())) │ │ │ │ +951 _D_U_N_E___T_H_R_O_W(_F_M_a_t_r_i_x_E_r_r_o_r,"matrix is singular"); │ │ │ │ +952#endif │ │ │ │ +953 x[0] = b[0]/(*this)[0][0]; │ │ │ │ +954 │ │ │ │ +955 } │ │ │ │ +956 else if (rows()==2) { │ │ │ │ +957 │ │ │ │ +958 _f_i_e_l_d___t_y_p_e detinv = (*this)[0][0]*(*this)[1][1]-(*this)[0][1]*(*this)[1] │ │ │ │ +[0]; │ │ │ │ +959#ifdef DUNE_FMatrix_WITH_CHECKING │ │ │ │ +960 if (_S_i_m_d_:_:_a_n_y_T_r_u_e(fvmeta::absreal(detinv) │ │ │ │ +961 < _F_M_a_t_r_i_x_P_r_e_c_i_s_i_o_n_<_>_:_:_a_b_s_o_l_u_t_e___l_i_m_i_t())) │ │ │ │ +962 _D_U_N_E___T_H_R_O_W(_F_M_a_t_r_i_x_E_r_r_o_r,"matrix is singular"); │ │ │ │ +963#endif │ │ │ │ +964 detinv = _r_e_a_l___t_y_p_e(1.0)/detinv; │ │ │ │ +965 │ │ │ │ +966 x[0] = detinv*((*this)[1][1]*b[0]-(*this)[0][1]*b[1]); │ │ │ │ +967 x[1] = detinv*((*this)[0][0]*b[1]-(*this)[1][0]*b[0]); │ │ │ │ +968 │ │ │ │ +969 } │ │ │ │ +970 else if (rows()==3) { │ │ │ │ +971 │ │ │ │ +972 _f_i_e_l_d___t_y_p_e d = determinant(doPivoting); │ │ │ │ +973#ifdef DUNE_FMatrix_WITH_CHECKING │ │ │ │ +974 if (_S_i_m_d_:_:_a_n_y_T_r_u_e(fvmeta::absreal(d) │ │ │ │ +975 < _F_M_a_t_r_i_x_P_r_e_c_i_s_i_o_n_<_>_:_:_a_b_s_o_l_u_t_e___l_i_m_i_t())) │ │ │ │ +976 _D_U_N_E___T_H_R_O_W(_F_M_a_t_r_i_x_E_r_r_o_r,"matrix is singular"); │ │ │ │ +977#endif │ │ │ │ +978 │ │ │ │ +979 x[0] = (b[0]*(*this)[1][1]*(*this)[2][2] - b[0]*(*this)[2][1]*(*this)[1][2] │ │ │ │ +980 - b[1] *(*this)[0][1]*(*this)[2][2] + b[1]*(*this)[2][1]*(*this)[0][2] │ │ │ │ +981 + b[2] *(*this)[0][1]*(*this)[1][2] - b[2]*(*this)[1][1]*(*this)[0][2]) / │ │ │ │ +d; │ │ │ │ +982 │ │ │ │ +983 x[1] = ((*this)[0][0]*b[1]*(*this)[2][2] - (*this)[0][0]*b[2]*(*this)[1][2] │ │ │ │ +984 - (*this)[1][0] *b[0]*(*this)[2][2] + (*this)[1][0]*b[2]*(*this)[0][2] │ │ │ │ +985 + (*this)[2][0] *b[0]*(*this)[1][2] - (*this)[2][0]*b[1]*(*this)[0][2]) / │ │ │ │ +d; │ │ │ │ +986 │ │ │ │ +987 x[2] = ((*this)[0][0]*(*this)[1][1]*b[2] - (*this)[0][0]*(*this)[2][1]*b[1] │ │ │ │ +988 - (*this)[1][0] *(*this)[0][1]*b[2] + (*this)[1][0]*(*this)[2][1]*b[0] │ │ │ │ +989 + (*this)[2][0] *(*this)[0][1]*b[1] - (*this)[2][0]*(*this)[1][1]*b[0]) / │ │ │ │ +d; │ │ │ │ +990 │ │ │ │ +991 } │ │ │ │ +992 else { │ │ │ │ +993 │ │ │ │ +994 V1& rhs = x; // use x to store rhs │ │ │ │ +995 rhs = b; // copy data │ │ │ │ +996 Elim elim(rhs); │ │ │ │ +997 _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_<_M_A_T_> A(asImp()); │ │ │ │ +998 _S_i_m_d_:_:_M_a_s_k_<_t_y_p_e_n_a_m_e_ _F_i_e_l_d_T_r_a_i_t_s_<_v_a_l_u_e___t_y_p_e_>_:_:_r_e_a_l___t_y_p_e> │ │ │ │ +999 nonsingularLanes(true); │ │ │ │ +1000 │ │ │ │ +1001 _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_<_M_A_T_>_:_:_l_u_D_e_c_o_m_p_o_s_i_t_i_o_n(A, elim, nonsingularLanes, true, │ │ │ │ +doPivoting); │ │ │ │ +1002 │ │ │ │ +1003 // backsolve │ │ │ │ +1004 for(int i=rows()-1; i>=0; i--) { │ │ │ │ +1005 for (size_type j=i+1; j │ │ │ │ +1013 inline void _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_:_i_n_v_e_r_t(bool doPivoting) │ │ │ │ +1014 { │ │ │ │ +1015 using _r_e_a_l___t_y_p_e = typename _F_i_e_l_d_T_r_a_i_t_s_<_M_A_T_>_:_:_r_e_a_l___t_y_p_e; │ │ │ │ +1016 using std::swap; │ │ │ │ +1017 │ │ │ │ +1018 // never mind those ifs, because they get optimized away │ │ │ │ +1019 if (rows()!=cols()) │ │ │ │ +1020 _D_U_N_E___T_H_R_O_W(_F_M_a_t_r_i_x_E_r_r_o_r, "Can't invert a " << rows() << "x" << cols() << " │ │ │ │ +matrix!"); │ │ │ │ +1021 │ │ │ │ +1022 if (rows()==1) { │ │ │ │ +1023 │ │ │ │ +1024#ifdef DUNE_FMatrix_WITH_CHECKING │ │ │ │ +1025 if (_S_i_m_d_:_:_a_n_y_T_r_u_e(fvmeta::absreal((*this)[0][0]) │ │ │ │ +1026 < _F_M_a_t_r_i_x_P_r_e_c_i_s_i_o_n_<_>_:_:_a_b_s_o_l_u_t_e___l_i_m_i_t())) │ │ │ │ +1027 _D_U_N_E___T_H_R_O_W(_F_M_a_t_r_i_x_E_r_r_o_r,"matrix is singular"); │ │ │ │ +1028#endif │ │ │ │ +1029 (*this)[0][0] = _r_e_a_l___t_y_p_e( 1 ) / (*this)[0][0]; │ │ │ │ +1030 │ │ │ │ +1031 } │ │ │ │ +1032 else if (rows()==2) { │ │ │ │ +1033 │ │ │ │ +1034 _f_i_e_l_d___t_y_p_e detinv = (*this)[0][0]*(*this)[1][1]-(*this)[0][1]*(*this)[1] │ │ │ │ +[0]; │ │ │ │ +1035#ifdef DUNE_FMatrix_WITH_CHECKING │ │ │ │ +1036 if (_S_i_m_d_:_:_a_n_y_T_r_u_e(fvmeta::absreal(detinv) │ │ │ │ +1037 < _F_M_a_t_r_i_x_P_r_e_c_i_s_i_o_n_<_>_:_:_a_b_s_o_l_u_t_e___l_i_m_i_t())) │ │ │ │ +1038 _D_U_N_E___T_H_R_O_W(_F_M_a_t_r_i_x_E_r_r_o_r,"matrix is singular"); │ │ │ │ +1039#endif │ │ │ │ +1040 detinv = _r_e_a_l___t_y_p_e( 1 ) / detinv; │ │ │ │ +1041 │ │ │ │ +1042 _f_i_e_l_d___t_y_p_e temp=(*this)[0][0]; │ │ │ │ +1043 (*this)[0][0] = (*this)[1][1]*detinv; │ │ │ │ +1044 (*this)[0][1] = -(*this)[0][1]*detinv; │ │ │ │ +1045 (*this)[1][0] = -(*this)[1][0]*detinv; │ │ │ │ +1046 (*this)[1][1] = temp*detinv; │ │ │ │ +1047 │ │ │ │ +1048 } │ │ │ │ +1049 else if (rows()==3) │ │ │ │ +1050 { │ │ │ │ +1051 using K = _f_i_e_l_d___t_y_p_e; │ │ │ │ +1052 // code generated by maple │ │ │ │ +1053 K t4 = (*this)[0][0] * (*this)[1][1]; │ │ │ │ +1054 K t6 = (*this)[0][0] * (*this)[1][2]; │ │ │ │ +1055 K t8 = (*this)[0][1] * (*this)[1][0]; │ │ │ │ +1056 K t10 = (*this)[0][2] * (*this)[1][0]; │ │ │ │ +1057 K t12 = (*this)[0][1] * (*this)[2][0]; │ │ │ │ +1058 K t14 = (*this)[0][2] * (*this)[2][0]; │ │ │ │ +1059 │ │ │ │ +1060 K det = (t4*(*this)[2][2]-t6*(*this)[2][1]-t8*(*this)[2][2]+ │ │ │ │ +1061 t10*(*this)[2][1]+t12*(*this)[1][2]-t14*(*this)[1][1]); │ │ │ │ +1062 K t17 = K(1.0)/det; │ │ │ │ +1063 │ │ │ │ +1064 K matrix01 = (*this)[0][1]; │ │ │ │ +1065 K matrix00 = (*this)[0][0]; │ │ │ │ +1066 K matrix10 = (*this)[1][0]; │ │ │ │ +1067 K matrix11 = (*this)[1][1]; │ │ │ │ +1068 │ │ │ │ +1069 (*this)[0][0] = ((*this)[1][1] * (*this)[2][2] - (*this)[1][2] * (*this) │ │ │ │ +[2][1])*t17; │ │ │ │ +1070 (*this)[0][1] = -((*this)[0][1] * (*this)[2][2] - (*this)[0][2] * (*this) │ │ │ │ +[2][1])*t17; │ │ │ │ +1071 (*this)[0][2] = (matrix01 * (*this)[1][2] - (*this)[0][2] * (*this)[1] │ │ │ │ +[1])*t17; │ │ │ │ +1072 (*this)[1][0] = -((*this)[1][0] * (*this)[2][2] - (*this)[1][2] * (*this) │ │ │ │ +[2][0])*t17; │ │ │ │ +1073 (*this)[1][1] = (matrix00 * (*this)[2][2] - t14) * t17; │ │ │ │ +1074 (*this)[1][2] = -(t6-t10) * t17; │ │ │ │ +1075 (*this)[2][0] = (matrix10 * (*this)[2][1] - matrix11 * (*this)[2][0]) * │ │ │ │ +t17; │ │ │ │ +1076 (*this)[2][1] = -(matrix00 * (*this)[2][1] - t12) * t17; │ │ │ │ +1077 (*this)[2][2] = (t4-t8) * t17; │ │ │ │ +1078 } │ │ │ │ +1079 else { │ │ │ │ +1080 using std::swap; │ │ │ │ +1081 │ │ │ │ +1082 _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_<_M_A_T_> A(asImp()); │ │ │ │ +1083 std::vector pivot(rows()); │ │ │ │ +1084 _S_i_m_d_:_:_M_a_s_k_<_t_y_p_e_n_a_m_e_ _F_i_e_l_d_T_r_a_i_t_s_<_v_a_l_u_e___t_y_p_e_>_:_:_r_e_a_l___t_y_p_e> │ │ │ │ +1085 nonsingularLanes(true); │ │ │ │ +1086 _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_<_M_A_T_>_:_:_l_u_D_e_c_o_m_p_o_s_i_t_i_o_n(A, ElimPivot(pivot), │ │ │ │ +nonsingularLanes, true, doPivoting); │ │ │ │ +1087 auto& L=A; │ │ │ │ +1088 auto& U=A; │ │ │ │ +1089 │ │ │ │ +1090 // initialize inverse │ │ │ │ +1091 *this=_f_i_e_l_d___t_y_p_e(); │ │ │ │ +1092 │ │ │ │ +1093 for(size_type i=0; i0;) { │ │ │ │ +1104 --i; │ │ │ │ +1105 for (size_type k=0; k0; ) { │ │ │ │ +1113 --i; │ │ │ │ +1114 for(std::size_t l = 0; l < _S_i_m_d_:_:_l_a_n_e_s((*this)[0][0]); ++l) │ │ │ │ +1115 { │ │ │ │ +1116 std::size_t pi = _S_i_m_d_:_:_l_a_n_e(l, pivot[i]); │ │ │ │ +1117 if(i!=pi) │ │ │ │ +1118 for(size_type j=0; j │ │ │ │ +1128 inline typename _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_:_f_i_e_l_d___t_y_p_e │ │ │ │ +1129 _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_:_d_e_t_e_r_m_i_n_a_n_t(bool doPivoting) const │ │ │ │ +1130 { │ │ │ │ +1131 // never mind those ifs, because they get optimized away │ │ │ │ +1132 if (rows()!=cols()) │ │ │ │ +1133 _D_U_N_E___T_H_R_O_W(_F_M_a_t_r_i_x_E_r_r_o_r, "There is no determinant for a " << rows() << "x" │ │ │ │ +<< cols() << " matrix!"); │ │ │ │ +1134 │ │ │ │ +1135 if (rows()==1) │ │ │ │ +1136 return (*this)[0][0]; │ │ │ │ +1137 │ │ │ │ +1138 if (rows()==2) │ │ │ │ +1139 return (*this)[0][0]*(*this)[1][1] - (*this)[0][1]*(*this)[1][0]; │ │ │ │ +1140 │ │ │ │ +1141 if (rows()==3) { │ │ │ │ +1142 // code generated by maple │ │ │ │ +1143 _f_i_e_l_d___t_y_p_e t4 = (*this)[0][0] * (*this)[1][1]; │ │ │ │ +1144 _f_i_e_l_d___t_y_p_e t6 = (*this)[0][0] * (*this)[1][2]; │ │ │ │ +1145 _f_i_e_l_d___t_y_p_e t8 = (*this)[0][1] * (*this)[1][0]; │ │ │ │ +1146 _f_i_e_l_d___t_y_p_e t10 = (*this)[0][2] * (*this)[1][0]; │ │ │ │ +1147 _f_i_e_l_d___t_y_p_e t12 = (*this)[0][1] * (*this)[2][0]; │ │ │ │ +1148 _f_i_e_l_d___t_y_p_e t14 = (*this)[0][2] * (*this)[2][0]; │ │ │ │ +1149 │ │ │ │ +1150 return (t4*(*this)[2][2]-t6*(*this)[2][1]-t8*(*this)[2][2]+ │ │ │ │ +1151 t10*(*this)[2][1]+t12*(*this)[1][2]-t14*(*this)[1][1]); │ │ │ │ +1152 │ │ │ │ +1153 } │ │ │ │ +1154 │ │ │ │ +1155 _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_<_M_A_T_> A(asImp()); │ │ │ │ +1156 _f_i_e_l_d___t_y_p_e det; │ │ │ │ +1157 _S_i_m_d_:_:_M_a_s_k_<_t_y_p_e_n_a_m_e_ _F_i_e_l_d_T_r_a_i_t_s_<_v_a_l_u_e___t_y_p_e_>_:_:_r_e_a_l___t_y_p_e> │ │ │ │ +1158 nonsingularLanes(true); │ │ │ │ +1159 │ │ │ │ +1160 _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_<_M_A_T_>_:_:_l_u_D_e_c_o_m_p_o_s_i_t_i_o_n(A, ElimDet(det), nonsingularLanes, │ │ │ │ +false, doPivoting); │ │ │ │ +1161 det = _S_i_m_d_:_:_c_o_n_d(nonsingularLanes, det, _f_i_e_l_d___t_y_p_e(0)); │ │ │ │ +1162 │ │ │ │ +1163 for (size_type i = 0; i < rows(); ++i) │ │ │ │ +1164 det *= A[i][i]; │ │ │ │ +1165 return det; │ │ │ │ +1166 } │ │ │ │ +1167 │ │ │ │ +1168#endif // DOXYGEN │ │ │ │ +1169 │ │ │ │ +_1_1_7_0 namespace _D_e_n_s_e_M_a_t_r_i_x_H_e_l_p { │ │ │ │ +1171 │ │ │ │ +1173 template │ │ │ │ +_1_1_7_4 static inline void _m_u_l_t_A_s_s_i_g_n(const _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_> &matrix, const │ │ │ │ +_D_e_n_s_e_V_e_c_t_o_r_<_V_1_> & x, _D_e_n_s_e_V_e_c_t_o_r_<_V_2_> & ret) │ │ │ │ +1175 { │ │ │ │ +1176 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(x._s_i_z_e() == matrix._c_o_l_s()); │ │ │ │ +1177 _D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S(ret._s_i_z_e() == matrix._r_o_w_s()); │ │ │ │ +1178 typedef typename _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_:_s_i_z_e___t_y_p_e size_type; │ │ │ │ +1179 │ │ │ │ +1180 for(size_type i=0; i │ │ │ │ +1193 static inline void multAssignTransposed( const _F_i_e_l_d_M_a_t_r_i_x_<_K_,_r_o_w_s_,_c_o_l_s_> │ │ │ │ +&matrix, const _F_i_e_l_d_V_e_c_t_o_r_<_K_,_r_o_w_s_> & x, _F_i_e_l_d_V_e_c_t_o_r_<_K_,_c_o_l_s_> & ret) │ │ │ │ +1194 { │ │ │ │ +1195 typedef typename _F_i_e_l_d_M_a_t_r_i_x_<_K_,_r_o_w_s_,_c_o_l_s_>_:_:_s_i_z_e___t_y_p_e size_type; │ │ │ │ +1196 │ │ │ │ +1197 for(size_type i=0; i │ │ │ │ +1207 static inline FieldVector mult(const FieldMatrix │ │ │ │ +&matrix, const FieldVector & x) │ │ │ │ +1208 { │ │ │ │ +1209 FieldVector ret; │ │ │ │ +1210 _m_u_l_t_A_s_s_i_g_n(matrix,x,ret); │ │ │ │ +1211 return ret; │ │ │ │ +1212 } │ │ │ │ +1213 │ │ │ │ +1215 template │ │ │ │ +1216 static inline FieldVector multTransposed(const │ │ │ │ +FieldMatrix &matrix, const FieldVector & x) │ │ │ │ +1217 { │ │ │ │ +1218 FieldVector ret; │ │ │ │ +1219 multAssignTransposed( matrix, x, ret ); │ │ │ │ +1220 return ret; │ │ │ │ +1221 } │ │ │ │ +1222#endif │ │ │ │ +1223 │ │ │ │ +1224 } // end namespace DenseMatrixHelp │ │ │ │ +1225 │ │ │ │ +1227 template │ │ │ │ +_1_2_2_8 std::ostream& _o_p_e_r_a_t_o_r_<_<_ (std::ostream& s, const _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>& a) │ │ │ │ +1229 { │ │ │ │ +1230 for (typename _D_e_n_s_e_M_a_t_r_i_x_<_M_A_T_>_:_:_s_i_z_e___t_y_p_e i=0; i sequence) │ │ │ │ -Unpack an std::integer_sequence to std::integral_constant... │ │ │ │ -DDeeffiinniittiioonn indices.hh:124 │ │ │ │ -_D_u_n_e_:_:_i_n_d_e_x___c_o_n_s_t_a_n_t │ │ │ │ -std::integral_constant< std::size_t, i > index_constant │ │ │ │ -An index constant with value i. │ │ │ │ -DDeeffiinniittiioonn indices.hh:29 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_c_h_i_l_d │ │ │ │ -decltype(auto) child(Node &&node, TreePath< Indices... > treePath) │ │ │ │ -Extracts the child of a node given by a TreePath object. │ │ │ │ -DDeeffiinniittiioonn childaccess.hh:55 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_h_i_l_d │ │ │ │ -typename Impl::ChildTraits< Node, indices... >::type Child │ │ │ │ -Template alias for the type of a child node given by a list of child indices. │ │ │ │ -DDeeffiinniittiioonn childaccess.hh:129 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_h_i_l_d_F_o_r_T_r_e_e_P_a_t_h │ │ │ │ -std::decay_t< decltype(child(std::declval< Node >(), std::declval< TreePath > │ │ │ │ -()))> ChildForTreePath │ │ │ │ -Template alias for the type of a child node given by a TreePath type. │ │ │ │ -DDeeffiinniittiioonn childaccess.hh:140 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_T_r_e_e_P_a_t_h │ │ │ │ -Dune::HybridMultiIndex< T... > TreePath │ │ │ │ -A type for representing tree paths that supports both compile time and run time │ │ │ │ -indices. │ │ │ │ -DDeeffiinniittiioonn treepath.hh:43 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_t_r_e_e_P_a_t_h │ │ │ │ -constexpr auto treePath(const T &... t) │ │ │ │ -Constructs a new TreePath from the given indices. │ │ │ │ -DDeeffiinniittiioonn treepath.hh:55 │ │ │ │ -_D_u_n_e_:_:_I_n_d_i_c_e_s │ │ │ │ -Namespace with predefined compile time indices for the range [0,19]. │ │ │ │ -DDeeffiinniittiioonn indices.hh:50 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e │ │ │ │ -DDeeffiinniittiioonn childaccess.hh:23 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_p_o_p___f_r_o_n_t │ │ │ │ -constexpr auto pop_front(const HybridMultiIndex< T... > &tp) │ │ │ │ -Removes first index on a HybridMultiIndex. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:374 │ │ │ │ -_D_u_n_e_:_:_H_y_b_r_i_d_M_u_l_t_i_I_n_d_e_x │ │ │ │ -A hybrid multi-index class that supports both compile time and run time │ │ │ │ -indices. │ │ │ │ -DDeeffiinniittiioonn hybridmultiindex.hh:81 │ │ │ │ +_D_U_N_E___A_S_S_E_R_T___B_O_U_N_D_S │ │ │ │ +#define DUNE_ASSERT_BOUNDS(cond) │ │ │ │ +If DUNE_CHECK_BOUNDS is defined: check if condition cond holds; otherwise, do │ │ │ │ +nothing. │ │ │ │ +DDeeffiinniittiioonn boundschecking.hh:30 │ │ │ │ +_D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e │ │ │ │ +typename AutonomousValueType< T >::type AutonomousValue │ │ │ │ +Type free of internal references that T can be converted to. │ │ │ │ +DDeeffiinniittiioonn typetraits.hh:566 │ │ │ │ +_D_u_n_e_:_:_o_p_e_r_a_t_o_r_<_< │ │ │ │ +std::ostream & operator<<(std::ostream &s, const bigunsignedint< k > &x) │ │ │ │ +DDeeffiinniittiioonn bigunsignedint.hh:301 │ │ │ │ +_D_U_N_E___T_H_R_O_W │ │ │ │ +#define DUNE_THROW(E,...) │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:314 │ │ │ │ +_D_u_n_e_:_:_S_i_m_d_:_:_a_n_y_T_r_u_e │ │ │ │ +bool anyTrue(const Mask &mask) │ │ │ │ +Whether any entry is true. │ │ │ │ +DDeeffiinniittiioonn simd/interface.hh:429 │ │ │ │ +_D_u_n_e_:_:_S_i_m_d_:_:_c_o_n_d │ │ │ │ +V cond(M &&mask, const V &ifTrue, const V &ifFalse) │ │ │ │ +Like the ?: operator. │ │ │ │ +DDeeffiinniittiioonn simd/interface.hh:386 │ │ │ │ +_D_u_n_e_:_:_S_i_m_d_:_:_a_l_l_T_r_u_e │ │ │ │ +bool allTrue(const Mask &mask) │ │ │ │ +Whether all entries are true. │ │ │ │ +DDeeffiinniittiioonn simd/interface.hh:439 │ │ │ │ +_D_u_n_e_:_:_S_i_m_d_:_:_S_c_a_l_a_r │ │ │ │ +typename Overloads::ScalarType< std::decay_t< V > >::type Scalar │ │ │ │ +Element type of some SIMD type. │ │ │ │ +DDeeffiinniittiioonn simd/interface.hh:235 │ │ │ │ +_D_u_n_e_:_:_S_i_m_d_:_:_M_a_s_k │ │ │ │ +Rebind< bool, V > Mask │ │ │ │ +Mask type type of some SIMD type. │ │ │ │ +DDeeffiinniittiioonn simd/interface.hh:289 │ │ │ │ +_D_u_n_e_:_:_S_i_m_d_:_:_R_e_b_i_n_d │ │ │ │ +typename Overloads::RebindType< std::decay_t< S >, std::decay_t< V > >::type │ │ │ │ +Rebind │ │ │ │ +Construct SIMD type with different scalar type. │ │ │ │ +DDeeffiinniittiioonn simd/interface.hh:252 │ │ │ │ +_D_u_n_e_:_:_S_i_m_d_:_:_l_a_n_e_s │ │ │ │ +constexpr std::size_t lanes() │ │ │ │ +Number of lanes in a SIMD type. │ │ │ │ +DDeeffiinniittiioonn simd/interface.hh:305 │ │ │ │ +_D_u_n_e_:_:_S_i_m_d_:_:_l_a_n_e │ │ │ │ +decltype(auto) lane(std::size_t l, V &&v) │ │ │ │ +Extract an element of a SIMD type. │ │ │ │ +DDeeffiinniittiioonn simd/interface.hh:324 │ │ │ │ +_D_u_n_e_:_:_S_i_m_d_:_:_O_v_e_r_l_o_a_d_s_:_:_m_a_s_k │ │ │ │ +Mask< V > mask(ADLTag< 0, std::is_same< V, Mask< V > >::value >, const V &v) │ │ │ │ +implements Simd::mask() │ │ │ │ +DDeeffiinniittiioonn defaults.hh:153 │ │ │ │ +_D_u_n_e │ │ │ │ +Dune namespace │ │ │ │ +DDeeffiinniittiioonn alignedallocator.hh:13 │ │ │ │ +_D_u_n_e_:_:_s_i_g_n │ │ │ │ +constexpr int sign(const T &val) │ │ │ │ +Return the sign of the value. │ │ │ │ +DDeeffiinniittiioonn math.hh:162 │ │ │ │ +_D_u_n_e_:_:_s_w_a_p │ │ │ │ +void swap(T &v1, T &v2, bool mask) │ │ │ │ +DDeeffiinniittiioonn simd.hh:472 │ │ │ │ +_D_u_n_e_:_:_c_o_n_j_u_g_a_t_e_C_o_m_p_l_e_x │ │ │ │ +constexpr K conjugateComplex(const K &x) │ │ │ │ +compute conjugate complex of x │ │ │ │ +DDeeffiinniittiioonn math.hh:146 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_H_e_l_p │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:1170 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_H_e_l_p_:_:_m_u_l_t_A_s_s_i_g_n │ │ │ │ +static void multAssign(const DenseMatrix< MAT > &matrix, const DenseVector< V1 │ │ │ │ +> &x, DenseVector< V2 > &ret) │ │ │ │ +calculates ret = matrix * x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:1174 │ │ │ │ +_D_u_n_e_:_:_S_t_d_:_:_a_b_s │ │ │ │ +constexpr T abs(T t) │ │ │ │ +DDeeffiinniittiioonn cmath.hh:27 │ │ │ │ +_D_u_n_e_:_:_I_s_N_u_m_b_e_r │ │ │ │ +Whether this type acts as a scalar in the context of (hierarchically blocked) │ │ │ │ +containers. │ │ │ │ +DDeeffiinniittiioonn typetraits.hh:194 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x │ │ │ │ +A dense n x m matrix. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:145 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_c_o_n_s_t___i_t_e_r_a_t_o_r │ │ │ │ +ConstIterator const_iterator │ │ │ │ +typedef for stl compliant access │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:249 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_o_p_e_r_a_t_o_r_+_= │ │ │ │ +constexpr derived_type & operator+=(const DenseMatrix< Other > &x) │ │ │ │ +vector space addition │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:294 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_b_e_f_o_r_e_B_e_g_i_n │ │ │ │ +constexpr Iterator beforeBegin() │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:241 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_u_m_h_v │ │ │ │ +constexpr void umhv(const X &x, Y &y) const │ │ │ │ +y += A^H x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:437 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_o_p_e_r_a_t_o_r_*_= │ │ │ │ +constexpr derived_type & operator*=(const field_type &k) │ │ │ │ +vector space multiplication with scalar │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:326 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_u_s_m_h_v │ │ │ │ +constexpr void usmhv(const typename FieldTraits< Y >::field_type &alpha, const │ │ │ │ +X &x, Y &y) const │ │ │ │ +y += alpha A^H x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:517 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_o_p_e_r_a_t_o_r_-_= │ │ │ │ +constexpr derived_type & operator-=(const DenseMatrix< Other > &x) │ │ │ │ +vector space subtraction │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:317 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_s_o_l_v_e │ │ │ │ +void solve(V1 &x, const V2 &b, bool doPivoting=true) const │ │ │ │ +Solve system A x = b. │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_f_i_e_l_d___t_y_p_e │ │ │ │ +Traits::value_type field_type │ │ │ │ +export the type representing the field │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:165 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_b_e_f_o_r_e_E_n_d │ │ │ │ +constexpr ConstIterator beforeEnd() const │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:269 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_o_p_e_r_a_t_o_r_!_= │ │ │ │ +constexpr bool operator!=(const DenseMatrix< Other > &x) const │ │ │ │ +Binary matrix incomparison. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:363 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_a_x_p_y │ │ │ │ +constexpr derived_type & axpy(const field_type &a, const DenseMatrix< Other > │ │ │ │ +&x) │ │ │ │ +vector space axpy operation (*this += a x) │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:343 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_C_o_n_s_t_C_o_l_I_t_e_r_a_t_o_r │ │ │ │ +std::remove_reference< const_row_reference >::type::ConstIterator │ │ │ │ +ConstColIterator │ │ │ │ +rename the iterators for easier access │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:253 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_i_n_v_e_r_t │ │ │ │ +void invert(bool doPivoting=true) │ │ │ │ +Compute inverse. │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_u_s_m_t_v │ │ │ │ +constexpr void usmtv(const typename FieldTraits< Y >::field_type &alpha, const │ │ │ │ +X &x, Y &y) const │ │ │ │ +y += alpha A^T x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:503 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_l_u_D_e_c_o_m_p_o_s_i_t_i_o_n │ │ │ │ +static void luDecomposition(DenseMatrix< MAT > &A, Func func, Mask │ │ │ │ +&nonsingularLanes, bool throwEarly, bool doPivoting) │ │ │ │ +do an LU-Decomposition on matrix A │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_b_l_o_c_k___t_y_p_e │ │ │ │ +Traits::value_type block_type │ │ │ │ +export the type representing the components │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:168 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_c_o_l_s │ │ │ │ +constexpr size_type cols() const │ │ │ │ +number of columns │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:720 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_s_i_z_e │ │ │ │ +constexpr size_type size() const │ │ │ │ +size method (number of rows) │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:205 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_<_ _D_y_n_a_m_i_c_M_a_t_r_i_x_<_ _K_ _>_ _>_:_:_M │ │ │ │ +constexpr size_type M() const │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:708 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_m_m_h_v │ │ │ │ +constexpr void mmhv(const X &x, Y &y) const │ │ │ │ +y -= A^H x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:476 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_r_i_g_h_t_m_u_l_t_i_p_l_y │ │ │ │ +MAT & rightmultiply(const DenseMatrix< M2 > &M) │ │ │ │ +Multiplies M from the right to this matrix. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:650 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_b_e_f_o_r_e_E_n_d │ │ │ │ +constexpr Iterator beforeEnd() │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:234 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_b_e_f_o_r_e_B_e_g_i_n │ │ │ │ +constexpr ConstIterator beforeBegin() const │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:276 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_f_r_o_b_e_n_i_u_s___n_o_r_m │ │ │ │ +constexpr FieldTraits< value_type >::real_type frobenius_norm() const │ │ │ │ +frobenius norm: sqrt(sum over squared values of entries) │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:533 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_v_a_l_u_e___t_y_p_e │ │ │ │ +Traits::value_type value_type │ │ │ │ +export the type representing the field │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:162 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_e_n_d │ │ │ │ +constexpr Iterator end() │ │ │ │ +end iterator │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:227 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_o_p_e_r_a_t_o_r_/_= │ │ │ │ +constexpr derived_type & operator/=(const field_type &k) │ │ │ │ +vector space division by scalar │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:334 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_o_p_e_r_a_t_o_r_- │ │ │ │ +constexpr derived_type operator-() const │ │ │ │ +Matrix negation. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:303 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_r_o_w_s │ │ │ │ +constexpr size_type rows() const │ │ │ │ +number of rows │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:714 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_m_v │ │ │ │ +constexpr void mv(const X &x, Y &y) const │ │ │ │ +y = A x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:373 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_l_e_f_t_m_u_l_t_i_p_l_y │ │ │ │ +MAT & leftmultiply(const DenseMatrix< M2 > &M) │ │ │ │ +Multiplies M from the left to this matrix. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:632 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_m_t_v │ │ │ │ +constexpr void mtv(const X &x, Y &y) const │ │ │ │ +y = A^T x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:392 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_i_n_f_i_n_i_t_y___n_o_r_m │ │ │ │ +constexpr FieldTraits< vt >::real_type infinity_norm() const │ │ │ │ +infinity norm (row sum norm, how to generalize for blocks?) │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:551 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ +constexpr row_reference operator[](size_type i) │ │ │ │ +random access │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:194 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_u_m_v │ │ │ │ +constexpr void umv(const X &x, Y &y) const │ │ │ │ +y += A x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:411 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_d_e_r_i_v_e_d___t_y_p_e │ │ │ │ +Traits::derived_type derived_type │ │ │ │ +type of derived matrix class │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:159 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_e_x_i_s_t_s │ │ │ │ +constexpr bool exists(size_type i, size_type j) const │ │ │ │ +return true when (i,j) is in pattern │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:728 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_u_s_m_v │ │ │ │ +constexpr void usmv(const typename FieldTraits< Y >::field_type &alpha, const X │ │ │ │ +&x, Y &y) const │ │ │ │ +y += alpha A x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:489 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_R_o_w_I_t_e_r_a_t_o_r │ │ │ │ +Iterator RowIterator │ │ │ │ +rename the iterators for easier access │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:216 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_<_ _D_y_n_a_m_i_c_M_a_t_r_i_x_<_ _K_ _>_ _>_:_:_b_l_o_c_k_l_e_v_e_l │ │ │ │ +static constexpr int blocklevel │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:183 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_b_e_g_i_n │ │ │ │ +constexpr ConstIterator begin() const │ │ │ │ +begin iterator │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:256 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_u_m_t_v │ │ │ │ +constexpr void umtv(const X &x, Y &y) const │ │ │ │ +y += A^T x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:424 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_C_o_n_s_t_I_t_e_r_a_t_o_r │ │ │ │ +DenseIterator< const DenseMatrix, const row_type, const_row_reference > │ │ │ │ +ConstIterator │ │ │ │ +Iterator class for sequential access. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:247 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_m_m_t_v │ │ │ │ +constexpr void mmtv(const X &x, Y &y) const │ │ │ │ +y -= A^T x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:463 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_e_n_d │ │ │ │ +constexpr ConstIterator end() const │ │ │ │ +end iterator │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:262 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_f_r_o_b_e_n_i_u_s___n_o_r_m_2 │ │ │ │ +constexpr FieldTraits< value_type >::real_type frobenius_norm2() const │ │ │ │ +square of frobenius norm, need for block recursion │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:541 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_r_o_w___t_y_p_e │ │ │ │ +Traits::row_type row_type │ │ │ │ +The type used to represent a row (must fulfill the Dune::DenseVector │ │ │ │ +interface). │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:174 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_<_ _D_y_n_a_m_i_c_M_a_t_r_i_x_<_ _K_ _>_ _>_:_:_N │ │ │ │ +constexpr size_type N() const │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:702 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_o_p_e_r_a_t_o_r_=_= │ │ │ │ +constexpr bool operator==(const DenseMatrix< Other > &x) const │ │ │ │ +Binary matrix comparison. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:353 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_s_i_z_e___t_y_p_e │ │ │ │ +Traits::size_type size_type │ │ │ │ +The type used for the index access and size operation. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:171 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_c_o_n_s_t___r_o_w___r_e_f_e_r_e_n_c_e │ │ │ │ +Traits::const_row_reference const_row_reference │ │ │ │ +The type used to represent a reference to a constant row (usually const │ │ │ │ +row_type &). │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:180 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_C_o_l_I_t_e_r_a_t_o_r │ │ │ │ +std::remove_reference< row_reference >::type::Iterator ColIterator │ │ │ │ +rename the iterators for easier access │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:218 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_r_o_w___r_e_f_e_r_e_n_c_e │ │ │ │ +Traits::row_reference row_reference │ │ │ │ +The type used to represent a reference to a row (usually row_type &). │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:177 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_D_e_n_s_e_M_a_t_r_i_x │ │ │ │ +friend class DenseMatrix │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:153 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_m_m_v │ │ │ │ +constexpr void mmv(const X &x, Y &y) const │ │ │ │ +y -= A x │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:450 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_i_t_e_r_a_t_o_r │ │ │ │ +Iterator iterator │ │ │ │ +typedef for stl compliant access │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:214 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_i_n_f_i_n_i_t_y___n_o_r_m___r_e_a_l │ │ │ │ +constexpr FieldTraits< vt >::real_type infinity_norm_real() const │ │ │ │ +simplified infinity norm (uses Manhattan norm for complex values) │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:566 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_C_o_n_s_t_R_o_w_I_t_e_r_a_t_o_r │ │ │ │ +ConstIterator ConstRowIterator │ │ │ │ +rename the iterators for easier access │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:251 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_b_e_g_i_n │ │ │ │ +constexpr Iterator begin() │ │ │ │ +begin iterator │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:221 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_o_p_e_r_a_t_o_r_= │ │ │ │ +constexpr derived_type & operator=(const RHS &rhs) │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:284 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_I_t_e_r_a_t_o_r │ │ │ │ +DenseIterator< DenseMatrix, row_type, row_reference > Iterator │ │ │ │ +Iterator class for sequential access. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:212 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_:_:_d_e_t_e_r_m_i_n_a_n_t │ │ │ │ +field_type determinant(bool doPivoting=true) const │ │ │ │ +calculates the determinant of this matrix │ │ │ │ +_D_u_n_e_:_:_F_i_e_l_d_T_r_a_i_t_s_<_ _D_e_n_s_e_M_a_t_r_i_x_<_ _M_ _>_ _>_:_:_r_e_a_l___t_y_p_e │ │ │ │ +const FieldTraits< typenameDenseMatVecTraits< M >::value_type >::real_type │ │ │ │ +real_type │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:36 │ │ │ │ +_D_u_n_e_:_:_F_i_e_l_d_T_r_a_i_t_s_<_ _D_e_n_s_e_M_a_t_r_i_x_<_ _M_ _>_ _>_:_:_f_i_e_l_d___t_y_p_e │ │ │ │ +const FieldTraits< typenameDenseMatVecTraits< M >::value_type >::field_type │ │ │ │ +field_type │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:35 │ │ │ │ +_D_u_n_e_:_:_F_i_e_l_d_M_a_t_r_i_x │ │ │ │ +A dense n x m matrix. │ │ │ │ +DDeeffiinniittiioonn fmatrix.hh:117 │ │ │ │ +_D_u_n_e_:_:_F_i_e_l_d_M_a_t_r_i_x_:_:_s_i_z_e___t_y_p_e │ │ │ │ +Base::size_type size_type │ │ │ │ +DDeeffiinniittiioonn fmatrix.hh:128 │ │ │ │ +_D_u_n_e_:_:_F_i_e_l_d_V_e_c_t_o_r │ │ │ │ +vector space out of a tensor product of fields. │ │ │ │ +DDeeffiinniittiioonn fvector.hh:97 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_r_i_x_A_s_s_i_g_n_e_r │ │ │ │ +you have to specialize this structure for any type that should be assignable to │ │ │ │ +a DenseMatrix │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:61 │ │ │ │ +_D_u_n_e_:_:_F_M_a_t_r_i_x_E_r_r_o_r │ │ │ │ +Error thrown if operations of a FieldMatrix fail. │ │ │ │ +DDeeffiinniittiioonn densematrix.hh:131 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_V_e_c_t_o_r │ │ │ │ +Interface for a class of dense vectors over a given field. │ │ │ │ +DDeeffiinniittiioonn densevector.hh:244 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_V_e_c_t_o_r_:_:_s_i_z_e │ │ │ │ +constexpr size_type size() const │ │ │ │ +size method │ │ │ │ +DDeeffiinniittiioonn densevector.hh:351 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_I_t_e_r_a_t_o_r │ │ │ │ +Generic iterator class for dense vector and matrix implementations. │ │ │ │ +DDeeffiinniittiioonn densevector.hh:132 │ │ │ │ +_D_u_n_e_:_:_M_a_t_h_E_r_r_o_r │ │ │ │ +Default exception class for mathematical errors. │ │ │ │ +DDeeffiinniittiioonn exceptions.hh:335 │ │ │ │ +_D_u_n_e_:_:_F_i_e_l_d_T_r_a_i_t_s │ │ │ │ +DDeeffiinniittiioonn ftraits.hh:26 │ │ │ │ +_D_u_n_e_:_:_F_i_e_l_d_T_r_a_i_t_s_:_:_f_i_e_l_d___t_y_p_e │ │ │ │ +T field_type │ │ │ │ +export the type representing the field │ │ │ │ +DDeeffiinniittiioonn ftraits.hh:28 │ │ │ │ +_D_u_n_e_:_:_F_i_e_l_d_T_r_a_i_t_s_:_:_r_e_a_l___t_y_p_e │ │ │ │ +T real_type │ │ │ │ +export the type representing the real type of the field │ │ │ │ +DDeeffiinniittiioonn ftraits.hh:30 │ │ │ │ +_D_u_n_e_:_:_D_e_n_s_e_M_a_t_V_e_c_T_r_a_i_t_s │ │ │ │ +DDeeffiinniittiioonn matvectraits.hh:31 │ │ │ │ +_D_u_n_e_:_:_F_M_a_t_r_i_x_P_r_e_c_i_s_i_o_n_:_:_a_b_s_o_l_u_t_e___l_i_m_i_t │ │ │ │ +static ctype absolute_limit() │ │ │ │ +return threshold to declare matrix singular │ │ │ │ +DDeeffiinniittiioonn precision.hh:28 │ │ │ │ _D_u_n_e_:_:_t_y_p_e │ │ │ │ -_D_u_n_e_:_:_M_e_t_a_T_y_p_e │ │ │ │ -A type that refers to another type. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:33 │ │ │ │ -_D_u_n_e_:_:_I_s_I_n_t_e_g_r_a_l_C_o_n_s_t_a_n_t │ │ │ │ -Check if T is an std::integral_constant. │ │ │ │ -DDeeffiinniittiioonn typetraits.hh:384 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_T_r_e_e_:_:_C_o_n_c_e_p_t_:_:_S_t_a_t_i_c_D_e_g_r_e_e_I_n_n_e_r_T_r_e_e_N_o_d_e │ │ │ │ -Model of an inner node of a typetree with compile time known degree and child │ │ │ │ -access via index_consta... │ │ │ │ -DDeeffiinniittiioonn nodeconcepts.hh:41 │ │ │ │ +_s_i_m_d_._h_h │ │ │ │ +Include file for users of the SIMD abstraction layer. │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00038.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: typetraits.hh File Reference │ │ │ +dune-common: path.cc File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -72,108 +72,52 @@ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ -Classes | │ │ │ Namespaces | │ │ │ -Typedefs | │ │ │ Functions
│ │ │ -
typetraits.hh File Reference
│ │ │ +
path.cc File Reference
│ │ │
│ │ │
│ │ │ │ │ │ -

Traits for type conversions and type information. │ │ │ +

Utilities for handling filesystem paths. │ │ │ More...

│ │ │ -
#include <complex>
│ │ │ -#include <type_traits>
│ │ │ -#include <utility>
│ │ │ -#include <vector>
│ │ │ -
│ │ │ -

Go to the source code of this file.

│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -

│ │ │ -Classes

struct  Dune::Empty
 Just an empty class. More...
struct  Dune::IsInteroperable< T1, T2 >
 Checks whether two types are interoperable. More...
struct  Dune::EnableIfInterOperable< T1, T2, Type >
 Enable typedef if two types are interoperable. More...
struct  Dune::AlwaysFalse< T >
 template which always yields a false value More...
struct  Dune::AlwaysTrue< T >
 template which always yields a true value More...
struct  Dune::IsCallable< F(Args...), R >
 Check if a type is callable with ()-operator and given arguments. More...
struct  Dune::IsNumber< T >
 Whether this type acts as a scalar in the context of (hierarchically blocked) containers. More...
struct  Dune::HasNaN< T >
 Whether this type has a value of NaN. More...
struct  Dune::IsIndexable< T, I >
 Type trait to determine whether an instance of T has an operator[](I), i.e. whether it can be indexed with an index of type I. More...
struct  Dune::IsIterable< T, typename >
 typetrait to check that a class has begin() and end() members More...
struct  Dune::IsTuple< T >
 Check if T is a std::tuple<...>. More...
struct  Dune::IsTupleOrDerived< T >
 Check if T derived from a std::tuple<...>. More...
struct  Dune::IsIntegralConstant< T >
 Check if T is an std::integral_constant<I, i>. More...
struct  Dune::IsCompileTimeConstant< T >
 Check if T is an integral constant or any type derived from std::integral_constant. More...
struct  Dune::AutonomousValueType< T >
 Type free of internal references that T can be converted to. More...
struct  Dune::AutonomousValueType< T & >
 Specialization to remove lvalue references. More...
struct  Dune::AutonomousValueType< T && >
 Specialization to remove rvalue references. More...
struct  Dune::AutonomousValueType< const T >
 Specialization to remove const qualifiers. More...
struct  Dune::AutonomousValueType< volatile T >
 Specialization to remove volatile qualifiers. More...
struct  Dune::AutonomousValueType< std::vector< bool >::reference >
 Specialization for the proxies of vector<bool>. More...
struct  Dune::AutonomousValueType< volatile const T >
 Specialization to remove both const and volatile qualifiers. More...
│ │ │ +
#include <algorithm>
│ │ │ +#include <iterator>
│ │ │ +#include <string>
│ │ │ +#include <dune/common/exceptions.hh>
│ │ │ +#include <dune/common/stringutility.hh>
│ │ │ +#include <dune/common/path.hh>
│ │ │ +
│ │ │ │ │ │ │ │ │ │ │ │

│ │ │ Namespaces

namespace  Dune
 Dune namespace
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -

│ │ │ -Typedefs

template<class... Types>
using Dune::void_t = typename Impl::voider<Types...>::type
 Is void for all valid input types. The workhorse for C++11 SFINAE-techniques.
template<class Type>
using Dune::field_t = typename FieldTraits<Type>::field_type
 Convenient access to FieldTraits<Type>::field_type.
template<class Type>
using Dune::real_t = typename FieldTraits<Type>::real_type
 Convenient access to FieldTraits<Type>::real_type.
template<class T>
using Dune::AutonomousValue = typename AutonomousValueType<T>::type
 Type free of internal references that T can be converted to.
│ │ │ │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ Functions

template<class T, T... t, std::size_t index>
constexpr auto Dune::integerSequenceEntry (std::integer_sequence< T, t... >, std::integral_constant< std::size_t, index > i)
 Get entry of std::integer_sequence.
template<class T>
constexpr AutonomousValue< T > Dune::autoCopy (T &&v)
 Autonomous copy of an expression's value for use in auto type deduction.
std::string Dune::concatPaths (const std::string &base, const std::string &p)
 concatenate two paths
std::string Dune::processPath (const std::string &p)
 sanitize a path for further processing
bool Dune::pathIndicatesDirectory (const std::string &p)
 check whether the given path indicates that it is a directory
std::string Dune::prettyPath (const std::string &p, bool isDirectory)
 pretty print path
std::string Dune::prettyPath (const std::string &p)
 pretty print path
std::string Dune::relativePath (const std::string &newbase, const std::string &p)
 compute a relative path between two paths
│ │ │

Detailed Description

│ │ │ -

Traits for type conversions and type information.

│ │ │ -
Author
Markus Blatt, Christian Engwer
│ │ │ +

Utilities for handling filesystem paths.

│ │ │ +
Author
Jö Fahlke jorri.nosp@m.t@jo.nosp@m.rrit..nosp@m.de
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── encoding │ │ │ │ @@ -1 +1 @@ │ │ │ │ -us-ascii │ │ │ │ +utf-8 │ │ │ ├── html2text {} │ │ │ │ @@ -1,94 +1,39 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s | _F_u_n_c_t_i_o_n_s │ │ │ │ -typetraits.hh File Reference │ │ │ │ -Traits for type conversions and type information. _M_o_r_e_._._. │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ -_G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -CCllaasssseess │ │ │ │ -struct   _D_u_n_e_:_:_E_m_p_t_y │ │ │ │ -  Just an empty class. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_I_n_t_e_r_o_p_e_r_a_b_l_e_<_ _T_1_,_ _T_2_ _> │ │ │ │ -  Checks whether two types are interoperable. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_E_n_a_b_l_e_I_f_I_n_t_e_r_O_p_e_r_a_b_l_e_<_ _T_1_,_ _T_2_,_ _T_y_p_e_ _> │ │ │ │ -  Enable typedef if two types are interoperable. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_l_w_a_y_s_F_a_l_s_e_<_ _T_ _> │ │ │ │ -  template which always yields a false value _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_l_w_a_y_s_T_r_u_e_<_ _T_ _> │ │ │ │ -  template which always yields a true value _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_C_a_l_l_a_b_l_e_<_ _F_(_A_r_g_s_._._._)_,_ _R_ _> │ │ │ │ -  Check if a type is callable with ()-operator and given arguments. │ │ │ │ - _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_N_u_m_b_e_r_<_ _T_ _> │ │ │ │ -  Whether this type acts as a scalar in the context of (hierarchically │ │ │ │ - blocked) containers. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_H_a_s_N_a_N_<_ _T_ _> │ │ │ │ -  Whether this type has a value of NaN. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_I_n_d_e_x_a_b_l_e_<_ _T_,_ _I_ _> │ │ │ │ -  Type trait to determine whether an instance of T has an operator[](I), │ │ │ │ - i.e. whether it can be indexed with an index of type I. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_I_t_e_r_a_b_l_e_<_ _T_,_ _t_y_p_e_n_a_m_e_ _> │ │ │ │ -  typetrait to check that a class has begin() and end() members _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_T_u_p_l_e_<_ _T_ _> │ │ │ │ -  Check if T is a std::tuple<...>. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_T_u_p_l_e_O_r_D_e_r_i_v_e_d_<_ _T_ _> │ │ │ │ -  Check if T derived from a std::tuple<...>. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_I_n_t_e_g_r_a_l_C_o_n_s_t_a_n_t_<_ _T_ _> │ │ │ │ -  Check if T is an std::integral_constant. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_C_o_m_p_i_l_e_T_i_m_e_C_o_n_s_t_a_n_t_<_ _T_ _> │ │ │ │ -  Check if T is an integral constant or any type derived from std:: │ │ │ │ - integral_constant. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e_<_ _T_ _> │ │ │ │ -  Type free of internal references that T can be converted to. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e_<_ _T_ _&_ _> │ │ │ │ -  Specialization to remove lvalue references. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e_<_ _T_ _&_&_ _> │ │ │ │ -  Specialization to remove rvalue references. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e_<_ _c_o_n_s_t_ _T_ _> │ │ │ │ -  Specialization to remove const qualifiers. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e_<_ _v_o_l_a_t_i_l_e_ _T_ _> │ │ │ │ -  Specialization to remove volatile qualifiers. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e_<_ _s_t_d_:_:_v_e_c_t_o_r_<_ _b_o_o_l_ _>_:_:_r_e_f_e_r_e_n_c_e_ _> │ │ │ │ -  Specialization for the proxies of vector. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e_<_ _v_o_l_a_t_i_l_e_ _c_o_n_s_t_ _T_ _> │ │ │ │ -  Specialization to remove both const and volatile qualifiers. _M_o_r_e_._._. │ │ │ │ +_N_a_m_e_s_p_a_c_e_s | _F_u_n_c_t_i_o_n_s │ │ │ │ +path.cc File Reference │ │ │ │ +_C_o_m_m_o_n » _U_t_i_l_i_t_i_e_s » _F_i_l_e_s_y_s_t_e_m_ _P_a_t_h_s │ │ │ │ +Utilities for handling filesystem paths. _M_o_r_e_._._. │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_e_x_c_e_p_t_i_o_n_s_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_t_r_i_n_g_u_t_i_l_i_t_y_._h_h> │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_p_a_t_h_._h_h> │ │ │ │ NNaammeessppaacceess │ │ │ │ namespace   _D_u_n_e │ │ │ │   Dune namespace │ │ │ │ -TTyyppeeddeeffss │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_v_o_i_d___t = typename Impl::voider_:_:_t_y_p_e │ │ │ │ -  Is void for all valid input types. The workhorse for C++11 SFINAE- │ │ │ │ - techniques. │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_f_i_e_l_d___t = typename _F_i_e_l_d_T_r_a_i_t_s_:_:_f_i_e_l_d___t_y_p_e │ │ │ │ -  Convenient access to _F_i_e_l_d_T_r_a_i_t_s_<_T_y_p_e_>_:_:_f_i_e_l_d___t_y_p_e. │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_r_e_a_l___t = typename _F_i_e_l_d_T_r_a_i_t_s_:_:_r_e_a_l___t_y_p_e │ │ │ │ -  Convenient access to _F_i_e_l_d_T_r_a_i_t_s_<_T_y_p_e_>_:_:_r_e_a_l___t_y_p_e. │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_A_u_t_o_n_o_m_o_u_s_V_a_l_u_e = typename _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e_T_y_p_e_:_:_t_y_p_e │ │ │ │ -  Type free of internal references that T can be converted to. │ │ │ │ FFuunnccttiioonnss │ │ │ │ -template │ │ │ │ - constexpr auto  _D_u_n_e_:_:_i_n_t_e_g_e_r_S_e_q_u_e_n_c_e_E_n_t_r_y (std:: │ │ │ │ - integer_sequence< T, t... >, std:: │ │ │ │ - integral_constant< std::size_t, index > i) │ │ │ │ -  Get entry of std::integer_sequence. │ │ │ │ -template │ │ │ │ -constexpr _A_u_t_o_n_o_m_o_u_s_V_a_l_u_e< T >  _D_u_n_e_:_:_a_u_t_o_C_o_p_y (T &&v) │ │ │ │ -  Autonomous copy of an expression's value for │ │ │ │ - use in auto type deduction. │ │ │ │ +std::string  _D_u_n_e_:_:_c_o_n_c_a_t_P_a_t_h_s (const std::string &base, const std::string &p) │ │ │ │ +  concatenate two paths │ │ │ │ +std::string  _D_u_n_e_:_:_p_r_o_c_e_s_s_P_a_t_h (const std::string &p) │ │ │ │ +  sanitize a path for further processing │ │ │ │ + bool  _D_u_n_e_:_:_p_a_t_h_I_n_d_i_c_a_t_e_s_D_i_r_e_c_t_o_r_y (const std::string &p) │ │ │ │ +  check whether the given path indicates that it is a directory │ │ │ │ +std::string  _D_u_n_e_:_:_p_r_e_t_t_y_P_a_t_h (const std::string &p, bool isDirectory) │ │ │ │ +  pretty print path │ │ │ │ +std::string  _D_u_n_e_:_:_p_r_e_t_t_y_P_a_t_h (const std::string &p) │ │ │ │ +  pretty print path │ │ │ │ +std::string  _D_u_n_e_:_:_r_e_l_a_t_i_v_e_P_a_t_h (const std::string &newbase, const std::string │ │ │ │ + &p) │ │ │ │ +  compute a relative path between two paths │ │ │ │ ********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ -Traits for type conversions and type information. │ │ │ │ +Utilities for handling filesystem paths. │ │ │ │ Author │ │ │ │ - Markus Blatt, Christian Engwer │ │ │ │ + Jö Fahlke _j_o_r_r_i_._n_o_s_p_@_m_._t_@_j_o_._n_o_s_p_@_m_._r_r_i_t_._._n_o_s_p_@_m_._d_e │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00041.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: typelist.hh File Reference │ │ │ +dune-common: propertymap.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -74,70 +74,60 @@ │ │ │
│ │ │ │ │ │
│ │ │
│ │ │
│ │ │ Classes | │ │ │ Namespaces | │ │ │ -Typedefs | │ │ │ Functions
│ │ │ -
typelist.hh File Reference
│ │ │ +
propertymap.hh File Reference
│ │ │
│ │ │
│ │ │ -
#include <type_traits>
│ │ │ -#include <tuple>
│ │ │ -#include <utility>
│ │ │ +
#include <cstddef>
│ │ │ +#include <iterator>
│ │ │ +#include <type_traits>
│ │ │
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ Classes

struct  Dune::MetaType< T >
 A type that refers to another type. More...
struct  Dune::IsTypeList< T >
 Check if given type is a TypeList. More...
struct  Dune::IsTypeList< TypeList< T... > >
 Check if given type is a TypeList. More...
struct  Dune::IsEmptyTypeList< T >
 Check if given type is an empty TypeList. More...
struct  Dune::TypeListSize< T >
struct  Dune::TypeListSize< TypeList< T... > >
 Get size of TypeList. More...
struct  Dune::TypeListElement< i, T >
struct  Dune::TypeListElement< i, TypeList< T... > >
 Get element of TypeList. More...
struct  Dune::PropertyMapTraits< PM >
struct  Dune::ReadablePropertyMapTag
 Tag for the category of readable property maps. More...
struct  Dune::WritablePropertyMapTag
 Tag for the category of writable property maps. More...
struct  Dune::ReadWritePropertyMapTag
 Tag for the category of readable and writable property maps. More...
struct  Dune::LvaluePropertyMapTag
 Tag for the category of lvalue property maps. More...
struct  Dune::PropertyMapTraits< T * >
struct  Dune::PropertyMapTraits< const T * >
struct  Dune::RAPropertyMapHelper< Reference, PropertyMap >
class  Dune::IteratorPropertyMap< RAI, IM, T, R >
 Adapter to turn a random access iterator into a property map. More...
class  Dune::AssociativePropertyMap< T >
 An adapter to turn an unique associative container into a property map. More...
class  Dune::ConstAssociativePropertyMap< T >
 An adaptor to turn an unique associative container into a property map. More...
struct  Dune::IdentityMap
 A property map that applies the identity function to integers. More...
struct  Dune::PropertyMapTypeSelector< T, C >
 Selector for the property map type. More...
│ │ │ │ │ │ │ │ │ │ │ │

│ │ │ Namespaces

namespace  Dune
 Dune namespace
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -

│ │ │ -Typedefs

template<class... T>
using Dune::TypeList = std::tuple<MetaType<T>...>
 A simple type list.
template<std::size_t i, class T>
using Dune::TypeListEntry_t = typename TypeListElement<i, T>::type
 Shortcut for TypeListElement<i, T>::type;.
template<template< class... > class Target, class TL>
using Dune::UnpackTypeList_t = typename Impl::UnpackTypeList<Target, TL>::type
 Unpack Dune::TypeList.
template<template< class... > class Target, class... T>
using Dune::UniqueTypes_t = typename Impl::UniqueTypesHelper<Target, TypeList<T...>>::type
 Remove duplicates from a list of types.
template<class NonUniqueTypeList>
using Dune::UniqueTypeList_t = typename Impl::UniqueTypesHelper<TypeList, NonUniqueTypeList>::type
 Remove duplicates from a Dune::TypeList.
│ │ │ │ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ Functions

template<class... T>
constexpr auto Dune::uniqueTypeList (TypeList< T... >)
 Remove duplicates from a Dune::TypeList.
template<class Reference, class PropertyMap, class Key>
Reference Dune::get (const RAPropertyMapHelper< Reference, PropertyMap > &pmap, const Key &key)
template<class Reference, class PropertyMap, class Key, class Value>
void Dune::put (const RAPropertyMapHelper< Reference, PropertyMap > &pmap, const Key &key, const Value &value)
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ ├── html2text {} │ │ │ │ @@ -1,54 +1,49 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _T_y_p_e_d_e_f_s | _F_u_n_c_t_i_o_n_s │ │ │ │ -typelist.hh File Reference │ │ │ │ +_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _F_u_n_c_t_i_o_n_s │ │ │ │ +propertymap.hh File Reference │ │ │ │ +#include │ │ │ │ +#include │ │ │ │ #include │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ CCllaasssseess │ │ │ │ -struct   _D_u_n_e_:_:_M_e_t_a_T_y_p_e_<_ _T_ _> │ │ │ │ -  A type that refers to another type. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_T_y_p_e_L_i_s_t_<_ _T_ _> │ │ │ │ -  Check if given type is a _T_y_p_e_L_i_s_t. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_T_y_p_e_L_i_s_t_<_ _T_y_p_e_L_i_s_t_<_ _T_._._._ _>_ _> │ │ │ │ -  Check if given type is a _T_y_p_e_L_i_s_t. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_E_m_p_t_y_T_y_p_e_L_i_s_t_<_ _T_ _> │ │ │ │ -  Check if given type is an empty _T_y_p_e_L_i_s_t. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_T_y_p_e_L_i_s_t_S_i_z_e_<_ _T_ _> │ │ │ │ -struct   _D_u_n_e_:_:_T_y_p_e_L_i_s_t_S_i_z_e_<_ _T_y_p_e_L_i_s_t_<_ _T_._._._ _>_ _> │ │ │ │ -  Get size of _T_y_p_e_L_i_s_t. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_T_y_p_e_L_i_s_t_E_l_e_m_e_n_t_<_ _i_,_ _T_ _> │ │ │ │ -struct   _D_u_n_e_:_:_T_y_p_e_L_i_s_t_E_l_e_m_e_n_t_<_ _i_,_ _T_y_p_e_L_i_s_t_<_ _T_._._._ _>_ _> │ │ │ │ -  Get element of _T_y_p_e_L_i_s_t. _M_o_r_e_._._. │ │ │ │ +struct   _D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _P_M_ _> │ │ │ │ +struct   _D_u_n_e_:_:_R_e_a_d_a_b_l_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +  Tag for the category of readable property maps. _M_o_r_e_._._. │ │ │ │ +struct   _D_u_n_e_:_:_W_r_i_t_a_b_l_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +  Tag for the category of writable property maps. _M_o_r_e_._._. │ │ │ │ +struct   _D_u_n_e_:_:_R_e_a_d_W_r_i_t_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +  Tag for the category of readable and writable property maps. _M_o_r_e_._._. │ │ │ │ +struct   _D_u_n_e_:_:_L_v_a_l_u_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +  Tag for the category of lvalue property maps. _M_o_r_e_._._. │ │ │ │ +struct   _D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _T_ _*_ _> │ │ │ │ +struct   _D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _c_o_n_s_t_ _T_ _*_ _> │ │ │ │ +struct   _D_u_n_e_:_:_R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r_<_ _R_e_f_e_r_e_n_c_e_,_ _P_r_o_p_e_r_t_y_M_a_p_ _> │ │ │ │ + class   _D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_<_ _R_A_I_,_ _I_M_,_ _T_,_ _R_ _> │ │ │ │ +  Adapter to turn a random access iterator into a property map. _M_o_r_e_._._. │ │ │ │ + class   _D_u_n_e_:_:_A_s_s_o_c_i_a_t_i_v_e_P_r_o_p_e_r_t_y_M_a_p_<_ _T_ _> │ │ │ │ +  An adapter to turn an unique associative container into a property │ │ │ │ + map. _M_o_r_e_._._. │ │ │ │ + class   _D_u_n_e_:_:_C_o_n_s_t_A_s_s_o_c_i_a_t_i_v_e_P_r_o_p_e_r_t_y_M_a_p_<_ _T_ _> │ │ │ │ +  An adaptor to turn an unique associative container into a property │ │ │ │ + map. _M_o_r_e_._._. │ │ │ │ +struct   _D_u_n_e_:_:_I_d_e_n_t_i_t_y_M_a_p │ │ │ │ +  A property map that applies the identity function to integers. _M_o_r_e_._._. │ │ │ │ +struct   _D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_y_p_e_S_e_l_e_c_t_o_r_<_ _T_,_ _C_ _> │ │ │ │ +  Selector for the property map type. _M_o_r_e_._._. │ │ │ │ NNaammeessppaacceess │ │ │ │ namespace   _D_u_n_e │ │ │ │   Dune namespace │ │ │ │ -TTyyppeeddeeffss │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_T_y_p_e_L_i_s_t = std::tuple<_M_e_t_a_T_y_p_e...> │ │ │ │ -  A simple type list. │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_T_y_p_e_L_i_s_t_E_n_t_r_y___t = typename _T_y_p_e_L_i_s_t_E_l_e_m_e_n_t_:_:_t_y_p_e │ │ │ │ -  Shortcut for TypeListElement::type;. │ │ │ │ -template class Target, class TL> │ │ │ │ -using  _D_u_n_e_:_:_U_n_p_a_c_k_T_y_p_e_L_i_s_t___t = typename Impl::UnpackTypeList_:_:_t_y_p_e │ │ │ │ -  Unpack _D_u_n_e_:_:_T_y_p_e_L_i_s_t. │ │ │ │ -template class Target, class... T> │ │ │ │ -using  _D_u_n_e_:_:_U_n_i_q_u_e_T_y_p_e_s___t = typename Impl::UniqueTypesHelper>_:_:_t_y_p_e │ │ │ │ -  Remove duplicates from a list of types. │ │ │ │ -template │ │ │ │ -using  _D_u_n_e_:_:_U_n_i_q_u_e_T_y_p_e_L_i_s_t___t = typename Impl::UniqueTypesHelper<_T_y_p_e_L_i_s_t, │ │ │ │ - NonUniqueTypeList>_:_:_t_y_p_e │ │ │ │ -  Remove duplicates from a _D_u_n_e_:_:_T_y_p_e_L_i_s_t. │ │ │ │ FFuunnccttiioonnss │ │ │ │ -template │ │ │ │ -constexpr auto  _D_u_n_e_:_:_u_n_i_q_u_e_T_y_p_e_L_i_s_t (_T_y_p_e_L_i_s_t< T... >) │ │ │ │ -  Remove duplicates from a _D_u_n_e_:_:_T_y_p_e_L_i_s_t. │ │ │ │ +template │ │ │ │ +Reference  _D_u_n_e_:_:_g_e_t (const _R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r< Reference, PropertyMap > │ │ │ │ + &pmap, const Key &key) │ │ │ │ +template │ │ │ │ + void  _D_u_n_e_:_:_p_u_t (const _R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r< Reference, PropertyMap > │ │ │ │ + &pmap, const Key &key, const Value &value) │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00041_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: typelist.hh Source File │ │ │ +dune-common: propertymap.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -71,149 +71,304 @@ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ -
typelist.hh
│ │ │ +
propertymap.hh
│ │ │
│ │ │
│ │ │ Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │
2// vi: set et ts=4 sw=2 sts=2:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ -
5#ifndef DUNE_COMMON_TYPELIST_HH
│ │ │ -
6#define DUNE_COMMON_TYPELIST_HH
│ │ │ +
5#ifndef DUNE_PROPERTYMAP_HH
│ │ │ +
6#define DUNE_PROPERTYMAP_HH
│ │ │
7
│ │ │ -
8#include <type_traits>
│ │ │ -
9#include <tuple>
│ │ │ -
10#include <utility>
│ │ │ +
8#include <cstddef>
│ │ │ +
9#include <iterator>
│ │ │ +
10#include <type_traits>
│ │ │
11
│ │ │ -
12namespace Dune {
│ │ │ -
13
│ │ │ -
32 template<class T>
│ │ │ -
│ │ │ -
33 struct MetaType {
│ │ │ -
35 using type = T;
│ │ │ -
36 };
│ │ │ -
│ │ │ -
37
│ │ │ -
86 template<class... T>
│ │ │ -
87 using TypeList = std::tuple<MetaType<T>...>;
│ │ │ -
88
│ │ │ +
12namespace Dune
│ │ │ +
13{
│ │ │ +
14
│ │ │ +
15 template<class PM>
│ │ │ +
│ │ │ + │ │ │ +
17 {
│ │ │ +
21 typedef typename PM::KeyType KeyType;
│ │ │ +
25 typedef typename PM::ValueType ValueType;
│ │ │ +
29 typedef typename PM::Reference Reference;
│ │ │ +
33 typedef typename PM::Category Category;
│ │ │ +
34 };
│ │ │ +
│ │ │ +
35
│ │ │ +
│ │ │ + │ │ │ +
38 {};
│ │ │ +
│ │ │ +
39
│ │ │ +
│ │ │ + │ │ │ +
42 {};
│ │ │ +
│ │ │ +
43
│ │ │ +
│ │ │ + │ │ │ + │ │ │ +
50 {};
│ │ │ +
│ │ │ +
51
│ │ │ +
│ │ │ + │ │ │ + │ │ │ +
57 {};
│ │ │ +
│ │ │ +
58
│ │ │ +
59 template<class T>
│ │ │ +
│ │ │ + │ │ │ +
61 {
│ │ │ +
62 typedef T ValueType;
│ │ │ + │ │ │ +
64 typedef std::ptrdiff_t KeyType;
│ │ │ + │ │ │ +
66 };
│ │ │ +
│ │ │ +
67
│ │ │ +
68
│ │ │ +
69 template<class T>
│ │ │ +
│ │ │ +
70 struct PropertyMapTraits<const T*>
│ │ │ +
71 {
│ │ │ +
72 typedef T ValueType;
│ │ │ +
73 typedef const ValueType& Reference;
│ │ │ +
74 typedef std::ptrdiff_t KeyType;
│ │ │ + │ │ │ +
76 };
│ │ │ +
│ │ │ +
77
│ │ │ +
78 template<class Reference, class PropertyMap>
│ │ │ +
│ │ │ + │ │ │ +
80 {};
│ │ │ +
│ │ │ +
81
│ │ │ +
82 template<class Reference, class PropertyMap, class Key>
│ │ │ +
83 inline Reference
│ │ │ +
│ │ │ + │ │ │ +
85 const Key& key)
│ │ │ +
86 {
│ │ │ +
87 return static_cast<const PropertyMap&>(pmap)[key];
│ │ │ +
88 }
│ │ │ +
│ │ │
89
│ │ │ -
90
│ │ │ -
99 template<class T>
│ │ │ -
100 struct IsTypeList : std::false_type {};
│ │ │ -
101
│ │ │ -
107 template<class... T>
│ │ │ -
108 struct IsTypeList<TypeList<T...> > : std::true_type {};
│ │ │ -
109
│ │ │ -
110
│ │ │ -
111
│ │ │ -
120 template<class T>
│ │ │ -
121 struct IsEmptyTypeList : std::is_same<T, TypeList<> > {};
│ │ │ -
122
│ │ │ -
123
│ │ │ -
124
│ │ │ -
125 template<class T>
│ │ │ -
126 struct TypeListSize {};
│ │ │ -
127
│ │ │ -
136 template<class... T>
│ │ │ -
137 struct TypeListSize<TypeList<T...>> : std::integral_constant<std::size_t, sizeof...(T)> {};
│ │ │ -
138
│ │ │ -
139
│ │ │ -
140
│ │ │ -
141 template<std::size_t i, class T>
│ │ │ - │ │ │ -
143
│ │ │ -
149 template<std::size_t i, class... T>
│ │ │ -
│ │ │ -
150 struct TypeListElement<i, TypeList<T...>>
│ │ │ -
151 {
│ │ │ -
157 using type = typename std::tuple_element<i, std::tuple<T...>>::type;
│ │ │ +
90 template<class Reference, class PropertyMap, class Key, class Value>
│ │ │ +
91 inline void
│ │ │ +
│ │ │ + │ │ │ +
93 const Key& key, const Value& value)
│ │ │ +
94 {
│ │ │ +
95 static_assert(std::is_convertible<typename PropertyMap::Category,WritablePropertyMapTag>::value,
│ │ │ +
96 "WritablePropertyMapTag required!");
│ │ │ +
97 static_cast<const PropertyMap&>(pmap)[key] = value;
│ │ │ +
98 }
│ │ │ +
│ │ │ +
99
│ │ │ +
103 template<class RAI, class IM,
│ │ │ +
104 class T = typename std::iterator_traits<RAI>::value_type,
│ │ │ +
105 class R = typename std::iterator_traits<RAI>::reference>
│ │ │ +
│ │ │ + │ │ │ +
107 : public RAPropertyMapHelper<R,IteratorPropertyMap<RAI,IM,T,R> >
│ │ │ +
108 {
│ │ │ +
109 public:
│ │ │ + │ │ │ +
114
│ │ │ +
120 typedef IM IndexMap;
│ │ │ +
121
│ │ │ +
125 typedef typename IndexMap::KeyType KeyType;
│ │ │ +
126
│ │ │ +
130 typedef T ValueType;
│ │ │ +
131
│ │ │ +
135 typedef R Reference;
│ │ │ +
136
│ │ │ + │ │ │ +
141
│ │ │ +
│ │ │ + │ │ │ +
150 const IndexMap& im=IndexMap())
│ │ │ +
151 : iter_(iter), indexMap_(im)
│ │ │ +
152 {}
│ │ │ +
│ │ │ +
153
│ │ │ +
│ │ │ + │ │ │ +
156 : iter_(), indexMap_()
│ │ │ +
157 {}
│ │ │ +
│ │ │
158
│ │ │ -
164 using Type = type;
│ │ │ -
165 };
│ │ │ +
│ │ │ +
160 inline Reference operator[](KeyType key) const
│ │ │ +
161 {
│ │ │ +
162 return *(iter_ + get(indexMap_, key));
│ │ │ +
163 }
│ │ │ +
│ │ │ +
164
│ │ │ +
165 private:
│ │ │ + │ │ │ +
169 IndexMap indexMap_;
│ │ │ +
170 };
│ │ │ +
│ │ │ +
171
│ │ │ +
176 template<typename T>
│ │ │ +
│ │ │ +
177 class AssociativePropertyMap
│ │ │ +
178 : RAPropertyMapHelper<typename T::value_type::second_type&,
│ │ │ +
179 AssociativePropertyMap<T> >
│ │ │ +
180 {
│ │ │ +
184 typedef T UniqueAssociativeContainer;
│ │ │ +
185
│ │ │ +
189 typedef typename UniqueAssociativeContainer::value_type::first_type
│ │ │ +
190 KeyType;
│ │ │ +
191
│ │ │ +
195 typedef typename UniqueAssociativeContainer::value_type::second_type
│ │ │ +
196 ValueType;
│ │ │ +
197
│ │ │ +
201 typedef ValueType& Reference;
│ │ │ +
202
│ │ │ +
206 typedef LvaluePropertyMapTag Category;
│ │ │ +
207
│ │ │ +
209 inline AssociativePropertyMap()
│ │ │ +
210 : map_(0)
│ │ │ +
211 {}
│ │ │ +
212
│ │ │ +
214 inline AssociativePropertyMap(UniqueAssociativeContainer& map)
│ │ │ +
215 : map_(&map)
│ │ │ +
216 {}
│ │ │ +
217
│ │ │ +
222 inline Reference operator[](KeyType key) const
│ │ │ +
223 {
│ │ │ +
224 return map_->find(key)->second;
│ │ │ +
225 }
│ │ │ +
226 private:
│ │ │ +
227 UniqueAssociativeContainer* map_;
│ │ │ +
228 };
│ │ │
│ │ │ -
166
│ │ │ -
170 template<std::size_t i, class T>
│ │ │ - │ │ │ -
172
│ │ │ -
173 namespace Impl {
│ │ │ -
174
│ │ │ -
175 template<template<class...> class Target, class ToDoList, class... Processed>
│ │ │ -
176 struct UniqueTypesHelper;
│ │ │ -
177
│ │ │ -
178 template<template<class...> class Target, class... Processed>
│ │ │ -
179 struct UniqueTypesHelper<Target, TypeList<>, Processed...>
│ │ │ -
180 {
│ │ │ -
181 using type = Target<Processed...>;
│ │ │ -
182 };
│ │ │ -
183
│ │ │ -
184 template<template<class...> class Target, class T0, class... T, class... Processed>
│ │ │ -
185 struct UniqueTypesHelper<Target, TypeList<T0, T...>, Processed...>
│ │ │ -
186 {
│ │ │ -
187 using type = std::conditional_t<
│ │ │ -
188 std::disjunction<std::is_same<T0, Processed>...>::value,
│ │ │ -
189 typename UniqueTypesHelper<Target, TypeList<T...>, Processed...>::type,
│ │ │ -
190 typename UniqueTypesHelper<Target, TypeList<T...>, T0, Processed...>::type>;
│ │ │ -
191 };
│ │ │ -
192
│ │ │ -
193 // Helper for unpacking Dune::TypeList
│ │ │ -
194 template<template<class...> class Target, class TL>
│ │ │ -
195 struct UnpackTypeList;
│ │ │ -
196
│ │ │ -
197 template<template<class...> class Target, class... T>
│ │ │ -
198 struct UnpackTypeList<Target, Dune::TypeList<T...>>
│ │ │ -
199 {
│ │ │ -
200 using type = Target<T...>;
│ │ │ -
201 };
│ │ │ -
202
│ │ │ -
203 } // namespace Impl
│ │ │ -
204
│ │ │ -
209 template<template<class...> class Target, class TL>
│ │ │ -
210 using UnpackTypeList_t = typename Impl::UnpackTypeList<Target, TL>::type;
│ │ │ -
211
│ │ │ -
219 template<template<class...> class Target, class... T>
│ │ │ -
220 using UniqueTypes_t = typename Impl::UniqueTypesHelper<Target, TypeList<T...>>::type;
│ │ │ -
221
│ │ │ -
227 template<class NonUniqueTypeList>
│ │ │ -
228 using UniqueTypeList_t = typename Impl::UniqueTypesHelper<TypeList, NonUniqueTypeList>::type;
│ │ │
229
│ │ │ -
235 template<class... T>
│ │ │ -
│ │ │ -
236 constexpr auto uniqueTypeList(TypeList<T...> /*list*/)
│ │ │ -
237 {
│ │ │ -
238 return typename Impl::UniqueTypesHelper<TypeList, TypeList<T...>>::type{};
│ │ │ -
239 }
│ │ │ -
│ │ │ -
240
│ │ │ -
241
│ │ │ -
242
│ │ │ -
243} // namespace Dune
│ │ │ -
244
│ │ │ -
245#endif // DUNE_COMMON_TYPELIST_HH
│ │ │ -
std::tuple< MetaType< T >... > TypeList
A simple type list.
Definition typelist.hh:87
│ │ │ +
234 template<typename T>
│ │ │ +
│ │ │ +
235 class ConstAssociativePropertyMap
│ │ │ +
236 : RAPropertyMapHelper<const typename T::value_type::second_type&,
│ │ │ +
237 ConstAssociativePropertyMap<T> >
│ │ │ +
238 {
│ │ │ +
242 typedef T UniqueAssociativeContainer;
│ │ │ +
243
│ │ │ +
247 typedef typename UniqueAssociativeContainer::value_type::first_type
│ │ │ +
248 KeyType;
│ │ │ +
249
│ │ │ +
253 typedef typename UniqueAssociativeContainer::value_type::second_type
│ │ │ +
254 ValueType;
│ │ │ +
255
│ │ │ +
259 typedef const ValueType& Reference;
│ │ │ +
260
│ │ │ +
264 typedef LvaluePropertyMapTag Category;
│ │ │ +
265
│ │ │ +
267 inline ConstAssociativePropertyMap()
│ │ │ +
268 : map_(0)
│ │ │ +
269 {}
│ │ │ +
270
│ │ │ +
272 inline ConstAssociativePropertyMap(const UniqueAssociativeContainer& map)
│ │ │ +
273 : map_(&map)
│ │ │ +
274 {}
│ │ │ +
275
│ │ │ +
280 inline Reference operator[](KeyType key) const
│ │ │ +
281 {
│ │ │ +
282 return map_->find(key)->second;
│ │ │ +
283 }
│ │ │ +
284 private:
│ │ │ +
285 const UniqueAssociativeContainer* map_;
│ │ │ +
286 };
│ │ │ +
│ │ │ +
287
│ │ │ +
│ │ │ + │ │ │ +
292 : public RAPropertyMapHelper<std::size_t, IdentityMap>
│ │ │ +
293 {
│ │ │ +
295 typedef std::size_t KeyType;
│ │ │ +
296
│ │ │ +
298 typedef std::size_t ValueType;
│ │ │ +
299
│ │ │ +
301 typedef std::size_t Reference;
│ │ │ +
302
│ │ │ + │ │ │ +
305
│ │ │ +
│ │ │ +
306 inline ValueType operator[](const KeyType& key) const
│ │ │ +
307 {
│ │ │ +
308 return key;
│ │ │ +
309 }
│ │ │ +
│ │ │ +
310 };
│ │ │ +
│ │ │ +
311
│ │ │ +
312
│ │ │ +
318 template<typename T, typename C>
│ │ │ +
│ │ │ + │ │ │ +
320 {
│ │ │ +
324 typedef T Tag;
│ │ │ +
329 typedef C Container;
│ │ │ +
330 };
│ │ │ +
│ │ │ +
331
│ │ │ +
332}
│ │ │ +
333
│ │ │ +
334#endif
│ │ │
Dune namespace
Definition alignedallocator.hh:13
│ │ │ -
constexpr auto uniqueTypeList(TypeList< T... >)
Remove duplicates from a Dune::TypeList.
Definition typelist.hh:236
│ │ │ -
typename Impl::UniqueTypesHelper< TypeList, NonUniqueTypeList >::type UniqueTypeList_t
Remove duplicates from a Dune::TypeList.
Definition typelist.hh:228
│ │ │ -
typename Impl::UniqueTypesHelper< Target, TypeList< T... > >::type UniqueTypes_t
Remove duplicates from a list of types.
Definition typelist.hh:220
│ │ │ -
typename Impl::UnpackTypeList< Target, TL >::type UnpackTypeList_t
Unpack Dune::TypeList.
Definition typelist.hh:210
│ │ │ -
typename TypeListElement< i, T >::type TypeListEntry_t
Shortcut for TypeListElement<i, T>::type;.
Definition typelist.hh:171
│ │ │ - │ │ │ -
A type that refers to another type.
Definition typelist.hh:33
│ │ │ -
T type
The referred-to type.
Definition typelist.hh:35
│ │ │ -
Check if given type is a TypeList.
Definition typelist.hh:100
│ │ │ -
Check if given type is an empty TypeList.
Definition typelist.hh:121
│ │ │ -
Definition typelist.hh:126
│ │ │ -
Definition typelist.hh:142
│ │ │ -
typename std::tuple_element< i, std::tuple< T... > >::type type
Export type of i-th element in TypeList.
Definition typelist.hh:157
│ │ │ -
type Type
Export type of i-th element in TypeList.
Definition typelist.hh:164
│ │ │ +
void put(const RAPropertyMapHelper< Reference, PropertyMap > &pmap, const Key &key, const Value &value)
Definition propertymap.hh:92
│ │ │ +
constexpr auto get(std::integer_sequence< T, II... >, std::integral_constant< std::size_t, pos >={})
Return the entry at position pos of the given sequence.
Definition integersequence.hh:22
│ │ │ +
Definition propertymap.hh:17
│ │ │ +
PM::ValueType ValueType
The type of the values of the property map.
Definition propertymap.hh:25
│ │ │ +
PM::Category Category
The category the property map belongs to.
Definition propertymap.hh:33
│ │ │ +
PM::Reference Reference
The type of the reference to the values.
Definition propertymap.hh:29
│ │ │ +
PM::KeyType KeyType
The type of the key of the property map.
Definition propertymap.hh:21
│ │ │ +
Tag for the category of readable property maps.
Definition propertymap.hh:38
│ │ │ +
Tag for the category of writable property maps.
Definition propertymap.hh:42
│ │ │ +
Tag for the category of readable and writable property maps.
Definition propertymap.hh:50
│ │ │ +
Tag for the category of lvalue property maps.
Definition propertymap.hh:57
│ │ │ +
ValueType & Reference
Definition propertymap.hh:63
│ │ │ +
std::ptrdiff_t KeyType
Definition propertymap.hh:64
│ │ │ +
T ValueType
Definition propertymap.hh:62
│ │ │ +
LvaluePropertyMapTag Category
Definition propertymap.hh:65
│ │ │ +
std::ptrdiff_t KeyType
Definition propertymap.hh:74
│ │ │ +
const ValueType & Reference
Definition propertymap.hh:73
│ │ │ +
T ValueType
Definition propertymap.hh:72
│ │ │ +
LvaluePropertyMapTag Category
Definition propertymap.hh:75
│ │ │ +
Definition propertymap.hh:80
│ │ │ +
IndexMap::KeyType KeyType
The key type of the property map.
Definition propertymap.hh:125
│ │ │ +
R Reference
The reference type of the property map.
Definition propertymap.hh:135
│ │ │ +
T ValueType
The value type of the property map.
Definition propertymap.hh:130
│ │ │ +
Reference operator[](KeyType key) const
Access the a value by reference.
Definition propertymap.hh:160
│ │ │ +
IteratorPropertyMap(RandomAccessIterator iter, const IndexMap &im=IndexMap())
Constructor.
Definition propertymap.hh:149
│ │ │ +
IteratorPropertyMap()
Constructor.
Definition propertymap.hh:155
│ │ │ +
IM IndexMap
The type of the index map.
Definition propertymap.hh:120
│ │ │ +
RAI RandomAccessIterator
The type of the random access iterator.
Definition propertymap.hh:113
│ │ │ +
LvaluePropertyMapTag Category
The category of this property map.
Definition propertymap.hh:140
│ │ │ +
A property map that applies the identity function to integers.
Definition propertymap.hh:293
│ │ │ +
std::size_t ValueType
The value type of the map.
Definition propertymap.hh:298
│ │ │ +
std::size_t KeyType
The key type of the map.
Definition propertymap.hh:295
│ │ │ +
ValueType operator[](const KeyType &key) const
Definition propertymap.hh:306
│ │ │ +
std::size_t Reference
The reference type of the map.
Definition propertymap.hh:301
│ │ │ +
ReadablePropertyMapTag Category
The category of the map.
Definition propertymap.hh:304
│ │ │ +
Selector for the property map type.
Definition propertymap.hh:320
│ │ │ +
T Tag
the tag identifying the property.
Definition propertymap.hh:324
│ │ │ +
C Container
The container type to whose entries the properties are attached.
Definition propertymap.hh:329
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,182 +1,359 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -typelist.hh │ │ │ │ +propertymap.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ 1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ 2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ 4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ -5#ifndef DUNE_COMMON_TYPELIST_HH │ │ │ │ -6#define DUNE_COMMON_TYPELIST_HH │ │ │ │ +5#ifndef DUNE_PROPERTYMAP_HH │ │ │ │ +6#define DUNE_PROPERTYMAP_HH │ │ │ │ 7 │ │ │ │ -8#include │ │ │ │ -9#include │ │ │ │ -10#include │ │ │ │ +8#include │ │ │ │ +9#include │ │ │ │ +10#include │ │ │ │ 11 │ │ │ │ -12namespace _D_u_n_e { │ │ │ │ -13 │ │ │ │ -32 template │ │ │ │ -_3_3 struct _M_e_t_a_T_y_p_e { │ │ │ │ -_3_5 using _t_y_p_e = T; │ │ │ │ -36 }; │ │ │ │ -37 │ │ │ │ -86 template │ │ │ │ -_8_7 using _T_y_p_e_L_i_s_t = std::tuple...>; │ │ │ │ -88 │ │ │ │ +12namespace _D_u_n_e │ │ │ │ +13{ │ │ │ │ +14 │ │ │ │ +15 template │ │ │ │ +_1_6 struct _P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s │ │ │ │ +17 { │ │ │ │ +_2_1 typedef typename PM::KeyType _K_e_y_T_y_p_e; │ │ │ │ +_2_5 typedef typename PM::ValueType _V_a_l_u_e_T_y_p_e; │ │ │ │ +_2_9 typedef typename PM::Reference _R_e_f_e_r_e_n_c_e; │ │ │ │ +_3_3 typedef typename PM::Category _C_a_t_e_g_o_r_y; │ │ │ │ +34 }; │ │ │ │ +35 │ │ │ │ +_3_7 struct _R_e_a_d_a_b_l_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +38 {}; │ │ │ │ +39 │ │ │ │ +_4_1 struct _W_r_i_t_a_b_l_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +42 {}; │ │ │ │ +43 │ │ │ │ +_4_8 struct _R_e_a_d_W_r_i_t_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +49 : public _R_e_a_d_a_b_l_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g, public _W_r_i_t_a_b_l_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +50 {}; │ │ │ │ +51 │ │ │ │ +_5_5 struct _L_v_a_l_u_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +56 : public _R_e_a_d_W_r_i_t_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +57 {}; │ │ │ │ +58 │ │ │ │ +59 template │ │ │ │ +_6_0 struct _P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s │ │ │ │ +61 { │ │ │ │ +_6_2 typedef T _V_a_l_u_e_T_y_p_e; │ │ │ │ +_6_3 typedef _V_a_l_u_e_T_y_p_e& _R_e_f_e_r_e_n_c_e; │ │ │ │ +_6_4 typedef std::ptrdiff_t _K_e_y_T_y_p_e; │ │ │ │ +_6_5 typedef _L_v_a_l_u_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g _C_a_t_e_g_o_r_y; │ │ │ │ +66 }; │ │ │ │ +67 │ │ │ │ +68 │ │ │ │ +69 template │ │ │ │ +_7_0 struct _P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s │ │ │ │ +71 { │ │ │ │ +_7_2 typedef T _V_a_l_u_e_T_y_p_e; │ │ │ │ +_7_3 typedef const _V_a_l_u_e_T_y_p_e& _R_e_f_e_r_e_n_c_e; │ │ │ │ +_7_4 typedef std::ptrdiff_t _K_e_y_T_y_p_e; │ │ │ │ +_7_5 typedef _L_v_a_l_u_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g _C_a_t_e_g_o_r_y; │ │ │ │ +76 }; │ │ │ │ +77 │ │ │ │ +78 template │ │ │ │ +_7_9 struct _R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r │ │ │ │ +80 {}; │ │ │ │ +81 │ │ │ │ +82 template │ │ │ │ +83 inline Reference │ │ │ │ +_8_4 _g_e_t(const _R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r_<_R_e_f_e_r_e_n_c_e_,_P_r_o_p_e_r_t_y_M_a_p_>& pmap, │ │ │ │ +85 const Key& key) │ │ │ │ +86 { │ │ │ │ +87 return static_cast(pmap)[key]; │ │ │ │ +88 } │ │ │ │ 89 │ │ │ │ -90 │ │ │ │ -99 template │ │ │ │ -_1_0_0 struct _I_s_T_y_p_e_L_i_s_t : std::false_type {}; │ │ │ │ -101 │ │ │ │ -107 template │ │ │ │ -_1_0_8 struct _I_s_T_y_p_e_L_i_s_t<_T_y_p_e_L_i_s_t > : std::true_type {}; │ │ │ │ -109 │ │ │ │ -110 │ │ │ │ -111 │ │ │ │ -120 template │ │ │ │ -_1_2_1 struct _I_s_E_m_p_t_y_T_y_p_e_L_i_s_t : std::is_same > {}; │ │ │ │ -122 │ │ │ │ -123 │ │ │ │ -124 │ │ │ │ -125 template │ │ │ │ -_1_2_6 struct _T_y_p_e_L_i_s_t_S_i_z_e {}; │ │ │ │ -127 │ │ │ │ -136 template │ │ │ │ -_1_3_7 struct _T_y_p_e_L_i_s_t_S_i_z_e<_T_y_p_e_L_i_s_t> : std::integral_constant {}; │ │ │ │ -138 │ │ │ │ -139 │ │ │ │ -140 │ │ │ │ -141 template │ │ │ │ -_1_4_2 struct _T_y_p_e_L_i_s_t_E_l_e_m_e_n_t {}; │ │ │ │ -143 │ │ │ │ -149 template │ │ │ │ -_1_5_0 struct _T_y_p_e_L_i_s_t_E_l_e_m_e_n_t> │ │ │ │ -151 { │ │ │ │ -_1_5_7 using _t_y_p_e = typename std::tuple_element>_:_:_t_y_p_e; │ │ │ │ +90 template │ │ │ │ +91 inline void │ │ │ │ +_9_2 _p_u_t(const _R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r_<_R_e_f_e_r_e_n_c_e_,_P_r_o_p_e_r_t_y_M_a_p_>& pmap, │ │ │ │ +93 const Key& key, const Value& value) │ │ │ │ +94 { │ │ │ │ +95 static_assert(std::is_convertible::value, │ │ │ │ +96 "WritablePropertyMapTag required!"); │ │ │ │ +97 static_cast(pmap)[key] = value; │ │ │ │ +98 } │ │ │ │ +99 │ │ │ │ +103 template::value_type, │ │ │ │ +105 class R = typename std::iterator_traits::reference> │ │ │ │ +_1_0_6 class _I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p │ │ │ │ +107 : public _R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r > │ │ │ │ +108 { │ │ │ │ +109 public: │ │ │ │ +_1_1_3 typedef RAI _R_a_n_d_o_m_A_c_c_e_s_s_I_t_e_r_a_t_o_r; │ │ │ │ +114 │ │ │ │ +_1_2_0 typedef IM _I_n_d_e_x_M_a_p; │ │ │ │ +121 │ │ │ │ +_1_2_5 typedef typename IndexMap::KeyType _K_e_y_T_y_p_e; │ │ │ │ +126 │ │ │ │ +_1_3_0 typedef T _V_a_l_u_e_T_y_p_e; │ │ │ │ +131 │ │ │ │ +_1_3_5 typedef R _R_e_f_e_r_e_n_c_e; │ │ │ │ +136 │ │ │ │ +_1_4_0 typedef _L_v_a_l_u_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g _C_a_t_e_g_o_r_y; │ │ │ │ +141 │ │ │ │ +_1_4_9 inline _I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p(_R_a_n_d_o_m_A_c_c_e_s_s_I_t_e_r_a_t_o_r iter, │ │ │ │ +150 const _I_n_d_e_x_M_a_p& im=_I_n_d_e_x_M_a_p()) │ │ │ │ +151 : iter_(iter), indexMap_(im) │ │ │ │ +152 {} │ │ │ │ +153 │ │ │ │ +_1_5_5 inline _I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p() │ │ │ │ +156 : iter_(), indexMap_() │ │ │ │ +157 {} │ │ │ │ 158 │ │ │ │ -_1_6_4 using _T_y_p_e = _t_y_p_e; │ │ │ │ -165 }; │ │ │ │ -166 │ │ │ │ -170 template │ │ │ │ -_1_7_1 using _T_y_p_e_L_i_s_t_E_n_t_r_y___t = typename _T_y_p_e_L_i_s_t_E_l_e_m_e_n_t_<_i_,_ _T_>_:_:_t_y_p_e; │ │ │ │ -172 │ │ │ │ -173 namespace Impl { │ │ │ │ -174 │ │ │ │ -175 template class Target, class ToDoList, class... │ │ │ │ -Processed> │ │ │ │ -176 struct UniqueTypesHelper; │ │ │ │ -177 │ │ │ │ -178 template class Target, class... Processed> │ │ │ │ -179 struct UniqueTypesHelper, Processed...> │ │ │ │ +_1_6_0 inline _R_e_f_e_r_e_n_c_e _o_p_e_r_a_t_o_r_[_](_K_e_y_T_y_p_e key) const │ │ │ │ +161 { │ │ │ │ +162 return *(iter_ + _g_e_t(indexMap_, key)); │ │ │ │ +163 } │ │ │ │ +164 │ │ │ │ +165 private: │ │ │ │ +167 _R_a_n_d_o_m_A_c_c_e_s_s_I_t_e_r_a_t_o_r iter_; │ │ │ │ +169 _I_n_d_e_x_M_a_p indexMap_; │ │ │ │ +170 }; │ │ │ │ +171 │ │ │ │ +176 template │ │ │ │ +_1_7_7 class AssociativePropertyMap │ │ │ │ +178 : _R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r > │ │ │ │ 180 { │ │ │ │ -181 using _t_y_p_e = Target; │ │ │ │ -182 }; │ │ │ │ -183 │ │ │ │ -184 template class Target, class T0, class... T, class... │ │ │ │ -Processed> │ │ │ │ -185 struct UniqueTypesHelper, Processed...> │ │ │ │ -186 { │ │ │ │ -187 using _t_y_p_e = std::conditional_t< │ │ │ │ -188 std::disjunction...>::value, │ │ │ │ -189 typename UniqueTypesHelper, Processed...>_:_:_t_y_p_e, │ │ │ │ -190 typename UniqueTypesHelper, T0, Processed...>_:_: │ │ │ │ -_t_y_p_e>; │ │ │ │ -191 }; │ │ │ │ -192 │ │ │ │ -193 // Helper for unpacking Dune::TypeList │ │ │ │ -194 template class Target, class TL> │ │ │ │ -195 struct UnpackTypeList; │ │ │ │ -196 │ │ │ │ -197 template class Target, class... T> │ │ │ │ -198 struct UnpackTypeList> │ │ │ │ -199 { │ │ │ │ -200 using _t_y_p_e = Target; │ │ │ │ -201 }; │ │ │ │ +184 typedef T UniqueAssociativeContainer; │ │ │ │ +185 │ │ │ │ +189 typedef typename UniqueAssociativeContainer::value_type::first_type │ │ │ │ +190 KeyType; │ │ │ │ +191 │ │ │ │ +195 typedef typename UniqueAssociativeContainer::value_type::second_type │ │ │ │ +196 ValueType; │ │ │ │ +197 │ │ │ │ +201 typedef ValueType& Reference; │ │ │ │ 202 │ │ │ │ -203 } // namespace Impl │ │ │ │ -204 │ │ │ │ -209 template class Target, class TL> │ │ │ │ -_2_1_0 using _U_n_p_a_c_k_T_y_p_e_L_i_s_t___t = typename Impl::UnpackTypeList::type; │ │ │ │ -211 │ │ │ │ -219 template class Target, class... T> │ │ │ │ -_2_2_0 using _U_n_i_q_u_e_T_y_p_e_s___t = typename Impl::UniqueTypesHelper>_:_:_t_y_p_e; │ │ │ │ -221 │ │ │ │ -227 template │ │ │ │ -_2_2_8 using _U_n_i_q_u_e_T_y_p_e_L_i_s_t___t = typename Impl::UniqueTypesHelper::type; │ │ │ │ +206 typedef _L_v_a_l_u_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g Category; │ │ │ │ +207 │ │ │ │ +209 inline AssociativePropertyMap() │ │ │ │ +210 : map_(0) │ │ │ │ +211 {} │ │ │ │ +212 │ │ │ │ +214 inline AssociativePropertyMap(UniqueAssociativeContainer& map) │ │ │ │ +215 : map_(&map) │ │ │ │ +216 {} │ │ │ │ +217 │ │ │ │ +222 inline Reference operator[](KeyType key) const │ │ │ │ +223 { │ │ │ │ +224 return map_->find(key)->second; │ │ │ │ +225 } │ │ │ │ +226 private: │ │ │ │ +227 UniqueAssociativeContainer* map_; │ │ │ │ +228 }; │ │ │ │ 229 │ │ │ │ -235 template │ │ │ │ -_2_3_6 constexpr auto _u_n_i_q_u_e_T_y_p_e_L_i_s_t(_T_y_p_e_L_i_s_t_<_T_._._._> /*list*/) │ │ │ │ -237 { │ │ │ │ -238 return typename Impl::UniqueTypesHelper<_T_y_p_e_L_i_s_t, _T_y_p_e_L_i_s_t>_:_:_t_y_p_e{}; │ │ │ │ -239 } │ │ │ │ -240 │ │ │ │ -241 │ │ │ │ -242 │ │ │ │ -243} // namespace Dune │ │ │ │ -244 │ │ │ │ -245#endif // DUNE_COMMON_TYPELIST_HH │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_L_i_s_t │ │ │ │ -std::tuple< MetaType< T >... > TypeList │ │ │ │ -A simple type list. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:87 │ │ │ │ +234 template │ │ │ │ +_2_3_5 class ConstAssociativePropertyMap │ │ │ │ +236 : _R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r > │ │ │ │ +238 { │ │ │ │ +242 typedef T UniqueAssociativeContainer; │ │ │ │ +243 │ │ │ │ +247 typedef typename UniqueAssociativeContainer::value_type::first_type │ │ │ │ +248 KeyType; │ │ │ │ +249 │ │ │ │ +253 typedef typename UniqueAssociativeContainer::value_type::second_type │ │ │ │ +254 ValueType; │ │ │ │ +255 │ │ │ │ +259 typedef const ValueType& Reference; │ │ │ │ +260 │ │ │ │ +264 typedef _L_v_a_l_u_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g Category; │ │ │ │ +265 │ │ │ │ +267 inline ConstAssociativePropertyMap() │ │ │ │ +268 : map_(0) │ │ │ │ +269 {} │ │ │ │ +270 │ │ │ │ +272 inline ConstAssociativePropertyMap(const UniqueAssociativeContainer& map) │ │ │ │ +273 : map_(&map) │ │ │ │ +274 {} │ │ │ │ +275 │ │ │ │ +280 inline Reference operator[](KeyType key) const │ │ │ │ +281 { │ │ │ │ +282 return map_->find(key)->second; │ │ │ │ +283 } │ │ │ │ +284 private: │ │ │ │ +285 const UniqueAssociativeContainer* map_; │ │ │ │ +286 }; │ │ │ │ +287 │ │ │ │ +_2_9_1 struct _I_d_e_n_t_i_t_y_M_a_p │ │ │ │ +292 : public _R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r │ │ │ │ +293 { │ │ │ │ +_2_9_5 typedef std::size_t _K_e_y_T_y_p_e; │ │ │ │ +296 │ │ │ │ +_2_9_8 typedef std::size_t _V_a_l_u_e_T_y_p_e; │ │ │ │ +299 │ │ │ │ +_3_0_1 typedef std::size_t _R_e_f_e_r_e_n_c_e; │ │ │ │ +302 │ │ │ │ +_3_0_4 typedef _R_e_a_d_a_b_l_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g _C_a_t_e_g_o_r_y; │ │ │ │ +305 │ │ │ │ +_3_0_6 inline _V_a_l_u_e_T_y_p_e _o_p_e_r_a_t_o_r_[_](const _K_e_y_T_y_p_e& key) const │ │ │ │ +307 { │ │ │ │ +308 return key; │ │ │ │ +309 } │ │ │ │ +310 }; │ │ │ │ +311 │ │ │ │ +312 │ │ │ │ +318 template │ │ │ │ +_3_1_9 struct _P_r_o_p_e_r_t_y_M_a_p_T_y_p_e_S_e_l_e_c_t_o_r │ │ │ │ +320 { │ │ │ │ +_3_2_4 typedef T _T_a_g; │ │ │ │ +_3_2_9 typedef C _C_o_n_t_a_i_n_e_r; │ │ │ │ +330 }; │ │ │ │ +331 │ │ │ │ +332} │ │ │ │ +333 │ │ │ │ +334#endif │ │ │ │ _D_u_n_e │ │ │ │ Dune namespace │ │ │ │ DDeeffiinniittiioonn alignedallocator.hh:13 │ │ │ │ -_D_u_n_e_:_:_u_n_i_q_u_e_T_y_p_e_L_i_s_t │ │ │ │ -constexpr auto uniqueTypeList(TypeList< T... >) │ │ │ │ -Remove duplicates from a Dune::TypeList. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:236 │ │ │ │ -_D_u_n_e_:_:_U_n_i_q_u_e_T_y_p_e_L_i_s_t___t │ │ │ │ -typename Impl::UniqueTypesHelper< TypeList, NonUniqueTypeList >::type │ │ │ │ -UniqueTypeList_t │ │ │ │ -Remove duplicates from a Dune::TypeList. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:228 │ │ │ │ -_D_u_n_e_:_:_U_n_i_q_u_e_T_y_p_e_s___t │ │ │ │ -typename Impl::UniqueTypesHelper< Target, TypeList< T... > >::type │ │ │ │ -UniqueTypes_t │ │ │ │ -Remove duplicates from a list of types. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:220 │ │ │ │ -_D_u_n_e_:_:_U_n_p_a_c_k_T_y_p_e_L_i_s_t___t │ │ │ │ -typename Impl::UnpackTypeList< Target, TL >::type UnpackTypeList_t │ │ │ │ -Unpack Dune::TypeList. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:210 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_L_i_s_t_E_n_t_r_y___t │ │ │ │ -typename TypeListElement< i, T >::type TypeListEntry_t │ │ │ │ -Shortcut for TypeListElement::type;. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:171 │ │ │ │ -_D_u_n_e_:_:_t_y_p_e │ │ │ │ -_D_u_n_e_:_:_M_e_t_a_T_y_p_e │ │ │ │ -A type that refers to another type. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:33 │ │ │ │ -_D_u_n_e_:_:_M_e_t_a_T_y_p_e_:_:_t_y_p_e │ │ │ │ -T type │ │ │ │ -The referred-to type. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:35 │ │ │ │ -_D_u_n_e_:_:_I_s_T_y_p_e_L_i_s_t │ │ │ │ -Check if given type is a TypeList. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:100 │ │ │ │ -_D_u_n_e_:_:_I_s_E_m_p_t_y_T_y_p_e_L_i_s_t │ │ │ │ -Check if given type is an empty TypeList. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:121 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_L_i_s_t_S_i_z_e │ │ │ │ -DDeeffiinniittiioonn typelist.hh:126 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_L_i_s_t_E_l_e_m_e_n_t │ │ │ │ -DDeeffiinniittiioonn typelist.hh:142 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_L_i_s_t_E_l_e_m_e_n_t_<_ _i_,_ _T_y_p_e_L_i_s_t_<_ _T_._._._ _>_ _>_:_:_t_y_p_e │ │ │ │ -typename std::tuple_element< i, std::tuple< T... > >::type type │ │ │ │ -Export type of i-th element in TypeList. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:157 │ │ │ │ -_D_u_n_e_:_:_T_y_p_e_L_i_s_t_E_l_e_m_e_n_t_<_ _i_,_ _T_y_p_e_L_i_s_t_<_ _T_._._._ _>_ _>_:_:_T_y_p_e │ │ │ │ -type Type │ │ │ │ -Export type of i-th element in TypeList. │ │ │ │ -DDeeffiinniittiioonn typelist.hh:164 │ │ │ │ +_D_u_n_e_:_:_p_u_t │ │ │ │ +void put(const RAPropertyMapHelper< Reference, PropertyMap > &pmap, const Key │ │ │ │ +&key, const Value &value) │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:92 │ │ │ │ +_D_u_n_e_:_:_g_e_t │ │ │ │ +constexpr auto get(std::integer_sequence< T, II... >, std::integral_constant< │ │ │ │ +std::size_t, pos >={}) │ │ │ │ +Return the entry at position pos of the given sequence. │ │ │ │ +DDeeffiinniittiioonn integersequence.hh:22 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:17 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_:_:_V_a_l_u_e_T_y_p_e │ │ │ │ +PM::ValueType ValueType │ │ │ │ +The type of the values of the property map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:25 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_:_:_C_a_t_e_g_o_r_y │ │ │ │ +PM::Category Category │ │ │ │ +The category the property map belongs to. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:33 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_:_:_R_e_f_e_r_e_n_c_e │ │ │ │ +PM::Reference Reference │ │ │ │ +The type of the reference to the values. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:29 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_:_:_K_e_y_T_y_p_e │ │ │ │ +PM::KeyType KeyType │ │ │ │ +The type of the key of the property map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:21 │ │ │ │ +_D_u_n_e_:_:_R_e_a_d_a_b_l_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +Tag for the category of readable property maps. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:38 │ │ │ │ +_D_u_n_e_:_:_W_r_i_t_a_b_l_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +Tag for the category of writable property maps. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:42 │ │ │ │ +_D_u_n_e_:_:_R_e_a_d_W_r_i_t_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +Tag for the category of readable and writable property maps. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:50 │ │ │ │ +_D_u_n_e_:_:_L_v_a_l_u_e_P_r_o_p_e_r_t_y_M_a_p_T_a_g │ │ │ │ +Tag for the category of lvalue property maps. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:57 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _T_ _*_ _>_:_:_R_e_f_e_r_e_n_c_e │ │ │ │ +ValueType & Reference │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:63 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _T_ _*_ _>_:_:_K_e_y_T_y_p_e │ │ │ │ +std::ptrdiff_t KeyType │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:64 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _T_ _*_ _>_:_:_V_a_l_u_e_T_y_p_e │ │ │ │ +T ValueType │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:62 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _T_ _*_ _>_:_:_C_a_t_e_g_o_r_y │ │ │ │ +LvaluePropertyMapTag Category │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:65 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _c_o_n_s_t_ _T_ _*_ _>_:_:_K_e_y_T_y_p_e │ │ │ │ +std::ptrdiff_t KeyType │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:74 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _c_o_n_s_t_ _T_ _*_ _>_:_:_R_e_f_e_r_e_n_c_e │ │ │ │ +const ValueType & Reference │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:73 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _c_o_n_s_t_ _T_ _*_ _>_:_:_V_a_l_u_e_T_y_p_e │ │ │ │ +T ValueType │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:72 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_r_a_i_t_s_<_ _c_o_n_s_t_ _T_ _*_ _>_:_:_C_a_t_e_g_o_r_y │ │ │ │ +LvaluePropertyMapTag Category │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:75 │ │ │ │ +_D_u_n_e_:_:_R_A_P_r_o_p_e_r_t_y_M_a_p_H_e_l_p_e_r │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:80 │ │ │ │ +_D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_:_:_K_e_y_T_y_p_e │ │ │ │ +IndexMap::KeyType KeyType │ │ │ │ +The key type of the property map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:125 │ │ │ │ +_D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_:_:_R_e_f_e_r_e_n_c_e │ │ │ │ +R Reference │ │ │ │ +The reference type of the property map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:135 │ │ │ │ +_D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_:_:_V_a_l_u_e_T_y_p_e │ │ │ │ +T ValueType │ │ │ │ +The value type of the property map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:130 │ │ │ │ +_D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ +Reference operator[](KeyType key) const │ │ │ │ +Access the a value by reference. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:160 │ │ │ │ +_D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p │ │ │ │ +IteratorPropertyMap(RandomAccessIterator iter, const IndexMap &im=IndexMap()) │ │ │ │ +Constructor. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:149 │ │ │ │ +_D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p │ │ │ │ +IteratorPropertyMap() │ │ │ │ +Constructor. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:155 │ │ │ │ +_D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_:_:_I_n_d_e_x_M_a_p │ │ │ │ +IM IndexMap │ │ │ │ +The type of the index map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:120 │ │ │ │ +_D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_:_:_R_a_n_d_o_m_A_c_c_e_s_s_I_t_e_r_a_t_o_r │ │ │ │ +RAI RandomAccessIterator │ │ │ │ +The type of the random access iterator. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:113 │ │ │ │ +_D_u_n_e_:_:_I_t_e_r_a_t_o_r_P_r_o_p_e_r_t_y_M_a_p_:_:_C_a_t_e_g_o_r_y │ │ │ │ +LvaluePropertyMapTag Category │ │ │ │ +The category of this property map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:140 │ │ │ │ +_D_u_n_e_:_:_I_d_e_n_t_i_t_y_M_a_p │ │ │ │ +A property map that applies the identity function to integers. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:293 │ │ │ │ +_D_u_n_e_:_:_I_d_e_n_t_i_t_y_M_a_p_:_:_V_a_l_u_e_T_y_p_e │ │ │ │ +std::size_t ValueType │ │ │ │ +The value type of the map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:298 │ │ │ │ +_D_u_n_e_:_:_I_d_e_n_t_i_t_y_M_a_p_:_:_K_e_y_T_y_p_e │ │ │ │ +std::size_t KeyType │ │ │ │ +The key type of the map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:295 │ │ │ │ +_D_u_n_e_:_:_I_d_e_n_t_i_t_y_M_a_p_:_:_o_p_e_r_a_t_o_r_[_] │ │ │ │ +ValueType operator[](const KeyType &key) const │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:306 │ │ │ │ +_D_u_n_e_:_:_I_d_e_n_t_i_t_y_M_a_p_:_:_R_e_f_e_r_e_n_c_e │ │ │ │ +std::size_t Reference │ │ │ │ +The reference type of the map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:301 │ │ │ │ +_D_u_n_e_:_:_I_d_e_n_t_i_t_y_M_a_p_:_:_C_a_t_e_g_o_r_y │ │ │ │ +ReadablePropertyMapTag Category │ │ │ │ +The category of the map. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:304 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_y_p_e_S_e_l_e_c_t_o_r │ │ │ │ +Selector for the property map type. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:320 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_y_p_e_S_e_l_e_c_t_o_r_:_:_T_a_g │ │ │ │ +T Tag │ │ │ │ +the tag identifying the property. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:324 │ │ │ │ +_D_u_n_e_:_:_P_r_o_p_e_r_t_y_M_a_p_T_y_p_e_S_e_l_e_c_t_o_r_:_:_C_o_n_t_a_i_n_e_r │ │ │ │ +C Container │ │ │ │ +The container type to whose entries the properties are attached. │ │ │ │ +DDeeffiinniittiioonn propertymap.hh:329 │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00044.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: tuplevector.hh File Reference │ │ │ +dune-common: stdstreams.cc File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -72,56 +72,43 @@ │ │ │ │ │ │
│ │ │ │ │ │
│ │ │
│ │ │
│ │ │ -Classes | │ │ │ Namespaces | │ │ │ -Functions
│ │ │ -
tuplevector.hh File Reference
│ │ │ +Variables
│ │ │ +
stdstreams.cc File Reference
│ │ │
│ │ │
│ │ │ - │ │ │ -

Provides the TupleVector class that augments std::tuple by operator[]. │ │ │ -More...

│ │ │ -
#include <tuple>
│ │ │ -#include <utility>
│ │ │ -#include <dune/common/indices.hh>
│ │ │ -#include <dune/common/typetraits.hh>
│ │ │ -#include <dune/common/std/type_traits.hh>
│ │ │ -
│ │ │ -

Go to the source code of this file.

│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -

│ │ │ -Classes

class  Dune::TupleVector< T >
 A class augmenting std::tuple by element access via operator[]. More...
struct  std::tuple_element< i, Dune::TupleVector< Args... > >
 Make std::tuple_element work for TupleVector. More...
struct  std::tuple_size< Dune::TupleVector< Args... > >
 Make std::tuple_size work for TupleVector. More...
│ │ │ +
#include <iostream>
│ │ │ +#include "stdstreams.hh"
│ │ │ +
│ │ │ │ │ │ │ │ │ │ │ │ - │ │ │ - │ │ │

│ │ │ Namespaces

namespace  Dune
 Dune namespace
namespace  std
 STL namespace.
│ │ │ - │ │ │ - │ │ │ - │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │ + │ │ │

│ │ │ -Functions

template<class... T>
constexpr auto Dune::makeTupleVector (T &&... t)

│ │ │ +Variables

DVVerbType Dune::dvverb (std::cout)
 stream for very verbose output.
DVerbType Dune::dverb (std::cout)
 Singleton of verbose debug stream.
DInfoType Dune::dinfo (std::cout)
 Stream for informative output.
DWarnType Dune::dwarn (std::cerr)
 Stream for warnings indicating problems.
DGraveType Dune::dgrave (std::cerr)
 Stream for warnings indicating fatal errors.
DErrType Dune::derr (std::cerr)
 Stream for error messages.
│ │ │ -

Detailed Description

│ │ │ -

Provides the TupleVector class that augments std::tuple by operator[].

│ │ │ -
Author
Carsten Gräser
│ │ │ -
│ │ │ + │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── encoding │ │ │ │ @@ -1 +1 @@ │ │ │ │ -utf-8 │ │ │ │ +us-ascii │ │ │ ├── html2text {} │ │ │ │ @@ -1,37 +1,28 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _F_u_n_c_t_i_o_n_s │ │ │ │ -tuplevector.hh File Reference │ │ │ │ -Provides the TupleVector class that augments std::tuple by operator[]. _M_o_r_e_._._. │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_i_n_d_i_c_e_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_t_d_/_t_y_p_e___t_r_a_i_t_s_._h_h> │ │ │ │ -_G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -CCllaasssseess │ │ │ │ - class   _D_u_n_e_:_:_T_u_p_l_e_V_e_c_t_o_r_<_ _T_ _> │ │ │ │ -  A class augmenting std::tuple by element access via operator[]. │ │ │ │ - _M_o_r_e_._._. │ │ │ │ -struct   _s_t_d_:_:_t_u_p_l_e___e_l_e_m_e_n_t_<_ _i_,_ _D_u_n_e_:_:_T_u_p_l_e_V_e_c_t_o_r_<_ _A_r_g_s_._._._ _>_ _> │ │ │ │ -  Make std::tuple_element work for TupleVector. _M_o_r_e_._._. │ │ │ │ -struct   _s_t_d_:_:_t_u_p_l_e___s_i_z_e_<_ _D_u_n_e_:_:_T_u_p_l_e_V_e_c_t_o_r_<_ _A_r_g_s_._._._ _>_ _> │ │ │ │ -  Make std::tuple_size work for TupleVector. _M_o_r_e_._._. │ │ │ │ +_N_a_m_e_s_p_a_c_e_s | _V_a_r_i_a_b_l_e_s │ │ │ │ +stdstreams.cc File Reference │ │ │ │ +#include │ │ │ │ +#include "_s_t_d_s_t_r_e_a_m_s_._h_h" │ │ │ │ NNaammeessppaacceess │ │ │ │ namespace   _D_u_n_e │ │ │ │   Dune namespace │ │ │ │ -namespace   _s_t_d │ │ │ │ -  STL namespace. │ │ │ │ -FFuunnccttiioonnss │ │ │ │ -template │ │ │ │ -constexpr auto  _D_u_n_e_:_:_m_a_k_e_T_u_p_l_e_V_e_c_t_o_r (T &&... t) │ │ │ │ -********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ -Provides the TupleVector class that augments std::tuple by operator[]. │ │ │ │ - Author │ │ │ │ - Carsten Gräser │ │ │ │ +VVaarriiaabblleess │ │ │ │ +_D_V_V_e_r_b_T_y_p_e  _D_u_n_e_:_:_d_v_v_e_r_b (std::cout) │ │ │ │ +  stream for very verbose output. │ │ │ │ + _D_V_e_r_b_T_y_p_e  _D_u_n_e_:_:_d_v_e_r_b (std::cout) │ │ │ │ +  _S_i_n_g_l_e_t_o_n of verbose debug stream. │ │ │ │ + _D_I_n_f_o_T_y_p_e  _D_u_n_e_:_:_d_i_n_f_o (std::cout) │ │ │ │ +  Stream for informative output. │ │ │ │ + _D_W_a_r_n_T_y_p_e  _D_u_n_e_:_:_d_w_a_r_n (std::cerr) │ │ │ │ +  Stream for warnings indicating problems. │ │ │ │ +_D_G_r_a_v_e_T_y_p_e  _D_u_n_e_:_:_d_g_r_a_v_e (std::cerr) │ │ │ │ +  Stream for warnings indicating fatal errors. │ │ │ │ + _D_E_r_r_T_y_p_e  _D_u_n_e_:_:_d_e_r_r (std::cerr) │ │ │ │ +  Stream for error messages. │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00047.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: tupleutility.hh File Reference │ │ │ +dune-common: matrixconcepts.hh File Reference │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -72,91 +72,30 @@ │ │ │ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │
│ │ │ -Classes | │ │ │ -Namespaces | │ │ │ -Functions
│ │ │ -
tupleutility.hh File Reference
│ │ │ +Namespaces
│ │ │ +
matrixconcepts.hh File Reference
│ │ │
│ │ │
│ │ │ - │ │ │ -

Contains utility classes which can be used with std::tuple. │ │ │ -More...

│ │ │ -
#include <cstddef>
│ │ │ -#include <tuple>
│ │ │ +
#include <utility>
│ │ │ #include <type_traits>
│ │ │ -#include <utility>
│ │ │ -#include <dune/common/hybridutilities.hh>
│ │ │ -#include <dune/common/typetraits.hh>
│ │ │ +#include <dune/common/std/type_traits.hh>
│ │ │
│ │ │

Go to the source code of this file.

│ │ │ │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ -

│ │ │ -Classes

struct  Dune::TupleAccessTraits< T >
struct  Dune::TupleAccessTraits< T * >
struct  Dune::TupleAccessTraits< T & >
struct  Dune::NullPointerInitialiser< std::tuple< Args... > >
struct  Dune::ForEachType< TE, std::tuple< Args... > >
class  Dune::TransformTupleFunctor< TE, Args >
struct  Dune::TransformTupleFunctor< TE, Args >::TypeEvaluator< T >
struct  Dune::AddRefTypeEvaluator< T >
 TypeEvaluator to turn a type T into a reference to T More...
struct  Dune::AddPtrTypeEvaluator< T >
 TypeEvaluator to turn a type T into a pointer to T More...
struct  Dune::AddPtrTypeEvaluator< T & >
struct  Dune::AtType< N, Tuple >
 Type for reverse element access. More...
struct  Dune::At< N >
 Reverse element access. More...
struct  Dune::PointerPairDeletor< Tuple >
 Deletes all objects pointed to in a std::tuple of pointers. More...
class  Dune::FirstPredicateIndex< Tuple, Predicate, start, size >
 Finding the index of a certain type in a std::tuple. More...
struct  Dune::IsType< T >
 Generator for predicates accepting one particular type. More...
struct  Dune::IsType< T >::Predicate< U >
 The actual predicate. More...
struct  Dune::FirstTypeIndex< Tuple, T, start >
 Find the first occurrence of a type in a std::tuple. More...
struct  Dune::PushBackTuple< typename std::tuple< Args... >, T >
struct  Dune::PushFrontTuple< typename std::tuple< Args... >, T >
struct  Dune::ReduceTuple< F, Tuple, Seed, N >
 Apply reduce with meta binary function to template. More...
struct  Dune::ReduceTuple< F, Tuple, Seed, 0 >
 Apply reduce with meta binary function to template. More...
struct  Dune::JoinTuples< Head, Tail >
 Join two std::tuple's. More...
struct  Dune::FlattenTuple< Tuple >
 Flatten a std::tuple of std::tuple's. More...
│ │ │ │ │ │ │ │ │ │ │ │ -

│ │ │ Namespaces

namespace  Dune
 Dune namespace
│ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │ - │ │ │

│ │ │ -Functions

template<class F, class ArgTuple, class I, I... i>
decltype(auto) Dune::applyPartial (F &&f, ArgTuple &&args, std::integer_sequence< I, i... >)
 Apply function with arguments from a given tuple.
template<class Tuple, class Functor>
auto Dune::genericTransformTuple (Tuple &&t, Functor &&f) -> decltype(genericTransformTupleBackend(t, f))
template<template< class > class TE, class... Args>
TransformTupleFunctor< TE, Args... > Dune::makeTransformTupleFunctor (Args &&... args)
template<template< class > class TypeEvaluator, class Tuple, class... Args>
auto Dune::transformTuple (Tuple &&orig, Args &&... args) -> decltype(genericTransformTuple(orig, makeTransformTupleFunctor< TypeEvaluator >(args...)))
│ │ │ -

Detailed Description

│ │ │ -

Contains utility classes which can be used with std::tuple.

│ │ │ -
│ │ │ +
│ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,80 +1,17 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -_C_l_a_s_s_e_s | _N_a_m_e_s_p_a_c_e_s | _F_u_n_c_t_i_o_n_s │ │ │ │ -tupleutility.hh File Reference │ │ │ │ -_C_o_m_m_o_n » _U_t_i_l_i_t_i_e_s » _T_u_p_l_e_ _U_t_i_l_i_t_i_e_s │ │ │ │ -Contains utility classes which can be used with std::tuple. _M_o_r_e_._._. │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ -#include │ │ │ │ +_N_a_m_e_s_p_a_c_e_s │ │ │ │ +matrixconcepts.hh File Reference │ │ │ │ #include │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ -#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ +#include │ │ │ │ +#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_t_d_/_t_y_p_e___t_r_a_i_t_s_._h_h> │ │ │ │ _G_o_ _t_o_ _t_h_e_ _s_o_u_r_c_e_ _c_o_d_e_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ -CCllaasssseess │ │ │ │ -struct   _D_u_n_e_:_:_T_u_p_l_e_A_c_c_e_s_s_T_r_a_i_t_s_<_ _T_ _> │ │ │ │ -struct   _D_u_n_e_:_:_T_u_p_l_e_A_c_c_e_s_s_T_r_a_i_t_s_<_ _T_ _*_ _> │ │ │ │ -struct   _D_u_n_e_:_:_T_u_p_l_e_A_c_c_e_s_s_T_r_a_i_t_s_<_ _T_ _&_ _> │ │ │ │ -struct   _D_u_n_e_:_:_N_u_l_l_P_o_i_n_t_e_r_I_n_i_t_i_a_l_i_s_e_r_<_ _s_t_d_:_:_t_u_p_l_e_<_ _A_r_g_s_._._._ _>_ _> │ │ │ │ -struct   _D_u_n_e_:_:_F_o_r_E_a_c_h_T_y_p_e_<_ _T_E_,_ _s_t_d_:_:_t_u_p_l_e_<_ _A_r_g_s_._._._ _>_ _> │ │ │ │ - class   _D_u_n_e_:_:_T_r_a_n_s_f_o_r_m_T_u_p_l_e_F_u_n_c_t_o_r_<_ _T_E_,_ _A_r_g_s_ _> │ │ │ │ -struct   _D_u_n_e_:_:_T_r_a_n_s_f_o_r_m_T_u_p_l_e_F_u_n_c_t_o_r_<_ _T_E_,_ _A_r_g_s_ _>_:_:_T_y_p_e_E_v_a_l_u_a_t_o_r_<_ _T_ _> │ │ │ │ -struct   _D_u_n_e_:_:_A_d_d_R_e_f_T_y_p_e_E_v_a_l_u_a_t_o_r_<_ _T_ _> │ │ │ │ -  TypeEvaluator to turn a type T into a reference to T _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_d_d_P_t_r_T_y_p_e_E_v_a_l_u_a_t_o_r_<_ _T_ _> │ │ │ │ -  TypeEvaluator to turn a type T into a pointer to T _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_d_d_P_t_r_T_y_p_e_E_v_a_l_u_a_t_o_r_<_ _T_ _&_ _> │ │ │ │ -struct   _D_u_n_e_:_:_A_t_T_y_p_e_<_ _N_,_ _T_u_p_l_e_ _> │ │ │ │ -  _T_y_p_e for reverse element access. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_A_t_<_ _N_ _> │ │ │ │ -  Reverse element access. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_P_o_i_n_t_e_r_P_a_i_r_D_e_l_e_t_o_r_<_ _T_u_p_l_e_ _> │ │ │ │ -  Deletes all objects pointed to in a std::tuple of pointers. _M_o_r_e_._._. │ │ │ │ - class   _D_u_n_e_:_:_F_i_r_s_t_P_r_e_d_i_c_a_t_e_I_n_d_e_x_<_ _T_u_p_l_e_,_ _P_r_e_d_i_c_a_t_e_,_ _s_t_a_r_t_,_ _s_i_z_e_ _> │ │ │ │ -  Finding the index of a certain type in a std::tuple. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_T_y_p_e_<_ _T_ _> │ │ │ │ -  Generator for predicates accepting one particular type. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_I_s_T_y_p_e_<_ _T_ _>_:_:_P_r_e_d_i_c_a_t_e_<_ _U_ _> │ │ │ │ -  The actual predicate. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_F_i_r_s_t_T_y_p_e_I_n_d_e_x_<_ _T_u_p_l_e_,_ _T_,_ _s_t_a_r_t_ _> │ │ │ │ -  Find the first occurrence of a type in a std::tuple. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_P_u_s_h_B_a_c_k_T_u_p_l_e_<_ _t_y_p_e_n_a_m_e_ _s_t_d_:_:_t_u_p_l_e_<_ _A_r_g_s_._._._ _>_,_ _T_ _> │ │ │ │ -struct   _D_u_n_e_:_:_P_u_s_h_F_r_o_n_t_T_u_p_l_e_<_ _t_y_p_e_n_a_m_e_ _s_t_d_:_:_t_u_p_l_e_<_ _A_r_g_s_._._._ _>_,_ _T_ _> │ │ │ │ -struct   _D_u_n_e_:_:_R_e_d_u_c_e_T_u_p_l_e_<_ _F_,_ _T_u_p_l_e_,_ _S_e_e_d_,_ _N_ _> │ │ │ │ -  Apply reduce with meta binary function to template. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_R_e_d_u_c_e_T_u_p_l_e_<_ _F_,_ _T_u_p_l_e_,_ _S_e_e_d_,_ _0_ _> │ │ │ │ -  Apply reduce with meta binary function to template. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_J_o_i_n_T_u_p_l_e_s_<_ _H_e_a_d_,_ _T_a_i_l_ _> │ │ │ │ -  Join two std::tuple's. _M_o_r_e_._._. │ │ │ │ -struct   _D_u_n_e_:_:_F_l_a_t_t_e_n_T_u_p_l_e_<_ _T_u_p_l_e_ _> │ │ │ │ -  Flatten a std::tuple of std::tuple's. _M_o_r_e_._._. │ │ │ │ NNaammeessppaacceess │ │ │ │ namespace   _D_u_n_e │ │ │ │   Dune namespace │ │ │ │ -FFuunnccttiioonnss │ │ │ │ -template │ │ │ │ - decltype(auto)  _D_u_n_e_:_:_a_p_p_l_y_P_a_r_t_i_a_l (F &&f, ArgTuple │ │ │ │ - &&args, std::integer_sequence< I, i... >) │ │ │ │ -  Apply function with arguments from a │ │ │ │ - given tuple. │ │ │ │ -template │ │ │ │ - auto  _D_u_n_e_:_:_g_e_n_e_r_i_c_T_r_a_n_s_f_o_r_m_T_u_p_l_e (Tuple &&t, │ │ │ │ - Functor &&f) -> decltype │ │ │ │ - (genericTransformTupleBackend(t, f)) │ │ │ │ -template class TE, class... Args> │ │ │ │ -_T_r_a_n_s_f_o_r_m_T_u_p_l_e_F_u_n_c_t_o_r< TE, Args... >  _D_u_n_e_:_:_m_a_k_e_T_r_a_n_s_f_o_r_m_T_u_p_l_e_F_u_n_c_t_o_r (Args │ │ │ │ - &&... args) │ │ │ │ -template class TypeEvaluator, class Tuple, class... Args> │ │ │ │ - auto  _D_u_n_e_:_:_t_r_a_n_s_f_o_r_m_T_u_p_l_e (Tuple &&orig, Args │ │ │ │ - &&... args) -> decltype │ │ │ │ - (_g_e_n_e_r_i_c_T_r_a_n_s_f_o_r_m_T_u_p_l_e(orig, │ │ │ │ - _m_a_k_e_T_r_a_n_s_f_o_r_m_T_u_p_l_e_F_u_n_c_t_o_r< TypeEvaluator │ │ │ │ - >(args...))) │ │ │ │ -********** DDeettaaiilleedd DDeessccrriippttiioonn ********** │ │ │ │ -Contains utility classes which can be used with std::tuple. │ │ │ │ =============================================================================== │ │ │ │ Generated by _[_d_o_x_y_g_e_n_] 1.15.0 │ │ ├── ./usr/share/doc/libdune-common-doc/doxygen/a00047_source.html │ │ │ @@ -1,15 +1,15 @@ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ -dune-common: tupleutility.hh Source File │ │ │ +dune-common: matrixconcepts.hh Source File │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ @@ -71,450 +71,115 @@ │ │ │ │ │ │ │ │ │
│ │ │
│ │ │ -
tupleutility.hh
│ │ │ +
matrixconcepts.hh
│ │ │
│ │ │
│ │ │ Go to the documentation of this file.
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
│ │ │
2// vi: set et ts=4 sw=2 sts=2:
│ │ │
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
│ │ │
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
│ │ │ -
5
│ │ │ -
6#ifndef DUNE_TUPLE_UTILITY_HH
│ │ │ -
7#define DUNE_TUPLE_UTILITY_HH
│ │ │ +
5#ifndef DUNE_COMMON_MATRIXCONCEPTS_HH
│ │ │ +
6#define DUNE_COMMON_MATRIXCONCEPTS_HH
│ │ │ +
7
│ │ │
8
│ │ │ -
9#include <cstddef>
│ │ │ -
10#include <tuple>
│ │ │ +
9
│ │ │ +
10#include <utility>
│ │ │
11#include <type_traits>
│ │ │ -
12#include <utility>
│ │ │ -
13
│ │ │ - │ │ │ - │ │ │ +
12
│ │ │ + │ │ │ +
14
│ │ │ +
15
│ │ │
16
│ │ │
17namespace Dune {
│ │ │ -
18
│ │ │ -
23
│ │ │ -
28
│ │ │ -
41 template<class F, class ArgTuple, class I, I... i>
│ │ │ -
│ │ │ -
42 decltype(auto) applyPartial(F&& f, ArgTuple&& args, std::integer_sequence<I, i...> /*indices*/)
│ │ │ -
43 {
│ │ │ -
44 return f(std::get<i>(args)...);
│ │ │ -
45 }
│ │ │ -
│ │ │ -
46
│ │ │ -
47 template<class T>
│ │ │ -
│ │ │ - │ │ │ -
49 {
│ │ │ -
50 typedef typename std::add_const<T>::type& ConstType;
│ │ │ -
51 typedef T& NonConstType;
│ │ │ -
52 typedef const typename std::remove_const<T>::type& ParameterType;
│ │ │ -
53 };
│ │ │ -
│ │ │ -
54
│ │ │ -
55 template<class T>
│ │ │ -
│ │ │ - │ │ │ -
57 {
│ │ │ -
58 typedef typename std::add_const<T>::type* ConstType;
│ │ │ -
59 typedef T* NonConstType;
│ │ │ -
60 typedef T* ParameterType;
│ │ │ -
61 };
│ │ │ -
│ │ │ -
62
│ │ │ -
63 template<class T>
│ │ │ -
│ │ │ - │ │ │ -
65 {
│ │ │ -
66 typedef T& ConstType;
│ │ │ -
67 typedef T& NonConstType;
│ │ │ -
68 typedef T& ParameterType;
│ │ │ -
69 };
│ │ │ -
│ │ │ -
70
│ │ │ -
78 template<class T>
│ │ │ - │ │ │ -
80
│ │ │ -
81 template<class... Args>
│ │ │ -
│ │ │ -
82 struct NullPointerInitialiser<std::tuple<Args...> >
│ │ │ -
83 {
│ │ │ -
84 typedef std::tuple<Args...> ResultType;
│ │ │ -
│ │ │ - │ │ │ -
86 {
│ │ │ -
87 return ResultType(static_cast<Args>(nullptr)...);
│ │ │ -
88 }
│ │ │ -
│ │ │ -
89 };
│ │ │ -
│ │ │ -
90
│ │ │ -
115 template<template <class> class TE, class T>
│ │ │ - │ │ │ -
117
│ │ │ -
118 template<template <class> class TE, class... Args>
│ │ │ -
│ │ │ -
119 struct ForEachType<TE, std::tuple<Args...> >
│ │ │ -
120 {
│ │ │ -
121 typedef std::tuple<typename TE<Args>::Type...> Type;
│ │ │ -
122 };
│ │ │ -
│ │ │ -
123
│ │ │ -
124#ifndef DOXYGEN
│ │ │ -
125 template<class Tuple, class Functor, std::size_t... I>
│ │ │ -
126 inline auto genericTransformTupleBackendImpl(Tuple& t, Functor& f, const std::index_sequence<I...>& )
│ │ │ -
127 -> std::tuple<decltype(f(std::get<I>(t)))...>
│ │ │ -
128 {
│ │ │ -
129 return std::tuple<decltype(f(std::get<I>(t)))...>(f(std::get<I>(t))...);
│ │ │ -
130 }
│ │ │ -
131
│ │ │ -
132 template<class... Args, class Functor>
│ │ │ -
133 auto genericTransformTupleBackend(std::tuple<Args...>& t, Functor& f) ->
│ │ │ -
134 decltype(genericTransformTupleBackendImpl(t, f,std::index_sequence_for<Args...>{}))
│ │ │ -
135 {
│ │ │ -
136 return genericTransformTupleBackendImpl(t, f,std::index_sequence_for<Args...>{});
│ │ │ -
137 }
│ │ │ -
138
│ │ │ -
139 template<class... Args, class Functor>
│ │ │ -
140 auto genericTransformTupleBackend(const std::tuple<Args...>& t, Functor& f) ->
│ │ │ -
141 decltype(genericTransformTupleBackendImpl(t, f, std::index_sequence_for<Args...>{}))
│ │ │ -
142 {
│ │ │ -
143 return genericTransformTupleBackendImpl(t, f, std::index_sequence_for<Args...>{});
│ │ │ -
144 }
│ │ │ -
145#endif
│ │ │ -
146
│ │ │ -
185 template<class Tuple, class Functor>
│ │ │ -
│ │ │ -
186 auto genericTransformTuple(Tuple&& t, Functor&& f) ->
│ │ │ -
187 decltype(genericTransformTupleBackend(t, f))
│ │ │ -
188 {
│ │ │ -
189 return genericTransformTupleBackend(t, f);
│ │ │ -
190 }
│ │ │ -
│ │ │ -
191
│ │ │ -
224 template<template<class> class TE, class... Args>
│ │ │ -
│ │ │ - │ │ │ -
226 {
│ │ │ -
227 mutable std::tuple<Args&...> tup;
│ │ │ -
228
│ │ │ -
229 template<class T, std::size_t... I>
│ │ │ -
230 inline auto apply(T&& t, const std::index_sequence<I...>& ) ->
│ │ │ -
231 decltype(TE<T>::apply(t,std::get<I>(tup)...)) const
│ │ │ -
232 {
│ │ │ -
233 return TE<T>::apply(t,std::get<I>(tup)...);
│ │ │ -
234 }
│ │ │ -
235
│ │ │ -
236 public:
│ │ │ -
237 template<class T>
│ │ │ -
│ │ │ -
238 struct TypeEvaluator : public TE<T>
│ │ │ -
239 {};
│ │ │ -
│ │ │ -
240
│ │ │ -
│ │ │ -
241 TransformTupleFunctor(Args&&... args)
│ │ │ -
242 : tup(args...)
│ │ │ -
243 { }
│ │ │ -
│ │ │ -
244
│ │ │ -
245 template<class T>
│ │ │ -
│ │ │ -
246 inline auto operator()(T&& t) ->
│ │ │ -
247 decltype(this->apply(t,std::index_sequence_for<Args...>{})) const
│ │ │ -
248 {
│ │ │ -
249 return apply(t,std::index_sequence_for<Args...>{});
│ │ │ -
250 }
│ │ │ -
│ │ │ -
251 };
│ │ │ -
│ │ │ -
252
│ │ │ -
253 template<template<class> class TE, class... Args>
│ │ │ -
│ │ │ - │ │ │ -
255 {
│ │ │ -
256 return TransformTupleFunctor<TE, Args...>(args...);
│ │ │ -
257 }
│ │ │ -
│ │ │ -
258
│ │ │ -
291 template<template<class> class TypeEvaluator, class Tuple, class... Args>
│ │ │ -
│ │ │ -
292 auto transformTuple(Tuple&& orig, Args&&... args) ->
│ │ │ - │ │ │ -
294 {
│ │ │ - │ │ │ -
296 }
│ │ │ -
│ │ │ -
297
│ │ │ -
299
│ │ │ -
303 template<class T>
│ │ │ -
│ │ │ - │ │ │ -
305 {
│ │ │ -
306 typedef T& Type;
│ │ │ -
│ │ │ -
307 static Type apply(T& t)
│ │ │ -
308 {
│ │ │ -
309 return t;
│ │ │ -
310 }
│ │ │ -
│ │ │ -
311 };
│ │ │ -
│ │ │ -
312
│ │ │ -
314
│ │ │ -
318 template<class T>
│ │ │ -
│ │ │ - │ │ │ -
320 {
│ │ │ -
321 typedef typename std::remove_reference<T>::type* Type;
│ │ │ -
│ │ │ -
322 static Type apply(T& t)
│ │ │ -
323 {
│ │ │ -
324 return &t;
│ │ │ -
325 }
│ │ │ -
│ │ │ -
326 };
│ │ │ -
│ │ │ -
327
│ │ │ -
328 // Specialization, in case the type is already a reference
│ │ │ -
329 template<class T>
│ │ │ -
│ │ │ - │ │ │ -
331 {
│ │ │ -
332 typedef typename std::remove_reference<T>::type* Type;
│ │ │ -
│ │ │ -
333 static Type apply(T& t)
│ │ │ -
334 {
│ │ │ -
335 return &t;
│ │ │ -
336 }
│ │ │ -
│ │ │ -
337 };
│ │ │ -
│ │ │ -
338
│ │ │ -
344 template<int N, class Tuple>
│ │ │ -
│ │ │ -
345 struct AtType
│ │ │ -
346 {
│ │ │ -
347 typedef typename std::tuple_element<std::tuple_size<Tuple>::value - N - 1, Tuple>::type Type;
│ │ │ -
348 };
│ │ │ -
│ │ │ -
349
│ │ │ -
357 template<int N>
│ │ │ -
│ │ │ -
358 struct At
│ │ │ -
359 {
│ │ │ -
360 template<typename Tuple>
│ │ │ -
361 static typename TupleAccessTraits<typename AtType<N, Tuple>::Type>::NonConstType
│ │ │ -
│ │ │ -
362 get(Tuple& t)
│ │ │ -
363 {
│ │ │ -
364 return std::get<std::tuple_size<Tuple>::value - N - 1>(t);
│ │ │ -
365 }
│ │ │ -
│ │ │ -
366
│ │ │ -
367 template<typename Tuple>
│ │ │ -
368 static typename TupleAccessTraits<typename AtType<N, Tuple>::Type>::ConstType
│ │ │ -
│ │ │ -
369 get(const Tuple& t)
│ │ │ -
370 {
│ │ │ -
371 return std::get<std::tuple_size<Tuple>::value - N - 1>(t);
│ │ │ -
372 }
│ │ │ -
│ │ │ -
373 };
│ │ │ -
│ │ │ -
374
│ │ │ -
378 template<class Tuple>
│ │ │ -
│ │ │ - │ │ │ -
380 {
│ │ │ -
381 template<typename... Ts>
│ │ │ -
│ │ │ -
382 static void apply(std::tuple<Ts...>& t)
│ │ │ -
383 {
│ │ │ -
384 Hybrid::forEach(t,[&](auto&& ti){delete ti; ti=nullptr;});
│ │ │ -
385 }
│ │ │ -
│ │ │ -
386 };
│ │ │ -
│ │ │ -
387
│ │ │ -
411 template<class Tuple, template<class> class Predicate, std::size_t start = 0,
│ │ │ -
412 std::size_t size = std::tuple_size<Tuple>::value>
│ │ │ -
│ │ │ - │ │ │ -
414 public std::conditional<Predicate<typename std::tuple_element<start,
│ │ │ -
415 Tuple>::type>::value,
│ │ │ -
416 std::integral_constant<std::size_t, start>,
│ │ │ -
417 FirstPredicateIndex<Tuple, Predicate, start+1> >::type
│ │ │ -
418 {
│ │ │ -
419 static_assert(std::tuple_size<Tuple>::value == size, "The \"size\" "
│ │ │ -
420 "template parameter of FirstPredicateIndex is an "
│ │ │ -
421 "implementation detail and should never be set "
│ │ │ -
422 "explicitly!");
│ │ │ -
423 };
│ │ │ -
│ │ │ -
424
│ │ │ -
425#ifndef DOXYGEN
│ │ │ -
426 template<class Tuple, template<class> class Predicate, std::size_t size>
│ │ │ -
427 class FirstPredicateIndex<Tuple, Predicate, size, size>
│ │ │ -
428 {
│ │ │ -
429 static_assert(AlwaysFalse<Tuple>::value, "None of the std::tuple element "
│ │ │ -
430 "types matches the predicate!");
│ │ │ -
431 };
│ │ │ -
432#endif // !DOXYGEN
│ │ │ -
433
│ │ │ -
443 template<class T>
│ │ │ -
│ │ │ -
444 struct IsType
│ │ │ -
445 {
│ │ │ -
447 template<class U>
│ │ │ -
448 struct Predicate : public std::is_same<T, U> {};
│ │ │ -
449 };
│ │ │ -
│ │ │ -
450
│ │ │ -
464 template<class Tuple, class T, std::size_t start = 0>
│ │ │ -
│ │ │ - │ │ │ -
466 public FirstPredicateIndex<Tuple, IsType<T>::template Predicate, start>
│ │ │ -
467 { };
│ │ │ -
│ │ │ -
468
│ │ │ -
475 template<class Tuple, class T>
│ │ │ - │ │ │ -
477
│ │ │ -
478 template<class... Args, class T>
│ │ │ -
│ │ │ -
479 struct PushBackTuple<typename std::tuple<Args...>, T>
│ │ │ -
480 {
│ │ │ -
481 typedef typename std::tuple<Args..., T> type;
│ │ │ -
482 };
│ │ │ -
│ │ │ -
483
│ │ │ -
490 template<class Tuple, class T>
│ │ │ - │ │ │ -
492
│ │ │ -
493 template<class... Args, class T>
│ │ │ -
│ │ │ -
494 struct PushFrontTuple<typename std::tuple<Args...>, T>
│ │ │ -
495 {
│ │ │ -
496 typedef typename std::tuple<T, Args...> type;
│ │ │ -
497 };
│ │ │ -
│ │ │ -
498
│ │ │ -
511 template<
│ │ │ -
512 template <class, class> class F,
│ │ │ -
513 class Tuple,
│ │ │ -
514 class Seed=std::tuple<>,
│ │ │ -
515 int N=std::tuple_size<Tuple>::value>
│ │ │ -
│ │ │ - │ │ │ -
517 {
│ │ │ -
518 typedef typename ReduceTuple<F, Tuple, Seed, N-1>::type Accumulated;
│ │ │ -
519 typedef typename std::tuple_element<N-1, Tuple>::type Value;
│ │ │ -
520
│ │ │ -
522 typedef typename F<Accumulated, Value>::type type;
│ │ │ -
523 };
│ │ │ -
│ │ │ -
524
│ │ │ -
535 template<
│ │ │ -
536 template <class, class> class F,
│ │ │ -
537 class Tuple,
│ │ │ -
538 class Seed>
│ │ │ -
│ │ │ -
539 struct ReduceTuple<F, Tuple, Seed, 0>
│ │ │ -
540 {
│ │ │ -
542 typedef Seed type;
│ │ │ -
543 };
│ │ │ -
│ │ │ -
544
│ │ │ -
554 template<class Head, class Tail>
│ │ │ -
│ │ │ - │ │ │ -
556 {
│ │ │ - │ │ │ -
559 };
│ │ │ -
│ │ │ -
560
│ │ │ -
569 template<class Tuple>
│ │ │ -
│ │ │ - │ │ │ -
571 {
│ │ │ - │ │ │ -
574 };
│ │ │ -
│ │ │ -
575
│ │ │ -
577}
│ │ │ -
578
│ │ │ -
579#endif
│ │ │ -
Traits for type conversions and type information.
│ │ │ - │ │ │ -
decltype(auto) applyPartial(F &&f, ArgTuple &&args, std::integer_sequence< I, i... >)
Apply function with arguments from a given tuple.
Definition tupleutility.hh:42
│ │ │ -
std::add_const< T >::type & ConstType
Definition tupleutility.hh:50
│ │ │ -
static void apply(std::tuple< Ts... > &t)
Definition tupleutility.hh:382
│ │ │ -
T * ParameterType
Definition tupleutility.hh:60
│ │ │ -
auto transformTuple(Tuple &&orig, Args &&... args) -> decltype(genericTransformTuple(orig, makeTransformTupleFunctor< TypeEvaluator >(args...)))
Definition tupleutility.hh:292
│ │ │ -
T & ConstType
Definition tupleutility.hh:66
│ │ │ -
ReduceTuple< F, Tuple, Seed, N-1 >::type Accumulated
Definition tupleutility.hh:518
│ │ │ -
T * NonConstType
Definition tupleutility.hh:59
│ │ │ -
Seed type
Result of the reduce operation.
Definition tupleutility.hh:542
│ │ │ -
std::remove_reference< T >::type * Type
Definition tupleutility.hh:321
│ │ │ -
static Type apply(T &t)
Definition tupleutility.hh:307
│ │ │ -
static ResultType apply()
Definition tupleutility.hh:85
│ │ │ -
std::tuple< Args... > ResultType
Definition tupleutility.hh:84
│ │ │ -
std::remove_reference< T >::type * Type
Definition tupleutility.hh:332
│ │ │ -
TransformTupleFunctor(Args &&... args)
Definition tupleutility.hh:241
│ │ │ -
std::tuple_element< std::tuple_size< Tuple >::value-N-1, Tuple >::type Type
Definition tupleutility.hh:347
│ │ │ -
static Type apply(T &t)
Definition tupleutility.hh:333
│ │ │ -
auto operator()(T &&t) -> decltype(this->apply(t, std::index_sequence_for< Args... >{})) const
Definition tupleutility.hh:246
│ │ │ -
T & NonConstType
Definition tupleutility.hh:67
│ │ │ -
T & NonConstType
Definition tupleutility.hh:51
│ │ │ -
static TupleAccessTraits< typenameAtType< N, Tuple >::Type >::ConstType get(const Tuple &t)
Definition tupleutility.hh:369
│ │ │ -
T & Type
Definition tupleutility.hh:306
│ │ │ -
static TupleAccessTraits< typenameAtType< N, Tuple >::Type >::NonConstType get(Tuple &t)
Definition tupleutility.hh:362
│ │ │ -
std::tuple< Args..., T > type
Definition tupleutility.hh:481
│ │ │ -
std::tuple_element< N-1, Tuple >::type Value
Definition tupleutility.hh:519
│ │ │ -
std::tuple< T, Args... > type
Definition tupleutility.hh:496
│ │ │ -
ReduceTuple< JoinTuples, Tuple >::type type
Result of the flatten operation.
Definition tupleutility.hh:573
│ │ │ -
static Type apply(T &t)
Definition tupleutility.hh:322
│ │ │ -
F< Accumulated, Value >::type type
Result of the reduce operation.
Definition tupleutility.hh:522
│ │ │ -
ReduceTuple< PushBackTuple, Tail, Head >::type type
Result of the join operation.
Definition tupleutility.hh:558
│ │ │ -
std::tuple< typename TE< Args >::Type... > Type
Definition tupleutility.hh:121
│ │ │ -
auto genericTransformTuple(Tuple &&t, Functor &&f) -> decltype(genericTransformTupleBackend(t, f))
Definition tupleutility.hh:186
│ │ │ -
T & ParameterType
Definition tupleutility.hh:68
│ │ │ -
const std::remove_const< T >::type & ParameterType
Definition tupleutility.hh:52
│ │ │ -
std::add_const< T >::type * ConstType
Definition tupleutility.hh:58
│ │ │ -
TransformTupleFunctor< TE, Args... > makeTransformTupleFunctor(Args &&... args)
Definition tupleutility.hh:254
│ │ │ -
constexpr void forEach(Range &&range, F &&f)
Range based for loop.
Definition hybridutilities.hh:261
│ │ │ -
STL namespace.
│ │ │ +
18
│ │ │ +
19 template<class, int, int>
│ │ │ +
20 class FieldMatrix;
│ │ │ +
21
│ │ │ +
22 template<class>
│ │ │ +
23 class DynamicMatrix;
│ │ │ +
24
│ │ │ +
25}
│ │ │ +
26
│ │ │ +
27namespace Dune::Impl {
│ │ │ +
28
│ │ │ +
29
│ │ │ +
30 // Some traits for checking matrix concepts. Currently these are
│ │ │ +
31 // all technical internal helpers that just serve different headers
│ │ │ +
32 // to do internal checks and are thus collected here.
│ │ │ +
33
│ │ │ +
34 template<class T>
│ │ │ +
35 using IsMatrixHelper = std::void_t<decltype(std::declval<T>().N(), std::declval<T>().M())>;
│ │ │ +
36
│ │ │ +
37 template<class T>
│ │ │ +
38 struct IsMatrix : public Dune::Std::is_detected<IsMatrixHelper, T> {};
│ │ │ +
39
│ │ │ +
40 // Check if T is a matrix by checking for member functions N() and M().
│ │ │ +
41 template<class T>
│ │ │ +
42 constexpr bool IsMatrix_v = Impl::IsMatrix<T>::value;
│ │ │ +
43
│ │ │ +
44
│ │ │ +
45
│ │ │ +
46 template<class T>
│ │ │ +
47 using IsStaticSizeMatrixHelper = std::void_t<decltype(T::rows, T::cols)>;
│ │ │ +
48
│ │ │ +
49 template<class T>
│ │ │ +
50 struct IsStaticSizeMatrix : public Dune::Std::is_detected<IsStaticSizeMatrixHelper, T> {};
│ │ │ +
51
│ │ │ +
52 // Check if T is a statically sized matrix by checking for static members rows and cols.
│ │ │ +
53 template<class T>
│ │ │ +
54 constexpr bool IsStaticSizeMatrix_v = Impl::IsStaticSizeMatrix<T>::value;
│ │ │ +
55
│ │ │ +
56
│ │ │ +
57
│ │ │ +
58 template<class T>
│ │ │ +
59 class IsFieldMatrix : public std::false_type {};
│ │ │ +
60
│ │ │ +
61 template< class K, int ROWS, int COLS>
│ │ │ +
62 class IsFieldMatrix<Dune::FieldMatrix<K, ROWS, COLS>> : public std::true_type {};
│ │ │ +
63
│ │ │ +
64 // Check if T is an instance of FieldMatrix
│ │ │ +
65 template<class T>
│ │ │ +
66 constexpr bool IsFieldMatrix_v = Impl::IsFieldMatrix<T>::value;
│ │ │ +
67
│ │ │ +
68
│ │ │ +
69
│ │ │ +
82 template<class T>
│ │ │ +
83 class IsDenseMatrix : public std::false_type {};
│ │ │ +
84
│ │ │ +
85 template<class T>
│ │ │ +
86 class IsDenseMatrix<const T> : public IsDenseMatrix<T> {};
│ │ │ +
87
│ │ │ +
88 template<class K, int ROWS, int COLS>
│ │ │ +
89 class IsDenseMatrix<Dune::FieldMatrix<K, ROWS, COLS>> : public std::true_type {};
│ │ │ +
90
│ │ │ +
91 template<class K>
│ │ │ +
92 class IsDenseMatrix<Dune::DynamicMatrix<K>> : public std::true_type {};
│ │ │ +
93
│ │ │ +
94 // Check if T is a dense matrix. This is implemented by specialization.
│ │ │ +
95 template<class T>
│ │ │ +
96 constexpr bool IsDenseMatrix_v = Impl::IsDenseMatrix<T>::value;
│ │ │ +
97
│ │ │ +
98
│ │ │ +
99
│ │ │ +
100} // namespace Dune::Impl
│ │ │ +
101
│ │ │ +
102
│ │ │ +
103
│ │ │ +
104#endif // DUNE_COMMON_MATRIXCONCEPTS_HH
│ │ │ + │ │ │ +
typename detected_or< nonesuch, Op, Args... >::value_t is_detected
Detects whether Op<Args...> is valid.
Definition type_traits.hh:141
│ │ │
Dune namespace
Definition alignedallocator.hh:13
│ │ │ -
constexpr std::integral_constant< std::size_t, sizeof...(II)> size(std::integer_sequence< T, II... >)
Return the size of the sequence.
Definition integersequence.hh:75
│ │ │ -
Definition tupleutility.hh:49
│ │ │ -
A helper template that initializes a std::tuple consisting of pointers to nullptr.
Definition tupleutility.hh:79
│ │ │ -
Helper template to clone the type definition of a std::tuple with the storage types replaced by a use...
Definition tupleutility.hh:116
│ │ │ -
Definition tupleutility.hh:226
│ │ │ -
Definition tupleutility.hh:239
│ │ │ -
TypeEvaluator to turn a type T into a reference to T
Definition tupleutility.hh:305
│ │ │ -
TypeEvaluator to turn a type T into a pointer to T
Definition tupleutility.hh:320
│ │ │ -
Type for reverse element access.
Definition tupleutility.hh:346
│ │ │ -
Reverse element access.
Definition tupleutility.hh:359
│ │ │ -
Deletes all objects pointed to in a std::tuple of pointers.
Definition tupleutility.hh:380
│ │ │ -
Finding the index of a certain type in a std::tuple.
Definition tupleutility.hh:418
│ │ │ -
Generator for predicates accepting one particular type.
Definition tupleutility.hh:445
│ │ │ -
The actual predicate.
Definition tupleutility.hh:448
│ │ │ -
Find the first occurrence of a type in a std::tuple.
Definition tupleutility.hh:467
│ │ │ -
Helper template to append a type to a std::tuple.
Definition tupleutility.hh:476
│ │ │ -
Helper template to prepend a type to a std::tuple.
Definition tupleutility.hh:491
│ │ │ - │ │ │ -
Join two std::tuple's.
Definition tupleutility.hh:556
│ │ │ -
Flatten a std::tuple of std::tuple's.
Definition tupleutility.hh:571
│ │ │ -
template which always yields a false value
Definition typetraits.hh:124
│ │ │ +
constexpr size_type N() const
number of rows
Definition densematrix.hh:702
│ │ │ +
A dense n x m matrix.
Definition fmatrix.hh:117
│ │ │ +
Construct a matrix with a dynamic size.
Definition dynmatrix.hh:61
│ │ │
│ │ │ │ │ │ │ │ │
│ │ │ │ │ │ ├── html2text {} │ │ │ │ @@ -1,520 +1,126 @@ │ │ │ │ dune-common 2.11 │ │ │ │ Loading... │ │ │ │ Searching... │ │ │ │ No Matches │ │ │ │ * _d_u_n_e │ │ │ │ * _c_o_m_m_o_n │ │ │ │ -tupleutility.hh │ │ │ │ +matrixconcepts.hh │ │ │ │ _G_o_ _t_o_ _t_h_e_ _d_o_c_u_m_e_n_t_a_t_i_o_n_ _o_f_ _t_h_i_s_ _f_i_l_e_. │ │ │ │ 1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- │ │ │ │ 2// vi: set et ts=4 sw=2 sts=2: │ │ │ │ 3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file │ │ │ │ LICENSE.md in module root │ │ │ │ 4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception │ │ │ │ -5 │ │ │ │ -6#ifndef DUNE_TUPLE_UTILITY_HH │ │ │ │ -7#define DUNE_TUPLE_UTILITY_HH │ │ │ │ +5#ifndef DUNE_COMMON_MATRIXCONCEPTS_HH │ │ │ │ +6#define DUNE_COMMON_MATRIXCONCEPTS_HH │ │ │ │ +7 │ │ │ │ 8 │ │ │ │ -9#include │ │ │ │ -10#include │ │ │ │ +9 │ │ │ │ +10#include │ │ │ │ 11#include │ │ │ │ -12#include │ │ │ │ -13 │ │ │ │ -14#include <_d_u_n_e_/_c_o_m_m_o_n_/_h_y_b_r_i_d_u_t_i_l_i_t_i_e_s_._h_h> │ │ │ │ -15#include <_d_u_n_e_/_c_o_m_m_o_n_/_t_y_p_e_t_r_a_i_t_s_._h_h> │ │ │ │ +12 │ │ │ │ +13#include <_d_u_n_e_/_c_o_m_m_o_n_/_s_t_d_/_t_y_p_e___t_r_a_i_t_s_._h_h> │ │ │ │ +14 │ │ │ │ +15 │ │ │ │ 16 │ │ │ │ 17namespace _D_u_n_e { │ │ │ │ 18 │ │ │ │ -23 │ │ │ │ +19 template │ │ │ │ +20 class _F_i_e_l_d_M_a_t_r_i_x; │ │ │ │ +21 │ │ │ │ +22 template │ │ │ │ +23 class _D_y_n_a_m_i_c_M_a_t_r_i_x; │ │ │ │ +24 │ │ │ │ +25} │ │ │ │ +26 │ │ │ │ +27namespace Dune::Impl { │ │ │ │ 28 │ │ │ │ -41 template │ │ │ │ -_4_2 decltype(auto) _a_p_p_l_y_P_a_r_t_i_a_l(F&& f, ArgTuple&& args, std::integer_sequence /*indices*/) │ │ │ │ -43 { │ │ │ │ -44 return f(std::get(args)...); │ │ │ │ -45 } │ │ │ │ -46 │ │ │ │ -47 template │ │ │ │ -_4_8 struct _T_u_p_l_e_A_c_c_e_s_s_T_r_a_i_t_s │ │ │ │ -49 { │ │ │ │ -_5_0 typedef typename std::add_const::type& _C_o_n_s_t_T_y_p_e; │ │ │ │ -_5_1 typedef T& _N_o_n_C_o_n_s_t_T_y_p_e; │ │ │ │ -_5_2 typedef const typename std::remove_const::type& _P_a_r_a_m_e_t_e_r_T_y_p_e; │ │ │ │ -53 }; │ │ │ │ -54 │ │ │ │ -55 template │ │ │ │ -_5_6 struct _T_u_p_l_e_A_c_c_e_s_s_T_r_a_i_t_s │ │ │ │ -57 { │ │ │ │ -_5_8 typedef typename std::add_const::type* _C_o_n_s_t_T_y_p_e; │ │ │ │ -_5_9 typedef T* _N_o_n_C_o_n_s_t_T_y_p_e; │ │ │ │ -_6_0 typedef T* _P_a_r_a_m_e_t_e_r_T_y_p_e; │ │ │ │ -61 }; │ │ │ │ -62 │ │ │ │ -63 template │ │ │ │ -_6_4 struct _T_u_p_l_e_A_c_c_e_s_s_T_r_a_i_t_s │ │ │ │ -65 { │ │ │ │ -_6_6 typedef T& _C_o_n_s_t_T_y_p_e; │ │ │ │ -_6_7 typedef T& _N_o_n_C_o_n_s_t_T_y_p_e; │ │ │ │ -_6_8 typedef T& _P_a_r_a_m_e_t_e_r_T_y_p_e; │ │ │ │ -69 }; │ │ │ │ -70 │ │ │ │ -78 template │ │ │ │ -_7_9 struct _N_u_l_l_P_o_i_n_t_e_r_I_n_i_t_i_a_l_i_s_e_r; │ │ │ │ -80 │ │ │ │ -81 template │ │ │ │ -_8_2 struct _N_u_l_l_P_o_i_n_t_e_r_I_n_i_t_i_a_l_i_s_e_r<_s_t_d::tuple > │ │ │ │ -83 { │ │ │ │ -_8_4 typedef std::tuple _R_e_s_u_l_t_T_y_p_e; │ │ │ │ -_8_5 static _R_e_s_u_l_t_T_y_p_e _a_p_p_l_y() │ │ │ │ -86 { │ │ │ │ -87 return _R_e_s_u_l_t_T_y_p_e(static_cast(nullptr)...); │ │ │ │ -88 } │ │ │ │ -89 }; │ │ │ │ +29 │ │ │ │ +30 // Some traits for checking matrix concepts. Currently these are │ │ │ │ +31 // all technical internal helpers that just serve different headers │ │ │ │ +32 // to do internal checks and are thus collected here. │ │ │ │ +33 │ │ │ │ +34 template │ │ │ │ +35 using IsMatrixHelper = std::void_t()._N(), std:: │ │ │ │ +declval().M())>; │ │ │ │ +36 │ │ │ │ +37 template │ │ │ │ +38 struct IsMatrix : public _D_u_n_e_:_:_S_t_d_:_:_i_s___d_e_t_e_c_t_e_d {}; │ │ │ │ +39 │ │ │ │ +40 // Check if T is a matrix by checking for member functions N() and M(). │ │ │ │ +41 template │ │ │ │ +42 constexpr bool IsMatrix_v = Impl::IsMatrix::value; │ │ │ │ +43 │ │ │ │ +44 │ │ │ │ +45 │ │ │ │ +46 template │ │ │ │ +47 using IsStaticSizeMatrixHelper = std::void_t; │ │ │ │ +48 │ │ │ │ +49 template │ │ │ │ +50 struct IsStaticSizeMatrix : public _D_u_n_e_:_:_S_t_d_:_: │ │ │ │ +_i_s___d_e_t_e_c_t_e_d {}; │ │ │ │ +51 │ │ │ │ +52 // Check if T is a statically sized matrix by checking for static members │ │ │ │ +rows and cols. │ │ │ │ +53 template │ │ │ │ +54 constexpr bool IsStaticSizeMatrix_v = Impl::IsStaticSizeMatrix::value; │ │ │ │ +55 │ │ │ │ +56 │ │ │ │ +57 │ │ │ │ +58 template │ │ │ │ +59 class IsFieldMatrix : public std::false_type {}; │ │ │ │ +60 │ │ │ │ +61 template< class K, int ROWS, int COLS> │ │ │ │ +62 class IsFieldMatrix> : public std:: │ │ │ │ +true_type {}; │ │ │ │ +63 │ │ │ │ +64 // Check if T is an instance of FieldMatrix │ │ │ │ +65 template │ │ │ │ +66 constexpr bool IsFieldMatrix_v = Impl::IsFieldMatrix::value; │ │ │ │ +67 │ │ │ │ +68 │ │ │ │ +69 │ │ │ │ +82 template │ │ │ │ +83 class IsDenseMatrix : public std::false_type {}; │ │ │ │ +84 │ │ │ │ +85 template │ │ │ │ +86 class IsDenseMatrix : public IsDenseMatrix {}; │ │ │ │ +87 │ │ │ │ +88 template │ │ │ │ +89 class IsDenseMatrix> : public std:: │ │ │ │ +true_type {}; │ │ │ │ 90 │ │ │ │ -115 template