Applications of ferroelectrics in photovoltaic devices