MathGroup Archive 2010

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

Search the Archive

Re: Numerical simulation

  • To: mathgroup at smc.vnet.net
  • Subject: [mg113771] Re: Numerical simulation
  • From: Daniel Huber <dh at metrohm.com>
  • Date: Thu, 11 Nov 2010 06:11:11 -0500 (EST)
  • References: <iaonn6$jm9$1@smc.vnet.net>

On 02.11.2010 11:04, Equilib wrote:
> Hi,
> Does anybody have a good idea on how to set up and run simple
> numerical simulations in Mathematica?
>
> I have an equation that consists of the variables p, g that I want to
> solve for p for different values of g=[0,1] and c=[0,1]. The function
> could be for example 1/2+c+g(1-p)+root(c+p*g-1)=0. (the real equation
> is to complex to solve algebraicly using Solve[XX,p]).
>
> I guess I need to construct a matrix for different values [0,1] of g
> and c and then use this to numerically solve for p. but how do i set
> this up in a smart way? And how do I use the results to plot p as a
> function of for example g?
>
> Best,
> Petter
>
>

Hi Petter,
maybe you problem is not properly formulated. If I interprete 
root(c+p*g-1) as "p is a root of equation "c+p*g-1==0" the you do not 
have one, but two equations:
c+p*g-1==0
1/2+c+g(1-p)+p==0
With 3 variables and 2 equations you only have 1 degree of freedom. 
Therefore, you can not specify g and c independently.
For the solution you may use, as mentioned before, Reduce.
cheers, Daniel


  • Prev by Date: Re: 2-D Fourier Transform?
  • Next by Date: Re: 2-D Fourier Transform?
  • Previous by thread: Re: Numerical simulation
  • Next by thread: Graphics: How to get values corresponding to Automatic?