Fusion Materials used in a Fusion Summon are not a cost.
Monsters Tributed with a Ritual Spell Card for a Ritual Summon are not a cost.
Both of these are considered to be cards sent to the Graveyard by the resolution of the Spell Card's effect. So the sending/Tributing is carried out at resolution, not at activation.
This means that if the Ritual Spell Card or "Polymerization" in question is negated, or have their effects negated, you do not send the Fusion Materials or Tributed monsters to the Graveyard.
This is also why you can chain "Mask of Restrict" to the activation of a Ritual Spell Card, and prevent the Tributes from being Tributed, thus preventing the Ritual Summon from taking place, because "Mask of Restrict" resolves first, and then prevents the Tribute at resolution of the Ritual Spell Card, because the effect of "Mask of Restrict" is Continuous.