Re: Multibody Vehicle Dynamic Simulation

Mark Alexander Mikofski <[email protected]>
Newsgroups gmane.comp.python.scientific.user
Message-ID <CAEqRcW3A_SGpkbw4uipXjZ1W0A3tdqKCZHdNUOvn_P1NTf-JAQ@mail.gmail.com>
 Hi and thanks for your interest in SciPy and Python. My responses
corresponded to your number questions:


   1. In my humble opinion Python with NumPy (http://www.numpy.org/) is
   especially well suited to your problem (of the multibody vehicle dynamic
   simulation), although other tools would also serve you well:
   - MATLAB (by the Mathworks) although expensive, and costly for
      additional toolboxes is sometimes sold at a reduced price, or
offered free,
      to colleges, so you should check if this is already available. It has a
      just in time compiler, extensive documentation, and online support
      - Python is FREE, almost all of the useful additional packages are
      also FREE (such as NumPy, SciPy, Numba, Cython), it also has a
JIT compiler
      (Numba), although most documentation is extensive, it isn't
consistent for
      every package since there are different developers usually volunteering,
      however online support for Python and Python packages (such as
this forum)
      is in my opinion just as good or better than MATLAB. Typically you
      will find most answers either on StackOverflow, in a user forum or
      IRC/Slack channel, or on GitHub, however it is important to
remember to be
      patient and respectful of others time, since they are not paid to respond
      to your questions or issues. You can also pay for online Python support
      from Anaconda (https://www.anaconda.com/support/) and Enthought (
      https://www.enthought.com/)
      - I think you will have a hard time with Octave or SciLab, not sure
      about the rest.
      - Julia (https://julialang.org/) is a new scientific computing
      language that you might consider, although IMHO, Python will be an easier
      path b/c it is more mature, more widely used, more support, and more
      packages.
   2.  I think you should use Spyder for developing modules and packages
   that form a reusable project. And then you can write scripts and reports
   with graphics, text, and equations in Jupyter notebooks so you can share
   them with others
   - For example: you could develop a package in Spyder called racetrack that
      contains classes like car, track, and all of your physics like forces
      with centrifugal, gravity, and friction. Then in a Jupyter notebook
      you could import racetrack and use it to simulate a race car and optimize
      its speed and steering to minimize its time around the track. You can
      demonstrate the equations and display plots and images in the notebook,
      export it as HTML or pdf and share it with others.
      - Make sure you keep everything in a Git repository, then mirror your
      repo online. I personally like GitHub, but Bitbucket and GitLab are also
      fine.
   3. Depends on what type of visualization. For plots and charts,
   matplotlib and seaborn are good, Bokeh is great for interactive plots,
   altair and holoview and good for descriptive (vs. imperative) datavis, this
   is a new concept where you let the software decide the best way to
   represent your data, rather than make commands about ever property of the
   plot.
      - for 3-d car simulations, I think you would have to try something
      like sketchup (https://www.sketchup.com/) which uses Ruby I think
   4. It appears to me that PyDy actually uses SymPy already for algebraic
   manipulation, so in using PyDy you would also be using SymPy.
      - looking at the PyDy site it hasn't been developed in over 2 years,
      that doesn't mean that it isn't any good, but it may mean that
you may have
      difficulty getting support.
      - perhaps you can consider this as an opportunity to revive PyDy and
      make some contributions to improve it or bring it up to date?
      - fork PyDy on GitHub https://github.com/pydy, create a conda
      environment without PyDy installed, and do a developer/editable install
      (pip install -e or python setup.py develop see https://pip.pypa.io/en/
      stable/reference/pip_install/ or http://setuptools.
      readthedocs.io/en/latest/setuptools.html#development-mode
      <http://setuptools.readthedocs.io/en/latest/setuptools.html#development-mode>),
      you can install the official version in a fresh conda environment either
      from PyPI (https://pypi.org/project/pydy/) using pip or from
      conda-forge (https://conda-forge.org/feedstocks/) using conda -c
      conda-forge ...
      - If you were to choose SymPy, which is only for algebraic
      manipulation, then you would have to develop all of the dynamic equations
      from scratch, which has already been done in PyDy, so you might be
      duplicating work already done, and your efforts might be better used
      improving what already exists?
   5. 5-6 I think you're going to have to figure these out on your own,
   maybe someone else will have some opinions. Try Stack Exchange? I know that
   some racing teams are already using Python to analyze their cars, so if you
   keep searching I bet you will come across them. Maybe go to some car races
   and ask in the pit?

Good luck and happy coding!


On Fri, May 25, 2018 at 1:27 AM, <[email protected]> wrote:

> Dear Scipy-Users,
>
>
>
> I am a student from Germany and I'm new to Scipy.
>
> It would be nice if you could help me out with your recommendations for
> the following project:
>
>
>
> I am planing to do a vehicle dynamic simulation with a multibody system
> for a race car. The suspension of the car is very simple and the whole
> car can be simplified.
>
>
>
> Goal:
>
> The vehicle should automatically follow a given path/trajectory (which is
> the racing line of a racing track) at the maximum possible
> speed/acceleration.
>
> I want to optimize some suspension parameters to get the minimum lap time
> of the given path/trajectory. This is called a lap time simulation.
>
> It should be possible to visualize the car in a (simple) 3D Model.
>
>
>
> The conditions for this project:
>
> I have time of 5 months for this project. I am a bachelor student of
> automotive engineering. I am working full time on this project. I am
> willing to do programming. I have some basic experiences in python and i
> have installed the anaconda distribution on a Linux distribution. I have
> basic knowledge of kinematics/dynamics.
>
>
>
> Some doubts and questions that i have:
>
> 1. In general: is it possible and advisable to do this in python? If not,
> which free software would you recommend? MBDyn? GNU Octave? SciLab?
> OpenModellica? MBSymba?
>
> 2. Which python environment (for Linux) would you recommend for
> programming? Spyder? Jupyter Notebook?
>
> 3. Which software would you recommend for visualization?
>
> 4. Which package should I use for the multibody approach? PyDy? SymPy?
>
> 5. How should I model the tires? With OpenTyre?
>
> 6. Which book is recommendable for my project? "The Multibody Systems
> Approach to Vehicle Dynamics" by Mike Blundell? Do you know any other
> source of information which could be helpful for me?
>
> 7. Do you think I can handle this project in the given time?
>
>
>
> Thanks a lot!
>
> Greetings
>
>
>
> _______________________________________________
> SciPy-User mailing list
> [email protected]
> https://mail.python.org/mailman/listinfo/scipy-user
>
>


-- 
Mark Mikofski, PhD (2005)
*Fiat Lux*

_______________________________________________
SciPy-User mailing list
[email protected]
https://mail.python.org/mailman/listinfo/scipy-user
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.