An apparatus for calculating an output signal of an encoder, comprising: a sampling means (21, 22) for sampling simultaneously an A-phase sine wave signal or a signal resembling said A-phase sine wave signal and a B-phase sine wave signal or a signal resembling said B-phase sine wave signal differing in phase by exactly a predetermined angle and thereby outputting an A/D converted value A of said A-phase sine wave signal or a signal resembling said A-phase sine wave signal and an A/D converted value B of said B-phase sine wave signal or a signal resembling said B-phase sine wave signal, an angle detection circuit for finding a phase angle θ at different sampling points of a resurge waveform, each sampling point obtained by plotting the A/D converted value A of said A-phase sine wave signal or a signal resembling said A-phase sine wave signal and the A/D converted value B of said B-phase sine wave signal or a signal resembling said B-phase sine wave signal at the sampling points by said sampling means on an X-axis and a Y-axis, respectively, of a Cartesian X-Y-coordinate system having four quadrants n, wherein n∈{1; 2; 3; 4}, such that said value A is indicated on the X-axis and said value B is indicated on the Y-axis, a means for finding a quadrant n of said coordinate system from polarities of said A/D converted value A and said A/D converted value B, where, n − 1 / 2 π ≤ θ < n / 2 π, and for converting the phase angle θ of the quadrant n to a phase angle θ' of the quadrant 1, a coefficient storing means storing coefficients α and β for each of a predetermined number of angle areas within said quadrant 1, said coefficients being set so that α|A|+β|B| approximates a radius R of a theoretical resurge waveform, wherein |A| and |B| are absolute values of said values A and B, and wherein values for α and β are retrieved from said coefficient storing means such that they correspond to the angle area within which said phase angle θ' falls, and a calculating means for calculating the radius R' of said resurge waveform on the basis of said retrieved values, wherein R'=α|A|+β|B|, and determining said calculated radius R' as the amplitude of the output signal of the encoder. a sampling means (21, 22) for sampling simultaneously an A-phase sine wave signal or a signal resembling said A-phase sine wave signal and a B-phase sine wave signal or a signal resembling said B-phase sine wave signal differing in phase by exactly a predetermined angle and thereby outputting an A/D converted value A of said A-phase sine wave signal or a signal resembling said A-phase sine wave signal and an A/D converted value B of said B-phase sine wave signal or a signal resembling said B-phase sine wave signal, an angle detection circuit for finding a phase angle θ at different sampling points of a resurge waveform, each sampling point obtained by plotting the A/D converted value A of said A-phase sine wave signal or a signal resembling said A-phase sine wave signal and the A/D converted value B of said B-phase sine wave signal or a signal resembling said B-phase sine wave signal at the sampling points by said sampling means on an X-axis and a Y-axis, respectively, of a Cartesian X-Y-coordinate system having four quadrants n, wherein n∈{1; 2; 3; 4}, such that said value A is indicated on the X-axis and said value B is indicated on the Y-axis, a means for finding a quadrant n of said coordinate system from polarities of said A/D converted value A and said A/D converted value B, where, n − 1 / 2 π ≤ θ < n / 2 π, and for converting the phase angle θ of the quadrant n to a phase angle θ' of the quadrant 1, a coefficient storing means storing coefficients α and β for each of a predetermined number of angle areas within said quadrant 1, said coefficients being set so that α|A|+β|B| approximates a radius R of a theoretical resurge waveform, wherein |A| and |B| are absolute values of said values A and B, and wherein values for α and β are retrieved from said coefficient storing means such that they correspond to the angle area within which said phase angle θ' falls, and a calculating means for calculating the radius R' of said resurge waveform on the basis of said retrieved values, wherein R'=α|A|+β|B|, and determining said calculated radius R' as the amplitude of the output signal of the encoder.