~ubuntu-branches/ubuntu/trusty/csound-manual/trusty-proposed

« back to all changes in this revision

Viewing changes to examples/genfarey.csd

  • Committer: Bazaar Package Importer
  • Author(s): Felipe Sateler
  • Date: 2011-08-01 22:21:58 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20110801222158-90kslkp5ujci2f5d
Tags: 1:5.13~dfsg-1
* New upstream release
 - Add Menno Knevel to the copyright file
 - Refresh patch 2000-stripped-opcodes.diff
 - Update copyright hints file
* Update Vcs-* headers
* Bump Standards-Version

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<CsoundSynthesizer>
 
2
<CsOptions>
 
3
</CsOptions>
 
4
<CsInstruments>
 
5
 
 
6
sr=44100
 
7
ksmps=10
 
8
nchnls=1
 
9
 
 
10
instr 4
 
11
      kndx init 0 ; read out elements of F_8 one by one and print to file
 
12
      if (kndx < 23) then    
 
13
         kelem tab kndx, 1
 
14
         fprintks "farey8table.txt", "%2.6f\\n", kelem
 
15
         kndx = kndx+1
 
16
      endif
 
17
endin
 
18
</CsInstruments>
 
19
<CsScore>
 
20
; initialise integer for Farey Sequence F_8
 
21
f1 0 -23 "farey" 8 0
 
22
      ; if mode=0 then the table stores all elements of the Farey Sequence
 
23
      ; as fractions in the range [0,1]
 
24
i4      0     1
 
25
e
 
26
</CsScore>
 
27
</CsoundSynthesizer>