calculateX