Say I have a set of equations where the unknown variables are the elements of a vector $c=(c_1,c_2,\ldots)$ and want to solve it for $c$. Is there a way to do this with Solve
without typing out all the elements?
In other words: Instead of writing something like
Solve[{c1*x + c2*y == 1, -c1*x + 2*c2*y == -2}, {c1, c2}]
which works and gives
{{c1 -> 4/(3 x), c2 -> -(1/(3 y))}}
I'd like to write something like
Solve[{c[[1]]*x + c[[2]]*y == 1, -c[[1]]*x + 2*c[[2]]*y == -2}, c]
which doesn't work