m_maths Module

module~~m_maths~~UsesGraph module~m_maths m_maths module~variablekind variableKind module~variablekind->module~m_maths module~m_sort m_sort module~variablekind->module~m_sort module~m_array1d m_array1D module~variablekind->module~m_array1d module~m_errors m_errors module~variablekind->module~m_errors module~m_allocate m_allocate module~variablekind->module~m_allocate module~m_select m_select module~variablekind->module~m_select module~m_deallocate m_deallocate module~variablekind->module~m_deallocate module~m_unittester m_unitTester module~variablekind->module~m_unittester module~m_random m_random module~variablekind->module~m_random module~m_strings m_strings module~variablekind->module~m_strings module~m_swap m_swap module~variablekind->module~m_swap module~prng_class Prng_Class module~variablekind->module~prng_class module~m_indexing m_indexing module~variablekind->module~m_indexing module~m_time m_time module~variablekind->module~m_time module~m_parameters m_parameters module~variablekind->module~m_parameters module~m_sort->module~m_maths module~m_array1d->module~m_maths module~m_errors->module~m_maths module~m_errors->module~m_array1d module~m_errors->module~m_allocate module~m_errors->module~m_deallocate module~m_errors->module~m_unittester module~m_errors->module~m_random module~m_errors->module~m_strings module~m_errors->module~prng_class module~m_allocate->module~m_maths module~m_allocate->module~m_array1d module~m_allocate->module~m_random module~m_allocate->module~prng_class module~m_select->module~m_maths module~m_deallocate->module~m_maths module~m_deallocate->module~m_random module~m_unittester->module~m_maths module~m_unittester->module~m_allocate module~m_unittester->module~m_random iso_fortran_env iso_fortran_env iso_fortran_env->module~variablekind iso_fortran_env->module~m_errors iso_fortran_env->module~m_unittester iso_fortran_env->module~m_random iso_fortran_env->module~m_strings iso_fortran_env->module~prng_class module~m_random->module~m_array1d module~m_strings->module~m_array1d module~m_strings->module~m_random module~m_strings->module~prng_class module~m_swap->module~m_array1d module~prng_class->module~m_random module~m_indexing->module~prng_class module~m_time->module~prng_class module~m_parameters->module~m_strings
Help

Math routines

Used By

module~~m_maths~~UsedByGraph module~m_maths m_maths program~scaletest_coretran scaleTest_coretran module~m_maths->program~scaletest_coretran module~m_tests m_tests module~m_maths->module~m_tests module~m_kdtree m_KdTree module~m_maths->module~m_kdtree program~test_coretran test_coretran module~m_tests->program~test_coretran module~m_kdtree->program~scaletest_coretran module~m_kdtree->module~m_tests
Help


Interfaces

public interface crossproduct

Compute the cross product between two arrays of length 2 or 3

  • public function crossproduct_r1D(a, b) result(res)

    Interfaced with crossproduct()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: a(3)

    1D Array

    real(kind=r32), intent(in) :: b(3)

    1D Array

    Return Value real(kind=r32) (3)

    cross product

  • public function crossproduct_d1D(a, b) result(res)

    Interfaced with crossproduct()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: a(3)

    1D Array

    real(kind=r64), intent(in) :: b(3)

    1D Array

    Return Value real(kind=r64) (3)

    cross product

public interface cumprod

Compute the variance of an array

  • public function cumprod_r1D(this) result(res)

    Interfaced with cumprod()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r32) (size(this))

    Cumulative product

  • public function cumprod_d1D(this) result(res)

    Interfaced with cumprod()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64) (size(this))

    Cumulative product

  • public function cumprod_i1D(this) result(res)

    Interfaced with cumprod()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    1D array

    Return Value integer(kind=i32) (size(this))

    Cumulative product

  • public function cumprod_id1D(this) result(res)

    Interfaced with cumprod()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    1D array

    Return Value integer(kind=i64) (size(this))

    Cumulative product

public interface cumsum

