#๐ arrays and vectors
13 messages ยท Page 1 of 1 (latest)
@glad heath
Remember to:
- Ask your Python question, not if you can ask or if there's an expert who can help.
- Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
- Explain what you expect to happen and what actually happens.
:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.
Just like when you did R = np.array([0, 0]) There's an R = command that will let you add up your vectors to give you that resultant vector.
what is "the resultant" of vectors? the sum?
when you add two arrays of the same shape with +, you get a new array of the same shape that is the element-wise sum
!e
import numpy as np
arr1 = np.array([1, 2, 3])
arr2 = np.array([4, 5, 6])
print(arr1 + arr2)
print(arr1.sum())
print(np.sum(arr1 + arr2))
:white_check_mark: Your 3.12 eval job has completed with return code 0.
001 | [5 7 9]
002 | 6
003 | 21
He could just do R = F1_vec + F2_vec + F3_vec
what was the solution?
This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.
๐ arrays and vectors