News for hackers. Stuff that matters.
Re:I Should Have Loved Electrical Engineering by dfawcus on Thursday September 04, 2025 @10:03AM (#45127402)
Yeah - there was a massive filtering of the students between the 1st year entry, and the second year at my Uni. Largely down to people unable to handle the (not terribly) complex maths at that stage.

I knew a number of folks in the first year who were very good at practical electronics, having come in from a technician side, but simply gave up due to the heavy maths load.

It got more complex when doing Control Theory, what with Laplace and Z transforms, freq domain analysis, and the apocryphal Poles and Zeros.

Further culling ensued at that point.

Re:I Should Have Loved Electrical Engineering by Eggpants on Thursday September 04, 2025 @11:46AM (#45128577)
I went into EE wanting to learn how to design CPU’s and thought the analog side would be boring.

However, control theory turned out to be my favorite class. Learning how negative feedback loops are everywhere was an eye opener.

Also learning Laplace transforms was one of my first “holy shit this is freaking clever and cool” moments. Just like how parity bits in data streams can be used to detect AND correct errors.

Re:I Should Have Loved Electrical Engineering by buildbot on Thursday September 04, 2025 @12:13PM (#45128876)
Same on the laplace transforms. I was kinda mad we had learned any other way. It was a lot easier than whatever we were doing before mathematically!

I wonder, how much control theory is there in CPU?

Re:I Should Have Loved Electrical Engineering by zhemao on Thursday September 04, 2025 @03:11PM (#45131071)
In computer architecture / digital ASIC design there's zero control theory. There's not much mathematics in general.
Re:I Should Have Loved Electrical Engineering by dreamcompiler on Thursday September 04, 2025 @07:04PM (#45133238)
There's Boolean algebra but no control theory is needed for logic design.

One minor caveat is that most CPUs nowadays contain phase-locked loop (PLL) clock multipliers. Those fall into the domain of control theory but strictly speaking they're not part of the logic.

Re:I Should Have Loved Electrical Engineering by uxp100 on Friday September 05, 2025 @08:55AM (#45137975)
And in my inexpert experience, they are IP developed by the fab. So if you are doing CPU design work, you may need to understand PLLs well enough to read a datasheet, but you will not need to design a PLL.

I maybe had the most trouble just figuring out which instantiated PLL in the chip belonged to which PLL design, and where someone stuck the documentation in the giant repo. Especially since a hardware designer may think, oh we don’t need to update the docs, “nothing changed,” but the PLLs did change names because of a process change and their parameters may have changed slightly, even if they’re essentially the same. And chasing down small changes and documenting them ends up being a lot of the job in software.

Re:I Should Have Loved Electrical Engineering by choilive on Thursday September 04, 2025 @12:51PM (#45129325)
Control theory was also one of my favorite classes that a low of software people should learn (at least the very basics). So many hand rolled heuristically driven if/else type systems that can simply be replaced more reliably with a PID.
Re:I Should Have Loved Electrical Engineering by Karrot_Kream on Thursday September 04, 2025 @04:46PM (#45132020)
I've played around with this over the years in my career but have found that tuning PID loops is very tricky, much trickier than creating a soup of if/else clauses and much less auditable to those who don't understand the math.
Re:I Should Have Loved Electrical Engineering by lll-o-lll on Thursday September 04, 2025 @05:46PM (#45132591)
PID is standard in the industry, but the reality is it is infinitely easier to model in the discrete domain. The z-plane if math, but you don’t really need much math. Just model like a games developer. Simulate with a bit of JS or python. Add the motor saturation! Play with feedback and disturbances.

I just think this gives much better results. The model can be as simple or complex as you need, and we aren’t trapped in the linear response range. PID is good enough for many tasks, but it’s never good.

Re:I Should Have Loved Electrical Engineering by dreamcompiler on Thursday September 04, 2025 @07:14PM (#45133301)
Yes, but...

If you can model your problem with linear differential equations then control theory replaces the need for tuning. The coefficients you need just pop directly out of the analysis.

Re:I Should Have Loved Electrical Engineering by Karrot_Kream on Thursday September 04, 2025 @08:15PM (#45133698)
Maybe I should add more context. I have specifically tried applying PID style feedback systems to computational problems, not controllers that interface with hardware, circuits, etc. The place I found it to work the best is with designing a homegrown autoscaler years before k8s ever became a viable thing for a company to play with [1]. Most of the problem domains I applied it to do not have linear models that can effectively model the theory. Yes I know that a PID is only proven to be stable when working with linear systems, but this is the reality of the problems I've worked with.

Eventually when if statements stop working I found that decision trees work great and XGBoost continues to be a great iteration of a decision tree.

[1]: I was an early hire at a tech unicorn and we built an autoscaler pretty early into the company's tenure. While it was a great success for a long time once k8s became established in the industry we had a really hard time training new talent to it and I left as we began a massive company-wide effort to move our workloads onto k8s.

Re:I Should Have Loved Electrical Engineering by lll-o-lll on Thursday September 04, 2025 @05:26PM (#45132403)
Absolutely the worst control systems of all time have been written by software engineers that don’t understand control theory. The second worst control systems are designed by those who only know the PID heuristic, and can’t be bothered to model a little non-linearity from motor drives saturating.
Re:I Should Have Loved Electrical Engineering by imtringued on Friday September 05, 2025 @07:06AM (#45137232)
The biggest problem with PID control is that the integral term performs double duty as both a signal that accumulates small errors to minimize the steady state error, but also as a signal that shows deviation from the target due to unmodeled constraints.

It should be pretty obvious that you cannot overcome constraints by moving even harder in the direction of the constraint, which is what the integral term does.

Re:I Should Have Loved Electrical Engineering by HeyLaughingBoy on Thursday September 04, 2025 @01:40PM (#45129968)
I never really "got" control theory until about 10 years after graduation.

I was working as an SW Engr and taking a set of courses towards a Mechatronics certificate (my employer did a lot of motion control work) and I had to basically take updated versions of the same classes. The lab instructor was an about-to-retire engineer from Schunk, and he did an amazing job of explaining what the theory meant in terms of real-world behavior. That's when it all finally sunk in and I could look at the math and "see" how a mechanism would respond.

Re:I Should Have Loved Electrical Engineering by dreamcompiler on Thursday September 04, 2025 @07:08PM (#45133267)
Agreed on the Laplace transforms. They instantly turn linear differential equations into basic high school algebra problems. But they don't work for nonlinear problems.
Re:I Should Have Loved Electrical Engineering by harrall on Thursday September 04, 2025 @10:04PM (#45134327)
I remember when I first learned calculus and holy shit that was cool already. Then it kept getting better and better as I learned differential equations, linear algebra, etc.

To me EE = heavy math and that’s what makes it so fun.

I actually do software now but it’s completely different. There’s like no math in most applications of it. Putting something together with a Rasp Pi or Arduino feels like 98% software and 2% EE.

Re:I Should Have Loved Electrical Engineering by underlipton on Thursday September 04, 2025 @03:32PM (#45131315)
I sometimes wonder if math suffers from a bit of basketball syndrome. That is, I'm sure there are dozens of potential Muggsy Bogues-esque players out there, but the game's meta continues to drift ever towards who coaches and trainers know how to coach and train, which is tall dudes.

There might be a structural issue if you have a bunch of guys coming in from the technician side, as you say, who almost all get filtered out. You might need remedial classes, a different curriculum progression, something. Or else recruitment standards/expectation-setting are wacked-out.