PHP: BC Math Functions - Manual in Deutsh
PHP: BC Math Functions - Manual in French
PHP: BC Math Functions - Manual in Polish

You Are At PHP: BC Math Functions - Manual Area


recent searches:
include functions , variable functions , post functions...




If you are new to PHP or just need to refresh your skills, this is the place to start. This series of tutorials will give you the basic knowledge you will need to create a simple PHP website.

PHP is a reflective programming language originally designed for producing dynamic web pages.[1] PHP is used mainly in server-side scripting, but can be used from a command line interface or in standalone graphical applications. Textual User Interfaces can also be created using ncurses.

PHP Manual
PrevNext

VII. BCMath Arbitrary Precision Mathematics Functions

Introduction

For arbitrary precision mathematics PHP offers the Binary Calculator which supports numbers of any size and precision, represented as strings.

Requirements

Since PHP 4.0.4, libbcmath is bundled with PHP. You don't need any external libraries for this extension.

Installation

These functions are only available if PHP was configured with --enable-bcmath. In PHP 3, these functions are only available if PHP was not configured with --disable-bcmath.

The windows version of PHP has built in support for this extension. You do not need to load any additional extension in order to use these functions.

Runtime Configuration

The behaviour of these functions is affected by settings in php.ini.

Table 1. BC math configuration options

NameDefaultChangeableChangelog
bcmath.scale"0"PHP_INI_ALL 
For further details and definitions of the PHP_INI_* constants, see the Appendix H.

Here's a short explanation of the configuration directives.

bcmath.scale integer

Number of decimal digits for all bcmath functions. See also bcscale().

Resource Types

This extension has no resource types defined.

Predefined Constants

This extension has no constants defined.

Table of Contents
bcadd -- Add two arbitrary precision numbers
bccomp -- Compare two arbitrary precision numbers
bcdiv -- Divide two arbitrary precision numbers
bcmod -- Get modulus of an arbitrary precision number
bcmul -- Multiply two arbitrary precision number
bcpow -- Raise an arbitrary precision number to another
bcpowmod -- Raise an arbitrary precision number to another, reduced by a specified modulus
bcscale -- Set default scale parameter for all bc math functions
bcsqrt -- Get the square root of an arbitrary precision number
bcsub -- Subtract one arbitrary precision number from another

Karma pedigree - Najlepsza dla twojego zwierzaka
fotograf ślubny lublin
raty
forma spółki
Wykaz informacyjny dodaj stronę

Another Useful functions:


ref.uodbc | ref.pdo-odbc | ref.pdo-odbc.connection | ref.bcompiler | ref.bc | function.pdo-pgsqllobcreate | function.pdf-setrgbcolor | function.pdf-setrgbcolor-stroke | function.pdf-setrgbcolor-fill | function.odbc-tables | function.odbc-tableprivileges | function.odbc-statistics | function.odbc-specialcolumns | function.odbc-setoption | function.odbc-rollback | function.odbc-result | function.odbc-result-all | function.odbc-procedures | function.odbc-procedurecolumns | function.odbc-primarykeys | function.odbc-prepare | function.odbc-pconnect | function.odbc-num-rows | function.odbc-num-fields | function.odbc-next-result | function.odbc-longreadlen | function.odbc-gettypeinfo | function.odbc-free-result | function.odbc-foreignkeys | function.odbc-field-type | function.odbc-field-scale | function.odbc-field-precision | function.odbc-field-num | function.odbc-field-name | function.odbc-field-len | function.odbc-fetch-row | function.odbc-fetch-object | function.odbc-fetch-into | function.odbc-fetch-array | function.odbc-execute | function.odbc-exec | function.odbc-errormsg | function.odbc-error | function.odbc-do | function.odbc-data-source | function.odbc-cursor | function.odbc-connect | function.odbc-commit | function.odbc-columns | function.odbc-columnprivileges | function.odbc-close | function.odbc-close-all | function.odbc-binmode | function.odbc-autocommit | function.mcrypt-cbc | function.is-subclass-of | function.ebcdic2ascii | function.cpdf-setrgbcolor | function.cpdf-setrgbcolor-stroke | function.cpdf-setrgbcolor-fill | function.bcsub | function.bcsqrt | function.bcscale | function.bcpowmod | function.bcpow | function.bcompiler-write-included-filename | function.bcompiler-write-header | function.bcompiler-write-functions-from-file | function.bcompiler-write-function | function.bcompiler-write-footer | function.bcompiler-write-file | function.bcompiler-write-exe-footer | function.bcompiler-write-constant | function.bcompiler-write-class | function.bcompiler-read | function.bcompiler-parse-class | function.bcompiler-load | function.bcompiler-load-exe | function.bcmul | function.bcmod | function.bcdiv | function.bccomp | function.bcadd | function.ascii2ebcdic |


PHP is a widely-used general-purpose scripting language that is especially suited for Web development and can be embedded into HTML. If you are new to PHP and want to get some idea of how it works, try the introductory tutorial. After that, check out the online manual, and the example archive sites and some of the other resources available in the links section.