refining functions