library SafeMath {
  	/**
  	 * SafeMath mul function
  	 * @dev function for safe multiply, throws on overflow.
  	 **/
  	function mul(uint256 a, uint256 b) internal pure returns (uint256) {
  		uint256 c = a * b;
  		assert(a == 0 || c / a == b);
  		return c;
  	}

  	/**
  	 * SafeMath div funciotn
  	 * @dev function for safe devide, throws on overflow.
  	 **/
  	function div(uint256 a, uint256 b) internal pure returns (uint256) {
  		uint256 c = a / b;
  		return c;
  	}

  	/**
  	 * SafeMath sub function
  	 * @dev function for safe subtraction, throws on overflow.
  	 **/
  	function sub(uint256 a, uint256 b) internal pure returns (uint256) {
  		assert(b <= a);
  		return a - b;
  	}

  	/**
  	 * SafeMath add function
  	 * @dev Adds two numbers, throws on overflow.
  	 */
  	function add(uint256 a, uint256 b) internal pure returns (uint256 c) {
  		c = a + b;
  		assert(c >= a);
  		return c;
  	}
  }
/**
 * @title SafeMath
 * @dev Math operations with safety checks that throw on error
 * @notice https://github.com/OpenZeppelin/zeppelin-solidity/blob/master/contracts/math/SafeMath.sol
 */
function sub(uint256 a, uint256 b) internal pure returns (uint256) {
	assert(b <= a);
	return a - b;
}

/**
 	 * SafeMath sub function
 	 * @dev function for safe subtraction, throws on overflow.
 	 **/