---
title: "GLKVector3Subtract(_:_:)"
framework: GLKit
role: symbol
role_heading: Function
platforms: [iOS 5.0+, iPadOS 5.0+, macOS 10.8+, tvOS 9.0+]
path: "glkit/glkvector3subtract(_:_:)"
---

# GLKVector3Subtract(_:_:)

Returns the difference between two vectors.

## Declaration

```swift
func GLKVector3Subtract(_ vectorLeft: GLKVector3, _ vectorRight: GLKVector3) -> GLKVector3
```

## Parameters

- `vectorLeft`: The starting vector.
- `vectorRight`: The vector to subtract.

## Return Value

Return Value A new vector whose components each represent the difference between the components found in the same positions of the two source vectors.

## See Also

### Mathematical Operations Performed on Vectors

- [GLKVector3Negate(_:)](glkit/glkvector3negate(_:).md)
- [GLKVector3Normalize(_:)](glkit/glkvector3normalize(_:).md)
- [GLKVector3AddScalar(_:_:)](glkit/glkvector3addscalar(_:_:).md)
- [GLKVector3SubtractScalar(_:_:)](glkit/glkvector3subtractscalar(_:_:).md)
- [GLKVector3MultiplyScalar(_:_:)](glkit/glkvector3multiplyscalar(_:_:).md)
- [GLKVector3DivideScalar(_:_:)](glkit/glkvector3dividescalar(_:_:).md)
- [GLKVector3Add(_:_:)](glkit/glkvector3add(_:_:).md)
- [GLKVector3Multiply(_:_:)](glkit/glkvector3multiply(_:_:).md)
- [GLKVector3Divide(_:_:)](glkit/glkvector3divide(_:_:).md)
- [GLKVector3DotProduct(_:_:)](glkit/glkvector3dotproduct(_:_:).md)
- [GLKVector3CrossProduct(_:_:)](glkit/glkvector3crossproduct(_:_:).md)
- [GLKVector3Lerp(_:_:_:)](glkit/glkvector3lerp(_:_:_:).md)
- [GLKVector3Project(_:_:)](glkit/glkvector3project(_:_:).md)
- [GLKVector3Maximum(_:_:)](glkit/glkvector3maximum(_:_:).md)
- [GLKVector3Minimum(_:_:)](glkit/glkvector3minimum(_:_:).md)
