## How to calculate azimuth and elevation angle?

RegGuheert
Posts: 6419
Joined: Mon Mar 19, 2012 4:12 am
Delivery Date: 16 Mar 2012
Leaf Number: 5926
Location: Northern VA

### How to calculate azimuth and elevation angle?

I'm stumped.

I'm helping a friend install a PV array on his workshop. He wants to mount the array on a 4:12-pitch roof which faces about 30 degrees north of West. In order to get the panels to face South, the intent is to mount the rails at *some* oblique angle to the roof and then use an elevation kit to raise the backs of the panels.

But I've come to the conclusion that as you raise the elevation of the panels relative to the roof, both the true azimuth and the elevation of the panels also change. So the question becomes: If I want the solar panels to face true south with a particular elevation, at would angle relative to the roof do I run the rails and at what elevation angle relative to the roof do I raise the panels?

I've tried to find an online calculator to provide the results, but I haven't found anything. Does anyone know of one? If not, is there a simple transformation that I can perform to calculate the true azimuth and elevation? TIA!
RegGuheert
2011 Leaf SL Demo vehicle
10K mi. on 041413; 20K mi. (55.7Ah) on 080714; 30K mi. (52.0Ah) on 123015; 40K mi. (49.8Ah) on 020817; 50K mi. (47.2Ah) on 120717; 60K mi. (43.66Ah) on 091918.
Enphase Inverter Measured MTBF: M190, M215, M250, S280

QueenBee
Posts: 1564
Joined: Sun Aug 08, 2010 5:14 pm
Delivery Date: 20 Jun 2011
Leaf Number: 2062
Location: Portland

### Re: How to calculate azimuth and elevation angle?

So if I understand correctly you are changing the angle of the panels and also running the rails NOT parallel to the building? That seems like some fun math.

So you know the buildings azimuth and you know that the rails are going to go up from the edge of the roof at X angle from parallel. So it seems like the geometry of this is that you need to create a triangle where the rail ends. The roof being one side, the other side being the height above the start of the rail at the roof and then the third side being how far into the building you are, level at the end of the rail. Then with that last number you can calculate the angle change when flat to give you the azimuth modifier.

As for the end result of the angle of the panels, I have no idea how to think about that.

RegGuheert
Posts: 6419
Joined: Mon Mar 19, 2012 4:12 am
Delivery Date: 16 Mar 2012
Leaf Number: 5926
Location: Northern VA

### Re: How to calculate azimuth and elevation angle?

Thanks, QueenBee!

Unfortunately, I'm having a bit of trouble with this part:
QueenBee wrote:Then with that last number you can calculate the angle change when flat to give you the azimuth modifier.
I don't think there can be a single number to modify the azimuth since I believe it changes continuously as you increase the tilt angle WRT the roof. For instance, the azimuth is always 30 degrees north of West when mounted flat, regardless of the angle chosen for the mounting rails.
RegGuheert
2011 Leaf SL Demo vehicle
10K mi. on 041413; 20K mi. (55.7Ah) on 080714; 30K mi. (52.0Ah) on 123015; 40K mi. (49.8Ah) on 020817; 50K mi. (47.2Ah) on 120717; 60K mi. (43.66Ah) on 091918.
Enphase Inverter Measured MTBF: M190, M215, M250, S280

QueenBee
Posts: 1564
Joined: Sun Aug 08, 2010 5:14 pm
Delivery Date: 20 Jun 2011
Leaf Number: 2062
Location: Portland

### Re: How to calculate azimuth and elevation angle?

RegGuheert wrote:Thanks, QueenBee!

Unfortunately, I'm having a bit of trouble with this part:
QueenBee wrote:Then with that last number you can calculate the angle change when flat to give you the azimuth modifier.
I don't think there can be a single number to modify the azimuth since I believe it changes continuously as you increase the tilt angle WRT the roof. For instance, the azimuth is always 30 degrees north of West when mounted flat, regardless of the angle chosen for the mounting rails.
Yeah yeah, agreed, the first part only gets you what the azimuth of the rails is then somehow gets modified by the additional angle which I have no idea how to even start thinking about. But as you said if the panels were installed flat to the roof but not parrallel the azimuth and angle are still the same as if they were parrallel.

