官术网_书友最值得收藏!

Scalar operations

Scalar operations involve a vector (or matrix) and a scalar. To perform an operation with a scalar on a matrix, simply apply to the scalar to every item in the matrix:

In Python, we would simply do the following: 

vector = np.array([[1,2], [1,2]])
new_vector = vector + 2
主站蜘蛛池模板: 定襄县| 大洼县| 宜章县| 石门县| 宣化县| 巴林左旗| 新田县| 阿拉善左旗| 宁武县| 库伦旗| 含山县| 黑山县| 龙门县| 开远市| 镶黄旗| 温泉县| 霍城县| 鄯善县| 台北市| 五峰| 华亭县| 宁国市| 灵川县| 昌邑市| 寿阳县| 天气| 天祝| 桃源县| 连江县| 福泉市| 合川市| 肥城市| 时尚| 谷城县| 金沙县| 温宿县| 博湖县| 保山市| 神农架林区| 隆德县| 辽中县|