Thanks for your reply.

 

I probably found the reason of the problem.

 

As said before I'm trying to solve an eq of this type:

 

A(d phi/d t) =  div (D grad phi) + q

 

where A and D are costant coefficient and q is a spatially varying heat source.

 

The problem is in how I create the cylindrical 1D mesh (origin of the mesh is 
not in 0.).

 

It doesn't matter if the discretization is logarithmic or uniform but how I 
declare it:

 

(using a uniform spacing:)

 
**  mesh = CylindricalGrid1D(dx=dr, nx=(len(DR))) + (r_int,)  **
 

SHOULD BE EQUAL TO:

 

**  mesh = CylindricalGrid1D(dx=DR) + (r_int,)  **

 

[dr = 5e-04, nr=58, r_int=0.00125, DR is a list which contains the various 
dx(58 elements of value dr for uniform grid)]

 

BUT It is NOT.

 

The mesh (cell centers, facecenters) is ok but the results are NOT.

The results are right only if I create the mesh using dx=dr and nx=.. .

And this is why before I thought the problem was the logaritmic discretization 
(must use DR=[...]).

 

As said before with Cylindrical 2D mesh results are instead correct.

Is this a bug?

 
> Date: Thu, 6 May 2010 11:11:10 -0400
> From: [email protected]
> To: [email protected]
> Subject: Re: Problem in solving Poisson equation with 1D Cylindrical mesh
> 
> 
> Edward, This may be to do with having a very small volume (or area or
> line or point) for the inner most element of the domain. It should be
> the same whether one is using a 1D or 2D mesh. Since you are getting
> differences in the 1D and 2D case, it should be relatively easy to
> debug and figure out what's going on. It could also be that the
> boundary condition on the inner boundary as zero area and this is
> causing issues. Try shifting the grid by a small value away from the
> zero point and see if things are improved. I have always had this
> issue with cylindrical grids and have never really had a satisfactory
> solution (other than shifting away from the zero point). If you
> discover a better way to handle this, let me know. Cheers.
> 
> 
> If you can't debug it, then send me the most minimalist scripts that
> show the issue and I'll give it a shot.
> 
> On Wed, May 5, 2010 at 9:53 PM, Eduard Manley <[email protected]> wrote:
> > Problem partially solved:
> >
> > I'm using a logarithmic discretization (first dr= 5e-04 and next
> > dr increasing as 1.05)(with internal radius= 0.00125, external radius=0.03)
> > and,
> > for some unknown reason this create problems and wrong result with
> > cylindrical 1D mesh. I tried using a uniform discretization (dr=5e-04 nx=58)
> > and now the result is correct.
> >
> > However I need to use the logarithmic discr. so after some hours of sleep
> > I'll think about the reason.....
> >
> > ________________________________
> > Hotmail: Trusted email with powerful SPAM protection. Sign up now.
> 
> 
> 
> -- 
> Daniel Wheeler
> 
> 
                                          
_________________________________________________________________
Your E-mail and More On-the-Go. Get Windows Live Hotmail Free.
https://signup.live.com/signup.aspx?id=60969

Reply via email to