Group Abstract Group Abstract

Message Boards Message Boards

0
|
18K Views
|
6 Replies
|
0 Total Likes
View groups...
Share
Share this post:
GROUPS:

Mathematica won't give me a numerical result

Posted 12 years ago

Hello everyone, I have a problem with Mathematica 9. For my thesis I have to work with a rather big, but not too complicated equation, but Mathematica just won't give me numerical results for it, even if I assign values to every single variable. Even when I use the N-function, it still won't give me a simple numerical result, but a product containing a square root and some sums. Has anyone else encountered such a problem and does anybody know a solution? Thank you in advance!

POSTED BY: Daniel Tausend
6 Replies
Posted 12 years ago

On a side note, we could let MMa try and simplify the expression, and replace decimals with fractions, i.e. 43.566 with 43566/1000. the result is more compact though not necessarily what you want.

we get

f[a_, b_] := 
 N[1/(4 Sqrt[14])
    Sqrt[((107500 + 21783 a + 18668 b) (224 b + 3 a (70 + 17 b)))/(
   a b)]]

Paul.

POSTED BY: Paul Cleary
Posted 12 years ago

Ah great. Thank you guys, this actually helps a lot. I'll just remove it then.

POSTED BY: Daniel Tausend
Posted 12 years ago

Hi Daniel,

Is there any reason you include the TextCell[""]? removing it then prints a numeric answer. I am suspecting that using TextCell is preserving the format.

Paul.

POSTED BY: Paul Cleary
Posted 12 years ago

TextCell[" "] is the problem.

f[a_, b_] := 
 10 Sqrt[5] \[Sqrt]((215. + 43.566 a + 
       37.336 b) (0.25 (5/(2 a) + 
          1500 (1/800 - (-1 + a)/(1000 a)) ) + 
       0.25 (5/(2 b) + 1250. (1/700 - (-1 + b)/(1000 b)) )))

So f[1,1] yields: 565.986

You rule assignment would work for the expression, e.g.

f[u, v] /. {u -> 1, v -> 1}
POSTED BY: Mark Dooris
Posted 12 years ago
POSTED BY: Daniel Tausend
Posted 12 years ago
POSTED BY: Paul Cleary
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard