import numpy as np
# 定义行向量
# Method1(直接定义)
x1 = np.array([[-3/4,-1/4,-1/8]])
print(x1)
# Method2
a = [[-3/4,-1/4,-1/8]]
x2 = np.array(a)
print(x2)
# 定义列向量
# Method1(直接定义)
x3 = np.array([[-3/4],[-1/4],[-1/8]])
print(x3)
# Method2(利用行向量的Method1)
x4 = x1.T
print(x4)
# Method3(利用行向量的Method2)
x5 = np.array(a).T
print(x5)