Re: [deal.II] Calculate cell center distance from a boundary

2022-02-17 Thread vachan potluri
>
> Hello,
> Here is the PR https://github.com/dealii/dealii/pull/13394 that adds the
> new wrappers for ArborX
> Best,
> Bruno


Thank you very much! Didn't expect it to come so fast :) !

-- 
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/CALAVa_x244GfUP_fr7Di8eTPjtPhbkJ8vDdNX2fEgyL%2BdXYGDw%40mail.gmail.com.


Re: [deal.II] Calculate cell center distance from a boundary

2022-02-17 Thread Bruno Turcksin
Hello,

Here is the PR https://github.com/dealii/dealii/pull/13394 that adds the 
new wrappers for ArborX

Best,

Bruno

On Saturday, February 12, 2022 at 11:58:35 PM UTC-5 vachanpo...@gmail.com 
wrote:

> Drs. Bruno and Wolfgang,
> *Actually what Wolfgang is suggesting is very doable. We have wrappers for 
> the ArborX 
> library 
> https://dealii.org/current/doxygen/deal.II/classArborXWrappers_1_1BVH.html 
>  
> which 
> allows you to find the nearest neighbor between two point clouds very 
> efficiently. You should be able to find the closest vertex on the boundary 
> for 100,000 points in a couple of seconds on the CPU and for several 
> millions of points if you are using a GPU. Right now we only have wrappers 
> for the serial version of ArborX but I have actually started to work on the 
> wrappers for distributed tree. When it's done, you will be able to get the 
> nearest neighbor even if they are on different processors.*
> That would be great! I think it would be very useful for applications like 
> turbulent flows where this information is required.
>
>
>
> *The best methods for the eikonal equation are all in the class of 
> "fastmarching method". It has its own wikipedia 
> page:https://en.wikipedia.org/wiki/Fast_marching_method 
> *
> Thank you very much!
> On Friday, February 11, 2022 at 9:48:16 PM UTC+5:30 Wolfgang Bangerth 
> wrote:
>
>> On 2/10/22 22:51, vachan potluri wrote: 
>> > This is a very difficult operation to do even in sequential 
>> computations 
>> > unless you have an analytical description of the boundary. That's 
>> because in 
>> > principle you would have to compare the current position with all 
>> points (or 
>> > at least all vertices) on the boundary -- which is very expensive to do 
>> if you 
>> > had to do it for more than just a few points. The situation does not 
>> get 
>> > better if you are in parallel, because then you don't even know all of 
>> the 
>> > boundary vertices. 
>> > 
>> > Completely realise and agree. 
>>
>> I stand corrected by Bruno about this -- I learned something today :-) 
>>
>>
>> > The only efficient way to do this sort of operation is to solve an 
>> eikonal 
>> > equation in which the solution function equals the distance to the 
>> boundary. 
>> > You can't solve it exactly, and so whatever distance you get is going 
>> to be a 
>> > finite-dimensional approximation of the exact distance function. 
>> > 
>> > I have got a basic idea of the equation from Wikipedia. Can you kindly 
>> also 
>> > point me to any references which describe its numerical solution 
>> technique? I 
>> > have no background in mathematics, so I have difficulty 
>> in understanding any 
>> > high level content. 
>>
>> The best methods for the eikonal equation are all in the class of "fast 
>> marching method". It has its own wikipedia page: 
>> https://en.wikipedia.org/wiki/Fast_marching_method 
>>
>> 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/eb91e358-299b-4e7e-9ce6-9734fe016379n%40googlegroups.com.


Re: [deal.II] Calculate cell center distance from a boundary

2022-02-12 Thread vachanpo...@gmail.com
Drs. Bruno and Wolfgang,
*Actually what Wolfgang is suggesting is very doable. We have wrappers for 
the ArborX 
library 
https://dealii.org/current/doxygen/deal.II/classArborXWrappers_1_1BVH.html 
 
