S-matrices for perturbations of certain conformal field theories