improved sin cos tan robustness

improved regexp of sin cos and tan to select complex equation