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

Community Tip - Stay updated on what is happening on the PTC Community by subscribing to PTC Community Announcements. X

SN Curve Plot

VG_10714868
4-Participant

SN Curve Plot

Hi,

New user for Prime 9

 

I want to customize the S N Curve (X, Y) plot

so that for induced stress values corresponding life cycles to be known.

how the units to be incorporated in (x, y) labels

X corresponding y value to be shown or vice versa

X, Y limit values to be customized

 

Thanks & Regards

GS

 

ACCEPTED SOLUTION

Accepted Solutions
Werner_E
25-Diamond I
(To:VG_10714868)

I sure second what Vladiir had written - you always should attach your Prime sheet and also state, which version of Prime you are using.

 

Its not quite clear to me what you would like to ask for.

 

To add units you simply multiply the column with the desired unit and I would suggest assigning the result to single variables.

Werner_E_0-1719320242205.png

In the plot you will see a unit placeholder next to the expression for each axis. If you plot "Failures" over "Stress" you will already see "Pa" at the x-axis and can overwrite it with "MPa".

Scaling of the axis is implemented quite tricky and very uncomfortable. You can edit the tiny numbers you see at the axis. You can add the very first number, the last number and the second number (so you can control the step width) at each axis. In the following plot I set the first number on the x-axis to 0, the second to 20 and let the last one at its default (the hightest value in vector "Stress").

At the y-axis I changed the number format from "General" to "Decimal" to match the display in vector Cr2.

You can add horizontal and vertical markers and I add each of them by manually typing in the values 200 and 500000. Format them as needed.

Werner_E_1-1719320590907.png

 

You may consider creating an interpolating function so you can calculate the number of failures depending on stress values not in the table using linear interpolation.

You can also use this function to create the plot. This time I used the expression "Stress/MPa" and "fails(stress)" in the placeholders for the vertical and horizontal markers. Prime shows the numbers nonetheless but you can see it if you click these placeholders.

Werner_E_4-1719320926312.png

You may also use cubic spline interpolation instead of linear interpolation, but I don't see any benefit doing so

Werner_E_5-1719321261043.png

 

Prime 9 sheet attached

 

View solution in original post

5 REPLIES 5

It's better to attach the worksheet.

VG_10714868
4-Participant
(To:VladimirN)

Regret for the same.

Attached my work sheet

mathcad prime9

 

(Would like to know which version is preferable)

Werner_E
25-Diamond I
(To:VG_10714868)

I sure second what Vladiir had written - you always should attach your Prime sheet and also state, which version of Prime you are using.

 

Its not quite clear to me what you would like to ask for.

 

To add units you simply multiply the column with the desired unit and I would suggest assigning the result to single variables.

Werner_E_0-1719320242205.png

In the plot you will see a unit placeholder next to the expression for each axis. If you plot "Failures" over "Stress" you will already see "Pa" at the x-axis and can overwrite it with "MPa".

Scaling of the axis is implemented quite tricky and very uncomfortable. You can edit the tiny numbers you see at the axis. You can add the very first number, the last number and the second number (so you can control the step width) at each axis. In the following plot I set the first number on the x-axis to 0, the second to 20 and let the last one at its default (the hightest value in vector "Stress").

At the y-axis I changed the number format from "General" to "Decimal" to match the display in vector Cr2.

You can add horizontal and vertical markers and I add each of them by manually typing in the values 200 and 500000. Format them as needed.

Werner_E_1-1719320590907.png

 

You may consider creating an interpolating function so you can calculate the number of failures depending on stress values not in the table using linear interpolation.

You can also use this function to create the plot. This time I used the expression "Stress/MPa" and "fails(stress)" in the placeholders for the vertical and horizontal markers. Prime shows the numbers nonetheless but you can see it if you click these placeholders.

Werner_E_4-1719320926312.png

You may also use cubic spline interpolation instead of linear interpolation, but I don't see any benefit doing so

Werner_E_5-1719321261043.png

 

Prime 9 sheet attached

 

VG_10714868
4-Participant
(To:Werner_E)

HI, Werner

I have gone through your reply. Thank you for the reply

As per your view it is not necessary to plot, we can directly use interpolation tools to know the cycles.

For graphical view I preferred the plot option.

In the plot I could not insert   unit, I could not alter x & y limit values. etc

I am not able to mark the corresponding X vs. Y value in the graph as you done in red color.

 

GS

Werner_E
25-Diamond I
(To:VG_10714868)

So, is there still something you struggle to achieve?

I just noticed tat in your plot you plotted stress over failures while I did it the other way around.

You may highlight a specific position by adding markers as shown in my first reply, you may alternatively (or additionally)  add a point hat way:

Werner_E_0-1719399921520.png

Add a "symbol" for the second plot and chose linestyle "none".

 

If you want to draw a horizontal line without using a marker, you have to use dummy variable at the x-axis.
You would see (or better: not see) a line drawn just from 0 to 10. To see the line from 0 to 10^6 you have 2 options. Either define the dummy variable as a range running from 0 to 10^6 or you manually edit the last tick value at the x-axis to read 10^6 (simply retype 10^6 at the value which already reads 10^6 🙂 )

Werner_E_1-1719400298541.png

Another option is to use a vector the same size as Cr2<1> instead of the scalar 200 with all elements being 200.

One way to create that vector is to multiply C2r<1> or Cr2<0> with zero and add 200.

Werner_E_2-1719400472622.png

 

 

Announcements

Top Tags