```---------- ---------- ---------- ---------- ---------- ---------- ---------- ----------
Let g(t) = log(1+t)/(1+t^2). We calculate the defined integral of g on [0,1]. Then we
look for the integral on [-1,0]. Let's see if we can even calculate the one between -1
and ∞.
We plot the graph of x -> ∫[0,x]g from -1 to ∞ (which we could have traced first, to
orient ourselves in the previous calculations).

g <- function(t) log(1+t)/(1+t^2)
integral(g, 0,1)
# [1] 0.2721983
# Try to see with WoframAlpha if it is an approximation of a simpler term:
# I introduce  0.2721983  and get  log(2)·π/8.   I control:
log(2)*pi/8
# [1] 0.2721983 OK

integral(g, -1,0)
# [1] -0.6437673

# To compute the integral between -1 and ∞, it is best to use the expression of the
# integral between successive powers of 10:
h = function(n) integral(g,10^n,10^(n+1))
integral(g, -1,1)
# [1] -0.3715691
integral(g, -1,1)+h(0)
# [1] 0.4823926
#  integral(g, -1,1)+h(0)+h(1)
# [1] 0.7604949
integral(g, -1,1)+h(0)+h(1)+h(2)+h(3)+h(4)+h(5)
# [1] 0.81658
integral(g, -1,1)+h(0)+h(1)+h(2)+h(3)+h(4)+h(5)+h(6)
# [1] 0.8165931
integral(g, -1,1)+h(0)+h(1)+h(2)+h(3)+h(4)+h(5)+h(6)+h(7)
# [1] 0.8165946
integral(g, -1,1)+h(0)+h(1)+h(2)+h(3)+h(4)+h(5)+h(6)+h(7)+h(8)
[1] 0.8165948
# With WolframAlpha I see that it equates to  log(2)·π·3/8

# Graph of 0∫xg
BF=4; HF=2.5
Plane(-1,20, 0,1.5)
Gintegra(g, 0,-1, "blue")
Gintegra(g, 0,20, "brown")

(In some analysis manuals as 0∫xg  log(1+x^2)·atn(x)/2 is determined; it coincides
with the exact expression only for x = 1: this testifies how useful it is to make
such calculations even with the help of the computer!)

```