I'm trying to model a projectile motion, considering every detail such as projectile aerodynamics, effects of wind, air temperature etc.

What is a good software to model it in with good graphics? I like how COMSOL multiphysics works and it's parameter sweep. It could be used to find the optimum angle for longest range and many other things but I don't know if I can model a projectile motion in it.

  • 1
    $\begingroup$ "the best model" is the simplest one that lets you solve your problem. But if you are already sure that you should use COMSOL, go ahead. $\endgroup$ – nicoguaro Mar 19 '18 at 22:09
  • $\begingroup$ @nicoguaro Is there any resource to learn how to solve similar mechanics problems with COMSOL? I don't think any of COMSOL application library examples fit this one. $\endgroup$ – Alireza Mar 19 '18 at 22:15
  • $\begingroup$ I suppose that you have support, since you already have the software. $\endgroup$ – nicoguaro Mar 19 '18 at 22:17
  • 1
    $\begingroup$ @Alireza you seem set on using COMSOL but what's is the advantage if you can't find resources or example codes which can help you along for your problem? Instead googling "python projectile motion" returns a number of useful resources. Why reinvent the wheel so to say? $\endgroup$ – nluigi Mar 19 '18 at 22:29
  • 2
    $\begingroup$ @Alireza what's is the context of your simulation? are you shooting rockets at high velocity into orbit or are you simply shooting a cannonball at a target? depending on the situation some of the effects (e.g. temperature increase due to viscous dissipation) you mention might be negligible and not worth the trouble of calculating. Making a model overly complicated is one thing, finding the right tool for the job is another $\endgroup$ – nluigi Mar 20 '18 at 6:32

You need to know which equations you need to solve inc initial conditions.

IMO, a disadvantage of click&result software is that it's not transparent to what you are actually solving.

Why don't you try solving the equations using a ODE solver in Python (using SciPy) and visualize using Matplotlib? At least you will have exact control over what you are solving. It's trivial to do a parameter sweep using a couple of loops in Python.

| cite | improve this answer | |
  • $\begingroup$ I've already done solving the equations in C++ with ODE solving methods but a) I can't simulate things like aerodynamics of the projectile (like its shape, sphere, cube etc) and I can't visualize the results as good as a professional software like comsol can. $\endgroup$ – Alireza Mar 19 '18 at 9:31
  • $\begingroup$ @Alireza what do you consider "good" visualization? if you already have a C++ implementation why can't you import the results into a visualization library? or use matplotlib-cpp $\endgroup$ – nluigi Mar 19 '18 at 10:53
  • 2
    $\begingroup$ @Alireza, you can take into account the shape of your projectile using different drag coefficients. $\endgroup$ – nicoguaro Mar 19 '18 at 16:32
  • $\begingroup$ @nicoguaro But again, there would be many options such as projectile temperature raise available if we could model it with something like COMSOL. $\endgroup$ – Alireza Mar 19 '18 at 22:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.