def putTruckAtOrigin(origin, longSlope, trsvSlope, truckLoadModel): bnd = ofrou664.CraneTruckLoadModel.getCenteredLoadBoundary() vDisp = (bnd.getMax(1) - 0.6) * longSlope vLoad = lmb.VehicleLoad( truckLoadModel, geom.Ref2d3d(origin - vDisp, -longSlope, trsvSlope)) putNodalLoads(vLoad) return vLoad
def getReferenceSystem(self, origin=None): ''' Return the member reference system. :param origin: member origin. ''' if (not origin): origin = self.memberOrigin return geom.Ref2d3d(origin, self.kVector, -self.jVector) # right-handed
def putTruckAt(position, longSlope, trsvSlope, truckLoadModel): vLoad = lmb.VehicleLoad(truckLoadModel, geom.Ref2d3d(position, longSlope, trsvSlope)) putNodalLoads(vLoad) return vLoad
# -*- coding: utf-8 -*- from __future__ import print_function import math import xc_base import geom p1 = geom.Pos3d(1, 1, 1) vI = geom.Vector3d(1, 1, 1) ref = geom.Ref2d3d(p1, vI) v = geom.Vector3d(1, 1, 1) vTrf = ref.getCooLocales(v) vTrfTeor = geom.Vector2d(math.sqrt(3.0), 0) ratio = (vTrf - vTrfTeor).getModulus() p0 = ref.getPosGlobal(geom.Pos2d(0.0, 0.0)) ratio2 = (p1 - p0).getModulus() p0 = geom.Pos3d(0, 0, 0) pA = geom.Pos3d(1, 0, 0) pB = geom.Pos3d(0, 1, 0) ref = geom.Ref2d3d(p0, pA, pB) ref.Org += geom.Vector3d(1, 1, 1) ratio3 = p1.distPos3d(ref.Org) ''' print("vTrf= ", vTrf) print("ratio= ", ratio) print("p0= ", p0) print("ratio2= ", ratio2) print(ref.Org) print("ratio3= ", ratio3) '''