add rule functions
add rule functions