0

I was searching the web for an answer but couldnt' find it:

I use Mathematica and instead of writing a vector like:

u = {1,2,3}

I was trying to do it hotkeys I found at the "Basic Math Assistant" like this:

( -> Ctr-Enter -> Ctr-Enter -> 3 -> up -> 2 -> up -> 1 -> Ctr-Space -> )

But if executed I get

{{1}, {2}, {3}}.

it looks like it is treated as a matrix and not a vector. This is a problem since I can't use such written vectors for calulations, with "cross" or similar. Is there something I am missing, or doing wrong? Why is it not the same as {1,2,3}

This is rather a cosmetic way of writing vectors, but I'm wondering if it would work.

Thanks.

Regards

  • Try using Ctrl-,. Using enter adds a row to the matrix, using , adds a column. – b3m2a1 Apr 12 '17 at 18:45
  • Using Ctrl-, will come out as {{1,2,3}}. I think trying to get this strange formatting is going to end up being more trouble than it's worth. If you need something pretty you can always output using TableForm or MatrixForm when you're done with your calculations. – N.J.Evans Apr 12 '17 at 18:51
  • Not an elegant solution, but if you really want to enter these vectors using Ctrl-Enter or Ctrl-,, you can always Flatten the result to get a 1-dimensional list. – jjc385 Apr 12 '17 at 19:03
  • Thanks,

    I guess I just stick to the standard. Thanks anyways

    –  Apr 12 '17 at 20:07
  • What does this question have to do with "Symbolic" vectors? – David G. Stork Apr 12 '17 at 22:34
  • The linked thread might be enlightening reading. – J. M.'s missing motivation Apr 14 '17 at 18:43

0 Answers0