Can you check that the generated normals on the two faces are actually one the 
opposite of the other? I see no other reasons for this to go wrong, unless the 
generated normals/geometry are not actually the same. 

Can you output a coarse result, using 10 subdivisions, and MappingManifold to 
generate the output? I’d expect the geometry to be continuous, but this may 
actually not be the case. This test should use the manifold of each cell to 
produce the subdivisions, so if the geometry is wrong, you should see a 
discontinuity (only if you produce more than one subdivision when generating 
the output, and if the subdivision respect the mapping…)

L.

> On 17 May 2016, at 10:38, Praveen C <cprav...@gmail.com> wrote:
> 
> Dear Luca
> 
> I am solving shallow water equation on sphere using a DG scheme. With 
> MappingQ, I get decent results, but I want to improve the mapping by using 
> MappingManifold.
> 
> With MappingManifold based on two charts, after just one time step, I see 
> large velocities at the junction region of the two charts as seen in attached 
> figure.
> 
> In the DG scheme, I have to assemble fluxes on the edges of the surface mesh.
> 
> Best
> praveen
> 
> On Tue, May 17, 2016 at 1:55 PM, luca.heltai <luca.hel...@gmail.com> wrote:
> Dear Praveen,
> 
> yes, I was expecting those numbers. Mapping Manifold should be machine 
> precision. I’d expect Q9 to be a little better though… I’ll try to look into 
> this (when I have some time).
> 
> What error do you see at the junction? What’s happening? What do you expect 
> to happen?
> 
> L.
> 
> 
> > On 17 May 2016, at 10:16, Praveen C <cprav...@gmail.com> wrote:
> >
> > So q_point * normal is most accurate with ManifoldMapping of O(1e-15) while 
> > MappingQ(9) is O(1e-9)
> >
> > Now the problem is when I use two charts, SphericalManifold and 
> > RotatedSphericalManifold to cover the sphere, I see errors at the junction 
> > region of the two charts.
> >
> > Best
> > praveen
> >
> > On Tue, May 17, 2016 at 12:30 PM, luca.heltai <luca.hel...@gmail.com> wrote:
> > Then can you verify which ones are correct, by taking the scalar product 
> > with the quadrature points (assuming a sphere centered at the origin), and 
> > check which ones are zero (IF they are zero)?
> >
> > Best,
> >
> > L.
> >
> >
> > > On 17 May 2016, at 8:53, Praveen C <cprav...@gmail.com> wrote:
> > >
> > > Dear Luca
> > >
> > > These are not normal to sphere surface, but normal to edges on the 
> > > sphere, which should be tangent to sphere surface.
> > >
> > > I get these normals from
> > >
> > > FEFaceValues<2,3> and using update_normal_vectors
> > >
> > > Best
> > > praveen
> > >
> > > On Tue, May 17, 2016 at 12:19 PM, luca.heltai <luca.hel...@gmail.com> 
> > > wrote:
> > > Can you verify which ones are correct? The normal on a sphere of radius 
> > > one, centered at the origin, is the same as the quadrature point itself. 
> > > From your numbers, MappingQ+Manifold seem completely off (y direction is 
> > > always zero?).
> > >
> > > Can you produce a minimal test that checks normals VS quadrature points?
> > >
> > > L.
> > >
> > >
> > > > On 17 May 2016, at 8:43, Praveen C <cprav...@gmail.com> wrote:
> > > >
> > > > Dear all
> > > >
> > > > There is also a large difference in face normal vectors which I need 
> > > > since I am using a DG scheme for pde on sphere.
> > > >
> > > > Here are normal vectors at some face quadrature points
> > > >
> > > > With MappingQ(9) + SphericalManifold
> > > > -0.707107 -1.28795e-09 0.707107
> > > >
> > > > -0.707107 -7.374e-10 0.707107
> > > >
> > > > -0.707107 -1.12489e-09 0.707107
> > > >
> > > > -0.707107 -1.08533e-09 0.707107
> > > >
> > > > -0.707107 -1.43344e-09 0.707107
> > > >
> > > > -0.707107 -1.52226e-09 0.707107
> > > >
> > > > -0.707107 -1.78585e-09 0.707107
> > > >
> > > > -0.707107 -1.81086e-09 0.707107
> > > >
> > > > -0.707107 -1.9384e-09 0.707107
> > > >
> > > > -0.707107 -1.80885e-09 0.707107
> > > >
> > > > With MappingManifold + SphericalManifold
> > > >
> > > > -0.649511 -0.103732 0.753243
> > > >
> > > > -0.652465 -0.101169 0.751036
> > > >
> > > > -0.659029 -0.0948727 0.74611
> > > >
> > > > -0.668238 -0.0844748 0.739136
> > > >
> > > > -0.678651 -0.0700161 0.731116
> > > >
> > > > -0.727853 0.06925 0.682227
> > > >
> > > > -0.730142 0.0918833 0.677089
> > > >
> > > > -0.730699 0.11164 0.67351
> > > >
> > > > -0.730325 0.125663 0.671442
> > > >
> > > >
> > > > -0.729954 0.131967 0.670636
> > > >
> > > >
> > > > The difference seems rather large.
> > > >
> > > > Best
> > > > praveen
> > > >
> > > > On Mon, May 16, 2016 at 9:08 PM, Praveen C <cprav...@gmail.com> wrote:
> > > > Dear Luca
> > > >
> > > > I need a Manifold<2,3> object but I could not succeed in composing 
> > > > SphericalManifold with a rotation. There were many dimensions involved 
> > > > in the composition which I have not understood.
> > > >
> > > > But I think I understood what it is supposed to do, so I modified 
> > > > Spherical Manifold by adding in a 90 deg rotation. I use 
> > > > RotatedSphericalManifold for north/south faces and SphericalManifold 
> > > > for the other faces.
> > > >
> > > > When I run my code with this, I find large errors arising in the region 
> > > > where north/south faces meet the other faces.
> > > >
> > > > Is there some incompatibility in my mapping ? Will the face normal 
> > > > vectors (which lie in tangent plane) be correct at the junction of the 
> > > > two manifolds ?
> > > >
> > > > The RotatedSphericalManifold is attached.
> > > >
> > > > Thanks
> > > > praveen
> > > >
> > > > On Mon, May 16, 2016 at 4:20 PM, luca.heltai <luca.hel...@gmail.com> 
> > > > wrote:
> > > >
> > > > > On 16 May 2016, at 12:37, Praveen C <cprav...@gmail.com> wrote:
> > > > >
> > > > > Dear Luca
> > > > >
> > > > > Thanks for clarifying this issue. I need tangent vector in my code.
> > > > >
> > > > > So I first define a ChartManifold which rotates by 90 deg about 
> > > > > x-axis, say RotateX. Then I compose it with SphericalManifold and use
> > > > >
> > > > > SphericalManifold * RotateX
> > > > >
> > > > > Is this what you meant ?
> > > > >
> > > > > We have the constructor
> > > > >
> > > > > CompositionManifold(F, G)
> > > > >
> > > > > Does this do F*G or G*F ? The description given in words is a bit 
> > > > > ambiguous.
> > > >
> > > >
> > > > y = G(F(x))
> > > >
> > > > "ChartManifold going from the chart of the firstChartManifold to the 
> > > > embedding space of the second ChartManifold"
> > > >
> > > > In your case, F is your spherical manifold, while your G is the 
> > > > rotation manifold (to preserve periodicity of the spherical manifold).
> > > >
> > > > Best,
> > > >
> > > > Luca.
> > > >
> > > > >
> > > > > Thanks
> > > > > praveen
> > > > >
> > > > > On Mon, May 16, 2016 at 2:29 PM, luca.heltai <luca.hel...@gmail.com> 
> > > > > wrote:
> > > > > Dear Praveen,
> > > > >
> > > > > there is a bug in SphericalManifold for dimension 3, which makes it 
> > > > > unusable so far with MappingManifold.
> > > > >
> > > > > The issue is with the computation of the tangent vector across the 
> > > > > north and south poles.
> > > > >
> > > > > At the moment MappingManifold is the only class using this 
> > > > > computation, so if you don’t use MappingManifold, you don’t see this 
> > > > > issue.
> > > > >
> > > > > You can solve it by writing a rotated SphericalManifold descriptor 
> > > > > (one where the poles are east and west respectively), and associating 
> > > > > this Manifold to the north and south faces of the sphere. You could 
> > > > > use, for example, CompositionManifold to compose a rotation of 90 
> > > > > degree along the x or y axis with SphericalManifold, and attach the 
> > > > > resulting manifold to the north and south faces.
> > > > >
> > > > > This is related to some of the issues here: 
> > > > > https://github.com/dealii/dealii/issues/2530
> > > > >
> > > > > What you are hitting is a problem with the geometry, not with 
> > > > > MappingManifold in itself. It is not possible to describe the surface 
> > > > > of a sphere with a single chart without introducing at least one 
> > > > > singularity. We have implemented the standard polar coordinate 
> > > > > mapping, which has two singularities (north and south poles 
> > > > > respectively), and these are the ones introducing nans in your 
> > > > > computation.
> > > > >
> > > > > Everything works fine when computing intermediate points, but not 
> > > > > when computing tangents. I’m still thinking of a way to fix this. The 
> > > > > easiest fix is to implement the SphericalManifold without charts, but 
> > > > > I haven’t had much time to sit down and do some fun stuff lately…
> > > > >
> > > > > Though, I can help you with implementing fixes, if you are willing to 
> > > > > help… :)
> > > > >
> > > > > L.
> > > > >
> > > > > > On 16 May 2016, at 10:35, Praveen C <cprav...@gmail.com> wrote:
> > > > > >
> > > > > > Dear all
> > > > > > I am solving pde on sphere and want to use MappingManifold
> > > > > >
> > > > > > My mesh is generated like this.
> > > > > >
> > > > > >       Point<spacedim> center(0.0, 0.0, 0.0);
> > > > > >       GridGenerator::hyper_sphere(triangulation, center, Radius);
> > > > > >       static SphericalManifold<dim,spacedim> surface_description;
> > > > > >       triangulation.set_all_manifold_ids(0);
> > > > > >       triangulation.set_manifold (0, surface_description);
> > > > > >       triangulation.refine_global(n_refine);
> > > > > >
> > > > > > Changing from MappingQ to MappingManifold leads to blow up, with 
> > > > > > nan.
> > > > > >
> > > > > > Before I debug, is there an example I can see of MappingManifold 
> > > > > > usage ?
> > > > > >
> > > > > > 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.
> > > > > > For more options, visit https://groups.google.com/d/optout.
> > > > >
> > > > > --
> > > > > 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.
> > > > > For more options, visit https://groups.google.com/d/optout.
> > > > >
> > > > >
> > > > > --
> > > > > 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.
> > > > > For more options, visit https://groups.google.com/d/optout.
> > > >
> > > > --
> > > > 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.
> > > > For more options, visit https://groups.google.com/d/optout.
> > > >
> > > >
> > > >
> > > > --
> > > > 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.
> > > > For more options, visit https://groups.google.com/d/optout.
> > >
> > > --
> > > 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.
> > > For more options, visit https://groups.google.com/d/optout.
> > >
> > >
> > > --
> > > 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.
> > > For more options, visit https://groups.google.com/d/optout.
> >
> > --
> > 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.
> > For more options, visit https://groups.google.com/d/optout.
> >
> >
> > --
> > 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.
> > For more options, visit https://groups.google.com/d/optout.
> 
> --
> 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.
> For more options, visit https://groups.google.com/d/optout.
> 
> 
> -- 
> 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.
> For more options, visit https://groups.google.com/d/optout.
> <visit0000.png>

-- 
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.
For more options, visit https://groups.google.com/d/optout.

Reply via email to