Plactic Logic