Cyber-Physical Systems

Chapter 1
Foundations of Cyber-Physical Systems

Bachelor Program in Mechatronics Engineering
Cyber-Physical Systems   •   Bachelor

Foundations of Cyber-Physical Systems

Introduction

Cyber-Physical Systems (CPS) are engineered systems in which computational components interact continuously with physical processes. Computers, sensors, communication networks, actuators, control algorithms, people, and physical environments operate as an integrated whole. A robotic arm, autonomous vehicle, smart power grid, medical infusion pump, and automated manufacturing cell are all examples of CPS.

The central idea is not simply that a physical device contains a computer. Rather, computation is closely coupled to physical behavior. Sensors measure the physical world, software interprets measurements and makes decisions, networks exchange information, and actuators influence the physical process. This interaction occurs over time and is constrained by dynamics, uncertainty, safety requirements, timing, energy, and human objectives.

CPS is therefore a foundational concept for mechatronics engineering. It connects mechanical design, electrical and electronic systems, control engineering, embedded computing, communication networks, data engineering, and systems thinking.

Learning Objectives

After studying this chapter, you should be able to:

  1. Define CPS and distinguish its major components.
  2. Explain the characteristics of CPS, including cyber-physical coupling, timing, feedback, and emergence.
  3. Describe the historical development from automation and embedded systems to CPS and Industry 4.0.
  4. Compare CPS with embedded systems, mechatronics, the Internet of Things, automation, and Industry 4.0.
  5. Analyze a practical CPS architecture and identify its sensing, computation, communication, control, and actuation functions.
  6. Discuss safety, security, reliability, ethical, and governance issues in CPS.

1. What Is a Cyber-Physical System?

A CPS is an engineered system whose computational elements monitor, communicate with, and control physical processes through feedback loops. The phrase contains two domains:

  • The cyber domain includes software, processors, data, networks, algorithms, models, and digital decision-making.
  • The physical domain includes matter, energy, motion, temperature, pressure, electrical quantities, biological processes, machines, and human activity.

The domains are coupled through interfaces. Sensors convert physical quantities into signals that can be processed digitally. Actuators convert computational decisions into physical effects. Communication networks connect components, while control algorithms determine how the system should respond.

A useful conceptual representation is:

Physical process → Sensors → Computation and communication → Actuators → Physical process
                         ↑                                      ↓
                         └──────────── feedback ────────────────┘

The feedback loop is essential. A system that only records data may be an information system, whereas a CPS generally uses information to influence a physical process. For example, a temperature-monitoring application becomes a CPS when it uses temperature measurements to control a heater or cooling valve.

There is no single universally accepted boundary for CPS. Some definitions emphasize tight timing and control; others include broad networked systems containing physical assets. In engineering practice, the most useful definition focuses on integrated computation, communication, sensing, actuation, and physical dynamics.

2. Core CPS Components

2.1 Physical process

The physical process is the part of the world being observed or controlled. It may be a motor, vehicle, production line, building, aircraft, power converter, or biological system. Physical processes exhibit dynamics: their state changes with time because of forces, energy flows, material flows, and disturbances.

Important physical variables include position, velocity, acceleration, force, torque, temperature, pressure, voltage, current, flow rate, and concentration.

2.2 Sensors and transducers

A sensor detects a physical quantity and produces a measurable output. A transducer converts energy from one form to another. Examples include thermocouples, encoders, accelerometers, cameras, pressure sensors, current transformers, and lidar units.

Sensor limitations include noise, bias, drift, calibration error, finite resolution, saturation, and latency. A digital controller never observes the physical state perfectly; it receives measurements that are sampled, quantized, delayed, and sometimes missing.

2.3 Embedded computation

Embedded processors execute software dedicated to a device or system. They may include microcontrollers, digital signal processors, programmable logic controllers, field-programmable gate arrays, system-on-chip devices, or industrial computers.

Embedded software may perform signal conditioning, state estimation, control, diagnostics, scheduling, communication, and safety monitoring. In CPS, computation is not isolated from physical consequences: an incorrect software decision can damage equipment or endanger people.

