I want to simulate longwave radiation on a building from the sky, the ground and also the urban environment. To do so, I need a View Factor matrix from those 3 fields.

I use the Visibility Percent function of LB to determine one matrix per face of my building per field, and then I will merge for each face the three matrix (ground, sky, environment) to have my global view factor matrix per face.

The problem is that I get wrong values (always 0%) while running the simulations, which is theoretically impossible. Is there an error in my meshes definitions ? maybe in the viewPoints part …? Is there another way to calculate the matrix ?

There’s no geometry in your file but I get the gist.

What you are trying to do here isn’t totally incorrect. However, it is an extremely roundabout way of doing it and it is not the most elegant way to compute sky exposure factor with LBT Ladybug. The more elegant way is to use the “LB View Percent” component to calculate sky view like so:

One point remains, as I want to vary the mesh on my faces, I deconstructed my box into 6 faces, but I think that the vectors on the vertical faces must be rotated from 90° right ? If yes, is there a parameter to set the face as vertical ?

You just need to use the spherical view vectors, plug the test geometry in as context (so that the view is blocked by the test geometry) and then multiply the output results by 2 to get the the fraction of the hemisphere that is unobstructed (rather than the fraction of the sphere).