From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: * X-Spam-Status: No, score=1.4 required=5.0 tests=BAYES_50,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,7bf4308ff88deca8 X-Google-Attributes: gid103376,public From: Mars Gralia Subject: Re: How I declare a 'mod' type within a record? Date: 1997/08/05 Message-ID: <33E78541.15FB@jhuapl.edu>#1/1 X-Deja-AN: 262530520 References: <33DF3FD2.20D2@mail.connect.usq.edu.au> Organization: Johns Hopkins University Applied Physics Lab, Laurel, MD, USA Newsgroups: comp.lang.ada Date: 1997-08-05T00:00:00+00:00 List-Id: Matthew Kennedy wrote, on (apparently) 27-July: > > Hello all, > > I'm trying to implement a time-series type to aid in defference equation > simulations. I would like to use a 'mod' type which would be an elegant > way of cycling around the buffer (which is just an array). (snip) > Matthew Kennedy > Student of Electronics Engineering > University of Southern Queensland, Australia > "When will you realise your already there?" > - Marilyn Manson a) I don't fully understand your specific application, but I have a good idea. (I've done a bit of signal processing in my day.) b) There is a data structure, often called a "ring" that will probably do what you need. The primary references are: 1) The theory: a text book, Grady Booch, "Software Components with Ada", Benjamin/Cummings Publishing, 1987, ISBN 0-8053-0609-9. (He also has a tape of code, but it you need to spend something like $500 (US) for it.) 2) A package which seems to do the job is named on the page > http://osiris.ipfw.indiana.edu/cs/cs260/labs/lab6.htm 3) I hope to have an example for you tomorrow. M Gralia, D.Sc. mars.gralia@jhuapl.edu Johns Hopkins University Applied Physics Laboratory