<!--
{
  "availability" : [
    "iOS: 18.5.0 -",
    "iPadOS: 18.5.0 -",
    "macCatalyst: 18.5.0 -",
    "macOS: 15.5.0 -",
    "tvOS: 18.5.0 -",
    "visionOS: 2.5.0 -",
    "watchOS: 11.5.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Accelerate",
  "identifier" : "/documentation/Accelerate/SparseRefactor(_:_:)-zegz",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Accelerate"
    ],
    "preciseIdentifier" : "c:@F@SparseRefactor#$@SA@SparseMatrix_Complex_Float#*$@SA@SparseOpaqueFactorization_Complex_Float#"
  },
  "title" : "SparseRefactor(_:_:)"
}
-->

# SparseRefactor(_:_:)

Reuses supplied factorization object’s storage to compute a new
factorization of the supplied matrix of complex float values.

```
func SparseRefactor(_ Matrix: SparseMatrix_Complex_Float, _ Factorization: UnsafeMutablePointer<SparseOpaqueFactorization_Complex_Float>)
```

## Parameters

`Matrix`

The matrix to be factorized.

`Factorization`

The factorization to be updated.

## Discussion

`Matrix` must have the same non-zero structure as that used for
the original factorization.

The same numerical factorization options will be used as in the original
construction of Factorization.

This call provides very similar behavior to that which can be achieved by
reusing explicit storage supplied to `SparseFactor` as the argument
`factorStorage`. However, in addition to providing a simplified call sequence,
this call can also reuse any additional storage allocated to accomodate
delayed pivots.

Note that if the reference count of the underlying object is not
exactly one (i.e. if there are any implict copies as a result of calls to
`SparseGetTranspose` or `SparseCreateSubfactor()` that have not been destroyed
through a call to `SparseCleanup`), then new storage will be allocated
regardless.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)