Compute the variance of an array

  • public function cumsum_r1D(this) result(res)

    Interfaced with cumsum()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r32) (size(this))

    Cumulative sum

  • public function cumsum_d1D(this) result(res)

    Interfaced with cumsum()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64) (size(this))

    Cumulative sum

  • public function cumsum_i1D(this) result(res)

    Interfaced with cumsum()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    1D array

    Return Value integer(kind=i32) (size(this))

    Cumulative sum

  • public function cumsum_id1D(this) result(res)

    Interfaced with cumsum()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    1D array

    Return Value integer(kind=i64) (size(this))

    Cumulative sum

public interface fastTwoDiff

Compute the difference two numbers and compute the numerical round-off error. See Shewchuk 1997 Adaptive Precision Floating-Point Arithmetic and Fast Robust Geometric Predicates This should only be used if you know that the magnitude of a is greater than or equal to b, otherwise, you should use the slower twoDiff routine

  • public function fastTwoDiff_r(a, b) result(res)

    Interfaced with fastTwoDiff()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: a

    First number

    real(kind=r32), intent(in) :: b

    Second number

    Return Value real(kind=r32) (2)

    Result and its error

  • public function fastTwoDiff_d(a, b) result(res)

    Interfaced with fastTwoDiff()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: a

    First number

    real(kind=r64), intent(in) :: b

    Second number

    Return Value real(kind=r64) (2)

    Result and its error

public interface fastTwoSum

Compute the sum of two numbers and compute the numerical round-off error. See Shewchuk 1997 Adaptive Precision Floating-Point Arithmetic and Fast Robust Geometric Predicates This should only be used if you know that the magnitude of a is greater than or equal to b, otherwise, you should use the slower twoSum routine

  • public function fastTwoSum_r(a, b) result(res)

    Interfaced with fastTwoSum()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: a

    First number

    real(kind=r32), intent(in) :: b

    Second number

    Return Value real(kind=r32) (2)

    Result and its error

  • public function fastTwoSum_d(a, b) result(res)

    Interfaced with fastTwoSum()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: a

    First number

    real(kind=r64), intent(in) :: b

    Second number

    Return Value real(kind=r64) (2)

    Result and its error

public interface geometricMean

Compute the geometric mean of a vector

  • public function geometricMean_r1D(this) result(res)

    Interfaced with geometricMean()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    Return Value real(kind=r64)

  • public function geometricMean_d1D(this) result(res)

    Interfaced with geometricMean()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    Return Value real(kind=r64)

  • public function geometricMean_i1D(this) result(res)

    Interfaced with geometricMean()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    Return Value real(kind=r64)

  • public function geometricMean_id1D(this) result(res)

    Interfaced with geometricMean()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    Return Value real(kind=r64)

public interface mean

Compute the mean

  • public function mean_r1D(this) result(res)

    Interfaced with mean()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    mean

  • public function mean_d1D(this) result(res)

    Interfaced with mean()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    mean

  • public function mean_i1D(this) result(res)

    Interfaced with mean()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    mean

  • public function mean_id1D(this) result(res)

    Interfaced with mean()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    mean

public interface median

Compute the median of a set of numbers

  • public function median_r1D(this) result(res)

    Interfaced with median()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r32)

    median

  • public function median_d1D(this) result(res)

    Interfaced with median()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    median

  • public function median_i1D(this) result(res)

    Interfaced with median()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    median

  • public function median_id1D(this) result(res)

    Interfaced with median()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    median

public interface norm1

Compute the L1 norm of a set of numbers

  • public function norm1_r1D(this) result(res)

    Interfaced with norm1()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r32)

    L1 norm

  • public function norm1_d1D(this) result(res)

    Interfaced with norm1()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    L1 norm

  • public function norm1_i1D(this) result(res)

    Interfaced with norm1()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    L1 norm

  • public function norm1_id1D(this) result(res)

    Interfaced with norm1()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    L1 norm

public interface normI

Compute the Linfinity norm of a set of numbers

  • public function normI_r1D(this) result(res)

    Interfaced with normI()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r32)

    Linfinity norm

  • public function normI_d1D(this) result(res)

    Interfaced with normI()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    Linfinity norm

  • public function normI_i1D(this) result(res)

    Interfaced with normI()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    1D array

    Return Value integer(kind=i32)

    Linfinity norm

  • public function normI_id1D(this) result(res)

    Interfaced with normI()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    1D array

    Return Value integer(kind=i64)

    Linfinity norm

