Example 5. Calculate the mass of the material segment $AB$, if $A(-2,1,0), B(-1,3,5)$, and the density at each point $M$ is proportional to the distance from $M$ to $A$ with a proportionality coefficient $k$.
Solution. Let's write down the equations of the segment $A B$. As a directing vector of the segment $A B$, we can take the vector $\overrightarrow{A B}=(1,2,5)$. Then the equations of $A B$ are $x=-2+t, y=1+2 t, z=5 t, t \in[0 ; 1]$. Now let's compute the differential $d l$ of the length of the segment:

$$
d l=\sqrt{(d x)^{2}+(d y)^{2}+(d z)^{2}}=\sqrt{1^{2}+2^{2}+5^{2}} d t=\sqrt{30} d t
$$

Therefore, the mass of the material segment with density $\rho(t)=$ $=k \cdot|A M|=k \sqrt{t^{2}+(2 t)^{2}+(5 t)^{2}}=k \cdot \sqrt{30} t$ is

$$
m=\int_{0}^{\mathrm{I}} \rho(t) d l=30 k \int_{0}^{1} t d t=\left.30 k \cdot \frac{t^{2}}{2}\right|_{0} ^{1}=15 k
$$

Answer. $m=15 k$