% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/proportional.R
\name{solve_2set}
\alias{solve_2set}
\title{Area-proportional 2-set circle layout}
\usage{
solve_2set(a_only, b_only, ab)
}
\arguments{
\item{a_only}{Items in A only (integer >= 0).}

\item{b_only}{Items in B only (integer >= 0).}

\item{ab}{Items in A intersection B (integer >= 0).}
}
\value{
A named list with elements:
  \describe{
    \item{circles}{Length-2 list of `list(cx, cy, r)` named lists.}
    \item{error}{Relative error of the achieved area fit (typically < 1e-4).}
    \item{is_approximate}{Always `FALSE` for 2-set.}
  }
}
\description{
Solves for two circles whose areas equal `a_only + ab` and `b_only + ab` and
whose intersection area equals `ab`, by analytical bisection on the
inter-center distance. Always exact (returns `is_approximate = FALSE`).
}
\details{
Mirrors Python `solve_2set` byte-for-byte.
}
\examples{
solve_2set(a_only = 30L, b_only = 30L, ab = 10L)
}
