-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
139 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
[submodule "extern/pybind11"] | ||
path = extern/pybind11 | ||
url = ../../pybind/pybind11 | ||
branch = stable | ||
[submodule "extern/eigen"] | ||
path = extern/eigen | ||
url = ../../libigl/eigen | ||
branch = master |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
#include <iostream> | ||
// #include <fstream> | ||
// #include <vector> | ||
// #include <fstream> | ||
// #include <stdexcept> | ||
// #include <csignal> | ||
// | ||
// #include "tclap/CmdLine.h" | ||
// #include "TCLAP/IgnoreArg.h" | ||
// | ||
// #include "Main/wieldEnergy1D.h" | ||
// #include "Main/wieldEnergy2D.h" | ||
// #include "Main/wieldCSL.h" | ||
// #include "Main/wieldEnergyOffset.h" | ||
// #include "Main/wieldBlenderVoxelData.h" | ||
// #include "Main/wieldVisualizeOR.h" | ||
// #include "Main/wieldEnergySurfaceSphere.h" | ||
// #include "Main/wieldEnergyInterface1D.h" | ||
// #include "Main/wieldEnergyOR1D.h" | ||
// #include "Main/wieldFacet2D.h" | ||
// #include "Utils/wieldExceptions.h" | ||
// #include "Utils/wieldProgress.h" | ||
// | ||
|
||
#include "Reader/Reader.h" | ||
#include "Series/wieldGaussDirac.h" | ||
#include "Series/wieldFourierSeries.h" | ||
#include "Integrator/wieldSurface.h" | ||
|
||
#include "pybind11/pybind11.h" | ||
#include "pybind11/stl.h" | ||
#include "pybind11/eigen.h" | ||
|
||
double add(double i, double j) { | ||
return i + j; | ||
} | ||
|
||
|
||
double SurfaceGaussDirac(Wield::Series::FourierSeries<Wield::Series::GaussDirac> C1, | ||
Eigen::Matrix3d R1, | ||
Wield::Series::FourierSeries<Wield::Series::GaussDirac> C2, | ||
Eigen::Matrix3d R2, | ||
double epsilon, | ||
double tolerance) | ||
{ | ||
return Wield::Integrator::Surface(C1,R1,C2,R2,epsilon,tolerance); | ||
} | ||
|
||
//PYBIND11_MODULE(wield, m) { | ||
// m.doc() = "pybind11 example plugin"; // optional module docstring | ||
// | ||
// m.def("add", &add, "A function that adds two numbers"); | ||
//} | ||
|
||
//Wield::Integrator::Surface<Wield::Series::GaussDirac>; | ||
//int null() | ||
//{ | ||
// &createMatrixFromAngle; | ||
// Wield::Integrator::Surface<Wield::Series::GaussDirac>; | ||
//} | ||
|
||
PYBIND11_MODULE(wield,m) { | ||
|
||
pybind11::class_<Wield::Series::FourierSeries<Wield::Series::GaussDirac>>(m,"Crystal") | ||
.def(pybind11::init< | ||
const int, const double, const double, const double, | ||
const double, std::vector<double>, std::vector<double>,std::vector<double>, | ||
int, int >()); | ||
|
||
m.def("Surface",&SurfaceGaussDirac,"Surface integrate"); | ||
//m.def("Surface",&add,"Surface integrate"); | ||
m.def("createMatrixFromAngle",&createMatrixFromAngle,"Surface integrate"); | ||
|
||
} | ||
|
||
|