Equations involving trigonometric identities