TI-BASIC:Logbase

From Learn @ Cemetech
Jump to navigationJump to search

LogBASE.gif

Command Summary

Allows you to find the log of a number using any base you want

Command Syntax

logBASE(value,base)

Menu Location

Press:

  1. ALPHA, then F2 (which is located over the WINDOW button)
  2. 5 or arrow keys to move down to logBASE(

or

  1. MATH
  2. A or arrow keys to move down to logBASE(

Calculator Compatibility

TI-84+SE with TI-OS 2.53 MP

Token Size

2 byte

The logBASE( command is an upgrade from the log( command allowing you to input any base you want rather than being restricted to base 10. The command searches for the exponent that base b must be raised to get the given value.

This command can be used on both the home screen and while programming. If you are using CLASSIC mode, the command looks like below:

logBASE(8,2)
            3

But in MATHPRINT mode, looks like the below:

log,,2,,(8) @<            >@3

Formulas

The log in base b can also be found using the Ln( or Log( commands. This is shown below:

<math> \log_bx = {\ln x \over \ln b} = {\log x \over \log b} </math>

Where in the case of the calculator, base c is 10. In other words, the two entries below are equivalent:


ln(x)/ln(b

can be

logBASE(x,b


The logBASE( command in this case saves one byte, so it is a minor optimization. However, for compatibility across calculators it would be better to use the traditional method in programs as it is only a byte more yet can be used by calculators that do not have the 2.53 MP OS.

Error Conditions

Related Commands