Author Topic: Which is more complex - car or an operating system?  (Read 5732 times)

0 Members and 1 Guest are viewing this topic.

Offline daqqTopic starter

  • Super Contributor
  • ***
  • Posts: 2321
  • Country: sk
    • My site
Which is more complex - car or an operating system?
« on: June 02, 2020, 10:55:41 am »
Hi guys,

There has been a philosophical discussion here as to which is more complicated - a modern car or a modern operating system (let's go with Windows)? I know that 'complicated' is not an exactly measurable quantity, but I'd say you can compare two items.

My guess would be that an operating system needs to be more complex and will have to account for more complicated interactions, whether or not it's within itself or with the outside world. At tens of millions of lines of code for itself, it has to play nice with itself as well as third party stuff, while at the same time maintaining compatibility with a load of historical baggage. Add to that the demand that it runs usably on pretty much anything from an ancient brick with buttons all the way up to an overpowered workstation that 20 years ago would have been categorized as a supercomputer with dozens of cores... and with hundreds of new security issues popping up every year... add to that needing to deal with third party software and hardware bugs... adding new features and hardware support on the fly...

In terms of the amount of developers needed, I read somewhere that the Windows 7 group had around 10k developers working on it. I'm not sure as to the veracity of the information, but sounds in the right ballpark. I've no clue as to how many people are needed to design, say, a Tesla or a WV car.

What's your opinion?

Thanks,

David
Believe it or not, pointy haired people do exist!
+++Divide By Cucumber Error. Please Reinstall Universe And Reboot +++
 

Offline RoGeorge

  • Super Contributor
  • ***
  • Posts: 7011
  • Country: ro
Re: Which is more complex - car or an operating system?
« Reply #1 on: June 02, 2020, 11:00:31 am »
Modern cars have at least one operating system, plus many other systems, so car is more complex than an operating system.   :-//
Q.E.D.

Offline greenpossum

  • Frequent Contributor
  • **
  • Posts: 408
  • Country: au
Re: Which is more complex - car or an operating system?
« Reply #2 on: June 02, 2020, 11:01:23 am »
Wife :-DD
 

Offline Rerouter

  • Super Contributor
  • ***
  • Posts: 4705
  • Country: au
  • Question Everything... Except This Statement
Re: Which is more complex - car or an operating system?
« Reply #3 on: June 02, 2020, 11:13:30 am »
Cars and trucks usually have less total software complexity, but that is somewhat required to still be able to review and test for edge cases, its one of the few industries where its not easy to "just patch it after release"

Each module is very built for purpose, meaning there is not much generalized code, take a normal ECU, most times the ROM image is in the ballpark of 256MB or less,

The main horrible mess of complexity can be found in the "infotainment" system, e.g. the radio and all the other crap that gets packed in there, more often than not they literally run on linux, and are bodge upon bodge upon bodge, but as certain parts will be stripped down for size, likely puts it at less than a fully featured OS.

Think of it like everything but the radio is usually akin to a large microprocessor written with embedded code, the radio is like a raspberry pi with enough hats to scrape the ceiling.
 

Offline artag

  • Super Contributor
  • ***
  • Posts: 1281
  • Country: gb
Re: Which is more complex - car or an operating system?
« Reply #4 on: June 02, 2020, 12:05:24 pm »
Yes.

Sorry. Absurd question. We have no reasonable way to measure complexity in a consistent way across disciplnes, so the question is as meaningless. Apples and Oranges, as we say.
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4987
  • Country: gb
Re: Which is more complex - car or an operating system?
« Reply #5 on: June 02, 2020, 01:33:00 pm »
The answer is quite easy to supply.

If L = How long is a piece of string. Lc, Los being the respective pieces of string.
Qc = Complexity factor of a Car
Qos = Complexity factor of an OS

So, assuming a 9th order, string theory of complexity, of the Q's.

Qc - Lc = Qos - Los = 0.64649467388363882562943573

So, in summary, they are BOTH very (opinion/specs dependent) complicated beasts.
 

Offline SiliconWizard

  • Super Contributor
  • ***
  • Posts: 15794
  • Country: fr
Re: Which is more complex - car or an operating system?
« Reply #6 on: June 02, 2020, 02:46:35 pm »
Modern cars have at least one operating system, plus many other systems, so car is more complex than an operating system.   :-//
Q.E.D.

Indeed. That makes the question sort of moot as it is.

Now if course, not all OSs have equal overall "complexity". A full Windows distribution has far more software complexity than a typical RTOS used for some subsystems in cars. Even a Linux(or QNX)-based OS used for UI in modern cars is less "complex" than Windows. So it can't be answered in a simple way.

As to the total number of engineers involved in a typical car project, don't underestimate it. All car vendors than I know of (even Tesla, which develops a lot of in-house stuff) use MANY third-party subsystems. It's very hard to estimate how many people in total could have possibly worked on all subsystems composing a given car. Not unlikely to be in the thousands, if not tens of thousands overall.
 

Offline RoGeorge

  • Super Contributor
  • ***
  • Posts: 7011
  • Country: ro
Re: Which is more complex - car or an operating system?
« Reply #7 on: June 02, 2020, 03:15:58 pm »
Oh, well, if by "complex" you mean cumbersome, then yes, nothing can beat Windows, except maybe what greenpossum said.   ^-^

Online ejeffrey

  • Super Contributor
  • ***
  • Posts: 4031
  • Country: us
Re: Which is more complex - car or an operating system?
« Reply #8 on: June 02, 2020, 04:08:34 pm »
It is hard to compare quantitatively, but as far as I am concerned qualitatively computer hardware systems are generally orders of magnitude more complex than the mechanical parts of cars, airplanes, rockets, etc.  And the software systems that run on that hardware is orders of magnitude more complex again.

Of course as mentioned cars have computers in them -- lots of them, and they are the most complex part of the car.

I am assuming what I consider a relatively non-controversial intuitive idea of complexity: that things with more distinct valid states, more unique elements, more constraints, more variables, etc. makes things more complex.  There is actually a quantitative way to capture this, the kolmogorov complexity but it is theoretically impossible to calculate in almost all cases. 

One question you would want to answer when looking at embedded or special purpose computers is whether to count the internal complexity or only the functional complexity.  Compared to a desktop computer the job of an ECU or even an in-car infotainment system is very simple.  Yet that infotainment system may run a full fledged general purpose OS underneath with a huge amount of functionality unused but available. 
 

Online nctnico

  • Super Contributor
  • ***
  • Posts: 28429
  • Country: nl
    • NCT Developments
Re: Which is more complex - car or an operating system?
« Reply #9 on: June 02, 2020, 04:57:41 pm »
It is hard to compare quantitatively, but as far as I am concerned qualitatively computer hardware systems are generally orders of magnitude more complex than the mechanical parts of cars, airplanes, rockets, etc.  And the software systems that run on that hardware is orders of magnitude more complex again.
I tend to disagree. It is just that car technology has been around longer and it is highly optimised to offer reliability at cut throat prices. Take something like hydraulic disc brakes for example. They look so simple but I'm very sure you can spend several person work-years to engineer them from scratch to the same level of reliability and simplicity.

A Youtuber called Muntz (or so) takes cars apart and analyses the construction methods. His videos about Tesla cars show how complicated it is to engineer a car (besides the electronics) and what incremental improvements Tesla has made in the past years.
« Last Edit: June 02, 2020, 05:13:18 pm by nctnico »
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline schmitt trigger

  • Super Contributor
  • ***
  • Posts: 2431
  • Country: mx
Re: Which is more complex - car or an operating system?
« Reply #10 on: June 02, 2020, 05:11:58 pm »
Let's take a single large subassembly on a vehicle: the transmission.

Modern, 8, 9 and 10 gear automatic transmissions on themselves are so spectacularly complex, that there are only a few companies that can design and build them.

Even companies like Ford and GM had to form an alliance to design the latest automatic transmission for their trucks, as the development cost was above a billion dollars.


 

Offline themadhippy

  • Super Contributor
  • ***
  • Posts: 3264
  • Country: gb
Re: Which is more complex - car or an operating system?
« Reply #11 on: June 02, 2020, 05:14:16 pm »
from a long time ago

If GM had developed technology like Microsoft, we would all be driving cars with the following characteristics:

1. For no reason at all, your car would crash twice a day.

2. Every time they repainted the lines on the road, you would have to buy a new car.

3. Occasionally, executing a manoeuver such as a left-turn would cause your car to shut down and refuse to restart, and you would have to reinstall the engine.

4. When your car died on the freeway for no reason, you would just accept this, restart and drive on.

5. Only one person at a time could use the car, unless you bought ‘Car95’ or ‘CarNT’, and then added more seats.

6. Apple would make a car powered by the sun, reliable, five times as fast, and twice as easy to drive, but would run on only five per cent of the roads.

7. Oil, water temperature and alternator warning lights would be replaced by a single ‘general car default’ warning light.

8. New seats would force every-one to have the same size butt.

9. The airbag would say ‘Are you sure?’ before going off.

10. Occasionally, for no reason, your car would lock you out and refuse to let you in until you simultaneously lifted the door handle, turned the key, and grabbed the radio antenna.

11. GM would require all car buyers to also purchase a deluxe set of road maps from Rand-McNally (a subsidiary of GM), even though they neither need them nor want them. Trying to delete this option would immediately cause the car’s performance to diminish by 50 per cent or more. Moreover, GM would become a target for investigation by the Justice Department.

12. Every time GM introduced a new model, car buyers would have to learn how to drive all over again because none of the controls would operate in the same manner as the old car.

13. You would press the ‘start’ button to shut off the engine.
 

Offline JPortici

  • Super Contributor
  • ***
  • Posts: 3573
  • Country: it
Re: Which is more complex - car or an operating system?
« Reply #12 on: June 02, 2020, 05:43:59 pm »
Cars and trucks usually have less total software complexity, but that is somewhat required to still be able to review and test for edge cases, its one of the few industries where its not easy to "just patch it after release"

you would be suprised :(
we also have a mechanic workshop and in the past few years many of the newer, higher end volvo and audi we serviced suffered from serious bugs in the transmission and lightning ecu. Customer would be asked to go to the dealer at least once every few weeks to update the ECUs
serious bugs meaning the gear will refuse to change, switch off / back on or that the whole rear lights would be stuck, witch of / back on.
I want to say that the engine and the safety critical parts are still immune to this problem.. i want to.
 

Online nctnico

  • Super Contributor
  • ***
  • Posts: 28429
  • Country: nl
    • NCT Developments
Re: Which is more complex - car or an operating system?
« Reply #13 on: June 02, 2020, 06:05:22 pm »
Cars and trucks usually have less total software complexity, but that is somewhat required to still be able to review and test for edge cases, its one of the few industries where its not easy to "just patch it after release"

you would be suprised :(
we also have a mechanic workshop and in the past few years many of the newer, higher end volvo and audi we serviced suffered from serious bugs in the transmission and lightning ecu. Customer would be asked to go to the dealer at least once every few weeks to update the ECUs
serious bugs meaning the gear will refuse to change, switch off / back on or that the whole rear lights would be stuck, witch of / back on.
I want to say that the engine and the safety critical parts are still immune to this problem.. i want to.

At least they got the car out of the door. Volkswagen can't even get the software to work on their new ID.3. They are going to pull a 'Rigol' by selling the cars with many features missing.
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Online CatalinaWOW

  • Super Contributor
  • ***
  • Posts: 5569
  • Country: us
Re: Which is more complex - car or an operating system?
« Reply #14 on: June 02, 2020, 06:12:37 pm »
Depends on what you mean by complexity.  Windows has hundreds of thousands of lines of code, while a car has only a few thousands, or possibly tens of thousands of parts.  But the Windows code works in a very simple environment where there are only a few hundred instructions and the language can be fully described in a single volume.  While the metallurgy of the various parts in a car requires multiple volumes.  And that is just one of the myriad of disciplines involved in designing said vehicle.  I suspect that the full staff designing Windows is an order of magnitude or more smaller than the staff designing a car.  Which would either mean Windows is less complex or that Microsoft is incredibly efficient compared to auto designers.  I know few who would vote on the latter.
 
The following users thanked this post: Someone

Offline T3sl4co1l

  • Super Contributor
  • ***
  • Posts: 22436
  • Country: us
  • Expert, Analog Electronics, PCB Layout, EMC
    • Seven Transistor Labs
Re: Which is more complex - car or an operating system?
« Reply #15 on: June 02, 2020, 06:25:35 pm »
Ah, another opportunity to wax philosophic.... :-DD

I agree with the statement that comparisons aren't useful -- but for different reasons.  Consider:

How did we arrive at modern, well, anything?  Complex software systems are built upon simpler software systems.  But they're also nearly useless without complex hardware systems to run them on.  Complex hardware systems, in turn, are built upon simpler hardware systems.  And those hardware systems are built upon complex industrial processes, which are built upon simpler, and so on and so forth -- we are dozens of generations in at this point, the list goes on.

It is not meaningful to speak of the development of one technology in isolation, because it depends implicitly upon every other supporting technology that is at a similar level of development.  The whole reason we have this complexity today, is because we had a similar increase in complexity in the previous generation, and so on.

A more concrete example that motivates this line of thought, is the thought experiment of the time travelling technologist -- if you were transported back 100, 1000, 10,000 years, whatever; even given a robust device to access current knowledge upon, not relying on your memory alone -- what might you be able to accomplish?

A typical answer seems to be ~roughly~ 18th century development, but on a much smaller scale, and only after many decades of concerted effort; and assuming adequate patronage from whatever political power you happen to be working under, and assuming no death from the great many natural causes that were typical of the time.


I don't think it's reasonable to compare complexity, when the design of a given, exact item is impossible without some chain of prerequisites.  For two items at the same depth, their complexity can be considered equivalent, or perhaps quibbled over in terms of modest degrees of complexity, which might be measured in some agreeable method, like minimal person-hours, or project time or budget, to take that existing technology (previous designs, theory, SDKs, etc.) and make the finished item.  Whereas things that exist on different technology nodes, are intrinsically ordered.

So, that laid out, I think there are some refinements that can be made:
- We might make something with a given technology node, but it doesn't need to be made that way.  Many things can be made, across many nodes, that are functionally equivalent.  An audio amplifier can be made with ICs, transistors, vacuum tubes, or indeed, carbon granules.  We've made a stopwatch (as such) in pure mechanics, discrete transistors, integrated circuits, and software on still-more-advanced integrated circuits; are they all equivalent?  (In other words, should we relax the requirement that we consider the technology required to create an exact particular item, but something that is, in some useful ways, equivalent?)
- There is a cost-scale tradeoff inherent in economics.  Consider the mainframe computer of the 1950s, which might've cost as much as a small factory; are they therefore equivalent in some sense?  Or compare the minicomputer of the 1970s to the personal computer of the 1980s or 90s: they might have equivalent performance, but one cost exponentially more than the other; does that make one or the other more advanced?
- We do have to be mindful of the minimum investment criteria.  It's always possible to make something cost more, so of course we need to avoid cases that ran absurdly over budget, under their performance target, were affected by corrupting influences, etc.  They're not more complicated just because of that.  Conversely -- we might argue that such influences are inseparably part of the game, and we should use a broader scope.  After all, if the locals object to construction of a new hi-tech factory, surely part of that technical node includes either addressing their concerns, or convincing them it's beneficial?  Technology isn't just physical objects, it's our entire society top to bottom, thoughts included!


Overall I think the idea of technology nodes, or generations, is a useful one, but I'm not sure that there can exist a simple, convincing method to compare things of greatly varying complexity as well as technology.  Well, that's just it -- I've enumerated several axes with which we might measure a thing.  It's just trying to order multidimensional vectors -- you can create a definition, but there can be no unique ordering of them.

Tim
Seven Transistor Labs, LLC
Electronic design, from concept to prototype.
Bringing a project to life?  Send me a message!
 

Offline 0xdeadbeef

  • Super Contributor
  • ***
  • Posts: 1581
  • Country: de
Re: Which is more complex - car or an operating system?
« Reply #16 on: June 02, 2020, 06:34:45 pm »
Depends on what you mean by complexity.  Windows has hundreds of thousands of lines of code, while a car has only a few thousands, or possibly tens of thousands of parts. 
I guess you underestimate both by quite a bit. I guess a typical engine control unit (gasoline, diesel) already has a few hundred thousand lines of code. Maybe already a few millions. Haven't checked recently but from what I know just the application functionality for something like lambda control already has thousands of lines of code. Hard to tell nowadays with auto-generated code and things like that.
And that's only one of the many control units. I guess the cockpit stuff with multimedia and navigation (even letting aside driving assistants) could already use much more code than the engine control unit. Definitely more bloated code for sure. And don't underestimate how many control units (i.e. microcontroller systems) there are in a car. Lots of sensors and actuators have their own little control unit, letting aside things like the gearbox, the airbags etc.
I'd still think though that Windows's complexity with all the subsystems, drivers and what not will be magnitudes above all the stuff in a normal modern car combined.
« Last Edit: June 02, 2020, 07:26:14 pm by 0xdeadbeef »
Trying is the first step towards failure - Homer J. Simpson
 

Online CatalinaWOW

  • Super Contributor
  • ***
  • Posts: 5569
  • Country: us
Re: Which is more complex - car or an operating system?
« Reply #17 on: June 02, 2020, 07:48:39 pm »
Depends on what you mean by complexity.  Windows has hundreds of thousands of lines of code, while a car has only a few thousands, or possibly tens of thousands of parts. 
I guess you underestimate both by quite a bit. I guess a typical engine control unit (gasoline, diesel) already has a few hundred thousand lines of code. Maybe already a few millions. Haven't checked recently but from what I know just the application functionality for something like lambda control already has thousands of lines of code. Hard to tell nowadays with auto-generated code and things like that.
And that's only one of the many control units. I guess the cockpit stuff with multimedia and navigation (even letting aside driving assistants) could already use much more code than the engine control unit. Definitely more bloated code for sure. And don't underestimate how many control units (i.e. microcontroller systems) there are in a car. Lots of sensors and actuators have their own little control unit, letting aside things like the gearbox, the airbags etc.
I'd still think though that Windows's complexity with all the subsystems, drivers and what not will be magnitudes above all the stuff in a normal modern car combined.

You misunderstand me.  I am saying that in some sense mechanical systems are more complex because they have a more complex environment and more complex choices.  I would agree with your estimates of slocs for both cars and windows.
 

Offline mc172

  • Frequent Contributor
  • **
  • Posts: 490
  • Country: gb
Re: Which is more complex - car or an operating system?
« Reply #18 on: June 02, 2020, 08:06:19 pm »
Don't forget the incredible complexity involved in designing the parts themselves, rather than just the software. The crankshaft, the fuel pump, the headlights, the housing for the ECU... Etc.
 

Offline Syntax Error

  • Frequent Contributor
  • **
  • Posts: 584
  • Country: gb
Re: Which is more complex - car or an operating system?
« Reply #19 on: June 02, 2020, 09:05:43 pm »
Perhaps another question is, which part of a car does not require an operating system? Just about everything from the oil flow sensor to the courtesy light subsystem is chattering away on the CAN bus. Name one device in a modern vehicle that does not require a bootloader/RTOS to function? Just one device you can fix with a multimeter rather than spending a really expensive diagnostic day/week plugged into some customer care service center, trying to figure out why the cruise control only works when the parking brake is engaged?

  :-// Fix it? It's your software mate.
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Which is more complex - car or an operating system?
« Reply #20 on: June 02, 2020, 09:14:56 pm »
Cars and trucks usually have less total software complexity, but that is somewhat required to still be able to review and test for edge cases, its one of the few industries where its not easy to "just patch it after release"

Each module is very built for purpose, meaning there is not much generalized code, take a normal ECU, most times the ROM image is in the ballpark of 256MB or less,

The main horrible mess of complexity can be found in the "infotainment" system, e.g. the radio and all the other crap that gets packed in there, more often than not they literally run on linux, and are bodge upon bodge upon bodge, but as certain parts will be stripped down for size, likely puts it at less than a fully featured OS.

Think of it like everything but the radio is usually akin to a large microprocessor written with embedded code, the radio is like a raspberry pi with enough hats to scrape the ceiling.

It seems crazy that modern ECUs would have a 256MB ROM, the ECU in my car has a 4K ROM.

Those infotainment systems are garbage, integrating tech with a 2-4 year life cycle into an expensive machine with a 15-30 year life cycle is ludicrous. Personally when I'm driving a car I'm *driving* the car and nothing else, if I want music I've got a thumb drive full of MP3s that I can plug into my head unit. Virtually everybody on the planet already has a smartphone these days, if auto makers want to include some sort of infotainment then just provide a nice integrated cubby in the dash with a clip to hold a phone with a USB socket for charging and BT receiver in the stereo. No infotainment system can ever hope to keep up with smartphones, every one of those systems will be woefully dated and obsolete a decade or more before the car is worn out.
 

Offline james_s

  • Super Contributor
  • ***
  • Posts: 21611
  • Country: us
Re: Which is more complex - car or an operating system?
« Reply #21 on: June 02, 2020, 09:18:02 pm »
Perhaps another question is, which part of a car does not require an operating system? Just about everything from the oil flow sensor to the courtesy light subsystem is chattering away on the CAN bus. Name one device in a modern vehicle that does not require a bootloader/RTOS to function? Just one device you can fix with a multimeter rather than spending a really expensive diagnostic day/week plugged into some customer care service center, trying to figure out why the cruise control only works when the parking brake is engaged?

  :-// Fix it? It's your software mate.

The battery?

Windshield washer pump, light bulbs, a few other things, not a whole lot though.

So far I've never owned a car newer than 1990 and I doubt I'll ever have anything newer than early 2000's unless I just get some beater to get me around at some point. They're all crap now, nothing has piqued my interest in the least, especially now that I hardly ever drive anymore.
 

Offline MK14

  • Super Contributor
  • ***
  • Posts: 4987
  • Country: gb
Re: Which is more complex - car or an operating system?
« Reply #22 on: June 02, 2020, 09:38:32 pm »
Which is more complex - car or an operating system?
{Quote changed to title, to make it brief}

There are some (relatively) rough and ready techniques/tricks, to guage (technical) complexity.
One method, is to go back in time, and see when a 'modern' version, of the item in question. First (significantly), appeared on the market.

E.g. In 1971, the Microprocessor first appeared on the market (opinions sometimes vary on the exact dates/years and which was the first one).

So, for the modern day car, I guess you would be talking around the mid-1990s (opinions, can easily vary).

For the modern day operating systems (windows was highlighted by the OP), I would say around the mid-1990s, windows was somewhat modern like.

So, I'd (very approximately), call it a tie.
 

Offline Mr. Scram

  • Super Contributor
  • ***
  • Posts: 9821
  • Country: 00
  • Display aficionado
Re: Which is more complex - car or an operating system?
« Reply #23 on: June 02, 2020, 09:43:19 pm »
{Quote changed to title, to make it brief}

There are some (relatively) rough and ready techniques/tricks, to guage (technical) complexity.
One method, is to go back in time, and see when a 'modern' version, of the item in question. First (significantly), appeared on the market.

E.g. In 1971, the Microprocessor first appeared on the market (opinions sometimes vary on the exact dates/years and which was the first one).

So, for the modern day car, I guess you would be talking around the mid-1990s (opinions, can easily vary).

For the modern day operating systems (windows was highlighted by the OP), I would say around the mid-1990s, windows was somewhat modern like.

So, I'd (very approximately), call it a tie.
Why would you say the modern car appeared in the 90s? I'd have said the 30s perhaps, or 50s or early 60s. The 90s feels completely arbitrary as almost all the development back then was iterative.
 
The following users thanked this post: amyk, Someone

Offline Mr. Scram

  • Super Contributor
  • ***
  • Posts: 9821
  • Country: 00
  • Display aficionado
Re: Which is more complex - car or an operating system?
« Reply #24 on: June 02, 2020, 09:45:56 pm »
The battery?

Windshield washer pump, light bulbs, a few other things, not a whole lot though.

So far I've never owned a car newer than 1990 and I doubt I'll ever have anything newer than early 2000's unless I just get some beater to get me around at some point. They're all crap now, nothing has piqued my interest in the least, especially now that I hardly ever drive anymore.
You absolutely positively have to mention this at the slightest provocation, don't you?  :-DD
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf