How to create a custom function to remove a contact record from a campaign?

How to create a custom function to remove a contact record from a campaign?

Hello, we are looking to create a custom function to can be called through a workflow rule to remove (dis-associate) a contact record from a campaign. Any help on how to do this would be appreciated.

Thanks.