you are not part of the faithful and you are not welcome to become part of the faithful.
That's what I thought too Harry but apparently if you're excommunicated (which is extremely rare) you can still attend mass (though you can't take Communion) and you are encouraged to maintain a relationship with the Church. In the old days I would say that the threat of excommunication was used very cleverly to exploit the fear that Catholics had of dying without being in 'a state of Grace'. If you made a death bed repentance even without a priest present, you'd be ok but you might not get that chance. That's why Catholics even during my own childhood trotted off to Confession on a Saturday and then tried to behave themselves in case they died before their next Confession!
I'll tell you something interesting. It's not actually shown in the film 'Michael Collins' but when he was shot, one of his comrades Commandant Sean O'Connell knelt by him and asked him 'Mick do you repent your sins' and then recited the Act of Contrition on Collins' behalf. This is routinely done when a Catholic can't speak for themselves. He was holding Collins' hand as he did so and he claimed that he felt Collins squeeze his hand in response but he may simply have imagined it as it seems that Collins died almost instantly from a pretty massive head wound.
In other words make an official Act iof Apostasy.
In light of this discussion I did a quick bit of research last night and you're not allowed to do that anymore. It was abolished in October 2010. Here's the official statement given to journalists by the Catholic Church in Ireland, that was read out on RTE, the national TV channel:
The Holy See confirmed at the end of August that it was introducing changes to Canon Law and as a result it will no longer be possible to formally defect from the Catholic Church. This will not alter the fact that many people can defect from the Church, and continue to do so, albeit not through a formal process. This is a change that will affect the Church throughout the world. The Archdiocese of Dublin plans to maintain a register to note the expressed desire of those who wish to defect. Details will be communicated to those involved in the process when they are finalised. Last year 229 people formally defected from the Church through the Archdiocese of Dublin. 312 have done so, so far this year.Despite the instructions from the Vatican, Ireland continued to record defections for the next few years but I think they stopped in 2014. Anyway they no longer accept them, that's for sure.