The basic idea is as follows:
Gross income 500
Less:
Pension premium (20) ==> if you pay these through your payslip
Income protection (30) ==> if you pay these through your payslip
'Reckonable income' 450
Tax due as follows
450 x 20% 90 ==> assumes you are only paying at 20%
Less:
Tax credit for period (100)
Tax deducted Nil ==> Non-refundable credit
In this example, no PAYE would be subtracted from your gross.
There are further calculations for PRSI which are quite complicated to explain. The above outlines how the PAYE only is calculated