2.4 Communication networks

Networks allow sensors, controllers, actuators, supervisory systems, and human operators to exchange information. Examples include Controller Area Network (CAN), Modbus, PROFINET, EtherCAT, industrial Ethernet, wireless sensor networks, 5G, and application protocols such as MQTT.

Communication introduces delay, jitter, packet loss, bandwidth limitations, and cybersecurity exposure. Consequently, network behavior can affect physical performance. A control algorithm that is stable with negligible delay may perform poorly when delays become large or variable.

2.5 Actuators

Actuators transform commands into physical action. Motors, hydraulic cylinders, pneumatic valves, solenoids, relays, heaters, pumps, and robotic end-effectors are common examples. Actuators have constraints such as maximum force, speed, torque, travel, power, and response time.

2.6 Control and decision algorithms

A controller compares desired behavior with measured behavior and computes an action. In a simple feedback controller, the error is:

e(t) = r(t) − y(t)

where r(t) is the reference or desired value, y(t) is the measured output, and e(t) is the error. The equation assumes that the reference and output represent the same physical quantity and use compatible units.

A proportional controller may be written as:

u(t) = Kp e(t)

where u(t) is the control command and Kp is the proportional gain. This is a simplified control law; practical systems may require integral, derivative, state-feedback, predictive, adaptive, or event-based control. A controller must also respect actuator saturation, sampling, delays, stability, and safety constraints.

2.7 Human and organizational elements

Operators, maintenance personnel, designers, managers, regulators, and affected communities are part of the broader CPS context. Human-machine interfaces support supervision and intervention, but they can also introduce workload, misunderstanding, and unsafe reliance on automation.

3. Defining Characteristics of CPS

Tight cyber-physical coupling

Computational activity and physical behavior influence one another. A change in software may alter motion, temperature, pressure, or power consumption; a physical change modifies sensor data and future computational decisions.

Feedback and closed-loop behavior

CPS commonly operate through feedback. The system measures outcomes, compares them with goals, and adjusts actions. Feedback can improve accuracy and disturbance rejection, but poorly designed feedback can cause oscillation or instability.

Real-time and temporal behavior

Correctness depends not only on what a computation produces but also on when it produces it. A late braking command may be equivalent to an incorrect command. Real-time requirements may be hard, meaning a deadline must never be missed, or soft, meaning occasional lateness degrades performance.

Heterogeneity and distribution

CPS integrate mechanical, electrical, software, network, and human components from different suppliers and engineering disciplines. Functions may be distributed across many processors and locations.

Adaptation and autonomy

Many CPS adjust their behavior in response to changing conditions. Adaptation may involve gain scheduling, fault reconfiguration, learning algorithms, or optimization. Autonomy does not remove engineering responsibility; autonomous decisions must remain bounded by verified rules and safety constraints.

Emergent behavior

System-level behavior may arise from interactions among components and may not be obvious from examining one component in isolation. Examples include traffic congestion caused by individually reasonable vehicle decisions, oscillations created by networked controllers, or cascading failures in power systems.

Dependability

Dependability includes availability, reliability, safety, maintainability, integrity, and confidentiality. CPS require a balanced treatment of these properties because failures can have physical consequences.

Security as a physical concern

Unauthorized access to a CPS can change physical behavior. Security objectives therefore include confidentiality, integrity, availability, authenticity, and sometimes non-repudiation. In a safety-critical system, integrity and availability may be more immediately important than secrecy.

4. Historical Development

Mechanical automation and control

Early automation used mechanical governors, cams, linkages, relays, and pneumatic systems. Feedback control became especially influential through devices such as centrifugal governors and later through formal control theory. These systems established the principle that measurement and correction could regulate physical processes.

Electronic control and industrial automation

The development of electronics enabled faster sensing, amplification, switching, and control. Relay logic and later programmable logic controllers transformed manufacturing. Industrial automation separated control logic from hard-wired circuits and made production systems more flexible.

Digital computers and embedded systems

