@Override
	public void execute(Shared shared, ComputeThread computeThread) {
		
		// Decompose further
		if (this.decompositionCounter > 0) {
			
//			System.out.println("Decomposing task..");
			UUID [] childIDs = new UUID[splitFactor];
			
			createChildrenTasks(childIDs);
			createSuccessorTask(childIDs);
		}
		
		// Task decomposed. Compute result.
		else {
			
			Result r = (Result)new MandelbrotSetResult(this.compute(), this.getTaskId());
//			System.out.println("Base case, computing...done");
			
			try {
				((Computer2Space)space).putPartialResult(r);
			} catch (RemoteException e) {
				System.err.println("Result could not be returned to its parent");
				e.printStackTrace();
			}
			catch (Exception e) {
				e.printStackTrace();
			}
		}
	}