optimize change sign