public void SetUp() { this.nodeFactory = new NodeFactory(ModelType.Truss1D); this.start = nodeFactory.Create(0); this.end = nodeFactory.Create(1); this.elementFactory = new ElementFactory(ModelType.Truss1D); this.spring = elementFactory.CreateLinearConstantSpring(start, end, 2); this.SUT = new LinearTrussStiffnessMatrixBuilder(spring); }
protected void CreateAndStore3DSpringFromOriginTo(double x, double y, double z) { nodeFactory = new NodeFactory(ModelType.Truss3D); start = nodeFactory.Create(0, 0, 0); end = nodeFactory.Create(x, y, z); elementFactory = new ElementFactory(ModelType.Truss3D); this.spring = elementFactory.CreateLinearConstantSpring(start, end, 1); this.SUT = new LinearTrussStiffnessMatrixBuilder(this.spring); }
protected void CreateAndStore2DSpringFromOriginTo(double x, double z) { this.nodeFactory = new NodeFactory(ModelType.Truss2D); this.start = nodeFactory.CreateFor2DTruss(0, 0); this.end = nodeFactory.CreateFor2DTruss(x, z); this.elementFactory = new ElementFactory(ModelType.Truss2D); this.spring = elementFactory.CreateLinearConstantSpring(this.start, this.end, 1); this.SUT = new LinearTrussStiffnessMatrixBuilder(this.spring); }
public void SetUp() { nodeFactory = new NodeFactory(ModelType.Frame2D); start = nodeFactory.CreateFor2DTruss(0, 0); end = nodeFactory.CreateFor2DTruss(1, 0); elementFactory = new ElementFactory(ModelType.Frame2D); material = new GenericElasticMaterial(0, 1, 0, 1); section = new GenericCrossSection(1, 1, 1, 1); beam = elementFactory.CreateLinear3DBeam(start, end, material, section); SUT = new Linear3DBernoulliBeamStiffnessMatrixBuilder(beam); }
public void CanCreateGlobalStiffnessMatrixForBeamAlignedToGlobalXAxisInReverseOrientation() { elementFactory = new ElementFactory(ModelType.Beam1D); beam = elementFactory.CreateLinear1DBeam(end, start, material, section); SUT = new Linear1DBernoulliBeamStiffnessMatrixBuilder(beam); StiffnessHelpers.Assert12x12StiffnessMatrix(SUT, 1, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 6, 0, 0, 0, -12, 0, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 4, 0, 0, 0, -6, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -12, 0, -6, 0, 0, 0, 12, 0, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 2, 0, 0, 0, -6, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); }