@SuppressWarnings("unused")
	private Control closeToEdge(){
		double[] pose = this.plane.getPosition();
		double x = pose[0];
		double y = pose[1];
		double theta = pose[2];
		double desiredTheta = 0; //overwritten?
		boolean closeToEdge = false;

		if (x< 10){
			if (y < 10){
				desiredTheta = Math.PI/4;
			}
			else if (y > 90){
				desiredTheta = 7*Math.PI/4;
			}
			else{
				desiredTheta = 0;
			}
			closeToEdge = true;
		}
		else if (x > 90){
			if (y < 10){
				desiredTheta = 3*Math.PI/4;
			}
			else if(y > 90){
				desiredTheta = 5*Math.PI/4;
			}
			else{
				desiredTheta = Math.PI;
			}
			closeToEdge = true;
		}
		else if (y < 10){
			desiredTheta = Math.PI/2;
			closeToEdge = true;
		}
		else if (y > 90){
			desiredTheta = 3*Math.PI/2;
			closeToEdge = true;
		}

		if (closeToEdge){
			double linSpeed = 5*Math.random() + 5;
			double angGain = .3;
			double angError = (desiredTheta - theta)%(2*Math.PI);
			double rotVel = angGain*angError;
			return new Control(linSpeed, rotVel);
		}
		return null;
	}