Simplify

Simplify[expr]

performs a sequence of algebraic and other transformations on expr and returns the simplest form it finds.

Simplify[expr,assum]

does simplification using assumptions.

Details and Options

  • Simplify tries expanding, factoring, and doing many other transformations on expressions, keeping track of the simplest form obtained.
  • Simplify can be used on equations, inequalities, and domain specifications.
  • Quantities that appear algebraically in inequalities are always assumed to be real.
  • FullSimplify does more extensive simplification than Simplify.
  • You can specify default assumptions for Simplify using Assuming.
  • The following options can be given:
  • Assumptions$Assumptionsdefault assumptions to append to assum
    ComplexityFunctionAutomatichow to assess the complexity of each form generated
    TimeConstraint300how many seconds to try doing any particular transformation
    TransformationFunctionsAutomaticfunctions to try in transforming the expression
    TrigTruewhether to do trigonometric as well as algebraic transformations
  • Assumptions can consist of equations, inequalities, domain specifications such as xIntegers, and logical combinations of these.
  • With the setting TimeConstraint->{tloc,ttot}, at most tloc seconds are spent for any particular transformation, and at most ttot seconds are spent for all transformations before the best result is returned.

Examples

open allclose all

Basic Examples  (3)

Simplify can get further if assumptions are made about x:

Scope  (4)

Simplify a polynomial:

Simplify a rational expression:

Simplify a trigonometric expression:

Simplify an exponential expression:

Simplify an equation:

Simplify expressions using assumptions:

Use assumptions to prove inequalities:

Options  (10)

Assumptions  (3)

Assumptions can be given both as an argument and as an option value:

The default value of the Assumptions option is $Assumptions:

When assumptions are given as an argument, $Assumptions is used as well:

Specifying assumptions as an option value prevents Simplify from using $Assumptions:

ComplexityFunction  (2)

The default ComplexityFunction counts the subexpressions and digits of integers:

LeafCount counts only the number of subexpressions:

With the default ComplexityFunction, Abs[x] is simpler than the FullForm of -x:

This complexity function makes Abs more expensive than Times:

ExcludedForms  (1)

This gives no simplification:

Excluding transformations of (x-2)^10 allows Simplify to expand the remaining terms:

TimeConstraint  (2)

This takes a long time, due to trigonometric expansion, but does not yield a simplification:

Use TimeConstraint to limit the time spent on any single transformation:

A similar example, where the transformation yields a simplification:

In this case, setting TimeConstraint prevents some simplification:

TransformationFunctions  (1)

Here Simplify uses t as the only transformation:

Here Simplify uses both t and all built-in transformations:

Trig  (1)

By default, Simplify uses trigonometric identities:

With Trig->False, Simplify does not use trigonometric identities:

Applications  (4)

Prove that a solution satisfies its equations:

Show that the arithmetic mean is larger than the geometric one:

This applies Fermat's little theorem:

Prove commutativity from Wolfram's minimal axiom for Boolean algebra:

Properties & Relations  (2)

Use Assuming to propagate assumptions:

Use FullSimplify to simplify expressions involving special functions:

Possible Issues  (2)

The Wolfram Language evaluates zero times a symbolic expression to zero:

This happens even if the symbolic expression is always infinite:

Because of this, results of simplification of expressions with singularities are uncertain:

In this case, FullSimplify recognizes the zero:

Results of simplification may depend on the names of symbols:

Introduced in 1988
 (1.0)
 |
Updated in 1996
 (3.0)
1999
 (4.0)
2000
 (4.1)
2002
 (4.2)
2003
 (5.0)
2014
 (10.0)