SyFi  0.3
barycenter_simplex.cpp File Reference
#include <SyFi.h>
#include <fstream>

Go to the source code of this file.

Functions

int main ()

Function Documentation

int main ( )

Definition at line 8 of file barycenter_simplex.cpp.

References SyFi::barycenter(), and SyFi::initSyFi().

           {

  /*
    initSyFi(3); 

    ex p0 = lst(0.0,0.0,0.0);
    ex p1 = lst(1.0,0.0,0.0);
    ex p2 = lst(0.0,1.0,0.0);
    ex p3 = lst(0.0,0.0,1.0);

    Simplex simplex(lst(p0,p1,p2,p3)); 

    ex coord = barycenter(simplex); 
    cout <<"coord "<<coord<<endl; 
    */

    initSyFi(4); 

    ex q0 = lst(0.0,0.0,0.0,0.0);
    ex q1 = lst(1.0,0.0,0.0,0.0);
    ex q2 = lst(0.0,1.0,0.0,0.0);
    ex q3 = lst(0.0,0.0,1.0,0.0);
    ex q4 = lst(0.0,0.0,0.0,1.0);

    Simplex simplex4(lst(q0,q1,q2,q3,q4)); 

    ex coord4 = barycenter(simplex4); 
    cout <<"coord "<<coord4<<endl; 

}
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator