이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.
What is the best practice for passing data to use for visualization?
- input_params.m defines parameters for a specific problem, this file in turn calls ode_sim.m with these parameters as a struct.
- ode_sim.m finds output variables like y_out, u_out, t_out etc. from an ode simulation, this file then calls kinematics.m and visualize.m
- kinematics.m constructs the other relevant output variables like the material points p_mat from y_out, u_out etc. as arguments
- visualize.m then takes a bunch of arguments y_out, u_out, p_mat to visualize them in plots and animations
- Save the data in a .mat file and load the variables from that in visualize.m
- Save the data in the workspace of input_params.m and run visualize.m there (this would work only if ode_sim.m was run earlier this session)