When the main power is not available, an uninterruptible power supply (UPS) uses battery and inverter.