What is New in Mathematica 5.1 Products
-----
 /
Mathematica
*String Manipulation
*DatabaseLink
*Binary Data I/O
*Additional Import/Export Formats
*Web Services
*Large-Scale Graph Layout
*Array Plotting
*Enhanced Linear Algebra Performance
<Piecewise
*Integration over Regions
*Event Handling
*Symbolic Differential Equations
*Cluster Analysis
*EquationTrekker
*MathematicaMark2004
*GUIKit
*Summary of Features
*Ask about this page
PreviousNext

Fully Integrated Piecewise Functions

See What's New in Wolfram Mathematica 6

Mathematica 5.1 introduces the unique capability of systemwide support for piecewise functions--functions with different definitions in different regions. More than 100 enhancements to solving, calculus, and other capabilities have been added to allow fully automatic handling of piecewise functions, whether entered explicitly using the new Piecewise function, or implicitly through functions like If, Max, Floor, or UnitStep.

Piecewise functionality is of wide-ranging importance across many different fields, especially in engineering. Mathematica 5.1 provides the first-ever unified system for general handling of arbitrary-dimension, arbitrarily nested piecewise functions.




More Details    

The following examples show the use of piecewise definitions with a number of standard Mathematica functions. Note that they work transparently throughout, not requiring the user to signal their presence to Mathematica beyond initial definition in any of the operations performed.

Example: Symbolic Manipulation of Piecewise Functions

Throughout Mathematica, piecewise functions are now automatically supported in symbolic operations. Mathematica supports traditional 2D formatting of piecewise definitions, for both output and input.

In[1]:=D[ Max[x, x^2], x ]

Out[1]:=



Example: Piecewise Integrals

Piecewise functions work with domain specification in Mathematica, enabling close-form solutions to a broad range of problems.

In[2]:=Assuming[x∈, ∫2 -
xx]

Out[2]:=



Example: Solving an Equation with Piecewise Elements

This differential equation involves two piecewise functions, UnitStep and Max.

In[3]:=DSolve[Max(t, t^2)
y(t) + y^′(t) θ(t) ∧y(0) 1, y(t),
t]

Out[3]:=



Example: Expanding Piecewise Definitions

In[4]:=

Out[4]:=


Related Links

Tutorials from The Mathematica Book  Tutorials from The Mathematica Book
Piecewise Functions
Advanced Topic: Logical and Piecewise Functions
  
Built-In Functions Reference Guide  Built-In Functions Reference Guide
Piecewise
PiecewiseExpand
$MaxPiecewiseCases
Boole
Clip
  
Additional Information  Additional Information
Technical Presentation: Piecewise Functions in Mathematica

Back to Top PreviousNext



 © 2008 Wolfram Research, Inc.  Terms of Use  Privacy Policy | [ja]