equivalent rate of interest per payment period

Inputs

  • the periodic rate of interest
  • the number of interest conversion periods per pay

Outputs

  • equivalent rate of interest per payment period

Neuron type

Best algorithm has been found - locked

Patterns

Pattern Input Output
1.
the periodic rate of interest: 1
the number of interest conversion periods per pay: 2
equivalent rate of interest per payment period: 3
2.
the periodic rate of interest: 2
the number of interest conversion periods per pay: 3
equivalent rate of interest per payment period: 26
3.
the periodic rate of interest: 3
the number of interest conversion periods per pay: 1
equivalent rate of interest per payment period: 3

Applicable neurons

  • x to the a (xª)
  • x - 1
  • x + 1
  • Substring (from start to position)
  • character n
  • IF (1) THEN a ELSE b
  • get month from date (yyyy-mm-dd)
  • convert HH:MM:SS into seconds

Algorithm

Test

Code made by AI:
/**
 * 1: 
 *
 * @return {Array}
 */
function neuron501()
{
return [1];
}

/**
 * Plus (x + y): The addition of two whole numbers is the total amount of those quantities combined.
 *
 * @param x1 first number
 * @param x2 second number
 * @return {Array}
 */
function neuron1(x1, x2)
{
math.config({number: 'BigNumber', precision: 64}); return [math.eval(Number(x1) + '+'+Number(x2)).toString()];
}

/**
 * x + 1: 
 * 
 * @param x1 x
 * @return {Array}
 */
function neuron596(x1)
{
  var outputs = [];
  outputs[0] = x1;

  arr = neuron501();
  outputs[1] = arr[0];

  arr = neuron1(outputs[1], outputs[0]);
  outputs[2] = arr[0];

  return[outputs[2]];
}


/**
 * x to the a  (xª): value of the number x to be the power of a
 *
 * @param x1 x - The base
 * @param x2 a - The exponent
 * @return {Array}
 */
function neuron18(x1, x2)
{
return[Math.pow(Number(x1), Number(x2))];
}

/**
 * 1: 
 *
 * @return {Array}
 */
function neuron501()
{
return [1];
}

/**
 * Minus (x - y): 
 *
 * @param x1 Number X
 * @param x2 Number Y
 * @return {Array}
 */
function neuron2(x1, x2)
{
math.config({number: 'BigNumber', precision: 64}); return [math.eval(Number(x1) + '-'+Number(x2)).toString()];
}

/**
 * x - 1: 
 * 
 * @param x1 x
 * @return {Array}
 */
function neuron595(x1)
{
  var outputs = [];
  outputs[0] = x1;

  arr = neuron501();
  outputs[1] = arr[0];

  arr = neuron2(outputs[0], outputs[1]);
  outputs[2] = arr[0];

  return[outputs[2]];
}


/**
 * equivalent rate of interest per payment period: 
 * 
 * @param x1 the periodic rate of interest
 * @param x2 the number of interest conversion periods per  pay
 * @return {Array}
 */
function neuron656(x1, x2)
{
  var outputs = [];
  outputs[0] = x1;
  outputs[1] = x2;

  arr = neuron596(outputs[0]);
  outputs[2] = arr[0];

  arr = neuron18(outputs[2], outputs[1]);
  outputs[3] = arr[0];

  arr = neuron595(outputs[3]);
  outputs[4] = arr[0];

  return[outputs[4]];
}


Code made by AI:

Rodokmen - poznejte své předky | TOPlist U.I., Umělá inteligence