 		int dim_cholfact = dim_theta * dim_theta - ((dim_theta - 1) * dim_theta) / 2;
 		cholfact.resize(dim_cholfact);
 
+		int ndata = Daug.GetNdata();
+		h_logdens.resize(ndata);
+		d_logdens = h_logdens;
+
 		decay_rate = 2.0 / 3.0;
 
 		// place array size constant memory

class Characteristic {
public:
	// constructor
	__device__ __host__ Characteristic(curandState& localState, int iter) : state(localState), current_iter(iter);
	__device__ __host__ virtual ~Characteristic() {}

	// compute the conditional log-posterior density of the measurements given the characteristic

	}

	// adapt the covariance matrix (i.e., the cholesky factors) of the theta proposals
	virtual void AdaptProp(double metro_ratio)
	{
		double unit_norm = 0.0;
	    for (int j=0; j<dim_theta; j++) {
