Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2004
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2004

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: How to explain functions' linearity to Mathematica 5 ?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg51079] Re: How to explain functions' linearity to Mathematica 5 ?
  • From: "Steve Luttrell" <steve_usenet at _removemefirst_luttrell.org.uk>
  • Date: Mon, 4 Oct 2004 06:17:38 -0400 (EDT)
  • References: <cjojiq$aro$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

You need the two definitions

N0[i_, j_, (r_) + (s_)] := N0[i, j, r] + N0[i, j, s];

N0[i_, j_, (a_)?NumberQ*(s_)] := a*N0[i, j, s];

then evaluating

N0[1, 2, I*N0[4, 1, r] + 97*N0[4, 3, 5*N0[2, 1, r]]]

gives

I*N0[1, 2, N0[4, 1, r]] + 485*N0[1, 2, N0[4, 3, N0[2, 1, r]]]

Steve Luttrell

"Stepan Yakovenko" <stiv at novi.ru> wrote in message 
news:cjojiq$aro$1 at smc.vnet.net...
> Hello !
>
> It would be great if someone will help me to find out a solution for a
> small problem.
> I have got an abstract function N0[i,j,r], where i and j are integers
> and r is some formulae.
> N0 has a feature: N0[i,j,r+s]=N0[i,j,r]+N0[i,j,s] and N0[i,j, a s]=a
> N0[i,j,s]. I have got
> a long expression like this: N0[1,2,
> I*N0[4,1,r]+97*N0[4,3,5*N0[2,1,r]]]. I want it to get expanded
> like this I*N0[1,2,N0[4,1,r]+5*97*N0[1,2,N0[4,3,N0[2,1,r]]]] with
> Mathematica 5. How can I do it ?
>
> Thanx in advance.
>
> 



  • Prev by Date: Re: Show In/Out Names
  • Next by Date: Re: Problem with Maximize and conditions.
  • Previous by thread: Re: How to explain functions' linearity to Mathematica 5 ?
  • Next by thread: Re: How to explain functions' linearity to Mathematica 5 ?