Detecting if the earth is causing any occult in the FOV

Hi Forum,

I am trying to simulate the number of GNSS spacecraft visible in the field of view of a GNSS antenna onboard an LEO spacecrft.

So I have a propagator configured with FieldOfViewDetector for every GNSS spacecraft. However, when I tried to simulate I noticed that, due to the attitude of the spacecraft, the FOV of the GNSS antenna can get occulted by the earth. How do I ensure I detect only the GNSS satellites which are in FOV and not occulted by the earth?

Thanks in advance!

Hi @gowtham

You can probably combine InterSatDirectViewDetector and FieldOfViewDetector using BooleanDetector.andCombine to get the behaviour you need.

Neat. Thank you @luc that’s exactly what I was looking for (somehow I missed it from the documentation).

I just got a follow-up question on this, since I am finding the number of GNSS spacecrafts visibile in the FOV and the event detector only talks about the entry and the exit, how do I find the spacecrafts visible at the start of the simulation?

You can directly call the g function of the detectors and check the signs.
For FieldOfViewDetector the function returns a negative value when the target is within the field of view. For InterSatDirectViewDetector the function returns a positive value when the satellites can see each other.

Thanks for the reply @luc. That’s very helpful.

Previously, I was iterating over the already found entry/exit events. As per your suggestion, I will iterate over time and check the g function values.