Q. 1. When the Pope speaks on any matter, or preaches a homily, are his words infaillible?
A. 1. The answer to your question is "No." Many Catholics believe that every word that comes out of the Pope's mouth are infallible. Should he preach a homily on a subject, his homily is better than the other 400,000 priest who are preaching on the same subject. Such is an illusion. The Pope is human like you and I. What he expresses on a daily basis, those words are his personal opinion. And the opinion can be wrong.
The infallibility of the Pope in the Canon Law is defined as follows:
Can. 749 §1 In virtue of his office the Supreme Pontiff is infallible in his teaching when, as chief Shepherd and Teacher of all Christ’s faithful, with the duty of strengthening his brethren in the faith, he proclaims by definitive act a doctrine to be held concerning faith or morals.
§2 The College of Bishops also possesses infallibility in its teaching when the Bishops, gathered together in an Ecumenical Council and exercising their magisterium as teachers and judges of faith and morals, definitively declare for the universal Church a doctrine to be held concerning faith or morals; likewise, when the Bishops, dispersed throughout the world but maintaining the bond of union among themselves and with the successor of Peter, together with the same Roman Pontiff authentically teach matters of faith or morals, and are agreed that a particular teaching is definitively to be held.
§3 No doctrine is understood to be infallibly defined unless this is manifestly demonstrated.