Function G2lib::solveLinearQuadratic

Function Documentation

int_type G2lib::solveLinearQuadratic(real_type A, real_type B, real_type C, real_type a, real_type b, real_type c, real_type *x, real_type *y)

Solve the nonlinear system

\[ A x + B y = C \]
\[ a x^2 + b y^2 = c \]
Parameters
  • A[in] first parameter of the linear equation

  • B[in] second parameter of the linear equation

  • C[in] third parameter of the linear equation

  • a[in] first parameter of the quadratic equation

  • b[in] second parameter of the quadratic equation

  • c[in] third parameter of the quadratic equation

  • x[out] x-coordinates of the solutions

  • y[out] y-coordinates of the solutions

Returns

the number of solution 0, 1 or 2