Creates elements and adds them to the repository if it exists.
 public void SetUp()
 {
     nodeFactory = new NodeFactory(ModelType.Truss1D);
     start = nodeFactory.Create(0);
     end = nodeFactory.Create(1);
     elementFactory = new ElementFactory(ModelType.Truss1D);
     SUT = elementFactory.CreateLinearConstantSpring(start, end, 2);
 }
 public void SetUp()
 {
     nodeFactory = new NodeFactory(ModelType.Truss1D);
     start = nodeFactory.Create(0);
     end = nodeFactory.Create(1);
     elementFactory = new ElementFactory(ModelType.Truss1D);
     material = new GenericElasticMaterial(0, 0.1, 0, 0);
     section = new SolidRectangle(0.1, 1);
     SUT = elementFactory.CreateLinearTruss(start, end, material, section);
 }
 public void SetUp()
 {
     ModelType modelType = ModelType.Beam1D;
     nodeFactory = new NodeFactory(modelType);
     start = nodeFactory.Create(0);
     end = nodeFactory.Create(1);
     elementFactory = new ElementFactory(modelType);
     material = new GenericElasticMaterial(0, 0.1, 0, 0);
     section = new SolidRectangle(0.1, 1);
     SUT = elementFactory.CreateLinear3DBeam(start, end, material, section);
 }
 public void Setup()
 {
     nodeFactory = new NodeFactory(ModelType.Truss2D);
     node1 = nodeFactory.CreateFor2DTruss(0, 0);
     node2 = nodeFactory.CreateFor2DTruss(0, 1);
     node3 = nodeFactory.CreateFor2DTruss(0, 2);
     SUT = new ElementRepository();
     elementFactory = new ElementFactory(ModelType.Truss2D, SUT);
     spring1 = elementFactory.CreateLinearConstantSpring(node1, node2, 1);
     spring2 = elementFactory.CreateLinearConstantSpring(node2, node3, 2);
 }
        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.SUT = elementFactory.CreateLinearConstantSpring(start, end, 1);
        }
        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.SUT = elementFactory.CreateLinearConstantSpring(this.start, this.end, 1);
        }