private int find_index( int index, int target ){
	    // divide weight into three groups: Self, Son & Daughter, and test each

	    // Testing self
	    int sum = tree.elementAt(index).chance_weight;
	    if( target < sum )
	    {
	        return index; // found within self
	    } // else outside self, must be in children

	    // Testing son (first-born is always a son)
	    sum += tree.elementAt( 2*index+1 ).family_weight;
	    if( target < sum )
	    {
	        return find_index( 2*index+1, target - tree.elementAt(index).chance_weight );
	    } // else not in son's range

	    // Testing daughter
	    sum += tree.elementAt( 2*(index+1) ).family_weight;
	    if( target < sum )
	    {
	        return find_index( 2*(index+1),
	         target - tree.elementAt(index).chance_weight - tree.elementAt( 2*index+1 ).family_weight );
	    }

	    // possible to reach here if a custom random number generator is used,
	    // and it fails to deliver a number in the correct range
	    return 0;
	};