[frames] | no frames]

Module Waveguides

source code

Waveguides.py - Contains classes defining the transmission matrices for simple geometries and functions to generate them.

 Classes
Waveguides
Base class for waveguides
Cylinder
Class representing a cylinder
Cone
Truncated cone transmission matrix calculation class
CurvedCone
Class representing a curved cone
Jump
Class representing a diameter jump
ToneHole
This class implements the transmission matrix of tone holes References:
 Functions

 PropagationConstant(f, a, air, beta) Calculate the complex propagation constant in an acoustic waveguide source code

 Build a list of Cylinder or Cone from a list of tuples containing position and diameters. source code

 ConeApproximatedWithCylinders(d0, de, L, N=200) source code

 EquationApproximatedWithCones(equation, L, N=10) Discretization in conical segments of an equation giving the radius of the waveguide as a function of its argument. source code
 Function Details

PropagationConstant(f, a, air, beta)

source code

Calculate the complex propagation constant in an acoustic waveguide

See Allan D. Pierce p. 531-534

Parameters:
• `f` - frequency array
• `a` - tube radius
• `air` - Air instance
• `beta` - factor to take into account wall roughness
Returns:
Γ = α + 1j * ω / v_φ where α is the attenuation, ω is 2πf and v_φ is the phase velocity

CreateCylindersAndConesFromList(list)

source code

Build a list of Cylinder or Cone from a list of tuples containing position and diameters.

Example:

```   >>> import wiat
>>> FluteBody = wiat.TM.CreateCylindersAndConesFromList(
... [(0.,0.0188),(0.132,0.0188),(0.340,0.0152),
...  (0.452,0.0135),(0.583,0.0112)])
>>> for s in FluteBody: print s
Cylinder(d=0.0188,L=0.1320)
Cone(d0=0.0188,de=0.0152,L=0.2080)
Cone(d0=0.0152,de=0.0135,L=0.1120)
Cone(d0=0.0135,de=0.0112,L=0.1310)
```
Parameters:
• `list` - a list of tuples (position,diameter) where the position is the distance along the centerline of the instrument from the mouthpiece.

EquationApproximatedWithCones(equation, L, N=10)

source code

Discretization in conical segments of an equation giving the radius of the waveguide as a function of its argument.

Parameters:
• `equation` - an equation of one argument. It will be evaluated from 0 to L.
• `L` - the length of the waveguide.

 Generated by Epydoc 3.0.1 on Wed Jun 18 14:33:28 2008 http://epydoc.sourceforge.net