Group law on the neutral component of the Jacobian of a real curve of genus 2 having many real components Torsion points on families of simple abelian surfaces and Pell's equation over polynomial rings (with an appendix by E. V. Flynn) 