Ferdinand II, King of the Two Sicilies, ruled Naples. For some time he had been under pressure to grant a constitution to his people. Riots by those wanting a constitution had broken out in 1837 but had been put down by the military. Further riots in 1847, and again early 1848, forced Ferdinand to offer a constitution on 29 January 1848. It based on the French model. However, disputes arose as to the nature of the oath that was required, and as uncertainty remained so riots continued. Battaglini became a student at the Astronomical Observatory of Capodimonte, on the hill of Naples, in 1850 but he resigned in order not to sign a petition to King Ferdinand II demanding that the King abolish the Constitution of 1848. He was prevented from obtaining a university post for political reasons until the unification of Italy and the end of the Kingdom of the Two Sicilies in 1860.
Politics was not the only obstacle to Battaglini. A school of classical geometry had been set up in Naples by Fergola and his pupil Flauti and it was so influential that it was able to prevent modern young geometers from obtaining posts. Battaglini, however, began to publish papers such as: Sugli assi principali (1850); Inscrivere in una superficie di 2 o grado un poligono in modo che i lati passino per punti dati (1851); Soluzione di un problema di geometria a tre coordinate. Descrivere una sfera in modo che intersechi quattro sfere ad angoli dati (1851); Sul problema di inscrivere in una curva di secondo grado un poligono in modo che i lati passino per punti dati (1851); Di alcune proprietà delle superficie di secondo grado che passano per una stessa curva o sono inviluppate da una stessa superficie sviluppabile (1853); and Sulla conica di minima area circoscritta ad un quadrangolo (1854).
Battaglini was named professor of higher geometry at the University of Naples in 1860. In fact this followed the beginning of a renewal of the university, which as we explained above had been in a poor state, following the return from exile of Francesco De Sanctis who was appointed as director general for education in 1860. In 1863, Battaglini was one of the three founders of the Giornale di matematiche, the others being Nicola Trudi (1811-1894) and Vincenzo Janni (1819-1891). Battaglini edited the journal, aimed at university students, which became the main outlet for papers in non-Euclidean geometry in Italy. Many articles by Battaglini appear in the journal from 1863 onwards, but his first memoir on non-Euclidean geometry Sulla geometria immaginaria di Lobachevsky was published in 1867. This was written to establish directly the principle which forms the foundation of the general theory of parallels and the trigonometry of Lobachevsky. He also translated Lobachevsky's Pangeometry and published it in the Giornale di matematiche in 1867 and Bolyai's Appendix which he published in the Giornale di matematiche in 1868. In  Salvatore Cicenia analyses:-
... the part G Battaglini, often mentioned only for the foundation of his 'Giornale di Matematiche', has had in the elaboration and in the divulgation of non-Euclidean geometry. By means of the study of his articles on hyperbolic geometry and of his unpublished specific correspondence with A Genocchi, we conclude by saying that the Neapolitan mathematician was interested not only in the technical development of non-Euclidean geometry but even in its foundational aspects and its philosophical implications. The Neapolitan Hegelism, which by its emphasis on the notion of 'a priori' was inevitably opposite to the anti-metaphysical foundation of Lobachevsky's geometry, was a resistance to the affirmation of the new geometry in the academic Parthenopean culture. On the contrary, the positivistic theory of knowledge was a theoretical reference nearer the principles of Lobachevskian geometry.Although Rome was a natural capital for the Kingdom of Italy, it remained under the control of the Pope after Italian unification in 1860. Only in 1870, after France stopped its support for the Papal States when the Franco-Prussian War began, did Italy capture Rome and it became the Italian capital in 1871. Immediately efforts were made to make the new capital a scientific centre of excellence and the top Italian mathematicians were offered positions there. Battaglini was one of these and, appointed by Giuseppe Garibaldi, he took up his chair in Rome in 1872. He remained in Rome until he retired in 1885, serving as Dean of the Faculty of Physical and Mathematical Sciences, and Rector in 1873-1874. During these years, he also taught at the Technical Institute in the city. In  Laura Martini explains how Battaglini indirectly contributed to the development of group theory while in Rome:-
At the University of Rome in the mid-1870s, Battaglini had two students who, during their careers, made important original contributions to group theory: Alfredo Capelli (1855-1910) and Giovanni Frattini (1852-1925). Battaglini, whose research focused mainly on geometric topics was, nevertheless, deeply interested in new developments in other mathematical disciplines, particularly algebra. Immediately after the publication of Camille Jordan's 'Traité des substitutions et des équations algébriques', Battaglini realized the importance of such a ground-breaking treatise. This appreciation is reflected in the Giornale di matematiche .... There Battaglini published a work on the theory of substitutions and Galois theory written by the young Vincenzo Janni (1871, 1872, 1873). This series of articles consists of a summary, with additions, of some of the chapters in Jordan's treatise as well as of parts drawn from Joseph Serret's 'Cours d'algèbre supérieure' and Peter Lejeune Dirichlet's 'Vorlesungen über Zahlentheorie'. Battaglini's interest in group theory also manifested itself in the course he gave on the theory of groups of substitutions at the University of Rome during the academic year 1875-1876. The audience included Alfredo Capelli. In fact, at the end of the introduction of his 1878 memoir "Sopra l'isomorfismo dei gruppi di sostituzioni" , the paper he extracted from his 1877 thesis written under Battaglini's supervision, Capelli credited his supervisor's lectures for his introduction to the subject.As well as Capelli and Frattini, the two students of Battaglini mentioned in this quote, we should also mention his students Enrico D'Ovidio (1842-1933), Riccardo De Paolis (1854-1892), Ettore Caporali (1855-1886), and Domenico Montesano (1863-1930) all of whom became well-known algebraic geometers. They all were appointed to chairs at leading Italian universities.
Battaglini retired for health reasons in 1885 and returned to Naples where he remained until his death. Retirement, however, did not mean that he stopped work and he continued to publish papers such as Intorno ad un'applicazione della teoria delle forme binarie quadratiche alla integrazione dell'equazione differenziale ellittica (1888), Sulle forme bilineari (1888), Sui punti sestatici di una curva qualunque (1888), Geometria analitica cartesiana (1891), and Intorno ad una serie di linee di secondo grado (1892). He also published the textbook Elementi di calcolo infinitesimal in 1889.
Some of Battaglini's results have proved significant. For example, in his doctoral dissertation of 1868, Klein introduced a classification scheme for second-degree line complexes based on Battaglini's earlier work. However, his main importance is his modern approach to mathematics which played a major role in invigorating the Italian university system, particularly in his efforts to bring the non-Euclidean geometry of Lobachevsky and Bolyai to the Italian speaking world. Jules Hoüel played a similar role for non-Euclidean geometry in the French speaking world and the correspondence between the two (see ) provides a vivid picture of the reactions of both the French and the Italian mathematical communities against the non-Euclidean geometries. Battaglini and Hoüel also exchanged ideas relating to mathematical education in various European countries. In particular they debated the use of Euclid's Elements as a textbook for teaching elementary geometry in schools.
In  Laura Martini describes Battaglini as a:-
... brilliant teacher and prolific scholar, with interests in basically all new branches of mathematics ...
Article by: J J O'Connor and E F Robertson