4

Ask HN: How to learn math from zero for adults?

 1 year ago
source link: https://news.ycombinator.com/item?id=31539549
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

Ask HN: How to learn math from zero for adults?

Ask HN: How to learn math from zero for adults?
134 points by stArrow 7 hours ago | hide | past | favorite | 41 comments
I am a 26 year old learner who is really into Machine Learning. But my lack of understanding in math has held me back. Skipping and hating math classes in high school have been my biggest regret.

Now, I am slowly trying to learn, but I don't know where to start. I need some guidance.

I was a C student in high school. I never took a math class beyond basic algebra. I started from Khan Academy's first exercise when I was 33 years old. It seems silly looking back that I was solving problems on the number line as an adult.

At that time, around 10 years ago, Khan Academy had excellent coverage through trigonometry and single variable calculus. Once I reached that point I went to my local community college and took all of their math classes. I transferred to University of Illinois at Urbana-Champaign and continued onward to get a BS CS, BS EE, and MS EE. I finished at 41 years old and landed a dream job that I would have never thought possible when I started.

I guess my advice is to start from the beginning and see where it takes you.

s.gif
Mate, you've no idea how much I could related to your story. I've a bachelor degree in Electrical Engineering. Looking back at those subjects, I feel like I didn't have the maturity needed to appreciate the depth and meaning of it. I was too busy just passing exams and working to get a degree and eventually land a job. I did that and I have no regrets. But those concepts taught to us are the foundations of almost everything. The more I think about it the more respect I have for scientists who came up with those before 1950s! They had nothing and they solved their own questions. Bloody legends.
s.gif
Above is not advice but I would echo it, with emphasis that higher education makes much more sense when you go there as an adult with other stuff to do outside of it so uou just focus on learning things.
s.gif
>It seems silly looking back that I was solving problems on the number line as an adult.

I study biostatistics and dabble in population genetics research. I still resort to number lines and venn diagrams frequently. There is a reason we teach number lines - they are very useful!

s.gif
Wow. I was going to come here and suggest them as well but your story does an even better job. Congrats to you and all the hard work you must have put in over the 10 years!
You don't say how much you already know.

Your first stop would be Khan Academy and knowing your gaps.

Fill your gaps.

Learn HS level Calculus, Linear Algebra, and Statistics.

You will need more Calculus and Linear Algebra later. But not now.

Then try studying "Machine Learning for Absolute Beginners" book. It not very mathy.

Then just keep going through ML courses. Learn what you need on the way.

The "way" of math needed in Machine Learning is not the same "way" that brings you scores in school/college exam.

You need absolutely crystal clear concepts in Linear Algebra, Multivariable Calculus, and in some areas of ML, Statistics.

Corporate "Data Science" and Machine Learning research/projects are wildly different beasts. Learn what you will pursue, and decide your path based on that.

And most importantly, you have to be patient. Machine Learning and Math for it takes time- not days or weeks, but months and years.

What helped me get a grip on learning mathematics was learning to prove theorems.

Working through Daniel Velleman's book "How to Prove It" (the only pre requisite is that you can understand boolean logic, which programmers have no problem with), and then a Set Theory book (I used Enderton) set me up to tackle (proof based) Linear Algebra, Analysis etc.

Just my personal experience. Hope this helps.

s.gif
I think theorems already presuppose some basic understanding of algebra, but I might be wrong.

It really depends on what OP actually knows and how deep he wants to learn and in what direction

I'm in my 40s and I started a machine learning degree in Nov 2020, so it's been about 1.5 years for me till now. I am a slow learner and my recommendations may reflect the same.

1) Maths (precalculus and calculus) - I started with Khan Academy 10th grade onwards. I finished till grade 12 in a week. By this time I had gone through content elsewhere, so 1 week may (not) be enough. Regardless, Khan Academy app comes highly recommended.

