From 37ddca4433d6de1a37df92995409e472d7bcc42f Mon Sep 17 00:00:00 2001 From: Stein Date: Mon, 17 Jun 2024 16:38:16 -0600 Subject: [PATCH] Wire Rope starting properties and parseYAML fix - System.parseYAML wasn't setting the mass vs. weight correctly for some reason, so I put in a fix for that - Wire rope properties are now added to MoorProps_default.yaml - - However, they're still missing cost properties, and drag and added mass properties --- moorpy/MoorProps_default.yaml | 7 ++++++- moorpy/system.py | 5 +++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/moorpy/MoorProps_default.yaml b/moorpy/MoorProps_default.yaml index dfa6a76..e0796ca 100644 --- a/moorpy/MoorProps_default.yaml +++ b/moorpy/MoorProps_default.yaml @@ -73,7 +73,12 @@ lineProps: Cd_ax : 0.741 # axial drag coefficient based on DNV-OS-E301 adjusted for use with volumetric diameter Ca : 1.0 # added mass coefficient based on Bureau Veritas 493-NR_2021-07 Ca_ax : 0.5 # axial added mass coefficient based on Bureau Veritas 493-NR_2021-07 - + + wire : # wire rope + mass_d2 : 5293 # linear mass density per diameter^2 [kg/m/m^2] + dvol_dnom : 1.18 # volume-equivalent diameter per nominal diameter [-] (assumes 4,875.5 kg/m^3 material density) + MBL_d2 : 1022e6 # minimum breaking load per diameter^2 [N/m^2] + EA_d2 : 97.1e9 # stiffness per diameter^2 [N/m^2] polyester : # polyester synthetic rope mass_d2 : 679 # linear mass density per diameter^2 [kg/m/m^2] diff --git a/moorpy/system.py b/moorpy/system.py index ed3b04b..7fb4a00 100644 --- a/moorpy/system.py +++ b/moorpy/system.py @@ -887,9 +887,10 @@ def parseYAML(self, data): for d in data['line_types']: name = d['name'] dia = float(d['diameter'] ) - w = float(d['mass_density'])*self.g + m = float(d['mass_density']) + w = (m - np.pi/4*dia**2 *self.rho)*self.g EA = float(d['stiffness'] ) - self.lineTypes[name] = dict(name=name, d_vol=dia, w=w, EA=EA) + self.lineTypes[name] = dict(name=name, d_vol=dia, m=m, w=w, EA=EA) addToDict(d, self.lineTypes[name], 'breaking_load' , 'MBL' , default=0) addToDict(d, self.lineTypes[name], 'cost' , 'cost', default=0)