U2 is an integrator in that it will convert the square wave input to a triangle wave. With the resistor on the inverting input the inverting input is at a virtual ground and thus the input becomes a constant current source for the capacitor connected between the inverting input and the output. When a capacitor is charged with a constant current current the capacitor charges in a linear mode instead of an expoential (sic) curve.
On the input when the square wave is at 0 the resistor on the inverting input discharges the capacitor in a linear mode giving a full cycle triangle wave.
U1 is a square wave oscillator, but it is questionable if the duty cycle is
50%, so it is questionable if the triangle wave from U2 has the same rise and fall times.