Algorithms to re-spatialize a stereo recording audio signal?
Which algorithms can be used to &quot;re-spatialize&quot; this recording, i.e. try to virtually &quot;move the microphones&quot;, and recreate a new stereo signal, for example with an AB mic positioning?

In general, this is a beamforming &quot;problem&quot;, but it cannot be done in exactly the way it is described here.
With a setup like this, you can adjust the relative differences between signals recorded on each microphone, but you would not be able to tell if rotating the microphones (or putting them apart) would result in one of the microphones:

Moving closer/further away from a source.
Moving closer/further away from a local pressure maximum/minimum in the room.

The way to overcome 1 (and partially 2) is to use an array of $M$ microphones and beamforming techniques. You would first localise the sources and the signals they contribute to the array and then place a set of $N&lt;M$ microphones within the array, re-project the signals and see what this sounds like.
This deals with 1 and it deals with 2 as long as, the microphones (or sources) do not move too far away from their locations.
A microphone does not only pick up the sound that is produced by a source in its vicinity but it also picks up the interference of the space the sound propagates in on that sound.
As the sound waves propagate, they get reflected, refracted, absorbed over surfaces and objects in a room. This is what gives the room a &quot;signature&quot;. You can tell for example a recording done in an empty warehouse because it has more reverberation. You can tell if the source was near or far from the microphone because in the first case the reverberation is softer and it is trailing the main sound but in the second case, the reverberation is thicker and the main sound has receded deeper into its reverberations.
If you tried to use beamforming to record sound in a tunnel and then asked, &quot;well what would it sound like if we placed the microphones further back in the tunnel?&quot; (many more reflections) Then, it is impossible to work out the dimensions of the tunnel and the effect these would have on the sound the mics pick up (without assumptions or some other way of filling your knowledge gap).
You would &quot;rotate the phase&quot; (for the new configuration of the mics) but you would not know the &quot;phase correction&quot; required at a given point in space because of the shape of this space.
For more elaborate examples of this type of beamforming, please see here or here and more generally look for work around audio beamforming.
Hope this helps.
EDIT:
On the points made more specific in the comments:

Are there formulas about how to shift signals according to a distance change?

Yes, that would be the typical way of working out &quot;phase of arrival&quot; taking into account the speed of sound in air and frequency of a component (from which you workout the wavelength and through that the frequency difference because of distance). These equations are present in the beamforming examples.