Advertisement
JoelSjogren

Untitled

Nov 12th, 2020
205
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.00 KB | None | 0 0
  1. box% octave
  2. GNU Octave, version 5.2.0
  3. Copyright (C) 2020 John W. Eaton and others.
  4. This is free software; see the source code for copying conditions.
  5. There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or
  6. FITNESS FOR A PARTICULAR PURPOSE. For details, type 'warranty'.
  7.  
  8. Octave was configured for "x86_64-pc-linux-gnu".
  9.  
  10. Additional information about Octave is available at https://www.octave.org.
  11.  
  12. Please contribute if you find this software useful.
  13. For more information, visit https://www.octave.org/get-involved.html
  14.  
  15. Read https://www.octave.org/bugs.html to learn how to submit bug reports.
  16. For information about changes from previous versions, type 'news'.
  17.  
  18. octave:1> A = [ 29.72 -14.892 53.778]; B = [ 33.422 -14.57 53.145]; C = [ 32.351 -16.136 54.869];
  19. octave:2> M = C + ((2*[A-C; B-C]*[A-C; B-C]')\([A*A'-C*C'; B*B'-C*C']-2*[A-C; B-C]*C'))'*[A-C; B-C]
  20. M =
  21.  
  22. 31.614 -14.897 53.631
  23.  
  24. octave:3> [norm(A-M) norm(B-M) norm(C-M)]
  25. ans =
  26.  
  27. 1.9001 1.9001 1.9001
  28.  
  29. octave:4>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement