Using the condition given, we have (m+n)2+(2018−m+n)2=20182. Let m+n=u, 2018−m+n=v. It can be seen that u,v>0. Since u2+v2=20182≡0(mod4), we get u≡v≡0(mod2). Let u=2u1, v=2v1. Then we have u12+v12=10092. Since (u1,v1,1009) is a Pythagorean Triple, we get 1009=d(r2+s2), (u1,v1)=(d(2rs),d(r2−s2)) or (u1,v1)=(d(r2−s2),d(2rs)) for some positive integers d,r,s. Since 1009 is a prime number, we obtain d=1 and r2+s2=1009. The last equation has solutions (r,s)=(28,15),(15,28). Hence all solutions are (u1,v1)=(840,559),(559,840) which correspond $(m,n) = (728,390), (1290,390).