MathGroup Archive 2008

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

Search the Archive

Re: solve question

  • To: mathgroup at smc.vnet.net
  • Subject: [mg90995] Re: solve question
  • From: Jean-Marc Gulliet <jeanmarc.gulliet at gmail.com>
  • Date: Sat, 2 Aug 2008 03:27:02 -0400 (EDT)
  • Organization: The Open University, Milton Keynes, UK
  • References: <g6uchj$pdf$1@smc.vnet.net>

Francisco Gutierrez wrote:

> Frieds: I have a question, as always I imagine it is quite simple.
>  
> I have made several functions. I give the following example:
>  
> newsubstraction[a_List, b_List]:=Module[{k=((b[[2]]+a[[2]])-(b[[1]]+a[[=
> 1]]))/2},{middle[a]-middle[b]-k, middle[a]-middle[b]+k}]
>  
> This function takes two lists of the form {a1,b1} and {a2,b2} and returns a list of identical form.  Now, suppose I have an equation with an unknown (of the form {u1,u2}). My question is: how to solve it?
> I would like something of the sort:
> IMAGINEDSOLVE[newsubstraction[firstlist, UNKNOWN]==secondlist, UNKNOWN]
> I would like this IMAGINEDSOLVE to work for newsubstraction and other functions of the same type. Thanks for any help.

Something along the lines,

     mySolve[l1_, l2_, uk_] :=
      Solve[Thread[newsub[l1, uk] == newsub[l2, uk]], uk]

should do it.

Regards,
-- Jean-Marc


  • Prev by Date: Re: Re: Re: When is a List not a
  • Next by Date: Re: Exported PDFs are too big in file size.
  • Previous by thread: solve question
  • Next by thread: Re: Performance of Array Addition