[1][2] Born in Bologna to a well-off family, he graduated in medicine in 1678 with Marcello Malpighi at the University of Bologna, at the same time he studied mathematics with Geminiano Montanari and became a member of the Academia della Traccia o dei Filosofi.
In 1686 he was named "Bologna General Water Administrator", an important role due to the large number of watercourses existing in the area and the frequent flooding that required surveillance.
The experience gave inspiration for his well-known work "Della natura dei fiumi" which is considered a masterpiece of modern river hydraulics.
[4] He married Costanza Gioannetti and had three daughters and a son, Giuseppe Ferdinando, who became his biographer.
In 1698 he was invited by the prestigious University of Padua to teach mathematics, astronomy and medicine and to collaborate in the restoration of the fortifications of Kotor in Dalmatia (today Montenegro).