It is an odd read because both lines end with Joesph, who was not the father of Jesus. So technically, neither line has anything to do with Jesus. But for legal purposes, this is what is recorded.
_______________________________________________________
As far as the different lines, this is not unusual. I have researched my family's genealogy for 20 years. I have found it interesting that I have lines back to an ancestor via different routes. Say my 12th great-grandfather has two sons. They both have lines that lead to my father. They are brothers, and both are my 11th great-grandfathers. The line splits but eventually, perhaps after many generations, comes back together, and great-great-grandchildren marry each other. So the lines will be different but come back together, and both lead back to the same 12th great-grandfather. It may not be what is happening with the Luke and Matthew lines... but it is not uncommon. It is also not that rare for 1st cousins to marry.
______________________________________________________
Some suggest that one line is that of Josepth while the other is of Mary. Yet both state they lead to Joseph.
Matthew 1:16 RV
16 and Jacob begat Joseph the husband of Mary, of whom was born Jesus, who is called Christ.
Luke 3:23 RV
23 And Jesus himself, when he began to teach, was about thirty years of age, being the son (as was supposed) of Joseph, the son of Heli,
__________________________________________________________
Others suggest that it was common to leave out individuals from the lineage. So I could say I am the son of Harry, who is actually my Great-Grandfather, not my father. We in fact see Jesus being called the "son of David." Leaving out many generations.
Matthew 21:9 RV
9 And the multitudes that went before him, and that followed, cried, saying, Hosanna to the son of David: Blessed is he that cometh in the name of the Lord; Hosanna in the highest.