RF:  extract scale_bem as separate function