equation inside java