Abstract : Let us denote by Q(N,[lambda]) the number of solutions of the diophantine equation $(A^2+B^2=C^2+C)$ satisfying N<=A<=B<=C<=[lambda]N-1/2. We prove that, for [lambda] fixed and N-->infinity, there exists a constant [alpha]([lambda]) such that Q(N,[lambda])=[alpha]([lambda])N+O_[lambda](N^7/8logN). When [lambda] =2, Q(2^n-1,2) counts the number of solutions of $(A^2+B^2=C^2+C)$ with the same number, n, of binary digits; these solutions are interesting in the problem of computing the function (a,b)-->[root](a^2+b^2) in radix-2 floating-point arithmetic. By elementary arguments, Q(N,[lambda]) can be expressed in terms of four sums of the type S(u,v;f)=[SIGMA]_(u<=d<=v) ([SIGMA]_(1<=[lambda]<=f(d)) 1) where u and v are real numbers and f: [u,v] -->R is a function. These sums are estimated by a classical, but deep, method of number theory, using Fourier analysis and Kloosterman sums. This method is effective, and, in the case [lambda]=2, a precise upper bound for |Q(N,[lambda])-[alpha]([lambda])N| is given.