programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
• Campbell Ritchie
• Jeanne Boyarsky
• Ron McLeod
• Paul Clapham
• Liutauras Vilda
Sheriffs:
• paul wheaton
• Rob Spoor
• Devaka Cooray
Saloon Keepers:
• Stephan van Hulst
• Tim Holloway
• Carey Brown
• Frits Walraven
• Tim Moores
Bartenders:
• Mikalai Zaikin

# how to solve this problem?

Greenhorn
Posts: 2
• Number of slices to send:
Optional 'thank-you' note:
Dear Java Developers

Can anyone help me to solve this problem ... i do not understand so much this problem

I tried this:

Thank you

Sheriff
Posts: 7125
184
• Number of slices to send:
Optional 'thank-you' note:
Welcome to the Ranch!

When you post a program, please UseCodeTags (← that's a link). I've added them for you this time.

What exactly are you having trouble with? Please TellTheDetails.

Martin Unger
Greenhorn
Posts: 2
• Number of slices to send:
Optional 'thank-you' note:
Hi Thank you for editing

From exercise i should find with formula payment ={(1+i)^y*p*i}/{(1+i)^y-1)*12} ... i don't know what is 'i' from here
also input: the down payment on the loan for the house ...is this rate inters or first payment for the house
and last input: the monthly utility expenses ... i don't know which expenses

Marshal
Posts: 8869
637
• Number of slices to send:
Optional 'thank-you' note:

Martin Unger wrote:From exercise i should find with formula payment ={(1+i)^y*p*i}/{(1+i)^y-1)*12}

What a strange formula. I'm afraid not correct, missing or extra parentheses.
What meaning of "curly braces" are? Since it is not a function, i'm a bit confused. Well, I might forgot all these things already..

Bartender
Posts: 5466
212
• Number of slices to send:
Optional 'thank-you' note:
Apart from a missing '(' in the denominator, the formula is correct.
Unfortunately, in this form the formula is unrecognizable and
impossible to decipher and remember.

In this topic:

https://coderanch.com/t/624366/java/java/Writing-formula-Java

I give a much simpler to remember form, including a derivation.

The í' is simply the annual interest rate. What happens here, implicitly, is
that we are dealing with a normal annuity loan, where the annual payment
is calculated, given the duration n, the face value p of the loan, and in annual
interest rate i.

So, in fact, the outcome would be that you pay back the whole loan if you do
just one payment, at the end of every year t (t = 1, 2, ..., n).
But these bankmen then divide the year payment by 12, and let you pay
that amount every month. In effect, you then have a real interest rate that
is slightly more than the communicated interest rate 'i'. Hmm... not nice,
but standard practise.

That's where the '12' in the denominator is coming from.

After this long introduction
the monthly payment can be calculated with the given horrible formula,
but taking as loan (the 'p' in the formula) the price of the house minus the
down payment. Well, I just had a look up of what 'down payment' is via
Google Translate, and it is the initial payment, the part of the house price that you
pay with own money. Correct me if I'm wrong here.

The monthly utility expenses are input.

The interest rate should also be input, somewhere. Strange that it is not mentioned
in the exercise.

Finally, the last question is a bit strange. Are you supposed to simply
add up the total monthly payments, for as long as the loan is not
fully repaid? Or are you supposed to calculate the so called present value
of all these payments? Is that given somewhere in the text book?

Greetz,
Piet

 Consider Paul's rocket mass heater.