fn apply_body_forces(&mut self) {
        for i in 0..self.w {
            for j in 0..self.h {
                *self.u.get_mut(i, j) += self.gravity.0;
                *self.v.get_mut(i, j) += self.gravity.1;
            }
        }
    }
/// Apply body forces (such as gravity) to the entire fluid.
Apply body forces (such as gravity) to the entire fluid.
Apply body forces ( such as gravity ) to the entire fluid .
fn apply_body_forces(&mut self) {
        for i in 0..self.w {
            for j in 0..self.h {
                *self.u.get_mut(i, j) += self.gravity.0;
                *self.v.get_mut(i, j) += self.gravity.1;
            }
        }
    }
fn apply_body_forces ( & mut self ) { for i in 0 .. self . w { for j in 0 .. self . h { * self . u . get_mut ( i , j ) += self . gravity . 0 ; * self . v . get_mut ( i , j ) += self . gravity . 1 ; } } }
Apply body forces (such as gravity) to the entire fluid.
Apply body forces ( such as gravity ) to the entire fluid .
&mut self
&mut self