Skip to main content
. 2023 Jun 10;23(12):5480. doi: 10.3390/s23125480
Algorithm 2. Algorithm to determine the occurrence of data reception between the static nodes and the antenna.
Data:
Hs significant wave height
Tp peak period
htwr terrestrial antenna height
ha node antenna height
d distance between antenna and node
Nrp number of random realizations
begin
Generate wave number ki for each frequency component ωi set ki:=ω i2g; Na :=0; Nf:=number of frequency components
  while Na<Nrp do
   for t=0:Δt:T
    μi:=2·Sηωi·Δω
    ai:=raylrndμi
    αi:=rand1,Nf·2·π
    η0,t=i=1Nfaicosωi+kix+αi
    ηxn,t=i=1Nfaicosωi+kixn+αi
Find the blocker at the current time instance
    for xn=1:d do
     if htwrη0,t+had>htwrηxn,tdxn then
  The distance and height of the blocker landing are saved to be subtracted from the component number.
     end if
    end for
   end for
  Na:=Na+1
  Regenerate a set of realizations of ai and αi random
  end while
end