Solution to special pythagorean triplet