Not really, because a lot of summations also go to infinity. Integrals are continuous compared to the for-loops discrete nature, so there's no direct analog for them in programming (that I'm aware of)
Well its summing up infinitesimally small units of something typically. They can be approximated by making the "infintesimally small units" larger (and thus discrete).
It's not really possible to do in a for loop because you wouldn't use a for loop usually without some other domain beyond a monotonically increasing counter. Most integrals I've come across in programming involve some sort of time domain so you are just taking the delta as the discrete period and summating those (which I guess is the same as just summating any arbitrary linear function to describe the curve of the integral). I mean you still only have the resolution of your timer but it usually is within whatever you're trying to accomplish in accuracy.
The biggest issue with calculus for most people is that it is taught in an abstract way. That's math in general though. I didn't really understand calculus until I took physics where I had real world applications for calculus.
I later took a scientific computing class where we revisited sums, series, methods, etc. and wrote code (matlab) that applied these concepts. And sure, a lot of these concepts have functions built into Matlab, but the point was to show how these functions work, what their shortcomings are, and how to determine when an approximation is good enough (ie how many steps into Taylor's series are required and when does more steps give no additional benefit).
Exactly. A minority of us enjoy abstraction for the sake of abstraction. A good teacher will try to motivate the abstract concepts with real life examples that speak to the student. I'm lucky to have been blessed with absolutely great math teachers until I reached university (I'm still upset at my integral calculus teacher in college who spent an entire 90m lecture deriving the fundamental theorem of algebra on the board to "explain" partial fraction decomposition, before telling us he did it for fun and we didn't have to know any of it for the purposes of the course).
As someone who did math first and programming later and has also been a teacher, it would never occur to me to teach it this way. I do not understand why this is any simpler than teaching it as repeated addition.
In this case it just helps me conceptualize it as something that makes a little more sense. Code makes more sense to me than math as I'm not great at math, so it's basically just taking a concept and converting it to something I would understand better.
I mean in these two series, particularly the summation, it's easy enough and I don't think I had any struggles there. I did, however, have struggles with your higher-level series dealing with more complex subjects such as a Ramanujan series. I didn't understand Ramanujan at all until I had a programming course ask me to write one, and then it actually made a good bit of sense.
998
u/nuclearslug Oct 06 '21
This would have been so helpful when I was talking calculus