wwhitney
Posts: 771
Joined: Sat Jul 17, 2010 10:10 am
Delivery Date: 01 Apr 2011
Location: Berkeley, CA

### Re: How to calculate azimuth and elevation angle?

RegGuheert wrote:I'm helping a friend install a PV array on his workshop. He wants to mount the array on a 4:12-pitch roof which faces about 30 degrees north of West. In order to get the panels to face South, the intent is to mount the rails at *some* oblique angle to the roof and then use an elevation kit to raise the backs of the panels.
OK, I'm going to work this out as I type, so bear with me.

I think the way to approach this is to use vector math on the vector orthogonal to the face of the panels. Vector length will be arbitrary, as we are only interested in direction.

So let's have the x-axis point east, the y-axis point north, and the z-axis point up.

If the 4:12 pitch roof faced due south, the orthogonal vector would be (0,-4,12) or (0,-1,3).

Since the building is turned 120 degree CCW from above, this become (-sin 120, -cos 120, 3) = (-sqrt(3)/2 , 0.5, 3)

Say you want the panels to face south at an elevation of 40 degrees. That vector would be (0,-sin 40, cos 40).

The cosine of the angle between the vectors is their dot product divided by their lengths. The angle is

arccos((0 + cos120 sin40 + 3 cos 40)/sqrt(10)) = arccos(0.625) = 51 degrees.

So you would need to an elevation kit that would rotate your panels 51 degrees, not sure if that is practical. We still need to find what direction to run the rails.

The rails would need to run perpendicular to both the pre and post rotation orthogonal vectors, i.e. perpendicular to both (-sin120, -cos120, 3) and (0, -sin 40, cos 40). That would be in the direction of their cross product. So the direction is given by

(-cos 120 * cos 40 - 3 * (-sin 40), 3 * 0 - (-sin 120) * cos 40, -sin 120* (-sin 40) - (-cos 120) * 0) = (2.31, 0.766, 0.557)

If the rails ran horizontally across the roof, their direction would be (cos 120, -sin 120, 0). So the angle between this and the desired rail direction is

arccos( (2.31 * cos 120 - 0.766 * sin 120 + 0) / sqrt (2.31^2 + 0.766^2 + .557^2) ) = 137 degrees.

Since the rail directions are only defined upto +-1, this is really 180 - 137 = 43 degrees. I haven't calculated whether that's CW or CCW, but from the roof it should be obvious which way to go.

The upshot is that for the inputs of a 1:3 slope, 120 degrees off south, and a desired south elevation of 40 degrees, you need to rotate the rails 43 degrees from the horizontal on the roof, and you need to elevate the panels 51 degrees relative to the roof. If I didn't make any calculation errors.

You could easily check this with a very small model. For other values of the inputs, repeat the calculation above substituting the new inputs.

If you have more than one row of panels, you will have to figure out how far apart to space the rows to avoid shading.

Cheers, Wayne

RegGuheert
Posts: 6419
Joined: Mon Mar 19, 2012 4:12 am
Delivery Date: 16 Mar 2012
Leaf Number: 5926
Location: Northern VA

### Re: How to calculate azimuth and elevation angle?

wwhitney wrote:
RegGuheert wrote:I'm helping a friend install a PV array on his workshop. He wants to mount the array on a 4:12-pitch roof which faces about 30 degrees north of West. In order to get the panels to face South, the intent is to mount the rails at *some* oblique angle to the roof and then use an elevation kit to raise the backs of the panels.
OK, I'm going to work this out as I type, so bear with me.

I think the way to approach this is to use vector math on the vector orthogonal to the face of the panels. Vector length will be arbitrary, as we are only interested in direction.

So let's have the x-axis point east, the y-axis point north, and the z-axis point up.

If the 4:12 pitch roof faced due south, the orthogonal vector would be (0,-4,12) or (0,-1,3).

