Borrar filtros
Borrar filtros

Combination and surface plot

2 visualizaciones (últimos 30 días)
Damilola
Damilola el 14 de Abr. de 2015
Respondida: pfb el 14 de Abr. de 2015
Please I need help on code for getting combination of the attached energy use schedule, each schedule has an equivalent energy cost and consumption and the practicality of each schedule ranges from 1 to 10, i.e. each schedule could have a practicality of 1, 2, 3, ...,10. I want to use the results to then obtain a surface plot that has Cost, consumption and practicality on each the axes. I will be glad if someone can help me out or lead me on how to go about writing a code for this. Thanks
  3 comentarios
John D'Errico
John D'Errico el 14 de Abr. de 2015
Editada: John D'Errico el 14 de Abr. de 2015
The data that you give in that worksheet has 6 sets of numbers, for 6 possible schedules. No practicality is even shown.
So the answer is, given the information you have provided, no such plot can be generated. Magic only works for Harry Potter.
Even if you did improve the data, so that you had actually told us the practicality for each such schedule, you would still almost certainly not be able to generate a complete surface. At least, any such surface would be a terribly poor guess. Your data is simply inadequate to generate a surface. You have 6 data points that are not at all well scattered. What did I say about magic? It still won't work.
Damilola
Damilola el 14 de Abr. de 2015
Thanks for your comments, an example of what I need to plot is cost = [0.056;0.0399;0.0398;0.0334;0.052;0.0502] consumption = [0.6111;0.6111;0.6181;0.5451;0.5475;0.611] practicality = [1;6;7;9;5;4]
Thanks once again

Iniciar sesión para comentar.

Respuestas (1)

pfb
pfb el 14 de Abr. de 2015
You could try "trisurf". But I agree with John d'Errico that your have too few data.
tri=delaunay(cost,consumption);
trisurf(tri,cost,consumption,practicality);
You actually get a surface...

Categorías

Más información sobre Animation 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!

Translated by