skeleton for BD tree simulator