SignalProcessing - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Science and Engineering : Signal Processing : Signal Generation : SignalProcessing/GenerateTriangle

SignalProcessing

  

GenerateTriangle

  

generate a triangle

 

Calling Sequence

Parameters

Options

Description

Thread Safety

Examples

Compatibility

Calling Sequence

GenerateTriangle( n, magnitude, frequency, phase, asymmetry )

Parameters

n

-

posint, number of samples to generate

magnitude

-

realcons, magnitude of the signal

frequency

-

realcons, the frequency of the signal (0 <= frequency < 1/2)

phase

-

realcons, the phase of the signal (0 <= phase < 2Pi)

asymmetry

-

realcons, the asymmetry of the signal (-Pi <= asymmetry < Pi)

Options

• 

container : Array, predefined Array for holding results

Description

• 

The GenerateTriangle(n, magnitude, frequency, phase, asymmetry ) command generates n samples for a triangular signal. The result is returned in an Array with datatype float[8].

• 

The value of the magnitude argument must be positive.

• 

The value of the frequency argument must be non-negative and strictly less than 12.

• 

The phase argument must be non-negative and strictly less than 2π.

• 

The asymmetry argument must be greater than or equal to π, and strictly less than π. When the value of asymmetry is equal to 0, the resulting triangle is symmetric.

• 

If the container=C option is provided, then the results are put into C and C is returned. With this option, no additional memory is allocated to store the result. The container must be an Array of size n having datatype float[8].

Thread Safety

• 

The SignalProcessing[GenerateTriangle] command is thread-safe as of Maple 17.

• 

For more information on thread safety, see index/threadsafe.

Examples

withSignalProcessing&colon;

GenerateTriangle10&comma;1&comma;1&pi;&comma;&pi;&comma;2.3

0.1546592529036540.8897381633598180.6845014316897890.05057747876637500.7856563892225400.7885832058270680.05350429537090360.6815746150852610.8926649799643460.157586069508182

(1)

cArray1..10&comma;&apos;datatype&apos;&equals;&apos;float&apos;8&comma;&apos;order&apos;&equals;&apos;C_order&apos;&colon;

GenerateTriangle10&comma;1&comma;1&pi;&comma;&pi;&comma;2.3&comma;&apos;container&apos;&equals;c

0.1546592529036540.8897381633598180.6845014316897890.05057747876637500.7856563892225400.7885832058270680.05350429537090360.6815746150852610.8926649799643460.157586069508182

(2)

c

0.1546592529036540.8897381633598180.6845014316897890.05057747876637500.7856563892225400.7885832058270680.05350429537090360.6815746150852610.8926649799643460.157586069508182

(3)

plots:-listplotGenerateTriangle100&comma;1&comma;1&pi;&comma;&pi;&comma;2.3

Compatibility

• 

The SignalProcessing[GenerateTriangle] command was introduced in Maple 17.

• 

For more information on Maple 17 changes, see Updates in Maple 17.

See Also

Array

GenerateSlope

GenerateTone

plots[listplot]

with

 


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam