getfem-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Getfem-users] Structured mesh coordinate values


From: Yves Renard
Subject: Re: [Getfem-users] Structured mesh coordinate values
Date: Fri, 24 Sep 2010 09:14:18 +0200
User-agent: KMail/1.13.2 (Linux/2.6.32-24-server; KDE/4.4.2; x86_64; ; )

Dear Torquil,

No, this really generates a mesh on the cube [0,1]^3. Are you sure you do not 
have an instruction

mesh.transformation(M);

after the mesh generation  (like in tests/laplacian.cc) ?

Another simple way to generate a structured mesh is to use getfem::import_mesh 
like this :


getfem::import_mesh("structured:GT_QK(3,1)";SIZES=[1,1,1];NSUBDIV=[10,10,10]", 
mesh);

This allows to use a the regular mesh from a parameter file instead of a 
filename.

Yves.


On jeudi 23 septembre 2010, Torquil Macdonald Sørensen wrote:
> Hi!
> 
> In the "Short User Documentation" it is written that to generate a 10x10x10
> mesh on the unit cube [0,1]^3, the following code would work:
> 
> getfem::mesh mymesh;
> bgeot::base_node org(0.0, 0.0, 0.0);
> std::vector<bgeot::base_small_vector> vect(3);
> vect[0] = bgeot::base_small_vector(1.0, 0.0, 0.0);
> vect[1] = bgeot::base_small_vector(0.0, 1.0, 0.0);
> vect[2] = bgeot::base_small_vector(0.0, 0.0, 1.0);
> std::vector<int> ref(3);
> ref[0] = ref[1] = ref[2] = 10;
> getfem::parallelepiped_regular_simplex_mesh(mymesh, 3, org, vect.begin(),
> ref.begin());
> 
> But when I print the coordinates of the points in this mesh, i.e.
> mymesh.points(), I get component values not within [0,1], but in [0,10].
> 
> Is this a mistake in the documentation, or do these values not represent
> the coordinates of the points (but instead "scaled coordinates")?
> 
> Thanks!
> Torquil
> 
> _______________________________________________
> Getfem-users mailing list
> address@hidden
> https://mail.gna.org/listinfo/getfem-users


-- 

  Yves Renard (address@hidden)       tel : (33) 04.72.43.87.08
  Pole de Mathematiques, INSA-Lyon             fax : (33) 04.72.43.85.29
  20, rue Albert Einstein
  69621 Villeurbanne Cedex, FRANCE
  http://math.univ-lyon1.fr/~renard

---------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]