# Plotting Spatial Hypersurface Embedding for Schwarzschild Spacetime¶

```
[1]:
```

```
from einsteinpy.hypersurface import SchwarzschildEmbedding
from einsteinpy.plotting import HypersurfacePlotter
from astropy import units as u
```

Declaring embedding object with specified mass of the body and plotting the embedding hypersurface for Schwarzschild spacetime

```
[2]:
```

```
surface_obj = SchwarzschildEmbedding(5.927e23 * u.kg)
```

```
[3]:
```

```
surface = HypersurfacePlotter(embedding=surface_obj, plot_type='surface')
surface.plot()
surface.show()
```

The plotted embedding has initial Schwarzschild radial coordinate to be greater than schwarzschild radius but the embedding can be defined for coordinates greater than 9m/4. The Schwarzschild spacetime is a static spacetime and thus the embeddings can be obtained by considering fermat’s surfaces of stationary time coordinate and thus this surface also represent the spacial geometry on which light rays would trace their paths along geodesics of this surface (spacially)!