Re: [deal.II] Parallized BEM (Step-34)

2024-05-06 Thread Daniel Arndt
Max,

the problem is that GridGenerator::extract_boundary_mesh doesn't
support the volume mesh to be an object of type
parallel::distributed::Triangulation.
This just isn't implemented yet. Do you actually need the input volume
mesh to be distributed?

Best,
Daniel

On Mon, May 6, 2024 at 12:06 PM 'Maximilian Hövener' via deal.II User
Group  wrote:
>
> Dear all,
> in the course of my master thesis at the TU Dortmund I came across Deal.II 
> while searching for a boundary element method. Is it possible to change the 
> BEM explained in Step-34 to use it parallelised?
> I have already tried to make some changes using Step-40. This includes 
> replacing the sparse matrix to a dense matrix using the PETSc library header 
> files. This resulted in the following error message:
>
> An error occurred in line <8242> of file 
> 
>  in function
> std::map::cell_iterator, typename 
> MeshType::face_iterator> 
> dealii::GridGenerator::extract_boundary_mesh(const MeshType&, 
> MeshType<(dim - 1), spacedim>&, const std::set&) [with MeshType 
> = dealii::parallel::distributed::Triangulation; int dim = 3; int spacedim = 
> 3; typename MeshType::face_iterator = 
> dealii::TriaIterator >; typename MeshType<(dim 
> - 1), spacedim>::cell_iterator = dealii::TriaIterator 3> >]
> The violated condition was:
> (dynamic_cast< const parallel::distributed::Triangulation 
> *>( _mesh.get_triangulation()) == nullptr)
> Additional information:
> You are trying to use functionality in deal.II that is currently not
> implemented. In many cases, this indicates that there simply didn't
> appear much of a need for it, or that the author of the original code
> did not have the time to implement a particular case. If you hit this
> exception, it is therefore worth the time to look into the code to
> find out whether you may be able to implement the missing
> functionality. If you do, please consider providing a patch to the
> deal.II development sources (see the deal.II website on how to
> contribute).
>
> I am asuming that the problem results because of the use of the manifold, 
> which is not embedded with parallelisation.
>
> Best regards,
> Max
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see 
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups 
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/dealii/13ba53e8-2959-42f7-9c11-f7abe5046fb6n%40googlegroups.com.

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKMvef-qBWj7tt%2BHZJwdGWq%3DaRhaBHTG-iRvW3xm%3DUzeA%40mail.gmail.com.


Re: [deal.II] Output domain id for different parts of the domain

2024-04-29 Thread Daniel Arndt
Chen,

