2.5 Advanced Visualization


Formal Metadata

2.5 Advanced Visualization
Title of Series
Part Number
Number of Parts
McLennan, Michael
CC Attribution - NonCommercial - ShareAlike 3.0 Unported:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal and non-commercial purpose as long as the work is attributed to the author in the manner specified by the author or licensor and the work or content is shared also in adapted form only under the conditions of this license.
Release Date

Content Metadata

Subject Area
00:09 Advanced Visualization 00:25 Molecules 01:36 Molecules 06:07 Data on a 2D rectangular grid 07:12 Mesh: unirect2d 10:39 Field 13:12 Cloud Mesh 15:07 Field for Cloud Mesh 16:13 Sequences 16:50 Sequence of Curves 18:42 If all else fails, use an image 19:57 If all else fails, use an image 21:42 Assignment #9: Bessel functions in Rappture
Point (geometry) Ocean current Computer programming Histogram Server (computing) Computer file Mountain pass Connectivity (graph theory) Real number Collaborationism Sheaf (mathematics) Boom (sailing) Function (mathematics) Parameter (computer programming) Mereology Protein Variance Wave packet Atomic number Visualization (computer graphics) Maize Data structure Metropolitan area network Simulation File format Structural load Element (mathematics) Interactive television Coma Berenices System call Symbol table Plot (narrative) Inclusion map Calculation Moore's law Computer animation Visualization (computer graphics) Personal digital assistant Function (mathematics) Device driver Volumenvisualisierung Website Configuration space output Whiteboard Form (programming) Electric current
Point (geometry) Ocean current Computer programming Slide rule Computer file Code Connectivity (graph theory) Sheaf (mathematics) Function (mathematics) Protein Emulation Variance Data compression String (computer science) Database Visualization (computer graphics) Row (database) Physical law Data structure Metropolitan area network Zoom lens File format Computer program Content (media) Coma Berenices Color management System call Inclusion map Computer animation Personal digital assistant Function (mathematics) Right angle Units of measurement Data type Electric current
Rectangle Code Multiplication sign Sheaf (mathematics) Function (mathematics) Parameter (computer programming) Food energy Variance Maxima and minima Matrix (mathematics) Mathematics Object (grammar) Visualization (computer graphics) Active contour model Cumulative distribution function Metropolitan area network Spacetime Point (geometry) Computer file Electronic mailing list Bit Measurement Demoscene Hausdorff dimension Computer cluster Order (biology) Duality (mathematics) Right angle Uniform space Quicksort Point (geometry) Surface Computer programming Polygon mesh Divisor Computer file Line (geometry) Connectivity (graph theory) Plot (narrative) Field (computer science) Emulation Number String (computer science) Data structure Conditional-access module Subtraction Run time (program lifecycle phase) Polygon mesh Information Sine Surface Interactive television Field (computer science) Correlation and dependence Rectangle Cartesian coordinate system System call Plot (narrative) Inclusion map Computer animation Personal digital assistant Function (mathematics) Field (mathematics) Statement (computer science) Matching (graph theory)
Point (geometry) Polygon mesh Manufacturing execution system Divisor Correspondence (mathematics) Multiplication sign Computer-generated imagery Curve Sheaf (mathematics) Price index Water vapor Point cloud Function (mathematics) Field (computer science) Variance Sequence Medical imaging Array data structure String (computer science) Visualization (computer graphics) Subtraction Sequence diagram Units of measurement Curve Simulation Polygon mesh Point (geometry) Electronic mailing list Point cloud Field (computer science) Line (geometry) Functional (mathematics) Plot (narrative) Subject indexing Loop (music) Computer animation Field (mathematics) Triangle Quicksort Object (grammar) Units of measurement Matching (graph theory) Finite element method Sequence diagram Series (mathematics)
Touchscreen Code Multiplication sign Zoom lens Curve Combinational logic Sheaf (mathematics) Median Price index Function (mathematics) Parameter (computer programming) Storage area network Medical imaging Bessel function Data compression Visualization (computer graphics) Moving average Curve Electric generator Bit Functional (mathematics) Uniform resource name Computer cluster Octave Data type Resultant Sequence diagram Wide area network Point (geometry) Surface Computer programming Slide rule 12 (number) Game controller Computer file Computer-generated imagery Average Uniqueness quantification Computer worm Integer Software protection dongle Sequence diagram Surface Element (mathematics) Content (media) Letterpress printing Frame problem Plot (narrative) Inclusion map Dressing (medical) Subject indexing Computer animation Visualization (computer graphics) Personal digital assistant Function (mathematics) Element (mathematics) Object (grammar)
Point (geometry) Computer programming Polygon mesh Computer file Code Sheaf (mathematics) Parameter (computer programming) Function (mathematics) Food energy Field (computer science) Formal language Number Maxima and minima Goodness of fit Term (mathematics) Octave Visualization (computer graphics) Moving average Subtraction Metropolitan area network Element (mathematics) Directory service Functional (mathematics) Maxima and minima Inclusion map Computer animation Bessel function Function (mathematics) Field (mathematics) Order (biology) Right angle Figurate number Units of measurement Data type
Software bug Computer file Computer-generated imagery Computer program Interface (computing) Bit Ordinary differential equation Plot (narrative) Field (computer science) Emulation Maxima and minima CAN bus Medical imaging Computer animation Bessel function Function (mathematics) Octave Visualization (computer graphics) Moving average Convex hull Routing Task (computing)
Point (geometry) Metropolitan area network State of matter Direction (geometry) Structural load Simultaneous localization and mapping Interface (computing) Ext functor Parameter (computer programming) Function (mathematics) Mereology Field (computer science) Number Medical imaging Computer animation Bessel function Function (mathematics) Visualization (computer graphics) Convex hull Integer Units of measurement
Point (geometry) Computer programming Connectivity (graph theory) Surface Physical law Source code Sheaf (mathematics) Function (mathematics) Cartesian coordinate system Functional (mathematics) Field (computer science) Computer animation Bessel function Personal digital assistant Function (mathematics) Hierarchy Visualization (computer graphics) Universe (mathematics) Convex hull Right angle Error message
Computer programming Functional (mathematics) Medical imaging Computer animation Bessel function Function (mathematics) Uniform resource name Analogy Visualization (computer graphics) Computer cluster Utility software Convex hull Scripting language Software testing Figurate number Units of measurement
Computer programming Code Function (mathematics) Line (geometry) Virtual memory Emulation Skeleton (computer programming) Bessel function Computer animation Bessel function Function (mathematics) Uniform resource name Visualization (computer graphics) Convex hull Software testing Scripting language
Point (geometry) Sheaf (mathematics) Function (mathematics) Mereology Emulation Number Maxima and minima Chain String (computer science) Visualization (computer graphics) Integer Raw image format Computer Cellular automaton Line (geometry) Cartesian coordinate system Functional (mathematics) Maxima and minima Computer animation Doubling the cube Bessel function Function (mathematics) Vertex (graph theory) Convex hull Units of measurement
Point (geometry) Computer programming Computer file Decision theory Connectivity (graph theory) Sheaf (mathematics) Insertion loss Function (mathematics) Heat transfer Infinity Disk read-and-write head Mereology Food energy Field (computer science) Number Wave packet Summation Medical imaging Array data structure Matrix (mathematics) Data compression String (computer science) Visualization (computer graphics) Flag Error message Surjective function File format Structural load Physical law Interactive television Electronic mailing list Line (geometry) Functional (mathematics) Plot (narrative) Maxima and minima Computer animation Bessel function Personal digital assistant Function (mathematics) Uniform resource name Computer cluster Order (biology) Right angle Pressure Units of measurement Resultant Wide area network
Sine View (database) Frame problem Plot (narrative) Revision control Medical imaging Computer animation Bessel function Function (mathematics) Boom (sailing) Visualization (computer graphics) Subtraction Multiplication
Metropolitan area network Medical imaging Mathematics Malware Computer animation Bessel function File format Function (mathematics) Visualization (computer graphics) Bit Conditional-access module
Computer icon Metropolitan area network Zoom lens Raw image format Zoom lens Interior (topology) Local Group Summation Medical imaging Pointer (computer programming) Malware Computer animation Bessel function Function (mathematics) Visualization (computer graphics) Units of measurement
Computer icon Metropolitan area network Personal identification number Spacetime State of matter Cellular automaton Interior (topology) Sheaf (mathematics) Insertion loss Cartesian coordinate system Functional (mathematics) Storage area network Plot (narrative) Mach's principle Computer animation Bessel function Function (mathematics) Uniform resource name Visualization (computer graphics) Quicksort Resultant
why I out how online simulation and more Fernando technology board in
this last section I 1 walk through some of the advanced visualizations stuff that's built into rapture because at this point you can build a pretty functional tool but we haven't really done much with the output we looked occurs we looked at histograms is a lot more that you can do on the output side to
suppose that your program producers of molecules and the simulate and part of the thing that it generates is a molecule that maybe you doing molecular dynamics calculations there is a way to do that and rapture there's an element called structure uh and again this is built into the builder yet so I'm again showing you advanced stuff that you can just drag and drop really easily but if you can create XML in the output section it looks like this then you can get a molecule in rapture an input an output usually I guess could be either in this case so all you need to do is make the right XML you start with something that's like a structure and it has a current and components and then molecule and then inside they're basically atoms that have a symbol in x y z coordinate another atom with a symbol in x y z coordinates and so forth so if you can generate that XML in your program you've got a molecule and rapture automatically knows how to draw molecules it it automatically connects to a rendering server talks to a program called primal written in Python does molecular visualization and it'll take your molecule and render in 3 D but there is another way to after we created that a lot of people said there's this PDB Protein Databank format of you guys know anything about that but it's real popular file format there's a of protein that databanks site where you can download all of these molecules if you want the molecular configuration of aspirin and you can find it in the Protein Data Bank along with lots of other things and there's a PDB file format and a lot of people said well I would have to convert from PDB into rapture so we need a way that you can say structure current components molecule and then you can just say PDB and inside the PDB section you can put something from the protein data bank in their interaction had a plot that to so if you get something from the Protein Data Bank show that in their boom you've got a molecule so how do you do that in your program and now again work this is what you run that XML file would look like if you successful and this is how you actually generated and suppose we have a Fortran program I'm assuming Fortran we've seen these calls already the builder does this a couple of the builder and calls for like API lived puts training and all that there is an API lived put file command that you can use and you pass even as the 1st argument the thing rapture loads at the beginning and could be called driver could be called I O it's the thing in your program and if we look at an example program you guys are looking perplexed at me may I think it's the end of the day so
let me show you my example program so in my Fortran program if I look at what rapture generated and the other in my example program but it was called I in in this program see just like the builder says API lived put string and automatically generated this text I O and then you put in the past and then you put in which you want to say that that have the same kind of thing here it's called I O because somewhere near the top your file so this is live command here that generates that name I 0 alright so if you wanted to do a molecule right here on your program in the output section we get add like an API live put file command and we get in the past output that when we stop the example of this point flip back to my slides today so in
that Fortran program this is what I would type call API lived put file that same name I 0 output . mild . current components molecule that PDB again that's the way I reference things it's in the output section and creating this structure called mall and in the current section of the components under molecule I wanted tag PDB and I want all my data there they are people file looks for a file in this case called data . PDB it reads the contents of that file and stuff sitting in your output so if your program generates a file called data . pdb here's how you can take that file and suck it in the rapture program and rapture will read that file and stuff it in right where the PTB tag is so if I look to that file and this at the all that Adam 1 sea level last all that Adam stuff that you see up there that's within my file my program generated that and when I call API live put file and given the name of the file is gonna read that file and stick it in just like you see up there if I look in the around XML that's what it looks like after I'm all done so that's the kind of Fortran code that you write to sticks in Protein databank stuff in your tool of the 1 here means compress the data and the 0 means over right as opposed to a append and all I guess if we set compress it would look exactly like that it would look like a bunch of compressed gobbledy-gook but if I made this 0 so that I didn't compress the data then you'd see it looking like that up there right so just remember ever run across a case where you need to produce some molecules and if you've got that molecules in the Protein Data Bank file format just remember all the others this slide I can go back and agreed that out the slide and put it in my program
right movement on the show you another thing another thing that's possible you can create surface plots like this in your program what times you'll have a program that generates a bunch of data that you want see the mountain plot surface plot and the way you do that depending on what your data is what you get is usually composed of 2 things the mesh and a bunch of values that sit on the mesh and a lot of times a mesh might be uniform in rectangular just as it's easy to generate a mesh that way so rapture has a thing called the interactivity it's a two-dimensional you a uniform rectangular mesh uniform in X or Y that doesn't have to be uniform everywhere will each each axis is uniformly spaced so this you direct to means that I'm not rectangular mesh and you can specify the sizes and everything in the match and then at each point of the match you have a value of field value and then if you give rapture those 2 things the field and the match that it will generate the the surface the mountain plot as an output the mystery I that
again if you're looking in your in your tool that answer if you can look at you run file at the end your program in the run file if you look in the output section you see something like what I'm showing here you've seen for example this year activity with something migrated or whatever it's got a label energy grid it's got x-axis section and y axis section the x axis and the y axis described the 2 dimensions of your match on the X. axis has a label and a mean value goes from 0 to 1 max value 1 and has 50 points so imagine it starts at 0 and ends at 1 and you divided into 50 points similarly the y axis goes from 0 to 1 and it's also got 50 points don't have to but could and might have 20 points minus 70 points but it's going from in this case 0 to 1 with 50 points in X and Y and I have a label Fermi-Dirac factor in another label energy and all that so if if I put that information in there in the output section then and then you'll see at least use of a uniform rectangular mentioning under the field yet but that defines the match now again you can hard code this information in your tool that XML if you know ahead of time everything about you match if you know your measures gonna simply always go from 0 to 1 and it's always get 50 points and so is that this label and all that all of this information that you see here you can hard code into your tool that x amount but you may say well I don't know how many points and have if I simulate in 1 case I might have a 100 points of assimilate another case I might have a thousand points right I don't know how many points and that have so you can put a lot of the information in the 2 about x amount and then you can change it in your program this is how I would change it in a Python program I would do the usual Python put command and I would say in the output section look for you directing the with the name migrated look in the x-axis section for parameter called max and give it a value 1 . 0 so for this run of the program I leave 0 alone but it's going to go to 1 . 0 actually didn't change but anyway so I'm I'm overriding the value here upend no I'm also going into the output section interactivity in the x axis and setting points to 50 for example and append equals no so I can hard code that information in the tool about XML and I could right in my program at my program could in the latest values for maximum points or whatever so this kind of a duality between the 2 will then XML and these programs statements that create things in the tool that XML we saw that in 1 of the the last than the last but the 1 before the lab exercise before we saw how you can create a brand new things in the XML just by putting information in there and that's what we're doing here you could start with most that information defined and then overwrite selectively whatever values you want or you can create every single bit of 1 of those information you can set the about label you can the x-axis label the Y axis label you have all kinds of commands here to settle those different labels and set the various values and that would create that structure so that's how you define things in the XML like direct to the trash in order to see the field plotted you also have to define a field and this is what the field looks like the field has about label the field has component section and the component has a match and values the mash that you see here this match right here out of this statement in red this defines that match that we're looking at a 2nd ago when you're when you define a field you have to say which measure belongs to this field goes to this mesh and the mesh says where all the points are in space right so so inside the component section you have a amassed output . uni 2 D parentheses migrant OK now I know where all the points on space and then you specify all the values at the 1st match point is this value at the next match point is this value you can kind of see here you know this is sort of how the values are laid out B 1 1 V 1 to V 1 3 and so forth for X and Y and again the way that you would do that if you want to put program field values in my code a lot of this in your tool that XML in tool that XML you might have a field statement with about and labeling component and match you probably don't have the values of the values or something that could generated at run time right so most of that information can be neutral that XML but then your program has to do this the program and take a bunch of values and there's a reshaped command I took a of other matrix z in Matlab z take is the transpose of the reshaped counter reshape said and then the valves makes it so there's a big long list of numbers so I'm basically taking my and my matlab matrix and converting it into a big long list of numbers and then stuffing in using the call API lived put string in the output section look for the field names the scene field ID equals the right there and then in the component that value section stick all those values so this column Matlab takes mizing matrix and makes a bunch of different numbers and then I put those into the value section to generate the code so this little complicated have to come work for if you wanna do that all the advanced graphics it's not easy you work for workforce but this is how you do it is define a lot of this stuff in the tool that XML and then you override things in your program to set the values and kind of tweak trash there is also a way of
handling an irregular mashed sometimes not the world a so easy everything's on a rectangular mash so you might you might have a bunch of different points and then there's something called a cloud mentioned rapture where you can just specify all the different X Y points and so for the cloud match again all these things have about section with the label so you can talk you can say with that that thing is this is a 2 D mesh on a cloud mesh also has units I said microns but hide yes that means I don't wanna see the mesh usually I just wanna see the field and then you can specify the points X Y newline x y newline XY new line so these are all the points on the mesh each point here each x and y value corresponds to 1 point on the mesh so this 1st line is probably this point and this next line is like this point and so forth so you to specify all the points on the mesh and then rapture read all those points and will connect them all together and make triangles out of so if you have an irregular mesh that looks like this then you do that in rapture and again how would I do that well in in Python here if I had an X factor and y vector is is a function that puts them together and for each x y in x and y vector is going to go through and computed create a string of X and Y and the new line so using X and Y substituting in and then I stick those things in in the output that cloud of points section I'm gonna put in the x and the y and the new line and append equals yes which means that each time I'm going through this loop it's adding another x y x y x y and so i'm converting x that and why back into a list the points that show up in the point section a sort of doing right and if I defined that cloud Nash I might have a field that goes with the cloud mesh just like the field we minute ago except this was using a different mesh so there's a mesh here that says mashed output . cloud and to the that's the the cloud that we defined right up here I've got a cloud named entity so I set the mesh down here output that cloud in 2 D and then I get all the values and the values adjusted water with the mesh points this is the 1st match point this is the value for the last point is the next best point this is the value for that match point next match point value for that match points so for so if you're doing finite element simulation this stuff probably seems really familiar to you because you just have a bunch of XY points and you have the value that we've computed at each point under finite element mesh anyway that's how you do fancy plots like the 1 that shown appear you notice it's really regular because wherever I have points you can kind of see the triangles here but over here I don't have any point so there's nothing plotted trash by there's another
thing completely different things you can do this the thing enrapture called the sequence and you can use a sequence to create something like a movie this sequence you can use with a sequence of images and you get something like a movie you can create a sequence of curves and you get something like a plot that acts like an animated plot you can also create a sequence of molecules and then you get a molecule for example with molecular dynamics that may be jiggling around and doing different things so a sequence has some kind of rapture object as a function of time or index or something like that and here's how you
do it again if you can create this XML in your program then you're good to go at the end of the day if you run that XML file looks like this you can load up in rapture and it'll show you a sequence with this sequence works this sequence has about label that's the label it shows up at the top of of the plot it as an index the index is in this case it says parameter a so down here there be a little movie control and it'll say parameter a for the movie control you can actually move around on this movie control and set whatever frame 1 or you can press the play button and will play for all the frames and and has it's doing it will show you parameter a equals each of these indexes you know notice for each element there's like index 1 N index to and all that so you'll see parameter a equals 1 parameter a equals to but you can use those however you want but this may time point and maybe a 1 microsecond it 2 microseconds at 3 microseconds or 1 . 7 microseconds 1 . 8 microseconds so in general that that index using doesn't have to be an integer can be anything could be time could be a day of the week could be whatever you want to whatever index you label here and whatever index value you show here rapture will will label it that way but and then for each element that you create you can stick in a curve like this or in the dual or anything but we've created so far and rapture of molecule and all that so this sequence is a pretty powerful and I don't know if they support every possible combination of rapture objects but the basic things like curves in images and stuff you can do inside of sequences so if you look in a rundown XML that's what you'd see trash on end users have to use commands like like this kind of stuff is put commands the kind of generate that that stuff by 1 last example it's kind of neat I suppose you have matlab and there's a really great picture that you can generate out of Matlab Matlab can do all kinds of neat visualizations 3 surfaces and crazy looking plots of and here's a little bit about lab or Octave code for example I I set up of but now Bessel function and then I went ahead and and surface plot it was some shading so you can type that code in the Matlab or Octave and will generate a plot that looks like that and you might say who I want that plot in rapture and I actually like that plot better than the other 1 the rapture does at the I want that in rapture how I get that but you can take any image that you can program you can generate from any other program and you can always say that as an image in rapture now you will be able to interact with the plot you will be able to rotate the plot zoom in and all of that is just an image but anything that you can generate is an image you can put in your program if you want to as output so let me show you how
to do that here is my little main program and use my matlab or Octave code and generating a Bessel function and doing all those commands that I showed you just a 2nd ago to generate the surface plot right so this is just my straight up Matlab code I can also tell matlab to draw and I can also tell matlab to save the output into a file called output . png so all that stuff tells Matlab to query quietly in the background generated drawing and save result in a file called output . png now if I can get output that PNG into raptures undone and the way I do that is with my friend put file whenever we stop at file a couple of slides ago put file will take any file read the contents and stuff it in wherever you say to stuff so in this case we set our people put file in the output section look for an image called snapshot and set its current value to the contents of that file and by the way the 1 says compress the image in a 0 says overwrite don't pay so that'll take that output image loaded up compress it and put it in as the current value for that image so well that now I have an image and rapture I could use the same thing for the sequencing I showed you a minute ago I might have a sequence of images and I go through a loop but for each output image in the sequence I'd do put file take that image and put it into the sequence take that image and put into the sequence so you can build really complicated things like that and if your program is generated a bunch of images
on and these examples to a lot of example code I and I should mention that I when we do that right now if we go into rapture and you know we we've shown you the documentation for all this stuff when you're looking at the documentation you go into the gooey XML elements in trying to figure out how I do it you activity at least you know it's there now you can look at the documentation and see all this stuff in there and you can look at some of the examples and then what's described here in terms of how it works and I'll show you what it looks like and all that but there's also examples in the code for rapture he going to the code for rapture there's a examples directory and the examples directory has a zoo of examples and then you find this and they'll have to and there's even a menu entry to help you copy the examples so for any 1 of these things if you wanted to see like I I wanna see what an example of you direct to the looks like a something every 1 of these has like a tool that XML file and and then it has like a little program that generates a match and and all that so as you're doing more and more complicated things with rapture take a look at the zoo of examples you can try out running example and see what it does and then if it does something guarantee you say I wanna how they did that in going to the codon can look at it and figure out figure out how it works so there's a lot of different examples there in the zoo and there's the at various stuff that I showed you before all the different languages and so forth so a lot of different good examples there to to poke around with so if you have energy any energy left in the deck and this is the last thing that we can try to do today maybe it's the 1st thing we'll finish up tomorrow morning I what you can do is play around with this function in Matlab but if you get into active a Matlab in your workspace new type this command you'll be able to generate like a Bessel function and then the question is can you can make a program where you can prompt the user for the max order the max axis and the number of grid points which is you know these parameters here And points new max max max basically going to prompt the user for these values I want generate the Bessel function and I was fitted out to rapture as indirect to be in a field so in order to do this by the way I'm showing it here you have to do it as a field in Utrecht to so you look back through the notes and you'd be looking at kind of this
stuff right here figuring out how do you generate a you direct TV in the output section that looks like that and how were generate a field that looks like that and I wanna take the values from Matlab and kind of get them stuck in my XML like that so if you're
curious and you wanna mess around you could also try this route to you up if you want a bag it with the field and you director to be on you could also try this rap to where you're actually generating the image in Matlab and not just doing a put file on the image in Matlab to try it out and that's another way to do it to so if you wanna mess around a
little bit with somebody advanced visualization and get started with this example and we'll pick it up in the morning and I'll go through the solution OK so use a solution you got his lab assignment 1 K is is a little bit of popular culture encountered rapid into rapture interface like that
so but so 1st thing I can run the rapture builder
and I get a least it part of my interface going on the direction builder doesn't have some things like the you direct TV and all that but each field and stuff like that but at least I can get you know a number and an integer and a number and if you want to have an image on the output side you can get that far so you can use the builders do as much as you can and then save out the tool . xml let me open the tool directional not gonna say that open the 1 that I generated now again the below the loads as much as they can understand so again it's got my definition for new Macs x max another points and it's got the image there and all that so that all looks good I've got the tools that are active that all looks good that's a nice explanations injury to my parameters but you notice on the output side of the builders not showing the Utrecht or the field and and like going say this if I say this right now it'll state exactly what you see here will save anything else but what I did was I built my tool that XML as
much as I could and then I went in and added some stuff added some stuff so this is the stuff the builder added and then I went in and added some extra stuff individual . xml right here I had at the start that the builders of known about buying it so I find myself you directly the main grid also you can access it with a label and in value and Y. axis of the label value of the fact that you know points to but also those later in the program is like you said here would work but he he's said later in Section program for sure of once you know what the user wants to be on so that hierarchy buying accesses the Y axis is that the law and then I had this field here and the field and by the way she always have a label on
face and so the rapture can show on that but anyway i've got a field here that I want prejudicial Bessel function surface and I've got component will match any of the national source said well but also as an output that directly from the story that means with the university that's fine grained some people were errors that did not the dimensionality of your field and that happens when when it's not really there is no greater than matching all what dimensionality what you're trying fly so I can imagine that XML none of this stuff is ever going to change so I said all of this in the tool that XML and then in my program i k as it is in case of over points in S values that he was varied over all the values from all of those of you that wants to the most important thing here that I need add and I'm also going to get
in and got this image here that I'm going to show you that hard to bring in a unit of an analogy is her out of the image that comes later again in my program but at least I got the label there if if you ever
forget about the label like this if you create an initial you don't get a label won't show up to now so monitor units of of each of us believe that he is labels suffered rapture figures you know all of that so if you say it was a century of least utility and the lower will do the builder will do that when using the builder it'll at least give label alright so I've got that actual that x amount and now I I've got my active program and I can run my test script and apply test it to look like it did very much it basically ran these functions and it did this flying
thing and it stays out an output . png and then it
quits so did very spectacular but if I x low-dimensional this output . png you can see that for my test so what I wanna do now is take that test script and integrated into some kind of skeleton media-generated a skeleton under the builder for my main program so here's my main program coming from the builder with my 1st skeleton code and then I can stick my stick my code in year for my Matlab script so those are the 3 lines basically that I needed to generate 2 vectors for new next and then the Bessel function of z everything
else now just becomes a matter all that the computation is happening right here everything else now just figuring out how to get the values and put them back out into rapture on television
that part of the cell I want a stage in the output section I've got a thing called you direct it a told you before I need to update the x-axis no points in the y axis number points and I do that according to the the number of points and end points here that we've got if I tried endpoints in there then men have policy the that is functions long was a string doesn't want the integer or double or something like it was found that so there's there's a handy function here there's a juster or not disturb that I can use to take an integer number and convert it into a string so that when you're old enough to stir to take my number points value and converted into a strain called non and then use that string value there so I'm setting the x-axis number points on the y axis No points according to this variable and points to start the to history also on the grid I was that the x-axis axis and the y axis next year I did it more in line I set x-axis max to not disturb a x max and Y. axis maximum disturb you next but whole function in 1 uses of such numbers that interested and then finally I wanna say that all the values and disable the values I can't decided nodes of just to explain what I wanted to do I want to go in
the output section of my field and I wanted to set the component values and whenever I do that I'm supposed to set that to a big strain of a solid is that point by by point of head and hand but it is a it lot generate 1 giant in a string of values so I would generate 1 gigantic string with all the values there's a trick in Matlab the US tradeoffs function if you get a vector of values by vector of 100 gallons of ethanol and they all follow us on values so that is where on that generating each of its strip of the law and format string here says cent 12 g that means some kind of decision number that's about 12 teachers why so low-precision number followed by a new newline if you guys if you had if you looked at around was he had the look and feel dissection is see number and a new line a number a number of over there there were down like that of different right back in his here we put that z well he left in the new 1 and we set in the values it's 25 long and so you you see 5 online of everywhere that point by 100 while vector because when I've got matrix up here this gives me a matrix of 50 by 50 and I wanted a vector with 20 500 points so this is what that function does the reshape functions case my back to my patients C and region it into a vector that is any point size and 1 also and 1 row of tall but turns into a lack of qualified what's this 1 by 1 long and 1 all of our peoples and 1 last little when you you all this and you look carefully at the results you'll you might notice when everything looks like a little small excesses by US is by herself and so in order to fix that problem matlab versus rapture I what I really need to do is use the the trace of the transfer of the money into it so that it matches the pressure excessive data and the birds of a point on there and what was happening in the order so all of which had a slightly higher values you have this you know it was followed by what's in right away so far right so that's the code and if you do that if you set this up until that XML and then you and then what this does is it tells you that is energy that then you get a nice interactive plot but there's 1 other thing here if we actually the other solution the other solution was to have matlab that generate the plot and so this is the coda we have noticed that you that while using wrong and then say out as the energy loss of about half of them so of that is a long list of our also so all that generated by our house was that a year he I just need to take that image and stuff it in the output and I do that with this
line this line are users were by his side with violence that was trained with filing is similar in mind that our values also said current uncertainty that's training in error as part asterism filing loads of file based on his file was size so it can open up with us in g that and as part of the review and the way which is binary and all that so I said a flag for compression social compressed Eugen and then 0 again always means all the right the value so this is the way I take the final output . png and stuff it in as the value of the current image so I've got outputs now and then like any other program I finish up with lived resulted in so if I run this now it asks me for some values and i can simulate any gives me a
nice plot and I can also look at the image that's 1 generated by Matlab the differences that this 1 I
can actually rotate and interact with this but is over here to zoom in I can move around on the plot or like that but there's also other things I can do and we reset the view I can fiddle with the contour lines turn them on and off and I can make a wire frame or not and I turn the great off so there's all kinds of weird things that I can do with this interactive version of the plot and I can do any of that with the image that I
got from that because there are no learning more so the only thing I can do with the image format that is I can zoom in on the image and when I assume and I can see the X is a little bit better so I can zoom in and zoom out and then but that's it in the image if I try to drag on it it doesn't rotate doesn't change so this 1 slightly better because it's a
little more interactive and if I like that picture I can always download it to my desktop and now
I can copy and paste and put it in my documents or whatever so that that's can maybe
I wanna zoom in on this sheet and I'm groups trying to write a 3rd maybe I'm writing a paper that talks about this particular P peak and then I can download that and grab that image and put it in my own work but that's what's nice little nicer about it the 2nd fiddle with the image that alright 1
other thing just to mention required if we filled with the
values so says that 2 5 and 5 and run it again so now might
migrate back on it but everything sort of back to the way it was but not wireframe alright so some people looked at that and thought how that looks like a really weird right why is this so weird my original plot look like that and money plot looks like that why is this so weird actually it's doing the right thing because you original loss was always 0 1 and 0 10 new ESS those original what holiday whole space whereas the plot that I just did it goes from 0 5 and he will it actually is doing the right it's going from 0 to 5 in 1 axis and from 0 to 5 on the other axis so this new plot is much smaller than the original plot and that's what this is showing you rapture and you were when you have actually results are actually also some of the axis so you hear and that's useful here because otherwise you might not realize what you're looking back and forth between cells you're actually zooming in yes it is that you didn't do this would be 1 of you might have thought at 1st it was OK but what will do later in this section of a much smaller states emerging function so if you do not rational he said had this is when you've plotted so you narratives when you're looking at


 1023 ms - page object


AV-Portal 3.11.0 (be3ed8ed057d0e90118571ff94e9ca84ad5a2265)