This document presents a detailed model of a photovoltaic module in MATLAB that accounts for the effects of irradiance and temperature. The model uses a single diode model with both series and parallel resistors for accuracy. It determines the key parameters of short circuit current, saturation current, series resistance, and parallel resistance based on manufacturer data and physical equations. The model is then simulated step-by-step in MATLAB/Simulink to generate current-voltage and power-voltage curves under varying irradiance and temperature conditions.