As microprocessors and microcontrollers became affordable, computing could be placed directly inside products. Automotive engine controllers, washing-machine controllers, medical devices, and industrial drives became embedded systems. These systems were often designed as relatively self-contained products.

Mechatronics

Mechatronics emerged as an interdisciplinary approach combining mechanical engineering, electronics, control, and computing. It emphasized integrated product design rather than treating mechanics and electronics as unrelated subsystems. CPS extends this integration by giving stronger emphasis to networking, distributed computation, software-intensive behavior, and interaction with broader environments.

Networked control and the Internet

Industrial networks and the Internet connected previously isolated devices. Supervisory control, remote diagnostics, distributed sensing, and enterprise integration became possible. The system boundary expanded from one machine to a production cell, factory, supply chain, city, or infrastructure network.

Internet of Things and CPS

The Internet of Things (IoT) popularized the connection of physical objects to networks and cloud services. IoT often emphasizes identification, connectivity, data collection, and services. CPS emphasizes the interaction between computation and physical dynamics, particularly sensing, control, timing, and safety. The concepts overlap substantially but are not identical.

Industry 4.0

Industry 4.0 describes a broad transformation of industrial production through interconnected equipment, data analytics, digital platforms, cyber-physical production systems, artificial intelligence, flexible automation, and human-machine collaboration. CPS are a technical foundation of Industry 4.0, while Industry 4.0 also includes organizational, business, and manufacturing-strategy dimensions.

5. Relationships with Related Concepts

ConceptMain emphasisRelationship to CPS
Embedded systemComputing dedicated to a deviceA CPS may contain one or many embedded systems, but adds stronger interaction and often networking
MechatronicsIntegrated mechanical, electronic, and control designCPS builds on mechatronics and extends it through software, networks, and system-level intelligence
IoTConnectivity and data exchange among objectsIoT may provide the communication layer; CPS additionally emphasizes physical dynamics and control
AutomationAutomatic execution of tasks or processesCPS is a modern architecture for connected, adaptive, and data-rich automation
Industrial control systemMonitoring and control of industrial processesMany industrial control systems are CPS, especially when networked and computationally integrated
Industry 4.0Industrial transformation and production strategyCPS is one of the enabling technologies within the wider Industry 4.0 framework
Digital twinDigital representation linked to a physical assetA digital twin may support a CPS through simulation, prediction, monitoring, and optimization
Artificial intelligenceMethods for learning, inference, and decision-makingAI can be used within CPS, but AI alone is not a CPS

The distinctions are functional rather than absolute. For example, a smart motor drive may be simultaneously an embedded system, a mechatronic product, an IoT device, and a CPS component.

6. A Layered CPS Architecture

A practical architecture can be understood in layers:

  1. Physical layer: machines, energy systems, materials, and environments.
  2. Sensing and actuation layer: transducers, signal conditioning, drives, and actuators.
  3. Control layer: local control loops, safety functions, and real-time computation.
  4. Communication layer: wired and wireless networks, addressing, synchronization, and protocols.
  5. Supervisory and data layer: monitoring, historians, diagnostics, optimization, and digital models.
  6. Enterprise and human layer: production planning, maintenance decisions, operators, regulation, and business objectives.

These layers are analytical aids rather than rigid physical boundaries. A programmable controller may perform sensing, control, communication, and diagnostics simultaneously. Good engineering requires traceability across layers: a business objective should be connected to measurable performance, control requirements, hardware constraints, and physical outcomes.

7. Worked Example: Temperature-Controlled Process

Consider a small industrial oven required to maintain 150 °C. A thermocouple measures oven temperature every 100 ms. A controller compares the measurement with the reference and commands a power controller connected to a heater.

Suppose the desired temperature is r = 150 °C, the measured temperature is y = 146 °C, and the proportional gain is Kp = 0.20 power units per degree Celsius. The error is:

e = r − y = 150 °C − 146 °C = 4 °C

The proportional command is:

u = Kp e = 0.20 × 4 = 0.80

