hermite_ex1.cpp

Go to the documentation of this file.
00001 #include <SyFi.h>
00002 
00003 using namespace GiNaC; 
00004 
00005 int main(){ 
00006   //---          2D Hermite element
00007   Triangle triangle(lst(0,0), lst(1,0), lst(0,1));   
00008   HermiteFE fe; 
00009   fe.set(triangle); 
00010   fe.compute_basis_functions(); 
00011 
00012   usage(fe); 
00013 
00014   Dof dof; 
00015   std::map<std::pair<int,int>, ex> A; 
00016   compute_Poisson_element_matrix(fe, dof, A); 
00017   print(A); 
00018 
00019   //---          3D Hermite element
00020 
00021   Tetrahedron tetrahedron(lst(0,0,0), lst(1,0,0), lst(0,1,0), lst(0,0,1));   
00022   HermiteFE fe2; 
00023   fe2.set(tetrahedron); 
00024   fe2.compute_basis_functions(); 
00025 
00026   usage(fe2); 
00027 
00028   Dof dof2; 
00029   std::map<std::pair<int,int>, ex> A2; 
00030   compute_Poisson_element_matrix(fe2, dof2, A2); 
00031   print(A2); 
00032 
00033 
00034 
00035 
00036 }
00037 

Generated on Wed Apr 19 12:38:13 2006 for SyFi by  doxygen 1.4.4