‘X zài Y lǐbian’ (X is inside Y) (e.g.: Qiú zài xiāngzi lǐbian.) (The ball is inside the box.): The compound position noun ‘Y lǐbian’ (Y inside) refers to the interior of the reference object. The phrase ‘X zài Y lǐbian’ states that the located object has the spatial relation of interiority with the reference object. Interiority implies inclusion or containment of the located object by the reference object. In principle, interiority may be either partial or total:
Bǐtǒng lǐbian chā zhe liǎng zhī bǐ.
(There are two pens inserted in the pen container.)
Xiāngzi lǐbian zhuāngmǎn le shū.
(The box was full of books.)
Xuésheng men zài jiàoshì lǐ (biān) shàngkè.
(The students were having a class in the classroom.)
In (1a), the located object ‘the pens’ are partially contained in the pen container, so they have some contact with the interior of the pen container. (1b) describes a situation where the located objects ‘books’ are totally contained in the reference object ‘the box’.
 Loar, J. K. (2011). Chinese syntactic grammar: functional and conceptual principles. New York: Peter Lang.