import java.util.ArrayList;

public class MarkovSeries {
	protected Matrix a;
	protected Matrix x_0;
	
	protected Matrix x_n;
	private ArrayList<Matrix> x_i;
	
	
	public MarkovSeries(Matrix a, Matrix x_0) {
		this.a = a;
		this.x_0 = x_0;
		//Fix references and copy instead
		this.x_n = x_0;
		
		x_i = new ArrayList<Matrix>();
		x_i.add(this.x_0);
	}
	
	protected void iterate() {
		a.multR(x_n);
	}
}

Create MarkovSeries.java