🤖
Robotics Handbook
HomeConnect
  • Welcome
    • Authors Note
  • Computer Aided Designs and Simulations
    • Computer Aided Design and Simulations
    • 3D Modelling CAD
      • SolidWorks
    • Simulations
    • PCB Design
  • ROS (Advanced)
    • ROS
    • ROS
      • Concepts and Packages
      • Manual and Quick Setup
    • Some Important packages
  • Hardware
    • Design Processes
      • Materials Selection
      • Build and Prototyping
      • 3D Printing and Machining
    • Fabrication Parts
  • Common Mechanisms
    • Wheels and Drives
    • Power Transmission
  • Career Paths & Research Opportunities
    • Career in Robotics
    • Job Roles In Robotics
    • Conferences and Journals
  • Companies Hiring for Robotics
  • Leading Institutes
  • Mathematical and Programming Foundations
    • Linear Algebra for Robotics
    • Calculus
  • Programming for Robotics
    • Common Languages
    • Algorithms
    • Digital Twin
  • Embedded Systems for Robotics
    • Embedded Systems
    • Microcontrollers
      • Microcontrollers (Advanced Theory)
      • Choosing a Microcontroller
    • Sensors and Actuators
      • Sensors for Robotics
      • Actuators for Robotics
    • Communication
      • Communication Protocols
    • RTOS
    • Power Systems
      • Battery Charging and Storage Best Practices
  • ML and Perception
    • ML and Perception
    • Reinforcement Learning
    • Cameras, Depth Sensors and LiDAR
    • Image Processing Basics (OpenCV)
    • Object Detection and Tracking
    • Example of a Vision Pipeline
  • Mobile Robotics
    • Mobile Robotics
    • SLAM and Navigation
    • Robot Kinematics and Dynamics
      • Some Kinematic Models
    • Trajectory Planning
    • AMR's and AGV's
    • MH633 : Mobile Robotics
      • Geometric Foundations
      • Kinematics
  • Frontiers and Emerging Fields
    • Frontiers and Emerging Fields
    • Humanoids
    • Autonomous Navigation
    • Bio-inspired and Soft Robotics
    • Space Robotics
    • Cobots
    • Edge Robotics
    • Medical Robotics
  • Drones, Rocketry and Aviation
    • Drones
      • Drone Anatomy
    • Rocketry
Powered by GitBook
On this page
  • Differentiation in Kinematics
  • Integration in Motion and Sensing
  • Trajectory Planning
  • Dynamics via Lagrange’s Equations
  • Control System Design
  • Perception and Computer Vision
  1. Mathematical and Programming Foundations

Calculus

PreviousLinear Algebra for RoboticsNextCommon Languages

Last updated 2 days ago

Differentiation in Kinematics

Robotic motion is often defined by a position function q(t)q(t) of joint angles or Cartesian coordinates over time. Differentiation yields:

  • Velocity

q˙(t)=ddtq(t)\dot{q}(t) = \frac{d}{dt}q(t)q˙​(t)=dtd​q(t)
  • Acceleration

$$ \ddot{q}(t) = \frac{d^2}{dt^2} q(t) $$

Example: for a single-joint rotary robot moving from angle θ0θ0 to θfθf via a cubic trajectory, the velocity and acceleration profiles are polynomials in tt.

theta(t)=a0+a1t+a2t2+a3t3theta(t) = a_0 + a_1 t + a_2 t^2 + a_3 t^3theta(t)=a0​+a1​t+a2​t2+a3​t3
theta(t)=a1+2a2 t+3a3 t2theta(t) = a_1 + 2a_2\,t + 3a_3\,t^2 theta(t)=a1​+2a2​t+3a3​t2

Integration in Motion and Sensing

Integration accumulates rates into displacements or sensor estimates:

  • Position from velocity: q(t)=q(t0)+∫t0tqË™(Ï„) dÏ„q(t)=q(t0)+∫t0tqË™(Ï„)dÏ„

  • State estimation (e.g., odometry): integrating wheel velocities to track robot pose.

Example: integrating a constant acceleration aa gives velocity and displacement:

Trajectory Planning

Selecting smooth paths between waypoints requires piecewise-polynomial fits that ensure continuous position, velocity, and sometimes acceleration. A common choice is the cubic segment between times titi and ti+1ti+1:

With boundary conditions

Dynamics via Lagrange’s Equations

Robot dynamics relate joint torques ττ, positions qq, and accelerations q¨q¨. The Euler–Lagrange formulation yields:

where

  • M(q)M(q) is the mass (inertia) matrix,

  • C(q,qË™)C(q,qË™) contains Coriolis and centrifugal terms,

  • g(q)g(q) is the gravity vector.

Control System Design

Calculus underlies feedback controllers and optimizations:

  • PID control uses proportional, integral, and derivative terms on tracking error e(t)e(t):

  • Linear Quadratic Regulator (LQR) solves continuous-time algebraic Riccati equations to minimize a quadratic cost.

Perception and Computer Vision

In vision, image coordinates x(u,v)x(u,v) vary with time as cameras or objects move. Optical flow computes image velocity:

where I˙I˙ is the temporal image derivative, ∇I∇I its spatial gradient, and vv the pixel velocity.

Calculus thus weaves through every phase of robotics: from physical motion and sensor fusion to high-level planning and control, allowing robots to move smoothly, react reliably, and perceive accurately.

theta(t)=2a2+6a3 ttheta(t) = 2a_2 + 6a_3\,ttheta(t)=2a2​+6a3​t
v(t)=v0+a tv(t) = v_0 + a\,tv(t)=v0​+at
s(t)=s0+v0 t+12 a t2s(t) = s_0 + v_0\,t + \tfrac12\,a\,t^2s(t)=s0​+v0​t+21​at2
qi(τ)=C0+C1τ+C2τ2+C3τ3,τ∈[0, T]q_i(\tau) = C_0 + C_1 \tau + C_2 \tau^2 + C_3 \tau^3,\quad \tau\in[0,\,T]qi​(τ)=C0​+C1​τ+C2​τ2+C3​τ3,τ∈[0,T]
qi(0)=q(ti)qi(0)=q(ti)qi(0)=q(ti)
q˙i(0)=q˙(ti)q˙i(0)=q˙(ti)q˙i(0)=q˙(ti)
qi(T)=q(ti+1)qi(T)=q(ti+1)qi(T)=q(ti+1)
q˙i(T)=q˙(ti+1)q˙i(T)=q˙(ti+1)q˙i(T)=q˙(ti+1)
qi(0)=q(ti)qi(0)=q(ti)qi(0)=q(ti)
q˙i(0)=q˙(ti)q˙i(0)=q˙(ti)q˙i(0)=q˙(ti)
qi(T)=q(ti+1)qi(T)=q(ti+1)qi(T)=q(ti+1)
q˙i(T)=q˙(ti+1)q˙i(T)=q˙(ti+1)q˙i(T)=q˙(ti+1)
M(q) q¨+C(q,q˙) q˙+g(q)=τM(q)\,\ddot q + C(q,\dot q)\,\dot q + g(q) = \tauM(q)q¨​+C(q,q˙​)q˙​+g(q)=τ
u(t)=KPe(t)+KI∫0te(τ) dτ+KDddte(t)u(t) = K_P e(t) + K_I \int_0^t e(\tau)\,d\tau + K_D \tfrac{d}{dt}e(t)u(t)=KP​e(t)+KI​∫0t​e(τ)dτ+KD​dtd​e(t)
I˙+∇I⋅v=0\dot I + \nabla I \cdot \mathbf{v} = 0I˙+∇I⋅v=0