What does MBRContains and MBRWithin test? What does "contains" and "within" mean?
These are DE-91M (Wikipedia) terms, and they were standardized with Simple Features

but, Wikipedia probably covers it best, with two definitions,


  
  a contains b: geometry b lies in a, and the interiors intersect.
  a contains b iff no points of b lie in the exterior of a, and at least one point of the interior of b lies in the interior of a
  


The within relationship is the inverse of contains, with one catch "polygons do not contain their boundary." Other than that, within(a,b) = contains(b,a). Though interestingly, linestrings do contain all the points along the linestrings, except the terminal points.

For more information see the Wikipedia, 


https://en.wikipedia.org/wiki/DE-9IM