Since the building is turned 120 degree CCW from above, this become (-sin 120, -cos 120, 3) = (-sqrt(3)/2 , 0.5, 3)

Say you want the panels to face south at an elevation of 40 degrees. That vector would be (0,-sin 40, cos 40).

The cosine of the angle between the vectors is their dot product divided by their lengths. The angle is

arccos((0 + cos120 sin40 + 3 cos 40)/sqrt(10)) = arccos(0.625) = 51 degrees.

So you would need to an elevation kit that would rotate your panels 51 degrees, not sure if that is practical. We still need to find what direction to run the rails.

The rails would need to run perpendicular to both the pre and post rotation orthogonal vectors, i.e. perpendicular to both (-sin120, -cos120, 3) and (0, -sin 40, cos 40). That would be in the direction of their cross product. So the direction is given by

(-cos 120 * cos 40 - 3 * (-sin 40), 3 * 0 - (-sin 120) * cos 40, -sin 120* (-sin 40) - (-cos 120) * 0) = (2.31, 0.766, 0.557)

If the rails ran horizontally across the roof, their direction would be (cos 120, -sin 120, 0). So the angle between this and the desired rail direction is

arccos( (2.31 * cos 120 - 0.766 * sin 120 + 0) / sqrt (2.31^2 + 0.766^2 + .557^2) ) = 137 degrees.

Since the rail directions are only defined upto +-1, this is really 180 - 137 = 43 degrees. I haven't calculated whether that's CW or CCW, but from the roof it should be obvious which way to go.

The upshot is that for the inputs of a 1:3 slope, 120 degrees off south, and a desired south elevation of 40 degrees, you need to rotate the rails 43 degrees from the horizontal on the roof, and you need to elevate the panels 51 degrees relative to the roof. If I didn't make any calculation errors.

You could easily check this with a very small model. For other values of the inputs, repeat the calculation above substituting the new inputs.

If you have more than one row of panels, you will have to figure out how far apart to space the rows to avoid shading.

Cheers, Wayne
Thanks, Wayne! I'm impressed!

That's exactly what I'm looking for! Right now we have a fixed-tilt kit (and I'm not sure of the exact tilt, since I believe it depends on the distance between the rails), so let me see how much South-pointing elevation we can achieve and which way the rails need to run. I'll post back once I figure out how that all works out. Perhaps a simple computer program is in order!
RegGuheert
2011 Leaf SL Demo vehicle
10K mi. on 041413; 20K mi. (55.7Ah) on 080714; 30K mi. (52.0Ah) on 123015; 40K mi. (49.8Ah) on 020817; 50K mi. (47.2Ah) on 120717; 60K mi. (43.66Ah) on 091918.
Enphase Inverter Measured MTBF: M190, M215, M250, S280

QueenBee
Posts: 1564
Joined: Sun Aug 08, 2010 5:14 pm
Delivery Date: 20 Jun 2011
Leaf Number: 2062
Location: Portland

### Re: How to calculate azimuth and elevation angle?

RegGuheert wrote:
wwhitney wrote: (-cos 120 * cos 40 - 3 * (-sin 40), 3 * 0 - (-sin 120) * cos 40, -sin 120* (-sin 40) - (-cos 120) * 0) = (2.31, 0.766, 0.557)

If the rails ran horizontally across the roof, their direction would be (cos 120, -sin 120, 0). So the angle between this and the desired rail direction is

arccos( (2.31 * cos 120 - 0.766 * sin 120 + 0) / sqrt (2.31^2 + 0.766^2 + .557^2) ) = 137 degrees.

Since the rail directions are only defined upto +-1, this is really 180 - 137 = 43 degrees. I haven't calculated whether that's CW or CCW, but from the roof it should be obvious which way to go.
Thanks, Wayne! I'm impressed!

That's exactly what I'm looking for! Right now we have a fixed-tilt kit (and I'm not sure of the exact tilt, since I believe it depends on the distance between the rails), so let me see how much South-pointing elevation we can achieve and which way the rails need to run. I'll post back once I figure out how that all works out. Perhaps a simple computer program is in order!
And that's why I'm in IT instead of computer engineering/science. I'm thoroughly impressed.

RegGuheert
Posts: 6419
Joined: Mon Mar 19, 2012 4:12 am
Delivery Date: 16 Mar 2012
Leaf Number: 5926
Location: Northern VA

### Re: How to calculate azimuth and elevation angle?

O.K. It looks like we will be installing these panels on Friday so I need to finalize my calculations pretty soon. Since this system will be used in an off-grid application, I want to get the tilt as steep as possible. My goal is 50 degrees (actual elevation), but I may need to settle for a lower angle if that is unachievable with the tilt kit which was purchased.

That kit does not appear to be a true 4-bar linkage, but rather the two different-length legs appear to be perpendicular to the PV module when mounted. That means my only degree of freedom when it comes to angle is how close together I mount the rails and therefore how much of the PV module is cantilevered above the top connection point.

So, that brings me to my two questions:

Q1) What is the maximum amount of PV panel which you would allow to cantilever above the top rail? For reference, here is a datasheet for the modules which we are mounting: LG265S1C-B3. Unlike panels which I have used before, these panels are thin and light. Thickness is only 1.38".

Q2) What is the minimum spacing you would allow between the two rails when mounting PV modules which will have an elevation angle of about 50 degrees from horizontal?

