[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Same .m file: different results with different versions of Octave
From: |
Søren Hauberg |
Subject: |
Re: Same .m file: different results with different versions of Octave |
Date: |
Mon, 19 Apr 2010 12:00:27 -0700 |
man, 19 04 2010 kl. 11:47 -0700, skrev Thomas D. Dean:
> On Mon, 2010-04-19 at 11:05 -0700, Søren Hauberg wrote:
>
> > I don't understand why
> >
> > (inf + inf * i) / (inf + inf * i)
> >
> > should equal
> >
> > 1 + 0 * i.
> >
> > I can understand why the 'tanh' call should give this result, but once
> > you actually evaluate 'sinh' and 'cosh' and perform the division
> > manually I don't see why you should get 1.
> >
> > Could you elaborate on this?
>
> I copied the code and made the output modifications to emulate the c++
> code. I think the output of sin()/cos() should be 1 + 0 * i, not the
> (inf... values.
Why? If 'sinh' returns infinity and 'cosh' also returns infinity,
shouldn't the division of their results be NaN? It seems to me that you
claim that
(Inf + Inf * i) / (Inf + Inf * i) = 1
which just doesn't make sense to me. In the specific case where the
infinite numbers came from 'sinh' and 'cosh' it might make mathematical
sense, but in the general setting I don't see how the above equation
could ever hold.
Søren
- Re: Same .m file: different results with different versions of Octave, (continued)
- Re: Same .m file: different results with different versions of Octave, Søren Hauberg, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Jaroslav Hajek, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Judd Storrs, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Judd Storrs, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Jaroslav Hajek, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Judd Storrs, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Judd Storrs, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Thomas D. Dean, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Søren Hauberg, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Thomas D. Dean, 2010/04/19
- Re: Same .m file: different results with different versions of Octave,
Søren Hauberg <=
- Re: Same .m file: different results with different versions of Octave, Thomas D. Dean, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Søren Hauberg, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Thomas D. Dean, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Thomas D. Dean, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Thomas D. Dean, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Judd Storrs, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Judd Storrs, 2010/04/19
- Re: Same .m file: different results with different versions of Octave, Jaroslav Hajek, 2010/04/20
- Re: Same .m file: different results with different versions of Octave, Judd Storrs, 2010/04/20
- Re: Same .m file: different results with different versions of Octave, Jaroslav Hajek, 2010/04/20