8 poly(polyIn), polyOrder(-1)
14 poly(polyIn), polyOrder(polyOrderIn)
24 Eigen::VectorXd diag = Eigen::VectorXd::Zero(
polyOrder);
25 Eigen::VectorXd subdiag = Eigen::VectorXd::Zero(
polyOrder);
27 for (
unsigned int i=1; i<
polyOrder+1; i++) {
30 double alpha_i = -
poly->bk(i)/
poly->ak(i);
31 double beta_i = std::sqrt(
poly->ck(i+1)/(
poly->ak(i)*
poly->ak(i+1)));
38 subdiag(i-1) = beta_i;
42 Eigen::SelfAdjointEigenSolver<Eigen::MatrixXd> es;
43 es.computeFromTridiagonal(diag, subdiag);
46 pts = es.eigenvalues().transpose();
49 double mu0 =
poly->Normalization(0);
52 wts = mu0*es.eigenvectors().row(0).array().square();
virtual void Compute(unsigned int quadOrder) override
std::shared_ptr< OrthogonalPolynomial > poly
Base class for multivariate quadrature rules. @detail An abstract class for computing nodes and weigh...