TOTAL_IRRADIANCE

This function calculates the total irradiance incident on a tilted surface (Plane of Array, POA) by summing its component parts: beam, sky diffuse, and ground reflected irradiance.

It supports multiple sky diffuse models (e.g., Isotropic, Klucher, Hay-Davies, Perez) and allows specifying ground albedo or surface types.

Excel Usage

=TOTAL_IRRADIANCE(surface_tilt, surface_azimuth, solar_zenith, solar_azimuth, dni, ghi, dhi, dni_extra, airmass, albedo, surface_type, diffuse_model, perez_set)
  • surface_tilt (float, required): Panel tilt from horizontal (degrees).
  • surface_azimuth (float, required): Panel azimuth (degrees).
  • solar_zenith (float, required): Solar zenith angle (degrees).
  • solar_azimuth (float, required): Solar azimuth angle (degrees).
  • dni (float, required): Direct normal irradiance (W/m^2).
  • ghi (float, required): Global horizontal irradiance (W/m^2).
  • dhi (float, required): Diffuse horizontal irradiance (W/m^2).
  • dni_extra (float, optional, default: 0): Extraterrestrial direct normal irradiance (W/m^2).
  • airmass (float, optional, default: 0): Relative airmass (unitless).
  • albedo (float, optional, default: 0.25): Ground surface albedo (0 to 1).
  • surface_type (str, optional, default: ““): Surface type (e.g. ‘snow’, ‘grass’). Overrides albedo.
  • diffuse_model (str, optional, default: “isotropic”): Sky diffuse irradiance model.
  • perez_set (str, optional, default: “allsitescomposite1990”): Perez coefficient set (used only if model=‘perez’).

Returns (list[list]): 2D list [[poa_global, poa_direct, poa_diffuse, poa_sky_diffuse, poa_ground_diffuse]], or an error string.

Example 1: Isotropic POA components

Inputs:

surface_tilt surface_azimuth solar_zenith solar_azimuth dni ghi dhi albedo diffuse_model
30 180 40 180 800 800 100 0.2 isotropic

Excel formula:

=TOTAL_IRRADIANCE(30, 180, 40, 180, 800, 800, 100, 0.2, "isotropic")

Expected output:

Result
891.865 787.846 104.019 93.3013 10.718
Example 2: POA components with the Hay-Davies transposition model

Inputs:

surface_tilt surface_azimuth solar_zenith solar_azimuth dni ghi dhi dni_extra albedo diffuse_model
25 180 35 170 850 900 120 1330 0.25 haydavies

Excel formula:

=TOTAL_IRRADIANCE(25, 180, 35, 170, 850, 900, 120, 1330, 0.25, "haydavies")

Expected output:

Result
977.632 833.956 143.676 133.136 10.5404
Example 3: POA components with the Perez transposition model

Inputs:

surface_tilt surface_azimuth solar_zenith solar_azimuth dni ghi dhi dni_extra airmass albedo diffuse_model perez_set
35 180 50 190 700 780 140 1325 1.6 0.2 perez allsitescomposite1990

Excel formula:

=TOTAL_IRRADIANCE(35, 180, 50, 190, 700, 780, 140, 1325, 1.6, 0.2, "perez", "allsitescomposite1990")

Expected output:

Result
874.761 671.475 203.285 189.179 14.1061
Example 4: POA components using a snow surface override

Inputs:

surface_tilt surface_azimuth solar_zenith solar_azimuth dni ghi dhi surface_type diffuse_model
45 180 55 200 600 650 160 snow isotropic

Excel formula:

=TOTAL_IRRADIANCE(45, 180, 55, 200, 600, 650, 160, "snow", "isotropic")

Expected output:

Result
768.368 569.926 198.442 136.569 61.8737

Python Code

Show Code
from pvlib.irradiance import get_total_irradiance as result_func

