I start with
nx = 5
ny = 5
mesh = UnitSquareMesh(nx, ny)
R = FunctionSpace(mesh, "R", 0)
Next: Given some $v \in \mathbb{R}^{10}$ and some $c \in \mathbb{R}^{11}$ (say as list
's or as numpy.array
's), I wish to define FunctionSpace
objects corresponding to the following two vector spaces:
- $V_1 := \mathbb{R}^{10}$
- $V_2 :=$ the set of $x \in \mathbb{R}^{10}$ such that $\sum_{j=1}^{10} c_j x_j = c_{11}$
Regarding the construction of $V_1$, I suppose I could do something like:
V_1 = R * R * R * R * R * R * R * R * R * R
but I wonder if I could instead do:
V_1 = R
for i in range(1, 10):
V_1 = V_1 * R
Regarding the construction of $V_2$, I don't know how to even start.
Any and all suggestions would be welcome.