I am trying two multiply two ore more different arrays with one constant factor. For example, I have two arrays from pressure measurement in bar and want to convert every array seperately to Pa by multiplying every row by the factor 1e5. The return should be also two arrays. I thought about a for loop, but I am new to Python and I have no idea how to deal with it.
# for example
import numpy as np
p1=np.array([2,3,4]) # pressure measurement p1 in bar
p2=np.array([8,7,6]) # pressure measurement p2 in bar
# loop to multiply p1 and p2 seperately with 1e5
# return
# p1[2e5,3e5,4e5]
# p2[8e5,7e5,6e5]
Can anybody help?
Thank you very much!
Jonas
