How to create vector of symbolic variables in sympy? I want to do something like
x, x1, x2, x3 = symbols ('x x1 x2 x3')
A = [x+x1,x+x2,x+x3]
B = A * Transpose(A)
print (B)
A
is array of symbolic variables.
I checked with sympy documentation, but couldn't figure out.
(Python 2.7.6, sympy 0.7.4.1)
Update:
I want to do something like
x, x1, x2, x3 = symbols ('x x1 x2 x3')
v1e = x+x1
v2e = x+x2
v3e = x+x3
v1 = v1e.subs(x1,1)
v2 = v2e.subs(x2,2)
v3 = v3e.subs(x3,3)
A = Matrix ([v1,v2,v3])
B = A * Transpose(A)
print (B)
But seems that there is problem with v1,..
putting as matrix elements. Any suggestions?