I did realise that there were a few gaps (more basic in nature), I covered those with Eddie Woo on YouTube (e.g. why is zero factorial 1). For others I just looked up relevant searches online.

2) Maths (calculus) - MITs videos on YouTube. That is the pace of content I really love. Lots of overlap with Khan academy calculus, but do go through both. Also 3blue1brown "essence of calculus" playlist.

3) Maths (Basic Linear Algebra) - although if someone were to say Gilbert Strang's MIT videos, they would be bang on perfect, I had to start slower. Bingewatch (with popcorn and beer) 3blue1browns "Essence of linear algebra" on YouTube. Then move ahead to the channel "Math the beautiful" which has a slower pace. You would also wish to visit their website www.lem.ma where they have exercises. Then of course come back and start Prof Strang's lectures (you're delving into heavier stuff midway through his course).

4) Statistics - hands down professor Leonard on YouTube, he is the statistics equivalent of Eddie Woo. Slow, smart, funny and he has biceps too ;-) After this Prof Tsitsikilis (MIT) on YouTube.

It goes without saying that you'll need to practice problems (ironical, coming from me). You can download question sets of your country from online.

5) When you've done the above, your search for "linear algebra" and "calculus" on HN will yield a lot of lovely results. Hidden gems will be there in comments too. Check those books, interactive books, websites, etc out. Your pace will be good by this time, but you will occassionally come across something which you have not come across before.

If there's anything else, feel free to ask.

The “Mathematics for the Practical Man” series, although old, might be a good resource to consider. These are the titles I know are out there:

