|
to Pieter's software index |
Spectroscopic Toolkit 64-bit phase oscillators for nanotonal synthesis |
![]() |
|
|
|||
addWAVELET() API-function) which are 8 bytes themselves, we lose
the bits occupied by the exponent there. I guess that at least 52 bits remain for
the mantissa, i.e. ST's actual frequency accuracy. (I might update to 128-bit doubles for the API soon.)
instruments are allocated and played, as long as
they are active. The differences with CSound are that instruments
are called WAVELETS and that they remain in memory rather than in a
.sco file. In ST, there is no separate sorting routine (as in CSound),
WAVELETS in the linked list structure maintain their order
- based on starttimes - by use of the addWAVELET() function.
main() in source file ST.c starts with creating
a logfile to write diagnostic messages to.ENGINE which contains
samplerate information, some samplerate-related constants and some wavetables.
addWAVELET().
Currently, 3 types of envelopes are supported, but it won't be too difficult to add more
in sourcefile ST_wavelets.c.
main(), function scoreWAVELETS()
may be called several times to draw scores with various dimensions. With parameter envelopeTracking switched on,
scoreWAVELETS() visualises envelope-shapes by greyscales. With envelopeTracking off,
only the top-amplitude of an envelope is used as greyscale (no intensity change over time).
playWAVELETS() from main(). Audio rendering will abort as soon as
over- or underflow occurs, files thus far will however be saved.visualiseTables() function:
![]() |
For audio, only a simple sinewave is used. In expontial envelopes (rise and fall) a sine is the only one that can be used. A cosine, for instance, might cause clicks when its' phase is aligned at the start or the end of the exponential. | |
![]() |
In calls to addWAVELET(), argument top specifies the center of the gaussian bell,
dur specifies only 1/5th of the total (really calculated) duration.Duration is measured here from inflection point at steepest ascend to inflection point at steepest descend, where amplitude is exp(-0.5), which is approximately 0.6065.
Here argument phase may be -1 (oscill sync), 0 (aligned sine) or 1 (aligned cosine). |
|
![]() |
In calls to addWAVELET(), argument top specifies the start of the exponential decay,
dur specifies only 1/15th of the total (really calculated) duration.Duration is measured here from start ( top) to the -6.02 dB point, where amplitude is exactly 0.5.
Here audio and subaudio tables need to be aligned to prevent 'clicks', argument phase
must be 0. |
|
![]() |
In calls to addWAVELET(), argument top specifies the end of the exponential rise,
dur specifies only 1/15th of the total (really calculated) duration.Duration is measured here from the -6.02 dB point, where amplitude is exactly 0.5, to the end ( top).
Here audio and subaudio tables need to be aligned to prevent 'clicks', argument phase
must be 0. |
| ST1.86.tar.gz | 18 MB | Spectroscopic Toolkit version 1.86, including Kurucz' database. | ||
gunzip ST1.86.tar.gz
tar xf ST1.86.tar
A new directory named ST1.86 should have been created by now.
ls -ls ST1.86
8 -rw-r--r-- 1 pieter user 3499 Sep 19 03:30 README
171064 -rw-r--r-- 1 pieter user 87582045 Jul 14 2002 gfall.dat
8 drwxr-xr-x 2 pieter user 4096 Sep 22 02:27 html
8 drwxr-xr-x 4 pieter user 4096 Sep 21 05:45 src
CC), change optimization flags
(CFLAGS), etc.
makefiles
(Mac OS 7, 8 or 9; MS Windows), put together a standard C project
containing:
.c files from directory src/:
ST.c,
ST_aiff.c,
ST_export.c,
ST_pconv.c,
ST_score.c and
ST_wavelets.c;
.c files from subdirectory src/comp/:
c00_example.c,
c01_massiveCloud.c,
c01_twoWeeks.c,
c02_smear.c
c03_H.c,
c04_Mendelejev.c,
c04_Xenofobia.c,
c05_hydrogenBirds.c
c06_Hbells.c,
c06_Hmelody.c,
c06_Hsplit.c,
c06_JEBASE.c and
c07_composition2003.c.
cd ST1.86/src
make
When this succeeded, a binary executable named ST should have been
created in the parent directory.
<math.h>.
Furthermore, your C compiler needs to support 64-bit integers (signed as well as unsigned)
as integral datatype (they are called long long and unsigned long long
on most systems).
cd ../
./ST 1000
This should yield a short AIFF file, two JPEG files and a logfile.
./ST 24 48000 1002
instructs ST to generate a 24-bit output file with a samplerate
of 48 kHz, rendering number 1002.
./ST
Version ST1.86 by Pieter Suurmond, october 16, 2004.
Parameter(s) missing!
USAGE: ST [bits] [samplerate] number
Bits may be 8, 16 or 24. Samplerate must be in Hertz.
Use one of the following numbers as (last) parameter:
0: Print usage and list numbers.
1000: Example 0: Gaussians (using no database) 00:21.
1001: Example 1: Clip test (using no database) 00:04.
1002: Example 2: Overtones (using no database) 00:23.
1003: Example 3: Phase test (using no database) 00:19.
1004: Example 4: Exponent test (using no database) 01:31.
1301: 'Mendelejev progression H to S' (study 2001) 06:55.
1302: 'Two Weeks - alchemist metals' (study 2001) 06:03.
1307: 'Hydrogen horizontally smeared' (study 2001) 01:04.
20030001: 'Boog' (composition 2003 part 1) 05:09.
20030002: 'Vogelbellen' (composition 2003 part 2) 07:59.
20030102: 'Hydrogen Birds' (2002) 08:10.
20030202: 'Hydrogen and Helium+ Bells' (2003) 02:43.
Example numbers 1000 to 1004 don't need any quantumphysical data. But the first time
ST does need it (when you supply numbers above 1300), it will pack textfile
gfall.dat to binary format, creating a file named
gfall.pbin.
.pbin files may not be portable between platforms
(especially not between big- and little endians).
| 1 | ST1.16HSmndljv |
Mendelejev progression hydrogen to sulphur (H He Li Be B C N O F Ne Na Mg Al Si P S) |
6:30 | 65.7 MB |
|
||||
|---|---|---|---|---|---|---|---|---|---|
| 2 | ST0.44twoWeeks |
Alchemistic metals and ions (Au Ag Fe Hg Sn Cu Pb -- Ag+ Fe+ Hg+ Sn+ Cu+ Pb+) |
6:03 | 61.2 MB |
|
||||
| 3 | ST1.14HOmndljv |
Mendelejev progression hydrogen to oxygen (H He Li Be B C N O) |
3:42 | 37.4 MB |
|
||||
| 4 | ST0.33AuGliss | Gold glissando (Au) | 1:13 | 12.4 MB |
|
||||
| 5 | ST0.33AgGliss | Silver glissando (Ag) | 0:27 | 4.6 MB |
|
||||
| 6 | ST0.33FeGliss | Iron glissando (Fe) | 0:33 | 5.7 MB |
|
||||
| 7 | ST0.35energyH | Hydrogen horizontal smeared (H) | 1:00 | 10.1 MB |
|
||||
| 8 | ST0.35togetherH | Hydrogen vertical (H) | 1:33 | 15.7 MB | (see energyH) | ||||
| 9 | ST0.33AuAgGliss | Gold and silver glissandi (Au Ag) | 0:54 | 9.2 MB |
|
||||
| 10 | ST0.07HOionErr | Hydrogen to oxygen staccato (H He Li Be B C N O) | 6:03 | 61.3 MB | (timing errors) | ||||
| 11 | ST0.08HOionErr | Hydrogen to oxygen legato (H He Li Be B C N O) | 11:51 | 119.8 MB | (timing errors) | ||||
| 12 | ST0.24week39 | Week 39 octaves (Au Ag Fe Hg Sn Cu Pb) | 3:44 | 37.8 MB |
(octave higher than ST0.26) |
||||
| 13 | ST0.26week40 | Week 40 octaves (Au Ag Fe Hg Sn Cu Pb) | 3:27 | 35.0 MB |
|
||||
| total: | 47:00 | 474.4 MB |