PYTHON void vorticityConfinement(MACGrid& vel, FlagGrid& flags, Real strength) {
	Grid<Vec3> velCenter(flags.getParent()), curl(flags.getParent()), force(flags.getParent());
	Grid<Real> norm(flags.getParent());
	
	GetCentered(velCenter, vel);
	CurlOp(velCenter, curl);
	GridNorm(norm, curl);
	KnConfForce(force, norm, curl, strength);
	KnAddForceField(flags, vel, force);
}
//! add Buoyancy force based on smoke density
PYTHON void print_dt_dx(FlagGrid& flags, Grid<Real>& density, MACGrid& vel) {
//	Vec3 f = - gravity * flags.getParent()->getDt() / flags.getParent()->getDx();
	std::cout << " flags.getParent()->getDt() " << flags.getParent()->getDt() << std::endl ;
	std::cout << " flags.getParent()->getDx() " << flags.getParent()->getDx() << std::endl ;
}
//! add Buoyancy force based on smoke density
PYTHON void addBuoyancy(FlagGrid& flags, Grid<Real>& density, MACGrid& vel, Vec3 gravity) {
	Vec3 f = - gravity * flags.getParent()->getDt() / flags.getParent()->getDx();
	KnAddBuoyancy(flags,density, vel, f);
}
//! add gravity forces to all fluid cells
PYTHON void addGravity(FlagGrid& flags, MACGrid& vel, Vec3 gravity) {    
	Vec3 f = gravity * flags.getParent()->getDt() / flags.getDx();
	KnAddForce(flags, vel, f);
}