Using complex variable is the right suggestion. Thank you!