![]() |
Synthia
Generic and flexible data structure generator
|
Uses the SineWave picker with the PrismPicker to generate Lissajous figures on an oscilloscope screen.
The wiring diagram of pickers in this program is given below:
We recall that a SineWave picker produces an output that corresponds to the equation A sin(ωt+φ), where A, ω and φ are pickers corresponding to amplitude, frequency and phase, respectively. The program depends on two parameters:
The program picks 1,000 points, and then plots them in a window that simulates the operation of an Oscilloscope. You can run the program by changing these values to produce various figures. Here are some classical examples:
| Figure | | | |
|---|---|---|---|
| Parameters | m = 1, n = 0 | m = 2, n = 5π/8 | m = 6/5, n = π/4 |
Caution: pay attention when entering ratios such as 4/3; you must make sure they are interpreted as a double; hence you must write 4d/3 (the d forces a cast to double).
Definition at line 72 of file Lissajous.java.
Static Public Member Functions | |
| static void | main (String[] args) |
|
static |
Definition at line 75 of file Lissajous.java.