trisurf etwas runder darstellen
DINA4
Gast
Beiträge: ---
Anmeldedatum: ---
Wohnort: ---
Version: ---
Verfasst am : 10.01.2011, 22:40
Titel : trisurf etwas runder darstellen
Hallo,
wie kann ich das ganze etwas runder darstellen. Trisurf macht das doch sehr eckig aufgrund der "wenigen" Punkte. Hat da einer einen Tip für mich. Im Anhang ist ein Bild wie es zurzeit aussieht.
MyCrustOpen Funktion hab ich von http://www.mathworks.com/matlabcent.....ttered-points-cloud-part2
Code:
pos=[ -0.992350722581999 ,0 ,0.64916893646091 ;1 ,-1.72 ,0.3 ;1 ,1.72 ,0.3 ;-0.9 ,1.54 ,0.9 ;-0.9 ,-1.54 ,0.9 ;1.78 ,0 ,0.9 ;0.66 ,1.14 ,1.5 ;-1.32 ,0 ,1.5 ;0.66 ,-1.14 ,1.5 ;0 ,0 ,2 ;-1.033575750670795 ,-0.219693307788096 ,0.626431053815558 ;-1.027876193039742 ,-0.457639966087027 ,0.602219495202126 ;-0.969261620921045 ,-0.70420978836255 ,0.576438749490894 ;-0.85362474212109 ,-0.948046321567525 ,0.548987115333871 ;-0.679201804331601 ,-1.176412033694787 ,0.519756299967555 ;-0.446975704930987 ,-1.375649768583402 ,0.488630992013489 ;-0.160993687112909 ,-1.531752614021296 ,0.455488406591399 ;0.171427927249139 ,-1.631027777480265 ,0.420197800950434 ;0.5396374728564 ,-1.660833366253001 ,0.38261995870775 ;0.929742036781121 ,-1.610360445637474 ,0.342606640659814 ;1.335755708940352 ,-1.474502182444386 ,0.3 ;1.613132483732978 ,-1.164561544069474 ,0.3 ;1.820007628318002 ,-0.803723978032437 ,0.3 ;1.947339706179977 ,-0.407759817459842 ,0.3 ;1.989563694509235 ,0.006025403784439 ,0.3 ;1.944834202402612 ,0.419547285970244 ,0.3 ;1.815106123301085 ,0.81473293854791 ,0.3 ;1.606049196765778 ,1.174310852188638 ,0.3 ;1.326800213652718 ,1.482565746620064 ,0.3 ;0.989563694509235 ,1.72602540378444 ,0.3 ;0.582769345136785 ,1.775267818310173 ,0.342606640659814 ;0.188705236152196 ,1.74457032165628 ,0.38261995870775 ;-0.167292514816618 ,1.639427562268902 ,0.420197800950434 ;-0.473786144265779 ,1.473331277201664 ,0.455488406591399 ;-0.722903149715221 ,1.260908426418238 ,0.488630992013489 ;-0.91026777686917 ,1.01713265671169 ,0.519756299967555 ;-1.034784115927218 ,0.756613321343339 ,0.548987115333871 ;-1.098298027703062 ,0.492984717546159 ,0.576438749490894 ;-1.105167329685545 ,0.238411044571174 ,0.602219495202126 ;-1.061770303892343 ,0.003215576774412 ,0.626431053815558 ;-1.200516844519774 ,1.319226783394077 ,0.9 ;-1.448565342215073 ,1.040797026001386 ,0.9 ;-1.633304583467861 ,0.716879444274193 ,0.9 ;-1.74666057695816 ,0.361630790862987 ,0.9 ;-1.783679121828036 ,-0.009422863405995 ,0.9 ;-1.74274233003199 ,-0.380064693328219 ,0.9 ;-1.62563933580803 ,-0.73409587239926 ,0.9 ;-1.437488101926254 ,-1.056043539263633 ,0.9 ;-1.186511740157085 ,-1.331837036003058 ,0.9 ;-0.883679121828036 ,-1.549422863405995 ,0.9 ;-0.560148836801076 ,-1.693467826866044 ,0.9 ;-0.195816481541609 ,-1.772922983537826 ,0.9 ;0.177073993592956 ,-1.774892898400645 ,0.9 ;0.542225485512215 ,-1.699291476722297 ,0.9 ;0.883679121828036 ,-1.549422863405995 ,0.9 ;1.186511740157084 ,-1.331837036003058 ,0.9 ;1.437488101926253 ,-1.056043539263633 ,0.9 ;1.625639335808029 ,-0.73409587239926 ,0.9 ;1.74274233003199 ,-0.380064693328219 ,0.9 ;1.783679121828036 ,-0.009422863405995 ,0.9 ;1.741102729306174 ,0.370082809655612 ,0.9 ;1.62611091460383 ,0.723991224674924 ,0.9 ;1.440050249987407 ,1.046257749080602 ,0.9 ;1.191052479318768 ,1.322797789349762 ,0.9 ;0.89 ,1.541525218736301 ,0.9 ;0.550050249987407 ,1.692880599005374 ,0.9 ;0.186060664616423 ,1.770248973755527 ,0.9 ;-0.186060664616423 ,1.770248973755527 ,0.9 ;-0.550050249987406 ,1.692880599005374 ,0.9 ;-0.89 ,1.541525218736302 ,0.9 ;0.408558088952066 ,1.25230998077626 ,1.5 ;0.139260228937704 ,1.309888006142593 ,1.5 ;-0.136123971325954 ,1.310217640100473 ,1.5 ;-0.405558900847383 ,1.253284476064179 ,1.5 ;-0.65726896031426 ,1.14157676649773 ,1.5 ;-0.88025321228901 ,0.979976674342242 ,1.5 ;-1.064766174963181 ,0.775546899068186 ,1.5 ;-1.202743746476483 ,0.537222002817936 ,1.5 ;-1.288155644863941 ,0.275417927167362 ,1.5 ;-1.317268960314261 ,0.00157676649773 ,1.5 ;-1.291154832968624 ,-0.274443431879442 ,1.5 ;-1.205880004088233 ,-0.536892368860056 ,1.5 ;-1.067902432574931 ,-0.775876533026065 ,1.5 ;-0.883252400393693 ,-0.980951169630161 ,1.5 ;-0.66 ,-1.143153532995459 ,1.5 ;-0.407902432574931 ,-1.255394601509603 ,1.5 ;-0.137977571513303 ,-1.312768901886121 ,1.5 ;0.137977571513303 ,-1.312768901886121 ,1.5 ;0.407902432574931 ,-1.255394601509603 ,1.5 ;0.66 ,-1.143153532995459 ,1.5 ;0.882596744016557 ,-0.977866548896817 ,1.5 ;1.066619775150529 ,-0.772995637282537 ,1.5 ;1.204026403900885 ,-0.534341107074408 ,1.5 ;1.288811301241076 ,-0.272333306434018 ,1.5 ;1.31726896031426 ,0.00157676649773 ,1.5 ;1.288155644863941 ,0.275417927167361 ,1.5 ;1.202743746476483 ,0.537222002817936 ,1.5 ;1.064766174963181 ,0.775546899068186 ,1.5 ;0.88025321228901 ,0.979976674342242 ,1.5 ;0.65726896031426 ,1.14157676649773 ,1.5 ;-1.393699704909526 ,0 ,0.707789138293422 ;-1.406727461756839 ,-0.299009152477831 ,0.698468478862468 ;-1.355726539755554 ,-0.603608344933256 ,0.688850518052228 ;-1.238899117490855 ,-0.900112896765416 ,0.678925772830864 ;-1.057366526901983 ,-1.174324497538821 ,0.668684457685963 ;-0.815306736300269 ,-1.412152691025227 ,0.6581164749763 ;-0.519959783189616 ,-1.600271664715896 ,0.647211404975857 ;-0.181492347978504 ,-1.726784344320071 ,0.635958495600275 ;0.187281415349074 ,-1.781863641133724 ,0.624346651805608 ;0.571319233554963 ,-1.758339799583693 ,0.612364424648928 ;0.9539 ,-1.652203265339953 ,0.6 ;1.27656737081143 ,-1.417771698045774 ,0.6 ;1.543442621868526 ,-1.121376704323581 ,0.6 ;1.742862024090555 ,-0.775972167660012 ,0.6 ;1.866109992679956 ,-0.396653923742122 ,0.6 ;1.907800000000001 ,-0 ,0.6 ;1.866109992679956 ,0.396653923742121 ,0.6 ;1.742862024090556 ,0.775972167660012 ,0.6 ;1.543442621868526 ,1.121376704323581 ,0.6 ;1.276567370811431 ,1.417771698045774 ,0.6 ;0.92441393831847 ,1.601131908392431 ,0.612364424648928 ;0.55365914952053 ,1.703987649685787 ,0.624346651805608 ;0.181492347978504 ,1.726784344320072 ,0.635958495600275 ;-0.17588222682616 ,1.673407607044337 ,0.647211404975857 ;-0.503887274290314 ,1.550805568675412 ,0.6581164749763 ;-0.7901047395334 ,1.368501552172825 ,0.668684457685963 ;-1.02468220503154 ,1.138024880630802 ,0.678925772830864 ;-1.200603430526258 ,0.872289451546457 ,0.688850518052228 ;-1.313819593142159 ,0.58495017018728 ,0.698468478862468 ;-1.363244022500668 ,0.289766462139952 ,0.707789138293422 ;-1.6 ,0 ,1.2 ;-1.565036161174089 ,-0.332658705308415 ,1.2 ;-1.461672732228162 ,-0.65077862892128 ,1.2 ;-1.294427190999916 ,-0.940456403667957 ,1.2 ;-1.070608970174174 ,-1.189031720763831 ,1.2 ;-0.8 ,-1.385640646055102 ,1.2 ;-0.494427190999916 ,-1.521690426072247 ,1.2 ;-0.167245541228246 ,-1.591235032589238 ,1.2 ;0.167245541228246 ,-1.591235032589238 ,1.2 ;0.494427190999916 ,-1.521690426072247 ,1.2 ;0.8 ,-1.385640646055103 ,1.2 ;1.070608970174174 ,-1.189031720763832 ,1.2 ;1.294427190999917 ,-0.940456403667958 ,1.2 ;1.461672732228163 ,-0.650778628921281 ,1.2 ;1.565036161174091 ,-0.332658705308415 ,1.2 ;1.600000000000002 ,-0 ,1.2 ;1.565036161174091 ,0.332658705308415 ,1.2 ;1.461672732228163 ,0.650778628921281 ,1.2 ;1.294427190999917 ,0.940456403667958 ,1.2 ;1.070608970174175 ,1.189031720763832 ,1.2 ;0.800000000000001 ,1.385640646055104 ,1.2 ;0.494427190999917 ,1.521690426072248 ,1.2 ;0.167245541228246 ,1.59123503258924 ,1.2 ;-0.167245541228246 ,1.59123503258924 ,1.2 ;-0.494427190999916 ,1.521690426072248 ,1.2 ;-0.800000000000001 ,1.385640646055104 ,1.2 ;-1.070608970174175 ,1.189031720763833 ,1.2 ;-1.294427190999918 ,0.940456403667959 ,1.2 ;-1.461672732228164 ,0.650778628921282 ,1.2 ;-1.565036161174092 ,0.332658705308416 ,1.2 ;-0.9682 ,0 ,1.75 ;-0.947042507030471 ,-0.201300099049755 ,1.75 ;-0.884494712089566 ,-0.39380241782599 ,1.75 ;-0.783290253953824 ,-0.569093681269572 ,1.75 ;-0.647852253076646 ,-0.719512820027213 ,1.75 ;-0.4841 ,-0.838485795944094 ,1.75 ;-0.299190253953824 ,-0.920812919076968 ,1.75 ;-0.101204458135742 ,-0.962896099095563 ,1.75 ;0.101204458135742 ,-0.962896099095563 ,1.75 ;0.299190253953824 ,-0.920812919076968 ,1.75 ;0.4841 ,-0.838485795944094 ,1.75 ;0.647852253076647 ,-0.719512820027214 ,1.75 ;0.783290253953825 ,-0.569093681269573 ,1.75 ;0.884494712089567 ,-0.39380241782599 ,1.75 ;0.947042507030472 ,-0.201300099049755 ,1.75 ;0.968200000000001 ,-0 ,1.75 ;0.947042507030472 ,0.201300099049755 ,1.75 ;0.884494712089567 ,0.39380241782599 ,1.75 ;0.783290253953825 ,0.569093681269573 ,1.75 ;0.647852253076647 ,0.719512820027214 ,1.75 ;0.484100000000001 ,0.838485795944095 ,1.75 ;0.299190253953824 ,0.920812919076969 ,1.75 ;0.101204458135742 ,0.962896099095563 ,1.75 ;-0.101204458135742 ,0.962896099095564 ,1.75 ;-0.299190253953824 ,0.920812919076969 ,1.75 ;-0.484100000000001 ,0.838485795944095 ,1.75 ;-0.647852253076647 ,0.719512820027214 ,1.75 ;-0.783290253953825 ,0.569093681269573 ,1.75 ;-0.884494712089568 ,0.39380241782599 ,1.75 ;-0.947042507030472 ,0.201300099049755 ,1.75 ;-0.696 ,0 ,1.875 ;-0.680790730110728 ,-0.14470653680916 ,1.875 ;-0.63582763851925 ,-0.283088703580757 ,1.875 ;-0.563075828084963 ,-0.409098535595561 ,1.875 ;-0.465714902025765 ,-0.517228798532266 ,1.875 ;-0.348 ,-0.602753681033969 ,1.875 ;-0.215075828084963 ,-0.661935335341427 ,1.875 ;-0.072751810434287 ,-0.692187239176318 ,1.875 ;0.072751810434287 ,-0.692187239176318 ,1.875 ;0.215075828084963 ,-0.661935335341427 ,1.875 ;0.348 ,-0.60275368103397 ,1.875 ;0.465714902025766 ,-0.517228798532267 ,1.875 ;0.563075828084964 ,-0.409098535595562 ,1.875 ;0.635827638519251 ,-0.283088703580757 ,1.875 ;0.680790730110729 ,-0.144706536809161 ,1.875 ;0.696 ,0 ,1.875 ;0.680790730110729 ,0.144706536809161 ,1.875 ;0.635827638519251 ,0.283088703580757 ,1.875 ;0.563075828084964 ,0.409098535595562 ,1.875 ;0.465714902025766 ,0.517228798532267 ,1.875 ;0.348 ,0.60275368103397 ,1.875 ;0.215075828084964 ,0.661935335341428 ,1.875 ;0.072751810434287 ,0.692187239176319 ,1.875 ;-0.072751810434287 ,0.692187239176319 ,1.875 ;-0.215075828084964 ,0.661935335341428 ,1.875 ;-0.348 ,0.60275368103397 ,1.875 ;-0.465714902025766 ,0.517228798532267 ,1.875 ;-0.563075828084964 ,0.409098535595562 ,1.875 ;-0.635827638519251 ,0.283088703580757 ,1.875 ;-0.68079073011073 ,0.144706536809161 ,1.875 ;-1.067339846241262 ,0 ,0.466330076879369 ;-1.111680132533492 ,-0.236294906648194 ,0.431742136003038 ;-1.105549875531468 ,-0.492222517625891 ,0.394912499272705 ;-1.042505966791333 ,-0.757424920573248 ,0.355695879048387 ;-0.91813073772209 ,-1.019687487563512 ,0.313937571382222 ;-0.730527154266445 ,-1.26531014749819 ,0.269472845733555 ;-0.480752388564113 ,-1.47960371174145 ,0.22212629513057 ;-0.173159522473878 ,-1.647502805535621 ,0.171711144214906 ;0.184382248481141 ,-1.754279910938606 ,0.118028512439642 ;0.580416342929584 ,-1.786337823341846 ,0.060866629514019 ;1 ,-1.732050807568878 ,0 ;1.338261212717717 ,-1.486289650954789 ,0 ;1.618033988749896 ,-1.175570504584947 ,0 ;1.827090915285203 ,-0.813473286151601 ,0 ;1.956295201467612 ,-0.415823381635519 ,0 ;2.000000000000001 ,-0 ,0 ;1.956295201467612 ,0.415823381635519 ,0 ;1.827090915285203 ,0.813473286151601 ,0 ;1.618033988749896 ,1.175570504584947 ,0 ;1.338261212717718 ,1.48628965095479 ,0 ;0.939133370485981 ,1.626626712765125 ,0.06086662951402 ;0.545088356420607 ,1.677609460861618 ,0.118028512439642 ;0.173159522473878 ,1.647502805535622 ,0.171711144214906 ;-0.162619885972636 ,1.547224862647775 ,0.22212629513057 ;-0.451490611041401 ,1.389545220791316 ,0.269472845733555 ;-0.686062428617779 ,1.188294983530089 ,0.313937571382222 ;-0.862247214263728 ,0.957622547037905 ,0.355695879048388 ;-0.979052142344491 ,0.711323018548031 ,0.394912499272705 ;-1.038258780848225 ,0.462262592007099 ,0.431742136003038 ;-1.044015909768481 ,0.221912432109189 ,0.466330076879369 ;]
hold on
stem3 ( pos( 1 :250 ,1 ) ,pos( 1 :250 ,2 ) ,pos( 1 :250 ,3 ) ,'o ','linestyle ','none ') ;
[ t] =MyCrustOpen( pos) ;
axis equal
trisurf ( t,pos( :,1 ) ,pos( :,2 ) ,pos( :,3 ) ,'facecolor ','c ','edgecolor ','b ')
hold off
Beschreibung:
Download
Dateiname:
Unbenannt.JPG
Dateigröße:
119.58 KB
Heruntergeladen:
929 mal
Beschreibung:
Download
Dateiname:
Unbenannt.JPG
Dateigröße:
119.58 KB
Heruntergeladen:
910 mal
DINA4
Gast
Beiträge: ---
Anmeldedatum: ---
Wohnort: ---
Version: ---
Verfasst am : 11.01.2011, 11:44
Titel :
Ich hab jetzt einen Weg gefunden damit es optisch besser aussieht. Er verbindet jetzt nur die Punkte falsch. Wie löse ich das? Siehe auch bilder im Anhang.
Code:
x=pos( :,1 ) ;
y=pos( :,2 ) ;
z=pos( :,3 ) ;
tx= -2.5 :0.1 :2.5 ;
ty= -2.5 :0.1 :2.5 ;
[ XI,YI] =meshgrid ( tx,ty) ;
ZI=griddata ( x,y,z,XI,YI,'cubic ') ;
II=isnan ( ZI) ;
ZI( II) =0 ;
surf ( XI,YI,ZI,'FaceColor ','red ','EdgeColor ','none ') ;
camlight right;
lighting phong;
set ( gca ,'CameraPosition ',[ 2 2 1.5 ] ) ;
grid on
xlabel ( { 'X ';''} )
ylabel ( { 'Y ';''} )
zlabel ( { 'Z ';''} )
stem3 ( pos( 1 :250 ,1 ) ,pos( 1 :250 ,2 ) ,pos( 1 :250 ,3 ) ,'o ','linestyle ','none ') ;
Beschreibung:
Download
Dateiname:
Kopie von Unbenannt2.JPG
Dateigröße:
65.24 KB
Heruntergeladen:
901 mal
Beschreibung:
Download
Dateiname:
Kopie (2) von Unbenannt2.JPG
Dateigröße:
64.35 KB
Heruntergeladen:
869 mal
Beschreibung:
Download
Dateiname:
Unbenannt.JPG
Dateigröße:
38.58 KB
Heruntergeladen:
907 mal
Einstellungen und Berechtigungen
Du kannst Beiträge in dieses Forum schreiben. Du kannst auf Beiträge in diesem Forum antworten. Du kannst deine Beiträge in diesem Forum nicht bearbeiten. Du kannst deine Beiträge in diesem Forum nicht löschen. Du kannst an Umfragen in diesem Forum nicht mitmachen. Du kannst Dateien in diesem Forum posten Du kannst Dateien in diesem Forum herunterladen
Impressum
| Nutzungsbedingungen
| Datenschutz
| FAQ
| RSS
Hosted by:
Copyright © 2007 - 2024
goMatlab.de | Dies ist keine offizielle Website der Firma The Mathworks
MATLAB, Simulink, Stateflow, Handle Graphics, Real-Time Workshop, SimBiology, SimHydraulics, SimEvents, and xPC TargetBox are registered trademarks and The MathWorks, the L-shaped membrane logo, and Embedded MATLAB are trademarks of The MathWorks, Inc.