Function PolyFactEq(ByVal MatX As Range, Optional ByVal R As Variant = 3)
'-> Application de polyfact()

'Traitement de l'arrondi
R = CLng(R)

'Tailles matrices
Dim l As Long, C As Long
l = MatX.Rows.Count
C = MatX.Columns.Count

'Erreur de taille
If C > 1 Then PolyFactEq = "#COLONNE!": Exit Function
If l - 1 = 0 Then PolyFactEq = "#DEGRE!": Exit Function

'Ecriture equation
Dim I As Long, Coef As Double, Solution As Double, Signe As String
Coef = MatX.Cells(1)
If Coef <> 1 Then PolyFactEq = MatX.Cells(1) & "*"
For I = 1 To l - 1
    Solution = PolyFact(MatX, I, R)
    Signe = Left$(CStr(Solution), 1)
    If Signe = "-" Then
        PolyFactEq = PolyFactEq & "(X " & Solution & ")"
    Else
        PolyFactEq = PolyFactEq & "(X + " & Solution & ")"
    End If
Next I

End Function