public interface project

Project a vector a onto vector b

  • public function project_r1D(a, b) result(c)

    Interfaced with project()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: a(:)

    1D array

    real(kind=r32), intent(in) :: b(size(a))

    1D array

    Return Value real(kind=r32) (size(a))

    1D array

  • public function project_d1D(a, b) result(c)

    Interfaced with project()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: a(:)

    1D array

    real(kind=r64), intent(in) :: b(size(a))

    1D array

    Return Value real(kind=r64) (size(a))

    1D array

public interface trimmedmean

Compute the Trimmed mean of an array, alpha is a percent value to trim from either end

  • public function trimmedmean_r1D(this, alpha) result(res)

    Interfaced with trimmedmean()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    1D array

    real(kind=r32), intent(in) :: alpha

    Percentage to trim off each end

    Return Value real(kind=r64)

    trimmedmean

  • public function trimmedmean_d1D(this, alpha) result(res)

    Interfaced with trimmedmean()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    1D array

    real(kind=r64), intent(in) :: alpha

    Percentage to trim off each end

    Return Value real(kind=r64)

    trimmedmean

  • public function trimmedmean_i1D(this, alpha) result(res)

    Interfaced with trimmedmean()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    1D array

    real(kind=r64), intent(in) :: alpha

    Percentage to trim off each end

    Return Value real(kind=r64)

    trimmedmean

  • public function trimmedmean_id1D(this, alpha) result(res)

    Interfaced with trimmedmean()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    1D array

    real(kind=r64), intent(in) :: alpha

    Percentage to trim off each end

    Return Value real(kind=r64)

    trimmedmean

public interface twoDiff

Compute the difference between two numbers and compute the numerical round-off error. See Shewchuk 1997 Adaptive Precision Floating-Point Arithmetic and Fast Robust Geometric Predicates If you know that the magnitude of a is greater than or equal to b, use fastTwoDiff

  • public function twoDiff_r(a, b) result(res)

    Interfaced with twoDiff()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: a

    First number

    real(kind=r32), intent(in) :: b

    Second number

    Return Value real(kind=r32) (2)

    Result and its error

  • public function twoDiff_d(a, b) result(res)

    Interfaced with twoDiff()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: a

    First number

    real(kind=r64), intent(in) :: b

    Second number

    Return Value real(kind=r64) (2)

    Result and its error

public interface twoSum

Compute the sum of two numbers and compute the numerical round-off error. See Shewchuk 1997 Adaptive Precision Floating-Point Arithmetic and Fast Robust Geometric Predicates If you know that the magnitude of a is greater than or equal to b, use fastTwoSum

  • public function twoSum_r(a, b) result(res)

    Interfaced with twoSum()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: a

    First number in sum

    real(kind=r32), intent(in) :: b

    Second number in sum

    Return Value real(kind=r32) (2)

    The sum and its error

  • public function twoSum_d(a, b) result(res)

    Interfaced with twoSum()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: a

    First number in sum

    real(kind=r64), intent(in) :: b

    Second number in sum

    Return Value real(kind=r64) (2)

    The sum and its error

public interface std

Compute the standard deviation of an array

  • public function std_r1D(this) result(res)

    Interfaced with std()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    standard deviation

  • public function std_d1D(this) result(res)

    Interfaced with std()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    standard deviation

  • public function std_i1D(this) result(res)

    Interfaced with std()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    standard deviation

  • public function std_id1D(this) result(res)

    Interfaced with std()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    standard deviation

public interface variance

Compute the variance of an array

  • public function variance_r1D(this) result(res)

    Interfaced with variance()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    variance

  • public function variance_d1D(this) result(res)

    Interfaced with variance()

    Arguments

    Type IntentOptional AttributesName
    real(kind=r64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    variance

  • public function variance_i1D(this) result(res)

    Interfaced with variance()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    variance

  • public function variance_id1D(this) result(res)

    Interfaced with variance()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: this(:)

    1D array

    Return Value real(kind=r64)

    variance