Here, the numerical command is 0.80 in the controller's normalized power units. The gain has units of power units per °C, so multiplication by the temperature error produces power units. In an actual oven, the command would be limited to the available heater range. The example illustrates the CPS loop, but it does not establish stability or guarantee accurate regulation. Thermal delay, heat loss, sensor error, actuator limits, and disturbances must be analyzed before deployment.

8. Illustrative Case: Networked Robotic Assembly Cell

Background

This illustrative case concerns a robotic assembly cell containing a six-axis robot, vision camera, conveyor, force sensor, programmable controller, safety scanner, and production-management connection.

Problem

The cell must place components accurately while adapting to variable component positions. It must stop safely when a person enters the restricted area and report production and maintenance data.

Analysis

The camera supplies position information, the controller plans a trajectory, and the robot executes motion. Conveyor position and robot position must be synchronized. Force feedback detects incorrect insertion. The safety scanner provides an independent protective function. Production data are transmitted to a supervisory system.

Several CPS issues arise:

  • Camera processing creates computational latency.
  • Network delay can reduce synchronization accuracy.
  • Sensor calibration affects placement quality.
  • A software fault could cause hazardous motion.
  • A cyberattack could alter commands or suppress alarms.
  • Human operators need clear status information and safe recovery procedures.

Approach and solution

The cell is designed with local real-time motion control so that basic safety and motion functions do not depend entirely on a remote cloud service. Safety-rated hardware and software supervise speed, position, and protective-zone access. Network segmentation separates safety-critical control traffic from enterprise traffic. Time-stamped data support diagnosis. The vision system is tested across lighting and component variations, while force limits prevent excessive insertion loads.

A digital model is used to test trajectories and estimate cycle time, but the model is not treated as a substitute for physical validation. Software changes are version-controlled, access is authenticated, and maintenance personnel receive training.

Outcome

The integrated design improves flexibility and traceability while preserving local safety functions. Performance is assessed using placement accuracy, cycle time, unplanned downtime, false safety trips, recovery time, and the number of production defects.

Learning points

  1. CPS engineering requires simultaneous consideration of mechanics, electronics, software, networks, and people.
  2. Cloud connectivity can support analysis but should not replace essential local control or safety functions.
  3. Safety and cybersecurity must be designed from the beginning.
  4. A successful prototype is not automatically a dependable production system.

9. Design and Engineering Considerations

Requirements and system boundaries

Requirements should identify physical objectives, timing deadlines, accuracy, operating conditions, failure responses, interfaces, cybersecurity needs, and regulatory obligations. Engineers must define what lies inside and outside the system boundary because connected systems can create hidden dependencies.

Modeling and simulation

Models may represent mechanical dynamics, electrical circuits, thermal behavior, communication delays, software logic, or human interaction. Model-based engineering allows early testing, but model validity depends on assumptions, parameter accuracy, and the operating range. Verification asks whether the system was built correctly; validation asks whether the correct system was built for its intended purpose.

Real-time scheduling

Tasks such as sensing, control, communication, and diagnostics compete for processor time. Scheduling must ensure that critical tasks meet deadlines. Average execution time is insufficient when occasional worst-case delays can create unsafe behavior.

Fault tolerance and graceful degradation

CPS should detect faults, isolate affected components, enter safe states, and recover where possible. Redundancy, watchdog timers, plausibility checks, fallback controllers, and emergency stops are common techniques. The appropriate response depends on the hazard: stopping a machine may be safe, whereas abruptly stopping a medical ventilator may not be.

Human-centered design

Interfaces should communicate system state, uncertainty, alarms, permissions, and recovery actions clearly. Automation should support appropriate human authority rather than encouraging either blind trust or unnecessary intervention.

10. Challenges and Limitations

CPS development is difficult because disciplines use different models, terminology, tools, and assurance methods. A mechanical engineer may focus on force and motion, a software engineer on code and interfaces, and a network engineer on packets and latency. System-level integration is therefore essential.

Other challenges include:

  • complexity and difficult-to-predict interactions;
  • incomplete or noisy sensor data;
  • timing uncertainty and network faults;
  • software updates in long-lived equipment;
  • cybersecurity threats and supply-chain vulnerabilities;
  • limited computational energy in edge devices;
  • difficulty proving learning-enabled behavior;
  • dependence on proprietary interfaces;
  • maintenance of legacy equipment;
  • conflict between production efficiency and safety margins.

