# Predefined Metrics in Symbolic Module

### Importing some of the predefined tensors. All the metrics are comprehensively listed in EinsteinPy documentation.


```python
from einsteinpy.symbolic.predefined import Schwarzschild, DeSitter, AntiDeSitter, Minkowski, find
from einsteinpy.symbolic import RicciTensor, RicciScalar
import sympy
from sympy import simplify

sympy.init_printing()  # for pretty printing
```

### Printing the metrics for visualization
All the functions return instances of :py:class:`~einsteinpy.symbolic.metric.MetricTensor`


```python
sch = Schwarzschild()
sch.tensor()
```


```python
Minkowski(c=1).tensor()
```


```python
DeSitter().tensor()
```


```python
AntiDeSitter().tensor()
```

### Calculating the scalar (Ricci) curavtures
They should be constant for De-Sitter and Anti-De-Sitter spacetimes.


```python
scalar_curvature_de_sitter = RicciScalar.from_metric(DeSitter())
scalar_curvature_anti_de_sitter = RicciScalar.from_metric(AntiDeSitter())
```


```python
scalar_curvature_de_sitter.expr
```


```python
scalar_curvature_anti_de_sitter.expr
```

On simplifying the expression we got above, we indeed obtain a constant


```python
simplify(scalar_curvature_anti_de_sitter.expr)
```

### Searching for a predefined metric
find function returns a list of available functions


```python
find("sitter")
```




    ['AntiDeSitter', 'AntiDeSitterStatic', 'DeSitter']



ea5595d2f910cb816d43b0615ef57b0816fab690
ipynb
Jupyter Notebook
EinsteinPy/Predefined Metrics in Symbolic Module.ipynb
IsaacW4/Advanced-GR
0351c368321b1a2375e2d328347f79b513be4c08
Apache-2.0
EinsteinPy/Predefined Metrics in Symbolic Module.ipynb
IsaacW4/Advanced-GR
0351c368321b1a2375e2d328347f79b513be4c08
Apache-2.0
EinsteinPy/Predefined Metrics in Symbolic Module.ipynb
IsaacW4/Advanced-GR
0351c368321b1a2375e2d328347f79b513be4c08
Apache-2.0
Qwen/Qwen-72B
1. YES
2. YES