MSPhysics 1.0.3 (16 October 2017)
-
Hi Anton
Please, please could you help me.
Firstly thanks for making it possible for us all to have this plugin. I really appreciate your work.
I have one little problem which I am sure is easily remedied. In my models the groups or components are falling through each (like in the following post) a lot of the time.
http://sketchucation.com/forums/viewtopic.php?f=61%26amp;t=64189
I need to change a setting somewhere I guess but I have no idea which. I hope I haven't missed something obvious, I have tried looking for the solution online without success and I have tried systematically changing setting also without success.
Many thanks once again.
-
Hi Anton
Is there a way I can tidy up the collision wireframe for Compound from CD shapes in the UI. Both the rack and the pinion I have drawn are not getting a very good collision detection wireframe so the gears are jumping out of the rack.
I have checked the geometry in the models and they appear to be sound so I am assuming this is related to the way the wireframe is generated/calculated.
Thanks again for this great plug in.
-
Hi, DonDeEs,
The Collision from CD shape is not reliable. Its ability to calculate proper collision is limited. What you can do is manually divide sub-geometry of the gear into convex-hull groups. Then assign Compound shape to the top level group. So, for the gear, every tooth should have its own group. The top level group, of Compound shape, should contain all the teeth.
For the chains, using collision as the constraint for keeping the objects from falling apart is not a viable approach. Yes, increasing the density of all chain links can get all pieces to hold tight, but they will break once a certain amout of force is applied. What would be a better solution is having every peace of chain interconnected by a ball-and-socket joint. There is a very efficient way to do it. Here, check out this example:
artificial_chains.skp
I might create a YouTube tutorial for it later.Anton
-
Hi Anton
Many thanks for your reply. The solution makes sense. It will make modelling gears a little more complicated but that is ok. I guess I could also let the gears run as cylinders on a box collision shape for the rack (so they roll effectively) and null the gear teeth on both.
I don't know if it helps you to know that when Collision Wireframe is enabled on the simulation it shows fine but if you use orbit the wireframes are lost. It means you effectively have to stop the simulation, orbit to where you want to see and restart in order to get the view you want with wireframe.
It is a minor problem for me but maybe it is a bug that you are not aware of and can fix.
Thanks again for your help.
-
Hi Anton just reporting this little bug im getting with your ams windowsettingsv4.2.0
plugin and MSphysics keeps jumping out of fullscreen.
im using MSPhysics_0.9.8/Win 8.1/Sketchup 2016 and ae-toolbar editor plugin
Before
After
any info would help
Tez -
Hi Anton
That makes sense of the geared joints option. I had not really worked out what they were about but this is absolutely the solution I needed so many thanks.
-
Thanks for reporting this, SketchyPhysicsNut. I came across it but forgot about it the next moment. Now I got it logged.
DonDeEs, for the geared effect, you can try connecting joints to joints. They are called geared joints. For your rack and pinion gear, you can connect slider to the rack group and hinge to the pinion group. Then connect slider with the hinge. After that, using UI you can adjust distance-to-angle ratio. Geared joints allows user to utilize gears without having any collision at all. I even tried making a differential gear using the geared joints. It worked very well. Once I get some free time, I will definitely make a tutorial about it. At the moment, here is an example of geared joints:
MSPhysics Geared JointsEdit: At the moment geared joints yield improper behavior under certain cases, but I'm intending to address the issue in the next release.
Also, I'm aware of the collision wireframe not drawing when the orbit tool is activated. The collision wireframe stops being drawn whenever the simulation is suspended. However, it starts drawing again whenever it is resumed. That's how SketchUp API works and I don't have much control over it. So, while having an orbit tool, if you right click and select Exit the simulation should resume the drawing.
-
Hi Anton
I hope it is OK to report a possible bug with MSPhysics 0.9.8.
I am using it with Sketchup 2017 on a Surface Pro running Windows 10.
It seems the UI opens in a different resolution and does not therefore display in full. The maximise button is disabled so I wondered if there is anything that I can do to fix this.
I have attached a screen shot for you if it helps.
-
I just checked and this only seems to be a problem with S2017. Seems to work fine in 2016.
-
Thank you for reporting this, DonDeEs. Someone reported something similar and I'm in the process of fixing it. I might have to send you s private message to verify the fix.
-
Sure thing. Feel free to do so.
-
Hi Anton
Congrats on your great work resurecting old SP for a new version. I played with SP some years ago and amazed myself by getting a caterpillar track chain to workMay I ask if it is possible, in your version, to assign real physical values to objects, eg mass in kg, spring rate m/kg, damping kg/m^2 and so on
and perhaps equivalent elements for rotating masses
Its all in aid of helping my student understand the dynamic behaviour of physical systems with different input and load conditions open loop and closed loop
If this could be done, it would be of fantastic benefit for Uni ugrads (yes there are professional - expensive suites to do this). Something tailored to fit with the unbeatable SU would be so good
It wasn't available in the original SP, only cruded dimensionless tweaks
Cheers
Robin
ps apologies if this has already been answered pls link me
-
Hi, robint,
Just to clarify a thing, MSPhysics is not a new version of SketchyPhysics; MSPhysics is a plugin written completely from scratch, integrating the latest NewtonDynamics Physics engine by Julio Jerez. Yes, it does have a similar functionality to SketchyPhysics, but that was done because I didn't want to reinvent all the ideas Chris Phillips put into writing SketchyPhysics and so that SketchyPhysics users wouldn't have hard time transitioning to MSPhysics.
In MSPhysics, the mass (kg), force (N), torque (Nm), angular velocity (rad/s), and linear velocity (m/s) - are controled with the standard SI units. These values are proper, even with the world scale set to some value other than one, as behind the scenes they are scaled to maintain themselves in SI units. The parameters for joints, such as power, accel, damp, and friction, however, are controlleded with unknown units. While writing the custom joints, I didn't place close attension to the units, but I think they can be converted to the units you described in your post. Some testing needs to be done to figure out the ratios.
By default the mass is calculated by taking the volume of an object, in m^3, and multiplying it by the density, in kg/m^3, which is by default 700 kg/m^3, the density of wood.
To assign a particular mass to a body, in killograms, you can do it with the UI dialog:
- Select the desired body.
- Open the MSPhysics UI.
- Activate the Body Properties tab.
- Select weight control option and switch it to mass.
- Write the desired mass into the mass input box.
The static and kinetic friciton coeffiences, which can also be assigned through the dialog, are not the actual coefficients. The actual coefficient is an average coeffiecent between the two touching bodies. For instance, if the floor has a static coefficient of 0.9 and kinetic of 0.7, and the touching body has a static coefficient of 0.4 and kinetic of 0.3, the actual static coefficient for the contact, would be (0.9+0.4)/2 and the actual kinetic coefficient would be (0.7+0.3)/2.
The same concept applies to elasticity and softness. I'm no expert what the softness does, as I didn't write the physics engine, doing most of the calculations for my wrapper, but I think it controls how much energy is transfered durding collision, i.e an aditional parameter for elasticity.
To control other physical properties, such as velocity, you need to assign a Ruby script to a group. This can be done by selecting a desired group, activating the Script tab in the MSPhysics UI, and writting some code in the editor. Here's a script for applying a particular velocity to an object whenever simulation starts:
onStart { this.set_velocity(0,1,2) # x, y, z - the velocity vector }
The velocity can also be applied every time the world is updated:
onUpdate { this.set_velocity(4,5,6) # x, y, z - the velocity vector }
And the velocity can also be recorded:
onUpdate { # Get current velocity cv = this.get_velocity # Output it in the note note = sprintf("Velocity; (%.3f, %.3f, %.3f)", cv.x, cv.y, cv.z) simulation.display_note(note) }
You may also apply force, torque, omega, and do other things with scripting. Check out this scripting documentation link:
http://www.rubydoc.info/github/AntonSynytsia/MSPhysics/indexHere is the exact link for all the functions available for a body:
http://www.rubydoc.info/github/AntonSynytsia/MSPhysics/MSPhysics/BodyRegards,
Anton -
Thank you so much Anton, thats given me some homework!
BTW I didn't wish to imply you were overwriting the previous SP. MSP is of course entirely yours started from scratch - brilliant stuff
I'll be glad to pass any useful models I can generate back to you to pass around to other interested parties and perhaps help generate other instructional models
Cheers
Robin
-
Hi, Robin,
I'm glad I could help.
Best regards,
Anton -
Dear Anton,
I just downloaded the plugin to make a simple cinematic / collision check on a folding workbench model, that is basically a deformable parallelogram.
Although I got the basic principle and manage to make singles hinges move as expected, any component is stuck as soon as it's linked to two hinges.There's also a message reading "Requires MSPhysics 0.9.8+" in a corner of the screen, should I understand that it won't work unless I install something else ?
Thanks
Armand -
Hi, Armand,
A hinge with no parent groups will act stationary. In order for the hinge to move, it must have a parent group. What I think is going on in your model is that the hinges are top level groups. If you want a hinge to link two groups together, and still move, simply create a hinge joint within one of the groups andd then, using the joint connection tool, connect it to the other group. That way the hinge joint will have a parent body, which will allow it to move.
Check out this mini clip:
Movable Joints ExampleThe message is there so that people using your model would know that they need MSPhysics in order to run it.
Regards,
Anton -
I think I have some issue with hinge when I link it to a parent:
Mac OSX 10.8.5, SU2015.
-
Hi, gilles,
To fix that, you have to select the joint, open MSPhysics UI, and check the "connected collide" option.
Regards,
Anton -
@anton_s said:
Hi, Robin,
I'm glad I could help.
Best regards,
AntonI made a simple mass/spring damper system as per model, but I get some odd results not like the damped sinusoid
Am I on the right track or have I made some basic errors
Also the block doesn't sit still on the plane but wanders off
I am also having difficulty tying in the UI with real values of spring rate N/m and damping c*velocity Ns/m
Any advice, most appreciated
Cheers
RobinBTW I looked at the Ruby docs but couldnt tie up real units to the constants
Advertisement