Skip to content

Instantly share code, notes, and snippets.

@hernandohhoyos
Created August 1, 2024 17:52
Show Gist options
  • Save hernandohhoyos/7f93470c1b6f65d5215d99c052779b73 to your computer and use it in GitHub Desktop.
Save hernandohhoyos/7f93470c1b6f65d5215d99c052779b73 to your computer and use it in GitHub Desktop.
Calcular el punto medio M de la línea AB
import numpy as np
a = np.array((0,0,0))
b = np.array((1,0,0))
M = ((a[0] + b[0]) / 2, (a[1] + b[1]) / 2, (a[2] + b[2]) / 2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment