瀏覽代碼

Update cheb_eval(...)

Dhairya Malhotra 10 年之前
父節點
當前提交
4db5f8a3e0
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      include/cheb_utils.txx

+ 1 - 0
include/cheb_utils.txx

@@ -508,6 +508,7 @@ void cheb_eval(const Vector<T>& coeff_, int cheb_deg, const std::vector<T>& in_x
  */
 template <class T>
 inline void cheb_eval(Vector<T>& coeff_, int cheb_deg, std::vector<T>& coord, Vector<T>& out){
+  if(!coord.size()) return;
   int dim=3;
   int d=cheb_deg+1;
   int n=coord.size()/dim;