Software stack:Android is architected in the form of software stack, comprising applications, operating system, runtime, middleware, services and libraries.
Android OS is divided into 5 layers
Linux Kernel: Android is based on linux kernel. In this layer contains all lower device drivers for various hardware components of android device.Linux kernel provides level of abstraction between the device hardware and the upper layers of the android software stack.
Libraries provides all the code that provides main features of os.
Android runtime provides a set of core libraries. it also include DVM ( Dalvik Virtual Machine). The DVM was developed by Google, relies on underlying linux kernel for lower level functionality. It is more efficient then standard JVM in terms of memory usage. It is specifically designed to allow multiple instances to run efficiently within resource of a mobile.To execute within DVM, app code must be transfered from standard java class files to dex which has a smaller memory footprint than standard java byte code.Standard java class files can be converted to Dex format using dx tool included within Android SDK.
Provides various capabilities of android os to application developers to use in their applications.
At this top layer, we can download and install applications from the android market as well as third party markets.