Drake
TestEllipsoidsSeparation Class Reference

This test is taken from the course notes of EE127A from University of California, Berkeley The goal is to find a hyperplane, that separates two ellipsoids E₁ = x₁ + R₁ * u₁, |u₁| ≤ 1 E₂ = x₂ + R₂ * u₂, |u₂| ≤ 1 A hyperplane aᵀ * x = b separates these two ellipsoids, if and only if for SOCP p* = min t₁ + t₂ s.t t₁ ≥ |R₁ᵀ * a| t₂ ≥ |R₂ᵀ * a| aᵀ(x₂-x₁) = 1 the optimal solution p* is no larger than 1. More...

#include <drake/solvers/test/second_order_cone_program_examples.h>

Public Member Functions

 TestEllipsoidsSeparation ()
 
void SolveAndCheckSolution (const MathematicalProgramSolverInterface &solver, double tol=1E-8)
 

Detailed Description

This test is taken from the course notes of EE127A from University of California, Berkeley The goal is to find a hyperplane, that separates two ellipsoids E₁ = x₁ + R₁ * u₁, |u₁| ≤ 1 E₂ = x₂ + R₂ * u₂, |u₂| ≤ 1 A hyperplane aᵀ * x = b separates these two ellipsoids, if and only if for SOCP p* = min t₁ + t₂ s.t t₁ ≥ |R₁ᵀ * a| t₂ ≥ |R₂ᵀ * a| aᵀ(x₂-x₁) = 1 the optimal solution p* is no larger than 1.

In that case, an appropriate value of b is b = 0.5(b₁ + b₂), where b₁ = aᵀx₁ + |R₁ᵀ * a| b₂ = aᵀx₂ - |R₂ᵀ * a|

Parameters
x1the center of ellipsoid 1
x2the center of ellipsoid 2
R1the shape of ellipsoid 1
R2the shape of ellipsoid 2

Constructor & Destructor Documentation

◆ TestEllipsoidsSeparation()

Member Function Documentation

◆ SolveAndCheckSolution()

void SolveAndCheckSolution ( const MathematicalProgramSolverInterface solver,
double  tol = 1E-8 
)

The documentation for this class was generated from the following files: