Adding a Capacitor and Resistor
You must adfd a resistor and capacitor to the input and output of your circuit for protection. They will regulate the DC voltage in a circuit so they don’t over charge the audio input/output.

Calculations
R2 = 10k ohms
R1 = 10k ohms
Gain = 1 + (R2 / R1)
Gain = 1 + (10k / 10k)
Gain = 1 + 1
Gain = 2
Calculations
Highest – R1 = 10k, R2 = 10k
Gain = 1 + (10k / 10k)
Gain = 1 + 1
Gain = 2
Lowest – R1 = 10k, R2 = 0
Gain = 1 + (0 / 10k)
Gain = 1 + 0
Gain = 1

Calculations and Analysis
Rin = 10k
Rf = 20k
Gain = -Vin * (Rf / Rin)
Gain = -1 * (20k / 10k)
Gain = -1 * 2
Gain = -2
In this photo the output is inverted and has two times the voltage of the input.
Calculations
Highest – Rin = 5k, Rf = 10k, Vin = 1
Gain = -1 (10k / 5k)
Gain = -1 * 2
Gain = -2
Lowest – Rin = 5k, Rf = 0k, Vin = 1
Gain = -1 (0 / 5k)
Gain = -1 * 0
Gain = 0