The matlab code allows you to model the i-v and p-v charateristic of photovoltaic modules as a 3D look-up table that can be used in Matalb, Simulink or other software like PLECS. The model generated is according to the single-diode, 5 parameters equivalent circuit. The ideal application of this research would be to model the PV input source in power electronics applications, where a converter is interfaced to a PV module.