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
- :
- help with plotting piecewise function

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

05-17-2019
09:24 AM

05-17-2019
09:24 AM

Hi, can someone help me, I cannot figure out what I am doing wrong in this. The error I get is that the value must be a scalar.

Solved! Go to Solution.

Labels:

1 ACCEPTED SOLUTION

Accepted Solutions

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

05-17-2019
01:20 PM

6 REPLIES 6

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

05-17-2019
10:01 AM

05-17-2019
10:01 AM

Re: help with plotting piecewise function

Hi,

Because you have not included the Prime sheet I have expressed the function in terms of all the input values.

Not sure if you are using Prime 15 or 14?

In your sheet T is a range variable so the comparison with a single variable T0 cannot be done.

Cheers

Terry

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

05-17-2019
10:09 AM

05-17-2019
10:09 AM

Re: help with plotting piecewise function No 2

Hi,

Forgot you also need to include what happens when T is equal to the comparison boundary limits.

Here is one way.

Cheers

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

05-17-2019
10:11 AM

05-17-2019
10:11 AM

Re: help with plotting piecewise function

Hi Terry, I'm using Prime 5 and I'm ultimately trying to plot the piecewise function that I was attempting to define with the code posted. I made those changes, but it still is not working. T0 is a single value, where T is an array, I tried a while loop to populate Sa but I could not get that to work either. I'm just trying to populate Sa with values and then plot Sa and T.

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

05-17-2019
11:22 AM

05-17-2019
11:22 AM

Re: help with plotting piecewise function

Hi

Here is the plot with some values assigned to the variables. T is a vector of values.

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

05-17-2019
01:20 PM

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

05-17-2019
01:45 PM

05-17-2019
01:45 PM

Re: help with plotting piecewise function

Not sure if you are using Prime 15 or 14?

Wow! You sure are far ahead of your time :-)

Top Tags