9 auto f = std::make_shared<SinOperator>(dim);
10 auto g = std::make_shared<ExpOperator>(dim);
12 auto graph = std::make_shared<WorkGraph>();
14 graph->AddNode(f,
"f");
15 graph->AddNode(g,
"g");
16 graph->AddEdge(
"f",0,
"g",0);
18 auto gof = graph->CreateModPiece(
"f");
20 Eigen::VectorXd x = Eigen::VectorXd::Random(dim);
21 std::cout <<
"exp(sin) = " << gof->Evaluate(x).at(0).transpose() << std::endl;