Solar radiation hitting different parts of earth's surface at specific time

Hi,

I want to calculate how much solar radiation is hitting different parts of earth’s surface at a specific time.

I imagine a function that takes a datetime and returns a 361x181 matrix (where the array indices can be easily converted to WGS84 coordinates).

Can you point me to libraries that provide the required functionalities?

(There seem to be libraries that calculate the position of the sun for a specific latitude and longitude, but it seems inefficient to do this for every coordinate.)

What are you going to use this data for? How to go about approximating this well depends on the usage.

I want to calculate how much solar radiation is hitting different parts of earth’s surface at a specific time.

You basically can’t. Cloud cover and other local conditions determine the bulk of this. The best you can do over the entire globe is calculate the maximum solar radiation.

For certain areas, there may be government or other databases of historical measurements. E.g. the NREL has the National Solar Radiation DB which covers much of North America. You could then back this out into a statistical model for each location by time-of-year to try to get predictions in the future, or before the data was taken.

but it seems inefficient to do this for every coordinate.

If you actually need all those points, it’s not going to be significantly more inefficient than any other approach. There’s not that much that is shared in the calculation for different locations.

returns a 361x181 matrix (where the array indices can be easily converted to WGS84 coordinates).

This isn’t a great approach for most purposes though. One degree longitude is 1.2 miles at 89 degrees, and about 70 miles near the equator. This equal spacing in degrees vastly oversamples the poles relative to the rest of the ellipsoid. It may be perfect for a graphical rendering engine that demands a sphere texture in this format, but for everything else there’s probably a better way to do it.

1 Like

Hi Aaron,

What are you going to use this data for? How to go about approximating this well depends on the usage.

Long answer

I am trying to get an overview of how the world works.

For that I want to write a game that simulates the world.

It roughly consists of these parts:

  1. A grid for every aspect of the world I think is important (e.g. elevation, water percentage, …, temperature, wind speed, …, population, body mass index, …)
  2. Systems that calculate these aspects based on a given time and other aspects they depend on.
  3. A UI that displays a visualization of the world and allows changing the visualized aspects and the time.
  4. A renderer that creates the visualizations and streams them to the UI.

More concretely:

  • I imagine having a list of aspects on the left side of the screen that I can chose from.
  • The selected aspect is visualized similar to a heatmap.
  • There can be different implementations of systems.
  • System implementations can be swapped instantaneously.

The overall ideas:

  • What is not tested does not work.
  • Building stuff to find knowledge gaps.
  • Easily making experiments leads to fast learning.

Short answer

You basically can’t. Cloud cover and other local conditions determine the bulk of this. The best you can do over the entire globe is calculate the maximum solar radiation.

To calculate the clouds I first need to know how much radiation hits earth.

For my use case at first there is no atmosphere.

This isn’t a great approach for most purposes though. One degree longitude is 1.2 miles at 89 degrees, and about 70 miles near the equator. This equal spacing in degrees vastly oversamples the poles relative to the rest of the ellipsoid. It may be perfect for a graphical rendering engine that demands a sphere texture in this format, but for everything else there’s probably a better way to do it.

Do you know a better way for this case?

A somewhat standard approach is to do a recursive triangular mesh starting from a regular octahedron, and projecting the vectors out to the sphere surface. There’s fast tests for neighbors at whatever resolution you decide to go down to, and pretty easy ways to turn centers to spherical coördinates and spherical coördinates to the triangle they would fall in.

Really?

you could implement the functions described here:

there is also the technical report on how to calculate solar radiation, aimed at solar panels: