i'm trying to make the simplest code (less than 3 or 4 lines) to generate a sawtooth wave in java
I already know the period,frequency, and amplitude of the graph (2). Any suggestions appreciated. I know that i need to use mod arithmetic with the period
i know i need to map the values of [0, period -1] to [-1, 1]. Idk how to use this with modulo arithmetic.