//===================================================================//
void UpdateXMatrix(double *x){

	DoublyLinkedList<Point> *list = Picker.GetPoints();
	Node<Point> *currNode = list->getHead();
	int n = list->getSize();

	for(int i=0; i<n; i++){

		x[i] = currNode->data[X];
		currNode = currNode->next;

	}
}
//===================================================================//
double* GetYMatrix(void){

	DoublyLinkedList<Point> *list = Picker.GetPoints();
	Node<Point> *currNode = list->getHead();
	int n = list->getSize();

	double *y = new double[n];

	if(!y){
		printf("Insufficient memory for the Y allocation!\n");
		exit(0);
	}

	for(int i=0; i<n; i++){

		y[i] = currNode->data[Y];
		currNode = currNode->next;

	}

	return y;
}