which 
allows you to find the nearest neighbor between two point clouds very 
efficiently. You should be able to find the closest vertex on the boundary 
for 100,000 points in a couple of seconds on the CPU and for several 
millions of points if you are using a GPU. Right now we only have wrappers 
for the serial version of ArborX but I have actually started to work on the 
wrappers for distributed tree. When it's done, you will be able to get the 
nearest neighbor even if they are on different processors.*
That would be great! I think it would be very useful for applications like 
turbulent flows where this information is required.



*The best methods for the eikonal equation are all in the class of 
"fastmarching method". It has its own wikipedia 
page:https://en.wikipedia.org/wiki/Fast_marching_method 
*
Thank you very much!
On Friday, February 11, 2022 at 9:48:16 PM UTC+5:30 Wolfgang Bangerth wrote:

> On 2/10/22 22:51, vachan potluri wrote:
> > This is a very difficult operation to do even in sequential computations
> > unless you have an analytical description of the boundary. That's 
> because in
> > principle you would have to compare the current position with all points 
> (or
> > at least all vertices) on the boundary -- which is very expensive to do 
> if you
> > had to do it for more than just a few points. The situation does not get
> > better if you are in parallel, because then you don't even know all of 
> the
> > boundary vertices.
> > 
> > Completely realise and agree.
>
> I stand corrected by Bruno about this -- I learned something today :-)
>
>
> > The only efficient way to do this sort of operation is to solve an 
> eikonal
> > equation in which the solution function equals the distance to the 
> boundary.
> > You can't solve it exactly, and so whatever distance you get is going to 
> be a
> > finite-dimensional approximation of the exact distance function.
> > 
> > I have got a basic idea of the equation from Wikipedia. Can you kindly 
> also 
> > point me to any references which describe its numerical solution 
> technique? I 
> > have no background in mathematics, so I have difficulty in understanding 
> any 
> > high level content.
>
> The best methods for the eikonal equation are all in the class of "fast 
> marching method". It has its own wikipedia page:
> https://en.wikipedia.org/wiki/Fast_marching_method
>
> 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/37f735a4-6a08-4b09-94a4-0bcfb2e275a5n%40googlegroups.com.


Re: [deal.II] Calculate cell center distance from a boundary

2022-02-11 Thread Wolfgang Bangerth

On 2/10/22 22:51, vachan potluri wrote:

This is a very difficult operation to do even in sequential computations
unless you have an analytical description of the boundary. That's because in
principle you would have to compare the current position with all points (or
at least all vertices) on the boundary -- which is very expensive to do if 
you
had to do it for more than just a few points. The situation does not get
better if you are in parallel, because then you don't even know all of the
boundary vertices.

Completely realise and agree.


I stand corrected by Bruno about this -- I learned something today :-)



The only efficient way to do this sort of operation is to solve an eikonal
equation in which the solution function equals the distance to the boundary.
You can't solve it exactly, and so whatever distance you get is going to be 
a
finite-dimensional approximation of the exact distance function.

I have got a basic idea of the equation from Wikipedia. Can you kindly also 
point me to any references which describe its numerical solution technique? I 
have no background in mathematics, so I have difficulty in understanding any 
high level content.


The best methods for the eikonal equation are all in the class of "fast 
marching method". It has its own wikipedia page:

  https://en.wikipedia.org/wiki/Fast_marching_method

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/f1cea71e-138d-2acc-42c9-7ea4973c9d15%40colostate.edu.


Re: [deal.II] Calculate cell center distance from a boundary

2022-02-11 Thread Bruno Turcksin
Vachan,

On Friday, February 11, 2022 at 12:51:49 AM UTC-5 vachanpo...@gmail.com 
wrote:

> Dear Dr. Wolfgang,
>
> Thank you very much for the kind reply.
>  
>
>> This is a very difficult operation to do even in sequential computations
>> unless you have an analytical description of the boundary. That's because 
>> in
>> principle you would have to compare the current position with all points 
>> (or
>> at least all vertices) on the boundary -- which is very expensive to do 
>> if you
>> had to do it for more than just a few points. The situation does not get
>> better if you are in parallel, because then you don't even know all of the
>> boundary vertices.
>
> Completely realise and agree.
>

