Group Abstract Group Abstract

Message Boards Message Boards

0
|
10K Views
|
8 Replies
|
0 Total Likes
View groups...
Share
Share this post:

Numbers as variables

Posted 10 years ago

Hello, I am having a lot of trouble with Mathematica since several weeks. When I ask it to plot an expression, nothing appears. But when I use the automatic function "plot", then it does it by including invisible parameters: Manipulate[ DiscretePlot[ 1/2 (-1 + k)^ L k^(-2 L) (-.1d (-1 + k)^(-1 + L) + (2 k^L (-1 + (k/(-1 + k))^L))/L) V, {k, 1, 20}], {.1d, 1,20}, {L, -2, 2}, {V, -2, 2}]

Also, the program treats numbers as variables, and then plots them, like this:

Plot[(16 .1d)/729, {.1d, -8, 8}]

Can someone help me, I have no idea what is going on. Thanks

Attachments:
POSTED BY: Sabine Flamand
8 Replies
Posted 10 years ago

Yes!!! Thank you!!

POSTED BY: Sabine Flamand
Posted 10 years ago

The numerator in your expression starts with two spaces. That is the source of the invisible parameter: enter image description here

Try to rewrite the expression:

enter image description here

POSTED BY: Hans Milton
Posted 10 years ago

Hello,

I attach a file, with a simple expression including only one variable.

I then click on the option "plot" that shows up, and as you can see, an invisible parameter appears in the command. If I remove it (second graph), the graph doesn't display.

Why is this invisible parameter showing up? How can I get rid of it?

Thanks

Attachments:
POSTED BY: Sabine Flamand
Posted 10 years ago

Please make one more post describing simply and clearly what you want the notebook to accomplish.

Just before you click "Publish" to send the post click "Add a file to this post" and locate your notebook which demonstrates as simply as possible the problem you are having and select that notebook so it will be attached to your message. Then click "Publish."

Hopefully this will avoid problems of the forum software making changes to what you are writing and will allow readers to download the exact notebook you have, run it, determine the problem and explain how to avoid this problem.

POSTED BY: Bill Simpson
Posted 10 years ago

Hello,

Thank you for your answer. But in fact, this ".1d" showed up only when I coped and pasted here. In the mathematica file, I dont see it, thats why I say it is an invisible parameter. See the PFD I attached to the first post, mathematica graphs the number, as if there was some parameter, although I can't see it.

So on my file when I click on plot I see something like:

Manipulate[ Plot[ 1/2 (-1 + k)^ L k^(-2 L) , {k, 1, 20}], {, 1,20}, {L, -2, 2}, {V, -2, 2}]

I don't know why this {, 1,20} shows up, and if I remove it the graph doesn't display.

POSTED BY: Sabine Flamand
Posted 10 years ago

Hello,

Thank you for your answer. But in fact, this ".1d" showed up only when I coped and pasted here. In the mathematica file, I dont see it, thats why I say it is an invisible parameter. See the PFD I attached to the first post, mathematica graphs the number, as if there was some parameter, although I can't see it.

So on my file when I click on plot I see something like:

Manipulate[ Plot[ 1/2 (-1 + k)^ L k^(-2 L) , {k, 1, 20}], {, 1,20}, {L, -2, 2}, {V, -2, 2}]

I don't know why this {, 1,20} shows up, and if I remove it the graph doesn't display.

POSTED BY: Sabine Flamand
POSTED BY: Otto Linsuain
Posted 10 years ago
POSTED BY: Bill Simpson
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard