/// <summary> /// Class constructor. /// </summary> /// <param name="geometricProperty"></param> /// <param name="mappingResolver"></param> /// <param name="mainMatrix"></param> /// <param name="profileValidator"></param> /// <param name="time"></param> /// <param name="naturalFrequency"></param> public CalculateRectangularBeamVibration( IRectangularGeometricProperty geometricProperty, IMappingResolver mappingResolver, IRectangularBeamMainMatrix mainMatrix, IRectangularProfileValidator profileValidator, ITime time, INaturalFrequency naturalFrequency) : base(geometricProperty, mappingResolver, mainMatrix, profileValidator, time, naturalFrequency) { }
public CalculateRectangularBeamWithPiezoelectricVibrationTest() { this._precision = 1e-16; this._beamProfile = new RectangularProfile { Height = 3e-3, Width = 25e-3 }; this._piezoelectricProfile = new RectangularProfile { Height = 0.267e-3, Width = 25e-3 }; this._numberOfPiezoelectricsPerElement = 2; // Area and Moment of Inertia to piezoelectric were calculate manualy. this._piezoelectricArea = this._numberOfPiezoelectricsPerElement * 6.675E-6; this._piezoelectricMomentOfInertia = 3.5701411E-11; this._arrayOperation = new ArrayOperation(); this._auxiliarOperation = new AuxiliarOperation(); this._newmarkMethod = new NewmarkMethod( this._arrayOperation, this._auxiliarOperation); this._mappingResolver = new MappingResolver(); this._profileValidator = new RectangularProfileValidator(); this._calculateGeometricProperty = new GeometricProperty(); this._piezoelectricProfileMapper = new PiezoelectricRectangularProfileMapper( this._arrayOperation, this._calculateGeometricProperty); this._profileMapper = new RectangularProfileMapper( this._arrayOperation, this._calculateGeometricProperty); this._mainMatrix = new RectangularBeamWithPiezoelectricMainMatrix(this._arrayOperation); this._operation = new CalculateRectangularBeamWithPiezoelectricVibration( this._newmarkMethod, this._mappingResolver, this._profileValidator, this._auxiliarOperation, this._profileMapper, this._piezoelectricProfileMapper, this._mainMatrix, this._arrayOperation); this._methodParameter = new NewmarkMethodParameter { InitialTime = 0, PeriodDivision = 100, NumberOfPeriods = 30, InitialAngularFrequency = 0.5 }; this._request = new BeamWithPiezoelectricRequest <RectangularProfile> { Author = "Teste", BeamData = new PiezoelectricRequestData <RectangularProfile> { DielectricConstant = 7.33e-9, DielectricPermissiveness = 30.705, ElasticityConstant = 1.076e11, ElectricalCharges = new List <ElectricalCharge>(), ElementsWithPiezoelectric = new uint[] { 2 }, FirstFastening = "Pinned", Forces = new List <Force> { new Force { NodePosition = 1, Value = 100 } }, LastFastening = "Pinned", Length = elementLength * numberOfElements, Material = "Steel4130", NumberOfElements = numberOfElements, PiezoelectricConstant = 190e-12, PiezoelectricPosition = "Up and down", PiezoelectricProfile = this._piezoelectricProfile, PiezoelectricSpecificMass = 7650, PiezoelectricYoungModulus = 63e9, Profile = this._beamProfile }, MethodParameterData = this._methodParameter }; this._beamWithPiezoelectic = new BeamWithPiezoelectric <RectangularProfile>() { DielectricConstant = 7.33e-9, DielectricPermissiveness = 30.705, ElasticityConstant = 1.076e11, ElectricalCharge = new double[piezoelectricDegreesFreedomMaximum] { 0, 0, 0 }, ElementsWithPiezoelectric = new uint[numberOfElementsWithPiezoelectrics] { 2 }, FirstFastening = new Pinned(), Forces = new double[degreesFreedomMaximum] { 0, 0, 100, 0, 0, 0 }, GeometricProperty = new GeometricProperty { // Beam profile: height = 3e-3, width = 25e-3. Area = new double[numberOfElements] { 7.5E-05, 7.5E-05 }, MomentOfInertia = new double[numberOfElements] { 5.625E-11, 5.625E-11 } }, LastFastening = new Pinned(), Length = elementLength * numberOfElements, Material = new Steel4130(), NumberOfElements = numberOfElements, NumberOfPiezoelectricPerElements = this._numberOfPiezoelectricsPerElement, PiezoelectricConstant = 190e-12, PiezoelectricGeometricProperty = new GeometricProperty { // Piezoelectric profile: height = 0.267e-3, width = 25e-3. Area = new double[numberOfElements] { 0, this._piezoelectricArea }, MomentOfInertia = new double[numberOfElements] { 0, this._piezoelectricMomentOfInertia } }, PiezoelectricProfile = this._piezoelectricProfile, PiezoelectricSpecificMass = 7650, Profile = this._beamProfile, PiezoelectricYoungModulus = 63e9 }; this._equivalentForce = new double[numberOfBoundaryConditionsTrue] { 0, 100, 0, 0, 0, 0 }; this._mass = new double[numberOfBoundaryConditionsTrue, numberOfBoundaryConditionsTrue] { { 0.000700893, 0.0045558, -0.00052567, 0, 0, 0 }, { 0.0045558, 0.237645, 0.00133738, -0.00534608, 0, 0 }, { -0.00052567, 0.00133738, 0.00152337, -0.000616855, 0, 0 }, { 0, -0.00534608, -0.000616855, 0.000822473, 0, 0 }, { 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0 } }; this._stiffness = new double[numberOfBoundaryConditionsTrue, numberOfBoundaryConditionsTrue] { { 90, -270, 45, 0, 0, 0 }, { -270, 2528.78, 92.1953, 362.195, 0, 0 }, { 45, 92.1953, 210.732, 60.3659, 1.60557e-07, -1.60557e-07 }, { 0, 362.195, 60.3659, 120.732, -1.60557e-07, 1.60557e-07 }, { 0, 0, 1.60557e-07, -1.60557e-07, -6.8633e-07, 6.8633e-07 }, { 0, 0, -1.60557e-07, 1.60557e-07, 6.8633e-07, -6.8633e-07 } }; this._damping = new double[numberOfBoundaryConditionsTrue, numberOfBoundaryConditionsTrue] { { 9e-05, -0.00027, 4.5e-05, 0, 0, 0 }, { -0.00027, 0.00252878, 9.21953e-05, 0.000362195, 0, 0 }, { 4.5e-05, 9.21953e-05, 0.000210732, 6.03659e-05, 1.60557e-13, -1.60557e-13 }, { 0, 0.000362195, 6.03659e-05, 0.000120732, -1.60557e-13, 1.60557e-13 }, { 0, 0, 1.60557e-13, -1.60557e-13, -6.8633e-13, 6.8633e-13 }, { 0, 0, -1.60557e-13, 1.60557e-13, 6.8633e-13, -6.8633e-13 } }; this._newmarkMethodInput = new NewmarkMethodInput { Parameter = this._methodParameter, NumberOfTrueBoundaryConditions = numberOfBoundaryConditionsTrue, Force = this._equivalentForce, Mass = this._mass, Stiffness = this._stiffness, Damping = this._damping }; }