reserving memory for an array

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jerry Coffin

    #46
    Re: reserving memory for an array

    In article <1158983794.315 414.191580@h48g 2000cwc.googleg roups.com>,
    vfunc@talktalk. net says...
    Where on this page does it mention amortized ?
    >
    http://en.wikipedia.org/wiki/Big-O_notation
    In the references. This page refers to _Introduction to Algorithms
    (Second Edition)_ by Cormen, Leiserson, Rivest and Stein. Chapter 17 of
    that book is titled "Amortized Analysis", and is devoted (surprise,
    surprise) to amortized analysis of algorithms. Of course, amortized
    analysis is used elsewhere in the book as well (the index entry of
    "amortized analysis" has 19 sub-entries in addition to the reference to
    chapter 17).

    The authoritative reference for C++ is the ISO 14882, 2003 (second
    edition). It uses the term in about a half dozen places, some of which
    (e.g. section 23.1.1/12) apply to a rather large number of containers.
    "Amortized" is a misleading and non standard term.
    Nonsense!

    It is a well-known term of art among computer scientists, and used in
    leading references on the subject. With respect specifically to C++ it
    is not only well-known, but officially and formally standardized as a
    requirement in the C++ standard.

    --
    Later,
    Jerry.

    The universe is a figment of its own imagination.

    Comment

    • Jerry Coffin

      #47
      Re: reserving memory for an array

      In article <1158985739.035 262.80970@m73g2 000cwd.googlegr oups.com>,
      vfunc@talktalk. net says...

      [ ... ]
      You agree with false statement, so you are wrong.
      You're putting words in my mouth. Your previous statements were wrong,
      and now you've descended to outright lies to try to cover them up.
      I do have a good understanding of big oh.
      Not to put too fine a point on it, the posts I've seen you make thus far
      do not make this claim particularly believable.
      I've just shown that I have a better understanding than you, by proving
      you wrong.
      Still more nonsense!
      I refer to cheaters, being people that confuse others by conveniently
      dropping terms like "amortized" to make things look better than they
      really are, for their own personal gain. Imagine how preposterous it
      would be if some athletes went around saying "my time for the 100m is
      0.1", then when someone said that is impossible they conveniently
      turned around and changed their tune to "my amortized time for the 100m
      is 0.1, you are wrong."
      First of all, people have been very careful to state that insertion into
      a vector has amortized constant complexity from the beginning. You are
      simply badly confused: you originally asked about _access_ to the array,
      which has constant complexity -- NOT amortized constant, but simply
      constant.

      You then went on to confuse the two, and don't seem to have sorted
      things out yet.
      Please post the exact errors you're receiving, and identify the compiler
      you're using. If you can't get that to compile, I'm reasonably certain
      there's a fairly serious problem either with your compiler, or with how
      you're using it.

      --
      >
      I will look elsewhere in future.
      Just for grins, I'll even suggest on place elsewhere that you can look.
      Comeau C++ is widely regarded as having the best conformance of any
      compiler available. Nicely enough, Greg Comeau is kind enough to make a
      version of it available via his web site. Running it over the code I
      posted gives the following results:

      -----------snip--------------------
      Your Comeau C/C++ test results are as follows:

      Comeau C/C++ 4.3.8 (Aug 19 2006 13:36:48) for ONLINE_EVALUATI ON_Alpha1
      Copyright 1988-2006 Comeau Computing. All rights reserved.
      MODE:strict errors C++


      In strict mode, with -tused, Compile succeeded (but remember, the Comeau
      online compiler does not link).
      -----------end snip------------------

      The URL for the test compiler is:



      So anybody who cares to verify the code I posted can do so. Of course,
      the compiler has far more uses than that. Since you claim to have had
      difficulty getting your compiler to work with my code, after you try it
      out, you should send Greg $50 and get a copy of his compiler, which
      obviously works a lot better than whatever you've been using.

      --
      Later,
      Jerry.

      The universe is a figment of its own imagination.

      Comment

      • Default User

        #48
        Re: reserving memory for an array

        Jerry Coffin wrote:
        In article <1158985739.035 262.80970@m73g2 000cwd.googlegr oups.com>,
        vfunc@talktalk. net says...
        >
        [ ... ]
        >
        You agree with false statement, so you are wrong.
        >
        You're putting words in my mouth. Your previous statements were
        wrong, and now you've descended to outright lies to try to cover them
        up.
        He's a troll, plonk him or ignore him.




        Brian

        Comment

        • Mark P

          #49
          Re: reserving memory for an array

          vfunc@talktalk. net wrote:
          Where on this page does it mention amortized ?
          >

          >
          "Amortized" is a misleading and non standard term.
          >
          It's also not on this page:



          Nor any of billions of other pages, but what has that to do with anything?

          Perhaps check out this page:



          That you believe it to be a non-standard term and don't understand the
          concept only betrays your ignorance on this subject.

          Comment

          • Dave Steffen

            #50
            Re: reserving memory for an array

            "Default User" <defaultuserbr@ yahoo.comwrites :
            Jerry Coffin wrote:
            >
            In article <1158985739.035 262.80970@m73g2 000cwd.googlegr oups.com>,
            vfunc@talktalk. net says...

            [ ... ]
            You agree with false statement, so you are wrong.
            You're putting words in my mouth. Your previous statements were
            wrong, and now you've descended to outright lies to try to cover them
            up.
            >
            He's a troll, plonk him or ignore him.
            Furthermore, he tends to respond to this kind of post (I posted a
            similar comment over on one of the GCC help forums) with an
            extraordinarily profane and insulting email. I'll probably get
            another from this post. Gents, he really isn't worth the time.

            ----------------------------------------------------------------------
            Dave Steffen, Ph.D.
            Software Engineer IV Disobey this command!
            Numerica Corporation - Douglas Hofstadter
            dgsteffen at numerica dot us

            Comment

            Working...