A CPS may also produce large volumes of data without producing useful knowledge. Data quality, context, governance, and interpretability matter more than data volume alone.

11. Safety, Ethics, and Governance

CPS can affect physical safety, privacy, employment, environmental quality, and social equity. Safety engineering addresses unintended harm, whereas cybersecurity addresses malicious or unauthorized behavior; the two are increasingly interdependent.

Important practices include hazard analysis, threat modeling, secure authentication, least-privilege access, encryption where appropriate, secure update mechanisms, logging, incident response, independent testing, and lifecycle maintenance. Safety cases should provide structured evidence that risks are controlled to an acceptable level.

Ethical questions arise when CPS make decisions affecting people. Autonomous vehicles, medical systems, workplace monitoring, and predictive maintenance may involve privacy and accountability concerns. Organizations should identify who is responsible for decisions, how data are collected and retained, how errors are reported, and how affected people can seek review.

Relevant standards and regulations vary by sector and jurisdiction. Engineers should consult applicable functional-safety, industrial-control, machinery, medical-device, automotive, data-protection, and cybersecurity requirements rather than assuming that a general technology standard is sufficient.

12. Contemporary Developments

Edge computing places analysis and control near the physical process, reducing latency and dependence on distant services. Cloud platforms provide scalable storage and fleet-level analytics. Digital twins connect models with operational data. Machine learning supports anomaly detection, predictive maintenance, perception, and optimization.

However, AI introduces challenges involving training-data quality, distribution shift, explainability, adversarial inputs, and verification. A learned perception system may be useful for identifying objects but should not automatically be trusted with unrestricted control in a safety-critical environment. A practical architecture often combines learned functions with deterministic limits, monitoring, redundancy, and human oversight.

The future of CPS will likely involve more autonomous coordination, collaborative robots, resilient industrial networks, energy-aware computation, and integration with sustainable infrastructure. These developments increase the importance of lifecycle thinking: design, deployment, operation, maintenance, upgrade, retirement, and responsible disposal must all be considered.

Chapter Summary

Cyber-Physical Systems integrate computation, communication, sensing, actuation, and physical processes through feedback. Their behavior depends on both logical correctness and physical timing. CPS evolved from mechanical control, electronic automation, embedded systems, mechatronics, networked control, and IoT, and they now provide a technical foundation for Industry 4.0.

Embedded systems are dedicated computational components; mechatronics is an integrated design discipline; IoT emphasizes connected objects and data; automation emphasizes automatic operation; and Industry 4.0 describes a broader industrial transformation. These concepts overlap, but CPS is distinguished by tight interaction between cyber functions and physical dynamics.

Effective CPS engineering requires system modeling, real-time design, dependable sensing and actuation, secure communication, human-centered operation, fault tolerance, and lifecycle governance. Safety, cybersecurity, ethics, and regulatory compliance must be treated as design requirements rather than afterthoughts.

Key Terms

Cyber-Physical System: An engineered system integrating computation, communication, and physical processes through sensing and actuation.

Cyber domain: The software, data, computing, and networking elements of a system.

Physical domain: The material, energetic, mechanical, electrical, biological, or environmental processes being observed or controlled.

Sensor: A device that detects a physical quantity and produces a usable signal.

Actuator: A device that converts a command into physical action.

Feedback: The use of measured output to influence future system behavior.

Embedded system: Computing hardware and software dedicated to a particular device or function.

Mechatronics: Integrated engineering of mechanical, electronic, control, and computational systems.

Internet of Things: A concept involving networked physical objects that collect, exchange, or use data.

Automation: Operation of a process with reduced direct human intervention.

Industry 4.0: The digitally connected and intelligent transformation of industrial production.

Real time: Operation in which computational correctness includes meeting specified timing requirements.

Latency: The time delay between an event, measurement, transmission, computation, or response.

Jitter: Variation in the timing of an otherwise periodic event.

