Paul answers the question...why has national Israel gotten so far off track....
he had just explained the golden Chain of redemption in romans 8;29-39.....
Then he explains that although Israel as a nation was chosen to have believers in it, NOT EVERY SINGLE ISRAELITE of physical descent was in "the Israel of God"
Paul makes a distinction between physical descent[sperma]...and spiritual children of promise[teknon]
Not all israel was of Israel....
he demonstrates it by showing Individual election even down to twins in the womb......one loved, one hated.....not nations as spoken of in malachi, but individuals.....
God has mercy on who he will....
Even to individual gentiles who come in on equal footing.....replacing broken off branches[unbelieving, covenant breaking jews]...with elect gentiles.....same pattern he preaches in acts 13:
46 Then Paul and Barnabas waxed bold, and said, It was necessary that the word of God should first have been spoken to you: but seeing ye put it from you, and judge yourselves unworthy of everlasting life, lo, we turn to the Gentiles.
47 For so hath the Lord commanded us, saying, I have set thee to be a light of the Gentiles, that thou shouldest be for salvation unto the ends of the earth.
48 And when the Gentiles heard this, they were glad, and glorified the word of the Lord: and as many as were ordained to eternal life believed.