The farmer needs to grow 81 square kilometers of corn to make a profit. Since his field must be a square to hold that area, the length of each side of the square field must be the square root of 81, which is 9 kilometers. Therefore, the sides of the farmer's corn field are each 9 kilometers long.