hmm - would this work?
//specify weightvalue as a floating point number
float weightValue;
float weightRemainder;
void loop(){
//convert to percentage of 100
weightValue = (analogRead(potPin) / 1024);
//find the weightValue's remainder out of 1
weightRemainder = (1 - weightValue);
//find the weighted average
(((weightValue * sineArray[i]) + (weightRemainder * triangleArray[i])) / 2) == weighted average;