- “Mathematics for the Practical Man” - “Arithmetic for the Practical Man” - “Algebra for the Practical Man” - “Geometry for the Practical Man” - “Calculus for the Practical Man” -> this last one was the one Richard Feynman used to teach himself calculus (https://physicstoday.scitation.org/do/10.1063/PT.5.9099/full...)

good luck!

I did this. I had to start with the absolute basics (what is a factor). The best approach was getting Schaum's books like Precalculus and doing all the problems and then supplementing with Youtube videos. I found that doing it in the morning and learning one concept a day instead of all at once helped me to make progress & consolidate what I learned. Unfortunately this is also a slow approach.
High-school dropout with a phd in a social science here. My grades weren’t good enough to study math during undergrad and I was dealing with a chronic illness that meant I didn’t have my shit together enough to transfer into a useful degree either. I’m a machine learning scientist at a company you’ve heard of and probably spent money on (not FAANG). Math is a big part of my day job.

Here’s what I did to learn math. I wouldn’t recommend this path. You will have a much easier time getting a job with a quantitative degree. You’re only 26, so you can go back to school without really losing much time. If you must do it this way, do the exercises, do the exercises, do the exercises, build a portfolio, and do the exercises.

Calculus/Analysis

Stewart single var calculus, then the multivar book. These are easy starters

Real analysis: Series, Functions of Several Variables, and Applications. Miklós Laczkovich, Vera T. Sós

Spivak Calc and Calc on Manifolds books

Bonus: Advanced Calculus A Geometric View, Callahan. This is what I turn to when I want to punish myself or remind myself how certain analysis proofs go.

Linear Algebra

Strang, Intro to LA is great. Start with this one

Strang, LA and learning from data. Will be tough without the first book

Stats

Hogg, Introduction to Mathematical Statistics

Gelman et al, BDA3 for Bayes

Bishop PRML and Elements of statistical learning. Do the exercises. Build the algos in Python.

Run through the math on Khan Academy to fill in your gaps for at least Algebra I, II and Precalculus. Then you need to Calculus I-III, Linear Algebra and basic Statistics which are also on Khan Academy.

Also I have created some youtube channels aggregating quite a bit of the quality university courses organized into playlists of playlists.

https://youtube.com/channel/UCjgQ2pJDjZlhdI4Ym7NQdUw

Note: You have to click on the titles of the topics on the home page that slide left/right (or up/down on a phone) to see the whole list of courses because YouTube truncates the lists on the home page.

Maybe I'm conceited but I think curiosity should guide you. Obviously something about ML inspires you. Envision what you want to achieve and fill the gaps as you go. Yes, there are more or less optimal ways to learn, but maybe it's more important to keep the fire alive than to push through quickly. The harsh truth is that maybe you still harbor an aversion for math. Most ML practitioners have dark spots, that's fine. But you need a genuine interest to navigate.
Once we're outside a formal academic setting, the way to start learning is to start learning.

The first high hurdle is accepting that starting out everything (to a first approximation) is over our heads.

There's no perfect first resource because hard subjects are hard and take time.

But because we are out of school, we have decades to learn.

There's no final in sixteen weeks and only a pop-quiz tomorrow if we are in the middle of applying what we learned.

So just start learning math and figure out what works for you as you go along.

Good luck.

Check out ossu/math. Good list of resources and community on discord https://github.com/ossu/math or ossu/datascience has suggested math prerequisites for data science https://github.com/ossu/data-science
Everything that can be learned can be studied through some mix of these techniques:

1. Rote learning/memorization. Copying, tracing, flash cards and so forth. This is how you learned to read and write, and while in school math it tends to be applied to calculation(memorizing results from adding and multiplying and so on) it can also be applied to build up recall of mathematical concepts like postulates and theorems.

2. Logic and problem solving strategies. Math "homework" is usually about finding a result through a mix of deductive, inductive and abductive strategies. When the result is calculation-focused it becomes very mechanical and "follow the steps you've memorized", and so can usually be delegated to a computer program now, but higher level math is more about integrating the concepts together to prove something is correct, which means having a really clear understanding of the definitions you're working with.

3. Dividing and conquering. Sometimes it's hard to see a concept in totality but you can understand a particular limited context and then generalize on it. This is typically where math research starts: there's a flash of insight into a concept and then progressive attempts to generalize it and reuse it to solve more problems or define its relationship to other concepts, like how there are multiple ways to define coordinate systems in geometry.

When reading a math text, it can be hard to get started because skimming the text doesn't really grant any access to the concepts: you have to follow through on internalizing them first, which means a mix of the rote learning and posing problems for oneself to solve, and looking for analogies in things you already know to find the differences and so gain more detailed understanding. By the time you've done that, you probably have read the same words hundreds of times and "slept on the problem" for weeks.

This quality of not really understanding math until you've grappled with the problems means that research mathematicians tend to only have a really detailed understanding of their own specialty, but have a more limited background in others, enough to communicate a little bit but not necessarily participate in the discussion substantially. To get "there", look at what's offered in college courses: you can reuse their textbooks and problem sets. Following an online course is also a valid method. You don't have to attend classes or lectures to study math, although sometimes you may want to ask questions to clarify - but the internet exists for that and lots of people are willing to help, at least up until you actually get to a research level problem.

I went a similar route. What did it for me was conceptual analysis. You know how to program already. Maybe you did object oriented analysis? Once I understood, that creating a sample space can be understood as creating a class of the samples you expect, and then putting the attributes on an axis of a space, it clicked. Depending on the space, you then can visualize the outcome probabilities as weight of a point or area in the space. A random variable is then a mapping of that space to R etc. Or that differentiation is basically a way to get the slope of a function’s tangents at any point (it is differentiation of a function!) and its converse, integration, helps you find the area under a function graph. The important point is here that many interesting points can be mapped to doing this (for example calculating the probability from A to B, if you decided to represent it as area). I had worked with UML, OPM (object process methodology) and BFO (basic fundamental ontology) before. Asking “what is it (attributes, parts) and what can I do with it helps me a lot. The most important trait however was coping with frustration, sometimes it took me months to understand a concept.
Since you mentioned ML, I assume you'll need linear algebra (LA). I hated it for a long time since the notation abstracts away too many things. You can look at an equation involving matrices, but you cannot imagine how it would be coded. Unlike calculus where numerical approximations and code implementations are relatively obvious.

But I eventually needed to learn it as I have to code something not in Python/Matlab/etc as part of an app and would like to postpone using LA libraries unless absolutely needed for performance. What helped me get the grips on LA is Jeff Chasnov's lectures on youtube and Mike Cohen's book. I would also recommend 3blue1brown for appreciation, if he happens to cover the topic you wish to dive into.

I'm many years older than you, by the way.

I’m in this boat as well. I dropped out of first year university some years ago and have subsequently forgot all the higher level math that I spent years learning. I can’t even understand the notation which used to be so familiar.

From my experience you have to start from scratch since some concepts are foundational and will block progress later if you don’t know them.

I have started with Khan Academy just answering questions on my phone. It’s a grind but I do it later in the day when my cognition is reduced. I imagine later on I will have to get a tutor.

This is a good map of Mathematics to get an overview of where you can go... https://www.youtube.com/watch?v=OmJ-4B-mS-Y

Then Giles McMullen-Klein has an awesome recommended list for data science (your mileage may vary). https://www.youtube.com/watch?v=V2aIDbpESyU

KhanAcademy and 3blue1brown (https://www.youtube.com/c/3blue1brown/playlists). Remember, it will take time. It won't be fast. Especially if you really want to understand ML algorithms.
Khan Academy is a pretty solid starting point. There's also a lot of great stuff on Youtube. I'm a fan of a Professor Leonard. He covers from pre-algebra through differential equations.

https://www.youtube.com/c/ProfessorLeonard

I would say err on the side of too easy to begin with. Start with textbooks for high school (that you skipped). And master that before moving on.
I neglected math a lot in HS too and tried the Khan Academy route, but figured out over time that you really can find your gaps and fill them on demand by focusing on the work you want to do.

I wouldn’t discourage you from trying a more comprehensive approach to building a great foundation in math. Math is awesome and if you enjoy it, go for it. If you want to stay focused on ML, you might do alright by figuring out what you need as you go. Just walk back from each problem until you find your bearings, then dig in.

Math is huge and you could find it takes forever to arrive at the skills you need to do the specific thing you want to do.

I always recommend courses on Udemy, Coursera, etc. Anywhere you have to pay for the knowledge. The money seems to be an important filter for quality. Not always, and there are certainly exceptions, but in my experience, it's highly predictive of useful knowledge.
Browsing https://math.stackexchange.com/questions can be a nice way to learn math notation and to see which math topics you find interesting.

(also, occasionally a question or answer will be so good you'll instantly grok the math concept even if you haven't learned it formally before; it's rare but magical when it happens).

why do you need math for machine learning? Code first, learn the math as you go. Otherwise, you will learn a bunch of math you don't need when your actual goal is machine learning.

Do you know pandas and scikit learn? If not, start there.

There are a lot of great introductory mathematics courses available at coursera.org[0] for free, without the certification.

See this thread[1] for a list of great math book resources.

[0]: https://coursera.org

[1]: https://news.ycombinator.com/item?id=30485544

khan academy is the best for ANY age. Start from basic algebra and progress through trig, geometry, calculus 1,2,3 and linear algebra, and you'll be fine. That's what I did. Should take a few months depending on work ethic
The MIT online lectures are amazing. I can't recommend them more highly. They got me through an engineering degree.
I would advise you to download[1] free maths class 10,11,12 books which is taught to indian students. They are well written, covers calculus, lots of exercises to practice as well to test your knowledge.

[1] https://ncert.nic.in/textbook.php?kemh1=6-16

Asess where you are. Define goal(s) as per comments below. And start the heck climbing a hill. Good luck.
I'd recommend going through the Khan Academy curriculum and filling your gaps - only study the topics you are struggling with. Once you do that, I'd suggest studying this https://teachyourselfcs.com/#math
Read the "mathematics for machine learning" book.

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK