 		const double* points, index_t points_nb,
 		const index_t* facets, index_t facets_nb,
 		index_t* points_nn, index_t k_p,
-		index_t* facets_nn, index_t dim
+		index_t* facets_nn, index_t k_f,
+		index_t  dim
 		) :
 		vertex_(vertex),
 		vertex_nb_(vertex_nb),

		mode_ = GLOBAL_MEMORY;
		allocate_and_copy(mode_);
		//might be improved dim3 type.
		int threads = 1024;
		int blocks = facet_nb_ / threads + ((facet_nb_ % threads) ? 1 : 0);
		switch (mode_)
		{
		case GLOBAL_MEMORY:
			kernel << < threads, blocks >> > (
				dev_vertex_, vertex_nb_,
				dev_points_, points_nb_,
				dev_facets_, facet_nb_,
				dev_points_nn_, k_,
				dev_facets_nn_, dimension_,
				dev_ret_
				);
			break;
		case CONSTANT_MEMORY:
			c_kernel << < threads, blocks >> >(

		double*			points, index_t			points_nb,
		index_t*		facets, index_t			facets_nb,
		index_t*		points_nn, index_t			k_p,
		index_t*		facets_nn, index_t			k_f,
		index_t			dim,
		double*			retdata
		){
		index_t fid = blockIdx.y * gridDim.x + blockIdx.x;
		index_t tid = threadIdx.x;
		if (fid >= facets_nb) return;

		if (fid < points_nb && tid == 0){
			g_seeds_information[tid * 4 + 0] = 0.0;
			g_seeds_information[tid * 4 + 1] = 0.0;
			g_seeds_information[tid * 4 + 2] = 0.0;
