[docs]classPointMass(MassProfile):def__init__(self,centre:Tuple[float,float]=(0.0,0.0),einstein_radius:float=1.0):""" Represents a point-mass. Parameters ---------- centre The (y,x) arc-second coordinates of the profile centre. einstein_radius The arc-second Einstein radius of the point-mass. """super().__init__(centre=centre,ell_comps=(0.0,0.0))self.einstein_radius=einstein_radiusdefconvergence_2d_from(self,grid:aa.type.Grid2DLike,**kwargs):squared_distances=np.square(grid[:,0]-self.centre[0])+np.square(grid[:,1]-self.centre[1])central_pixel=np.argmin(squared_distances)convergence=np.zeros(shape=grid.shape[0])# convergence[central_pixel] = np.pi * self.einstein_radius ** 2.0returnconvergence@aa.grid_dec.to_arraydefpotential_2d_from(self,grid:aa.type.Grid2DLike,**kwargs):returnnp.zeros(shape=grid.shape[0])@aa.grid_dec.to_vector_yx@aa.grid_dec.transform@aa.grid_dec.relocate_to_radial_minimumdefdeflections_yx_2d_from(self,grid:aa.type.Grid2DLike,**kwargs):grid_radii=self.radial_grid_from(grid=grid,**kwargs)returnself._cartesian_grid_via_radial_from(grid=grid,radius=self.einstein_radius**2/grid_radii)@propertydefis_point_mass(self):returnTrue