From its source in the confluence of Madre de Dios and Mamoré rivers and downstream to Abuna river the Madeira flows northward forming border between Bolivia and Brazil. Below its confluence with the latter tributary the flow of river changes to north-eastward direction, inland of Rondônia state of Brazil. The section of the river from the border to Porto Velho has notable drop of bed and was not navigable. Before 2012 the falls of Teotônio and of San Antonio existed here, they had higher flow rate and bigger level drop than more famous Boyoma Falls in Africa. Currently these rapids are submerged by the reservoir of Santo Antônio Dam. Below Porto Velho the Madeira meanders north-eastward through the Rondônia and Amazonas states of north west Brazil to its junction with the Amazon.