<commit_before>
#pragma once

#include <ionCore.h>
#include <cmath>

#include "Constants.h"


template <typename T>
T Abs(T const value)
{
	return std::abs(value);
}

//! \brief Template function for selecting from two values the one with larger magnitude
//! The absolute values of a and b are compared, but the original values of a or b
//! are returned.
template <typename T>
static T const MaxAbs(T const a, T const b)
{
	return Abs(b) < Abs(a) ? a : b;
}


template <typename T>
T Sin(T const value)
{
	return sin(value);
}

template <typename T>
T Cos(T const value)
{
	return cos(value);
}

template <typename T>
T Tan(T const value)
{
	return tan(value);
}

template <typename T>
T ArcTan(T const value)
{
	return atan(value);
}

template <typename T>
T ArcTan(T const y, T const x)
{
	return atan2(y, x);
}

template <typename T>
T Sqrt(T const value)
{
	return sqrt(value);
}

template <typename T>
T DegToRad(T const degrees)
{
	return degrees * Constants<T>::Pi() / 180;
}

template <typename T>
T RadToDeg(T const radians)
{
	return radians * 180 / Constants<T>::Pi();<commit_msg>[ionMath] Fix compiler warnings from compiling vec2i with Length<commit_after>
#pragma once

#include <ionCore.h>
#include <cmath>

#include "Constants.h"


template <typename T>
T Abs(T const value)
{
	return std::abs(value);
}

//! \brief Template function for selecting from two values the one with larger magnitude
//! The absolute values of a and b are compared, but the original values of a or b
//! are returned.
template <typename T>
static T const MaxAbs(T const a, T const b)
{
	return Abs(b) < Abs(a) ? a : b;
}


template <typename T>
T Sin(T const value)
{
	return sin(value);
}

template <typename T>
T Cos(T const value)
{
	return cos(value);
}

template <typename T>
T Tan(T const value)
{
	return tan(value);
}

template <typename T>
T ArcTan(T const value)
{
	return atan(value);
}

template <typename T>
T ArcTan(T const y, T const x)
{
	return atan2(y, x);
}

template <typename T>
T Sqrt(T const value)
{
	return (T) sqrt(value);
}

template <typename T>
T DegToRad(T const degrees)
{
	return degrees * Constants<T>::Pi() / 180;
}

template <typename T>
T RadToDeg(T const radians)
{
	return radians * 180 / Constants<T>::Pi();
{'fraction_non_alphanumeric': 0.1249442213297635, 'fraction_numerical': 0.006693440428380187, 'mean_word_length': 4.189814814814815, 'pattern_counts': {'":': 0, '<': 33, '<?xml version=': 0, '>': 31, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2928150', 'n_tokens_mistral': 828, 'n_tokens_neox': 793, 'n_words': 302}