Easy binary operations with php