def test_no_roughness(self): model = models.Power2018(Hs=4, Tp=11, beta=0.1) assert np.isnan(model.R2)
def test_list_input(self): model = models.Power2018(Hs=[1, 2], Lp=[100, 200], beta=[0.05, 0.1], r=[0.00075, 0.00075]) assert model.R2 == approx((0.922, 2.88), abs=0.1)
def test_dissipative(self): model = models.Power2018(Hs=4, Tp=11, beta=0.001, r=0.00075) assert model.R2 == approx(33.75, abs=0.01)
def test_low_wave_conditions(self): model = models.Power2018(Hs=1, Tp=8, beta=0.07, r=0.00075) assert model.R2 == approx(1.12, abs=0.01)
def test_reflective(self): model = models.Power2018(Hs=4, Tp=11, beta=0.1, r=0.00075) assert model.R2 == approx(4.79, abs=0.01)