Everybody is desperate to buy a phone with preferably more RAM. There were days when 256 MB of RAM was more than enough for a phone to work well. But, now even 1 GB can lag the hell out of any phone. Why is that? Well, the answer is simple. As time passed on, the apps developed and got bigger and bigger, they went on adding features and the size of applications got bigger.
It is known fact that when an application is requested to run, first it is transferred to the RAM and only then everything else takes place (because, RAM is fastest place in computation to access and dump the data required in operations). But what if the memory is not big enough? Then the memory takes in app's files in part by parts and load them as per requirement, but this transfer needs the time, this is when you experience the lags. Had the RAM been more in size, the required files would've already been loaded into the Memory and everything would run smoothly.
Well alright, now the question is how RAM helps in multitasking ?
To answer that, consider this scenario, you are running multiple applications at a time, when you switch between these apps the one which goes into the background enters into suspended mode. When in suspended mode, the app data has to be saved somewhere, because when you go back to app you don't want the app to be restarted from scratch. So, it stores all its data some place. If this place is phone internal storage, then you know when you return to this app it has to read the complete data from the storage and transfer itself to RAM before it becomes functional, this takes a lot of time, this is where you see the switching lags.
And there are also scenarios where you see apps being shutdown but not resumed. Yes, that happens when you have used up all the RAM and there is no more memory to store data, in that case OS chooses to remove that app from memory and execution line, completely shut it off to run current required apps with higher priority or recent use. And some are resumed but they take time to load. And also there is limit to use the hard disk space as storage for files from RAM.
Another question, can applications still lag even after having big enough RAM?
Yes, totally. It must be seen that those files in memory must be handled real well and done with right timing. So, if the processor isn't powerful enough and Memory management isn't well designed then the apps should lag.
So, what do we learn from this? We learn that memory size doesn't always matters, the bigger the better. But, it also should is understood that the excess memory that isn't handled well by CPU is just a waste. And also the Memory Management factor affects the performance very much.
Ok, Now the serious question ! Does keeping many apps running in RAM or MEMORY cause battery drain?
Well, to be specific, Yes and No.
How yes and how no? Well if you run applications that are active all the timing computing something and always connected to internet, keeping radios active. Then hell yeah, they gonna drain battery.
But if there are apps that aren't CPU hungry and doesn't utilize internet that much, then there is no or very little difference with battery usage.
And powering 100 MB RAM, 1.1 GB RAM or all the RAM module all cost the same amount of charge as rated by the manufacturer. So, it doesn't matter how much is used or free, it uses same power. It is all dependent on kind of apps it has in it.
What is this theory about Don't close apps for the sake of decreasing RAM usage, it will cause battery drain?
We know if apps are already in the RAM then there is no extra procedure to perform to put them in action. And also we learn't that apps don't drain battery if they are in RAM unless they keep working in background.
Now, it is to be understood that if we transfer files between RAM and storage there are some calculations to be done. This calculations cost CPU cycles, hence also charge of the battery. So, whenever you close an app and restart again, it is erased from memory and re-read into RAM. So, that costs charge. If you know that any app you are going to close is to be accessed soon again then better leave it in background. It will do no harm.
If you are worried that it will clog the memory space. Don't worry, as I said earlier, OS clears the app which have remained inactive for longer time and replaces it with current required ones.