SyFi  0.3
nedelec_ex1.cpp File Reference
#include <SyFi.h>

Go to the source code of this file.

Functions

void print_out (FE &fe)
int main ()

Function Documentation

int main ( )

Definition at line 12 of file nedelec_ex1.cpp.

References SyFi::Nedelec::compute_basis_functions(), SyFi::initSyFi(), print_out(), SyFi::StandardFE::set_order(), and SyFi::StandardFE::set_polygon().

           {

    initSyFi(2); 

    ReferenceTriangle triangle; 
    Nedelec fe; 
    fe.set_polygon(triangle); 
    fe.set_order(0); 
    fe.compute_basis_functions(); 
    cout <<"-------- 0 order ---------- 2D "<<endl; 
    print_out(fe); 

    fe.set_order(1); 
    fe.compute_basis_functions(); 
    cout <<"-------- 1 order ---------- 2D"<<endl; 
    print_out(fe); 

    fe.set_order(2); 
    fe.compute_basis_functions(); 
    cout <<"-------- 2 order ---------- 2D"<<endl; 
    print_out(fe); 

    fe.set_order(3); 
    fe.compute_basis_functions(); 
    cout <<"-------- 2 order ---------- 2D"<<endl; 
    print_out(fe); 





    initSyFi(3); 

    ReferenceTetrahedron tetrahedon; 
    fe.set_polygon(tetrahedon); 
    fe.set_order(0); 
    fe.compute_basis_functions(); 
    cout <<"-------- 0 order ---------- 3D "<<endl; 
    print_out(fe); 

    fe.set_order(1); 
    fe.compute_basis_functions(); 
    cout <<"-------- 1 order ---------- 3D "<<endl; 
    print_out(fe); 

    fe.set_order(2); 
    fe.compute_basis_functions(); 
    cout <<"-------- 2 order ---------- 3D "<<endl; 
    print_out(fe); 

    fe.set_order(3); 
    fe.compute_basis_functions(); 
    cout <<"-------- 2 order ---------- 3D "<<endl; 
    print_out(fe); 


    return 0; 


}
void print_out ( FE fe)

Definition at line 6 of file nedelec_ex1.cpp.

References SyFi::FE::N(), and SyFi::FE::nbf().

Referenced by main().

                       { 
    for (unsigned int i=0; i< fe.nbf(); i++) { 
        cout <<"fe.N("<<i<<")        =       "<<fe.N(i)<<endl; 
    }
}
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator