Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #6799
| From | Ray Koopman <koopman@sfu.ca> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: How to solve or approximate a first order differential equation ? |
| Date | 2011-11-29 12:04 +0000 |
| Organization | Steven M. Christensen and Associates, Inc and MathTensor, Inc. |
| Message-ID | <jb2hou$5ah$1@smc.vnet.net> (permalink) |
| References | <jasv6s$762$1@smc.vnet.net> <javp9t$jap$1@smc.vnet.net> |
On Nov 28, 2:54 am, Dino <dinodebla...@gmail.com> wrote:
> Hello and thanks for your reply,
>
> I have a list like this(these are the first terms:
> data = {{1.1795*10^-12, 0.}, {1.1795*10^-12, 0.000011918},
> {1., 0.0000276853}, {1., 0.000027194}, {1., 0.0000242474},
> {1., 0.0000267025}, {1., 0.0000281765}, {1., 0.0000276853},
> {1., 0.000031607}, {1., 0.0000276853}, {1., 0.000027194},
> {2., 0.0000262109}, {2., 0.0000232628}, {2., 0.0000379602},
> {2., 0.0000355202}, {2., 0.0000311167}, {2., 0.000035031},
> {2., 0.0000306263}, {2., 0.0000374716}, {2., 0.0000360052},
> {3., 0.0000306263}, {3., 0.0000203098}, {3., 0.0000355202},
> {3., 0.0000384486}, {3., 0.0000345417}, {3., 0.0000345417},
> {3., 0.0000237551}, {3., 0.0000252315}, {3., 0.0000257192},
> {4., 0.0000237551}, {4., 0.0000267025}}
>
> and it gives me some errors. Is that possible to keep only a selected
> amount of data, because it would be easier to work with a less amount
> of data.
> Furthermore the first terms {xi, ...} are repeated because there are
> more measures for each second. How to keep only one value for each
> {xi, ...} ?
Use the means:
{#, Mean@Cases[data,{#,_}][[All,2]]}& /@ Union@data[[All,1]]
{{1.1795*^-12, 5.959*^-6},
{1., 0.0000275753},
{2., 0.0000325783},
{3., 0.0000298549},
{4., 0.0000252288}}
> In conclusion I would like to keep only for example 50 terms from the
> list of data and make the model work as you showed.
>
> Thanks,
Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Find similar | Unroll thread
Re: How to solve or approximate a first order differential equation ? Bob Hanlon <hanlonr357@gmail.com> - 2011-11-27 09:17 +0000
Re: How to solve or approximate a first order differential equation ? Dino <dinodeblasio@gmail.com> - 2011-11-28 10:57 +0000
Re: How to solve or approximate a first order differential equation ? Dino <dinodeblasio@gmail.com> - 2011-11-28 10:54 +0000
Re: How to solve or approximate a first order differential equation ? Ray Koopman <koopman@sfu.ca> - 2011-11-29 12:04 +0000
csiph-web