what is a matrix android
Matrix is a class in Android framework that stores values which give information on how to transform an image, for example translate or scale. If you want to drag an image, you can display image as an ImageView, and calculate the difference between x and y coordinates of the first and last position of finger that is touching the ImageView. Then you create a new Matrix object and call a method postTranslate with those x and y values on it. Then you call setMatrix method on the ImageView and the image on screen will move. Take a look at https://github.com/MikeOrtiz/TouchImageView, a project where ImageView is extended to support drag and zoom.