basis functions for Discontinuous Galerkin
Dear all, I am a new Nektar++ user. I want to use the Advection-Diffusion-Reaction Solver where Discontinuous Galerkin method is chosen (property "Projection" has the value "Discontinuous") to solve 2D Unsteady Advection equations over a mesh comprised of both triangles and quads. I have two questions. Q1) When TYPE = "MODIFIED" (in the "EXPANSIONS" node in a xml file), what are the basis functions over a triangle, over a quad used? The user guide v4.2.0, Section 3.2 addresses this part only generally. Q2) The approximate solution is a linear combination of basis functions. How can one export the coefficients of the linear combination to an output file? I opened a file *.fld, those coefficients seem to be written inside the node <"ELEMENTS FIELDS="u"...> but the output coefficients are in some kind of encrypted format. Are there any documents that I can find answers to the two questions? Of course, I appreciate very much if someone can answer those questions via this mailing list. Thank you very much in advance, Manh Nguyen Department of Computer & Information Science & Engineering, University of Florida
Hi Manh,
On 1 Feb 2016, at 21:07, Manh Nguyen <dmanhn@gmail.com> wrote:
Dear all,
I am a new Nektar++ user. I want to use the Advection-Diffusion-Reaction Solver where Discontinuous Galerkin method is chosen (property "Projection" has the value "Discontinuous") to solve 2D Unsteady Advection equations over a mesh comprised of both triangles and quads.
I have two questions.
Q1) When TYPE = "MODIFIED" (in the "EXPANSIONS" node in a xml file), what are the basis functions over a triangle, over a quad used? The user guide v4.2.0, Section 3.2 addresses this part only generally.
This would be the modified orthogonal basis. The best definition is probably in the code, especially given Q2 below: http://doc.nektar.info/doxygen/4.2.0/class_nektar_1_1_lib_utilities_1_1_basi... Quads use a tensor product of two 1D ModifiedA expansions; Triangles use a tensor product of ModifiedA and ModifiedB.
Q2) The approximate solution is a linear combination of basis functions. How can one export the coefficients of the linear combination to an output file? I opened a file *.fld, those coefficients seem to be written inside the node <"ELEMEMNTS FIELDS="u"...> but the output coefficients are in some kind of encrypted format.
It's not encrypted but it is compressed -- in particular, the string inside the ELEMENTS tag is an array of doubles with precisely the coefficients you want, but compressed with zlib and then base64 encoded. I'd suggest that if you want the raw data, it would be worth looking at the code, and, in particular, the routines from LibUtilities/BasicUtils/FieldIO.cpp.
Are there any documents that I can find answers to the two questions? Of course, I appreciate very much if someone can answer those questions via this mailing list.
We are working on the developers guide at the moment, which will be a bit more of a technical manual to consult for finer-grained detail. Until then its just the code, user guide, Spencer's book and any papers which we may have published on the topics! Plus this mailing list of course :-) Cheers, Dave
Thank you very much in advance, Manh Nguyen Department of Computer & Information Science & Engineering, University of Florida _______________________________________________ Nektar-users mailing list Nektar-users@imperial.ac.uk https://mailman.ic.ac.uk/mailman/listinfo/nektar-users
-- David Moxey (Research Associate) d.moxey@imperial.ac.uk | www.imperial.ac.uk/people/d.moxey Room 363, Department of Aeronautics, Imperial College London, London, SW7 2AZ, UK.
Hi Dave, Thank you very much for the answers. I will look into your hints and will let you know if I need more help. Cheers, Manh http://www.cise.ufl.edu/~dmnguyen/ Department of Computer & Information Science & Engineering, University of Florida On Mon, Feb 1, 2016 at 5:02 PM, David Moxey <d.moxey@imperial.ac.uk> wrote:
Hi Manh,
On 1 Feb 2016, at 21:07, Manh Nguyen <dmanhn@gmail.com> wrote:
Dear all,
I am a new Nektar++ user. I want to use the Advection-Diffusion-Reaction Solver where Discontinuous Galerkin method is chosen (property "Projection" has the value "Discontinuous") to solve 2D Unsteady Advection equations over a mesh comprised of both triangles and quads.
I have two questions.
Q1) When TYPE = "MODIFIED" (in the "EXPANSIONS" node in a xml file), what are the basis functions over a triangle, over a quad used? The user guide v4.2.0, Section 3.2 addresses this part only generally.
This would be the modified orthogonal basis. The best definition is probably in the code, especially given Q2 below:
http://doc.nektar.info/doxygen/4.2.0/class_nektar_1_1_lib_utilities_1_1_basi...
Quads use a tensor product of two 1D ModifiedA expansions; Triangles use a tensor product of ModifiedA and ModifiedB.
Q2) The approximate solution is a linear combination of basis functions. How can one export the coefficients of the linear combination to an output file? I opened a file *.fld, those coefficients seem to be written inside the node <"ELEMEMNTS FIELDS="u"...> but the output coefficients are in some kind of encrypted format.
It's not encrypted but it is compressed -- in particular, the string inside the ELEMENTS tag is an array of doubles with precisely the coefficients you want, but compressed with zlib and then base64 encoded. I'd suggest that if you want the raw data, it would be worth looking at the code, and, in particular, the routines from LibUtilities/BasicUtils/FieldIO.cpp.
Are there any documents that I can find answers to the two questions? Of course, I appreciate very much if someone can answer those questions via this mailing list.
We are working on the developers guide at the moment, which will be a bit more of a technical manual to consult for finer-grained detail. Until then its just the code, user guide, Spencer's book and any papers which we may have published on the topics! Plus this mailing list of course :-)
Cheers,
Dave
Thank you very much in advance, Manh Nguyen Department of Computer & Information Science & Engineering, University of Florida _______________________________________________ Nektar-users mailing list Nektar-users@imperial.ac.uk https://mailman.ic.ac.uk/mailman/listinfo/nektar-users
-- David Moxey (Research Associate) d.moxey@imperial.ac.uk | www.imperial.ac.uk/people/d.moxey
Room 363, Department of Aeronautics, Imperial College London, London, SW7 2AZ, UK.
participants (2)
-
David Moxey
-
Manh Nguyen