def total_irradiance(surface_tilt, surface_azimuth, solar_zenith, solar_azimuth, dni, ghi, dhi, dni_extra=0, airmass=0, albedo=0.25, surface_type='', diffuse_model='isotropic', perez_set='allsitescomposite1990'):
    """
    Determine total in-plane irradiance and its beam, sky diffuse and ground reflected components.

    See: https://pvlib-python.readthedocs.io/en/stable/reference/generated/pvlib.irradiance.get_total_irradiance.html

    This example function is provided as-is without any representation of accuracy.

    Args:
        surface_tilt (float): Panel tilt from horizontal (degrees).
        surface_azimuth (float): Panel azimuth (degrees).
        solar_zenith (float): Solar zenith angle (degrees).
        solar_azimuth (float): Solar azimuth angle (degrees).
        dni (float): Direct normal irradiance (W/m^2).
        ghi (float): Global horizontal irradiance (W/m^2).
        dhi (float): Diffuse horizontal irradiance (W/m^2).
        dni_extra (float, optional): Extraterrestrial direct normal irradiance (W/m^2). Default is 0.
        airmass (float, optional): Relative airmass (unitless). Default is 0.
        albedo (float, optional): Ground surface albedo (0 to 1). Default is 0.25.
        surface_type (str, optional): Surface type (e.g. 'snow', 'grass'). Overrides albedo. Default is ''.
        diffuse_model (str, optional): Sky diffuse irradiance model. Valid options: Isotropic, Klucher, Hay-Davies, Reindl, King, Perez, Perez-Driesse. Default is 'isotropic'.
        perez_set (str, optional): Perez coefficient set (used only if model='perez'). Valid options: 1990 Composite, 1988 Composite, Sandia 1988, USA 1988, France 1988, Phoenix 1988, El Monte 1988, Osage 1988, Albuquerque 1988, Cape Canaveral 1988, Albany 1988. Default is 'allsitescomposite1990'.

    Returns:
        list[list]: 2D list [[poa_global, poa_direct, poa_diffuse, poa_sky_diffuse, poa_ground_diffuse]], or an error string.
    """
    try:
        tilt = float(surface_tilt)
        azim = float(surface_azimuth)
        zen = float(solar_zenith)
        s_azim = float(solar_azimuth)
        dn = float(dni)
        gh = float(ghi)
        dh = float(dhi)

        dn_e = float(dni_extra) if dni_extra not in [None, "", 0] else None
        am = float(airmass) if airmass not in [None, "", 0] else None
        alb = float(albedo) if albedo not in [None, ""] else 0.25
        st = str(surface_type).strip() if surface_type not in [None, ""] else ""
        if not st: st = None

        mod = str(diffuse_model) if diffuse_model is not None else 'isotropic'
        mod_p = str(perez_set) if perez_set is not None else 'allsitescomposite1990'

        res = result_func(
            surface_tilt=tilt,
            surface_azimuth=azim,
            solar_zenith=zen,
            solar_azimuth=s_azim,
            dni=dn,
            ghi=gh,
            dhi=dh,
            dni_extra=dn_e,
            airmass=am,
            albedo=alb,
            surface_type=st,
            model=mod,
            model_perez=mod_p
        )

        out = [
            float(res['poa_global']),
            float(res['poa_direct']),
            float(res['poa_diffuse']),
            float(res['poa_sky_diffuse']),
            float(res['poa_ground_diffuse'])
        ]
        return [out]
    except Exception as e:
        return f"Error: {str(e)}"

Online Calculator

Panel tilt from horizontal (degrees).
Panel azimuth (degrees).
Solar zenith angle (degrees).
Solar azimuth angle (degrees).
Direct normal irradiance (W/m^2).
Global horizontal irradiance (W/m^2).
Diffuse horizontal irradiance (W/m^2).
Extraterrestrial direct normal irradiance (W/m^2).
Relative airmass (unitless).
Ground surface albedo (0 to 1).
Surface type (e.g. 'snow', 'grass'). Overrides albedo.
Sky diffuse irradiance model.
Perez coefficient set (used only if model='perez').