function GetDebtCalculationval(arg_p, arg_n, arg_r) {
debugger;
var p = parseFloat(arg_p);
var n = parseFloat(arg_n);
var r = (parseFloat(arg_r) / 12) / 100;
var powerval = n * -1;
var step1 = Math.pow((1 + r), powerval);
var step2 = 1 - step1;
var step3 = step2 / r;
var result = p / step3;
return result;
}
function GetN_NumOfMonthViaMPA(principal, interest, monthlypayment) {
debugger;
var rate = interest / 100, noofpay = 12;
var nper1 = Math.log((1 - ((principal / monthlypayment) * (rate / noofpay))));
var nper2 = Math.log((1 + (rate / noofpay)));
nper = -(nper1 / nper2);
interestpaid = monthlypayment * nper - principal;
nper = -Math.round((nper1 / nper2));
return nper;
}
sadafsdsfdsfds
ReplyDeletedfsfdsfds
ReplyDelete