optimized as default funtion