If you have a new account but are having problems posting or verifying your account, please email us on [email protected] for help. Thanks :)
Hello All, This is just a friendly reminder to read the Forum Charter where you wish to post before posting in it. :)
Hi all, The AutoSave Draft feature is now disabled across the site. The decision to disable the feature was made via a poll last year. The delay in putting it in place was due to a bug/update issue. This should serve as a reminder to manually save your drafts if you wish to keep them. Thanks, The Boards Team.
Hello all! This is just a quick reminder to ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere.

Forecasting tomorrow's sunshine (to better use the solar)

  • 06-02-2022 12:03am
    Moderators, Science, Health & Environment Moderators Posts: 4,512 Mod ✭✭✭✭ Tree

    Does anyone have any reliable ways of figuring out if there'll be good solar on the following day?

    I'm used to reading the forecast for rain and wind, but when it comes to sun/cloud cover, I can't match it up at all to what ends up being generated on the day. I'm aiming to use the washing machine more on sunny mornings for example, and I set it up the night before, but half the time it's cloudy and there's not much solar energy and other times it's grand. It's probably going to be a non-issue come the summer, but while it's still early spring, I'd like to be able to plan my usage better.



  • Registered Users Posts: 3,546 ✭✭✭ graememk

    There's but that's generally API access, you'll have to do the work yourself. It also integrated with home assistant. have an API also that gives the hourly solar radiation value, it's more accurate but there's a lot more calculations needed to make it useful

  • Registered Users Posts: 1,393 ✭✭✭ THE ALM

    The I find fairly inaccurate, I run it is home assistant.

    Todays forecast production is 7.23kWh, I'm currently on 15.3kWh, yesterday forecast 6.38 and produced 2.8kWh.

    I think it is one of the most difficult things to allow for in Ireland as you could be 5 miles up the road and it be totally different.

  • Registered Users Posts: 3,546 ✭✭✭ graememk

    In the summer its fine, a good indication of good day/bad day

    But winter, is unfortunately highly variable.

  • Moderators, Science, Health & Environment Moderators Posts: 4,512 Mod ✭✭✭✭ Tree

    Ok, so it's a real problem, not one I invented for myself :)

    Sounds like is as good as met éireann (at least I'll know if it's raining or not, but no clue on sun/cloud).

  • Registered Users Posts: 1,830 ✭✭✭ bullit_dodger

    If you've got some coding skills, as graememk mentions above Met Eireann have an API which you can pass your long/lat and then they will return the forecast for the next 72 hrs, along with solar radiation levels (watts/m^2)

    Eg. (For dublin);long=-6.32     

    Then you can build something like.....

    Ok, it's not perfect. The reality is that while I think Met Eirean do a pretty decent job on the temperature, wind speed and direction, etc. It's hard to forecast sunlight where you have broken clouds. But if you want "something"'s not bad.

    I've been building a history of the forecasts and plan on cross referencing with the actuals to see what the correlation is. (have to do that once I get 6+ months of data)

  • Advertisement
  • Moderators, Science, Health & Environment Moderators Posts: 4,512 Mod ✭✭✭✭ Tree

    I have half a notion to see if I can plot the estimated alongside the actual for a few weeks, but it can take anything from 2 days to 5 years for me to get around to this sort of project

  • Registered Users Posts: 7 bumblebee22

    you could give try to solcast you can back feed the data for their algorithm to improve on forecast, i dont have pv installed yet to verify for solcast but i heard solcast is better.

    i did small php script with mysql database to record the data from let me know if you want to give it try.

  • Registered Users Posts: 1,393 ✭✭✭ THE ALM

    Solcast is available as an integration in Home Assistant also.

    I'm running Solcast and and will see how they compare. Solcast is limited to 50 calls a day through the free api.

  • Registered Users Posts: 7 bumblebee22

    i can but i can not see solcast in HA, is there a different name?

  • Registered Users Posts: 1,393 ✭✭✭ THE ALM

    If you add - - as a custom integration in hacs that will allow installation.

  • Advertisement
  • Registered Users Posts: 3,546 ✭✭✭ graememk

    Gonna try and have a crack at taking that hourly number and put it into a kwh

    I'll prob need someone to bounce ideas off. (or if someone can find a formula that would be great)

    what I am going to try and assume,

    say the value is 100w/m2 (easy counting) on a flat surface, so it already takes the angle of sun into account. eg if you had a panel on the ground flat that would be the power it would receive.

    then you have to take the efficiency of the panel which is 18-20%

    so 1m2 would generate 20wh/m2

    That would be a decent start, Would be able to that easily this evening.

    Then we need to take in the angle of the sun relative to the panels, (is there an api? /calculations) for the apparent area of the panel

    That would be a calculation for the angle of the sun in relation to the aspect and angle of the panels. (im at lunch and visualising it by rotating a place mat around.

    I wonder would digging into apparent area of an inclined plane will get me the calculation .

    the today was way off, going on was telling me it was gonna be a good one.

    So I planned accordingly.

    Once we get all that going, we could even take into account the temperature! (thats why may is so good, still relatively cold, long days....

    Any math or physics people about?

  • Registered Users Posts: 1,830 ✭✭✭ bullit_dodger

    I've actually got a degree in math, but I don't think we need to overly complicated it. Sort of a rough indicator is all that's needed and the data that Met Eireann dumps out is ok to be fair. To do it "right", you'd have to work out an hourly map of panel orientation as the sun tracks across the sky, relating that to the forecast for that specific hour, but it's not necessary I think.

    I pulled the historical forecast for 7am this morning from my app and it shows the following. I use that same Met Eireann API to get the raw data

    You can see that the sum of today's radiation is 3551. This is the highest so far this year btw. This number is sort of a "makie-uppie" number. It's the hourly values summed for the day. Compared that to tomorrow's of 1951 or Wed's'd expect Weds to only get 1/3 of the production of today.

    In reality from my experience, it doesn't quite work that way. The comparisons are good, but not perfect. The panels seem to have some inherent diffuse production capacity. Scattered light still gives some production. I know from comparing my own installation with Jonathan (he's north of Dublin, while i'm in Dublin16) so relatively close, on the dark dull days I'd have 1.5Kwhr while he'd have 0.3Kwhr on a similar sized array. So i have 500% the production he does. This only comes into play on the dark days though, when the sun is shining he (rightly) trounces my installation with his south facing panels, but it would appear that my panels/inverter handle "soft" light better than his. This for the most part is fine though as it's on crap days - which we don't really care about much anwyay

    I'll have a look over the next few days and see if I can easily decouple the inverter stuff that I have for me and then make this available for people.

  • Registered Users Posts: 177 ✭✭ connesha

    Yea, I don't think it needs to be too complicated, and the forecasts can be quite inaccurate.

    I've been tracking the daily radiation (from Met Eireann feed) vs generation for the past few days also, and it has been quite consistent, until today that is...(The weather forecast for today was quite a bit off here, so any calculation would have been off). Will be interested to see the rest of this week as the forecasts are for poor weather.

    Apart from today, its worked out within 1kwh of the simple formula: sum_of_days_radiation * kwp * 80%.

    My setup is 9.4kwp, East West, 20 deg pitch roof, North Co. Dublin.

    I imagine the 80% factor will vary across different months of the year as the sun is at a better angle for the low pitch, but that can be adjusted based on the average of the previous N days (I think you mentioned doing this in another thread also bullit_dodger).

    Its not clipping production at the 6kw inverter limit this time of the year yet, but when that happens it won't matter much - only want to know if the day will be good or not so can set/disable night-time charging.

    The intention is to run this a 1am each night. Get a rough forecast of solar production, and charge the batteries to a level to get through the day, or disable charging completely. I'm on the Bord Gais EV plan, so 2am to 5am is 5p per kwh

  • Moderators, Education Moderators, Home & Garden Moderators Posts: 7,606 Mod ✭✭✭✭ Jonathan

    Interested to hear how you get on with this @connesha. I'm also in Fingal and got caught out today with the weather. Was expecting another great day and it ended up being meh. Ended up with 8.9kWh but most of that went into the battery as I expecting a great day and purposely didn't charge the battery over night.

  • Moderators, Science, Health & Environment Moderators Posts: 4,512 Mod ✭✭✭✭ Tree

    So I've got Solcast and set up in Home Assistant, and they've been wildly different the last few days (by up to 15 kWh). I have the half hourly solcast plotted too.

    I can't for the life of me get the Met Eireann global radiation into home assistant (I've got a separate server serving a simplified forecast, but god forbid there's enough documentation on the home assistant side to use the REST sensor for forecast data), so I'm just going to start plotting it on a separate dashboard to keep an eye on.

  • Registered Users Posts: 2,631 ✭✭✭ yankinlk

    Thought i was smart filling battery at nigh rate based on forecast - wow couldnt have been more wrong. 5KW imported at night rate - and 6 Kw exported during the day.

    I think i might just go back to zero night import - too much hassle to save a few pennies IMHO

  • Registered Users Posts: 177 ✭✭ connesha

    Here are the calcs for the past few days @Jonathan, incl today.

    Granted, its' a very small data set. Unfortunately, I didnt keep the radiation levels for the previous days, so if anyone has them for (north) Dublin for the past couple of weeks, I can add them in and see if it still holds somewhat consistent.

    The "radiation" is updated in excel on the evening of the day before, so I know what to charge to that night.

    "est kwh" is the estimated generation, with the 80% factor.

    Given that yesterday was so far off, I'm now thinking of calcuating the factor as:

    Take the past 14 days "actual factor".

    Accept that there will be outliers, as weather forecsts in Ireland can be very inaccurate (especially this time of the year), so remove the highest one and the lowest one from the 14. Then take the average of the remaining 12.

    "avg minus outliers" is the average after the highest one and lowest one is removed.

    (I'm not sure of the mathematical soundness of this approach, but lets see how it works in practice...)

    For now, its in excel, and I manually execute a python script in the evening to set the inverter charge current for that night.  Over the next few days, time permitting, I'll move it to the NUC, put the data into a DB, and run as a cronjob before the 2am low unit rate kicks in.

    Initiating an Eddi boost between 2 and 5am is also interesting for the days with poor generation, but I havent looked at that much yet.

    I know a lot on here are integrating with Home Assistant, and maybe theres a more elegant way of running this than cronjob? I've just installed that a few days ago and have yet to get my head around it properly...

  • Registered Users Posts: 1,830 ✭✭✭ bullit_dodger

    What I was thinking of doing myself is taking a 10 point moving average of the radiation forecasts. For example, when it's Feb11th, you sum all the radiation forecasts from Feb 1st, 2nd, 3rd etc up to the 10th, and then average that. You then compare that against the 10point moving average for the "actuals" for the same period. then you can derrive an average radiation level -> average actuals amount. Divide that so that you have the value for 1,000 radiation points gives you.

    Naturally on Feb 12th, you now take Feb 2nd, 3rd, etc up until the 11th. So your window of the 10 points move to be the latest 10 days.

    Why 10? No reason, you could pick 20 too. I figured 10 is large enough so that it's relatively stable, but not too large that if you had a week of bad weather it would still respond when better sunshine came along. If you used 20 or 30, it could also be affected by a lag in the sun hitting the panels more as the year progresses and would take longer for it to respond to changes in production due to more sunlight hitting the panels.

    This way you get rid of the "actual factor" that you have in play as it "self-aligns" hopefully.

  • Registered Users Posts: 4 Seamus1234

    Your irradiance levels to generate power will be dictated by the angle and direction of your solar panels. Is it not easier to measure with a CT the power being returned to the grid and if this is above say 1.5kw switch on the washing machine?.

  • Registered Users Posts: 3,546 ✭✭✭ graememk

    Yeah thats the easy way.

    But a lot of this is for night time charging too, Come April it doesnt matter anyway!

    That and some of us just like the challenge :) NOAA have a spreadsheet that calculates the sun position...

    If you could pull the days irradiance first thing in the morning, Its most likely the accurate its going to get for the comparison calculation.

    And still the prediction will be always a prediction unfortunatley.

    Looking at tomorrow.. it aint good for me!


    I have done a calculation assuming flat panels, (mine are fairly flat anyway)

    Tomorrow is 6kwh,

    Next day is 22kwh. We shall see how that pans out. before i dig more into the NOAA spreadsheet... and working out apparent areas of rectangles at an angle.

    Post edited by graememk on

  • Advertisement
  • Registered Users Posts: 3,546 ✭✭✭ graememk


    I'm well down this rabbit hole,... but chatting to the mrs about what i'm trying to do... I think its not as complicated as it seems.

    I can replicate the NOAA spreadsheet in code, and test accordingly. so getting the elevation and azimuth isnt an issue.

    the area (or apparent area) was the stumbling block for me.

    And I'm keeping it simple as I can at the start, One axis, Panel is flat, Sun goes in a semi- circle around the panel.

    At 0 and 180 the area is the apparent area is 0,

    at 90 the apparent area is 100%

    and then at 45 and 135 apparent area is 50%

    Then if I work out the angle of the sun relative to the panels in the 2 axis, I should be able to work out the apparent area for that hour slot..

    With 2 axis's say at 45 for simplicity, the effective area would only be 25%.

    I think that is sound reasoning? best way to find out if your wrong is put it on the internet!

  • Registered Users Posts: 1,830 ✭✭✭ bullit_dodger

    I think your over complicating it though graememk and won't actually get much better accuracy for the work.

    You see the way I was planning it with a 10 point moving average of the forecasts, verses the actuals gained from those you've effectively already "built into" the model the whole area, angles and tracking. it's unnecessary to compute them because you've already got those incorporated inside the "actuals" that you inverter has given you for YOUR system. (if you follow me?)

    I guess it might help to put this in a little spreadsheet. :-)

    So "Column B" is the forecasted Met Eireann radiation levels summed for my location at 6am on the day in question (before sunrise basically)

    Column C, I create a 10 point moving average. Since I have to have 10 data points, that's why it only starts in March 1st as I'm adding up Feb 20+Feb21+Feb22 etc and the averaging them. This then "rolls forward" if you know what I mean, so I'm only summing the previous 10 days.

    Column D is obvious enough, the actual KwHr that the inverter reported for these days.

    Similar to "Column C" I create a 10 pt moving average for the actuals, this is column E

    Column F is the start of the brains, so I work out from the 10 pt moving averages how many Kwhr "1000" in solar radiation will give me.

    The final column is the computed forecast at 6am on the day in question. For example, on March 2nd at 6am, it computed that it would generate 3.18Kwhr. In reality (from the actuals column) it actually generated 3.98Kwhr. Not bad.

    March 5th is another one. Forecast 13.08Kwhr, actual generated 13.07Kwhr. Yeeosir! This is more like it, but I suspect a bit of a fluke! :)

    So tomorrow, it's forecasting (albeit 12 hrs earlier forecast than normal as I'm looking at this at 6pm on Wed 9th), but it's forecasting 15.38 Kwhr for me tomorrow. This would actually be close to the record for me which currently is at 15.93Kwhr. So I dunno if I'll get that, but I have a reasonable ballpark to go with. I know it's unlikely to be 5-6Kwhr, but probably in the 13-16Kwhr range. This is good enough I think to decide charging levels.

  • Registered Users Posts: 3,546 ✭✭✭ graememk

    Oh im way overcomplicating things I know that, but its more of the challenge.... the 10 point avg is working well though.

    Even my prediction today, assuming flat panels (mine are at 12 degrees i think, the roof is very walkable) was for 6kwh, and generated 7kwh. = 10kwh.

    For Tomorrow, Forecast has changed to 21.7kwh (going for a decimal now lol), Forecast.Solar is predicting 10.

    Do you calculate each string separately? or just the whole thing as a whole?

  • Registered Users Posts: 1,830 ✭✭✭ bullit_dodger

    I do have the "actuals" daily data for each string in a database, but no I wasn't forecasting for each one.....only the total installation as a whole. The problem (for me) is that I don't have even split. I've 1.5Kwp east and 3.8Kwp west, and while I could probably do the sums, the ROI on it wasn't worth it. It gets more complicated as you have to do the solar radiation for each hour (instead of the once for the day), and ultimately I don't think it would improve accuracy. There's a fair bit of energy captured by background diffused light for me, which I don't think I can easily account for. That is built into the daily "one shot" compute so I think I'll go that way. I've been collecting the Met Eireann xmls since last August for Dublin, so in another couple of months I'll have the full year.

    Ultimately the whole reason for me was to compute what my yield would be the next day so I could decide appropriately what to do. That would be setting the level of charge to put into the battery from night rate, or maybe I don't turn on the washing machine/tumble dryer and leave it for lunchtime the next day.

    I see that the forecast for tomorrow moved from 3413->3454 since earlier, so computing that in the 10 pt average that is estimating 15.56 Kwhr. Be interesting to see what I actually capture tomorrow at "close of business" - LOL

  • Registered Users Posts: 1,830 ✭✭✭ bullit_dodger

    Final forecast at 6am this morning = 3732. So computing that has raised the forecasted yield for my system to 16.82 Kwhr

    Interesting to see how close I'll be as this is actually above the all-time record for me (new installation < 6 months so this isn't unusual), but yeah, curious to see how the model works.

  • Registered Users Posts: 2,631 ✭✭✭ yankinlk

    there is a queue for laundry in my place trying to soak up the excess... at 11am!

  • Registered Users Posts: 177 ✭✭ connesha

    Could you share the MetEireann daily radiation data from Feb 22nd to now @bullit_dodger ? Thanks.

    That was my installation date, so am interested to see how consistent the predictions are from before I started gathering this data last week...

    Rough draft 1 of script to get forecast and update charge rate is just about ready, and hoping to have its first automatic run tonight... Looking forward to having this all done this automatically., besides me having to remember to open laptop, retrieve data and manually run a script every eve... here's hoping!

  • Registered Users Posts: 1,830 ✭✭✭ bullit_dodger

    Sure - although I only have it for Dublin. Specifically...;long=-6.32           

    Is that ok for you? If so, I'll dump them out to a ZIP file and place them into dropbox (or attach here)

    By the way, most computers have an "Auto-turn on" in the BIOS, so you could set the laptop to auto-turn on,.....wait a few minutes ....then in the startup folder run your script, and then have a scheduled task to run a few minutes later

    "shutdown -s"

    BOOM - done.

    Edit:- Actually, you just want the radiation levels. It's in the excel spreadsheet above.....

  • Registered Users Posts: 177 ✭✭ connesha

    Ah, so it is, I see it in spreadsheet above now. Perfect. You're close enough to me that it'll be accurate enough for my needs.

    Yea, I have a NUC running all the time anyways, so once the manual steps are taken out, it'll be a cronjob on that.


  • Advertisement
  • Moderators, Education Moderators, Home & Garden Moderators Posts: 7,606 Mod ✭✭✭✭ Jonathan

    Interested to know how did your respective algorithms work out today. underpredicted my generation by more than 10kWh. 12.77kWh predicted, ended up with 23.5kWh.