How To Write A Matrix Command