The data of a query does not stay in the cache for a fixed time. Analysis Services has a cost based memory manager that gives memory to different processes like query calculation, session management, caching, and cube processing depending on available memory (which may increase or decrease over time depending on other processes on the server) and importance of these requests. "Cost based" in this context means that each type of memory usage has a cost (amount of RAM needed) and offers an income based on some parameters.
For cache warming, see e. g.