C library for evaluating functions on an adaptive mesh