void wavelet::inverse(const vector<double>& in, vector<double>& out, const int level) const { assert(weight(in.size()) == 1); // resize the output vector if necessary out.init(in.size()); // start at the smallest heirarchy and work towards the largest const int limit = getlimit(in.size(), level) << 1; for (int n = limit; n <= in.size(); n <<= 1) partial_inverse(in, out, n); }