vector ConstructTheta(double cr, vector& c) {
	vector theta(c.GetLength(),.0);

	for(int i = 0; i < c.GetLength(); i++)
		if(c(i) >= cr)
			theta(i) = 1.0;

	return theta;
}
matrix ConstructSequence(const vector& dt, const vector& x) {
	int Order = dt.GetLength();
	matrix Sequence(Order,1);
	
	for(int i = Order; i > 0; i--)
			Sequence[i-1] = ComputeRecursiveDerivative(i,i,i,dt,x,Sequence[i-1]);
	
	return Sequence;
}