How to make the pressure contours colorbar concentration the same for all values
Mostra commenti meno recenti
How to make the Cp reference colour the same for this coding with different Cp values? Because when I run this coding for the other half of the tail, the Cp colour at 0.008 is in orange colour. How to make the Cp contour constant?

% Make x-y mesh grid
x = [-4.2195;
-5.7195;
-7.2195;
-8.7195;
-2.7195;
-4.2195;
-5.7195;
-7.2195;
-8.7195;
-1.2195;
-2.7195;
-4.2195;
-5.7195;
-7.2195;
-8.7195];
y = [6.3;
6.3;
6.3;
6.3;
4;
4;
4;
4;
4;
1.7;
1.7;
1.7;
1.7;
1.7;
1.7];
pressure = [0.007422;
0.005551;
0.003788;
0.003951;
0.008568;
0.004381;
0.003754;
0.003587;
0.003588;
0.006594;
0.003985;
0.003538;
0.00387;
0.003596;
0.003762];
[xq,yq] = meshgrid(...
linspace(min(x),max(x),170),...
linspace(min(y),max(y),170));
% Interpolate using "griddata" function
pq = griddata(x,y,pressure,xq,yq,'cubic');
% Visualize the result
figure
%surfc(xq,yq,pq)
surfc(xq,yq,pq, 'EdgeColor','none ')
xlabel('x','FontSize',16)
ylabel('y','FontSize',16)
c = colorbar;
c.Label.String = 'Cp';
c.Label.FontSize = 16;
c.Limits = [0 0.012]
Risposta accettata
Più risposte (2)
Seelan Kumar
il 3 Giu 2022
0 voti
Seelan Kumar
il 3 Giu 2022
0 voti
Categorie
Scopri di più su Colorbar in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
