Get Help

Turn on suggestions

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

Showing results for

- Community
- :
- PTC Mathcad
- :
- PTC Mathcad
- :
- 3D Scatter Plot with Natural Log Element MathCAD 1...

Options

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

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

Showing results for

Highlighted

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

01-30-2015
03:42 PM

01-30-2015
03:42 PM

In MathCAD 14, I am having trouble making a 3D scatter plot when the matrix-function contains an element that is a natural log function. The same matrix-function plots OK If I substitute and different function for the natural log function. I have included an example file; why does the p.2xyz function plot OK and p.1xyz not plot at all?

Solved! Go to Solution.

1 ACCEPTED SOLUTION

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

01-30-2015
04:57 PM

01-30-2015
04:57 PM

Unlike a 2D-plot a 3D plot will not respect and use your range t. So you used the 3D quickplot and it defaults to a range from -5 to 5. Give it a try, change your t-range and watch your second plot - nothing will happen.

The negative values in the range [-5; 5] throw a complex result, 0 makes the log function fail. Unlike a 2D plot a 3D plot fails if just one result is complex or NaN or the like.

To make your plot work you have to edit the quickplot range accordingly:

It may be more convenient to use the CreateSpace() function at the price of having to get rid of the units (which you should do in a 3D-plot anyway):

6 REPLIES 6

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

01-30-2015
03:46 PM

01-30-2015
03:46 PM

Re: 3D Scatter Plot with Natural Log Element MathCAD 14

correction: "substitute a dirfferent" not "substitute and dirfferent"

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

01-30-2015
04:57 PM

01-30-2015
04:57 PM

Unlike a 2D-plot a 3D plot will not respect and use your range t. So you used the 3D quickplot and it defaults to a range from -5 to 5. Give it a try, change your t-range and watch your second plot - nothing will happen.

The negative values in the range [-5; 5] throw a complex result, 0 makes the log function fail. Unlike a 2D plot a 3D plot fails if just one result is complex or NaN or the like.

To make your plot work you have to edit the quickplot range accordingly:

It may be more convenient to use the CreateSpace() function at the price of having to get rid of the units (which you should do in a 3D-plot anyway):

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

01-30-2015
05:01 PM

01-30-2015
05:01 PM

Re: 3D Scatter Plot with Natural Log Element MathCAD 14

Erroll Brady wrote:

correction: "substitute a dirfferent" not "substitute and dirfferent"

Even better "substitute a different", I guess.

BTW, as long as nobody has replied to a post of yours, you can still edit it. If its the initial post you find the option to do so in the outer right column, otherwise at the end of the posting.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

02-02-2015
12:28 PM

02-02-2015
12:28 PM

Re: 3D Scatter Plot with Natural Log Element MathCAD 14

Yes. I suffer from doofus-finger.

Thanks.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

02-02-2015
12:41 PM

02-02-2015
12:41 PM

Re: 3D Scatter Plot with Natural Log Element MathCAD 14

Erroll Brady wrote:

Yes. I suffer from doofus-finger.

Thanks.

I can perfectly understand that as I have a similar problem 😉

Hope the answer below helped anyway.

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

02-02-2015
12:42 PM

02-02-2015
12:42 PM

Re: 3D Scatter Plot with Natural Log Element MathCAD 14

Thank you,

That did the trick.

Erroll

Top Tags