ALTADataSet.AddStressProfile: Difference between revisions

From ReliaWiki
Jump to navigation Jump to search
No edit summary
Line 1: Line 1:
{{Template:APIClass|ALTADataSet Class|ALTADataSet}}
{{Template:API}}{{Template:APIBreadcrumb|.[[ALTADataSet_Class|ALTADataSet]]}}
{{Template:ALTADataSet.AddStressProfile.Cmt}} Stress profiles can be used only when the cumulative damage model is selected.


== Syntax ==
<ul><li>
AddStressProfile(
{{APIName|Profile}}
{{APIPrefix|As}}
[[ALTAStressProfile Class|ALTAStressProfile]]
)
</li></ul>


Parameters
<onlyinclude>Returns an [[ALTAStressProfile_Class|ALTAStressProfile]] object that represents a time-dependent stress profile and associates it with an ALTADataSet object. Applies to the cumulative damage (CD) model only.</onlyinclude>
:''Profile'': A defined stress profile, as an instance of the [[ALTAStressProfile Class|ALTAStressProfile]] class.


== Usage Example ==
==Syntax==
  {{APIComment|'Declare a new ALTADataSet object. See [[ALTADataSet Class|ALTADataSet]].}}
'''.AddStressProfile'''(''Profile'')
  Dim ALTADS as New ALTADataSet
 
 
===Parameters===
  {{APIComment|Declare a new stress profile. See [[ALTAStressProfile Class|ALTAStressProfile]].}}
''Profile''
  Dim sp = New ALTAStressProfile("Profile1")
:Required. The [[ALTAStressProfile_Class|ALTAStressProfile]] object.
  sp.RepeatCycle = True
 
  sp.AddSegment(1, 250)
 
  sp.AddSegment(2, 300)
==Example==
  sp.AddSegment(3, 400)
The following example demonstrates how to create a stress profile and associate it with an ALTADataSet object.
 
'''VB.NET'''
  {{APIComment|'Declare a new ALTADataSet object.}}  
  {{APIPrefix|Dim}} ADS {{APIPrefix|As New}} ALTADataSet
  {{APIComment|'Declare a new stress profile.}}
  {{APIPrefix|Dim}} sp {{APIPrefix|As New}} ALTAStressProfile({{APIString|"Profile1"}})
  sp.RepeatCycle = True
  sp.AddSegment(1, 250)
  sp.AddSegment(2, 300)
  sp.AddSegment(3, 400)
    
    
  {{APIComment|Add the stress profile to the data set.}}
  {{APIComment|'Add the stress profile to the ALTADataSet object.}}
  ALTADS.AddStressProfile(sp)
  ALTADS.AddStressProfile(sp)
    
    
  {{APIComment|Add a failure time to the data set. See [[ALTADataSet.AddFailure|AddFailure]].}}
  {{APIComment|'Add a failure time to the data set, using the stress profile.}}
  ALTADS.AddFailure(100, 1, sp)
  ALTADS.AddFailure(100, 1, sp)

Revision as of 21:24, 15 April 2016

APIWiki.png


Member of: SynthesisAPI.ALTADataSet


Returns an ALTAStressProfile object that represents a time-dependent stress profile and associates it with an ALTADataSet object. Applies to the cumulative damage (CD) model only.

Syntax

.AddStressProfile(Profile)

Parameters

Profile

Required. The ALTAStressProfile object.


Example

The following example demonstrates how to create a stress profile and associate it with an ALTADataSet object.

VB.NET

 'Declare a new ALTADataSet object.  
  Dim ADS As New ALTADataSet

 'Declare a new stress profile. 
  Dim sp As New ALTAStressProfile("Profile1")
  sp.RepeatCycle = True
  sp.AddSegment(1, 250)
  sp.AddSegment(2, 300)
  sp.AddSegment(3, 400)
 
 'Add the stress profile to the ALTADataSet object. 
  ALTADS.AddStressProfile(sp)
 
 'Add a failure time to the data set, using the stress profile. 
  ALTADS.AddFailure(100, 1, sp)