ALTADataSet.AddSuspension

From ReliaWiki
Revision as of 23:55, 24 February 2014 by Chris Kahn (talk | contribs)
Jump to navigation Jump to search


Adds suspensions to the data set, using the time at which the units were suspended, the number of suspensions at that time and the associated stress level.

Syntax

  • AddSuspension( Value As Double , NumberInGroup As Integer , Stress() As Object ) Adds suspensions to the data set, using the specified time, the number of suspensions at that time and an array of stress values/profiles for all the stresses.
  • AddSuspension( Value As Double , NumberInGroup As Integer , Stress1 As Object ) Adds suspensions to the data set, using the specified time, the number of suspensions at that time and a single stress value/profile.
  • AddSuspension( Value As Double , NumberInGroup As Integer , Stress1 As Object , Stress2 As Object ) Adds suspensions to the data set, using the specified time, the number of suspensions at that time and two stress values/profiles.

Parameters

Value: The suspension time.
NumberInGroup: The number of units that were suspended at the Value time.
Stress(): An array containing numeric stress values or references to added ALTAStressProfiles.
Stress1: A numeric stress value or reference to an added ALTAStressProfile.
Stress2: A numeric stress value or reference to an added ALTAStressProfile.

Usage Example

Declare the ALTADataSet. See New ALTADataSet for additional details.

       Dim ALTADS as New ALTADataSet

Declare an ALTAStressProfile. See ALTAStressProfile for additional details.

       Dim sp = New ALTAStressProfile("Profile1")
       sp.RepeatCycle = True
       sp.AddSegment(1, 250)
       sp.AddSegment(2, 300)
       sp.AddSegment(3, 400)

Add values to the raw data.

       ALTADS.AddSuspension(1, 1, sp)
       ALTADS.AddSuspension(2, 1, sp)
       ALTADS.AddSuspension(3, 1, sp)

Get the number of suspensions. In this example, NumberOfSuspension will be 3.

       Dim NumberOfSuspension as Integer
       NumberOfSuspension = ALTADS.SuspensionCount