cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - You can change your system assigned username to something more personal in your community settings. X

Plot problem

FC_10037391
9-Granite

Plot problem

How can I use bode function in prime? 

ACCEPTED SOLUTION

Accepted Solutions
StuartBruff
23-Emerald III
(To:Werner_E)

It took me a couple of seconds to work out why Tetsuro's phase plot looks different to yours - it's the linear vs logarithmic x-axis. 

 

To add my minor tuppence worth, I've modified your phase plot, removed the symbols, and added gridlines (I believe they're normally shown in Bode Plots?).  I didn't necessarily like the auto-scale's choice of min/max values and steps, either.

 

.2024 09 14 B.png

 

Stuart

 

 

 

.

View solution in original post

6 REPLIES 6
Werner_E
25-Diamond I
(To:FC_10037391)

Your function would return all  non-real results which can't be plotted, like

Werner_E_0-1726067926579.png

 

You type a square bracket and this creates a matrix - guess this was not your intention.

Maybe you meant it to be the absolute value? Then of course you also would get real results.

But because f is a vector, you will also use vectorization as otherwise only the absolute value of the vector would be the only single scalar value.

Werner_E_1-1726068115581.png

 

Vectorization is also what you need in your second plot

Werner_E_2-1726068151009.png

 

 

P10 file attached

StuartBruff
23-Emerald III
(To:Werner_E)

It took me a couple of seconds to work out why Tetsuro's phase plot looks different to yours - it's the linear vs logarithmic x-axis. 

 

To add my minor tuppence worth, I've modified your phase plot, removed the symbols, and added gridlines (I believe they're normally shown in Bode Plots?).  I didn't necessarily like the auto-scale's choice of min/max values and steps, either.

 

.2024 09 14 B.png

 

Stuart

 

 

 

.

Werner_E
25-Diamond I
(To:StuartBruff)


@StuartBruff wrote:

It took me a couple of seconds to work out why Tetsuro's phase plot looks different to yours - it's the linear vs logarithmic x-axis. 

Correct. All I edited was the vectorization and I left the original of @FC_10037391 otherwise unchanged. Actually I avoid opening the chart component because its so slow and awkward to use.

StuartBruff
23-Emerald III
(To:Werner_E)


@Werner_E wrote:

@StuartBruff wrote:

It took me a couple of seconds to work out why Tetsuro's phase plot looks different to yours - it's the linear vs logarithmic x-axis. 

Correct. All I edited was the vectorization and I left the original of @FC_10037391 otherwise unchanged.


OK.  That explains that.

 


@Werner_E wrote:

Actually I avoid opening the chart component because its so slow and awkward to use.

I don't recall using the chart component before, but never has a truer word been spoken, Werner.   Even the Aesop's hare got past the finishing post first and he'd had a very long sleep in the gentle warmth of the CPU.

 

I don't know why PTC didn't/don't give these "area" defined tools the ability to pass/return settings as part of a function.  Or even, as I suggested a very long time ago, treat them as user-accessible objects.   That way, the user could directly set properties and even define appropriate methods (functions).

 

Not that I mind user-interfaces for property setting (far from it), it's just that I prefer to have them as an overlay on top of a user-accessible model.

 

Stuart

 

Indeed, as I noted 12 years ago, "Well, I was a bit of a late-comer to the Collaboratory, but I have heard rumours that Apollonius made a similar request when he was beta-testing Mαθκαδ α ... and I'm pretty sure he wanted built-in geometric drawing tools as well."

 

https://community.ptc.com/t5/Mathcad/Mathcad-worksheet-as-a-function/m-p/338734#M132404

Werner_E
25-Diamond I
(To:StuartBruff)

Well, I sure second yours and Apollonius' feature request.

But I would have preferred PTC to improve the native plots (2D and sure also 3D) rather than amateurishly integrating a third party software that can't even handle units. An absolute no-go for software like Mathcad - but unfortunately it's no longer Mathcad, it's just Prime...

ttokoro
20-Turquoise
(To:FC_10037391)

image.pngimage.png

Announcements

Top Tags