implemented generate children