Digital twin: A digital representation linked to a physical asset or process.

Dependability: The ability of a system to deliver trusted service, including reliability, availability, and safety.

Fault tolerance: The ability to continue safe or useful operation despite component faults.

Edge computing: Processing data near the physical source rather than exclusively in a remote cloud.

Human-machine interface: The means through which people monitor, control, or interact with a system.

Review Questions

Short Answer Questions

  1. Define a Cyber-Physical System and identify its cyber and physical domains.
  2. Why are sensors and actuators essential to CPS operation?
  3. Distinguish an embedded system from a CPS.
  4. What is meant by real-time behavior in a CPS?
  5. State two ways in which CPS security differs from security in a purely informational system.

Long Answer Questions

  1. Explain the historical development from mechanical automation to CPS and Industry 4.0.
  2. Compare CPS, mechatronics, IoT, automation, and Industry 4.0 using examples.
  3. Describe a layered architecture for a networked robotic or manufacturing system.
  4. Discuss how timing, latency, and feedback influence CPS performance.
  5. Explain why safety, cybersecurity, ethics, and lifecycle maintenance should be integrated into CPS design.

Analytical / Application Questions

  1. Analyze a smart greenhouse as a CPS. Identify its physical process, sensors, actuators, controller, communication network, human users, and possible failure modes.
  2. A networked motor controller occasionally receives commands 200 ms late. Explain the possible physical consequences and propose engineering responses.
  3. Design a high-level CPS architecture for an automated warehouse vehicle. Justify the allocation of local control, cloud analytics, safety functions, and human supervision.

Multiple Choice Questions with Answers

Question 1

Which feature most directly distinguishes a CPS from a system that only collects data?

A. Use of a display screen

B. Use of feedback to influence a physical process

C. Storage of data in a database

D. Connection to a local area network

Correct Answer: B. Use of feedback to influence a physical process

Question 2

Which component converts a computational command into physical action?

A. Sensor

B. Actuator

C. Database

D. Protocol

Correct Answer: B. Actuator

Question 3

In the feedback equation e(t) = r(t) − y(t), what does r(t) represent?

A. Measured output

B. Controller gain

C. Reference or desired value

D. Communication delay

Correct Answer: C. Reference or desired value

Question 4

Why is timing important in a real-time CPS?

A. A result can be correct only if it is produced within its required deadline

B. Real-time systems never use sensors

C. Timing eliminates all measurement noise

D. Timing makes cybersecurity unnecessary

Correct Answer: A. A result can be correct only if it is produced within its required deadline

Question 5

Which concept primarily emphasizes connectivity and data exchange among physical objects?

A. IoT

B. Mechatronics

C. Actuator saturation

D. Fault isolation

Correct Answer: A. IoT

Question 6

Which statement best describes Industry 4.0?

A. A single type of microcontroller

B. A broad industrial transformation using connected and intelligent technologies

C. A mechanical feedback device

D. A sensor calibration method

Correct Answer: B. A broad industrial transformation using connected and intelligent technologies

Question 7

A temperature reference is 150 °C and the measured temperature is 146 °C. What is the control error e = r − y?

A. −4 °C

B. 0 °C

C. 4 °C

D. 296 °C

Correct Answer: C. 4 °C

Question 8

Which issue is especially important when a network is placed inside a physical control loop?

A. Packet delay and jitter

B. Keyboard color

C. Document font size

D. File naming convention only

Correct Answer: A. Packet delay and jitter

Question 9

What is a digital twin?

A. A duplicate physical sensor

B. A digital representation linked to a physical asset or process

C. A backup battery

D. A mechanical emergency stop

Correct Answer: B. A digital representation linked to a physical asset or process

Question 10

Why should essential safety functions often remain local rather than depend entirely on a cloud service?

A. Local functions can reduce dependence on communication availability and delay

B. Cloud services cannot store data

C. Local controllers never require testing

D. Safety functions do not involve physical processes

Correct Answer: A. Local functions can reduce dependence on communication availability and delay

Cyber-Physical Systems
Chapter 1 of 15