optimad / bitpit

Open source library for scientific HPC
http://optimad.github.io/bitpit/
GNU Lesser General Public License v3.0
117 stars 34 forks source link

discretization: add some fast paths for constant polynomials #363

Closed andrea-iob closed 1 year ago

andrea-iob commented 1 year ago

It is possible to optimize the evaluation of constant polynomials taking advantage of the fact that basis value is 1 and basis derivative is 0.

This kind of optimization was already done for the evaluation of the polynomial value and gradient. Let's extend it also for the update of the polynomials and for the evaluation of the weights.