Inmathematics, abasic semialgebraic set is a set defined by polynomial equalities and polynomial inequalities, and asemialgebraic set is afiniteunion of basic semialgebraic sets. Asemialgebraic function is afunction with a semialgebraicgraph. Such sets and functions are mainly studied inreal algebraic geometry which is the appropriate framework foralgebraic geometry over the real numbers.
Let be areal closed field (For example could be thefield ofreal numbers).Asubset of is asemialgebraic set if it is a finite union of sets defined bypolynomial equalities of the form and of sets defined by polynomialinequalities of the form

Similarly toalgebraic subvarieties, finite unions andintersections of semialgebraic sets are still semialgebraic sets. Furthermore, unlike subvarieties, thecomplement of a semialgebraic set is again semialgebraic. Finally, and most importantly, theTarski–Seidenberg theorem says that they are also closed under the projection operation: in other words a semialgebraic set projected onto alinear subspace yields another semialgebraic set (as is the case forquantifier elimination). These properties together mean that semialgebraic sets form ano-minimal structure onR.
A semialgebraic set (or function) is said to bedefined over a subringA ofR if there is some description, as in the definition, where the polynomials can be chosen to have coefficients inA.
On adenseopen subset of the semialgebraic setS, it is (locally) asubmanifold. One can define the dimension ofS to be the largest dimension at points at which it is a submanifold. It is not hard to see that a semialgebraic set lies inside an algebraic subvariety of the same dimension.