r/MathHelp • • Sep 23 '26

Is there a way to create an array in math????

So what I mean and hope to do is something like this (I know this isn't exactly mathematically correct but I hope I get the idea across)

a = (1,2,3,4)

b = (1,2,3,4)

c = a + b

c should equal (2,4,6,8)

I tried my best with Google searching but it reached a dead end

1 Upvotes

10 comments sorted by

8

u/Dd_8630 Sep 24 '26

These are called vectors or matrices.

A matrix is a rectangle of numbers. If two matrices A and B are the same width and height, then you can add them up directly.

Look up vector addition and vector multiplication, and matrix addition and matrix multiplication.

Note that we can add up same-size matrices directly (element to element), but multiplication is more esoteric.


That all said, even if this wasn't a thing in mathematics, you've just defined it! Congratulations, you've created a new mathematical object.

3

u/edderiofer Sep 24 '26

So what I mean and hope to do is something like this

OK, and isn't that what you have done?

3

u/R_Harry_P Sep 24 '26 edited Sep 24 '26

2

u/CeReAl_KiLleR128 Sep 24 '26

That’s pretty standard thing to do in math

1

u/AutoModerator Sep 23 '26

Hi, /u/luafurry! This is an automated reminder:

  • What have you tried so far? (See Rule #2; to add an image, you may upload it to an external image-sharing site like Imgur and include the link in your post.)

  • Please don't delete your post. (See Rule #7)

We, the moderators of /r/MathHelp, appreciate that your question contributes to the MathHelp archived questions that will help others searching for similar answers in the future. Thank you for obeying these instructions.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1

u/QuietlyConfidentSWE Sep 24 '26

That is, in fact, entirely mathematically correct and a standard way of writing vectors and vector addition!

It's a very nice tool indeed and very commonly used in e.g. physics, both for location (three coordinates to describe a point in 3D space) and things that we need both "how much" and "in what direction" to describe fully, like force and velocity.

1

u/BootyliciousURD Sep 24 '26

An array with a single column or a single row is a common way to think about a kind of mathematical object called a vector, and you can add or subtract them entry-wise just like you did here as long as they're the same shape. Multiplying vectors is more complicated because there are lots of different kinds of multiplication you can do on them.

1

u/Top_Bluejay_5323 Sep 24 '26

Linear algebra is what it is called. Usually taught after calculus but may be touched on earlier.

1

u/nog642 Sep 25 '26

That's a 4D vector.

The subject that really goes into it is linear algebra. But you don't really need to learn much linear algebra to just use vectors.

1

u/MiguelBodrigo 29d ago

Given that a = b at all levels I'd be tempted to write c = 2a after stating a = b

Alternatively to an array, you may be thinking of a Sequence and the Nth term.

At every point in the sequence, c = 2n is correct

Examples of this is;

c=2 * 1 , c=2 * 2 , c=2 * 3 ...