three dimensional graph for given data
16 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
I use the following code to draw 3 D graph but the plot is not correct
x=0:0.1:1
t=0:0.001:0.01
c=[ 1.0, 1.00200400935774, 1.00401607505823, 1.00603625398793, 1.00806460363401, 1.01010118209271, 1.01214604807773, 1.01419926092855, 1.01626088061884, 1.01833096776475, 1.02040958363333
0.90483741803596, 0.906564233432415, 0.908297572067991, 0.910037477448149, 0.911783993513358, 0.913537164644842, 0.915297035670336, 0.917063651869828, 0.918837058981314, 0.920617303206547, 0.922404431216785
0.818730753077954, 0.820222443360045, 0.821719434735509, 0.823221760630547, 0.824729454788085, 0.826242551271732, 0.827761084469751, 0.829285089099023, 0.830814600209014, 0.832349653185739, 0.833890283755733
0.740818220680134, 0.742110003794443, 0.743406110511287, 0.744706566629163, 0.746011398178128, 0.747320631422515, 0.748634292863652, 0.749952409242585, 0.751275007542791, 0.752602114992902, 0.753933759069419
0.67032004600776, 0.671441457955808, 0.672566409081118, 0.673694919378938, 0.67482700901374, 0.675962698321017, 0.67710200780908, 0.678244958160856, 0.679391570235683, 0.680541865071112, 0.681695863884699
0.606530659455261, 0.607506517907187, 0.608485283869302, 0.609466972886304, 0.610451600624628, 0.611439182873475, 0.612429735545835, 0.61342327467951, 0.614419816438142, 0.615419377112236, 0.616421973120184
0.548811634514286, 0.549662833249987, 0.550516428846856, 0.551372433378605, 0.552230859000839, 0.553091717951276, 0.553955022549961, 0.55482078519949, 0.555689018385218, 0.556559734675482, 0.557432946721819
0.496585296475096, 0.497329459482098, 0.498075604255425, 0.498823740046355, 0.499573876147634, 0.500326021892609, 0.501080186654356, 0.501836379844811, 0.502594610913901, 0.503354889348677, 0.504117224672438
0.449328936544621, 0.449980953769076, 0.450634611847856, 0.451289917500412, 0.451946877434986, 0.452605498345995, 0.453265786911424, 0.453927749790212, 0.454591393619639, 0.455256725012715, 0.455923750555571
0.406569570964509, 0.407142030852987, 0.407715845130743, 0.408291017793109, 0.408867552740486, 0.409445453772717, 0.41002472458345, 0.410605368754516, 0.411187389750288, 0.411770790912059, 0.412355575452406
0.367879188712522, 0.36838271526503, 0.368887342872768, 0.369393071858138, 0.369899902302313, 0.370407834034272, 0.370916866619838, 0.371426999350717, 0.371938231233535, 0.372450560978875, 0.372963986990317]
surf(t,x,c)
the data is in attachement file
1 comentario
Respuestas (1)
Chunru
el 13 de Dic. de 2021
Editada: Chunru
el 13 de Dic. de 2021
What do you expect?
x=0:0.1:1;
t=0:0.001:0.01;
c=[ 1.0, 1.00200400935774, 1.00401607505823, 1.00603625398793, 1.00806460363401, 1.01010118209271, 1.01214604807773, 1.01419926092855, 1.01626088061884, 1.01833096776475, 1.02040958363333
0.90483741803596, 0.906564233432415, 0.908297572067991, 0.910037477448149, 0.911783993513358, 0.913537164644842, 0.915297035670336, 0.917063651869828, 0.918837058981314, 0.920617303206547, 0.922404431216785
0.818730753077954, 0.820222443360045, 0.821719434735509, 0.823221760630547, 0.824729454788085, 0.826242551271732, 0.827761084469751, 0.829285089099023, 0.830814600209014, 0.832349653185739, 0.833890283755733
0.740818220680134, 0.742110003794443, 0.743406110511287, 0.744706566629163, 0.746011398178128, 0.747320631422515, 0.748634292863652, 0.749952409242585, 0.751275007542791, 0.752602114992902, 0.753933759069419
0.67032004600776, 0.671441457955808, 0.672566409081118, 0.673694919378938, 0.67482700901374, 0.675962698321017, 0.67710200780908, 0.678244958160856, 0.679391570235683, 0.680541865071112, 0.681695863884699
0.606530659455261, 0.607506517907187, 0.608485283869302, 0.609466972886304, 0.610451600624628, 0.611439182873475, 0.612429735545835, 0.61342327467951, 0.614419816438142, 0.615419377112236, 0.616421973120184
0.548811634514286, 0.549662833249987, 0.550516428846856, 0.551372433378605, 0.552230859000839, 0.553091717951276, 0.553955022549961, 0.55482078519949, 0.555689018385218, 0.556559734675482, 0.557432946721819
0.496585296475096, 0.497329459482098, 0.498075604255425, 0.498823740046355, 0.499573876147634, 0.500326021892609, 0.501080186654356, 0.501836379844811, 0.502594610913901, 0.503354889348677, 0.504117224672438
0.449328936544621, 0.449980953769076, 0.450634611847856, 0.451289917500412, 0.451946877434986, 0.452605498345995, 0.453265786911424, 0.453927749790212, 0.454591393619639, 0.455256725012715, 0.455923750555571
0.406569570964509, 0.407142030852987, 0.407715845130743, 0.408291017793109, 0.408867552740486, 0.409445453772717, 0.41002472458345, 0.410605368754516, 0.411187389750288, 0.411770790912059, 0.412355575452406
0.367879188712522, 0.36838271526503, 0.368887342872768, 0.369393071858138, 0.369899902302313, 0.370407834034272, 0.370916866619838, 0.371426999350717, 0.371938231233535, 0.372450560978875, 0.372963986990317];
whos
surf(t,x,c);
xlabel("t"); ylabel("x"); zlabel("c")
0 comentarios
Ver también
Categorías
Más información sobre 2-D and 3-D Plots en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
