News for hackers. Stuff that matters.
Re:An open source, educational, low-cost modern analog computer by pkaye on Friday June 02, 2023 @05:26PM (#36170965)
I'm wondering if Modelica might be useful for this. Its an open source modeling language though I've never used it. Its basically writing models with differential equations for each of the components and then connect them together to form a system.

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

Re:An open source, educational, low-cost modern analog computer by GeorgeTirebiter on Friday June 02, 2023 @09:46PM (#36172915)
I have used https://openmodelica.org/. It's another one of those "invest substantial time understanding what they are doing, and you will likely be rewarded." Simple things are simple, but I found it took longer than I would have like to bang out e.g. a PID algo with a particular motor and load. If you want to try this, buy the book, and follow it to the end. Then keep learning, as you build more and more sophisticated simulators.
Re:An open source, educational, low-cost modern analog computer by ChrisRackauckas on Saturday June 03, 2023 @11:48AM (#36177605)
I'd argue that acausal modeling is much easier for circuit design. And there's quite a bit of research, including surveys of experts, that backs it up as well. I recently put out a video exactly on this topic that summarizes some of the research and shows some examples to this end (https://www.youtube.com/watch?v=ZYkojUozeC4). Acausal modeling definitely isn't something that is taught in most (American) engineering schools, but once you get the brain flip it pretty clearly can improve productivity, no matter which acausal modeling language is used.
Re:An open source, educational, low-cost modern analog computer by mk_stjames on Saturday June 03, 2023 @02:19PM (#36179125)
Responding at the bottom of the thread here, and also just to say Hi to Chris above.

So in my top level I mentioned Simulink as a nice path for students to learn modeling circuits, and in a way then could use this path to simulate what an Analog computer such as that in the original link is running.

My early forays into numerical simulation and linear systems modeling were thru Simulink, and I've built models of some very big systems in Simulink and used them in the design process of various things- typically vehicles, automotive systems; modeling powertrains, electro-hydraulic controls, EV drive cycle range simulation, etc. That was all many years ago.

I then went down the path of learning a bit of OpenModelica and as I was intrigued by the acausal approach and the open source aspect. Like anything the learning curve was steep (steeper than simulink) and I never got past a lot of clunkiness.

Then I discovered Julia a few years ago and even though I've moved on to other work, I've followed how people using Julia are modeling and solving closely, and what Chris says about how building acausal systems can be easier, and the benefits seen in ModelingToolkit.jl combined with the full Julia ecosystem all rings so true. I'm really excited to eventually see a full on acausal, block-based, yet easily extendable Simulink competitor sprout from Julia devs because as it does it will be the killer app for the language for a lot of engineers, IMO.

Funny enough, now Mathworks implements an acausal modeling approach in the Simulink GUI domain with their 'SimScape' add-on, but I have not gotten a chance to use it.

Anyway, yeah I need to get a project going to utilize some of the latest happenings in Julia modeling, and maybe find a way to contribute. Cheers to you and the other devs, Chris!

Re:An open source, educational, low-cost modern analog computer by ChrisRackauckas on Saturday June 03, 2023 @11:45AM (#36177582)
The creators of Modelica, Hilding Elmqvist and Martin Otter, work in Julia these days so there's been a boom to the development of acausal modeling tooling in Julia. They built https://github.com/ModiaSim/Modia.jl and then we collaborated with them on some ideas to build ModelingToolkit.jl (https://docs.sciml.ai/ModelingToolkit/dev/). The latest versions and experiments in OpenModelica are now targeting ModelingToolkit as a compilation backend, which gives a pathway for legacy Modelica code to be used with the MTK ecosystem. The OpenModelica community has always been a very small group in comparison to the Dymola compiler team and so the open part of Modelica never really caught on, but we hope to help them piggyback off of our compiler to get it there. We'll have a workshop on this collaboration in Linköping next February if you're interested in the details.