       • To: mathgroup at smc.vnet.net
• Subject: [mg56197] Re : [mg56184] Integrate is driving me crazy, please help!
• From: "Jaccard Florian" <Florian.Jaccard at he-arc.ch>
• Date: Tue, 19 Apr 2005 04:54:53 -0400 (EDT)
• Sender: owner-wri-mathgroup at wolfram.com

```Hello Jim,

It is in fact a beginner-problem... The arguments of functions must be [] , not () ...

So you should write :

expr = Integrate[hillb*((f0 + hilla)/(2*Pi*f*a*Cos[ArcSin[x/a]] + hillb)) - hilla, {x, -a, a}]

Which gives an answer like you expect...

expr2 = Simplify[expr, {a, hilla, f, hillb, f0} > 0];

expr2 /. {hilla -> 3, hillb -> 50, f0 -> 8, a -> 1, f -> 1.}

gives :

14.037200672826035 + 0.*I

Don't be afraid of the complex numbers, the imaginary part is 0...

Regards

F.Jaccard

-----Message d'origine-----
De : Jim Martin [mailto:jim.martin at utah.edu]
Envoyé : lundi, 18. avril 2005 09:09
À : mathgroup at smc.vnet.net
Objet : [mg56184] Integrate is driving me crazy, please help!

Hello Mathematica Experts:

I am a biomechanist and work mostly in the area of muscle contraction. I
do a lot of numerical computations using excel, but right now I need an
analytical solution that represents force as a function of position
integrated over a shortening amplitude. I downloaded a trial version of
Mathematica and have tried to obtain a solution for this:

Integrate[(hillb*((f0 + hilla)/(2*pi*f*a*Cos(ArcSin(x/a)) + hillb))) -
hilla, {x, -a, a}]

Mathematica returns this:
(-4 a ArcSin Cos f hilla pi + (f0 + hilla) hillb (-Log[hillb - 2 a
ArcSin Cos f pi] + Log[hillb + 2 a ArcSin Cos f pi]))/(4 a ArcSin
Cos f pi)

I know the line wrap makes this hard to read so please feel free to
email me and I can send you the output as a picture.

In a sample data set, hilla=3, hillb=50, f0=8, a=1, f=1

I can numerically integrate this function and obtain a value for that
sample data set of 14.04. When I put those sample values into the
solution that Mathematica produces, I get 10.01.

Can any of you please give a hand here? I must be making some simple
Mathematica-beginner error but I just can't see it.

In Mathematica, Log is Log to base e, right (LN in excel)? Did I use
variables that have intrinsic functions in Mathematica? Maybe I am
misunderstanding the output with regard to implicit parentheses etc.
Any help appreciated!

Thanks,

Jim

```

• Prev by Date: Re: How can I get a nonscalar logical variable into a compiled function?
• Next by Date: Re: Integrate is driving me crazy, please help!
• Previous by thread: Re: Re: holding boxes verbatim
• Next by thread: How to run multiple sessions on Mac OS X?