Live data from Hacker News

Functions are vectors

thenumb.at

41–50 of 124 posts

Re: Functions are vectors

#41
I wish I could upvote this twice. This is the best basic introduction to concepts in functional analysis that I've seen. Another great overview that goes deeper into the math is [1].

Another fantastic application that the website doesn't mention is the composition / Koopman operator. In control theory (e.g. autonomous drones, cars, robot arms, etc.), most real-world systems are described by nonlinear dynamics which are very difficult to work with (e.g. safety/stability guarantees, optimizing over forward horizons using NMPC, state estimation, etc.) The Koopman operator however gives a globally relevant linear approximation of non-linear systems. In other words, you can treat a nonlinear system as a linear system with fairly high accuracy. This greatly simplifies control and estimation from a computational perspective. You can also learn these linearizations from data. Steve Brunton has some good materials on Koopman theory [2][3], and there are some great applications to control of systems such as soft robots [4].

[1]: https://arxiv.org/abs/1904.02539

[2]: https://youtube.com/playlist?list=PLMrJAkhIeNNSVXUvppZTYNHKQ...

[3]: https://arxiv.org/abs/2102.12086

[4]: https://arxiv.org/abs/1902.02827

Re: Functions are vectors

#42
post #34

Earlier quoted context omitted.

But the idea that two functions can be thought of operating additively on a vector - or space - seems... trivial. No, the functions are not operating on a vector, the functions themselves are vectors , which means you can do things like define a linear transformation L and then you have things like this: L(af + bg) = aL(f) + bL(g) You may also define a norm on a function space (such as an L^P space [1]), ||f||_p, whi…

Thanks. I'm trying to understand this. So take a function that returns a random shuffled deck of cards with 52! possible real number vector outputs. What is the generalized insight from treating this function itself as a vector space... is there a shortcut to monte carlo-ing a million random shuffles if you can "divide" that function by one which produces a straight flush?

[deleted]

Re: Functions are vectors

#43

Earlier quoted context omitted.

My friend, you don't even need it to be in vector space for functional analysis. Truly what is needed is just an inner product. I will grant you the inner product must be linear and hence in a vector space.

Why even require an inner product! You can get away with a lot just sitting in an Banach space (only a norm required).

I agree. The GP comment contains some inaccuracies: most of the spaces of functions considered in functional analysis do not have an inner product defined on them, but are still vector spaces. The existence of an inner product presupposes a vector space structure, but the converse is not true…

Perhaps the most famous example is provided by the Lp spaces [1] consisting of functions whose pth power is absolutely integrable. For p≥1, these spaces are Banach spaces (complete normed spaces) but it is only when p=2 that the norm is associated with an inner product.

[1] https://en.wikipedia.org/wiki/Lp_space

Re: Functions are vectors

#44
post #34

Earlier quoted context omitted.

But the idea that two functions can be thought of operating additively on a vector - or space - seems... trivial. No, the functions are not operating on a vector, the functions themselves are vectors , which means you can do things like define a linear transformation L and then you have things like this: L(af + bg) = aL(f) + bL(g) You may also define a norm on a function space (such as an L^P space [1]), ||f||_p, whi…

Thanks. I'm trying to understand this. So take a function that returns a random shuffled deck of cards with 52! possible real number vector outputs. What is the generalized insight from treating this function itself as a vector space... is there a shortcut to monte carlo-ing a million random shuffles if you can "divide" that function by one which produces a straight flush?

> So take a function that returns a random shuffled deck of cards with 52! possible real number vector outputs.

that is not a function in the (mathematical) sense that the article is talking about. a function is a mapping from a set of inputs to a set of outputs, and the same input will always map to the same output. (in programming terms it's what you would call a "pure function")

Re: Functions are vectors

#46
post #36

Earlier quoted context omitted.

Isn't this just describing a tautology? I was reading here earlier today about the naming of the constant for light as c , and I had a question which I was too embarrassed to ask. It is this: In e=mc^2 , what are the units, and if the units aren't defined and it's just a relationship, then why specify c^2? What's the point of squaring a constant, since it's just another constant? Not that I understand a damn thing ab…

Assuming this is in good faith, the units are: - c: speed of light in meters per second - m: mass in kilograms - energy: joules

yes it was in total good faith. soooo... the metric system just happens to perfectly conform to meters per second squared times kilograms equaling joules? That seems... mind-blowing since it was invented before kilograms and joules would have been interchangeable.. ??.

Re: Functions are vectors

#47
post #2

Meditating on the converse statement is also an interesting thought exercise: A vector is (just) a (cached) function (evaluation).

Indeed, many linear algebra textbooks define a tuple of real numbers as a function f: {1,...,n} -> R.

Re: Functions are vectors

#49
post #44

Earlier quoted context omitted.

Thanks. I'm trying to understand this. So take a function that returns a random shuffled deck of cards with 52! possible real number vector outputs. What is the generalized insight from treating this function itself as a vector space... is there a shortcut to monte carlo-ing a million random shuffles if you can "divide" that function by one which produces a straight flush?

> So take a function that returns a random shuffled deck of cards with 52! possible real number vector outputs. that is not a function in the (mathematical) sense that the article is talking about. a function is a mapping from a set of inputs to a set of outputs, and the same input will always map to the same output. (in programming terms it's what you would call a "pure function")

then remapping them by some arithmetic is tautological, isn't it?

Re: Functions are vectors

#50
post #36

Earlier quoted context omitted.

Assuming this is in good faith, the units are: - c: speed of light in meters per second - m: mass in kilograms - energy: joules

yes it was in total good faith. soooo... the metric system just happens to perfectly conform to meters per second squared times kilograms equaling joules? That seems... mind-blowing since it was invented before kilograms and joules would have been interchangeable.. ??.

If you express it in a different unit system all E, m, and c will take different numerical values, but the relationship will still be true.

So there’s nothing special about the metric system. When we want to discuss this kind of relationship without reference to human convention we talk about a quantity’s dimension (not geometric like 3D). A Meter and a foot both have dimensions of length. c has units of length/time. 1 kilogram and 1 gram both have units of mass. And so on.

https://en.wikipedia.org/wiki/Dimensional_analysis

Post reply on HN