The expansion of the Spanish railway network (1848–1941): an analysis through the evolution of its companyies