hi.
Lacan does an extense reading of Freud and finds that the best way to locate the psyche and its entropic energetic states is through topology of surfaces (2-D).
not 3-D, as Freud did (iceberg = ego, superego and id).
he does this because psyche and its energetic motions through Freudian obsevations (such as projection-introjection, narcissistic-objectal libido) has the same propierties that mathematically closed finite & infinite spaces do, to understand the nature of an egoic intersubjective reality in neurosis, psychosis and perversion.
Lacan does use mathematics because they operate with pure signifiers that do not create chains of signifiers (like they do in signification, meaning or sense).
numbers lack meaning by themselves, so they can be operated by stripping all attempts from the imaginary to capt them (which is something that Lacan tries to avoid, and blames Jung for falling for it).
mathematics and logic formulae are located within the Real (signifiers that do not make chains), in opposition to and out-of sense/meaning/signification in which Jungian archetypes would be located.