<!--
{
  "availability" : [
    "Swift: -",
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macOS: 10.10.0 -",
    "tvOS: 10.0.0 -",
    "watchOS: 3.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Accelerate",
  "identifier" : "/documentation/simd/matrix_invert(_:)-nkj5",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "simd"
    ],
    "preciseIdentifier" : "s:4simd13matrix_invertySo0A10_double2x2aADF"
  },
  "title" : "matrix_invert(_:)"
}
-->

# matrix_invert(_:)

Returns the inverse of the specified matrix.

```
func matrix_invert(_ x: simd_double2x2) -> simd_double2x2
```

---

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)