Arcana Coelestia#7871
7871. 'And will strike all the firstborn in the land of Egypt' means the damnation of those governed by faith separated from charity. This is clear from the meaning of 'striking' as damnation, for striking is killing or putting to death, and 'death' in the spiritual sense means damnation, see 6119; from the meaning of 'the firstborn' - when used in reference to the Egyptians, who represent those steeped in falsities arising from evil - as faith separated from charity, 3325, 7039, 7766, 7778, 7779. In the genuine sense the expression 'the firstborn', when it describes a feature of the spiritual Church, means faith that is wedded to charity, see 367, 2435, 3325, 3494, 6344, 7035; therefore in the contrary sense 'the firstborn' is faith devoid of charity.
Arcana Coelestia#6651
6651. 'And a new king arose over Egypt' means separated factual knowledge, which is opposed to the Church's truths. This is clear from the representation of Pharaoh, to whom 'king' refers here, as factual knowledge in general, dealt with in 6015. The word 'king' is used because in the genuine sense 'king' means truth, 1672, 2015, 2069, 3670, 4581, 4966, 5044, 6148, and in the contrary sense falsity; and since 'king' refers here to Pharaoh, false factual knowledge is meant, that is, factual knowledge that is opposed to the Church's truths. This also explains why the expression 'new king' is used, for the one who lived in Joseph's time represented factual knowledge that accorded with the Church's truths. For the meaning of 'Egypt' as factual knowledge, here that knowledge in particular, see above in 6638.