public float dot(Vector4f vec) {
        if (null == vec) {
            logger.warning("Provided vector is null, 0 returned.");
            return 0;
        }
        return x * vec.x + y * vec.y + z * vec.z + w * vec.w;
    }
<code>dot</code> calculates the dot product of this vector with a
provided vector. If the provided vector is null, 0 is returned.

@param vec
           the vector to dot with this vector.
@return the resultant dot product of this vector and a given vector.
jme3-core/src/main/java/com/jme3/math/Vector4f.java