Added function for equations with variable on both sides