Actually what Wolfgang is suggesting is very doable. We have wrappers for 
the ArborX library 
https://dealii.org/current/doxygen/deal.II/classArborXWrappers_1_1BVH.html 
which allows you to find the nearest neighbor between two point clouds very 
efficiently. You should be able to find the closest vertex on the boundary 
for 100,000 points in a couple of seconds on the CPU and for several 
millions of points if you are using a GPU. Right now we only have wrappers 
for the serial version of ArborX but I have actually started to work on the 
wrappers for distributed tree. When it's done, you will be able to get the 
nearest neighbor even if they are on different processors.

Best,

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/87266398-5876-45f9-b51c-e9826df33f37n%40googlegroups.com.


Re: [deal.II] Calculate cell center distance from a boundary

2022-02-10 Thread vachan potluri
Dear Dr. Wolfgang,

Thank you very much for the kind reply.


> This is a very difficult operation to do even in sequential computations
> unless you have an analytical description of the boundary. That's because
> in
> principle you would have to compare the current position with all points
> (or
> at least all vertices) on the boundary -- which is very expensive to do if
> you
> had to do it for more than just a few points. The situation does not get
> better if you are in parallel, because then you don't even know all of the
> boundary vertices.

Completely realise and agree.

The only efficient way to do this sort of operation is to solve an eikonal
> equation in which the solution function equals the distance to the
> boundary.
> You can't solve it exactly, and so whatever distance you get is going to
> be a
> finite-dimensional approximation of the exact distance function.

I have got a basic idea of the equation from Wikipedia. Can you kindly also
point me to any references which describe its numerical solution technique? I
have no background in mathematics, so I have difficulty in understanding
any high level content.

Thanks again!

On Fri, 11 Feb 2022 at 10:22, Wolfgang Bangerth 
wrote:

> On 2/10/22 21:24, vachanpo...@gmail.com wrote:
> >
> > Is there a way to get the shortest distance from cell center to a given
> > boundary in p::d::Triangulation? What I really want is the wall normal
> > distance. Any other suggestions are also welcome.
>
> This is a very difficult operation to do even in sequential computations
> unless you have an analytical description of the boundary. That's because
> in
> principle you would have to compare the current position with all points
> (or
> at least all vertices) on the boundary -- which is very expensive to do if
> you
> had to do it for more than just a few points. The situation does not get
> better if you are in parallel, because then you don't even know all of the
> boundary vertices.
>
> The only efficient way to do this sort of operation is to solve an eikonal
> equation in which the solution function equals the distance to the
> boundary.
> You can't solve it exactly, and so whatever distance you get is going to
> be a
> finite-dimensional approximation of the exact distance function.
>
> 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/1df8e903-7124-86e1-2459-9a12a21f17f6%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/CALAVa_zfN377%2BFdGWRexwH6ub64kfSLp73bRYwpfXtpQeWVY3g%40mail.gmail.com.


Re: [deal.II] Calculate cell center distance from a boundary

2022-02-10 Thread Wolfgang Bangerth

On 2/10/22 21:24, vachanpo...@gmail.com wrote:


Is there a way to get the shortest distance from cell center to a given 
boundary in p::d::Triangulation? What I really want is the wall normal 
distance. Any other suggestions are also welcome.


This is a very difficult operation to do even in sequential computations 
unless you have an analytical description of the boundary. That's because in 
principle you would have to compare the current position with all points (or 
at least all vertices) on the boundary -- which is very expensive to do if you 
had to do it for more than just a few points. The situation does not get 
better if you are in parallel, because then you don't even know all of the 
boundary vertices.


The only efficient way to do this sort of operation is to solve an eikonal 
equation in which the solution function equals the distance to the boundary. 
You can't solve it exactly, and so whatever distance you get is going to be a 
finite-dimensional approximation of the exact distance function.


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/1df8e903-7124-86e1-2459-9a12a21f17f6%40colostate.edu.