This shows you the differences between two versions of the page.
|
documentation:ref:expanddenominator [2015/11/21 12:33] |
documentation:ref:expanddenominator [2015/11/21 12:33] (current) |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ====== ExpandDenominator ====== | ||
| + | ---- | ||
| + | |||
| + | ====Description==== | ||
| + | * ''ExpandDenominator'' expands out products and powers that appear as denominators in expressions. | ||
| + | | ||
| + | | ||
| + | * ''ExpandDenominator[transformations]'' additionally applies transformations at each level of expand procedure. | ||
| + | |||
| + | |||
| + | * ''ExpandDenominator'' works only on negative integer powers. | ||
| + | |||
| + | |||
| + | * ''ExpandDenominator'' applies only to the top level in expressions. | ||
| + | |||
| + | |||
| + | ====Examples==== | ||
| + | ---- | ||
| + | Expand the denominator of a fraction: | ||
| + | <sxh groovy; gutter: false> | ||
| + | println ExpandDenominator >> '(x - 1) * (x - 2)/((x - 3) * (x - 4))'.t | ||
| + | </sxh> | ||
| + | <sxh plain; gutter: false> | ||
| + | > (x-1)*(x-2)/(x**2 - 7*x +12) | ||
| + | </sxh> | ||
| + | |||
| + | ---- | ||
| + | |||
| + | Expand the denominator in each term: | ||
| + | <sxh groovy; gutter: false> | ||
| + | println ExpandDenominator >> '1/(1 + x) + 2/(2 + x)**2 + 3/(3 + x)**3'.t | ||
| + | </sxh> | ||
| + | <sxh plain; gutter: false> | ||
| + | > 1/(1 + x) + 2/(4 + 4*x + x**2) + 3/(27 + 27*x + 9*x**2 + x**3) | ||
| + | </sxh> | ||
| + | |||
| + | ---- | ||
| + | |||
| + | ====Details==== | ||
| + | |||
| + | ''ExpandDenominator[transformations]'' additionally applies transformations at each level of expand procedure: | ||
| + | <sxh groovy; gutter: false> | ||
| + | def t = '1/((k_a - p_a)*(k^a + p^a))'.t | ||
| + | println ExpandDenominator['k_a*k^a = 0'.t] >> t | ||
| + | </sxh> | ||
| + | <sxh plain; gutter: false> | ||
| + | > -1/(p_a*p^a) | ||
| + | </sxh> | ||
| + | For more examples see [[documentation:ref:expand#details|Expand]]. | ||
| + | |||
| + | ====See also==== | ||
| + | * Related guides: [[documentation:guide:applying_and_manipulating_transformations]], [[documentation:guide:list_of_transformations]] | ||
| + | * Related transformations: [[documentation:ref:expand]], [[documentation:ref:expandnumerator]], [[documentation:ref:expandall]] | ||
| + | * JavaDocs: [[http://api.redberry.cc/redberry/1.1.9/java-api/cc/redberry/core/transformations/expand/ExpandDenominatorTransformation.html|ExpandDenominatorTransformation]] | ||
| + | * Source code: [[https://bitbucket.org/redberry/redberry/src/tip/core/src/main/java/cc/redberry/core/transformations/expand/ExpandDenominatorTransformation.java|ExpandDenominatorTransformation.java]] | ||