Fixed BM hydrostatic computation (wrong CoG coordinates)
This commit is contained in:
parent
a10ee753e2
commit
ec5fb278b0
|
@ -306,13 +306,13 @@ def BMT(ship, draft, trim=0.0):
|
||||||
B1 = displacement(ship,draft,roll,trim,0.0)[1]
|
B1 = displacement(ship,draft,roll,trim,0.0)[1]
|
||||||
# * M
|
# * M
|
||||||
# / \
|
# / \
|
||||||
# / \ BM ==|> BM = (BB/2) / tan(alpha/2)
|
# / \ BM ==|> BM = (BB/2) / sin(alpha/2)
|
||||||
# / \
|
# / \
|
||||||
# *-------*
|
# *-------*
|
||||||
# BB
|
# BB
|
||||||
BB = [B1.x - B0.x, B1.y - B0.y]
|
BB = [B1.y - B0.y, B1.z - B0.z]
|
||||||
BB = math.sqrt(BB[0]*BB[0] + BB[1]*BB[1])
|
BB = math.sqrt(BB[0]*BB[0] + BB[1]*BB[1])
|
||||||
BM = BM + 0.5*BB/math.tan(math.radians(0.5*roll)) / nRoll # nRoll is the weight function
|
BM = BM + 0.5*BB/math.sin(math.radians(0.5*roll)) / nRoll # nRoll is the weight function
|
||||||
return BM
|
return BM
|
||||||
|
|
||||||
def mainFrameCoeff(ship, draft):
|
def mainFrameCoeff(ship, draft):
|
||||||
|
|
Loading…
Reference in New Issue
Block a user