]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/fortran/doc/gfortran/intrinsic-procedures/log10.rst
sphinx: add missing trailing newline
[thirdparty/gcc.git] / gcc / fortran / doc / gfortran / intrinsic-procedures / log10.rst
CommitLineData
c63539ff
ML
1..
2 Copyright 1988-2022 Free Software Foundation, Inc.
3 This is part of the GCC manual.
4 For copying conditions, see the copyright.rst file.
5
6.. _log10:
7
8.. index:: LOG10
9
10.. index:: ALOG10
11
12.. index:: DLOG10
13
14.. index:: exponential function, inverse
15
16.. index:: logarithm function with base 10
17
18.. index:: base 10 logarithm function
19
20LOG10 --- Base 10 logarithm function
21************************************
22
23.. function:: LOG10(X)
24
25 ``LOG10(X)`` computes the base 10 logarithm of :samp:`{X}`.
26
27 :param X:
28 The type shall be ``REAL``.
29
30 :return:
31 The return value is of type ``REAL`` or ``COMPLEX``.
32 The kind type parameter is the same as :samp:`{X}`.
33
34 Standard:
35 Fortran 77 and later
36
37 Class:
38 Elemental function
39
40 Syntax:
41 .. code-block:: fortran
42
43 RESULT = LOG10(X)
44
45 Example:
46 .. code-block:: fortran
47
48 program test_log10
49 real(8) :: x = 10.0_8
50 x = log10(x)
51 end program test_log10
52
53 Specific names:
54 .. list-table::
55 :header-rows: 1
56
57 * - Name
58 - Argument
59 - Return type
60 - Standard
61
62 * - ``ALOG10(X)``
63 - ``REAL(4) X``
64 - ``REAL(4)``
65 - Fortran 77 and later
66 * - ``DLOG10(X)``
67 - ``REAL(8) X``
68 - ``REAL(8)``
3ed1b4ce 69 - Fortran 77 and later