Since it may impact wind loading slightly, I will point out that there are quite a few deciduous trees around the building where we are mounting the panels.

Thanks in advance for any thoughts!
RegGuheert
2011 Leaf SL Demo vehicle
10K mi. on 041413; 20K mi. (55.7Ah) on 080714; 30K mi. (52.0Ah) on 123015; 40K mi. (49.8Ah) on 020817; 50K mi. (47.2Ah) on 120717; 60K mi. (43.66Ah) on 091918.
Enphase Inverter Measured MTBF: M190, M215, M250, S280

QueenBee
Posts: 1564
Joined: Sun Aug 08, 2010 5:14 pm
Delivery Date: 20 Jun 2011
Leaf Number: 2062
Location: Portland

### Re: How to calculate azimuth and elevation angle?

RegGuheert wrote: Since this system will be used in an off-grid application, I want to get the tilt as steep as possible.
I was going to ask you why you were going through so much trouble to do this goofy looking install but that definitely makes sense.
RegGuheert wrote:
Q1) What is the maximum amount of PV panel which you would allow to cantilever above the top rail? For reference, here is a datasheet for the modules which we are mounting: LG265S1C-B3. Unlike panels which I have used before, these panels are thin and light. Thickness is only 1.38".

Q2) What is the minimum spacing you would allow between the two rails when mounting PV modules which will have an elevation angle of about 50 degrees from horizontal?
I've always tried to follow the manufacturer's guidelines on where to install the rails. For example looking in the install manual they show either using the predrilled bolt holes or with clamps a range that starts at 270mm and ends at 400 mm from the top/bottom. Page 8 of the install manual.

wwhitney
Posts: 771
Joined: Sat Jul 17, 2010 10:10 am
Delivery Date: 01 Apr 2011
Location: Berkeley, CA

### Re: How to calculate azimuth and elevation angle?

RegGuheert wrote:He wants to mount the array on a 4:12-pitch roof which faces about 30 degrees north of West.
I take it either this is a shed roof, so there is no other side, or there is some other reason not to use the other side of the roof, that faces 30 degrees south of East?

How big is the roof, and how many panels are you putting up?
RegGuheert wrote:My goal is 50 degrees (actual elevation), but I may need to settle for a lower angle if that is unachievable with the tilt kit which was purchased.
The web info you linked to doesn't give the length of the long leg and the short leg. Do you have that info?
RegGuheert wrote: Q1) What is the maximum amount of PV panel which you would allow to cantilever above the top rail?
The tilt kit manual says to limit the cantilever to a maximum of 15% of the panel length. Without knowing anything else or doing a wind load calculation, I would think that would be OK. Your panels are 65 inches long, so that would be 9.75 inches.

Cheers, Wayne