[deal.II] Re: Issue with intersection of two meshes with curved boundaries

2023-12-05 Thread Marco Feder
After debugging this particular instance, it turns out the issue is related to the CGAL kernels used by deal.II. In particular, with CGAL it's possible to rely on the so-called "exact computation paradigm" (a brief explanation is available here: https://www.cgal.org/exact.html). In the dealii::

[deal.II] Re: Trying to interpolate deal.ii solution to a Cartesian grid

2023-03-08 Thread Marco Feder
Hi, I've recently used the following function for a similar task: https://www.dealii.org/developer/doxygen/deal.II/classFunctions_1_1FEFieldFunction.html#ac25d965867c71d1139262cf383f9f593 (see in particular the first snippet). This works under the assumption that the cartesian grid is entirely

[deal.II] Re: Spack error with cgal and arbox

2023-02-22 Thread Marco Feder
Hi Wayne, CGAL requires C++17, hence you should add a proper compiler flag (https://github.com/dealii/dealii/wiki/deal.II-in-Spack#compiler-flags) if you want to have it. Adding *cppflags="-std=c++17"* should fix that. For what concerns your last message, here's a related discussion: https:/

[deal.II] Re: Finding cut cells

2022-12-15 Thread Marco Feder
Hi, I think Step 85 does this by using a (global) level set function. Otherwise, you can use RTrees of bounding boxes with https://www.dealii.org/developer/doxygen/deal.II/classGridTools_1_1Cache.html#aca2782d6e93b5a0033c046b57904c67f combined with boost::geometry::index to identify intersec

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

2022-11-07 Thread Marco Feder
Ah, I hadn’t noticed you were compiling a tutorial program. My apologies. Il giorno lunedì 7 novembre 2022 alle 17:53:10 UTC+1 d.arnd...@gmail.com ha scritto: > You would get this compile-time error if you haven't configured deal.II > with `DEAL_II_WITH_MPI=ON`. > > Best, > Daniel > > On Mon, N

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

2022-11-07 Thread Marco Feder
Hi, the copy constructor for Triangulation is indeed deleted. If you do need a copy, you may want to use copy_triangulation() , that is also implemented for p::d::T.

Re: [deal.II] How to implemente the Neumann bc for laplacian

2022-08-26 Thread Marco Feder
mail.com >> <http://gmail.com/> wrote: >> Actually, it turns out there's a tutorial program doing precisely what you >> are looking for: step-11 >> (https://www.dealii.org/developer/doxygen/deal.II/step_11.html >> <https://www.dealii.org/developer/doxygen/

Re: [deal.II] How to implemente the Neumann bc for laplacian

2022-08-26 Thread Marco Feder
per/doxygen/deal.II/step_11.html > <https://www.dealii.org/developer/doxygen/deal.II/step_11.html>) > > Best, > Marco > > Il giorno martedì 23 agosto 2022 alle 18:54:24 UTC+2 Marco Feder ha scritto: > > Hi, > > step-7 (https://www.dealii.org/current/doxygen

[deal.II] Re: How to implemente the Neumann bc for laplacian

2022-08-23 Thread Marco Feder
Actually, it turns out there's a tutorial program doing precisely what you are looking for: step-11 (https://www.dealii.org/developer/doxygen/deal.II/step_11.html) Best, Marco Il giorno martedì 23 agosto 2022 alle 18:54:24 UTC+2 Marco Feder ha scritto: > > Hi, > &

[deal.II] Re: How to implemente the Neumann bc for laplacian

2022-08-23 Thread Marco Feder
Hi, step-7 (https://www.dealii.org/current/doxygen/deal.II/step_7.html) shows this procedure. Be careful that if you apply Neumann BCs on all your boundary, then the solution is determined up to a constant and you need to add an additional constraint to your solution. Also, you need to satisfy

Re: [deal.II] FEInterfaceValues and hp::FECollection

2022-08-18 Thread Marco Feder
on cell 0, columns to local dofs on cell > 1. > > 4. Use global_dof_indices of cell 0 and cell 1 to map each local matrix to > the global matrix. > > Best, > Simon > > > > On 09/08/2022 00:58, Marco Feder wrote: >> Dear all, >> I'm using a

[deal.II] FEInterfaceValues and hp::FECollection

2022-08-08 Thread Marco Feder
Dear all, I'm using an hp::FECollection object to describe different FE spaces in my grid. In particular, I'm in the following scenario: x- - - - - -x | | | 0 | | | x - - F - -x | | | 1 | | | x- - - - - -x On cell number 0 I h

[deal.II] Re: dealii-9.4.0 release candidate 1

2022-07-01 Thread Marco Feder
This may be of interest to you: https://github.com/dealii/dealii/issues/13574#issuecomment-1166472620 Best, Marco Il giorno giovedì 30 giugno 2022 alle 13:55:34 UTC+2 Alberto Salvadori ha scritto: > Matthias, > > I wonder if this release is fully compatible with Apple M1 (and M2 as > well) o

Re: [deal.II] convert linear_operator to SparseMatrix or get the inverse of linear_operator

2022-04-09 Thread Marco Feder
Hi Chen, You can work directly with LinearOperator(s). What you need is the *inverse operator* of op_M , and you can get it by giving a Solver and a corresponding preconditioner to inverse_operator() [https://www.dealii.org/current/doxygen/deal.II/group__LAOperators.html#ga87e38fbde431397c069a8

[deal.II] Re: Integral over different lines

2022-03-12 Thread Marco Feder
Hi Giuseppe, if your goal is to compute the integral of an arbitrary function f(x,y) over a random segment inside your rectangle (you can assume the segment is not parallel to x-axis or y-axis), you could just consider its parametrisation \phi(t), t \in [0,1] so that you have a 1D integral that

[deal.II] Re: Integral over different lines

2022-03-12 Thread Marco Feder
Hi Giuseppe, if your goal is to compute the integral an arbitrary function f(x,y) over a random segment inside your rectangle (you can assume the segment is not parallel to x-axis or y-axis), you could just consider its parametrisation \phi(t), t \in [0,1] so that you have a 1D integral that yo

Re: [deal.II] Extractors for local_rhs in step-22

2021-11-19 Thread Marco Feder
Thanks Wolfgang, indeed, as we have incompressibility, the last component of the rhs will always be 0. I wrote a possible patch, I'll open the pr tomorrow so that I can take another look at it! Best, Marco Il giorno venerdì 19 novembre 2021 alle 23:15:50 UTC+1 Wolfgang Bangerth ha scritto: >

[deal.II] Extractors for local_rhs in step-22

2021-11-18 Thread Marco Feder
Dear all, I was going through step-22 and I saw that since you're using primitive elements, then you compute the local_rhs contribution using *fe.system_to_component_index(i).first* However, as written in the program, we could as well multiply the dim+1 tensor having the values of the i-th sha

Re: [deal.II] Inaccurate convergence rate using ParsedConvergenceTable class

2021-08-09 Thread Marco Feder
n the class documentation. > This explains the results you see... > > On Sun, Aug 8, 2021, 15:15 Marco Feder wrote: > >> Ciao Luca! >> >> > Can you check if you get the same results with this order? >> Yes, the rates are the same. >> >> > Are you ca

Re: [deal.II] Inaccurate convergence rate using ParsedConvergenceTable class

2021-08-08 Thread Marco Feder
Ciao Luca! > Can you check if you get the same results with this order? Yes, the rates are the same. > Are you calling `error_from_exact` with mapping as a first argument? Yes Actually, I've fixed the issue after reading this: > If the Solution class implements the Gradient, then ParsedConverg