This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
documentation:ref:expandtensors [2015/11/20 20:42] poslavskysv [Examples] |
documentation:ref:expandtensors [2015/11/20 20:45] poslavskysv [Examples] |
||
---|---|---|---|
Line 41: | Line 41: | ||
<sxh plain; gutter: false> | <sxh plain; gutter: false> | ||
> (c+r)*(c+d)*(a+b)**2*f_a*f^a + (c+r)*((a+b)*(c+d)*(k+i) + | > (c+r)*(c+d)*(a+b)**2*f_a*f^a + (c+r)*((a+b)*(c+d)*(k+i) + | ||
- | (a + c))*t_a*(a+b)*f^a + (c+r)*(a+b)*(c+d)*f_a*(c+d)*t^a | + | (a + c))*(a+b)*t_a*f^a + (c+r)*(a+b)*(c+d)*(c+d)*f_a*t^a |
- | + (c+r)*((a+b)*(c+d)*(k+i) + (a + c))*t_a*(c+d)*t^a | + | + (c+r)*((a+b)*(c+d)*(k+i) + (a + c))*(c+d)*t_a*t^a |
</sxh> | </sxh> | ||
+ | |||
+ | ---- | ||
+ | Specify additional simplifications: | ||
+ | |||
+ | <sxh groovy; gutter: false> | ||
+ | def simplify = 'f_a*f^a = a'.t & 'f_a*t^a = b'.t & 't_a*t^a = c'.t | ||
+ | def t = '(2*(c+a)-164*a)*(f_{a}+t_{a})*f^{a}'.t | ||
+ | println ExpandTensors[simplify] >> t | ||
+ | </sxh> | ||
+ | <sxh plain; gutter: false> | ||
+ | > a*(-164*a+2*(c+a))+b*(-164*a+2*(c+a)) | ||
+ | </sxh> | ||
+ | |||
====See also==== | ====See also==== | ||
* Related guides: [[documentation:guide:applying_and_manipulating_transformations]], [[documentation:guide:list_of_transformations]] | * Related guides: [[documentation:guide:applying_and_manipulating_transformations]], [[documentation:guide:list_of_transformations]] |