# Differences

This shows you the differences between two versions of the page.

 — documentation:ref:eliminatemetrics [2015/11/21 12:33] (current) Line 1: Line 1: + ====== EliminateMetrics ====== + ---- + + ====Description==== + * ''​EliminateMetrics''​ eliminates contractions with [[metric_tensor|metric tensors]] and [[Kronecker delta|Kronecker deltas]] in any part of expression. + + + * ''​EliminateMetrics''​ eliminates metrics for all types of indices, for who metric is defined. ​ + + * ''​EliminateMetrics''​ eliminates Kroneckers for all types of indices (even if no metric is defined for this type). ​ + ====Examples==== + ---- + Eliminate metric tensor and Kronecker delta: + + println EliminateMetrics >> '​g_nm*A^m*d^n_a'​.t + ​ + + > A_a + ​ + ---- + Eliminate metric tensors in ''​D''​ dimensions: + + def t = ('​g^mn*g^ab*g^gd*(p_g*g_ba + p_a*g_bg)*(p_m*g_dn + p_n*g_dm)'​).t + //eliminate metrics in D dimensions ​               ​ + println ((EliminateMetrics & 'd_a^a = D'.t) >> t) + ​ + + > 2*(1+D)*p^{d}*p_{d} + ​ + ---- + Eliminate metric tensors for different types of indices: + + def t = '​g_mn*A^mn + g_\\alpha\\beta*B^\\alpha\\beta + g_AB*C^AB'​.t + println ​ EliminateMetrics >> t + ​ + + > A_{n}^{n}+B_{\beta}^{\beta}+C_{B}^{B} + ​ + ---- + ====See also==== + * Related guides: [[documentation:​guide:​applying_and_manipulating_transformations]],​ [[documentation:​guide:​list_of_transformations]] + * Related transformations:​ [[documentation:​ref:​expandandeliminate]] + * Related reference material: [[documentation:​ref:​metric_tensor]],​ [[documentation:​ref:​kronecker_delta]] + * JavaDocs: [[http://​api.redberry.cc/​redberry/​1.1.9/​java-api/​cc/​redberry/​core/​transformations/​EliminateMetricsTransformation.html|EliminateMetricsTransformation]] + * Source code: [[https://​bitbucket.org/​redberry/​redberry/​src/​tip/​core/​src/​main/​java/​cc/​redberry/​core/​transformations/​EliminateMetricsTransformation.java|EliminateMetricsTransformation.java]]