UPDATE: negative rate

Terry fastsnip-bcard1 at yahoo.com
Wed Mar 9 18:20:26 EST 2005

On Wednesday 09 March 2005 10:49, Vijay Vishvas Dharap wrote:
> First of all sorry for sending 3 messages.
> Ok let me clarify more.
> I browsed fin.c file from cvs from src/calculation directory.
> And I just used the functions[_fi_calc_interest and functions required
> by it] listed there as I cannot use the whole application as its ported
> only to linux.

First of all, let me clarify this point - that the financial equations and 
their implementation under gnucash are "ported only to Linux". 

The equations are implemented in standard C - there are no dependencies on the 
operating system of any kind. I have only tested and run the implementation 
using gcc on Linux, but they should compile (at least with gcc) under Windows 
or any other flavor of OS you desire. I would be surprised if they did not 
compile using any standard C compiler - there are no tricks that depend on 

Have you tried to compile the C implenetation in the gnucash source tree? If 
not, then why not. If you have tried to compile the original under your OS, 
then what results did you obtain from the compiler? If you obtained some 
error messages then that will point you in the direction of resolving the 
problems the compiler is having with the implementation, if one exists.

Why translate to another language and then assume the original is wrong 
because it does not agree with your translation?

> Furthermore I converted the functions listed in that place into java
> class for my work.
> I have attached the code that I used in java. Only minimal changes were
> done from actual C source code needed for compilation purposes.

If only minimal changes were made then you should the get competent help in 
deciding if the Java must also be placed under the GPL, since my original 
coyright would still be in place which would place the Java translation under 
the GPL. If you only use the Java yourself or at your company and do not 
distribute, this is not a problem. If you do distribute, you must do so under 
the provisions of the GPL.

> Now when I use this function of rate and provide the specified values,
> I get positive value of the rate.
> But same values when given to VB function rate, gives me negative rate.
> i.e. -1.98245150

First what "specified values" are you talking about - be specific and exact.

if the other implementation is giving different values from the gnucash 
implementation (i.e., the C implementation in the source tree - not your 
translation thereof into another language), then the other implentation is 
just plain wrong.

> Whenever the VB rate is giving positive values, the values by my rate
> function matches with the VB rate function. But for negative values, I
> don't get correct values.
> Now probably I am clearer about discrepancy I am talking about.

No - you are not clear at all - in order to know anything about what you 
trying to do you must give SPECIFIC and EXACT details of what numbers you 
used (ALL numbers for ALL variables, what results you obtained, what 
equations you are using just for starters. Giving vague acounts of what you 
have done, or think you have done, will not help in any manner whatsoever.


> Regards,
> Vijay
> > -----Original Message-----
> > From: Ludovic Nicolle [mailto:lnicolle at chezludo.com]
> > Sent: Wednesday, March 09, 2005 9:04 PM
> > To: Vijay Vishvas Dharap
> > Cc: Ludovic Nicolle
> > Subject: 3 messages already
> >
> > Hi Vijay,
> >
> > your message got through to the gnucash list, please don't send it
> > again.
> >
> > as for the answer, the question itself is not very clear so i don't
> > know which functions you are talking about. So if you have to clarify
> > things, please take the time to rewrite your mressage with better
> > context and details, but send it only once.
> >
> >
> > thank you.
> >
> >
> > Ludo


"A human being is part of the whole called by us the 
Universe. We experience ourselves, our thoughts and 
feelings as something separated from the rest --a kind 
of optical delusion of consciousness.
This delusion is a kind of prison for us, restricting 
us to our personal desires and to affection for a few 
persons nearest us. Our task must be to free ourselves 
from this prison by widening our circle of compassion 
to embrace all living creatures, and the whole of 
nature in its beauty."

Albert Einstein.
"We can't solve problems by using the same kind of 
thinking we used when we created them." 
--Albert Einstein


We have the best government money can buy, and it has.

Terry Boldt.     


You must decide: 

Are you a body with a soul or a soul with a body?

Terry Boldt


When you change the way you look at things, 
the things you look at change.

Paraphrasing Ben Franklin:

Those who sacrifice freedom for safety, have neither.

The exact quote:               

They that can give up essential liberty to obtain a little
temporary safety deserve neither liberty nor safety.
  Benjamin Franklin (1706 - 1790),
  US author, diplomat, inventor, physicist, politician, & printer
  Historical Review of Pennsylvania, 1759

A thought often repeated becomes an act, an act often
repeated becomes a habit, a habit often repeated,
a character and a settled character molds the very
destiny of man.

Man is the master of his own destiny.

"The Voice of Babaji", Page 236
What man thinks, that he becomes

Common sense is so very extraordinary 
for being for so very uncommon.

Terry Boldt
To say what is real,
Must be exactly what we feel,
To speak of the truth,
And be open this way,
Is to say what you mean,
And mean what you say.

Pearl Boldt
"If you don't know, you cannot teach, except by faith.
And faith implies doubt. Doubt and the resulting
repression of doubt breed fanaticism and intolerance.
Worse, they breed ignorance pretending to infallibility,
which breeds charlatans and blind followers."

"Muddy Tracks", Frank DeMarco, page xxv
"for without time,no thought of anything is possible;
without space, no conception of anything is possible and
without causation no consideration of anything is possible. And
again, time space and causation generally appear inter-related
in our consciousness not dependent of one another.
So the mind lives, moves and has its existence in these
three notions, which are necessarily finite, owing to
their perceptional value and without which we cannot think,
conceive or imagine anything. Deprived of these three,
the constitution of the mind breaks down."

"The Voice of Babaji", Page 442-443
"The definition of and the mystery and meaning of faith,
will open like a flower, only while sitting in silence.
Faith in something greater than oneself is tantamount to
a veil being withdrawn from the depths and distances
glimmering within, and a feeling of eternal hunger for
peace and fullness, for all that the distracted world
of today denies. It is not possible to discover the Real
and abide in it, except by our own experience."

"The Voice of Babaji", Page 444

More information about the gnucash-devel mailing list