How can I convert surface plot into STL format file?

I want to know whats the further process to convert the surface plot into STL file ?
I have downloaded the file from https://www.mathworks.com/matlabcentral/fileexchange/4512-surf2stl then whats the next process to follow it?

2 件のコメント

KSSV
KSSV 2022 年 5 月 16 日
Read the help of function, it is clearly shown what to do.
siddhartha paudel
siddhartha paudel 2022 年 5 月 16 日
I am a begineeer so i didnt understand. can you helo me to get through it?

サインインしてコメントする。

回答 (1 件)

KSSV
KSSV 2022 年 5 月 16 日

0 投票

[X,Y,Z] = peaks(100) ;
surf2stl('test.stl',X,Y,Z)

9 件のコメント

siddhartha paudel
siddhartha paudel 2022 年 5 月 16 日
I have done this but still an error. Can we connect on social media so i can clearly show you my problem?
KSSV
KSSV 2022 年 5 月 16 日
What error you are getting?
siddhartha paudel
siddhartha paudel 2022 年 5 月 16 日
unrecognized variable'surf2stl'
KSSV
KSSV 2022 年 5 月 16 日
You are not running/ calling the function properly.
  1. Go to the link: https://in.mathworks.com/matlabcentral/fileexchange/4512-surf2stl. Down load the function into your pc.
  2. Go to the folder, where you have downloaded/ copied the function surf2stl.
  3. DEfine your mesh, Check the example code I have given.
  4. Note that when you run/ call the function, the function should be in your present working directory.
siddhartha paudel
siddhartha paudel 2022 年 5 月 16 日
I have done this but still a problem. i have sent a message.please can we have a chat on message.
siddhartha paudel
siddhartha paudel 2022 年 5 月 16 日
please explain step number 4.
KSSV
KSSV 2022 年 5 月 16 日
You have to change the path to the folder, where you have the function.
Charles
Charles 2023 年 5 月 17 日
I am able to use the surf2stl file and functionalities to convert "surf" (mesh) into .stl
However, for "fsurf" (function surf, mesh), the functionalities does not seem to work.
Does anyone have experience on how to resolve this issue?
(For the typical X,Y,Z surf, the surf2stl works fine. However, for X,Y,Z defined as functions, hence fsurf, the surf2stl no longer works: "Wrote 0 facets"). Thank you for your help.

サインインしてコメントする。

質問済み:

2022 年 5 月 16 日

コメント済み:

DGM
2025 年 6 月 29 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by