Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

Mar 11, 2020
05:19 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Mar 11, 2020
05:19 AM

assuming variable as integer

i am working with fourier at the moment and when i assume n as integer is gives an error message, as seen in the photo linked

am i using this wrong or is it not able to apply to this. i know the answer is 2/(pi^2*n^2) but i would like to have mathcad solve it for me for other equations

Solved! Go to Solution.

Labels:

1 ACCEPTED SOLUTION

Accepted Solutions

Mar 11, 2020
08:35 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Mar 11, 2020
08:35 AM

The "assume" modifier in Mathcads symbolic is quite weak and ever so often does not do what we expect.

But in your case it should work OK and actually it does for me. I tried with Prime 6 where PTC introduced a new symbolic engine and found that both, the old and the new engine, can successfully simplify your expression.

As you can see in the picture, the old engine needs to be told to simplify the result.

Its hard to debug just a picture so I can say what went wrong when you tried it. I would advice that you always attach your worksheet with your question and also state, which version of Prime you are using.

Did you try using a fresh worksheet without any definitions and calculations done above? Maybe something you assigned earlier (n?) is responsible for the error.

Here is the screenshot from Prime 6 using the new and also the old symbolic engine:

BTW, I would suggest to turn c.n into a function by typing c(n):=.... so you can use it in further calculations with variable values of n.

EDIT: I overlooked at first glance hat you wrote a boolean equal sign and not an assignment. But I just gave it a try and it still worked OK, so thats not the cause for the error.

5 REPLIES 5

Mar 11, 2020
08:29 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Mar 11, 2020
08:29 AM

The question is, I guess, what would you like Prime to do, other than assuming that n is a integer?

You are writing that cn __is equal to__ this integral. Note! You are NOT assigning the integral to cn.

Essentially the task here is for Prime to decide whether your statement, that cn equals that integer, is either true or false...

Luc

Mar 11, 2020
08:35 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Mar 11, 2020
08:35 AM

The "assume" modifier in Mathcads symbolic is quite weak and ever so often does not do what we expect.

But in your case it should work OK and actually it does for me. I tried with Prime 6 where PTC introduced a new symbolic engine and found that both, the old and the new engine, can successfully simplify your expression.

As you can see in the picture, the old engine needs to be told to simplify the result.

Its hard to debug just a picture so I can say what went wrong when you tried it. I would advice that you always attach your worksheet with your question and also state, which version of Prime you are using.

Did you try using a fresh worksheet without any definitions and calculations done above? Maybe something you assigned earlier (n?) is responsible for the error.

Here is the screenshot from Prime 6 using the new and also the old symbolic engine:

BTW, I would suggest to turn c.n into a function by typing c(n):=.... so you can use it in further calculations with variable values of n.

EDIT: I overlooked at first glance hat you wrote a boolean equal sign and not an assignment. But I just gave it a try and it still worked OK, so thats not the cause for the error.

Mar 11, 2020
08:53 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Mar 11, 2020
08:53 AM

Here is an example of what I was talking about (turning c into a function of n):

Mar 11, 2020
08:18 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Mar 11, 2020
08:18 PM

Mar 11, 2020
08:35 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator

Mar 11, 2020
08:35 AM

Other than that, Prime should be happy to accept an assignment like this:

et cetera.

Success!

Luc