Have a look at how the subdomain id is added to the output results in
step-40 
(https://www.dealii.org/current/doxygen/deal.II/step_40.html#LaplaceProblemoutput_results).

Best,
Daniel

On Mon, Apr 29, 2024 at 9:23 AM 陈敏  wrote:
>
> Dear all
>
> I'm dealing with a fluid-structure interaction problem, and I want ot output 
> the domain id to the cell to the vtk/vtu result files. By the way, 
> partitioning the fluid and solid domain by the id can be very convenient in 
> paraview. But I don't know how to output the domain id when using dealii. 
> Could anyone help me?
>
>
> Best regards
> Chen
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see 
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups 
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/dealii/CADr3OdJcgOW8VfxzUwPS01zsGuT%2BkKy6-UiPnR66XAeij%2B0R0g%40mail.gmail.com.

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BAqrb6nDE1wf0K0P9q4D7AgmmW0NjZ4q26%2BJ4kSGcLEQ%40mail.gmail.com.


Re: [deal.II] There are some mistake about the function ”GridTools::collect_periodic_faces()"

2024-04-17 Thread Daniel Arndt
I meant

#include 

Best,
Daniel

Daniel Arndt

8:43 AM (0 minutes ago)


to dealii

On Wed, Apr 17, 2024 at 8:43 AM Daniel Arndt  wrote:
>
> You will have to include
>
> #include 
>
> Best,
> Daniel
>
> On Wed, Apr 17, 2024 at 7:21 AM Xue Yu  wrote:
> >
> > Dear deal.ii community,
> >
> > first of all, a big thank you for all the effort going into this
> > software.
> > With reference to step-45, I am solving the homogenization problem with 
> > dealii software.
> > After drawing a grid for a 3D cuboid cell, a periodic boundary condition 
> > with equal displacement of opposite sides is created. My version of dealii 
> > is 9.4.0
> > But i meet an error while make run as following:
> > error: ‘collect_periodic_faces’ is not a member of ‘dealii::GridTools
> > And my code is attached. I've already added the corresponding header file, 
> > so why do I still have this problem? Could you please give me a debug 
> > direction?
> >
> > --
> > The deal.II project is located at http://www.dealii.org/
> > For mailing list/forum options, see 
> > https://groups.google.com/d/forum/dealii?hl=en
> > ---
> > You received this message because you are subscribed to the Google Groups 
> > "deal.II User Group" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to dealii+unsubscr...@googlegroups.com.
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msgid/dealii/4ad2f5e1-1015-44fb-8309-cf10166e1a55n%40googlegroups.com.

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BfowryaxicNCLmRZhodsdC8MCypRpJshB%3DOav9-nMs9g%40mail.gmail.com.


Re: [deal.II] There are some mistake about the function ”GridTools::collect_periodic_faces()"

2024-04-17 Thread Daniel Arndt
You will have to include

#include 

Best,
Daniel

On Wed, Apr 17, 2024 at 7:21 AM Xue Yu  wrote:
>
> Dear deal.ii community,
>
> first of all, a big thank you for all the effort going into this
> software.
> With reference to step-45, I am solving the homogenization problem with 
> dealii software.
> After drawing a grid for a 3D cuboid cell, a periodic boundary condition with 
> equal displacement of opposite sides is created. My version of dealii is 9.4.0
> But i meet an error while make run as following:
> error: ‘collect_periodic_faces’ is not a member of ‘dealii::GridTools
> And my code is attached. I've already added the corresponding header file, so 
> why do I still have this problem? Could you please give me a debug direction?
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see 
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups 
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/dealii/4ad2f5e1-1015-44fb-8309-cf10166e1a55n%40googlegroups.com.

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJ9AQ%3DMgmfh-SyKFDsQDnMLbhWH%2BXQzWLmE3KJ%2BmX685A%40mail.gmail.com.


Re: [deal.II] gridin.read_exodusii to import exodusii mesh in dealii 9.5.1 fails

2024-03-29 Thread Daniel Arndt
Sina,

You'll have to provide the path directly as a function argument, i.e.,

gridin.read_exodusii(case_path + "mesh.exo");

Best,
Daniel


On Fri, Mar 29, 2024 at 7:32 AM Sina Tajfirooz  wrote:
>
> Dear developers/users,
>
> How can I import an exodusii mesh in dealii version 9.5.1, which is 
> configured with Trilinos?
>
> doing
>
> "
> gridin.attach_triangulation(triangulation);
> std::ifstream f(case_path + "mesh.exo");
> gridin.read_exodusii(f);
>
> "
>
> raises the error:
> "
>  error: no matching function for call to 
> ‘dealii::GridIn<3>::read_exodusii(std::ifstream&)’
>  gridin.read_exodusii(f);
> "
>
> How can I resolve this?
>
> Best,
> Sina
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see 
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups 
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/dealii/2ea642fb-b3fb-480f-88e7-2b2c96a264e2n%40googlegroups.com.

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbLCgzFuxzVoxMf_q14LkXO_Z0BuO1cDph2paeaE%2BrELmw%40mail.gmail.com.


Re: [deal.II] Possible typo in step 26 tutorial

2024-03-22 Thread Daniel Arndt
Kyle,

Why don't you just submit a pull request for this fix?

Best,
Daniel

On Fri, Mar 22, 2024 at 9:10 AM Kyle Schwiebert  wrote:

> Hello,
>
> I'm sorry for not just mentioning this on github. If I'm honest I wasn't
> sure of the procedure for such a small change. I think there is a typo in: The
> deal.II Library: The step-26 tutorial program (dealii.org)
> .
> Regarding the first test case in "What could possibly go wrong?" it seems
> that the coefficient on a(t) should be +1 rather than -1 (or the initial
> condition should be a(0) = -1).
>
> Regards,
> Kyle
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/ad2938d8-e04f-4695-a2e0-1668ae67b4f9n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJsiDfJdn9OLEemJ77y8NzrR4upqYYJyTC%2BzEC-cZn1rg%40mail.gmail.com.


Re: [deal.II] [Assigning boundary condition to node]

2024-02-22 Thread Daniel Arndt
Can specify what you mean by "assign a certain BC [boundary condition] to a
node"? Typically boundary conditions only make sense on the boundary of a
mesh with codimension 1 (embedded in the same physical space).
Thus, you would only consider setting boundary conditions on a node/point
(0-dimensional) if you are dealing with a 1d-mesh.
You can, of course, just add a constraint for a specific degree of freedom
in your AffineConstraints object, also see step-11.

Best,
Daniel

On Thu, Feb 22, 2024 at 1:14 PM veerendra koilakuntla <
veerendrak...@gmail.com> wrote:

> Dear community,
>
> Is there a way to assign a certain BC to a node? Or are we stiĺl
> struggling a lot to do this in deal.ii?
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/CAHd4K04CVnai-H7pt%3DnyBPm9tQQ3XV%3DGvFNGd8%3Dxog9qpqJgWg%40mail.gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJmc_e2JmVdiJrO5%2B6i2RZEoxXWELccEepS7jmyGNc7hg%40mail.gmail.com.


Re: [deal.II] Re: Can't configure with cmake

2024-02-07 Thread Daniel Arndt
Sean,

that problem doesn't sound specific to compiling with Kokkos+Cuda. Can you
make sure to start from a clean work directory and again select
`nvcc_wrapper` as compiler?

Best,
Daniel

On Tue, Feb 6, 2024 at 6:26 PM Sean Johnson  wrote:

> Bruno,
>
> I apparently spoke to soon. It passed "make test" with 0 failed test.
> However, when I run "cmake ." in the directory of step-1 I get this output:
>
>
> -- Using the deal.II-9.5.2 installation found at /usr/local
> -- Include macro
> /usr/local/share/deal.II/macros/macro_deal_ii_add_test.cmake
> -- Include macro
> /usr/local/share/deal.II/macros/macro_deal_ii_initialize_cached_variables.cmake
> -- Include macro
> /usr/local/share/deal.II/macros/macro_deal_ii_invoke_autopilot.cmake
> -- Include macro
> /usr/local/share/deal.II/macros/macro_deal_ii_pickup_tests.cmake
> -- Include macro
> /usr/local/share/deal.II/macros/macro_deal_ii_query_git_information.cmake
> -- Include macro
> /usr/local/share/deal.II/macros/macro_deal_ii_setup_target.cmake
> -- Include macro
> /usr/local/share/deal.II/macros/macro_shell_escape_option_groups.cmake
> -- Include macro
> /usr/local/share/deal.II/macros/macro_target_compile_flags.cmake
> -- Include macro
> /usr/local/share/deal.II/macros/macro_target_link_flags.cmake
> -- Autopilot invoked
> -- Run   $ make info  to print a detailed help message
> -- Configuring done
> CMake Error in CMakeLists.txt:
>   Imported target "dealii::dealii_debug" includes non-existent path
>
> "/usr/local/include/deal.II/bundled"
>
>   in its INTERFACE_INCLUDE_DIRECTORIES.  Possible reasons include:
>
>   * The path was deleted, renamed, or moved to another location.
>
>   * An install or uninstall procedure did not complete successfully.
>
>   * The installation package was faulty and references files it does not
>   provide.
>
>
>
> -- Generating done
> CMake Generate step failed.  Build files cannot be regenerated correctly.
>
>
>
> Then when I try "make" I get this:
>
>
>
> [ 33%] Building CXX object CMakeFiles/step-1.dir/step-1.cc.o
> In file included from /usr/local/include/deal.II/grid/tria.h:20,
>  from /home/sean/dealii-9.5.2/examples/step-1/step-1.cc:22:
> /usr/local/include/deal.II/base/config.h:588:12: fatal error: mpi.h: No
> such file or directory
>   588 | #  include 
>   |^~~
> compilation terminated.
> make[3]: *** [CMakeFiles/step-1.dir/build.make:76:
> CMakeFiles/step-1.dir/step-1.cc.o] Error 1
> make[2]: *** [CMakeFiles/Makefile2:90: CMakeFiles/step-1.dir/all] Error 2
> make[1]: *** [CMakeFiles/Makefile2:123: CMakeFiles/run.dir/rule] Error 2
> make: *** [Makefile:137: run] Error 2
>
> I am currently recompiling with fewer jobs to see if any errors pop up or
> if recompiling might help.
>
> Thanks,
> Sean
>
> On Tuesday, February 6, 2024 at 3:17:42 PM UTC-7 bruno.t...@gmail.com
> wrote:
>
>> Sean,
>>
>> That's great to hear. We don't mark problems as solved. So there is
>> nothing to do.
>>
>> Best,
>>
>> Bruno
>>
>> Le mar. 6 févr. 2024 à 16:41, Sean Johnson  a écrit :
>>
>>> Thanks again!
>>>
>>> The using a newer version of Boost helped me get further and realize I
>>> made another bone headed mistake of compiling kokkos as a static library.
>>>
>>> I am all compiled and passed all tests now.
>>>
>>> Thanks for your help and let me know if I have to do anything for this
>>> to be marked as solved.
>>>
>>> Best,
>>> Sean
>>>
>>> On Tuesday, February 6, 2024 at 8:30:19 AM UTC-7 bruno.t...@gmail.com
>>> wrote:
>>>
 Sean,

 I am not sure what's the issue. It's probably not the issue but make
 sure that mpi is using nvcc_wrapper as the underlying compiler. If you use
 OpenMPI, you can use export `OMPI_CXX=nvcc_wrapper`. You could also try to
 use a newer version of Boost. The bundled version is pretty old. Since you
 are using Ubuntu 22.04, you can just use your package manager to install a
 newer version of boost.

 Best,

 Bruno

 Le mar. 6 févr. 2024 à 09:37, Sean Johnson  a
 écrit :

> Thanks,
>
> I tried lowering it down to 2 and it looks like two of them were
> caught a lot earlier. Now I don't make it past 6%. I erased everything 
> from
> before and recompiled the cmake files and ran with just 2 jobs and again 
> it
> stuck in the same spot.
>
> Here are the last few lines and logs.
>
> [  6%] Building CXX object
> bundled/boost-1.70.0/libs/iostreams/src/CMakeFiles/bundled_boost_iostreams_debug.dir/gzip.cpp.o
> /home/sean/dealii-9.5.2/bundled/boost-1.70.0/libs/iostreams/src/../../../include/boost/mpl/assert.hpp:193:42:
> warning: unnecessary parentheses in declaration of ‘assert_arg’
> [-Wparentheses]
>   193 | template< typename Pred >
>   |  ^
>
> /home/sean/dealii-9.5.2/bundled/boost-1.70.0/libs/iostreams/src/../../../include/boost/mpl/assert.hpp:193:42:
> note: remove parentheses
>   

Re: [deal.II] cmake configure does not find cgal

2024-01-23 Thread Daniel Arndt
What happens if you configure with CGAL_DIR=
/home/spack/opt/spack/linux-opensuse15-broadwell/gcc-12.3.0/cgal-5.5.2-6umjskepmayihkexoscjiovjmtgo5toy/lib64/cmake/CGAL
?

Best,
Daniel

On Sun, Jan 14, 2024 at 4:14 AM Praveen C  wrote:

> CGALConfig.cmake is present
>
> *$ ls -l `spack location -i cgal`/lib64/cmake/CGAL/CGALConfig**
> -rw-r--r-- 1 praveen 8.5K Jun 13  2022
> /home/spack/opt/spack/linux-opensuse15-broadwell/gcc-12.3.0/cgal-5.5.2-6umjskepmayihkexoscjiovjmtgo5toy/lib64/cmake/CGAL/
> CGALConfig_binary.cmake.in
> -rw-r--r-- 1 praveen  144 Jun 13  2022
> /home/spack/opt/spack/linux-opensuse15-broadwell/gcc-12.3.0/cgal-5.5.2-6umjskepmayihkexoscjiovjmtgo5toy/lib64/cmake/CGAL/
> CGALConfig_binary_header_only.cmake.in
> -rw-r--r-- 1 praveen   28 Feb 25  2023
> /home/spack/opt/spack/linux-opensuse15-broadwell/gcc-12.3.0/cgal-5.5.2-6umjskepmayihkexoscjiovjmtgo5toy/lib64/cmake/CGAL/CGALConfigBuildVersion.cmake
> -rw-r--r-- 1 praveen 6.3K Nov 26  2022
> /home/spack/opt/spack/linux-opensuse15-broadwell/gcc-12.3.0/cgal-5.5.2-6umjskepmayihkexoscjiovjmtgo5toy/lib64/cmake/CGAL/CGALConfig.cmake
> -rw-r--r-- 1 praveen 8.4K Jun 13  2022
> /home/spack/opt/spack/linux-opensuse15-broadwell/gcc-12.3.0/cgal-5.5.2-6umjskepmayihkexoscjiovjmtgo5toy/lib64/cmake/CGAL/
> CGALConfig_install.cmake.in
> -rw-r--r-- 1 praveen  158 Jun 13  2022
> /home/spack/opt/spack/linux-opensuse15-broadwell/gcc-12.3.0/cgal-5.5.2-6umjskepmayihkexoscjiovjmtgo5toy/lib64/cmake/CGAL/
> CGALConfigVersion_binary_header_only.cmake.in
> -rw-r--r-- 1 praveen  951 Oct 15  2022
> /home/spack/opt/spack/linux-opensuse15-broadwell/gcc-12.3.0/cgal-5.5.2-6umjskepmayihkexoscjiovjmtgo5toy/lib64/cmake/CGAL/CGALConfigVersion.cmake
>
> Thanks
> praveen
>
> On Saturday, January 6, 2024 at 3:54:09 AM UTC+5:30 d.arnd...@gmail.com
> wrote:
>
> What about CGALConfig.cmake? A CMake project installation should provide
> that.
>
> Best,
> Daniel
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/32907406-7360-4146-8c1c-2554b848ab66n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2B2Hez4dv%2BC0Ghrq08tQ207tOJ9gU9QEofPOn08R4HYZw%40mail.gmail.com.


Re: [deal.II] Shape gradients of (f(x)*\phi_i)

2024-01-23 Thread Daniel Arndt
Abbas,

\dfrac{\partial f(x) \phi_i}{\partial x} is just \dfrac{\partial
f(x)}{\partial x} \phi_i+f(x)\dfrac{f(x)}{\partial x} which I would use.
There is no need to integrate by parts.

Best,
Daniel

On Tue, Jan 23, 2024 at 2:37 PM Abbas Ballout 
wrote:

> I know I can query the standard shape gradient at a quadrature point with  
> fe_values.shape_grad(i,
> q).
> Is it possible to query for something like the gradient of the shape
> function multiplied by another function? I need \dfrac{\partial f(x)
> \phi_i}{\partial x} but I don't want to integrate by parts.
>
> Abbas
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/64e24fc5-9876-4e34-97c4-ba6bc77d22a4n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BpXJ3F%2Bs7MS7vEpoka4mcPscAPxpkRM_yrpQz6QU%3DXHw%40mail.gmail.com.


Re: [deal.II] cmake configure does not find cgal

2024-01-05 Thread Daniel Arndt
What about CGALConfig.cmake? A CMake project installation should provide
that.

Best,
Daniel

On Fri, Jan 5, 2024 at 11:09 AM Praveen C 
wrote:

> I think deal.II is supposed to provide FindCGAL.cmake, there is no such
> file inside cgal.
>
> Thanks
> praveen
>
> On 05-Jan-2024, at 8:16 PM, Daniel Arndt  wrote:
>
> It seems like the spark installation doesn't provide FindCGAL.cmake or at
> least not in the path that you provide as CGAL_DIR.
> Can you try finding that file and (if it exists) setting the respective
> directory as CGAL_DIR?
>
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/7A4450E8-2B8F-4498-A84C-643D1666146A%40gmail.com
> <https://groups.google.com/d/msgid/dealii/7A4450E8-2B8F-4498-A84C-643D1666146A%40gmail.com?utm_medium=email_source=footer>
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbK5iZ3-4Xr%2BK2u%3DbT7rCw-u2BV5Shu4iLUcUj8p0LnPPA%40mail.gmail.com.


Re: [deal.II] cmake configure does not find cgal

2024-01-05 Thread Daniel Arndt
It seems like the spark installation doesn't provide FindCGAL.cmake or at
least not in the path that you provide as CGAL_DIR.
Can you try finding that file and (if it exists) setting the respective
directory as CGAL_DIR?

Best,
Daniel

On Fri, Jan 5, 2024 at 9:37 AM timo Hyvärinen 
wrote:

> hi, praveen
>
> I think spack did cause something went wrong, building deal.ii with cgal
> without spack may be a good way.
>
> bset,
> Tim
>
> On Fri, Jan 5, 2024 at 4:25 PM Praveen C 
> wrote:
>
>> So this error
>>
>> On 05-Jan-2024, at 7:28 PM, Praveen C  wrote:
>>
>> [100%] Built target step-1
>> $ ./step-1
>> step-1: malloc.c:2382: sysmalloc: Assertion `(old_top == initial_top (av)
>> && old_size == 0) || ((unsigned long) (old_size) >= MINSIZE && prev_inuse
>> (old_top) && ((unsigned long) old_end & (pagesize - 1)) == 0)' failed.
>> Aborted (core dumped)
>>
>>
>> happens even if I compile dealii without cgal.
>>
>> I upgraded os/compilers few days back.
>>
>> Thanks
>> praveen
>>
>> --
>> The deal.II project is located at http://www.dealii.org/
>> For mailing list/forum options, see
>> https://groups.google.com/d/forum/dealii?hl=en
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "deal.II User Group" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to dealii+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/dealii/C0D09D96-F25C-449C-BC05-BA3610F92711%40gmail.com
>> 
>> .
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/CAArwj0ELE3Oxc2oo0Wy0b4_78Q_0573rp1T51vPHG%2Bgm95zy3g%40mail.gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbLDiey5M9xvYPyK8NMuG89Wj%2BQYROo65JyPGKnnVNXzjg%40mail.gmail.com.


Re: [deal.II] Reporting issue with repo

2023-12-05 Thread Daniel Arndt
Alex,

grid_reordering,h was removed in
https://github.com/dealii/dealii/commit/fd0c356263d7115ebf58fcea15d0412a32da199e
(which isn't part of any release yet).

Best,
Daniel

On Tue, Dec 5, 2023 at 7:47 AM Alex Quinlan 
wrote:

> Dear deal.ii devs,
>
> I cloned the deal.ii repo yesterday and found that the header file
> grid_reorder.h has been removed from include/deal.II/grid/.
>
> I searched the logs and the documentation and it appeared that the file
> *should* still be there, though I'm not 100% sure of that.
>
> I am not very savvy with git, so I thought I would just post here.  Is
> this the correct place to make this kind of report, or is there a preferred
> process that I should take in the future?
>
> Thanks,
> Alex
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/3c1a7409-a834-4fed-b1b5-48caa5de7a69n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJ%3DWQmKZ5f8C2iQRv2ge5JMryiDK3U%2B%2BbSRiNj%3DoVyJcQ%40mail.gmail.com.


Re: [deal.II] How to find the cell index by using global dof index

2023-12-04 Thread Daniel Arndt
Lance,

Have a look at GridTools::vertex_to_cell_map(
https://www.dealii.org/current/doxygen/deal.II/namespaceGridTools.html#a9b7e2ca8ecd26a472e5225ba91a58acb
).

Best,
Daniel

On Sun, Dec 3, 2023 at 11:38 PM Lance Zhang  wrote:

> Hello team,
>
> may I know how to find the cell index with the information of its global
> Dofs index?
>
> I have the global dofs index ,I would like to find which cell this global
> dof belongs to.
>
> Thanks in advance!
> Best regards
> Lance
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/4453e03d-2511-43c4-a05d-71e695a9276cn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJLsBk2D45tHF4grTeHT%3DejkqQqXMtkLBqB1K-b%3DHbh%2BA%40mail.gmail.com.


Re: [deal.II] How to find the neighbor of one cell

2023-11-29 Thread Daniel Arndt
Lance,

You would check for the cell being at a boundary first before asking for
its neighbor:

// Loop over all neighboring cells
for (unsigned int f = 0; f < cell->n_faces(); ++f)
{
if (cell->at_boundary(f))
  continue;
auto neighbor = cell->neighbor(f);
int neighbor_index = neighbor->active_cell_index();//get the
global index of the cell if it exists
[...]


Best,
Daniel

On Wed, Nov 29, 2023 at 9:43 AM Lance Zhang  wrote:

> Hello Wolfgang,
>
> thanks for your message.
>
> May I know which method or keywords can be used to stand for the
> non-existing cell and could I use cell->at_boundary() to check whether
> the cell exists or not?
>
> I would like to know how we can identify if the object
> of dealii::IteratorRange 3, false> > >::IteratorOverIterators does not exist. I have tried ==NULL
> and nullptr, however, it doe snot work.
>
> There is the code snippet below, please take a look:
>
>  for (const auto  : solid_3d.dof_handler_ref.active_cell_iterators())
>   {
>
> if(cell->at_boundary()){
>   continue;
>   }//to check whether the cell exists
>
>   const unsigned int cell_index = cell->active_cell_index();
>
>   if (visited_cells[cell_index])
>  continue; // Skip if the cell has been visited by its all
> neighbors
>
> // Loop over all degrees of freedom on the current cell
> for (unsigned int i = 0; i < solid_3d.dofs_per_cell; ++i)
>   {
>
> // Loop over all neighboring cells
> for (unsigned int f = 0; f < cell->n_faces(); ++f)
> {
> auto neighbor = cell->neighbor(f);//find the neighbor ,but not
> sure if it exists
>
> if(neighbor->at_boundary())
> continue;//check if the neighbor of cell exists
> int neighbor_index = neighbor->active_cell_index();//get the
> global index of the cell if it exists
> ...
>
> The whole code can be found via the link :
> https://github.com/Lancelof2019/cook_membrane_snippet/blob/main/code_snippet.cpp
>
> Thanks in advance!
>
> Best regards
> Lance
>
> Wolfgang Bangerth  于2023年11月28日周二 01:54写道:
>
>>
>> On 11/27/23 14:52, Lance Zhang wrote:
>> >
>> > May I know how to find the neighbor of a cell?
>> >
>> > Here is one part of my code:
>> >
>> --
>> > for (const auto  :
>> solid_3d.get_dof_handler().active_cell_iterators()
>> > {
>> >  const unsigned int cell_index = cell->active_cell_index();
>> >
>> >  // Loop over all degrees of freedom on the current cell
>> >  for (unsigned int i = 0; i < dofs_per_cell.dofs_per_cell; ++i)
>> >  {
>> >  // Loop over all neighboring cells
>> >  for (const auto  : Find_neighbors?)){
>>
>> You can write this as
>>for (unsigned int f=0; fn_faces(); ++f)
>>{
>>  DoFHandler::cell_iterator neighbor = cell->neighbor(f);
>>  ...
>>}
>>
>> Best
>>   W.
>>
>> --
>> The deal.II project is located at http://www.dealii.org/
>> For mailing list/forum options, see
>> https://groups.google.com/d/forum/dealii?hl=en
>> ---
>> You received this message because you are subscribed to a topic in the
>> Google Groups "deal.II User Group" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/dealii/XYNlOZYskis/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> dealii+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/dealii/ef1fdaad-0bde-4478-8054-74df1a572c5f%40colostate.edu
>> .
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/CADwW6P%3Dy7uJAdD5q8DwpUnK-3iQBgTnVh5ioi-Pr62w54D0ikw%40mail.gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbL757Zyb9kWNGCUhKDJ38qaVKCt%2BN%2Bq%3Dk46vcdpJ0GUWA%40mail.gmail.com.


Re: [deal.II] Re: merge_triangulation error

2023-11-20 Thread Daniel Arndt
Vinayak,

Would you have a minimal reproducer?

Best,
Daniel

On Mon, Nov 20, 2023 at 4:13 AM Vinayak Vijay  wrote:

> Hello,
>
> I also tried to do the same using the 
> GridGenerator::replicate_triangulation(triangulation1,{2},triangulation2)
> function. This should result in a triangulation (triangulation1) to be
> repeated in the three-coordinate axis two times. However, it results in the
> same error.
> Please note that the triangulations are with dim=1 and spacedim=2.
>
> I am not sure where things are going wrong. Could someone help me with
> this?
>
> Thanks
> Vinayak
> On Thursday, November 16, 2023 at 10:05:11 AM UTC+1 Vinayak Vijay wrote:
>
>> Hello,
>>
>> I am trying to merge two triangulations into a single one. However, I am
>> getting the following error:
>>
>> An error occurred in line <11736> of file
>> 
>> in function
>> void dealii::Triangulation<, 
>> >::create_triangulation(const std::vector >&, const
>> std::vector >&, const dealii::SubCellData&) [with int
>> dim = 1; int spacedim = 3]
>> The violated condition was:
>> !(correct(i, j) ^ (neighbor->direction_flag() ==
>> (*cell)->direction_flag()))
>> Additional information:
>> (none)
>>
>> I am using the dealii 9.4.0 version.
>>
>> I have attached the two triangulations that need to be merged and the .cc
>> file to reproduce the error.
>> Can someone help me with this?
>>
>> Thanks
>> Vinayak
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/a9aaa852-3ad8-40c7-a0db-87d339c37cb2n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2Bd64qzgRiM1r9Ht8aUVDO-YEpfRjqr6zdb7UkKiY8bNw%40mail.gmail.com.


Re: [deal.II] how to treat the intersection point at the first and second kined bcs

2023-11-14 Thread Daniel Arndt
Dirichlet boundary conditions are normally enforced strongly while Neumann
boundary conditions are enforced weakly.
Thus, when interpolating the Dirichlet boundary conditions on the
respective boundary you would set the degrees of freedom accordingly
while the Neumann boundary conditions are part of the weak formulation.

Best,
Daniel

On Mon, Nov 13, 2023 at 11:20 PM ztdepyahoo  wrote:

> I mean one boundary has the first kind bc, while the second has neumann
> bc.  so What is the bc for the intersection nodes.
>
> ztdepyahoo
> ztdepya...@gmail.com
>
> 
>  Replied Message 
> From ztdep...@gmail.com 
> Date 11/13/2023 13:48
> To deal.II User Group 
> Subject [deal.II] how to treat the intersection point at the first and
> second kined bcs
> Since the two kinds of bc has one common nodes. I want to know which one
> is impelented in idealii.
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "deal.II User Group" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/dealii/7T3v6ddmVa0/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/1add8537-743b-4b7e-bf50-96000b03f2e3n%40googlegroups.com
> 
> .
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/D9FD7D20-38AC-480D-B980-3ECC4ACEF267%40gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKyLrivRTVtk3gkNtEzJEY9T5okRCctsaB6BaBkkPsJew%40mail.gmail.com.


Re: [deal.II] how to use const std::function< T(const T &, const T &)> & combiner

2023-11-02 Thread Daniel Arndt
It's simply a function that takes two arguments of the same type by
reference and returns a new value of that type.
For a sum reduction using doubles, you could pass in in a lambda, for
example:

[](const double& a, const double& b) {return a+b;}

Best,
Daniel

On Thu, Nov 2, 2023 at 9:03 AM ztdep...@gmail.com 
wrote:

> I want to use the mpi::all_reduce to add some values from every processes.
> but i don't know how to set the "const std::function< T(const T &, const T
> &)> &   combiner".
> Could you please give me some help about it?
>
>  Utilities::MPI::all_reduce ( const T &   local_value,
> const MPI_Comm &   comm,
> const std::function< T(const T &, const T &)> &   combiner
> )
>
> const std::function< T(const T &, const T &)> &   combiner
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/801ac1c2-cc05-490d-8683-e55613e655fen%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BK6D652ZxuMR85i3KPrEvN2tmK0GTheNr-KhtCTJ1egg%40mail.gmail.com.


Re: [deal.II] Mixed codimensionality

2023-10-27 Thread Daniel Arndt
Alex,

If you can formulate your problem/approach in a way (iteratively?) that you
could solve separately on the three triangulations (using input from the
solution on the other triangulations), that might be easier.
On the other hand, if you only want one system matrix you would identify
matching dofs manually and merge the system matrices manually.
Maybe, someone else has better ideas and more experience than me. I'm still
curious how your full weak form looks like.

Best,
Daniel


On Fri, Oct 27, 2023 at 1:42 PM Alex Quinlan 
wrote:

> Hi Daniel,
>
> Thanks for the response.  I am essentially using the approach in Step-8,
> where I am seeking a vector-valued displacement solution using FE_System.
> So, I've been using:
>
> dealii::FESystem<3>(FE_Q<3>(1), 3 )
> and
> dealii::FESystem<2,3>(FE_Q<2,3>(1), 3 )
>
>
> Based on your suggestion, I am picturing doing something like this:
>
> // Shared Objects
> AffineConstraints constraints;
> SparsityPatternsparsity_pattern;
> SparseMatrix system_matrix;
> Vector solution;// This is the solution vector
> Vector system_rhs;  // This is the load / right-hand-side vector
>
> // Dimension dependent objects
> // 3D
> Triangulation<3,3>   triangulation_3D;
> DoFHandler<3,3>  dof_handler_3D;
> FESystem<3,3>fe_3D;
>
> // 2D
> Triangulation<2,3>   triangulation_2D;
> DoFHandler<2,3>  dof_handler_2D;
> FESystem<2,3>fe_2D;
>
> // 1D
> Triangulation<1,3>   triangulation_1D;
> DoFHandler<1,3>  dof_handler_1D;
> FESystem<1,3>fe_1D;
>
> Then I need to proceed with each of these triangulations, and *somehow*
> link them together within the system_matrix and system_rhs.
>
> I have been building the system matrix using this line for each cell in
> the dof_handler.active_cell_iterators:
>
> constraints.distribute_local_to_global(  cell_matrix, cell_rhs,
> local_dof_indices,
>  system_matrix, system_rhs);
>
> I see two challenges using this:
> 1)  keeping track of the dof_indices across 3 dof_handlers so they can be
> added to the correct place in the system_matrix
> 2) Connecting the triangulations within the system matrix.
>
>
> Have I understood your suggestion correctly?  Do you forsee any other
> challenges?
>
> Thanks very much,
> Alex
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/7b15f86c-0069-42c9-b7ed-4bde752ee07bn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJ4%3DYfq4F3mwEf8co64Gs__dqFu8oTBGofTnr3dxKE8Mg%40mail.gmail.com.


Re: [deal.II] Mixed codimensionality

2023-10-27 Thread Daniel Arndt
Alex,

FiniteElements in deal.II are used with a Triangulation and DoFHandler of
the same dimension and space dimension.
>From your sketch, it seems like the Triangulation for your 3 types of
finite elements is (expectedly) different. Thus, it doesn't make much sense
to combine those in a FESystem.
It's probably better to define three separate Triangulations and use the
respective finite element classes for them. The tricky would likely be
getting the constraints between them right.
What does your weak form look like anyway?

Best,
Daniel

On Fri, Oct 27, 2023 at 11:13 AM Alex Quinlan 
wrote:

> Dear all,
>
> I've been working with deal.ii in the solid mechanics field for both 3D
> and 2D cases.
> I am now being asked by my colleagues to develop a model that can combine
> elements of different dimensionality.  This is approach is already
> implemented in my colleagues' abaqus models, and so we're looking to
> replicate the functionality in deal.ii.
>
> The elements to be combined would be FE_System elements of type:
> - 3D volumetric element in 3D space 
> - 2D planar element in 3D space 
> - 1D linear element in 3D space 
>
> I've attached a sketch of an application that might use this.
>
> From what I've seen, deal.ii does not like to mix 's.  Does anyone
> have thoughts on how I might go about implementing a model with these
> elements?  If I need to modify or implement new functionalities, could you
> estimate the magnitude of time required to make changes? (i.e. days, weeks,
> months)
>
> I realize that there are alternative methods to represent the physical
> system that could avoid this problem.  However, I am essentially being
> asked to automate the conversion from existing abaqus input files into
> deal.ii.  I appreciate any ideas you all might have.
>
> Thanks,
> Alex
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/a7ff55e9-b406-403b-b176-75690c2d121en%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKx-ju%2BJpJMcdW3Amtg2-NCEFU05Pm_uEtq8wJyqSW4DA%40mail.gmail.com.


Re: [deal.II] Compilation of deal.II fails due to conversion error from std::complex to double

2023-10-15 Thread Daniel Arndt
Roland,

Using PETSc with complex values is pretty niche and there isn't much CI in
place for this case.
It looks like

  boost::serialization::array_wrapper wrapper(

should be replaced with

  boost::serialization::array_wrapper wrapper(

and similarly in VectorBase::load.

Best,
Daniel

On Sat, Oct 14, 2023 at 1:01 PM 'develo...@googlemail.com' via deal.II User
Group  wrote:

> Hei,
> I'm currently trying to compile deal.II on my local machine, but encounter
> the following compilation error:
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> *[  0%] Built target expand_instantiations_exe[  0%] Built target
> doxygen_headers[  0%] Built target object_arborx_inst[  0%] Built target
> object_arborx_debug[  4%] Built target object_numerics_instConsolidate
> compiler generated dependencies of target object_numerics_debug[  4%]
> Building CXX object
> source/numerics/CMakeFiles/object_numerics_debug.dir/unity_0.cc.oIn file
> included from
> /home/user/Downloads/git-files/dealii/build/source/numerics/unity_0.cc:5:In
> file included from
> /home/user/Downloads/git-files/dealii/source/numerics/data_out.cc:16:In
> file included from
> /home/user/Downloads/git-files/dealii/include/deal.II/base/work_stream.h:20:In
> file included from
> /home/user/Downloads/git-files/dealii/build/include/deal.II/base/config.h:584:/home/user/Downloads/git-files/dealii/include/deal.II/base/numbers.h:533:12:
> warning: explicit comparison with NaN in fast floating point mode
> [-Wtautological-constant-compare]return std::isnan(x);
>  ^In file included from
> /home/user/Downloads/git-files/dealii/build/source/numerics/unity_0.cc:10:In
> file included from
> /home/user/Downloads/git-files/dealii/source/numerics/dof_output_operator.cc:23:In
> file included from
> /home/user/Downloads/git-files/dealii/include/deal.II/lac/petsc_block_vector.h:27:In
> file included from
> /home/user/Downloads/git-files/dealii/include/deal.II/lac/petsc_vector.h:29:/home/user/Downloads/git-files/dealii/include/deal.II/lac/petsc_vector_base.h:1324:55:
> error: no matching constructor for initialization of
> 'boost::serialization::array_wrapper'
> boost::serialization::array_wrapper wrapper(
>
> ^/media/storage/local_opt/boost/include/boost/serialization/array_wrapper.hpp:46:5:
> note: candidate constructor not viable: no known conversion from 'const
> PetscScalar *' (aka 'const complex *') to 'const double *' for 1st
> argumentarray_wrapper(T * t, std::size_t s) :
> ^/media/storage/local_opt/boost/include/boost/serialization/array_wrapper.hpp:41:5:
> note: candidate constructor not viable: requires single argument 'rhs', but
> 2 arguments were providedarray_wrapper(const array_wrapper & rhs) :
> ^In file included from
> /home/user/Downloads/git-files/dealii/build/source/numerics/unity_0.cc:10:In
> file included from
> /home/user/Downloads/git-files/dealii/source/numerics/dof_output_operator.cc:23:In
> file included from
> /home/user/Downloads/git-files/dealii/include/deal.II/lac/petsc_block_vector.h:27:In
> file included from
> /home/user/Downloads/git-files/dealii/include/deal.II/lac/petsc_vector.h:29:/home/user/Downloads/git-files/dealii/include/deal.II/lac/petsc_vector_base.h:1363:49:
> error: no matching constructor for initialization of
> 'boost::serialization::array_wrapper'
> boost::serialization::array_wrapper velocity_wrapper(
>
> ^/media/storage/local_opt/boost/include/boost/serialization/array_wrapper.hpp:46:5:
> note: candidate constructor not viable: no known conversion from
> 'PetscScalar *' (aka 'complex *') to 'double *' for 1st argument
> array_wrapper(T * t, std::size_t s) :
> ^/media/storage/local_opt/boost/include/boost/serialization/array_wrapper.hpp:41:5:
> note: candidate constructor not viable: requires single argument 'rhs', but
> 2 arguments were providedarray_wrapper(const array_wrapper & rhs) :
> ^1 warning and 2 errors generated.make[2]: ***
> [source/numerics/CMakeFiles/object_numerics_debug.dir/build.make:76:
> source/numerics/CMakeFiles/object_numerics_debug.dir/unity_0.cc.o] Error
> 1make[1]: *** [CMakeFiles/Makefile2:1805:
> source/numerics/CMakeFiles/object_numerics_debug.dir/all] Error 2make: ***
> [Makefile:136: all] Error 2*
>
> PETSc was configured to use complex values. The same for deal.II, but I
> still get that error. CMakeCache is attached, but how can I fix that
> problem?
> Thanks!
> Regards,
> Roland Richter
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/ddde2d6a-3423-4d56-88ff-dfe7473236e1n%40googlegroups.com
> 

Re: [deal.II] An error occurred in line <1467> of file in function dealii::IndexSet dealii::TrilinosWrappers::MPI::Vector::locally_owned_elements() const

2023-10-11 Thread Daniel Arndt
Yi,

How are you initializing your TrilinosWrappers::MPI::BlockVector? It looks
like you are calling the constructor with only one std::vector
but some of the index sets are overlapping.
You should use the constructor taking two std::vector objects
with the first one containing the locally owned indices and the second one
the locally relevant indices, see
https://www.dealii.org/current/doxygen/deal.II/classTrilinosWrappers_1_1MPI_1_1BlockVector.html#a13d7be7dd540e34e89559e9ff6a0d779
.

Best,
Daniel

On Tue, Oct 10, 2023 at 11:30 PM Tiny Y  wrote:

> Hi al,
> I am a freshman in dealii. I have installed Dealii 9.4.2 on 22.04. The
> senior wrote code on the old version of dealii, so I made changes to his
> code to adapt to the new version of dealii, but I encountered some
> problems. The function(locally_owned_elements()) where the error code is
> located has been deleted, but this error still occurs. I want to know where
> this problem comes from and how I can solve it. Thanks in advance!
> Regard,
> Yi
> Error Message
>
> qincai@qincai-OMEN:~/桌面/cracks-master_mod版本更新$ mpirun -n 8 ./cracks
> parameters_ring.prm
> Running on 8 cores
> Cells: 442
>
> DoFs: 5440 solid + 2720 phase + 2720 pressure = 10880
>
> ===
> Parameters
> ==
> h (min): 0.0415041
> k: 4.15041e-12
> eps: 0.166016
> G_c: 1.2
> gamma penal: 0
> Poisson nu: 0.2
> E modulus: 1
> Lame mu: 4166.67
> Lame lambda: 2777.78
>
>
> 
> An error occurred in line <1467> of file
> 
> in function
> dealii::IndexSet
> dealii::TrilinosWrappers::MPI::Vector::locally_owned_elements() const
> The violated condition was:
> owned_elements.size() == size()
> Additional information:
> The locally owned elements have not been properly initialized! This
> happens for example if this object has been initialized with exactly
> one overlapping IndexSet.
>
> Stacktrace:
> ---
> #0 ./cracks:
> dealii::TrilinosWrappers::MPI::Vector::locally_owned_elements() const
> #1 /home/qincai/dealii-candi/deal.II-v9.4.2/lib/libdeal_II.g.so.9.4.2:
> #2  /home/qincai/dealii-candi/deal.II-v9.4.2/lib/libdeal_II.g.so.9.4.2:
> dealii::internal::DataOutImplementation::DataEntry<2, 2,
> double>::DataEntry(dealii::DoFHandler<2,
> 2> const*, dealii::TrilinosWrappers::MPI::BlockVector const*,
> dealii::DataPostprocessor<2> const*)
> #3  /home/qincai/dealii-candi/deal.II-v9.4.2/lib/libdeal_II.g.so.9.4.2:
> std::__detail::_MakeUniq 2, double> >::__single_object
> std::make_unique double>, dealii::DoFHandler<2, 2> const*,
> dealii::TrilinosWrappers::MPI::BlockVector const*,
> dealii::DataPostprocessor<2> const*>(dealii::DoFHandler<2, 2> const*&&,
> dealii::TrilinosWrappers::MPI::BlockVector const*&&,
> dealii::DataPostprocessor<2> const*&&)
> #4  /home/qincai/dealii-candi/deal.II-v9.4.2/lib/libdeal_II.g.so.9.4.2:
> void dealii::DataOut_DoFData<2, 2, 2,
> 2>::add_data_vector(dealii::DoFHandler<2,
> 2> const&, dealii::TrilinosWrappers::MPI::BlockVector const&,
> dealii::DataPostprocessor<2> const&)
> #5  ./cracks: void dealii::DataOut_DoFData<2, 2, 2,
> 2>::add_data_vector(dealii::TrilinosWrappers::MPI::BlockVector
> const&, dealii::DataPostprocessor<2> const&)
> #6  ./cracks: FracturePhaseFieldProblem<2>::output_results() const
> #7  ./cracks: FracturePhaseFieldProblem<2>::run()
> #8  ./cracks: main
> 
>
> Calling MPI_Abort now.
> To break execution in a GDB session, execute 'break MPI_Abort' before
> running. You can also put the following into your ~/.gdbinit:
>   set breakpoint pending on
>   break MPI_Abort
>   set breakpoint pending auto
>
> 
> An error occurred in line <1467> of file
> 
> in function
> dealii::IndexSet
> dealii::TrilinosWrappers::MPI::Vector::locally_owned_elements() const
> The violated condition was:
> owned_elements.size() == size()
> Additional information:
> The locally owned elements have not been properly initialized! This
> happens for example if this object has been initialized with exactly
> one overlapping IndexSet.
>
> Stacktrace:
> ---
> #0  ./cracks:
> dealii::TrilinosWrappers::MPI::Vector::locally_owned_elements() const
> #1  /home/qincai/dealii-candi/deal.II-v9.4.2/lib/libdeal_II.g.so.9.4.2:
> #2 /home/qincai/dealii-candi/deal.II-v9.4.2/lib/libdeal_II.g.so.9.4.2:
> dealii::internal::DataOutImplementation::DataEntry<2, 2,
> double>::DataEntry(dealii::DoFHandler<2,
> 2> const*, dealii::TrilinosWrappers::MPI::BlockVector const*,
> dealii::DataPostprocessor<2> const*)
> #3 /home/qincai/dealii-candi/deal.II-v9.4.2/lib/libdeal_II.g.so.9.4.2:
> std::__detail::_MakeUniq 2, double> >::__single_object
> std::make_unique double>, dealii::DoFHandler<2, 2> const*,
> dealii::TrilinosWrappers::MPI::BlockVector const*,
> dealii::DataPostprocessor<2> const*>(dealii::DoFHandler<2, 2> 

Re: [deal.II] I am experiencing varying execution speeds when running my code with different configurations of Ubuntu and Deal.II. Here are the observed speeds for the same code on different systems

2023-09-25 Thread Daniel Arndt
What is your code doing and how do you configure deal.II in all of these
cases? Are you running in Release mode when comparing the run time of your
program with different configurations?
I would be very surprised to find that vastly different runtimes are a
result of using different Ubuntu versions.

Best,
Daniel

On Mon, Sep 25, 2023 at 1:29 AM ME20D503 NEWTON 
wrote:

>
>
> "I am experiencing varying execution speeds when running my code with
> different configurations of Ubuntu and Deal.II. Here are the observed
> speeds for the same code on different systems:
>
> 1. Ubuntu 22.04.2 LTS, Deal.II 9.5.1, 32GB RAM, Intel Xeon Silver 4208 CPU
> @ 2.10GHz x 16 cores: The code runs very fast on this system.
>
> 2. Ubuntu 22.04.1 LTS, Deal.II 9.5.1, 32GB RAM, Intel Xeon Silver 4208 CPU
> @ 2.10GHz x 16 cores: The code runs very slow on this system.
>
> 3. Ubuntu 20.04.3 LTS, Deal.II 9.4.2, 64GB RAM, Intel Xeon Silver 4208 CPU
> @ 2.10GHz x 40 cores: The code runs very slow on this system.
>
> 4. Ubuntu 22.04.3 LTS, Deal.II 9.5.1, 32GB RAM, Intel Xeon Silver 4208 CPU
> @ 2.10GHz x 16 cores: The code runs very slow on this system.
>
> I am seeking assistance to understand why there is such a significant
> difference in code execution speed across these configurations."
>
> Thank you.
>
> regards
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/d657d4ed-a443-4282-9993-93e580977f99n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJTJq_dMCsaMJj2r9Y1bDYtHqef%2BYSxr%3DPtr-EO6oBzhw%40mail.gmail.com.


Re: [deal.II] Vector-valued matrix-free operatior with CUDA

2023-08-07 Thread Daniel Arndt
Justin,

As far as I know, we haven't made any significant progress with
vector-valued support for CudaWrappers::MatrixFree (apart from porting it
to Kokkos).
What's your specific use case? What functionality do you need specifically
(same finite elements? FESystsem?)?

Best,
Daniel

On Mon, Aug 7, 2023 at 10:03 AM Justin O'Connor 
wrote:

> Howdy!
>
> I see here:
> https://github.com/dealii/dealii/issues/4399
> that using cuda for matrix-free operators with multiple components has
> been discussed before, and I think it is referenced again here
> https://github.com/dealii/dealii/issues/7037
> but this issue hasn't been referenced by 2019. Has anyone been trying this?
> Would it be at all possible to use the existing framework to grab the
> individual components, and work with them inside the loop to do the
> operations I need? And then somehow put the results into the result vector
> from there?
>
> Thank you,
> Justin
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/2974346e-9ed7-4697-a32a-2df5ed5bf85en%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKfWXt6ezoprbbKXbo8Lf0OJqujgay-Ndnfgi9dxFns2Q%40mail.gmail.com.


Re: [deal.II] Question about compiling with CUDA

2023-08-07 Thread Daniel Arndt
I'm glad you found something that is working for you!

Best,
Daniel

On Mon, Aug 7, 2023 at 9:52 AM Justin O'Connor 
wrote:

> For posterity, ere's a dockerfile I got working that installs deal.ii with
> cuda capability. :)
>
> Thanks,
> Justin
> On Friday, July 28, 2023 at 4:33:46 PM UTC-6 Justin O'Connor wrote:
>
>> I'm now just using your dockerfile (thanks for the tips on it), and I am
>> trying to install deal.ii at the end.
>>
>> Adding this to the end of it:
>> RUN apt update && apt install -y libblas-dev liblapack-dev
>>
>> WORKDIR /opt
>> ENV DEALII_VERSION 9.5.1
>> RUN wget --no-verbose https://www.dealii.org/downloads/dealii-
>> $DEALII_VERSION.tar.gz
>> RUN gunzip -c dealii-$DEALII_VERSION.tar.gz | tar -xof -
>> ENV DEALII_DIR /opt/dealii-$DEALII_VERSION
>> WORKDIR $DEALII_DIR
>> RUN pwd
>> RUN mkdir build
>> RUN mkdir dealii_installed
>> WORKDIR $DEALII_DIR/build
>> RUN cmake $DEALII_DIR -DCMAKE_INSTALL_PREFIX=opt/dealii_installed \
>>-DCMAKE_CXX_COMPILER=clang++ \
>>-DDEAL_II_WITH_TBB=ON \
>>-DDEAL_II_WITH_MPI=ON \
>>-DDEAL_II_MPI_WITH_DEVICE_SUPPORT=ON \
>>-DDEAL_II_WITH_LAPACK=ON \
>>-DDEAL_II_WITH_BLAS=ON \
>>-DDEAL_II_WITH_64BIT_INDICES=ON \
>>-DKOKKOS_DIR=$KOKKOS_DIR \
>>-DDEAL_II_WITH_CUDA=ON
>>
>> gives the attached error, still saying the compiler and linker flags are
>> the issue?
>>
>> short version:
>>
>> CMake Error at cmake/setup_finalize.cmake:126 (message):
>>
>>
>> Configuration error: Cannot compile a test program with the final set
>> of
>> compiler and linker flags:
>>   CXX flags (DEBUG): -openmp-simd -pthread
>> -ffp-exception-behavior=strict -Og -ggdb -Wa,--compress-debug-sections
>>   LD flags  (DEBUG): -rdynamic  -pthread -fopenmp=libomp -ggdb
>> -Wl,--compress-debug-sections=zlib
>>   LIBRARIES (DEBUG): dl;
>>
>>
>>
>>
>> Call Stack (most recent call first):
>>   cmake/macros/macro_verbose_include.cmake:19 (include)
>>   CMakeLists.txt:123 (verbose_include)
>>
>>
>> Thank you so much for all your help already,
>>
>> Justin
>>
>> On Thursday, July 27, 2023 at 10:58:58 AM UTC-6 d.arnd...@gmail.com
>> wrote:
>>
>>> Justin,
>>>
>>> a docker file that we are using in a different project can be found at
>>> https://github.com/arborx/ArborX/blob/master/docker/Dockerfile in case
>>> that helps.
>>> In general, I would advise against using nvhpc/nvc++ which proves to be
>>> pretty buggy as compared to nvcc/nvcc_wrapper or even (clang++ which is
>>> another option for a compiler supporting CUDA).
>>> Anyway, it seems the current configuration is using nvcc_wrapper. What
>>> does the failing compile-line look like? What is the host compiler (I guess
>>> g++ but which version)?
>>>
>>> Best,
>>> Daniel
>>>
>>> On Thu, Jul 27, 2023 at 10:39 AM Justin O'Connor <
>>> jul...@rams.colostate.edu> wrote:
>>>
 Howdy!

 I'm working on making a Dockerfile that will let me use deal.ii with
 CUDA. However, when I run make install, I get the following error:

 Error: Internal Compiler Error (codegen): "casting aggregate to
 non-void type is not supported!"

 make[2]: *** [source/fe/CMakeFiles/object_fe_debug.dir/build.make:713:
 source/fe/CMakeFiles/object_fe_debug.dir/fe_values.cc.o] Error 2
 make[2]: *** Waiting for unfinished jobs

 I'm hoping this is a known issue and I'm just doing something silly.
 Any pointers would be greatly appreciated.

 My Dockerfile is attached if that is of any use to anyone.

 Thank you,
 Justin

 --
 The deal.II project is located at http://www.dealii.org/
 For mailing list/forum options, see
 https://groups.google.com/d/forum/dealii?hl=en
 ---
 You received this message because you are subscribed to the Google
 Groups "deal.II User Group" group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to dealii+un...@googlegroups.com.
 To view this discussion on the web visit
 https://groups.google.com/d/msgid/dealii/34846fa5-7a9e-4417-80c9-af54792844a9n%40googlegroups.com
 
 .

>>> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/3b70963d-f52a-4533-a92a-6248cc26db7en%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing 

Re: [deal.II] Integrate difference isn't picking on the

2023-07-27 Thread Daniel Arndt
Abbas,

Try following the steps at
https://github.com/dealii/dealii/wiki/Contributing.

Best,
Daniel

On Thu, Jul 27, 2023 at 1:24 PM Abbas Ballout 
wrote:

> Lucas
> It's not the linker but I am guessing it's when I edit something deep
> within the library.h files.
> Since everything is linked to it many files are being rebuilt
> I didn't know about other linker so thanks for the tip. I am sure I will
> do that in the future.
>
> Anyone,
> This is my first pull request ever and I don't know exactly how to
> approach this.
> Details:
> I extended the VectorFunctionFromTensorFunction. to return the
> gradient of a function,
> I ended up editing the files: function.h and function.templates.h. but I
> ended up copying from other files.
>
> I am getting the right H1 convergence in my example code so I know what I
> am doing works.
> How do I proceed?
>
> Best,
> Abbas
>
>
> On Saturday, July 22, 2023 at 6:53:24 PM UTC+2 lucasm...@gmail.com wrote:
>
>> I haven't tried this with deal.II yet, but I've recently started using
>> the mold linker for programs I write which have many compilation units
>> (link to GitHub here: https://github.com/rui314/mold). If you're only
>> changing one line then probably only one compilation unit is being
>> recompiled, so the bulk of the wait time is probably being taken by the
>> linker.
>>
>> Note that, to get a significant speedup, you'll have to recompile with
>> all of your cores so the linking can be parallelized. I've found that using
>> all cores to compile sometimes causes make to get killed because it uses
>> too much memory, but if most things are compiled and you're just on the
>> linking stage you don't really run into this.
>>
>> Alternatively, I think that some other folks use gold linker or the lld
>> linker (in case you can't get mold to work).
>>
>> - Lucas
>>
>>
>> On Sat, Jul 22, 2023, 11:37 AM Abbas Ballout 
>> wrote:
>>
>>> If I change a single line in deal I'll have to wait a good amount of
>>> time for it to compile.
>>> Do you all go through this? All I have is a 4 cores and 16 GBs of RAM on
>>> my Laptop.
>>>
>>> On Monday, July 17, 2023 at 9:48:00 AM UTC+2 Abbas Ballout wrote:
>>>
 YES. Would take me a while but I ll do it.
 Be prepared for many questions.

 On Monday, July 17, 2023 at 2:44:01 AM UTC+2 Wolfgang Bangerth wrote:

> On 7/16/23 07:22, Abbas Ballout wrote:
> > I get this error when I call the
> exact_solution_vector_function.gradient(p1):
> > !ERROR Message:
> > /An error occurred in line <135> of file
> >
> 
> in function
> > dealii::Tensor<1, dim, Number> dealii::Function > RangeNumberType>::gradient(const dealii::Point&, unsigned int)
> const
> > [with int dim = 2; RangeNumberType = double]
> > The violated condition was:
> > false
> > Additional information:
> > You (or a place in the library) are trying to call a function
> that is
> > declared as a virtual function in a base class but that has not
> been
> > overridden in your derived class./
> > /
> > /
> > Calling value  works fine but not gradient even though I have
> overridden both
> > functions.
>
> You do in your own class, but VectorFunctionFromTensorFunction does
> not.
> That's not by design, but probably simply because nobody has ever had
> a need
> for this. Would you like to try and write a patch that adds
> VectorFunctionFromTensorFunction::gradient()? You could model it on
> VectorFunctionFromTensorFunction::value().
>
> Best
> Wolfgang
>
> --
> 
>
> Wolfgang Bangerth email: bang...@colostate.edu
> www: http://www.math.colostate.edu/~bangerth/
>
>
> --
>>> The deal.II project is located at http://www.dealii.org/
>>> For mailing list/forum options, see
>>> https://groups.google.com/d/forum/dealii?hl=en
>>> ---
>>> You received this message because you are subscribed to the Google
>>> Groups "deal.II User Group" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to dealii+un...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/dealii/15f0b1e7-d5ea-49ed-b58f-ea10fae84d52n%40googlegroups.com
>>> 
>>> .
>>>
>> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> 

Re: [deal.II] Question about compiling with CUDA

2023-07-27 Thread Daniel Arndt
Justin,

a docker file that we are using in a different project can be found at
https://github.com/arborx/ArborX/blob/master/docker/Dockerfile in case that
helps.
In general, I would advise against using nvhpc/nvc++ which proves to be
pretty buggy as compared to nvcc/nvcc_wrapper or even (clang++ which is
another option for a compiler supporting CUDA).
Anyway, it seems the current configuration is using nvcc_wrapper. What does
the failing compile-line look like? What is the host compiler (I guess g++
but which version)?

Best,
Daniel

On Thu, Jul 27, 2023 at 10:39 AM Justin O'Connor 
wrote:

> Howdy!
>
> I'm working on making a Dockerfile that will let me use deal.ii with CUDA.
> However, when I run make install, I get the following error:
>
> Error: Internal Compiler Error (codegen): "casting aggregate to non-void
> type is not supported!"
>
> make[2]: *** [source/fe/CMakeFiles/object_fe_debug.dir/build.make:713:
> source/fe/CMakeFiles/object_fe_debug.dir/fe_values.cc.o] Error 2
> make[2]: *** Waiting for unfinished jobs
>
> I'm hoping this is a known issue and I'm just doing something silly. Any
> pointers would be greatly appreciated.
>
> My Dockerfile is attached if that is of any use to anyone.
>
> Thank you,
> Justin
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/34846fa5-7a9e-4417-80c9-af54792844a9n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BAcEzUbpnYtnK1VvQsdYdVwJK7YreO34YTD-PPzW2eeg%40mail.gmail.com.


Re: [deal.II] Q: Question about extracting part of a vector

2023-07-20 Thread Daniel Arndt
Najwa,

the relevant code reads something like

  const unsigned int n_components = dof.get_fe(0).n_components();
  AssertDimension(exact_solution.n_components, n_components);
  if (weight != nullptr)
{
  Assert((weight->n_components == 1) ||
   (weight->n_components == n_components),
 ExcDimensionMismatch(weight->n_components, n_components));
}

which means that your exact solution still needs to have as many components
as the FiniteElement object used (and the number of components for
ComponentSelectFunction must also match that).
ComponentSelectFunction then makes sure that all other components are
ignored when computing the error.

Best,
Daniel

On Thu, Jul 20, 2023 at 6:15 AM Najwa Alshehri 
wrote:

> Hello again,
>
> I have a follow-up question. Does this ComponentSelectFunction work also
> with vectors that are not written as blocked vectors? I have applied it
> before when I was dealing with blocked vectors and it worked perfectly.
>
> So, I did this,
> const ComponentSelectFunction primal_mask(0,2);
> Later,
> VectorTools::integrate_difference(omega2_dh,
> u_omega2,
> ExactSolution2(),
> cellwise_errors2,
> quadrature,
> VectorTools::L2_norm
> ,_mask);
> const double u2_l2_error =
> VectorTools::compute_global_error(triangulation_omega2,
> cellwise_errors2,
> VectorTools::L2_norm);
>
> And I got the following error!!
> An error occurred in line <455> of file
> <../include/deal.II/numerics/vector_tools_integrate_difference.templates.h>
> in function
> void dealii::VectorTools::internal::do_integrate_difference(const
> dealii::hp::MappingCollection&, const
> dealii::DoFHandler&, const InVector&, const
> dealii::Function&, OutVector&,
> const dealii::hp::QCollection&, const dealii::VectorTools::NormType&,
> const dealii::Function*, double) [with int dim = 2; int spacedim
> = 2; InVector = dealii::Vector; OutVector = dealii::Vector;
> typename InVector::value_type = double]
> The violated condition was:
>
> ::dealii::deal_II_exceptions::internals::compare_for_equality(exact_solution.n_components,
> n_components)
> Additional information:
> Dimension 1 not equal to 2.
>
>  Obviously, we have dimensionality mismatching between u_omega2 and the
> exact solution. which means that the mask is not really picking up the
> first component of the solution u_omega2.  Do you have any suggestions to
> fix this issue?
>
> Appreciate your help,
> Najwa
> On Thursday, July 20, 2023 at 11:48:04 AM UTC+3 Najwa Alshehri wrote:
>
>> Thank you Daniel for the clear quick answer. I will follow it.
>>
>> Best,
>> Najwa
>>
>> On Wednesday, July 19, 2023 at 5:16:14 PM UTC+3 d.arnd...@gmail.com
>> wrote:
>>
>>> Najwa,
>>>
>>> The documentation of VectorTools::integrate_difference(
>>> https://www.dealii.org/current/doxygen/deal.II/namespaceVectorTools.html#a676190d2c897ac5da68a9c460fa95832)
>>> says
>>>
>>>
>>> The additional argument weight allows to evaluate weighted norms. The
>>> weight function may be scalar, establishing a spatially variable weight in
>>> the domain for all components equally. This may be used, for instance, to
>>> only integrate over parts of the domain. The weight function may also be
>>> vector-valued, with as many components as the finite element: Then,
>>> different components get different weights. A typical application is when
>>> the error with respect to only one or a subset of the solution variables is
>>> to be computed, in which case the other components would have weight values
>>> equal to zero. The ComponentSelectFunction
>>> 
>>> class is particularly useful for this purpose as it provides such a "mask"
>>> weight. The weight function is expected to be positive, but negative values
>>> are not filtered. The default value of this function, a null pointer, is
>>> interpreted as "no weighting function", i.e., weight=1 in the whole domain
>>> for all vector components uniformly.
>>>
>>> Best,
>>> Daniel
>>>
>>> On Wed, Jul 19, 2023 at 8:01 AM Najwa Alshehri 
>>> wrote:
>>>
 Dear group members,

 I have one question,

 I am trying to calculate the L2 norm of the error of a solution. In
 particular, I have a *vector of the solution* u_omega and a *FeSystem*
 with two fes.

 I am interested in computing the L2 norm of the error related to the
 first fe using *integrate_difference * function. (Note here u_omega is *not
 a blocked vector*, however, it has two solutions stacked together in
 one vector). Can I extract the solution of the first part from u_omega?



 Thank you in advance for your help.

 Best,

 Najwa

 --
 The deal.II project is located at http://www.dealii.org/
 For mailing list/forum options, see
 https://groups.google.com/d/forum/dealii?hl=en
 ---
 You received this message because you are subscribed to the Google

Re: [deal.II] Q: Question about extracting part of a vector

2023-07-19 Thread Daniel Arndt
Najwa,

The documentation of VectorTools::integrate_difference(
https://www.dealii.org/current/doxygen/deal.II/namespaceVectorTools.html#a676190d2c897ac5da68a9c460fa95832)
says


The additional argument weight allows to evaluate weighted norms. The
weight function may be scalar, establishing a spatially variable weight in
the domain for all components equally. This may be used, for instance, to
only integrate over parts of the domain. The weight function may also be
vector-valued, with as many components as the finite element: Then,
different components get different weights. A typical application is when
the error with respect to only one or a subset of the solution variables is
to be computed, in which case the other components would have weight values
equal to zero. The ComponentSelectFunction

class is particularly useful for this purpose as it provides such a "mask"
weight. The weight function is expected to be positive, but negative values
are not filtered. The default value of this function, a null pointer, is
interpreted as "no weighting function", i.e., weight=1 in the whole domain
for all vector components uniformly.

Best,
Daniel

On Wed, Jul 19, 2023 at 8:01 AM Najwa Alshehri 
wrote:

> Dear group members,
>
> I have one question,
>
> I am trying to calculate the L2 norm of the error of a solution. In
> particular, I have a *vector of the solution* u_omega and a *FeSystem*
> with two fes.
>
> I am interested in computing the L2 norm of the error related to the first
> fe using *integrate_difference * function. (Note here u_omega is *not a
> blocked vector*, however, it has two solutions stacked together in one
> vector). Can I extract the solution of the first part from u_omega?
>
>
>
> Thank you in advance for your help.
>
> Best,
>
> Najwa
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/9741338e-2a31-418b-815d-277a5d7cb573n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2Bo%3DQF7DTMrtPEgsHDCyBc2OS3BZRjJd3Q64K2yw1W0hg%40mail.gmail.com.


Re: [deal.II] create reference simplex in 2d (triangle) based on three vertices

2023-07-18 Thread Daniel Arndt
Math,

You can use ReferenceCells::get_simplex()
https://www.dealii.org/current/doxygen/deal.II/namespaceReferenceCells.html#ace7fb0fa0c1a98b17ae9c6f6d2eaa650
to create a ReferenceCell object describing the reference simplex.

Best,
Daniel

On Tue, Jul 18, 2023 at 1:49 PM Mathieu  wrote:

> Thank you Daniel!
>
> I have one follow-up (I apologize for this basic question):
> -The ReferenceCall that I have to pass to GridGenerator::reference_cell
> only has a default constructor.
> So how can I create a simplex using this constructor?
>
> Best,
> Math
>
> d.arnd...@gmail.com schrieb am Dienstag, 18. Juli 2023 um 17:14:14 UTC+2:
>
> Mathieu,
>
> You should be able to use GridGenerator::reference_cell (
> https://www.dealii.org/current/doxygen/deal.II/namespaceGridGenerator.html#aeb9a83e353f8d69ce49ebdd191a3a51f
> ),
> and then move the vertices to your liking, e.g. by using
> GridTools::transform (
> https://www.dealii.org/current/doxygen/deal.II/namespaceGridTools.html#a212e99cf0d923cebfa04f1d23fa60b04
> ).
>
> Best,
> Daniel
>
> On Tue, Jul 18, 2023 at 5:07 AM Mathieu  wrote:
>
> Hello everyone,
>
> I read the simplex support
>  
> documentation
> and was wondering
> whether it is possible to create a triangle in 2d based on three vertices?
>
> The quadrilateral pendant is GridGenerator::general_cell().
> Contrary to what one might think, GridGenerator::simplex()
> transforms the reference simplex into three quadrilaterals,
> which is also not what I am looking for.
>
> So is there a way to create a mesh consisting of one triangle (using three
> vertices)?
> I have deal.II 9.3.2 installed, but can upgrade if necessary.
>
> Thank you,
> Math
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/1b0cefaa-24fe-4e7c-8f9a-aaaf72d8ee2cn%40googlegroups.com
> 
> .
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/4e354772-377b-47bb-a9b7-eee733b957dbn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJRygOtcLhWZmQ0AmYBjzsHvZSbyU800k-g-mqUTM_Gfg%40mail.gmail.com.


Re: [deal.II] create reference simplex in 2d (triangle) based on three vertices

2023-07-18 Thread Daniel Arndt
Mathieu,

You should be able to use GridGenerator::reference_cell (
https://www.dealii.org/current/doxygen/deal.II/namespaceGridGenerator.html#aeb9a83e353f8d69ce49ebdd191a3a51f
),
and then move the vertices to your liking, e.g. by using
GridTools::transform (
https://www.dealii.org/current/doxygen/deal.II/namespaceGridTools.html#a212e99cf0d923cebfa04f1d23fa60b04
).

Best,
Daniel

On Tue, Jul 18, 2023 at 5:07 AM Mathieu  wrote:

> Hello everyone,
>
> I read the simplex support
>  
> documentation
> and was wondering
> whether it is possible to create a triangle in 2d based on three vertices?
>
> The quadrilateral pendant is GridGenerator::general_cell().
> Contrary to what one might think, GridGenerator::simplex()
> transforms the reference simplex into three quadrilaterals,
> which is also not what I am looking for.
>
> So is there a way to create a mesh consisting of one triangle (using three
> vertices)?
> I have deal.II 9.3.2 installed, but can upgrade if necessary.
>
> Thank you,
> Math
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/1b0cefaa-24fe-4e7c-8f9a-aaaf72d8ee2cn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BqoRn14YNp28ZRShh%2BvSWH7yavpZU-P6dTK1B%3Dwbt1wQ%40mail.gmail.com.


Re: [deal.II] how to define periodic bc in delal.II

2023-07-12 Thread Daniel Arndt
Have a look at step-45.

On Tue, Jul 11, 2023 at 11:48 PM ztdep...@gmail.com 
wrote:

> I waant to know how to define periodic bc in delal.II.
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/9c8bb95d-65a3-4967-bf7f-888684b7080en%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbL5-j9VWhkK78AQPsRwprN8bC%3D-Vqh3BsFW5YegD1PPRg%40mail.gmail.com.


Re: [deal.II] Re: Finding unconnected regions in a triangulation

2023-07-10 Thread Daniel Arndt
Kaushik,

The implementation for those functions is pretty simple so it shouldn't be
too hard to modify them to meet your needs, see
https://dealii.org/current/doxygen/deal.II/grid__tools_8cc_source.html#l03828
.

Best,
Daniel

On Mon, Jul 10, 2023 at 1:01 PM Kaushik Das  wrote:

> Hi   Bruno, thank you very much for your quick reply. This is what I was
> looking for. Thanks. But I have another question, is there a way the
> generate these graph by only considering a subset of cells from a
> triangulation? Like cells that has a specific fe_index or material_id or
> flags? Thank you.
>
> On Mon, Jul 10, 2023 at 11:43 AM Bruno Turcksin 
> wrote:
>
>> Kaushik,
>>
>> You could use get_face_connectivity_of_cells()
>> 
>> or get_vertex_connectivity_of_cells()
>> 
>> (depending on what you mean by connected) to have a sparsity pattern. This
>> maps to a graph where the nodes are the cells, now you just need to check
>> if the graph is connected see here
>> 
>>
>> Best,
>>
>> Bruno
>> On Monday, July 10, 2023 at 10:33:21 AM UTC-4 k.d...@gmail.com wrote:
>>
>>> Hi all,
>>> Is there any way to find or count number of unconnected regions in a
>>> triangulation. Triangulation will have non zero refinement levels.
>>> Thanks,
>>> Kaushik
>>>
>> --
>> The deal.II project is located at http://www.dealii.org/
>> For mailing list/forum options, see
>> https://groups.google.com/d/forum/dealii?hl=en
>> ---
>> You received this message because you are subscribed to a topic in the
>> Google Groups "deal.II User Group" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/dealii/gQH57TWRGP0/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to
>> dealii+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/dealii/c77b5d42-9228-497a-ab2b-2ac25dc06fb7n%40googlegroups.com
>> 
>> .
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/CAC-fs6vmote0mqgCu7d60EjRrsAHpRPw-kSXeJJRtaFXg%2BXDtw%40mail.gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKH7hTA9PhQ8kE%2Bx8eUONPLjqGMCipEnWF9UYpKbLvX1g%40mail.gmail.com.


Re: [deal.II] Unable to compile in ubuntu 22.04

2023-06-19 Thread Daniel Arndt
Sabyasachi,

What is the boost version of the system-provided boost installation?
You should be able to work around this issue by forcing deal.II to use its
bundled boost package via using `-DDEAL_II_FORCE_BUNDLED_BOOST=ON` when
configuring deal.II.

Best,
Daniel

On Sun, Jun 18, 2023 at 2:01 AM sabyasachi chatterjee 
wrote:

> Hello,
>
> I recently upgraded to ubuntu 22.04 and the deal ii version I am using is
> 9.1.1. It used to compile fine in ubuntu 20.04. However, now I am seeing
> the following error:
>
>
> ***
> In file included from
> /usr/include/boost/smart_ptr/detail/sp_thread_sleep.hpp:22,
>  from /usr/include/boost/smart_ptr/detail/yield_k.hpp:23,
>  from
> /usr/include/boost/smart_ptr/detail/spinlock_gcc_atomic.hpp:14,
>  from /usr/include/boost/smart_ptr/detail/spinlock.hpp:42,
>  from
> /usr/include/boost/smart_ptr/detail/spinlock_pool.hpp:25,
>  from /usr/include/boost/smart_ptr/shared_ptr.hpp:29,
>  from
> /usr/include/boost/archive/detail/helper_collection.hpp:27,
>  from
> /usr/include/boost/archive/detail/basic_iarchive.hpp:28,
>  from
> /usr/include/boost/archive/detail/common_iarchive.hpp:21,
>  from
> /usr/include/boost/archive/basic_binary_iarchive.hpp:30,
>  from
> /usr/include/boost/archive/binary_iarchive_impl.hpp:21,
>  from /usr/include/boost/archive/binary_iarchive.hpp:20,
>  from
> /home/sabyasachi/Documents/dealii_libraries/dealii_setup/deal.II-v9.1.1/include/deal.II/base/utilities.h:45,
>  from
> /home/sabyasachi/Documents/dealii_libraries/dealii_setup/deal.II-v9.1.1/include/deal.II/base/tensor.h:26,
>  from
> /home/sabyasachi/Documents/dealii_libraries/dealii_setup/deal.II-v9.1.1/include/deal.II/base/point.h:23,
>  from
> /home/sabyasachi/Documents/dealii_libraries/dealii_setup/deal.II-v9.1.1/include/deal.II/base/quadrature.h:22,
>  from
> /home/sabyasachi/Documents/dealii_libraries/dealii_setup/deal.II-v9.1.1/include/deal.II/base/quadrature_lib.h:22,
>  from
> /home/sabyasachi/Documents/postdoc/irradiated_hardness_test_contact/main_hardness_contact.cc:1:
> /usr/include/boost/detail/no_exceptions_support.hpp:17:1: note: ‘#pragma
> message: This header is deprecated. Use
>  instead.’
>17 | BOOST_HEADER_DEPRECATED("")
>   | ^~~
> In file included from
> /home/sabyasachi/Documents/dealii_libraries/dealii_setup/deal.II-v9.1.1/include/deal.II/grid/grid_tools.h:45,
>  from
> /home/sabyasachi/Documents/postdoc/irradiated_hardness_test_contact/main_hardness_contact.cc:33:
> /usr/include/boost/geometry/index/detail/serialization.hpp: In static
> member function ‘static
> boost::geometry::index::detail::rtree::load::node_pointer
> boost::geometry::index::detail::rtree::load::raw_apply(Archive&,
> unsigned int,
> boost::geometry::index::detail::rtree::load::size_type,
> boost::geometry::index::detail::rtree::load::size_type&,
> const parameters_type&, const translator_type&,
> boost::geometry::index::detail::rtree::load::allocators_type&,
> boost::geometry::index::detail::rtree::load::size_type)’:
> /usr/include/boost/geometry/index/detail/serialization.hpp:399:49: error:
> ‘Allocators’ was not declared in this scope; did you mean ‘allocators’?
>   399 | node_pointer n = rtree::create_node internal_node>::apply(allocators);  // MAY THROW (A)
>   | ^~
>   | allocators
> /usr/include/boost/geometry/index/detail/serialization.hpp:399:74: error:
> template argument 1 is invalid
>   399 | node_pointer n = rtree::create_node internal_node>::apply(allocators);  // MAY THROW (A)
>   |
>^
> /usr/include/boost/geometry/index/detail/serialization.hpp:422:49: error:
> ‘Allocators’ was not declared in this scope; did you mean ‘allocators’?
>   422 | node_pointer n = rtree::create_node leaf>::apply(allocators);   // MAY THROW (A)
>   | ^~
>   | allocators
>
> 
>
> Probably it is something related to boost library. My code is an extension
> of Step 18 and I think it does not need the boost library. Please suggest
> how to resolve this.
>
> Thanks,
> Sabyasachi
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II 

Re: [deal.II] Re: Mean Value Constraints

2023-05-19 Thread Daniel Arndt
Corbin,

- Using ARPACK might indeed be an option. Do you really need to know the
whole spectrum, though?
- Yes, you would just call AffineConstraints::add_line() to add constrain a
given DoF to zero. Note that it's a no-op if the DoF is already
constrained. This doesn't change the size of the linear system.
- You will need to include deal.II/lac/affine_constraints.templates.h,
deal.II/lac/affine_constraints.h only contains the declarations but not the
definitions.

Best,
Daniel

On Fri, May 19, 2023 at 12:04 PM Corbin Foucart 
wrote:

> I'm working on a similar pure Neumann problem with a rank-1 deficiency
> (pressure known only up to a constant). I've implemented the subspace
> projection method Konrad mentioned, with good results. However, I'm
> interested in comparing it to the single DoF constraint method, as well as
> an alternative penalization method alluded to in the paper by Bochev. I had
> a few questions:
>
>1. For a Sparse or ChunkSparse matrix object, is there a simple way of
>obtaining the eigenvalues? I know I can rebuild deal.ii with ARPACK, but
>this seems like overkill
>2. Exactly how would I use an AffineConstraints object to "pin" the
>degree of freedom? Is it a matter of a single call to
>AffineConstraints::add_line()? It's unclear to me from the documentation
>whether this would add an additional "row" to the linear system, or replace
>an existing one (I'd be looking to do the second)
>3. I've implemented the subspace projection by wrapping the
>ChunkSparse matrix class  and overriding the vmult() function; however, at
>the moment, I'm forced to copy an original ChunkSparse matrix object into
>the wrapped object because the
>AffineConstraints::distribute_local_to_global() function doesn't recognize
>the wrapped matrix --I receive a linker error
>
> libHDG_experimental.so: error: undefined reference to 'void
> dealii::AffineConstraints::distribute_local_to_global dealii::Vector >(dealii::FullMatrix const&, dealii::Vector const&,
> std::vector const&,
> HDG::LinearSystem::ChunkSparseWrapper&, dealii::Vector&, bool,
> std::integral_constant) const'
>
> I find that surprising, given that my wrapper class inherits publicly from
> ChunkSparseMatrix.
>
> Any guidance would be appreciated!
> Corbin
>
> On Monday, December 28, 2020 at 1:23:19 PM UTC-5 Wolfgang Bangerth wrote:
>
>> On 12/26/20 3:06 AM, Konrad Simon wrote:
>> > What one can also do is just constrain one DoF to a specific value
>> (this would
>> > also remove rigid motion in elasticity). But think about your solution
>> > variable: If it is in the Sobolev space H^1 then point evaluations may
>> not be
>> > defined for dimension larger than 2. Similarly if, for example, the
>> pressure
>> > in a mechanical or fluid problem is often just in L^2. Point
>> evaluations do
>> > not make sense there at all.
>>
>> Right, this is the correct approach: Constrain a single degree of freedom
>> to
>> zero (or any other value you choose) and solve the problem. Then you can
>> subtract the mean value of the solution *after* solving the linear
>> system.
>> (See VectorTools::subtract_mean_value and
>> VectorTools::compute_mean_value.)
>>
>> If you're uncomfortable with the ill-posedness of taking a point value,
>> you
>> can also take the mean value along a small segment of the boundary
>> (step-1) or
>> a small part of the domain. But in practice, this is not necessary and
>> Konrad's solution is what everyone seems to be doing.
>>
>> Best
>> W.
>>
>> --
>> 
>> Wolfgang Bangerth email: bang...@colostate.edu
>> www: http://www.math.colostate.edu/~bangerth/
>>
>> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/ae39fbcc-c76b-4c03-bfbb-93d19ab2e3d7n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbLXuWzaAkL1ki9p-HY6Y1QvOTNL0O5FJ0eX0gxZ3AoKKw%40mail.gmail.com.


Re: [deal.II] determine global dof index of a point

2023-05-18 Thread Daniel Arndt
There is also DoFTools::map_support_points_to_dofs, see
https://www.dealii.org/current/doxygen/deal.II/namespaceDoFTools.html#a3540ceb577e65414bde1b6b14808da2c

Best,
Daniel

On Thu, May 18, 2023 at 11:15 AM Wolfgang Bangerth 
wrote:

> On 5/17/23 12:00, Mathieu wrote:
> >
> > I apologize for my simple question:
> > Given a point, which is also a vertex (support point of FE_Q element),
> in real
> > coordinates, is there a function that allows me to query the global dof
> index
> > associated with that support point?
> >
> > I know all the cells at which these support point lives.
> > One could then loop over the vertices of anyone of these cells, and call
> > cell->vertex_dof_index(vertex,...)
> > if vertex is the one that matches the support point.
> >
> > But I was wondering if there is a direct way to get the dof index of a
> vertex
> > based on the coordinates in real space.
>
> You can use DoFTools::map_dofs_to_support_points(). This gives you the map
> "in
> the wrong direction", but would probably still be useful for your case.
>
> Best
>   W.
>
> --
> 
> Wolfgang Bangerth  email: bange...@colostate.edu
> www: http://www.math.colostate.edu/~bangerth/
>
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/78768f0a-b5a4-b689-adeb-e6a95e6da1a8%40colostate.edu
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbLt1EKRRu-H6T3Sxk2fYm5UZYquuBc_Mb_QuEJ_SvYw%2Bg%40mail.gmail.com.


Re: [deal.II] Error in using FESystem usage

2023-05-16 Thread Daniel Arndt
Vinayak,

an alternative to initializing an object of type FESystem in the
constructor is to use a smart pointer like

std::unique_ptr> fe_system_ptr;

as a member variable since that one would have a default constructor.

Best,
Daniel

On Tue, May 16, 2023 at 10:26 AM Lucas Myers  wrote:

> Hi Vinayak,
>
> If you do not manually initialize member variables in a constructor, they
> are automatically initialized with their default constructor (i.e. one
> which takes no arguments). However, the FESystem class is such that the
> default constructor is manually deleted, and so can't be constructed
> without explicitly passing in some arguments. In order to get your code to
> compile, you'll need to call a non-default constructor for your FESystem
> member variable in the constructor of Network.
>
> See the FESystem documentation or step-8 (
> https://www.dealii.org/current/doxygen/deal.II/step_8.html#ElasticProblemElasticProblemconstructor)
> for an example of how to properly construct an FESystem object.
>
>
> On Tue, May 16, 2023, 9:12 AM Vinayak Vijay  wrote:
>
>> Hello,
>>
>> I am trying to initialise FESystem in a class called "Network"
>> (definition present in a header file), however when i am getting the
>> following error:
>>
>> In constructor ‘Network::Network(const string&)’:
>> /home/Network.cpp:21:57: error: use of deleted function
>> ‘dealii::FESystem::FESystem() [with int dim = 1; int
>> spacedim = 3]’
>>21 | Network::Network(const std::string _file)
>>   | ^
>> In file included from /home/Network.h:16,
>>  from /home/Network.cpp:1:
>> /home/user/spack/opt/spack/linux-ubuntu20.04-icelake/gcc-9.4.0/dealii-9.4.2-4haiezd5dty7b537inhxmeebwxllx4gs/include/deal.II/fe/fe_system.h:215:3:
>> note: declared here
>>   215 |   FESystem() = delete;
>>
>> I am not able to figure out the error. Can someone help?
>>
>> Thanks
>> Vinayak
>>
>> --
>> The deal.II project is located at http://www.dealii.org/
>> For mailing list/forum options, see
>> https://groups.google.com/d/forum/dealii?hl=en
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "deal.II User Group" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to dealii+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/dealii/de162421-9d6d-4722-a3e6-6c92fa316319n%40googlegroups.com
>> 
>> .
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/CALTw5sZZB6Ey8O_3sUh67oj25BkatbNdKb_AS1qwzW%2B3onD%3DkQ%40mail.gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKKrNC3NKc%3DGbPfnHphFcPst-zdq0AEPy_5afJ5k3sdYg%40mail.gmail.com.


Re: [deal.II] Re: Could not find partitioner that fits vector

2023-05-15 Thread Daniel Arndt
Wayne,

> I have another suggestion that the
mg_constrained_dofs::make_zero_boundary() seems only accept one
> boundary_ids set + ComponentMask combination. So if there are 2 Dirichlet
BC that mask different components
> in vector problems, more make_zero_boundary functions might be added. Not
a big problem though.

The documentation (
https://www.dealii.org/current/doxygen/deal.II/classMGConstrainedDoFs.html#ad9f0da6bd4cb834c8ea3798d8ddacb92)
says:

[...]
This function can be called multiple times to allow considering different
sets of boundary_ids for different components.
[...]

Best,
Daniel

On Mon, May 15, 2023 at 8:57 AM 'yy.wayne' via deal.II User Group <
dealii@googlegroups.com> wrote:

> The modification is easy:
> 1) on line 518 of include/deal.II/multigrid/mg_transfer_matrix_free.h
> ,
> change first build() to:
> void
>   build(const DoFHandler _handler,
> const std::vector Utilities::MPI::Partitioner>>
>   _partitioners =
> std::vector Utilities::MPI::Partitioner>>());
> 2) on line 768 of source/multigrid/mg_transfer_matrix_free.cc
> ,
> change first build() to
> template 
> void
> MGTransferBlockMatrixFree::build(
>   const DoFHandler _handler,
>   const std::vector>
>   _partitioners)
> {
>   AssertDimension(this->matrix_free_transfer_vector.size(), 1);
>   this->matrix_free_transfer_vector[0].build(dof_handler,
>  external_partitioners);
> }
>
> I'm not familiar with github pulls so just list the modification here. I
> tested with either with external_partitioners
> or without external_partitioners build() functions, and both show no
> error. By introducing external_partitioners
> the former bug diminishes.
>
> I have another suggestion that the
> mg_constrained_dofs::make_zero_boundary() seems only accept one
> boundary_ids set + ComponentMask combination. So if there are 2 Dirichlet
> BC that mask different components
> in vector problems, more make_zero_boundary functions might be added. Not
> a big problem though.
>
> Best,
> Wayne
>
>
> 在2023年5月7日星期日 UTC+8 15:37:24 写道:
>
>> Thanks!
>> Peter
>>
>> On Sunday, 7 May 2023 at 09:27:34 UTC+2 yy.wayne wrote:
>>
>>> I'll try add build function to  MGTransferBlockMatrixFree  then.
>>> Thank you.
>>>
>>> Best,
>>> Wayne
>>>
>>> 在2023年5月7日星期日 UTC+8 15:23:12 写道:
>>>
 >  I wonder will the unmatched partitioners occur even coding is
 correct?

 Yes. The requirements of MG and the level operators are not identical.
 If you don't do anything special, the vector are set up for MG and not the
 level operators. With the help of external partitioners you can fix this
 "problem".

 I guess you could introduce a new
 function MGTransferBlockMatrixFree::build(). Shouldn't to be too much work,
 since all you need to do is to delegate the task
 to MGTransferMatrixFree::build(). Happy to accept a patch!

 Peter

 On Sunday, 7 May 2023 at 08:18:37 UTC+2 yy.wayne wrote:

> Thank you Peter,
>
> Currently I'm using MGTransferBlockMatrixFree where build with
> external partitioners is not supported.
> But before moving to modify Block mg transfers, I wonder will the
> unmatched partitioners occur even coding is correct?
> My problem is preconditioned with global coarsening h-MG, with 6 dofs
> per node for real and imaginary vectors in 3d,
> BlockVectors are applied except for trilinos direct solver on coarsest
> level, where only Vectors rather than BlockVector
> is supported. Transfer between Vector and BlockVector is a potential
> risk though.
>
> Best,
> Wayne
>
> 在2023年5月6日星期六 UTC+8 16:41:40 写道:
>
>> Hi Wayne,
>>
>> my best guess it that the partitioners in the multigrid operator and
>> the matrix-free operators not match, with the result that a vector with
>> wrong ghosting coming from the multigrid operator is used as src/dst in 
>> the
>> matrix-free loop resulting in the assert you show. Previously, one would
>> need to fix the the ghosting in the operator (see
>> https://github.com/dealii/dealii/blob/a091f25c5ff77687fbd8a65f5b336b235f201100/include/deal.II/matrix_free/operators.h#L489-L498)
>> but nowadays one can pass in external partitioners to MG: see, e.g.,
>> https://github.com/peterrum/dealii-multigrid/blob/c50581883c0dbe35c83132699e6de40da9b1b255/multigrid_throughput.cc#L1802.
>> Similarly one can do this in the context of global-coarsening MG.
>>
>> Hope this helps!
>>
>> Peter
>>
>> On Saturday, 6 May 2023 at 10:22:58 UTC+2 yy.wayne wrote:
>>
>>> It might fails too for 1st basis order too ...
>>> But all fails occur when mpi process > 2. If I run with only 2 mpi

Re: [deal.II] Unable to refresh spack module

2023-05-12 Thread Daniel Arndt
> Can you tell me how can I let spack know about the package that is
installed through system installation?

Have a look at
https://spack.readthedocs.io/en/latest/build_settings.html#external-packages
.

I don't know about the other spack issue.

Best,
Daniel

On Fri, May 12, 2023 at 9:32 AM Vinayak Vijay  wrote:

> Hi,
>
> Thank you for your reply. I will try it. Can you tell me how can I let
> spack know about the package that is installed through system installation?
>
> Also, can you help me with the other error that I get when I try to
> refresh the modules?
>
> ==> Error: Cannot use invalid module set default.Valid module set
> names are []
>
> Thanks again for your help.
> Vinayak
>
> On Fri, 12 May 2023 at 3:12 PM, Daniel Arndt 
> wrote:
>
>> Yes, our HDF5 integration only works well with a raw install (like a
>> system package manager provides) that doesn't expose CMake files.
>> https://github.com/dealii/dealii/pull/15199 offers a workaround for that
>> issue but otherwise, it's best to just use the system installation
>> obtainable through
>>
>> apt-get install libhdf5-dev
>>
>> or the like and let spack know about it.
>>
>> Best,
>> Daniel
>>
>> On Fri, May 12, 2023 at 7:55 AM 陈敏  wrote:
>>
>>> Hi, Vinayak Vijay
>>>
>>> I think installing dealii-9.4 with hdf5 using spack maybe some bug, you
>>> can turn off the hdf5 by spack install dealii@9.4.0~hdf5.
>>>
>>> Best
>>> Chen
>>>
>>> Vinayak Vijay  于2023年5月12日周五 17:23写道:
>>>
>>>> Hello,
>>>>
>>>> In order to upgrade the version of dealii, i reinstalled the latest
>>>> version of spack. I have been able to also install dealii using spack.
>>>> However, when i use the command "spack module tcl refresh", i get the
>>>> following error.
>>>>
>>>> ==> Error: Cannot use invalid module set default.Valid module set
>>>> names are []
>>>>
>>>> If i just ignore this and perform "make run" of my code i get the
>>>> following error:
>>>>
>>>> [ 14%] Linking CXX executable main
>>>> /usr/bin/ld.gold: error: cannot find -lhdf5-shared
>>>> collect2: error: ld returned 1 exit status
>>>> make[3]: *** [CMakeFiles/main.dir/build.make:292: main] Error 1
>>>> make[2]: *** [CMakeFiles/Makefile2:90: CMakeFiles/main.dir/all] Error 2
>>>> make[1]: *** [CMakeFiles/Makefile2:123: CMakeFiles/run.dir/rule] Error 2
>>>> make: *** [Makefile:137: run] Error 2
>>>>
>>>> I think these two errors are linked. Can someone point out what i
>>>> should do now?
>>>>
>>>> Note: I was able to perfectly run dealii v9.3 befor this
>>>> reinstallation.
>>>>
>>>> Thanks,
>>>> Vinayak
>>>>
>>>> --
>>>> The deal.II project is located at http://www.dealii.org/
>>>> For mailing list/forum options, see
>>>> https://groups.google.com/d/forum/dealii?hl=en
>>>> ---
>>>> You received this message because you are subscribed to the Google
>>>> Groups "deal.II User Group" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>> an email to dealii+unsubscr...@googlegroups.com.
>>>> To view this discussion on the web visit
>>>> https://groups.google.com/d/msgid/dealii/4a585a05-c8e1-45aa-972d-d01caaaebed2n%40googlegroups.com
>>>> <https://groups.google.com/d/msgid/dealii/4a585a05-c8e1-45aa-972d-d01caaaebed2n%40googlegroups.com?utm_medium=email_source=footer>
>>>> .
>>>>
>>> --
>>> The deal.II project is located at http://www.dealii.org/
>>> For mailing list/forum options, see
>>> https://groups.google.com/d/forum/dealii?hl=en
>>> ---
>>> You received this message because you are subscribed to the Google
>>> Groups "deal.II User Group" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to dealii+unsubscr...@googlegroups.com.
>>>
>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/dealii/CADr3OdKdm-HCp-ZpEwWx8u%2BxHDmprrKvt3VTAzOkVs7C-s9d%2Bg%40mail.gmail.com
>>> <https://groups.google.com/d/msgid/dealii/CADr3OdKdm-HCp-ZpEwWx8u%2BxHDmprrKvt3VTAzOkVs7C-s9d%2Bg%40mail.gmail.com?utm_medium=email_source=footer>
>>> .
>>>
>> --
>> The deal.II pro

Re: [deal.II] Unable to refresh spack module

2023-05-12 Thread Daniel Arndt
Yes, our HDF5 integration only works well with a raw install (like a system
package manager provides) that doesn't expose CMake files.
https://github.com/dealii/dealii/pull/15199 offers a workaround for that
issue but otherwise, it's best to just use the system installation
obtainable through

apt-get install libhdf5-dev

or the like and let spack know about it.

Best,
Daniel

On Fri, May 12, 2023 at 7:55 AM 陈敏  wrote:

> Hi, Vinayak Vijay
>
> I think installing dealii-9.4 with hdf5 using spack maybe some bug, you
> can turn off the hdf5 by spack install dealii@9.4.0~hdf5.
>
> Best
> Chen
>
> Vinayak Vijay  于2023年5月12日周五 17:23写道:
>
>> Hello,
>>
>> In order to upgrade the version of dealii, i reinstalled the latest
>> version of spack. I have been able to also install dealii using spack.
>> However, when i use the command "spack module tcl refresh", i get the
>> following error.
>>
>> ==> Error: Cannot use invalid module set default.Valid module set
>> names are []
>>
>> If i just ignore this and perform "make run" of my code i get the
>> following error:
>>
>> [ 14%] Linking CXX executable main
>> /usr/bin/ld.gold: error: cannot find -lhdf5-shared
>> collect2: error: ld returned 1 exit status
>> make[3]: *** [CMakeFiles/main.dir/build.make:292: main] Error 1
>> make[2]: *** [CMakeFiles/Makefile2:90: CMakeFiles/main.dir/all] Error 2
>> make[1]: *** [CMakeFiles/Makefile2:123: CMakeFiles/run.dir/rule] Error 2
>> make: *** [Makefile:137: run] Error 2
>>
>> I think these two errors are linked. Can someone point out what i should
>> do now?
>>
>> Note: I was able to perfectly run dealii v9.3 befor this reinstallation.
>>
>> Thanks,
>> Vinayak
>>
>> --
>> The deal.II project is located at http://www.dealii.org/
>> For mailing list/forum options, see
>> https://groups.google.com/d/forum/dealii?hl=en
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "deal.II User Group" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to dealii+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/dealii/4a585a05-c8e1-45aa-972d-d01caaaebed2n%40googlegroups.com
>> 
>> .
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/CADr3OdKdm-HCp-ZpEwWx8u%2BxHDmprrKvt3VTAzOkVs7C-s9d%2Bg%40mail.gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKbv2KJLiYb%3DDE7TLNzBRN5V-jRcd0jq_BxFNFYysNLkA%40mail.gmail.com.


Re: [deal.II] Two-component reaction-diffusion equations

2023-05-09 Thread Daniel Arndt
In the end, you have decoupled heat equations so step-26 (
https://www.dealii.org/current/doxygen/deal.II/step_26.html) and tutorials
leading up to it would be good places to start from.

Best,
Daniel

On Tue, May 9, 2023 at 4:26 AM D. Sarkar  wrote:

> Hello, deal.II users,
>
> I am new to deal.II and have basic knowledge of C++ programming. I am
> looking at tutorial examples which are distributed on the website, so that
> I can adapt an example towards the set of boundary value problem (BVP) I am
> trying to solve.
>
> I have a two-component reaction-diffusion equations and attached with this
> post is a PDF file with the governing equations, brief description and
> schematic. Is there a recommended tutorial for these type of BVPs or
> similar deal.II based online documentation that I can read and adapt my
> input file.
>
> Many thanks for your suggestions and advise.
>
> With my best regards,
>
> Daipayan Sarkar, Ph.D.
> MSU-DOE Plant Research Laboratory
> East Lansing, MI, USA
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/6fb0faae-9f58-4bdc-bf08-c04014e0af34n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJyYYCRMjvhDGSNd7KtZ%2BCnfKxPC1A7xuL6UBgqhSYU-g%40mail.gmail.com.


Re: [deal.II] Problem compiling deal.II with CUDA

2023-05-01 Thread Daniel Arndt
Sean,

we removed the implementation for atomic add for doubles for nvcc < 8 and
compute capability < 6 in https://github.com/dealii/dealii/pull/10298
(maybe in error). I would expect that you could the code in that pull
request as a patch.

Best,
Daniel

On Sat, Apr 29, 2023 at 1:46 PM Sean Johnson  wrote:

> Hey everyone,
>
> Sorry I have been working on this problem for a few day. I believe the
> problem is with the mating of deal.II and CUDA because after installing
> CUDA it passed all the post installation tests. The error mentions the
> atomicAdd() function for doubles which is only for compute capability 6.x+
> according to CUDA and my gpu is 5.0 but deal.II says it only needs compute
> capability of 3.2+ so I figure the problem isn't that simple. Below is the
> error code and attached are the log files.
>
> Thanks for any help ahead of time! And sorry if there is anything I missed
> to include as this is my first post on here. I will correct it as soon as I
> can when notified. Thank you again!
>
> Building CUDA object
> source/lac/CMakeFiles/obj_lac_release.dir/cuda_kernels.cu.o
> nvcc warning : The 'compute_35', 'compute_37', 'compute_50', 'sm_35',
> 'sm_37' and 'sm_50' architectures are deprecated, and may be removed in a
> future release (Use -Wno-deprecated-gpu-targets to suppress warning).
> /home/sjohnson/Downloads/dealii-9.4.1/include/deal.II/lac/cuda_atomic.h(54):
> error: no instance of overloaded function "atomicAdd" matches the argument
> list
> argument types are: (double *, double)
>
> /home/sjohnson/Downloads/dealii-9.4.1/include/deal.II/lac/cuda_kernels.templates.h(96):
> error: no instance of overloaded function "atomicAdd" matches the argument
> list
> argument types are: (double *, const double)
>   detected during instantiation of "Number
> dealii::LinearAlgebra::CUDAWrappers::kernel::ElemSum::atomic_op(Number
> *, Number) [with Number=double]"
> /home/sjohnson/Downloads/dealii-9.4.1/source/lac/cuda_kernels.cu(160):
> here
>
> /home/sjohnson/Downloads/dealii-9.4.1/include/deal.II/lac/cuda_kernels.templates.h(132):
> error: no instance of overloaded function "atomicAdd" matches the argument
> list
> argument types are: (double *, const double)
>   detected during instantiation of "Number
> dealii::LinearAlgebra::CUDAWrappers::kernel::L1Norm::atomic_op(Number
> *, Number) [with Number=double]"
> /home/sjohnson/Downloads/dealii-9.4.1/source/lac/cuda_kernels.cu(161):
> here
>
> /home/sjohnson/Downloads/dealii-9.4.1/include/deal.II/lac/cuda_kernels.templates.h(272):
> error: no instance of overloaded function "atomicAdd" matches the argument
> list
> argument types are: (double *, const double)
>   detected during instantiation of "Number
> dealii::LinearAlgebra::CUDAWrappers::kernel::DotProduct::atomic_op(Number
> *, Number) [with Number=double]"
> /home/sjohnson/Downloads/dealii-9.4.1/source/lac/cuda_kernels.cu(175):
> here
>
> 4 errors detected in the compilation of
> "/home/sjohnson/Downloads/dealii-9.4.1/source/lac/cuda_kernels.cu".
> make[2]: *** [source/lac/CMakeFiles/obj_lac_release.dir/build.make:583:
> source/lac/CMakeFiles/obj_lac_release.dir/cuda_kernels.cu.o] Error 1
> make[1]: *** [CMakeFiles/Makefile2:3790:
> source/lac/CMakeFiles/obj_lac_release.dir/all] Error 2
> make: *** [Makefile:130: all] Error 2
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/eb4eb66d-b139-4d5e-b33b-859e9838a119n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbL8gv%3Dj7XR0rmHRySbS%3D79SFNh9UgaM%3DW9oLVVKcAnZDA%40mail.gmail.com.


Re: [deal.II] Applying boundary conditions to a point on the boundary in MP framework

2023-04-19 Thread Daniel Arndt
Wasim,

What does the backtrace in your debugger (gdb?) look like?

Best,
Daniel

On Wed, Apr 19, 2023 at 7:27 AM Wasim Niyaz Munshi ce21d400 <
ce21d...@smail.iitm.ac.in> wrote:

> Hello everyone.
> I am trying to apply a particular boundary condition at one single point
> in the domain for a problem very similar to step-40.
> I am using the following code to do it:
>
> for (const auto  : dof_handler.active_cell_iterators())
>   if (cell->is_locally_owned())
>
>   {
>   for (const auto  : cell->face_iterators())
>
>   for (const auto vertex_number : cell->vertex_indices())
>   {
>   const auto vert = cell->vertex(vertex_number);
>   const Point<2>& node = vert;
>   if (std::fabs(node(0)<1e-12) )
>   {
> const unsigned int dof = cell->vertex_dof_index(vertex_number, 0);
>   constraints.add_line(dof);
>   constraints.set_inhomogeneity(dof,1);
>   } // This set a scalar at node to value 1
>
>   }
>
>   }
>
> However, I am getting a segmentation fault. Kindly provide some help in
> this regard.
>
> Thanks
> Wasim
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/eea6e885-5e7a-4330-b769-4272a70af626n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJQ6CxsB7aPQJvLLTfrX3%3DOo%3DB7QMDjbhLX%3DrZeELC3BA%40mail.gmail.com.


Re: [deal.II] Trouble installing p4est from candi M1 mac

2023-04-10 Thread Daniel Arndt
Matteo,

what happens if you just use p4est CMake installation interface instead of
our scripts? You probably only need to make sure to enable MPI support.

Best,
Daniel

On Mon, Apr 10, 2023 at 8:25 AM Matteo Malvestiti 
wrote:

> Hi, thanks for your response!
> Could you please tell me how to compile with clang instead of gcc?
> Unfortunately I’m a beginner at using the command line...
>
> I’ve done this:
>
> export CC=clang; export CXX=clang++; export FC=mpifort; export
> FF=mpifort; \
>
> OMPI_CC=clang; export OMPI_CXX=clang++; export OMPI_FC=gfortran-1
>
> But I still get the same error:
>
> Build FAST: /Users/##/dealii-candi/tmp/build/p4est-2.3.2/FAST
>
> Build DEBUG: /Users/##/dealii-candi/tmp/build/p4est-2.3.2/DEBUG
>
> Install FAST: /Users/##/dealii-candi/p4est-2.3.2/FAST
>
> Install DEBUG: /Users/##/dealii-candi/p4est-2.3.2/DEBUG
>
> Checking environment: CFLAGS P4EST_CFLAGS_FAST P4EST_CFLAGS_DEBUG
>
> See output in files .../config.output and .../make.output
>
>
> Build FAST version in /Users/##/dealii-candi/tmp/build/p4est-2.3.2/FAST
>
> /Users/##/dealii-candi/tmp/unpack/p4est-2.3.2/configure: line 4056:
> test: argument expected
>
> configure: error: in
> `/Users/##/dealii-candi/tmp/build/p4est-2.3.2/FAST':
>
> configure: error: Fortran 77 compiler cannot create executables
>
> See `config.log' for more details
>
> Error: Error in configure
>
> Great thanks in advance!
> Matteo
>
> Il giorno 7 apr 2023, alle ore 13:11, blais...@gmail.com <
> blais.br...@gmail.com> ha scritto:
>
> What I would suggest is to not use GCC, but instead use the clang compiler
> native with the Mac M1.
> At least this is how I did it on my apple M1 macbook pro computer
>
>
> On Thursday, April 6, 2023 at 6:25:13 a.m. UTC-4 malve...@gmail.com wrote:
>
>> Good afternoon.
>> I’m truly sorry to bother you, but I’ve spent a lot of time trying to fix
>> this problem, without any success.
>> I’m trying to install dealii on my M1 macbook air with MacOs Ventura.
>> Ive been following the guide on
>> https://github.com/dealii/dealii/wiki/Apple-ARM-M1-OSX
>>
>> I installed brew
>> I verified I have mac developer tools updated
>> Using brew I installed cmake and openmpi.
>> Using brew, with much more effort and not complete certainty of success,
>> I installed gcc11.
>>
>> I cloned candi git repo.
>> I set the following env variables, to use clang instead of gcc11:
>>
>> *export CC=mpicc; export CXX=mpicxx; export FC=mpifort; export
>> FF=mpifort; \  OMPI_CC=clang; export OMPI_CXX=clang++; export
>> OMPI_FC=gfortran-1*
>> I began installing the packages together but had troubles.
>>
>> So I proceeded doing them one by one.
>> hdf5 went fine
>> But p4est exits with the following error:
>>
>>
>>
>>
>>
>>
>>
>> *Build FAST version in
>> /Users/matteom/dealii-candi/tmp/build/p4est-2.3.2/FAST/Users/##/dealii-candi/tmp/unpack/p4est-2.3.2/configure:
>> line 4056: test: argument expectedconfigure: error: in
>> `/Users/##/dealii-candi/tmp/build/p4est-2.3.2/FAST':configure: error:
>> Fortran 77 compiler cannot create executablesSee `config.log' for more
>> detailsError: Error in configure*
>> Note: I even tried to switch to Master branch, but nothing changed.
>>
>>
>> Do you have any clue what I could try next?
>>
>> Thanks for your cooperation.
>> Best wishes,
>> Matteo Malvestiti
>>
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/24357a2e-1b43-4ed3-b841-19760e650d96n%40googlegroups.com
> 
> .
>
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/658FE192-4447-4B23-B066-4EE015375153%40gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails 

Re: [deal.II] Extracting element solution in step-40

2023-04-07 Thread Daniel Arndt
Wasim,

step-40 uses Q2 elements which means that you have 9 dofs/cell in 2D and
for 32 cells in each direction (33+32)^2=65^2=4225 dofs.

Best,
Daniel



On Fri, Apr 7, 2023 at 5:47 AM Wasim Niyaz Munshi ce21d400 <
ce21d...@smail.iitm.ac.in> wrote:

> Thank You, Prof. Bangerth.
> I have one more doubt about the output of step-40.
> For cycle 0, there are 1024 cells (32*32 mesh). So, we have 33 nodes each,
> along x and y. So, shouldn't the number of DOFs be 1089 instead of 4225?
>
> Regards
> Wasim
>
> On Thursday, April 6, 2023 at 11:27:32 PM UTC+5:30 Wolfgang Bangerth wrote:
>
>> On 4/6/23 10:18, Wasim Niyaz Munshi ce21d400 wrote:
>> > How do I get the no.of cells owned by the processor?
>>
>> Triangulation::n_locally_owned_active_cells().
>>
>> Best
>> W.
>>
>> --
>> 
>> Wolfgang Bangerth email: bang...@colostate.edu
>> www: http://www.math.colostate.edu/~bangerth/
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/2b5174fe-2358-40b3-b404-1bcdfc332e62n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BWiZ8b1fkgCwctSVqQaBo9LZ6Rdj%2Bv5dAdPA0oaimXVA%40mail.gmail.com.


Re: [deal.II] Extracting element solution in step-40

2023-04-06 Thread Daniel Arndt
Wasim,

The answer depends very much on what you actually want to do with that
solution vector.
Do you want a representation of the solution (assuming you are using Q1?
nodal elements) on a single process/all processes
or are you just interested in the partial solution on every process
separately?
What you are doing looks quite similar to what DataOut would give you for
visualizing solutions.

Best,
Daniel

On Thu, Apr 6, 2023 at 8:02 AM Wasim Niyaz Munshi ce21d400 <
ce21d...@smail.iitm.ac.in> wrote:

> Hello everyone.
> I want to extract the element solution vector from the global solution
> once the problem is solved in step-40. For a serial code, I would do
> something like this:
>
> *int i=0;*
>
>
>
> *for (const auto vertex : cell->vertex_indices()) { int a =
> (cell->vertex_dof_index(vertex, 0)); element_sol[i] =  solution_vector[a];*
>
> *  i=i+1; }*
>
> I don't have a solution_vector for a parallel code, but a
> locally_relevant_solution. I want to know that, given this
> locally_relevant_solution and the cell, how do I get the element_sol?
> The global_dof will not be helpful here, as the solution_vector is
> distributed across a number of processors.
>
> Thanks and regards
> Wasim
>
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/b2834b5b-f4f2-4931-9c5e-3f40d91b0648n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BCgOgk6%2BWr%2BMZBXaRwtK9OQgDFs-JkcuGeRCtRWb8nAg%40mail.gmail.com.


Re: [deal.II] Compile deal.ii with metis

2023-04-05 Thread Daniel Arndt
 Li Xiangyue,

You need to tell deal.II to enable METIS support using a CMake option. Have
a look at https://dealii.org/9.1.1/users/cmake.html#configurefeature.

Best,
Daniel

On Wed, Apr 5, 2023 at 3:59 AM 李相越  wrote:

> Dear deal.ii developers,
>
> I’m Li Xiangyue, a novice programmer. I initially installed deal.ii
> through “sudo apt-get install libdeal.ii-dev”. When I tried to run STEP17,
> I realized that I needed to compile deal.ii with metis. Now I have
> installed metis through “sudo apt-get install libmetis-dev”. What should I
> do next?
>
> Thank you for your time and I look forward to hearing from you!
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/CAH9TCVtOPx1my%3DH6hMQR4SWMTboruquTF%3DBrGjw0W7Hn6s4P-g%40mail.gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKAveB8D-Z1%3Df1_dtoBLN-_ScZikv4kBFsqxJ%2BThDKK5Q%40mail.gmail.com.


Re: [deal.II] Linking error when compiling examples: undefined reference to 'boost::archive::archive_exception::archive_exception(boost::archive::archive_exception const&)'

2023-03-21 Thread Daniel Arndt
Laryssa,

The bundled boost package only includes the files that are used within
deal.II. If you want to use additional boost features, you should build
boost yourself (and tell deal.II where to find it).

Best,
Daniel

On Tue, Mar 21, 2023 at 1:19 PM Laryssa Abdala  wrote:

>
> Great, that solved the problem. Thank you.
> The problem was that I had extracted the boost headers locally and had not
> built/installed it. David Wells (thanks David!) reported the issue here:
> https://github.com/dealii/dealii/issues/14925. Since then, I have been
> trying to link one of my projects against deal.ii (copy with bundled boost)
> and I get this error:
>
> c++: error: unrecognized command line option ‘-fopenmp-simd’
> make[2]: *** [Tests/CodimHeatEquation/CMakeFiles/demo.dir/demo.cc.o] Error
> 1
> make[1]: *** [Tests/CodimHeatEquation/CMakeFiles/demo.dir/all] Error 2
> make[1]: *** Waiting for unfinished jobs
> [  6%] Building CXX object CMakeFiles/fchep.dir/src/Datafile.cpp.o
> [ 13%] Building CXX object CMakeFiles/fchep.dir/src/EPSolver.cpp.o
> [ 13%] Building CXX object
> CMakeFiles/fchep.dir/src/IonicModels/FentonKarma4v.cpp.o
> [ 16%] Building CXX object
> CMakeFiles/fchep.dir/src/IonicModels/IonicModel.cpp.o
> [ 20%] Building CXX object
> CMakeFiles/fchep.dir/src/IonicModels/MinimalModel.cpp.o
> [ 23%] Building CXX object
> CMakeFiles/fchep.dir/src/IonicModels/NashPanfilov.cpp.o
> [ 26%] Building CXX object
> CMakeFiles/fchep.dir/src/IonicModels/Passive.cpp.o
> [ 30%] Building CXX object
> CMakeFiles/fchep.dir/src/IonicModels/Ryzhii.cpp.o
> [ 40%] Building CXX object CMakeFiles/fchep.dir/src/Timer.cpp.o
> [ 40%] Building CXX object CMakeFiles/fchep.dir/src/TimeData.cpp.o
> [ 40%] Building CXX object
> CMakeFiles/fchep.dir/src/IonicModels/vanderPolDuffing.cpp.o
> In file included from
> /nas/longleaf/home/laryssa/dogwood/sfw/dealii/install-dbg/include/deal.II/bundled/boost/fusion/support/tag_of.hpp:14:0,
>  from
> /nas/longleaf/home/laryssa/dogwood/sfw/dealii/install-dbg/include/deal.II/bundled/boost/fusion/support/category_of.hpp:11,
>  from
> /nas/longleaf/home/laryssa/dogwood/sfw/dealii/install-dbg/include/deal.II/bundled/boost/fusion/adapted/struct/detail/extension.hpp:14,
>  from
> /nas/longleaf/home/laryssa/dogwood/sfw/dealii/install-dbg/include/deal.II/bundled/boost/fusion/adapted/struct/adapt_struct.hpp:22,
>  from
> /nas/longleaf/home/laryssa/dogwood/sfw/dealii/install-dbg/include/deal.II/bundled/boost/fusion/adapted/std_pair.hpp:14,
>  from
> /nas/longleaf/home/laryssa/dogwood/sfw/dealii/install-dbg/include/deal.II/bundled/boost/fusion/include/std_pair.hpp:11,
>  from /nas/longleaf/home/laryssa/fch-ep/src/Datafile.h:11,
>  from /nas/longleaf/home/laryssa/fch-ep/src/Datafile.cpp:8:
>
> /nas/longleaf/home/laryssa/dogwood/sfw/dealii/install-dbg/include/deal.II/bundled/boost/fusion/support/detail/is_mpl_sequence.hpp:12:69:
> fatal error: boost/fusion/support/detail/is_native_fusion_sequence.hpp: No
> such file or directory
>  #include 
>  ^
> compilation terminated.
>
> Shouldn't fusion be available once I use the bundled version of boost? I
> am not sure what to get out of this error message.
>
> Thanks again,
> Laryssa
>
>
> On Monday, March 20, 2023 at 1:51:24 PM UTC-4 Wolfgang Bangerth wrote:
>
>> On 3/19/23 15:47, Laryssa Abdala wrote:
>> >
>> > I've tried using different versions of boost, but have not been
>> > successful with any. I've attached the detailed.log if anyone could
>> help
>> > me.
>>
>> Laryssa, I don't know specifically what causes this error, but you can
>> almost certainly avoid it if you use the bundled version of deal.II. I
>> believe that you can achieve that by passing
>> -DEAL_II_FORCE_BUNDLED_BOOST=ON
>> to cmake when you configure. In the output, cmake currently reports
>> (based on the file you had attached) this:
>> # DEAL_II_WITH_BOOST set up with external dependencies
>> With the flag above, it should then say that it is using the 'bundled'
>> version of BOOST instead.
>>
>> Best
>> W.
>>
>>
>> --
>> 
>> Wolfgang Bangerth email: bang...@colostate.edu
>> www: http://www.math.colostate.edu/~bangerth/
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/261cbc2d-7920-4000-8cc3-154d148b32a4n%40googlegroups.com
> 

Re: [deal.II] Using affine constraints object to apply boundary condition at a vertex

2023-03-12 Thread Daniel Arndt
Wasim,

Have a look at step-11 (
https://www.dealii.org/current/doxygen/deal.II/step_11.html).

Best,
Daniel

On Sun, Mar 12, 2023 at 9:17 AM Wasim Niyaz Munshi ce21d400 <
ce21d...@smail.iitm.ac.in> wrote:

> I am solving an elasticity problem wherein I have a pin support at one
> vertex. Earlier, I was using std::map object to apply BCs. Now, I am trying
> to solve the same problem using an affine constraint object to apply BCs.
> But, I am facing issues filling my affine constraint object with the
> information corresponding to the vertex with pin support.
>
> I was doing the following for my std::map boundary_values object:
>
> for (const auto  : dof_handler.active_cell_iterators())
> {
> for (const auto  : cell->face_iterators())
>
> for (const auto vertex_number : cell->vertex_indices())
> {
> const auto vert = cell->vertex(vertex_number);
> if (vertices satisfy the condition)
> {
>
>types::global_dof_index x=
> cell->vertex_dof_index(vertex_number, 0);
> boundary_values[x] = 0;
>
> types::global_dof_index y=
> cell->vertex_dof_index(vertex_number, 1);
> boundary_values[y] = 0;
> }
> }
>
> }
>
> What changes should I do to fill my constraint object with the same
> information?
> Thanks and regards
> Wasim Niyaz
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/932c962f-e382-4c73-9ab3-a1486b2624b4n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKxTZ4raz%2BShKajZKXVbknaq-b8uLYmGz%2BVJ0pyyf4VRg%40mail.gmail.com.


Re: [deal.II] How to apply Spherical Manifold

2023-02-21 Thread Daniel Arndt
Deepika,

https://www.dealii.org/current/doxygen/deal.II/namespaceGridGenerator.html#a533c4778cbc9bcbed365dcab42ca4418
says

By default, the manifold_id is set to 0 on the boundary faces, 1 on the
boundary cells, and numbers::flat_manifold_id

on the central cell and on internal faces. A SphericalManifold

is attached by default to the boundary faces for correct placement of
boundary vertices upon refinement and to be able to use higher-order
mappings.

It seems that you are trying to assign a SphericalManifold object to the
central cell. This doesn't work properly because the manifold is singular
at the center. Instead, you should only assign it to the boundary cells of
the hyper ball parts of your triangulation. If the mesh doesn't look good
enough after refining, you also might want to have a look at
https://www.dealii.org/current/doxygen/deal.II/classTransfiniteInterpolationManifold.html
and https://www.dealii.org/current/doxygen/deal.II/step_65.html.
Best,
Daniel



On Mon, Feb 20, 2023 at 10:37 PM Deepika Kushwah <
deepika20263...@iitgoa.ac.in> wrote:

> Thank you very much sir for your explanation.
>
> I have assigned material id to different domains. Now I am trying to set
> spherical manifold id by using the following code
>
>
>   for (const auto  : tri.cell_iterators())
>{
>  double v = (cell->center()[0])*(cell->center()[1]) ;
>
>   if ((cell->center()[0] > -0.5) && (cell->center()[1] > -0.5) &&
> (cell->center()[0] < 0.5) && (cell->center()[1] < 0.5) && v>0)
>   {
>  cell->set_material_id(15);
>   }
>
>  else
>  {
>  cell->set_material_id(20);
>  }
>   }
>
>
>
>
>
>
>
>
>
>
>
> * for (auto  : tri.active_cell_iterators())  {if
> ((cell->center()[0] == -0.25) && (cell->center()[1] == -0.25) &&
> cell->material_id() == 15){   cell->set_all_manifold_ids(10);
>   }   if ((cell->center()[0] == 0.25) && (cell->center()[1] ==
> 0.25) && cell->material_id() == 15){
>  cell->set_all_manifold_ids(12);} }  *
>  tri.reset_all_manifolds();
> //tri.set_all_manifold_ids(0);
>
>
> const SphericalManifold<2> manifold_neg(center);
>  //tri.set_all_manifold_ids_on_boundary(10);
>   tri.set_manifold (10, manifold_neg);
>
> //tri.set_all_manifold_ids_on_boundary(12);
> const  SphericalManifold<2> manifold_pos(center_1);
>  tri.set_manifold (12, manifold_pos);
>
>  tri.refine_global(3);
>
> but it is showing the following error:
> [image: image.png]
>
> I am not understanding the meaning of this, can you please elaborate it.
>
>
> Thanks
> Deepika
>
> On Mon, Feb 20, 2023 at 2:00 PM Luca Heltai  wrote:
>
>> At the moment, you are setting the manifold ID on the boundary of your
>> *domain* with the call to
>>
>>
>> tri.set_all_manifold_ids_on_bounary(4);
>> tri.set_manifold (4, manifold_neg);
>>
>> And then you are telling the triangulation to use on it the
>> SphericalManifold<2> manifold_neg(center).
>> Then you re-do the same thing (i.e., you define all boundaries *of the
>> triangulation*) with the other id (5), and again set another manifold
>>
>>
>> tri.set_all_manifold_ids_on_bounary(5);
>> tri.set_manifold (5, manifold_neg);
>>
>> The effect of this is: your domain *boundary* now has id 5, and in fact
>> the faces of the boundary, upon refinement try to refine according to polar
>> coordinates around the center of `manifold_neg`.
>>
>> what you really want to do is to identify the regions you want to behave
>> like manifold_neg (NOT the domain boundary, so the call to
>> tri.set_all_manifold_ids_on_bounary should not be there).
>>
>> in your first picture, identify the cells that belong to id 4:
>>
>> for cell in first region:
>> cell->set_all_boundary_ids(4);
>>
>> then do the same with the second region:
>>
>> for cell in first region:
>> cell->set_all_boundary_ids(5);
>>
>> and at this point instruct the triangulation that those two different
>> region, follow different manifold rules:
>>
>> tri.set_manifold (4, manifold_neg);
>> tri.set_manifold (5, manifold_pos);
>>
>> The logic here is this one:
>>
>> 1. identify what region is described by what manifold (cell, face, line,
>> etc. ->set_manifold_id(…)) using an identification (a manifold id)
>> 2. tell the triangulation that the region identified by the chosen
>> manifold id must obey the given manifold description
>> (tria.set_manifold(manifold_id, manifold_object)
>>
>> You are doing this with the boundary of the domain (that has nothing to
>> do with the regions you colored differently), and you are assigning *the
>> same id* to the two regions, so the triangulation does what you asked for:
>> it uses only one descriptor (because the other id is not present in the
>> triangulation), and it uses it in both regions *and* on the boundary.
>>
>> L.
>>
>>
>>
>>
>> > On 20 

Re: [deal.II] Discontinous Galerkin with periodic boundary conditions

2023-02-17 Thread Daniel Arndt
Nils,

Using DG with periodic boundary conditions is not very common to my
knowledge. It seems you are hitting a bug in deal.II in Debug mode and it
should work with

diff --git a/include/deal.II/meshworker/mesh_loop.h
b/include/deal.II/meshworker/mesh_loop.h
index f46c737c2a..699264551e 100644
--- a/include/deal.II/meshworker/mesh_loop.h
+++ b/include/deal.II/meshworker/mesh_loop.h
@@ -570,7 +570,10 @@ namespace MeshWorker

 // Now neighbor is on the same refinement level.
 // Double check.
-Assert(!cell->neighbor_is_coarser(face_no),
+Assert((!periodic_neighbor &&
+!cell->neighbor_is_coarser(face_no)) ||
+ (periodic_neighbor &&
+
 !cell->periodic_neighbor_is_coarser(face_no)),
ExcInternalError());

 // If we own both cells only do faces from one side
(unless

Best,
Daniel


On Fri, Feb 17, 2023 at 7:20 AM Nils Schween 
wrote:

> Hmmm ... I really I do not would like to be impatient.
>
> Can no one help me with setting up periodic boundary conditions for
> discontinuous elements? Is it uncommon to do this?
>
> Probably a small example code would be enough to get me started.
>
> Thank you very much.
> With best regards,
> Nils
>
>
> Nils Schween  writes:
>
> > Dear deal.ii community,
> >
> > first of all, a big thank you for all the effort going into this
> > software.
> >
> > I am currently developing an application and I stumbled upon
> > implementing periodic boundary conditions for discontinuous Lagrange
> > elements.
> >
> > I found the following thread
> > https://groups.google.com/g/dealii/c/WlOiww5UVxc/m/mtQJDUwiBQAJ
> >
> > In this thread Dr. Arndt explains that when discontinuous elements were
> > used, it made more sense to enforce boundary conditions weakly instead
> > of using strong boundary conditions. In deal.ii this seems to be
> > tantamount to telling the MeshWorker to treat the boundary faces as
> > internal faces without using an additional constraint matrix enforcing
> > the equality of DoFs on the periodic parts of the domain.
> >
> > If I understand correctly the MeshWorker can be informed to treat the
> > boundary faces as internal faces by modifying the triangulation with a
> > call of the function triangulation.add_periodocity(periodicity_vector).
> > Where the periodicity vector is filled by calling the function
> > collect_periodic_faces.
> >
> > I tried this and it works as expected in 1D, but in 2D I get the
> > following error message.
> >
> >> An error occurred in line <1001> of file
> 
> in function
> >> const Accessor& dealii::TriaRawIterator::operator*()
> const [with Accessor = dealii::CellAccessor<2, 2>]
> >> The violated condition was:
> >> Accessor::structure_dimension != Accessor::dimension || state() ==
> IteratorState::valid
> >> Additional information:
> >> You tried to dereference a cell iterator for which this is not
> >> possible. More information on this iterator: level=-1, index=-1,
> >> state=past_the_end
> >
> > I adapted the step 12 tutorial such that it is easy for you to reproduce
> > the error. I attach the code to this email. Just change the template
> > argument for the parameter dim from 1 to 2 to see for yourself.
> >
> > I should mention the adapted tutorial is not working with a distributed
> > triangulation. In my application I am. So at first I thought, that I was
> > using a wrong filter for the iterator range which I am handing over to
> > mesh_loop function. But since the error persist even when using only one
> > processor, it must be something else.
> >
> > What am I doing wrong? Any help is appreciated.
> > Thank you very much.
> >
> > Regards,
> > Nils
> >
> > --
> > The deal.II project is located at http://www.dealii.org/
> > For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> > ---
> > You received this message because you are subscribed to the Google
> Groups "deal.II User Group" group.
> > To unsubscribe from this group and stop receiving emails from it, send
> an email to dealii+unsubscr...@googlegroups.com.
> > To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/87pmadlmn0.fsf%40mpi-hd.mpg.de.
> >
> > [2. adapted_step12 --- application/octet-stream;
> periodic_boundary_step12.cpp]...
> >
> >
> > --
> > Nils Schween
> > PhD Student
> >
> > Phone: +49 6221 516 557
> > Mail: nils.schw...@mpi-hd.mpg.de
> > PGP-Key: 4DD3DCC0532EE96DB0C1F8B5368DBFA14CB81849
> >
> > Max Planck Institute for Nuclear Physics
> > Astrophysical Plasma Theory (APT)
> > Saupfercheckweg 1, D-69117 Heidelberg
> >
> https://www.mpi-hd.mpg.de/mpi/en/research/scientific-divisions-and-groups/independent-research-groups/apt
>
>
> --
> Nils Schween
> PhD Student
>
> Phone: +49 6221 516 557
> Mail: nils.schw...@mpi-hd.mpg.de
> PGP-Key: 4DD3DCC0532EE96DB0C1F8B5368DBFA14CB81849
>
> Max Planck Institute 

Re: [deal.II] VectorTools::interpolate_boundary_values doesn't work for DG

2023-01-04 Thread Daniel Arndt
Abbas,

Yes, FE_DGQ only defines dofs in the interior of cells. Thus, trying to
interpolate the boundary has no effect. You would normally use penalty
terms to prescribe boundary values for DG methods.

Best,
Daniel

On Wed, Jan 4, 2023 at 6:04 PM Abbas  wrote:

> Hello,
>
> The VectorTools::interpolate_boundary_values function works for
> interpolating fe_Q functions but not fe_DGQ .
> Was this meant to be the case?
> I attached a minimal code that illustrates this.
>
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/0a8d1da6-e564-45de-bc3d-1f5a9d5dfad9n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKhorQ25J5C0YJgHLbo2qq%3Dtrb6MzdPMi%2B_n4wrfh4nOg%40mail.gmail.com.


Re: [deal.II] Linking warning: could not create compact unwind for ___emutls_get_address: registers 23 and 24 not saved contiguously in frame

2022-12-14 Thread Daniel Arndt
Praveen,

I'm also seeing this warning and from what I found on the internet it's
harmless. Exception handling might be a bit slower but that's about it.

Best,
Daniel

On Tue, Dec 13, 2022 at 11:22 PM Praveen C  wrote:

> Hello
>
> When compiling deal.ii on macos M1 with clang I get these messages while
> linking
>
> [ 90%] *Linking CXX shared library ../lib/libdeal_II.g.dylib*
>
> ld: warning: could not create compact unwind for ___emutls_get_address:
> registers 23 and 24 not saved contiguously in frame
>
>
> Compiling succeeds and examples seem to run, though I see those warnings
> there also
>
>
> [100%] Built target release
>
> *Consolidate compiler generated dependencies of target step-3*
>
> [ 50%] Building CXX object CMakeFiles/step-3.dir/step-3.cc.o
>
> [100%] *Linking CXX executable step-3*
>
> ld: warning: could not create compact unwind for ___emutls_get_address:
> registers 23 and 24 not saved contiguously in frame
> [100%] Built target step-3
>
> But is this something we can ignore or needs to be fixed ?
>
> Thanks
> praveen
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/EB9A235B-3BCA-4D74-8F2A-43A4EDA8%40gmx.net
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BfLUkb6587WZT5pwV8gPD9Wfs3zP_h_E9e01M3QNQe-A%40mail.gmail.com.


Re: [deal.II] Hoe to merge hyper_cube_with_cylindrical_hole with hyper_ball()

2022-12-07 Thread Daniel Arndt
Deepika,

You will need to appropriate manifolds ids and manifolds after merging the
triangulations. Also, you need to make sure that the coarse triangulations
share the same vertices and edges at the interior boundary.

Best,
Daniel

On Wed, Dec 7, 2022 at 2:24 AM Deepika Kushwah 
wrote:

> Hello Everyone,
>
> I am trying to create a triangulation
> with hyper_cube_with_cylindrical_hole function but in place of hole I want
> to use solid inclusion. I tried with
> function GridGenerator::merge_triangulations(tria_inner, tria_outer,
> triangulation) but I am getting the following geometry ( see the
> attachment).
>
> How to resolve this please help.
>
> Thanks & Regards
> Deepika
>
>
>
> **
> This e-mail is for the sole use of the intended recipient(s) and may
> contain confidential and privileged information. If you are not the
> intended recipient, please contact the sender by reply e-mail and destroy
> all copies and the original message. Any unauthorized review, use,
> disclosure, dissemination, forwarding, printing or copying of this email
> is strictly prohibited and appropriate legal action will be taken.
> 
> 
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/d1f3c6a3-a408-4de8-905c-121b4e5a2c42n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJF08Jerh715DLwDDejHZoUiGNoz-%3D9SSboOuRjmJOAgA%40mail.gmail.com.


Re: [deal.II] Re: Getting global DoF indices of a face

2022-11-22 Thread Daniel Arndt
Alexander,

Yes, we are identifying DoFs on faces and thus FE_DGQ doesn't have any DoFs
on faces.

Best,
Daniel

On Tue, Nov 22, 2022 at 6:48 AM Alexander Kiselyov <
aleksandr.kisel...@gmail.com> wrote:

> Dear Peter,
>
> Thank you for the reply!
>
> The thing is that the input data is a FE_DGQ DoF vector, and I would
> rather not project it into FE_Q elements. The original plan was not to
> create a separate dummy DoFHandler, but your idea seems like a solution for
> my issue.
>
> Still, I'm a bit confused about why FE_DGQ doesn't contain face DoFs. Is
> the reason that in this case DoF indices would be different when looking on
> either sides of a face?
>
> Regards,
> Alexander
>
> On Sun, 2022-11-20 at 08:43 -0800, Peter Munch wrote:
>
> Hi Alexander,
>
> You are using FE_DGQ, which per definition only has DoFs in the cell.
> Switch to quadratic FE_Q and then your idea with the dummy DoFHandler to
> globally uniquely identify faces should work! Not sure why you create a
> system!?
>
> Peter
>
> On Friday, 18 November 2022 at 18:30:38 UTC+1 Alexander Kiselyov wrote:
>
> Dear deal.II users,
>
> I'm currently developing a way to uniquely identify a boundary face on
> a mesh. My idea has been to gather global DoF indices on a face and
> hash them together. However, `get_dof_indices` method of a face
> accessor doesn't return any useful information, and
> `FESystem::max_dofs_per_face()`, surprisingly, returns 0. See the
> attachment for a minimal example. The problem persists when running on
> a single process. The version of deal.II used is 9.4.0.
>
> What am I doing wrong here? Is there a better way to globally identify
> a face?
>
> Best regards,
> Alexander Kiselyov
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/54a20ebc-b6e2-479d-8eed-d236e1ee90cdn%40googlegroups.com
> 
> .
>
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/a3badbdabac248c7524fb6fd353138a8ad525e0c.camel%40gmail.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BnpDRpcEVbJhkDk6gsdkjwpPyvdJMV%3D%3DZUH%2B_jfJ0ciw%40mail.gmail.com.


Re: [deal.II] Tutorial 40 , error: use of deleted function

2022-11-07 Thread Daniel Arndt
You would get this compile-time error if you haven't configured deal.II
with `DEAL_II_WITH_MPI=ON`.

Best,
Daniel

On Mon, Nov 7, 2022 at 9:51 AM ztdep...@gmail.com 
wrote:

> when i compile the tutorial 40, i met the following error. It semms that
> the function has been deleted.
>
>  error: use of deleted function
> ‘dealii::parallel::distributed::Triangulation spacedim>::Triangulation(const MPI_Comm&, typename
> dealii::Triangulation::MeshSmoothing,
> dealii::parallel::distributed::Triangulation::Settings)
> [with int dim = 2; int spacedim = 2; MPI_Comm = int; typename
> dealii::Triangulation::MeshSmoothing =
> dealii::Triangulation<2, 2>::MeshSmoothing]’
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/6682d965-46f7-4ca7-b3e6-a5a365e138ffn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbL4LaLhgDqdT%2BXWJBfzobJfF7GDFkKoRxr%3Dbv7%2BYJ7r-w%40mail.gmail.com.


Re: [deal.II] Applying a zero constraints to cell based on material_id

2022-10-31 Thread Daniel Arndt
Bruno,

I don't think we have a function that would do that already. I would just
loop over all (locally relevant) cells, and add the respective (locally
relevant) dofs to the AffineConstraints object with add_line().

Best,
Daniel

On Mon, Oct 31, 2022 at 8:36 AM blais...@gmail.com 
wrote:

> Dear all, I hope you are all doing fine :)!
>
> I am trying to do some quick testing of something and this would require
> me applying a zero constraint to a set of cells which have a specific
> material id. I could surely do that from the weak form, but I was wondering
> if there was a way to do it strongly by applying a constraint like we do
> with boundary conditions (e.g. using VectorTools). I looked around in the
> documentation but I could not find anyway (but maybe I did not look
> carefully enough).
>
> Thanks!
> Bruno
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/0605a226-d35e-4286-ad2e-13a7b1c185e9n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2Be%2B2YfWJVDnc_%2BUpFrG3h3ZKDoSOSsf2saFLqOKhs_8A%40mail.gmail.com.


Re: [deal.II] C++ language in step16

2022-09-26 Thread Daniel Arndt
cell_worker and copier are lambda functions. You can think of them as
in-place structs with a call operator (operator()) with the specified
signature. We define a new cell_worker object because the place we are
passing it into expects the object to have a call operator that does what
this->cell_worker implements.

Best,
Daniel

On Sun, Sep 25, 2022 at 11:02 PM 'yy.wayne' via deal.II User Group <
dealii@googlegroups.com> wrote:

> In step16 function assemble_system() and assemble_multigrid(), there are 2
> variables/functions defined as:
> auto cell_worker =
> [&](const typename DoFHandler::active_cell_iterator ,
> ScratchData & scratch_data,
> CopyData & copy_data)
>{ this->cell_worker(cell, scratch_data, copy_data); };
> auto copier =
> [&](const CopyData )
>{ this->constraints.distribute_local_to_global(cd.cell_matrix,
>
>  cd.cell_rhs,
>
>  cd.local_dof_indices,
>
>  system_matrix, system_rhs); };
> I'm not expert in C++ and these codes seem confusing to me. Are
> *cell_worker* and *copier* defined here variables or functions? And why
> we define a new cell_worker here (is it because we cannot directly pass
> this->cell_worker to MeshWorker::mesh_loop) ? Sorry it might be silly.
> Should I know the terminology for this "technique" I can google myself.
> Thank you.
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/c284ce35-13ec-4afd-8ef3-5fdde8fd68can%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJ191WrR2nriTJj2XQpi_0SmW%3DOh%3D_VdoOTg8GNHnDNHg%40mail.gmail.com.


Re: [deal.II] Issue linking GMSH when installing & building dealii 9.4

2022-09-08 Thread Daniel Arndt
Matthew,

I don't know if the missing references are due to missing components in
your gmsh installation (but I wouldn't be surprised).
In any way, *"netgen, tetgen and blas support has to be enabled in Gmsh" *
relates to CMake options when building gmsh from source, e.g.,
https://gmsh.info/src/gmsh-4.10.5-source.tgz.
I would try if building gmsh yourself with those dependencies/options
resolves the issue.

Best,
Daniel

On Thu, Sep 8, 2022 at 9:48 AM Matthew Rich  wrote:

> Hi all,
>
> I was upgrading the 9.4 and I needed to include GMSH for a project I am
> working on so I can use the API in my dealii code. I am getting the
> following error despite getting the all clear from CMAKE. How can I fix
> this , are there version limits on GMSH? I did notice this line* "netgen,
> tetgen and blas support has to be enabled in Gmsh"  *How does one ensure
> that? I do not see much in their github readme.
>
> *Some details- *
> On a windows system running dealii in WSL2 under debian. I have built gmsh
> from source and it is functional by itself, so I feel I did that part
> right.  I have -DGMSH_DIR set to the root directory of my gmsh installation
> so ~/gmsh-gmsh-4.10.5 cmake settings when I install dealii
>
> *make Error *
> [ 75%] Linking CXX executable ../bin/step_3_mixed.debug
> ../lib/libdeal_II.g.so.9.4.0: error: undefined reference to
> 'gmsh::model::addPhysicalGroup(int, std::vector >
> const&, int)'
> ../lib/libdeal_II.g.so.9.4.0: error: undefined reference to
> 'gmsh::model::mesh::removeDuplicateNodes()'
> ../lib/libdeal_II.g.so.9.4.0: error: undefined reference to
> 'gmsh::initialize(int, char**, bool)'
> collect2: error: ld returned 1 exit status
> make[2]: *** [examples/CMakeFiles/step_3_mixed.debug.dir/build.make:292:
> bin/step_3_mixed.debug] Error 1
> make[1]: *** [CMakeFiles/Makefile2:3926:
> examples/CMakeFiles/step_3_mixed.debug.dir/all] Error 2
> make: *** [Makefile:149: all] Error 2
>
> *CMAKE output *
>
> #  Configured Features (DEAL_II_ALLOW_BUNDLED = ON,
> DEAL_II_ALLOW_AUTODETECTION = ON):
> #  ( DEAL_II_WITH_64BIT_INDICES = OFF )
> #  ( DEAL_II_WITH_ADOLC = OFF )
> #  ( DEAL_II_WITH_ARBORX = OFF )
> #DEAL_II_WITH_ARPACK set up with external dependencies
> #DEAL_II_WITH_ASSIMP set up with external dependencies
> #DEAL_II_WITH_BOOST set up with external dependencies
> #  ( DEAL_II_WITH_CGAL = OFF )
> #DEAL_II_WITH_COMPLEX_VALUES = ON
> #  ( DEAL_II_WITH_CUDA = OFF )
> #  ( DEAL_II_WITH_GINKGO = OFF )
> #DEAL_II_WITH_GMSH set up with external dependencies
> #DEAL_II_WITH_GSL set up with external dependencies
> #DEAL_II_WITH_HDF5 set up with external dependencies
> #DEAL_II_WITH_KOKKOS set up with external dependencies
> #DEAL_II_WITH_LAPACK set up with external dependencies
> #DEAL_II_WITH_METIS set up with external dependencies
> #DEAL_II_WITH_MPI set up with external dependencies
> #DEAL_II_WITH_MUPARSER set up with external dependencies
> #DEAL_II_WITH_OPENCASCADE set up with external dependencies
> #DEAL_II_WITH_P4EST set up with external dependencies
> #DEAL_II_WITH_PETSC set up with external dependencies
> #DEAL_II_WITH_SCALAPACK set up with external dependencies
> #DEAL_II_WITH_SLEPC set up with external dependencies
> #  ( DEAL_II_WITH_SUNDIALS = OFF )
> #  ( DEAL_II_WITH_SYMENGINE = OFF )
> #DEAL_II_WITH_TBB set up with external dependencies
> #DEAL_II_WITH_TRILINOS set up with external dependencies
> #DEAL_II_WITH_UMFPACK set up with external dependencies
> #DEAL_II_WITH_ZLIB set up with external dependencies
> #
> #  Component configuration:
> #  ( DEAL_II_COMPONENT_DOCUMENTATION = OFF )
> #DEAL_II_COMPONENT_EXAMPLES
> #  ( DEAL_II_COMPONENT_PACKAGE = OFF )
> #  ( DEAL_II_COMPONENT_PYTHON_BINDINGS = OFF )
> #
> #  Detailed information (compiler flags, feature configuration) can be
> found in detailed.log
> #
> #  Run  $ make info  to print a help message with a list of top level
> targets
> #
> ###
> -- Configuring done
> -- Generating done
> -- Build files have been written to: /home/mjrich/dealii-9.4.0/build
>
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/82a12172-3189-410c-9fbc-4e050b81dd2cn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, 

Re: [deal.II] compiling deal.ii 9.4 on wsl error

2022-09-08 Thread Daniel Arndt
Qiong,

It's not sufficient to include deal.II's include files but you need to link
the library target. Have a look at
https://www.dealii.org/current/users/cmake_user.html.

Best,
Daniel


On Wed, Sep 7, 2022 at 9:38 PM jim wo  wrote:

> and at the same time, I write the codes and it comes "the
> deal.II/grid/tria.h not found" I dont konw why
> best
> Qiong
>
>
> 在2022年9月8日星期四 UTC+8 09:34:59 写道:
>
>> I created a new cmake project on wsl with vscode ,I write the
>> INCLUDE_DIRETORIES with header file of dealii in the CMakeLists and then
>> cmake project ,I am not sure if its going to work . But when I make it
>> comes error as follow
>> [image: 1662600815935.png]
>>  best
>> Qiong
>> 在2022年9月8日星期四 UTC+8 09:23:08 写道:
>>
>>> I did install MPI on wsl
>>> and I congfigure deal.ii with DEAL_II_WITH_PETSC = ON
>>> DEAL_II_WITH_P4EST = ON
>>>
>>>
>>> 在2022年9月7日星期三 UTC+8 23:03:57 写道:
>>>
 Qiong,

 What CMake settings did you use to configure deal.II?
 Does your system indeed provide an MPI installation?

 Bets,
 Daniel

 On Wed, Sep 7, 2022 at 10:22 AM jim wo  wrote:

> Hello,
> I want to  develop my own project on wsl with deal.ii 9.4.  after make
> I got this message:
>
> In file included from /home/wu/deal_II/include/deal.II/grid/tria.h:20,
>  from /home/wu/cmakeQuickStart/main.cpp:23:
> /home/wu/deal_II/include/deal.II/base/config.h:540:12: fatal error:
> mpi.h: No such file or directory
>   540 | #  include 
>   |^~~
> compilation terminated.
> thanks for  your help
>  Qiong
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google
> Groups "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to dealii+un...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/c3b2d20c-923f-457f-b938-61ca4e13029fn%40googlegroups.com
> 
> .
>
 --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/9bbc2b6b-a3de-49d5-aab2-7f9ee31fc168n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJ0Dv44iiiZ1Yy857P876SDiR2KMdgw3j1b93v8Ea9YQg%40mail.gmail.com.


Re: [deal.II] compiling deal.ii 9.4 on wsl error

2022-09-07 Thread Daniel Arndt
Qiong,

What CMake settings did you use to configure deal.II?
Does your system indeed provide an MPI installation?

Bets,
Daniel

On Wed, Sep 7, 2022 at 10:22 AM jim wo  wrote:

> Hello,
> I want to  develop my own project on wsl with deal.ii 9.4.  after make I
> got this message:
>
> In file included from /home/wu/deal_II/include/deal.II/grid/tria.h:20,
>  from /home/wu/cmakeQuickStart/main.cpp:23:
> /home/wu/deal_II/include/deal.II/base/config.h:540:12: fatal error: mpi.h:
> No such file or directory
>   540 | #  include 
>   |^~~
> compilation terminated.
> thanks for  your help
>  Qiong
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/c3b2d20c-923f-457f-b938-61ca4e13029fn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKZYAVCWYpy1Giu_cYer8-Y_JgDDt9PGgyNoByEmrQB%3DA%40mail.gmail.com.


Re: [deal.II] visualizing a finite element field: different piecewise constant values within cells

2022-08-26 Thread Daniel Arndt
Simon,

You could also refine once globally and then manually assign values.
Implementing a new finite element class just for the sake of visualization
sounds like much more work.

Best,
Daniel

On Fri, Aug 26, 2022 at 12:31 PM Simon  wrote:

> Dear all,
>
>
> my triangulation is two-dimensional and consists of quadrilaterals, i.e.
> four vertices per cell. Each cell has four quadrature points (qp's).
>
> I visualize the data at the quadrature points (in paraview) by producing a
> discontinuous finite element field which has as many DoFs as my
> triangulation has qp's, that is, the qp values are somehow assigned to the
> nodes.
> In paraview (or other visualization programs) I would like to see four
> piecewice constant "colors" on every element: Sloppy speaking, each cell is
> divided into four subcells, and each of the subcells shows only one color
> which corresponds to the nodal value belonging to that subcell.
>
> To this end, I think I need a finite element with piecewise constant shape
> functions. Each shape function is '1' at one quarter of the reference
> domain and '0' at the remaining three quarters.
> Or is there an easier way to do this?
> If not, I probably would have to write my own finite element class, given
> that such an element does not exist in dealii?
>
>
> Thank you,
> Simon
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/0206f2a1-85cb-4970-9da8-d78de0bf6cc7n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKNmLyc_qbE8YscXihrwWO%3DqFf0guK2MMG1vSzc8niL1g%40mail.gmail.com.


Re: [deal.II] Re: Solving the linear system of equations using PETSc BlockSparseMatrix

2022-08-23 Thread Daniel Arndt
Adding to what Bruno is saying,

If you are not taking advantage of the block structure, you should be able
to treat the block matrix as "regular", i.e., non-block, matrix possibly by
copying it to a corresponding non-block type.

Best,
Daniel

On Mon, Aug 22, 2022 at 10:51 AM Bruno Turcksin 
wrote:

> Hi,
>
> If you search for "block solver" here
> https://dealii.org/developer/doxygen/deal.II/Tutorial.html, you will see
> all the tutorials that use block solvers. I think that only deal.II's own
> solvers support BlockSparseMatrix directly.
>
> Best,
>
> Bruno
>
> On Monday, August 22, 2022 at 9:02:28 AM UTC-4 masou...@gmail.com wrote:
>
>> Dear All,
>>
>> The following system of equations:
>> KQ=R
>> where,
>> [image: Screenshot from 2022-08-22 13-45-45.png]
>> were solved using BlockSparseMatrix to form tangent matrix K. It was
>> solved by:
>>
>> SparseDirectUMFPACK A_direct;
>> A_direct.initialize(K);
>> A_direct.vmult(Q_stp, R);
>>
>> Now, I'm trying to run my code with MPI using PETSc/Trilinos, but the
>> solver does not except  PETSc/Trilinos BlockSparseMatrix. How do we solve
>> such a general system of equations?
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/9c70b7e9-08ed-4cd6-bfd7-7eefe5eb2159n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKvTYa%3DgLNqz0pfcs58dz0m1o%2BV1zVFXwhdVqL0GYMViw%40mail.gmail.com.


Re: [deal.II] Issue encountered while solving Step-40 in 1 dimension

2022-08-22 Thread Daniel Arndt
Syed,

Yes, you should be able to use parallel::shared::Triangulation instead.

Best,
Daniel

On Sat, Aug 20, 2022 at 5:25 AM syed ansari  wrote:

> Thanks Daniel for your quick reply. Is it possible to solve the
> same problem with parallel::shared::Triangulation for dim ==1?
>
> On Fri, 19 Aug 2022, 8:18 pm Daniel Arndt,  wrote:
>
>> Syed,
>>
>> parallel::distributed::Triangulation is just not implemented for dim==1
>> so you can't run step-40 for the one-dimensional case.
>>
>> Best,
>> Daniel
>>
>> On Fri, Aug 19, 2022 at 7:07 AM syed ansari  wrote:
>>
>>> Dear all,
>>> I was trying to run step-40 in 1 dimension and encountered
>>> the error corresponding to MeshSmoothing in the constructor. The details of
>>> the error are as follows:
>>> 
>>> An error occurred in line <3455> of file
>>> 
>>> in function
>>> dealii::parallel::distributed::Triangulation<1,
>>> spacedim>::Triangulation(ompi_communicator_t* const&, typename
>>> dealii::Triangulation<1, spacedim>::MeshSmoothing,
>>> dealii::parallel::distributed::Triangulation<1, spacedim>::Settings) [with
>>> int spacedim = 1; MPI_Comm = ompi_communicator_t*; typename
>>> dealii::Triangulation<1, spacedim>::MeshSmoothing =
>>> dealii::Triangulation<1, 1>::MeshSmoothing]
>>> The violated condition was:
>>> false
>>> Additional information:
>>> You are trying to use functionality in deal.II that is currently not
>>> implemented. In many cases, this indicates that there simply didn't
>>> appear much of a need for it, or that the author of the original code
>>> did not have the time to implement a particular case. If you hit this
>>> exception, it is therefore worth the time to look into the code to
>>> find out whether you may be able to implement the missing
>>> functionality. If you do, please consider providing a patch to the
>>> deal.II development sources (see the deal.II website on how to
>>> contribute).
>>>
>>> Stacktrace:
>>> ---
>>> #0  /home/syed/dealii-candi/deal.II-v9.3.2/lib/libdeal_II.g.so.9.3.2:
>>> dealii::parallel::distributed::Triangulation<1,
>>> 1>::Triangulation(ompi_communicator_t* const&, dealii::Triangulation<1,
>>> 1>::MeshSmoothing, dealii::parallel::distributed::Triangulation<1,
>>> 1>::Settings)
>>> #1  ./step-40: Step40::LaplaceProblem<1>::LaplaceProblem()
>>> #2  ./step-40: main
>>> 
>>>
>>> Calling MPI_Abort now.
>>> To break execution in a GDB session, execute 'break MPI_Abort' before
>>> running. You can also put the following into your ~/.gdbinit:
>>>   set breakpoint pending on
>>>   break MPI_Abort
>>>   set breakpoint pending auto
>>>
>>> 
>>> An error occurred in line <3455> of file
>>> 
>>> in function
>>> dealii::parallel::distributed::Triangulation<1,
>>> spacedim>::Triangulation(ompi_communicator_t* const&, typename
>>> dealii::Triangulation<1, spacedim>::MeshSmoothing,
>>> dealii::parallel::distributed::Triangulation<1, spacedim>::Settings) [with
>>> int spacedim = 1; MPI_Comm = ompi_communicator_t*; typename
>>> dealii::Triangulation<1, spacedim>::MeshSmoothing =
>>> dealii::Triangulation<1, 1>::MeshSmoothing]
>>> The violated condition was:
>>> false
>>> Additional information:
>>> You are trying to use functionality in deal.II that is currently not
>>> implemented. In many cases, this indicates that there simply didn't
>>> appear much of a need for it, or that the author of the original code
>>> did not have the time to implement a particular case. If you hit this
>>> exception, it is therefore worth the time to look into the code to
>>> find out whether you may be able to implement the missing
>>> functionality. If you do, please consider providing a patch to the
>>> deal.II development sources (see the deal.II website on how to
>>> contribute).
>>>
>>> Stacktrace:
>>> ---
>>> #0  /home/syed/dealii-candi/deal.II-v9.3.2/lib/libdeal_II.g.so.9.3.2:
>>> dealii::parallel::distributed::Tria

Re: [deal.II] Issue encountered while solving Step-40 in 1 dimension

2022-08-19 Thread Daniel Arndt
Syed,

parallel::distributed::Triangulation is just not implemented for dim==1 so
you can't run step-40 for the one-dimensional case.

Best,
Daniel

On Fri, Aug 19, 2022 at 7:07 AM syed ansari  wrote:

> Dear all,
> I was trying to run step-40 in 1 dimension and encountered the
> error corresponding to MeshSmoothing in the constructor. The details of the
> error are as follows:
> 
> An error occurred in line <3455> of file
> 
> in function
> dealii::parallel::distributed::Triangulation<1,
> spacedim>::Triangulation(ompi_communicator_t* const&, typename
> dealii::Triangulation<1, spacedim>::MeshSmoothing,
> dealii::parallel::distributed::Triangulation<1, spacedim>::Settings) [with
> int spacedim = 1; MPI_Comm = ompi_communicator_t*; typename
> dealii::Triangulation<1, spacedim>::MeshSmoothing =
> dealii::Triangulation<1, 1>::MeshSmoothing]
> The violated condition was:
> false
> Additional information:
> You are trying to use functionality in deal.II that is currently not
> implemented. In many cases, this indicates that there simply didn't
> appear much of a need for it, or that the author of the original code
> did not have the time to implement a particular case. If you hit this
> exception, it is therefore worth the time to look into the code to
> find out whether you may be able to implement the missing
> functionality. If you do, please consider providing a patch to the
> deal.II development sources (see the deal.II website on how to
> contribute).
>
> Stacktrace:
> ---
> #0  /home/syed/dealii-candi/deal.II-v9.3.2/lib/libdeal_II.g.so.9.3.2:
> dealii::parallel::distributed::Triangulation<1,
> 1>::Triangulation(ompi_communicator_t* const&, dealii::Triangulation<1,
> 1>::MeshSmoothing, dealii::parallel::distributed::Triangulation<1,
> 1>::Settings)
> #1  ./step-40: Step40::LaplaceProblem<1>::LaplaceProblem()
> #2  ./step-40: main
> 
>
> Calling MPI_Abort now.
> To break execution in a GDB session, execute 'break MPI_Abort' before
> running. You can also put the following into your ~/.gdbinit:
>   set breakpoint pending on
>   break MPI_Abort
>   set breakpoint pending auto
>
> 
> An error occurred in line <3455> of file
> 
> in function
> dealii::parallel::distributed::Triangulation<1,
> spacedim>::Triangulation(ompi_communicator_t* const&, typename
> dealii::Triangulation<1, spacedim>::MeshSmoothing,
> dealii::parallel::distributed::Triangulation<1, spacedim>::Settings) [with
> int spacedim = 1; MPI_Comm = ompi_communicator_t*; typename
> dealii::Triangulation<1, spacedim>::MeshSmoothing =
> dealii::Triangulation<1, 1>::MeshSmoothing]
> The violated condition was:
> false
> Additional information:
> You are trying to use functionality in deal.II that is currently not
> implemented. In many cases, this indicates that there simply didn't
> appear much of a need for it, or that the author of the original code
> did not have the time to implement a particular case. If you hit this
> exception, it is therefore worth the time to look into the code to
> find out whether you may be able to implement the missing
> functionality. If you do, please consider providing a patch to the
> deal.II development sources (see the deal.II website on how to
> contribute).
>
> Stacktrace:
> ---
> #0  /home/syed/dealii-candi/deal.II-v9.3.2/lib/libdeal_II.g.so.9.3.2:
> dealii::parallel::distributed::Triangulation<1,
> 1>::Triangulation(ompi_communicator_t* const&, dealii::Triangulation<1,
> 1>::MeshSmoothing, dealii::parallel::distributed::Triangulation<1,
> 1>::Settings)
> #1  ./step-40: Step40::LaplaceProblem<1>::LaplaceProblem()
> #2  ./step-40: main
> 
>
> Calling MPI_Abort now.
> To break execution in a GDB session, execute 'break MPI_Abort' before
> running. You can also put the following into your ~/.gdbinit:
>   set breakpoint pending on
>   break MPI_Abort
>   set breakpoint pending auto
>
> 
> An error occurred in line <3455> of file
> 
> in function
> dealii::parallel::distributed::Triangulation<1,
> spacedim>::Triangulation(ompi_communicator_t* const&, typename
> dealii::Triangulation<1, spacedim>::MeshSmoothing,
> dealii::parallel::distributed::Triangulation<1, spacedim>::Settings) [with
> int spacedim = 1; MPI_Comm = ompi_communicator_t*; typename
> dealii::Triangulation<1, spacedim>::MeshSmoothing =
> dealii::Triangulation<1, 1>::MeshSmoothing]
> The violated condition was:
> false
> Additional information:
> You are trying to use functionality in deal.II that is currently not
> implemented. In many cases, this indicates that there simply didn't
> appear much of a need for it, or that the author of the 

Re: [deal.II] Refine per direction

2022-08-17 Thread Daniel Arndt
Uclus,

Use GridOut::write_vtu or GridOut::write_vtu_with_pvtu_record as
demonstrated in step-40 instead.

Best,
Daniel

On Wed, Aug 17, 2022 at 3:06 AM Uclus Heis  wrote:

> Dear Wolfgang,
>
> Thank you very much I could solve that.
>
> I would like to ask another question if it is ok. When I try to export the
> mesh, using a parallel::distributed::Triangulation  with MPI, I am not
> able to export the whole mesh. What I get is the pieces of the mesh
> corresponding to a certain process.  Is it possible to export the msh file
> of the whole domain grid?
>
>
> GridGenerator::subdivided_hyper_rectangle (
> triangulation,repetitions,Point(0,0,0),Point(2, 1, 1),false);
> triangulation.refine_global(1);
> std::ofstream out("domain_grid.msh");
> GridOut grid_out;
> grid_out.write_msh(triangulation, out);
>
>
> Thank you
> Regards
>
>
>
> El martes, 16 de agosto de 2022 a las 15:38:15 UTC+2, Wolfgang Bangerth
> escribió:
>
>> On 8/16/22 07:23, Uclus Heis wrote:
>> >
>> >
>> GridGenerator::hyper_rectangle(triangulation,Point(0,0,0),Point(2,1,1),false
>>
>> > );
>> > triangulation.refine_global(2);
>> >
>> > This code generates. rectangle with 4 cells per direction. How can I
>> perform a
>> > refinement so that I get more elements at the long dimension of the
>> rectangle,
>> > for example 8 cells? I can not find a function to determine the number
>> of
>> > refinements per direction. Could you please help me?
>> >
>>
>> Take a look at GridGenerator::subdivided_hyper_rectangle().
>>
>> Best
>> W.
>>
>> --
>> 
>> Wolfgang Bangerth email: bang...@colostate.edu
>> www: http://www.math.colostate.edu/~bangerth/
>>
>> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/c51493cc-a651-4504-8dc9-9d901a5cf4efn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BgrJUpLLQLLS-uYOWRAb2Tuy8PYRO134FBCAw3Wgo_rQ%40mail.gmail.com.


Re: [deal.II] Installation problem using spack

2022-08-09 Thread Daniel Arndt
Marco,

It appears that

-- Insufficient hdf5 installation found: hdf5 has to be configured with MPI
support.

is the problem. HDF5 has not been compiled with MPI support. Thus, you can
either try to make sure that HDF5 is built with MPI support or, in case you
are not going to use HDF5 anyway, just disable the dependency.

Best,
Daniel

On Tue, Aug 9, 2022 at 7:41 AM Marco Nawijn  wrote:

> Dear All,
>
> I run into an issue when trying to install dealii using spack. The error
> is as follows:
>
>   Could not find the hdf5 library!
>
>   Insufficient hdf5 installation found!
>
>   hdf5 has to be configured with MPI support.
>
>   Please ensure that a suitable hdf5 library is installed on your computer.
>
>   If the library is not at a default location, either provide some hints
> for
>   autodetection,
>
> A complete log and additional information is provided in the two
> attachments.
> I am a little lost at the moment because as far as I can tell, the
> installation process finds the correct HDF5 folder (I checked the tags). In
> addition, I installed HDF5 using spack with MPI, C++ and Fortran support (I
> added the output of `tree` to the attachment).
>
> I am a little at loss now, because I don't know what dealii is exactly
> missing from the HDF5 installation.
>
> The system is just a laptop, so nothing cluster like.
>
> Just as a side note. I am pretty impressed with the easy and flexibility
> of spack. All other dependencies installed without a hitch (petsc,
> sundials, trilinios etc.).
>
> Does anybody have an idea of what the problem is?
>
> Any help is highly appreciated.
>
> Marco
> P.S. I am a complete novice with dealii, but otherwise comfortable in the
> linux eco-system.
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/7383fcc8-af66-438f-b363-3aa1c9032d5en%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKAZFU06L27CzkBeXATXOob%2BFLY9aK22zBpGXTkXrSrWg%40mail.gmail.com.


Re: [deal.II] trilinos error with candi

2022-07-20 Thread Daniel Arndt
My best bet would be that your compiler is just too old, what are you using?
Also, what does the referenced line in
packages/kokkos/core/src/impl/Kokkos_Core.cpp look like?

Best,
Daniel

On Wed, Jul 20, 2022 at 11:12 AM erkin yildiz  wrote:

> I am getting[image: Screenshot from 2022-07-20 17-08-04.png] this error.
> I am pretty new for Linux environment. What should I write after getting
> this error. May you help me about that?
>
> Informativa sulla Privacy: https://www.unibs.it/it/node/1452
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/1591dd76-3f1f-4a44-8fde-26babe1b45e6n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJxf18%3Df%3DG%3DhE%3DYDd3wQF6Xk3BFQKE9ki5c%3DdW2VVTjKA%40mail.gmail.com.


Re: [deal.II] 3D Periodic BCs

2022-07-07 Thread Daniel Arndt
Jack,

step-45 https://www.dealii.org/current/doxygen/deal.II/step_45.html
provides an example for dealing with periodic boundary conditions. Even
though it's a 2D example, the interface is the same in 3D.

Assuming that the arguments for your set_periodic_boundary_condition
function are similar to the ones for GridTools::collect_periodic_faces and
you use a unit cube with standard coloring, you probably want to call it
with arguments 0,1,0 and 2,3,1 respectively.

Best,
Daniel

On Thu, Jul 7, 2022 at 1:56 PM jack urombo  wrote:

> I am trying to set periodic boundary conditions for a 3D problem like
>
>
>
>
> *velocity->set_periodic_boundary_condition(0, 1, 2);
> velocity->set_periodic_boundary_condition(2, 3, 1);
> pressure->set_periodic_boundary_condition(0, 1, 2);
> pressure->set_periodic_boundary_condition(2, 3, 1);*
>
> The boundary conditions are not matching and that i triggering errors.
>
> How do you set the period BCs in 3D.
>
> The information in this message is confidential and legally privileged. It
> is intended solely for the addressee(s). Access to this message by anyone
> else is unauthorized. If received in error, please accept our apologies and
> notify the sender immediately. You must also delete the original message
> from your machine. If you are not the intended recipient, any use,
> disclosure, copying, distribution or action taken in reliance of it, is
> prohibited and may be unlawful. The information, attachments, opinions or
> advice contained in this email are not the views or opinions of Harare
> Institute of Technology, its subsidiaries or affiliates. Although this
> email and any attachments are believed to be free of any virus or other
> defects which might affect any computer or IT system into which they are
> received, no responsibility is accepted by Harare Institute of Technology
> and/or its subsidiaries for any loss or damage arising in any way from the
> receipt or use thereof.
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/5eaf4f26-00dd-4e6d-841d-4a22e2328fb1n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbLt%2BqGNL0rU%2BRoiMh9ZNamUptVraMnUXfWEntiYM18n8A%40mail.gmail.com.


Re: [deal.II] discretization of a analytical function on a second triangulation

2022-07-06 Thread Daniel Arndt
Simon,

if you get all information you need using VectorTools::interpolate then
this sounds good.
Note that there also is FEFieldFunction(
https://www.dealii.org/current/doxygen/deal.II/classFunctions_1_1FEFieldFunction.html
)
that implements the interpolation for you.

Best,
Daniel



On Wed, Jul 6, 2022 at 3:03 AM Simon Wiesheier 
wrote:

> Dear Daniel,
>
>
> yes, I defined a class derived from deal::Function and it seems to work
> for me.
>
> Basically, my motivation to call VectorTools::interpolate is to compute
> the nodal values (scalar field --> DOFs) in the triangulation based on the
> formula implemented in the just derived class.
> During the assembly routine, I access some interpolated values at
> quadrature points,...
>
> With this in mind, is this an appropriate way?
>
>
> Best
> Simon
>
> Am Di., 5. Juli 2022 um 09:16 Uhr schrieb Daniel Arndt <
> d.arndt.m...@gmail.com>:
>
>> Simon,
>>
>> defining a class derived from dealii::Function sounds sensible.
>> Whether calling VectorTools::interpolate makes sense, depends on what you
>> want to do with the interpolated function. In may cases, it's enough to
>> just evaluate it locally during assembly using functionality like
>> FEValues::get_function_values.
>>
>> Best,
>> Daniel
>>
>> On Mon, Jul 4, 2022 at 10:26 AM Simon  wrote:
>>
>>> Dear all:
>>>
>>>
>>> I am solving a nonlinear PDE on a Triangulation T_1.
>>>
>>> I know the analytical representation of a scalar function of two
>>> variables (no space co-ordinates, but two invariants of a quantity)
>>> and my goal is to find a discretized version of the analytical function
>>> (on a second, two-dimensional triangulation T_2).
>>> The nodal values of T_2 should be the exact values corresponding to the
>>> analytical solution.
>>> As for the values between the nodes, I want to start with a bilinear
>>> interpolation.
>>>
>>> The coupling to my original PDE works as follows:
>>> For each quadrature point defined on T_1, I compute the two input
>>> variables of the above function based on my solution vector, find the
>>> corresponding cell of T_2 and want to retrieve the interpolated nodal
>>> values.
>>>
>>> My idea is to use the function
>>> VectorTools::interpolate ,
>>> but I do not know a suitable Function object to hand over.
>>>
>>> Is this an appropriate approach at all?
>>>
>>>
>>> Thank you,
>>> Simon
>>>
>>> --
>>> The deal.II project is located at http://www.dealii.org/
>>> For mailing list/forum options, see
>>> https://groups.google.com/d/forum/dealii?hl=en
>>> ---
>>> You received this message because you are subscribed to the Google
>>> Groups "deal.II User Group" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to dealii+unsubscr...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/dealii/14b1d8f6-f902-4414-a5c6-348ae3f5003en%40googlegroups.com
>>> <https://groups.google.com/d/msgid/dealii/14b1d8f6-f902-4414-a5c6-348ae3f5003en%40googlegroups.com?utm_medium=email_source=footer>
>>> .
>>>
>> --
>> The deal.II project is located at http://www.dealii.org/
>> For mailing list/forum options, see
>> https://groups.google.com/d/forum/dealii?hl=en
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "deal.II User Group" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to dealii+unsubscr...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/dealii/CAOYDWbKNTV%3D8Bipyq_gzbMoLvxdvv-%2BmHLipn27DbOcK-eWL_A%40mail.gmail.com
>> <https://groups.google.com/d/msgid/dealii/CAOYDWbKNTV%3D8Bipyq_gzbMoLvxdvv-%2BmHLipn27DbOcK-eWL_A%40mail.gmail.com?utm_medium=email_source=footer>
>> .
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/CAM50jEsXcMsvZzq0-EFgQwWn%3Dr%3D6yBw8yVr

Re: [deal.II] error: installation of dealii using spack

2022-07-06 Thread Daniel Arndt
Simon,

It looks like all the errors are related to the Sundials dependency
(release 6.0.0). Looking at https://github.com/dealii/dealii/pull/13918, it
seems that you need the latest deal.II release (9.4.0) to support that
Sundials version.
If you don't anticipate needing it I would just turn the dependency off if
I were you.

Best,
Daniel

On Wed, Jul 6, 2022 at 9:38 AM Simon  wrote:

> Dear all:
>
> I already have an older version of dealii installed and wanted to install
> now a newer version of dealii including all the dependencies using the
> command
> 'spack install dealii'.
>
> Many dependencies are installed successfully (see "spack_error.png"),
> however, the installation of dealii itself failes at some point.
> The error message states that I should have a look in the file
> "spack-build-out.txt", which I attached as well.
> In there, there are indeed a bunch of error messages, which refer to a
> similar message that too few arguments are passed to certain functions.
>
> How can I fix this?
>
> Thanks you,
> Simon
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/f995ce5f-4ed3-401c-8e8c-2c623ce45f81n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJMOi-aLruTVdX5Ki_-zG996kAeEb_fNGvLd5gTS%2B0S4g%40mail.gmail.com.


Re: [deal.II] discretization of a analytical function on a second triangulation

2022-07-05 Thread Daniel Arndt
Simon,

defining a class derived from dealii::Function sounds sensible.
Whether calling VectorTools::interpolate makes sense, depends on what you
want to do with the interpolated function. In may cases, it's enough to
just evaluate it locally during assembly using functionality like
FEValues::get_function_values.

Best,
Daniel

On Mon, Jul 4, 2022 at 10:26 AM Simon  wrote:

> Dear all:
>
>
> I am solving a nonlinear PDE on a Triangulation T_1.
>
> I know the analytical representation of a scalar function of two variables
> (no space co-ordinates, but two invariants of a quantity)
> and my goal is to find a discretized version of the analytical function
> (on a second, two-dimensional triangulation T_2).
> The nodal values of T_2 should be the exact values corresponding to the
> analytical solution.
> As for the values between the nodes, I want to start with a bilinear
> interpolation.
>
> The coupling to my original PDE works as follows:
> For each quadrature point defined on T_1, I compute the two input
> variables of the above function based on my solution vector, find the
> corresponding cell of T_2 and want to retrieve the interpolated nodal
> values.
>
> My idea is to use the function
> VectorTools::interpolate ,
> but I do not know a suitable Function object to hand over.
>
> Is this an appropriate approach at all?
>
>
> Thank you,
> Simon
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/14b1d8f6-f902-4414-a5c6-348ae3f5003en%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKNTV%3D8Bipyq_gzbMoLvxdvv-%2BmHLipn27DbOcK-eWL_A%40mail.gmail.com.


Re: [deal.II] Re: Trouble getting UMFPACK to work

2022-07-05 Thread Daniel Arndt
What does the log for running
cmake -DDEAL_II_WITH_UMFPACK=ON .
look like? The summary printed at the end should tell you if `UMFPACK`
really was found. N=Any problems in finding a compatible library should be
contained in the output printed when running the CMake command.

Best,
Daniel

On Mon, Jul 4, 2022 at 12:25 PM ME20D503 NEWTON 
wrote:

> Hello everyone,
> which command i have to use to check whether UMFPACK is enabled or not??
> if it is OFF how to turn it ON??
>
> Thank you in advance.
>
> On Thursday, August 31, 2017 at 9:28:52 PM UTC+5:30 John wrote:
>
>> Hello everyone,
>>
>> I am currently using Deal II version 8.0.0. When I try to run a project I
>> am getting the following:
>>
>> 
>> Exception on processing:
>>
>> 
>> An error occurred in line <379> of file 
>> 
>> in function
>> void dealii::SparseDirectUMFPACK::factorize(const Matrix&) [with
>> Matrix = dealii::SparseMatrix]
>> The violated condition was:
>> false
>> The name and call sequence of the exception was:
>> ExcMessage("To call this function you need UMFPACK, but configured
>> deal.II without passing the necessary switch to 'cmake'. Please consult the
>> installation instructions in doc/readme.html.")
>> Additional Information:
>> To call this function you need UMFPACK, but configured deal.II without
>> passing the necessary switch to 'cmake'. Please consult the installation
>> instructions in doc/readme.html.
>>
>> Stacktrace:
>> ---
>> #0  /Downloads/deal.II/lib/libdeal_II.so.8.0.0: void
>> dealii::SparseDirectUMFPACK::factorize
>> >(dealii::SparseMatrix const&)
>> #1  step-3: TmsProblem::solve()
>> #2  step-3: TmsProblem::run()
>> #3  step-3: main
>> 
>>
>> Aborting!
>> 
>> CMake Error at CMakeFiles/run_target.cmake:6 (MESSAGE):
>>
>>
>>   Program terminated with exit code: 1
>>
>>
>> CMakeFiles/run.dir/build.make:57: recipe for target 'CMakeFiles/run'
>> failed
>> make[3]: *** [CMakeFiles/run] Error 1
>> CMakeFiles/Makefile2:264: recipe for target 'CMakeFiles/run.dir/all'
>> failed
>> make[2]: *** [CMakeFiles/run.dir/all] Error 2
>> CMakeFiles/Makefile2:271: recipe for target 'CMakeFiles/run.dir/rule'
>> failed
>> make[1]: *** [CMakeFiles/run.dir/rule] Error 2
>> Makefile:196: recipe for target 'run' failed
>> make: *** [run] Error 2
>>
>>
>>
>> I have tried "*cmake -DDEAL_II_WITH_UMFPACK=ON*" and "*cmake
>> -DDEAL_II_WITH_UMFPACK=ON -DUMFPACK_DIR=/Downloads/deal.II/bundled/umfpack
>> .*" and also  "*cmake -DDEAL_II_WITH_UMFPACK=ON
>> -DUMFPACK_DIR=/Downloads/deal.II/bundled/umfpack/UMFPACK .*" and then
>> following each of these with "*make*" and "*make run*". However, all of
>> these still end up giving me the same error as above. Can anyone help me
>> with getting umfpack to work? Thank you in advance.
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/f8629e26-974f-4dd9-aa0e-99a198de0f96n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbLFsJycNqXUO44z52WHtGCWC42YCgjicXNdsui3A7wWVg%40mail.gmail.com.


Re: [deal.II] Compilation fails for deal.II when compiling with PETSc+Kokkos

2022-06-16 Thread Daniel Arndt
Roland,

Instead of debugging where thighs go wring in choosing the correct compiler
when using the launch_compiler, you could either use Kokkos' nvcc_wrapper
(in the Kokkos installation directory in the bin directory) or use clang++.
The former one forces all compilation to go through nvcc which you likely
want anyway since everything you are compiling now implicitly depends on
Kokkos (which considers all files as CUDA files if you compile with the
CUDA backend).
The same applies to using clang++ that can deal with CUDA files
out-of-the-box on its own.

Best,
Daniel

On Thu, Jun 16, 2022 at 4:20 AM 'develo...@googlemail.com' via deal.II User
Group  wrote:

> I did not set any of those settings by hand, they were set automatically
> during the configuration/generation step, I suppose.
> Regards,
> Roland
>
> Wolfgang Bangerth schrieb am Donnerstag, 16. Juni 2022 um 10:14:10 UTC+2:
>
>> On 6/16/22 01:49, 'develo...@googlemail.com' via deal.II User Group
>> wrote:
>> > **
>> >
>> > Thanks for the idea! I tested it, and got the following output:
>> > //opt/petsc/bin/kokkos_launch_compiler /opt/petsc/bin/nvcc_wrapper
>> > /opt/intel/oneapi/mpi/2021.6.0/bin/mpicxx
>> > /opt/intel/oneapi/mpi/2021.6.0/bin/mpicxx -DBOOST_NO_AUTO_PTR  -fPIC
>> > -march=native -mavx2 -fPIC -Wall -Wextra -Wmissing-braces
>> -Woverloaded-virtual
>> > -Wpointer-arith -Wsign-compare -Wsuggest-override -Wswitch -Wsynth
>> > -Wwrite-strings -Wno-placement-new -Wno-deprecated-declarations
>> > -Wno-literal-suffix -Wno-psabi -Wno-class-memaccess -fopenmp-simd
>> > -DKOKKOS_DEPENDENCE -fPIC -march=native -mavx2 -Wno-parentheses
>> > -Wno-unused-local-typedefs
>> >
>> -expt-extended-lambda;-Wext-lambda-captures-this;-lineinfo;-arch=sm_60;-Xcompiler;-fopenmp
>>
>> > -MD -MT
>> >
>> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/expand_instantiations.cc.o
>>
>> > -MF
>> CMakeFiles/expand_instantiations_exe.dir/expand_instantiations.cc.o.d -o
>> > CMakeFiles/expand_instantiations_exe.dir/expand_instantiations.cc.o -c
>> >
>> /home/local/Downloads/git-files/dealii/cmake/scripts/expand_instantiations.cc
>>
>> > nvcc fatal   : No input files specified; use option --help for more
>> information
>> > /bin/sh: 1: -Wext-lambda-captures-this: not found
>> > /bin/sh: 1: -lineinfo: not found
>> > /bin/sh: 1: -arch=sm_60: not found
>> > /bin/sh: 1: -Xcompiler: not found
>> > /bin/sh: 1: -fopenmp: not found
>> > make[2]: ***
>> > [cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/build.make:76:
>> >
>> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/expand_instantiations.cc.o]
>>
>> > Error 127/
>> > Are there other flags which might help?
>>
>> The underlying issue here is that you are trying to compile a tool that
>> is
>> supposed to be run during compile time on the host (namely, the
>> 'expand_instantiations' program) with the *target* compiler (namely,
>> nvcc).
>> The error messages indicate that that doesn't work, and indeed it
>> shouldn't
>> work because the executable is not meant to be executed on the GPU but on
>> the CPU.
>>
>> The bigger question is *why* that happens. I don't really know the answer
>> because I've never tried to compile for GPUs, so others might have to
>> help out
>> with that, but I wonder how it comes that you are trying to compile with
>> /opt/petsc/bin/kokkos_launch_compiler. Did you set the CXX environment
>> variable to that, or passed this as a flag to cmake?
>>
>> Best
>> W.
>>
>> --
>> 
>> Wolfgang Bangerth email: bang...@colostate.edu
>> www: http://www.math.colostate.edu/~bangerth/
>>
>> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/313e44cd-de0a-4c6a-9642-a6c912248c92n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJYaXKtxSWa3%2BCkjJzXZBacigGphp4WrDxxEwTh4eiFBA%40mail.gmail.com.


Re: [deal.II] Compilation fails for deal.II when compiling with PETSc+Kokkos

2022-06-15 Thread Daniel Arndt
Somewhere the compiler flag -DKOKKOS_DEPENDENCE got lost, you might try if
adding it fixes your problem.
Kokkos allows specifying an arbitrary CMake C++ compiler to be used as host
compiler for nvcc under the hood. As long as the compiler is not clang++
(which can compile CUDA code on its own),
everything that depends on Kokkos (all targets that use -DKOKKOS_DEPENDENCE
for compilation) is compiled by nvcc with the specified CMake C++ as host
compiler.
If the target doesn't depend on Kokkos, the host compiler is invoked
directly but it of course doesn't know about CUDA compiler flags like
-arch=sm_60.

Best,
Daniel

On Wed, Jun 15, 2022 at 3:03 AM 'develo...@googlemail.com' via deal.II User
Group  wrote:

>
> Hei,
> I recently tried to re-install deal.II on a new server. For testing
> purposes I installed PETSc with Kokkos (as it supports the direct
> integration) and CUDA-support.
> Unfortunately, compilation does now not work at all, with the error
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> */usr/bin/cmake -S/home/local/Downloads/git-files/dealii
> -B/home/local/Downloads/git-files/dealii/build --check-build-system
> CMakeFiles/Makefile.cmake 0/usr/bin/cmake -E cmake_progress_start
> /home/local/Downloads/git-files/dealii/build/CMakeFiles
> /home/local/Downloads/git-files/dealii/build//CMakeFiles/progress.marksmake
>  -f CMakeFiles/Makefile2 allmake[1]: Entering directory
> '/home/local/Downloads/git-files/dealii/build'make  -f
> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/build.make
> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/dependmake[2]:
> Entering directory '/home/local/Downloads/git-files/dealii/build'cd
> /home/local/Downloads/git-files/dealii/build && /usr/bin/cmake -E
> cmake_depends "Unix Makefiles" /home/local/Downloads/git-files/dealii
> /home/local/Downloads/git-files/dealii/cmake/scripts
> /home/local/Downloads/git-files/dealii/build
> /home/local/Downloads/git-files/dealii/build/cmake/scripts
> /home/local/Downloads/git-files/dealii/build/cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/DependInfo.cmake
> --color=make[2]: Leaving directory
> '/home/local/Downloads/git-files/dealii/build'make  -f
> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/build.make
> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/buildmake[2]:
> Entering directory '/home/local/Downloads/git-files/dealii/build'[  0%]
> Building CXX object
> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/expand_instantiations.cc.ocd
> /home/local/Downloads/git-files/dealii/build/cmake/scripts &&
> /opt/petsc/bin/kokkos_launch_compiler /opt/petsc/bin/nvcc_wrapper
> /opt/intel/oneapi/mpi/2021.6.0/bin/mpicxx
> /opt/intel/oneapi/mpi/2021.6.0/bin/mpicxx -DBOOST_NO_AUTO_PTR  -fPIC
> -march=native -mavx2 -fPIC -Wall -Wextra -Wmissing-braces
> -Woverloaded-virtual -Wpointer-arith -Wsign-compare -Wsuggest-override
> -Wswitch -Wsynth -Wwrite-strings -Wno-placement-new
> -Wno-deprecated-declarations -Wno-literal-suffix -Wno-psabi
> -Wno-class-memaccess -fopenmp-simd -Wno-parentheses
> -Wno-unused-local-typedefs
> -expt-extended-lambda;-Wext-lambda-captures-this;-lineinfo;-arch=sm_60;-Xcompiler;-fopenmp
> -MD -MT
> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/expand_instantiations.cc.o
> -MF CMakeFiles/expand_instantiations_exe.dir/expand_instantiations.cc.o.d
> -o CMakeFiles/expand_instantiations_exe.dir/expand_instantiations.cc.o -c
> /home/local/Downloads/git-files/dealii/cmake/scripts/expand_instantiations.cc/usr/bin/ld:
> warning: cannot find entry symbol xpt-extended-lambda; defaulting to
> 1040/usr/bin/ld:
> /usr/lib/gcc/x86_64-linux-gnu/11/../../../x86_64-linux-gnu/Scrt1.o: in
> function `_start':(.text+0x1b): undefined reference to `main'collect2:
> error: ld returned 1 exit status/bin/sh: 1: -Wext-lambda-captures-this: not
> found/bin/sh: 1: -lineinfo: not found/bin/sh: 1: -arch=sm_60: not
> found/bin/sh: 1: -Xcompiler: not found/bin/sh: 1: -fopenmp: not
> foundmake[2]: ***
> [cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/build.make:76:
> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/expand_instantiations.cc.o]
> Error 127make[2]: Leaving directory
> '/home/local/Downloads/git-files/dealii/build'make[1]: ***
> [CMakeFiles/Makefile2:1758:
> cmake/scripts/CMakeFiles/expand_instantiations_exe.dir/all] Error 2make[1]:
> Leaving directory '/home/local/Downloads/git-files/dealii/build'make: ***
> [Makefile:136: all] Error 2*
> Is there a way I can fix/circumvent that bug? And where is it coming from?
> Thanks!
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> 

Re: [deal.II] No printing of TimerOutput after catch of exception in MPI based code

2022-05-09 Thread Daniel Arndt
Maurice,

You could try to wrap the calls that might throw in a try-catch block to
deal with the exception yourself (including ignoring it).

Best,
Daniel

On Mon, May 9, 2022 at 11:14 AM 'maurice rohracker' via deal.II User Group <
dealii@googlegroups.com> wrote:

> Dear all,
>
> In the attached mwe we are facing the issue, that the TimerOutput object
> does not print the resulting table to the screen when an exception is
> thrown and caught within in a MPI based code.
>
> We are aware that some collective routine might be needed.
>
> However, is there a way which can handle this easily, such that
> TimerOutput object prints the resulting table to the screen even if an
> exception is thrown or are we missing something?
>
> We were already able to do so in the serial case.
>
> Thanks in advance.
>
> Best regards,
> Maurice
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/c68d2663-d1a7-4670-a632-9a51abae3d6fn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbLFN1GpwKoBuiVVDL6s6YbEmC92wTXLpiwvWeKLFAPLyw%40mail.gmail.com.


Re: [deal.II] simple application of anti-periodic boundary conditions

2022-04-21 Thread Daniel Arndt
Paras,

You can also use add_periodicity with regular Triangulation objects, see
https://www.dealii.org/current/doxygen/deal.II/classTriangulation.html#adbf04756b28dae69194870812acaf941.
This should make sure that periodic neighbors differ at most by one
refinement.

Best,
Daniel

On Wed, Apr 20, 2022 at 4:20 AM Wolfgang Bangerth 
wrote:

> On 4/19/22 13:17, Paras Kumar wrote:
> >
> > One follow-up question: The mesh (which is initially periodic at the
> > boundaries)  is refined adaptively during the simulation and it cannot
> be
> > guaranteed if both the left and the right boundary faces would be
> refined at
> > the same time. Will make_periodicity_constraints() work in that case? If
> yes,
> > how would the periodic constraints look like for the child cell dofs? In
> case
> > it matters, I currently have a dealii::Triangulation and also wish to
> update
> > to p:d:T in future.
>
> I don't recall the details, but at least for p::d::T, it is possible to
> tell
> the triangulation about the periodicity of sides and it will ensure that
> if
> you refine the cells on one side the ones on the other side are refined
> accordingly.
>
> Others might remember more of the details.
>
> Best
>   W.
>
>
> --
> 
> Wolfgang Bangerth  email: bange...@colostate.edu
> www: http://www.math.colostate.edu/~bangerth/
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/be3be255-d6a0-bdbd-fb56-f46161fc0856%40colostate.edu
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BrZbnXhr%2ByKzMNaYj%3DWurZ1TFezVG6XD-4-g2VGhoJfA%40mail.gmail.com.


Re: [deal.II] Issue with deal.ii installation on Cori

2022-02-23 Thread Daniel Arndt
Vishwas,

A deal.II installation should not use that much disk space or are you
talking about the memory being used while compiling? Every compilation unit
uses a couple GB so running with 64 threads might be too much.
If it's the disk space, do you have any idea which directories are
particularly large? Maybe, try only building in Release mode via
CMAKE_BUILD_TYPE=Release.

Best,
Daniel

Am Mi., 23. Feb. 2022 um 16:09 Uhr schrieb Vishwas Goel :

> Hi,
>
> I am trying to install deal.ii on Cori using the following commands.
> However, the overall installation files run over 40 Gbs. Can you please let
> me know what could be the issue? I suspect I might be installing everything
> in deal.ii, which I might not even need.
>
> $ wget https://dealii.43-1.org/downloads/dealii-9.2.0.tar.gz
>
> $ tar xvzf dealii-9.2.0.tar.gz
>
> $ cd dealii-9.2.0
>
> $ mkdir build-executable
>
> $ cd build-executable
>
> $ cmake ..
>
> $ make expand_instantiations_exe
>
> $ export PATH="$PWD/bin:$PATH"
>
> $ cd
>
> $ mkdir dealii_install
>
> $ mkdir build
>
> $ cd build
>
> *$ cmake -DCMAKE_INSTALL_PREFIX=~/dealii_install \*
>
> * -DCMAKE_PREFIX_PATH=/opt/cray/pe/lib64 \*
>
> * -DWITH_MPI=ON \*
>
> *-DMPI_DIR=/opt/cray/pe/mpt/default/gni/mpich-gnu/5.1/ \*
>
> *
> -DMPI_CXX_INCLUDE_PATH=/opt/cray/pe/mpt/default/gni/mpich-gnu/5.1/include/
> \*
>
> *-DCMAKE_CXX_COMPILER=/opt/cray/pe/craype/2.6.2/bin/CC \*
>
> *-DCMAKE_C_COMPILER=/opt/cray/pe/craype/2.6.2/bin/cc \*
>
> *-DCMAKE_Fortran_COMPILER=/opt/cray/pe/craype/2.6.2/bin/ftn
> \*
>
> * -DWITH_P4EST=ON -DP4EST_DIR=~/p4est_install/ \*
>
> *-DCMAKE_SYSTEM_NAME=CrayLinuxEnvironment \*
>
> * ~/dealii-9.2.0 *
>
> $ make -j 64 install
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/616952b2-443f-456a-9534-cb41e6a7219bn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJ1GH8Qf%3DmLzjKqee_KHRFgMVRxkCV5usUHApay%3D3e5hw%40mail.gmail.com.


Re: [deal.II] FunctionManifold class

2022-01-31 Thread Daniel Arndt
Giuseppe,

Searching for FunctionMnaifold in the tests folder should give you a couple
of examples on how to use FunctionManifold with an analytical function.
Most of them use std::strings but
tests/fe/fe_values_function_manifold.cc and
tests/mappings/mapping_q_manifold_02.cc actually use Function objects.

Best,
Daniel

Am Mo., 31. Jan. 2022 um 02:56 Uhr schrieb giuseppe orlando <
giusor...@gmail.com>:

> Good morning everyone,
> I would have a question about the creation of a triangulation. Is it
> possible to use the 'FunctionManifold' class to create a boundary described
> by an analytical function? If so, how can I attach this manifold and
> "substitute" for instance the default straight boundary of a hyperectangle?
>
> Thanks in advance,
> Giuseppe
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/f32dfb1a-375a-4771-a84e-1062fea391ffn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BozWmwD3HSZMyem39nXRVahUSzLC_Mpd9JWDKk6hE2eA%40mail.gmail.com.


Re: [deal.II] Is any faster version of VectorTools::point_gradient?

2021-12-14 Thread Daniel Arndt
Hello,

Have a look at VectorTools::point_gradients (
https://www.dealii.org/developer/doxygen/deal.II/namespaceVectorTools.html#aada37fd09d8be1b9ed9bb12d698f8ee4
).

Best,
Daniel

Am Di., 14. Dez. 2021 um 10:16 Uhr schrieb 沈键 :

> Hello,
>   I want to compute streamlines in deal.II after solving a velocity
> potential equation, so I need to get velocity (gradient of solution) on the
> point to take the streamline a step forward. Unfortunately, each streamline
> consists around 2000 points which means it should call
> `VectorTools::point_gradient` 2000 times. It takes too much time. I search
> the document but find VectorTools::point_gradient only support searching
> the point belong to which cell globally.  I think it can be optimized,
> because if I have got previous point, next point should locate in the same
> cell or neighbor cells. My question is:
>   Is any ready-made function of `point_gradient` in deal.II supporting
> searching the specified point's owner cell only around given cells not
> globally?
>   Thanks for your reply in advance.
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/d2dca380-e475-400a-9c30-345f824550aan%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKpV3WHUFrwVVz4p96j1DPqEKouTiAZMtdNV0e8zDj%2BtQ%40mail.gmail.com.


Re: [deal.II] evaluating basis functions at random points

2021-12-13 Thread Daniel Arndt
Andrea,

have a look at GridTools::compute_point_locations(
https://www.dealii.org/developer/doxygen/deal.II/namespaceGridTools.html#a8e8bb9211264d2106758ac4d7184117e
).
Step-60 demonstrates its use.

Best,
Daniel

Am Mo., 13. Dez. 2021 um 16:14 Uhr schrieb Andrea Bonito :

> Howdy:
>
> this might be a simple question but I do not seem to find a way to
> efficiently evaluate basis functions at random points. More precisely, I am
> given random points in my computational domain and I need to assemble the
> terms
>
> phi_i(p) phi_j(p)  for all random points p and all i,j =1,..., n_dofs.
>
> As of now, I am going cell by cell and check whether p is inside the cell
> (including the boundary). If it is, I am creating a quadrature with one
> point in the reference cell (using the mapping).
>
> I am sure one of you has a better way... any help would be appreciated.
>
> Andrea
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/18f9edd4-c848-4983-9724-e87b31bd219cn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbL0sLUAKK2wOzu8uV2oKOhu-QY7OXSyQPUSaX1NVMxmsQ%40mail.gmail.com.


Re: [deal.II] Centroids of a distributed triangulation

2021-11-02 Thread Daniel Arndt
Vachan,

There is TriaAccessor::barycenter(
https://www.dealii.org/current/doxygen/deal.II/classTriaAccessor.html#a56cc737f4b28f8d28a576d2e3d32ef9f)
and TriaAccessor::measure(
https://www.dealii.org/current/doxygen/deal.II/classTriaAccessor.html#a9cecb2b7c9a1644fb5fd44bbba40ab0c)
for a single cell but I don't think such a function exists for the whole
triangulation.
On the other hand, it should not be too difficult to implement that
yourself if you use the former functions. You only need to integrate x over
the whole domain and divide by the area of the whole domain which you can
do by taking the sum of the barycenter of each cell mutlplied by its
measure and divide by the sum of the measures. Alternatively, integrate x
over the whale domain and divide by the integral of 1 over the whole domain.

Best,
Daniel

Best,
Daniel

Am Di., 2. Nov. 2021 um 05:16 Uhr schrieb vachanpo...@gmail.com <
vachanpotluri1...@gmail.com>:

> Dear all,
>
> Is there a built-in function to calculate centroid of the area spanned by
> all the owned cells? I couldn't find any related function in GridTools.
> Using a bounding box will not work in all cases for my problem.
>
> Thanking in anticipation
> Vachan
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/9e76890d-412e-44f8-a3a7-70b55a566a29n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJb2Sj31%3D2TvoT2QJB1NwbQe_7CKA-vECy2tVAVjc3KZw%40mail.gmail.com.


Re: [deal.II] Missing (block_sparse_matrix)

2021-10-22 Thread Daniel Arndt
Ahmed,

The file and the respective classes were deleted in
https://github.com/dealii/dealii/pull/9761 and deprecated in
https://github.com/dealii/dealii/pull/5352.
If you need to replace BlockMatrixArray, you should have a look at the
documentation in the latter pull request to use BlockLinearOperator(
https://www.dealii.org/current/doxygen/deal.II/classBlockLinearOperator.html)
instead.

Best,
Daniel

Am Fr., 22. Okt. 2021 um 04:29 Uhr schrieb Ahmed Galal <
ahmed.galal8...@gmail.com>:

> I am trying to compile a deal.ii code but it failed because of
> missing .
>
> I do not know how to include it in the recent dealii version. I found it
> available deal.ii 8.5.0.
>
> Thanks in advance!
>
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/442d1ff2-fa5d-4d09-bbd1-c188f0d467bbn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKPxE8sPVUWHX_bjuJNztsYSBxzdwfDTu0rL2aLoDHxYQ%40mail.gmail.com.


Re: [deal.II] Direct solver matrix.free

2021-10-21 Thread Daniel Arndt
Joss,

The MatrixFree framework relies on the operator to be only defined by its
action. Accessing individual elements (as direct solvers typically require)
falls out of this concept. That is to say that the MatrixFree framework
only works well with an iterative solver.

Best,
Daniel

Am Do., 21. Okt. 2021 um 13:45 Uhr schrieb Joss G. :

> Hi all,
>
> I was using the solver PETScWrappers::SparseDirectMUMPS for a sparse
> matrix approach. Now I am changing the code to a matrix-free implementation
> and I am not using PETSc anymore, instead, I use
> LinearAlegebra::distributed::Vector. I am not able to find an
> equivalent direct solver that I can use. Could anyone please point me what
> solver can i use?
>
> Thank you very much.
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/90916560-faf4-4d5a-b93c-d684deeb1b6fn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKw3LMWN1dRxWP2m1tHYmfJvy8JJMoyRURUTtwyk7pH2A%40mail.gmail.com.


Re: [deal.II] Time dependent boundary conditions

2021-10-01 Thread Daniel Arndt
Kyle,

Function is derived from FunctionTime which implements
get_time()/set_time(). In particular, step-26 uses get_time() to access a
previously stored time via set_time().

Best,
Daniel

Am Fr., 1. Okt. 2021 um 16:09 Uhr schrieb Kyle Schwiebert :

> I am having trouble understanding the class FunctionTime, under what
> circumstances it is need, and how it is implemented.
>
> Consider Step-26 in the tutorial. There is no variable anywhere defined
> with class FunctionTime. However, the function get_time() is still used,
> seemingly to get the current value of the time variable. However, when I do
> similarly, it seems the the variable created in my BoundaryValues function
> is always zero. I am using the line:
>
> const double time = this->get_time();
>
> This is not surprising to me: If we don't have a class FunctionTime time
> variable, I would expect get_time to either error or output zero. However,
> while in my function, get_time() always returns zero, in apparently does
> not do so in step-26. Can someone help me understand this?
>
> Thank you,
> Kyle
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/89092349-4116-4d90-93b5-3d40ac10145bn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2B0ZOt6g1Fopf-nUPtHedvSDH%2B05BMy8ddG3Svw641XKg%40mail.gmail.com.


Re: [deal.II] Element-wise DOF numbering and shape function numbering

2021-09-29 Thread Daniel Arndt
Lixing,

Yes, using FiniteElemnt::component_to_system_index() seems to be reasonable
to use to identify the overall DoF number for copies of the same finite
element. The FiniteElement class doesn't need class accessor argument and
the mapping is thus generic.
Also note that there is DoFTools::map_dofs_to_support_points and
DoFTools::map_support_points_to_dofs that might be helpful for you.

Best,
Daniel

Am Mi., 29. Sept. 2021 um 13:27 Uhr schrieb Lixing Zhu <
zhulixin...@gmail.com>:

> Hi all,
>
> I am playing with a vector-valued 2D problem (displacement vector u and
> v). Since I need to use the shape functions of a specific vertex, I export
> the DOFs numbering and its corresponding number of the vertex. As
> illustrated in FiniteElement
> , for
> quadratic 2D FE_Q element, the pair of DODs of a specific vertex are
> grouped as follows:
>
> #DOF, #component, #within the base
> 0 0 0
> 1 1 0
> 2 0 1
> 3 1 1
> 4 0 2
> 5 1 2
> 6 0 3
> 7 1 3
> 8 0 4
> 9 1 4
> 10 0 5
> 11 1 5
> 12 0 6
> 13 1 6
> 14 0 7
> 15 1 7
> 16 0 8
> 17 1 8
>
> However, for high-order elements (higher than or equal to 3), this pattern
> no longer exists. In other words, the DOFs of the same vertex are not
> grouped. Take 4th order 2D FE_Q as an example,
>
> #DOF, #component, #within the base
> 0 0 0
> 1 1 0
> 2 0 1
> 3 1 1
> 4 0 2
> 5 1 2
> 6 0 3
> 7 1 3
> 8 0 4
> 9 0 5
> 10 0 6
> 11 1 4
> 12 1 5
> 13 1 6
> 14 0 7
> 15 0 8
> 16 0 9
> 17 1 7
> 18 1 8
> 19 1 9
> 20 0 10
> 21 0 11
> 22 0 12
> 23 1 10
> 24 1 11
> 25 1 12
> 26 0 13
> 27 0 14
> 28 0 15
> 29 1 13
> 30 1 14
> 31 1 15
> 32 0 16
> 33 0 17
> 34 0 18
> 35 0 19
> 36 0 20
> 37 0 21
> 38 0 22
> 39 0 23
> 40 0 24
> 41 1 16
> 42 1 17
> 43 1 18
> 44 1 19
> 45 1 20
> 46 1 21
> 47 1 22
> 48 1 23
> 49 1 24
>
> I guess this suggests that we cannot simply assume the pairing of DOFs in
> vector-valued problems. My question is, is the numbering of the DOF is
> fixed among the same type of elements? Since I need to fetch the DOFs of a
> specific vertex, I guess FiniteElement::component_to_system_index() can
> help determine the current DOF number of a specific vertex. Do I need to
> check them for each element? or just check it once for a certain type of
> element?
>
> Regards,
> Lixing
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/26a04f52-2766-442c-ae99-00589fda8612n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbK9pyw%2BvpQP7sCFwgZ6FDdaB91ircfSpA1XyR2FHDuRww%40mail.gmail.com.


Re: [deal.II] Calculating an integral over the boundary

2021-09-28 Thread Daniel Arndt
Kyle,

Have a look at VectorTools::point_value(
https://www.dealii.org/current/doxygen/deal.II/namespaceVectorTools.html#a7be5c7eed52308898dfaad91c4cff204
).

Best,
Daniel

Am Di., 28. Sept. 2021 um 13:04 Uhr schrieb Kyle Schwiebert <
kjsch...@mtu.edu>:

> Thank you for the help. I think that has the pretty much sorted out for
> me. One additional question: On this test problem people also like to know
> the pressure drop across the obstacle. This basically involves calculating
> the pressure at two points in the mesh and finding their difference. I see
> in step 13 this can be done by hoping that the points you need to evaluate
> are vertices of the mesh. Is there a more general solution--or a way to
> ensure a certain point is in the mesh? FYI I'm using the very helpful
> builtin meshing scheme for this
> problem: GridGenerator::channel_with_cylinder()
>
> Thanks,
> Kyle
>
> On Monday, September 27, 2021 at 6:24:57 PM UTC-4 Wolfgang Bangerth wrote:
>
>> On 9/27/21 1:43 PM, Kyle Schwiebert wrote:
>> > I'm trying to replicate the simulation described in this paper
>> > <
>> https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwias-berlin.de%2Fpeople%2Fjohn%2FELECTRONIC_PAPERS%2FJoh04.IJNMF.pdf=04%7C01%7CWolfgang.Bangerth%40colostate.edu%7Ce97881b432a742a2b53008d981ef1a37%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C637683686653742835%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000=dDqBEMcMDHgOSMr4G2McKiWUmifKo5sSZpc3ReFfUQ8%3D=0>.
>>
>> > How could I compute the integrals in equations 4 and 5? I'm sure it's
>> > covered in the tutorial, but I couldn't find it after searching in
>> > several different steps in the tutorial. Could someone please point me
>> > to an example in the tutorials where this type of computation with a
>> > computed solution? The only examples I could find seem to only discuss
>> > computing L2, or H1 errors with a special function that avoid manually
>> > computing the integral. Is the easiest thing to do as is done in the
>> > matrix assembly?
>>
>> Kyle,
>> in essence you just have to loop over all cells and integrate up the
>> quantity you have in the formula for a given choice of v_l and v_d. This
>> works in a similar way to this example here where we compute the angular
>> momentum:
>>
>>
>> https://github.com/geodynamics/aspect/blob/master/source/simulator/nullspace.cc#L357-L459
>>
>>
>> > Finally, how would one initialize the vectors v_l and v_d? Could it be
>> > done easily with an appropriate AffineConstraints object?
>>
>> As long as you satisfy the boundary conditions, it's your choice. So you
>> could, for example, start with a zero vector, evaluate boundary values
>> as indicated on the boundary in question, and then just go through the
>> constraints you get as a result and apply them to your zero vector (via
>> AffineConstraints::distribute(), applied to the zero vector). That would
>> probably be what I'd do.
>>
>> Or you just take v_l/v_d as functions that are analytically described
>> (i.e., that are not finite element functions to begin with).
>>
>> Best
>> W.
>>
>> --
>> 
>> Wolfgang Bangerth email: bang...@colostate.edu
>> www: http://www.math.colostate.edu/~bangerth/
>>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/161d3d21-836f-43bf-b751-6da7de2a451dn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbLudDq7ZpL65wROMpZQUXxRi64qt6LLzmnSwRZeTQvyLw%40mail.gmail.com.


Re: [deal.II] MatrixTools::apply_boundary_values for BlockSparseMatrix> and BlockVector> entries

2021-09-17 Thread Daniel Arndt
Mariia,

I also tried fixing this within deal.II and discovered that some more
changes are necessary, see https://github.com/dealii/dealii/pull/12761.
Would you mind checking if the changes proposed there work for you?

Best,
Daniel

Am Fr., 17. Sept. 2021 um 06:25 Uhr schrieb Мария Бронзова <
masianic...@gmail.com>:

> Dear Daniel,
>
> Thank you a lot for the solution ways! I was trying to modify the
> /dealii-9.3.1/source/numerics/matrix_tools.inst.in as follows:
>
> // -
> //
> // Copyright (C) 2010 - 2018 by the deal.II authors
> //
> // This file is part of the deal.II library.
> //
> // The deal.II library is free software; you can use it, redistribute
> // it, and/or modify it under the terms of the GNU Lesser General
> // Public License as published by the Free Software Foundation; either
> // version 2.1 of the License, or (at your option) any later version.
> // The full text of the license can be found in the file LICENSE.md at
> // the top level directory of deal.II.
> //
> // -
>
> for (number : REAL_SCALARS)
>   {
> template void MatrixTools::local_apply_boundary_values(
>   const std::map _values,
>   const std::vector & local_dof_indices,
>   FullMatrix & local_matrix,
>   Vector & local_rhs,
>   const bool   eliminate_columns);
>
> template void MatrixTools::apply_boundary_values(
>   const std::map _values,
>   SparseMatrix &   matrix,
>   Vector & solution,
>   Vector & right_hand_side,
>   const bool   eliminate_columns);
>
> template void MatrixTools::apply_boundary_values(
>   const std::map _values,
>   BlockSparseMatrix &  matrix,
>   BlockVector &solution,
>   BlockVector &right_hand_side,
>   const bool   eliminate_columns);
>   }
>
> for (number : COMPLEX_SCALARS)
>   {
> template void MatrixTools::apply_boundary_values(
>   const std::map _values,
>   SparseMatrix &   matrix,
>   Vector & solution,
>   Vector & right_hand_side,
>   const bool   eliminate_columns);
>
> *template void MatrixTools::apply_boundary_values(*
> *  const std::map _values,*
> *  BlockSparseMatrix &  matrix,*
> *  BlockVector &solution,*
> *  BlockVector &right_hand_side,*
> *  const bool
>  eliminate_columns);*
>   }
>
> Then I recompiled everything and got the error:
>
> /home/mariia/Downloads/dealii-9.3.1/source/numerics/matrix_tools.cc:364:49:
> *error*: no match for ‘operator!=’ (operand types are
> ‘std::complex’ and ‘double’)
>   364 |   .diag_element(block_index.second) != 0.0)
> In file included from
> /home/mariia/Downloads/dealii-9.3.1/include/deal.II/base/parallel.h:23,
>  from
> /home/mariia/Downloads/dealii-9.3.1/include/deal.II/base/aligned_vector.h:25,
>  from
> /home/mariia/Downloads/dealii-9.3.1/include/deal.II/base/table.h:21,
>  from
> /home/mariia/Downloads/dealii-9.3.1/include/deal.II/lac/block_sparsity_pattern.h:25,
>  from
> /home/mariia/Downloads/dealii-9.3.1/include/deal.II/lac/sparsity_tools.h:24,
>  from
> /home/mariia/Downloads/dealii-9.3.1/include/deal.II/base/graph_coloring.h:25,
>  from
> /home/mariia/Downloads/dealii-9.3.1/include/deal.II/base/work_stream.h:22,
>  from
> /home/mariia/Downloads/dealii-9.3.1/source/numerics/matrix_tools.cc:19:
> ..
> make[2]: ***
> [source/numerics/CMakeFiles/obj_numerics_release.dir/build.make:188:
> source/numerics/CMakeFiles/obj_numerics_release.dir/matrix_tools.cc.o]
> Error 1
> make[1]: *** [CMakeFiles/Makefile2:3269:
> source/numerics/CMakeFiles/obj_numerics_release.dir/all] Error 2
> make: *** [Makefile:136: all] Error 2
>
>
> I am a bit confused, what else needs to be adjusted may be in the
> matrix_tools.cc. I would greatly appreciate help here.
>
> Thank you for your time!
>
> With kind regards,
> Mariia
>
>
> среда, 15 сентября 2021 г. в 16:56:41 UTC+2, d.arnd...@gmail.com:
>
>> Mariia,
>>
>> That's a problem a little more complicated to solve. Basically, we are
>> not instantiating the template for complex and BlockSparseMatrix.
>> If you are OK with recompiling deal.II, you should modify source/numerics/
>> matrix_tools.inst.in so that all overloads are also compiled for complex
>> numbers.
>> Otherwise, copy
>> 

Re: [deal.II] MatrixTools::apply_boundary_values for BlockSparseMatrix> and BlockVector> entries

2021-09-15 Thread Daniel Arndt
Mariia,

That's a problem a little more complicated to solve. Basically, we are not
instantiating the template for complex and BlockSparseMatrix.
If you are OK with recompiling deal.II, you should modify source/numerics/
matrix_tools.inst.in so that all overloads are also compiled for complex
numbers.
Otherwise, copy
https://github.com/dealii/dealii/blob/7439f2b0b4d210d237e8df53f12f47c242cfac3f/source/numerics/matrix_tools.cc#L240-L499
somewhere in your source code.

Best,
Daniel

Am Mi., 15. Sept. 2021 um 09:10 Uhr schrieb Мария Бронзова <
masianic...@gmail.com>:

> Dear Daniel,
>
> Thank you a lot for the hint, it makes perfect sense! I also correctted the*
> interpolate_boundary_values* call as follows:
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
> *templateclass DirichletBoundaryValues : public Function std::complex>   {   public:  DirichletBoundaryValues():
> Function>(1)   {}  virtual
> std::complex value(const Point , const unsigned int
> component = 1) const override;   };   template 
> std::complex DirichletBoundaryValues::value(const Point &
> p,   const unsigned int /*component*/) const   {  const
> std::complex i = {0,1};  return i;   }*
>
>
>
>
>
>
>
>
>
>
>
>
> * FEValuesExtractors::Scalar pressures(dim);
> std::map> boundary_values;
>   VectorTools::interpolate_boundary_values(dof_handler, 1,
> DirichletBoundaryValues(), boundary_values,
> fe.component_mask(pressures));
> MatrixTools::apply_boundary_values(boundary_values,   system_matrix,
> solution,   system_rhs);*
>
> And now getting the following error:
> undefined reference to 'void
> dealii::MatrixTools::apply_boundary_values
> >(std::map, std::less,
> std::allocator > > >
> const&, dealii::BlockSparseMatrix >&,
> dealii::BlockVector >&,
> dealii::BlockVector >&, bool)'
>
> I am a bit lost, what it could be connected to. Would appreciate any hints!
>
> Thank you a lot for your time!
>
> Kind regards,
> Mariia Bronzova
>
> вторник, 14 сентября 2021 г. в 16:33:44 UTC+2, d.arnd...@gmail.com:
>
>> Mariia,
>>
>> You need to make sure that the std::map also uses values of type
>> std::complex. The compile error you shared shows that you use
>> doubles.
>>
>> Best,
>> Daniel
>>
>> Am Di., 14. Sept. 2021 um 07:30 Uhr schrieb Мария Бронзова <
>> masia...@gmail.com>:
>>
>>> Hi everyone,
>>>
>>> I ran into the following difficulty: I have a vector-valued problem with
>>> complex numbers as entries for my BlockSparseMatrix system_matrix and
>>> BlockVector system_rhs and solution vectors and I am trying to apply
>>> Dirichlet boundary conditions, using the
>>> MatrixTools::apply_boundary_values(boundary_values, system_matrix,
>>> solution, system_rhs) function.
>>>
>>> The compiler is complaining, indicating the error: no matching function
>>> for call to ‘apply_boundary_values(std::map&,
>>> dealii::BlockSparseMatrix >&,
>>> dealii::BlockVector >&,
>>> dealii::BlockVector >&)’.
>>>
>>> Is it not possible to use the function for complex-values systems?
>>>
>>> Thank you!
>>>
>>> Kind regards,
>>> Mariia
>>>
>>> --
>>> The deal.II project is located at http://www.dealii.org/
>>> For mailing list/forum options, see
>>> https://groups.google.com/d/forum/dealii?hl=en
>>> ---
>>> You received this message because you are subscribed to the Google
>>> Groups "deal.II User Group" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to dealii+un...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/dealii/aa6ad6fa-7404-4617-bff3-3f108d2b6001n%40googlegroups.com
>>> 
>>> .
>>>
>> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/4a66ce86-5e20-4a5e-a28b-0073d2cfb185n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbLsbfraH%2Bqdt5zptyEYdG1Dk0OS0xYyVwO7D-8t0HNUeQ%40mail.gmail.com.


Re: [deal.II] MatrixTools::apply_boundary_values for BlockSparseMatrix> and BlockVector> entries

2021-09-14 Thread Daniel Arndt
Mariia,

You need to make sure that the std::map also uses values of type
std::complex. The compile error you shared shows that you use
doubles.

Best,
Daniel

Am Di., 14. Sept. 2021 um 07:30 Uhr schrieb Мария Бронзова <
masianic...@gmail.com>:

> Hi everyone,
>
> I ran into the following difficulty: I have a vector-valued problem with
> complex numbers as entries for my BlockSparseMatrix system_matrix and
> BlockVector system_rhs and solution vectors and I am trying to apply
> Dirichlet boundary conditions, using the
> MatrixTools::apply_boundary_values(boundary_values, system_matrix,
> solution, system_rhs) function.
>
> The compiler is complaining, indicating the error: no matching function
> for call to ‘apply_boundary_values(std::map&,
> dealii::BlockSparseMatrix >&,
> dealii::BlockVector >&,
> dealii::BlockVector >&)’.
>
> Is it not possible to use the function for complex-values systems?
>
> Thank you!
>
> Kind regards,
> Mariia
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/aa6ad6fa-7404-4617-bff3-3f108d2b6001n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbK1d1KXnrsK7D_%2BSo9EON_RCi-LnAGKbpiZAtvGXCh%3Dkw%40mail.gmail.com.


Re: [deal.II] Massively parallel & inverse matrix solver

2021-09-01 Thread Daniel Arndt
Hermes,

The SparseDirectUMFPACK solver doesn't work with MPI parallel matrices. You
will need to find another solver based on the matrix class you are using.
Standard choices would be GMRES or CG but I am assuming that your linear
system might also be non-symmetric or indefinite.

Best,
Daniel



Am Mi., 1. Sept. 2021 um 11:53 Uhr schrieb Hermes Sampedro <
hermesampe...@gmail.com>:

> Dear all,
>
> I am trying to solve a similar problem as step-29 but including the
> massive parallel solution as presented in step-40.
> I would like to ask how the solve() function would be in this case.
>
> In step-29:
> //LU decomposition and inverse matrix
> SparseDirectUMFPACK A_direct;
> A_direct.initialize(system_matrix);
>
> //Solve with inverse matrix
> A_direct.vmult(solution, system_rhs);
>
> When applying massive parallel computations, my initial guess was:
>
> LA::MPI::Vector
> completely_distributed_solution(locally_owned_dofs,mpi_communicator);
> //LU decomposition and inverse matrix
> SparseDirectUMFPACK A_direct;
> A_direct.initialize(system_matrix);
>
> //Solve with inverse matrix
> A_direct.vmult(completely_distributed_solution, system_rhs);
>  locally_relevant_solution = completely_distributed_solution;
>
>
>  However, I get a *no matching member function for call to 'vmult'*
> error.
>
> How can I use this LU decomposition and inverse matrix solver using MPI?
>
>
> Thank you,
>
> Regards,
>
> H
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/ded2e156-7bd7-4474-aa5f-fb57e8540926n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbKG87reQPBrhZu0RwoZHrMXMtVWS9Ui6EoFCWtmemG1vQ%40mail.gmail.com.


Re: [deal.II] Equation implementation

2021-08-25 Thread Daniel Arndt
Toddy,

I would start with thinking about the time discretization scheme you want
to use and in particular which terms you want to treat explicitly and which
implicitly.
After you have done that, you might still end up with a nonlinear problem
in which case you should have a look at
https://www.dealii.org/current/doxygen/deal.II/step_15.html and
https://www.dealii.org/current/doxygen/deal.II/step_25.html.

Best,
Daniel

Am Mi., 25. Aug. 2021 um 09:11 Uhr schrieb Toddy Liu :

> Dear Deal.II community,
>
> I'm getting trouble in constructing system matrix of a complex PDE. My PDE
> is a time-dependent equation, and in simplicity it seems like
>
> [image: screenshot.png]
> U is the variable, t denotes the time. D, alpha, beta are constant. So
> could you please give me some advice about doing this or any reference in
> existing dealii examples.
>
> Thank you very much.
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/b239ae4a-a114-47a7-ad59-a275f8771239n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2Bd7hp%2Bww7w9AKmYm1JnSwt8ZAFmig%3D5W_%3DZ-O6R14ORg%40mail.gmail.com.


Re: [deal.II] point_value, Real parts, step-29

2021-08-10 Thread Daniel Arndt
Hermes,

Use another overload. The one returning the solution as a parameter should
work:
https://www.dealii.org/current/doxygen/deal.II/namespaceVectorTools.html#acd358e9b110ccbf4a7f76796d206b9c7

Best,
Daniel

Am Di., 10. Aug. 2021 um 09:41 Uhr schrieb Hermes Sampedro <
hermesampe...@gmail.com>:

> Dear all,
>
> It is explained in Step-3 how to evaluate the solution in a point. I am
> trying to do the same for Step-29, to evaluate the real and imaginary parts
> separately in a single point:
>
> *std::cout << "Solution at (0.2,0.2): "<<
> VectorTools::point_value(dof_handler, solution,Point<2>(0.2, 0.2))<<
> std::endl;*
>
> I do not have any problems compiling however, an error occurs when running:
>
> *The violated condition was:  dof.get_fe(0).n_components() == 1*
>
> What is the proper way to call the real and imaginary parts of the
> solution at a particular point here?
>
>
> Thank you very much!
>
> H.
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/54a2d44e-194a-43c0-aa7f-9fddd5bd0dean%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2BR0bRTVxB-F22Hwk_ZexN4%3DVwCbZ7ZKqs3JjEaHFhncA%40mail.gmail.com.


Re: [deal.II] Copying field evaluated at quadrature points to device via CUDA

2021-08-09 Thread Daniel Arndt
Lucas,

In case you are using the GPU matrix-free framework as described in
step-64, you can use CUDAWrappers::MatrixFree::evaluate_coefficients() to
to perform the function inversion.
Otherwise, you need to keep track of the mapping from cells/quadrature
points to vector indices yourself. So you would fill a CUDA accessible
vector with the quadrature points and use that to fill the data vector you
want to perform your function inversion one.
LinearAlgebra::distributed::Vector with MemorySpace::CUDA should work well
for that.

Best,
Daniel

Am Mo., 9. Aug. 2021 um 14:22 Uhr schrieb Lucas Myers <
lucasmyer...@gmail.com>:

> Hi folks,
>
> As I understand it, the standard way of looping through a finite element
> problem is to iterate through (1) each cell in the mesh, (2) each
> quadrature point in the cell, (3) the ith shape functions, and (4) the jth
> shape functions. Given that, would it be possible to copy a finite element
> field evaluated at all of the quadrature points into an (n_cells x
> n_q_points_per_cell) array/vector/matrix/whatever?
>
> My purpose for doing this would be to copy this array over to a GPU device
> in order to perform a (somewhat complicated) function inversion in parallel
> on all of the quadrature point values, and then pass the inverted points
> back to the host. I have two questions regarding this business:
>
>1. If, after I have iterated through all cells/quadrature points and
>processed my data, I iterate *again* through the mesh/q_points/shape
>functions in order to fill in my matrix as in a typical FE problem, will
>the iteration go back through in the same way as the first time? That is,
>will I be able to index the processed data in the same way that I indexed
>the initial data that I copied over? This might be obvious, but I ask
>because the cell iterators are a seemingly complicated object that I don't
>understand fully yet.
>2. Is there a better way to do this process using already-written
>dealii objects (e.g. in the CUDAWrappers namespace)? I ask because I'm
>having a little bit of trouble parsing the step-64 comments, particularly
>regarding the management of different CUDA memory locations (e.g. how often
>does each object access global memory?).
>
> In any case, thank you for any help and for any general tips on the
> problem.
>
> Kind regards,
> Lucas
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/05ff3360-2772-4740-97d5-47b41f2ad052n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbL4yyj3%3DNJhqnVd5xoy7ufzpNeH698ioP4kRAzZ4p41%2Bg%40mail.gmail.com.


Re: [deal.II] step 21 runs error

2021-06-07 Thread Daniel Arndt
Nick,

Just pass "MappingQGeneric

(1)" as first argument, see
https://www.dealii.org/current/doxygen/deal.II/namespaceVectorTools.html#ac6b404bf03cb2a742b290421cc2789fe
.

Best,
Daniel

Am Mo., 7. Juni 2021 um 05:37 Uhr schrieb Nick Wang :

> When using the function "project", we found the mapping is necessary(in
> vector_tools_project.templates.h),but in step21(line 1155) don't have
> mapping. So when we run this exe, it has error and we can't get results.
> Therefore, we want know how to change this problem.
> [image: 1.png][image: 2.png]
> Thanks,
> Nick
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/c72ebdc7-d674-44e0-991d-794622168fd3n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWbJ4SdSE1PDFyyJXo_GunS6dF1YJ5Saudmqu_QhBAc0kqQ%40mail.gmail.com.


Re: [deal.II] Compiling deal.II with GCC version 9.3.0 results in missing C++11 features error

2021-06-07 Thread Daniel Arndt
Alex,

it looks like Trilinos and SUNDIALS are using different MPI implementations
that are incompatible. There is not much we can do about this within
deal.II.
Can you try to reinstall SUNDIALS or Trilinos using the same MPI
implementation as the other one?

Best,
Daniel

Am Mo., 7. Juni 2021 um 09:26 Uhr schrieb Alex Cumberworth <
alexandercumberwo...@gmail.com>:

> Hi Bruno,
>
> I repeated the compilation with deal.ii 9.3 and had the same error. I
> looked at the documentation in deal.ii for the class EpetraWrappers, and
> apparently it requires MPI:
>
> *This class implements a wrapper to the Trilinos distributed vector class
> Epetra_FEVector. This class is derived from the
> LinearAlgebra::VectorSpaceVector
> 
> class. Note however that Epetra only works with Number = double. This class
> requires Trilinos to be compiled with MPI support.*
> Since epetra is a required trilinos module, does this mean that if
> trilinos is included, it must be compiled with MPI (and then therefore also
> deal.ii, as cmake does not allow non-matching MPI configurations between
> them)?
>
> I recompiled trilinos with mpi on (openmpi 4.0.5), but when attempting to
> recompile deal.ii with MPI on, I ended up with new errors. There are too
> many errors to paste here, but it begins with
>
> In file included from
> /home/ipausers/cumberworth/include/Teuchos_Time.hpp:56,
>
>  from
> /home/ipausers/cumberworth/include/Teuchos_TimeMonitor.hpp:70,
>
>  from
> /home/ipausers/cumberworth/include/Teuchos_CommUtilities.hpp:45,
>
>  from
> /home/ipausers/cumberworth/include/Teuchos_CommHelpers.hpp:46,
>
>  from
> /home/ipausers/cumberworth/include/Kokkos_TeuchosCommAdapters.hpp:47,
>
>  from
> /home/ipausers/cumberworth/include/Sacado_Fad_ScalarTraitsImp.hpp:627,
>
>  from
> /home/ipausers/cumberworth/include/Sacado_Fad_DFadTraits.hpp:144,
>
>  from
> /home/ipausers/cumberworth/include/Sacado.hpp:51,
>
>  from
> /home/ipausers/cumberworth/src/dealii-9.2.0/include/deal.II/base/numbers.h:151,
>
>  from
> /home/ipausers/cumberworth/src/dealii-9.2.0/build13/include/deal.II/base/config.h:449,
>
>  from
> /home/ipausers/cumberworth/src/dealii-9.2.0/source/sundials/arkode.cc:17:
>
> /home/ipausers/cumberworth/include/mpi.h:30:13: error: conflicting
> declaration ‘typedef int
> MPI_Datatype’
>
>30 | typedef int
> MPI_Datatype;
>
>   |
> ^~~~
>
>
> I have included the rest as an attachment.
>
> Best,
> Alex
> On Monday, June 7, 2021 at 2:03:34 p.m. UTC+2 bruno.t...@gmail.com wrote:
>
>> Alex,
>>
>> This is really strange. I've never seen that error before. Can you try
>> to install deal.II 9.3
>> https://github.com/dealii/dealii/releases/tag/v9.3.0 and see if you
>> get the same error?
>>
>> Best,
>>
>> Bruno
>>
>> Le lun. 7 juin 2021 à 05:54, Alex Cumberworth
>>  a écrit :
>> >
>> > Hello,
>> >
>> > I recompiled trilinos without tpetra to sidestep this error, but ended
>> up with another error involving epetra, and apparently epetra is minimal
>> module required for trilinos with deal.ii, so I cannot do the same
>> thing.The error:
>> >
>> > [ 31%] Building CXX object
>> source/numerics/CMakeFiles/obj_numerics_debug.dir/data_out_dof_data.cc.o
>> > In file included from
>> /home/ipausers/cumberworth/src/dealii-9.2.0/source/numerics/data_out_dof_data.cc:28:
>>
>> >
>> /home/ipausers/cumberworth/src/dealii-9.2.0/include/deal.II/numerics/data_out_dof_data.templates.h:429:33:
>> error: ‘EpetraWrappers’ is not a member of ‘dealii::LinearAlgebra’
>> > 429 | VectorHelper::extract(
>> > | ^~
>> >
>> /home/ipausers/cumberworth/src/dealii-9.2.0/include/deal.II/numerics/data_out_dof_data.templates.h:429:55:
>> error: template argument 1 is invalid
>> > 429 | VectorHelper::extract(
>> > | ^
>> >
>> /home/ipausers/cumberworth/src/dealii-9.2.0/include/deal.II/numerics/data_out_dof_data.templates.h:430:28:
>> error: ‘EpetraWrappers’ in namespace ‘dealii::LinearAlgebra’ does not name
>> a type
>> > 430 | const LinearAlgebra::EpetraWrappers::Vector & /*vector*/,
>> > | ^~
>> >
>> /home/ipausers/cumberworth/src/dealii-9.2.0/include/deal.II/numerics/data_out_dof_data.templates.h:430:51:
>> error: expected unqualified-id before ‘&’ token
>> > 430 | const LinearAlgebra::EpetraWrappers::Vector & /*vector*/,
>> > | ^
>> >
>> /home/ipausers/cumberworth/src/dealii-9.2.0/include/deal.II/numerics/data_out_dof_data.templates.h:430:50:
>> error: expected ‘)’ before ‘&’ token
>> > 430 | const LinearAlgebra::EpetraWrappers::Vector & /*vector*/,
>> > | ^~
>> > | )
>> >
>> /home/ipausers/cumberworth/src/dealii-9.2.0/include/deal.II/numerics/data_out_dof_data.templates.h:429:65:
>> note: to match this ‘(’
>> > 429 | VectorHelper::extract(
>> > | ^
>> >
>> 

Re: [deal.II] How to get derivative value at one specified point after solving the system

2021-05-17 Thread Daniel Arndt
You can use VectorTools::point_gradient (
https://www.dealii.org/current/doxygen/deal.II/namespaceVectorTools.html#af72dcb595cc262bec07ca5c81614586f)
to obtain the gradient of a finite element solution in a specific point.

Best,
Daniel

Am Sa., 15. Mai 2021 um 23:05 Uhr schrieb 沈键 :

> I met a problem that need constrain one point's gradient to zero vector. I
> found it's hard to give this constraint in deal.ii, so I change it to a
> optimization problem whose target is to minimize the given point's gradient
> magnitude to zero, but an another problem appeared, in each iteration,
> after solving the system  I need to evaluate the gradient at that point,
> and what I know is that point geometry coordinate. How can I get derivative
> value at specified point after solving the system? Thanks for your answer
> in advance!
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/29d6d211-7a71-41f4-8121-5a413c4f4930n%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAOYDWb%2B%3D5XzXytm02aEw%2BeMcJp%3DHTVUDkBVosww9dFw_TEZk8g%40mail.gmail.com.


Re: [deal.II] Gmsh unexpected behaviour - axes directions swapped

2021-05-07 Thread Daniel Arndt
Vachan,

The documentation for the second version says

"Instead of defining a 'first' and 'second' boundary with the help of two
boundary_ids this function defines a 'left' boundary as all faces with
local face index 2*direction and boundary indicator b_id and, similarly, a
'right' boundary consisting of all face with local face index 2*direction+1
and boundary indicator b_id. Faces with coordinates only differing in the
direction component are identified."

So there is an assumption about the local face index and the direction
parameter that is also used for identifying faces. This implies that a case
like yours where the cell is rotated is not supported by this overload.
Just as you said, it's not enough for the cell to be in standard
orientation.

I'm sorry that this caused so much trouble but I'm glad that the first
version (that I would probably always recommend using anyway) works for you.

Best,
Daniel



Am Fr., 7. Mai 2021 um 02:58 Uhr schrieb vachanpo...@gmail.com <
vachanpotluri1...@gmail.com>:

> I think I have found an explanation.
>
> Since the mesh generated is a cartesian mesh, I was assuming that the
> faces of physical and reference cells have normals in the same direction
> and the mapping between then would be a simple stretching. But when I
> printed out vectors connecting face centers (0 to 1, 2 to 3 and 4 to 5), I
> found that this was not the case. The physical and reference cells have a
> rotation too included in the mapping.
>
> That was the reason why version 1
> 
>  of
> collect_periodic_faces() was working and version 2
> 
>  was
> not: since the direction parameter is also used to access faces in the
> latter version. This would produce an exception because there is a rotation
> of axes between physical and reference space and the boundary id wouldn't
> match.
>
> This has provoked another question. Version 2 of collect_periodic_faces()
> says 'This compatibility version of collect_periodic_faces() only works on
> grids with cells in standard orientation'. But is that sufficient? In my
> case, the mesh, after reading through GridIn, was in standard orientation.
> I had verified this by printing face orientation, flip and rotation. But
> since the boundary ids were set according to physical axes directions and
> these are different from reference axes directions, the output was
> unexpected to me.
>
> Any comments on whatever I concluded so far would be greatly helpful to me!
>
> On Thursday, May 6, 2021 at 10:41:21 AM UTC+5:30 vachanpo...@gmail.com
> wrote:
>
>> I have just read the gmsh manual and verified that the physical tags to
>> surfaces are indeed getting assigned properly. The relevant lines are 25-31
>> in the msh file provided above.
>>
>> I have arranged these lines in a table and verified that the physical
>> tags are getting assigned exactly as I prescribed in the geo file. The
>> picture shows the first 9 space-separated entries of lines 25-31 of
>> cube.msh. I have inserted an additional column commenting about the plane's
>> location.
>> [image: cube_surface_tags.png]
>>
>> According to the msh file, both x normal surfaces have tag 2, both y
>> normal surfaces have tag 3 and z normal surfaces have tags 4 and 5 --
>> exactly as in the geo file.
>>
>> So, I think the issue is with the procedure I am employing to read the
>> mesh. I am attaching the main.cc (provided in the MWE above) here again,
>> inline. I am unable to understand why the tags for y normal and z normal
>> surfaces get swapped when I read and print them using this code. I used a
>> similar code for 2D meshes and it worked fine. Are there any tricky things
>> to consider additionally in 3D?
>>
>> Vachan
>>
>>
>> 
>> #include 
>> #include 
>>
>> #include 
>> #include 
>> #include 
>> #include 
>> #include 
>>
>> using namespace dealii;
>>
>> int main(int argc, char **argv)
>> {
>> Utilities::MPI::MPI_InitFinalize mpi_initialization(argc, argv, 1);
>>
>> constexpr int dim = 3;
>>
>> MPI_Comm mpi_comm(MPI_COMM_WORLD);
>>
>> parallel::distributed::Triangulation triang(mpi_comm);
>>
>> GridIn grid_in;
>> grid_in.attach_triangulation(triang);
>> std::ifstream file("cube.msh");
>> grid_in.read_msh(file);
>>
>> const int periodic_dir = std::stoi(argv[1]); // first command line
>> argument
>> for(auto cell: triang.active_cell_iterators()){
>> const auto face_1 = cell->face(2*periodic_dir);
>> const auto face_2 = cell->face(2*periodic_dir+1);
>> if(face_1->at_boundary()){
>> std::cout << "Found face1 of local id " << 2*periodic_dir <<
>> " at boundary with bid "
>> << face_1->boundary_id() << "\n";
>> }
>> 

Re: [deal.II] The periodic boundary condition for an RVE analysis

2021-05-04 Thread Daniel Arndt
Farzin,

https://www.dealii.org/current/doxygen/deal.II/namespaceDoFTools.html#a03324e6e060c6a55191b2c60ad871eab
shows that the signature of the function you want to call is

void DoFTools::make_periodicity_constraints(
  const DoFHandlerType &   dof_handler,
  const types::boundary_id   b_id1,
  const types::boundary_id   b_id2,
  const unsigned int   direction,
  AffineConstraints< number > &   constraints,
  const ComponentMask &   component_mask = ComponentMask(),
  const number   periodicity_factor = 1.)

In particular, the AffineConstraints object comes before the ComponentMask
object (which can actually be omitted in your case).

Best,
Daniel

Am Di., 4. Mai 2021 um 10:18 Uhr schrieb Farzin Mozafari <
mozafari.far...@gmail.com>:

> Dear Daniel,
> Thank you for your reply.
>
> As per your recommendation, I followed step-45 for applying PBC. As far as
> I realized, since I am not using parallel meshing, the second and third
> steps are not necessary for my case. Thus, I just used steps 1 and 4 as
> follows:
>
>
> DoFTools::make_periodicity_constraints(dof_handler,10,11,0,ComponentMask(),constraints,1);
>
> But, I am getting the following error:
>
> error: no matching function for call to
> ‘make_periodicity_constraints(dealii::DoFHandler<3, 3>&, int, int, int,
> dealii::ComponentMask, dealii::AffineConstraints&, int)’
>   188 |
>  
> DoFTools::make_periodicity_constraints(dof_handler,10,11,0,ComponentMask(),constraints,1);
>   |
>  
> ~~^~~
>
> Are there any further steps that need to be taken?
>
> Regards,
> Farzin
>
> On Friday, 30 April 2021 at 00:44:48 UTC+3 d.arnd...@gmail.com wrote:
>
>> Farzin,
>>
>> std::vector> GridGenerator::Triangulation::cell_iterator>>
>> periodicity_vector;
>>
>> should be
>>
>> std::vector> Triangulation::cell_iterator>>
>> periodicity_vector;
>>
>> In general, I would recommend looking into step-45 (
>> https://www.dealii.org/current/doxygen/deal.II/step_45.html) for an
>> example using periodic boundary conditions.
>>
>> Best,
>> Daniel
>>
>> Am Do., 29. Apr. 2021 um 14:33 Uhr schrieb Farzin Mozafari <
>> mozafar...@gmail.com>:
>>
>>> Dear Daniel,
>>>
>>> Thank you for your reply.
>>> I tried to follow your solution, but I am encountering an error. To what
>>> follows, I will post my code and error as well. I will be thankful if you
>>> give me a piece of advice to get rid of this error.
>>> As I mentioned, my domain is a linear elastic cube that I am going to
>>> impose PBCs on opposite facec.
>>>
>>> My code is:
>>>
>>>
>>> template 
>>> void CubeVector::meshing()
>>> {
>>> const Point LL(0, 0, 0);
>>> const Point RH(0.1, 0.1, 0.1);
>>> std::vector repetition(dim);
>>> repetition[0] = 1;
>>> repetition[1] = 1;
>>> repetition[2] = 1;
>>> GridGenerator::subdivided_hyper_rectangle(triangulation, repetition, LL,
>>> RH);
>>> std::string mesh_name = "Rectangle-mesh";
>>> std::ofstream outputmeshfile(mesh_name);
>>> GridOut gridout;
>>> gridout.write_eps(triangulation, outputmeshfile);
>>> std::cout << " Mesh file output to "
>>> << mesh_name
>>> << std::endl;
>>>
>>> // Boundary indicator // Assign name to every face. This indicators will
>>> be used for defining periodic faces.
>>> double Lenght_x = RH[0] - LL[0];
>>> double Lenght_y = RH[1] - LL[1];
>>> double Lenght_z = RH[2] - LL[2];
>>> for (auto& face : triangulation.active_face_iterators()){
>>> if (face->at_boundary())
>>> {
>>> if (face->center()[0] == 0) { face->set_boundary_id(10);}
>>> if (face->center()[0] == Lenght_x) { face->set_boundary_id(11);}
>>> if (face->center()[1] == 0) { face->set_boundary_id(20);}
>>> if (face->center()[1] == Lenght_y) { face->set_boundary_id(21);}
>>> if (face->center()[2] == 0) { face->set_boundary_id(30);}
>>> if (face->center()[2] == Lenght_z) { face->set_boundary_id(31);}
>>>
>>>
>>> }
>>> }
>>> std::vector>> GridGenerator::Triangulation::cell_iterator>>
>>> periodicity_vector;
>>>
>>> GridTools::collect_periodic_faces(triangulation,
>>> 10,
>>> 11,
>>> 0,
>>> periodicity_vector);
>>>
>>> }
>>>
>>>
>>> And the error is :
>>>
>>> /mnt/d/research/deal_ii_projects/3d_elasticity/step-1.cc: In member
>>> function ‘void CubeVector::meshing()’:
>>> /mnt/d/research/deal_ii_projects/3d_elasticity/step-1.cc:179:19: error:
>>> ‘Triangulation’ is not a member of ‘dealii::GridGenerator’
>>>   179 |GridGenerator::Triangulation::cell_iterator>>
>>>   |   ^
>>> /mnt/d/research/deal_ii_projects/3d_elasticity/step-1.cc:179:19: note:
>>> suggested alternatives:
>>> In file included from
>>> /usr/local/include/deal.II/grid/tria_description.h:23,
>>>  from /usr/local/include/deal.II/grid/tria.h:28,
>>>  from
>>> /mnt/d/research/deal_ii_projects/3d_elasticity/step-1.cc:2:
>>> /usr/local/include/deal.II/grid/cell_id.h:37:7: note:
>>>  ‘dealii::Triangulation’
>>>37 | class Triangulation;
>>>   |   ^
>>> In file 

Re: [deal.II] Gmsh unexpected behaviour - axes directions swapped

2021-05-04 Thread Daniel Arndt
Vachan,

It is difficult to say what goes wrong here with the information you
provided. How does the msh file created by gmsh look like. Is the boundary
information correct there?
Which gmsh version are you using? Can you post a complete minimal example
of your code?

Best,
Daniel

Am Di., 4. Mai 2021 um 05:56 Uhr schrieb vachanpo...@gmail.com <
vachanpotluri1...@gmail.com>:

> Dear all,
>
> I have encountered a strange problem while dealing with physical boundary
> ids. I have a simple cube mesh (annexure 1) which I am exporting to msh4
> format for reading through GridIn. The mesh is constructed by extruding a
> square 2D mesh in x-y plane to 3D.
>
> I was facing problems with using collect_periodic_faces()
> 
>  on
> this mesh. So I mimicked the function by writing my own test function
> (annexure 2). It loops over faces with ids 2*direction and 2*direction+1
> (with direction=2) which lie on a boundary and prints the boundary id.
>
> According to the construction of the mesh (see geo file) face1 must have
> boundary id 4 and face 2 must have boundary id 5 in the test function
> (coincidentally, matching with the cell-local id). However, when I execute
> the test, the output shows both faces have a boundary id 0.
>
> More interestingly, if I uncomment the lines in geo file and set boundary
> ids for all boundaries (in the trailing lines), then the code execution
> shows boundary ids of y-normal and z-normal faces swapped; i.e.; face1 and
> face2 show boundary id 3 which was assigned to y-normal faces (see the
> output below).
>
> Found face1 of local id 4 at boundary with bid 3
> Found face2 of local id 5 at boundary with bid 3
>
> If I instead define face1 and face2 with direction=1 using
>
> const auto face_1 = cell->face(2);
> const auto face_2 = cell->face(3);
>
> in the test function and modify the local id in print statements, then the
> boundary ids printed are 4 and 5 which were assigned to z-normal faces.
>
> Found face1 of local id 2 at boundary with bid 4
> Found face2 of local id 3 at boundary with bid 5
>
> The x normal faces lying on boundary have the correct boundary id. So it
> looks like y and z axes are getting swapped?
>
> Am I doing something wrong? Has anyone experienced this before? I am
> unable to find an explanation for this behaviour.
>
> Thanking in anticipation
> Vachan
>
> *Annexure 1*
> 
> // cube.geo file
> SetFactory("OpenCASCADE");
>
> // Simple cube geometry
> lc=0.1;
> l=1;
>
> // 2D geometry
> p1=newp; Point(p1) = {0,0,0,lc};
> p2=newp; Point(p2) = {l,0,0,lc};
> p3=newp; Point(p3) = {l,l,0,lc};
> p4=newp; Point(p4) = {0,l,0,lc};
>
> l1=newl; Line(l1) = {p1,p2};
> l2=newl; Line(l2) = {p2,p3};
> l3=newl; Line(l3) = {p3,p4};
> l4=newl; Line(l4) = {p4,p1};
>
> Transfinite Curve{l1,l2,l3,l4} = 10;
>
> ll1=newll; Curve Loop(ll1) = {l1,l2,l3,l4};
> s1=news; Plane Surface(s1) = {ll1};
> Transfinite Surface{s1} = {p1,p2,p3,p4};
> Recombine Surface{s1};
>
> // 3D extrusion
> out[] = Extrude {0,0,l} {
> Surface{s1}; Layers{10}; Recombine;
> };
>
> // Physical entities
> Physical Volume(1) = {out[1]};
> // Physical Surface(2) = {out[3],out[5]}; // x dir faces
> // Physical Surface(3) = {out[2],out[4]}; // y dir faces
> Physical Surface(4) = {s1}; // z- dir face
> Physical Surface(5) = {out[0]}; // z+ dir face
>
> *Annexure 2*
> --
> // snippet from test function mimicking collect_periodic_faces()
> for(auto cell: problem.triang.active_cell_iterators()){
> const auto face_1 = cell->face(4);
> const auto face_2 = cell->face(5);
> if(face_1->at_boundary()){
> std::cout << "Found face1 of local id 4 at boundary with bid " <<
> face_1->boundary_id()
> << "\n";
> }
> if(face_2->at_boundary()){
> std::cout << "Found face2 of local id 5 at boundary with bid " <<
> face_2->boundary_id()
> << "\n";
> }
> }
>
> --
> The deal.II project is located at http://www.dealii.org/
> For mailing list/forum options, see
> https://groups.google.com/d/forum/dealii?hl=en
> ---
> You received this message because you are subscribed to the Google Groups
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/dealii/97ddd5ab-18be-4ce2-8ecf-b0d77cd70f9dn%40googlegroups.com
> 
> .
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II 

  1   2   3   4   5   >