PMKS+ (Planar Mechanism Kinematic Simulator Plus) is an educational web-based tool designed for comprehensive 2D linkage analysis. It offers an interactive platform for users to rapidly create, edit, and analyze planar linkages. Along with performing kinematic and force analysis, PMKS+ allows for easy sharing of linkages with peers or teaching staff.
Built with a strong emphasis on the four core principles of education, flexibility, collaboration, and accessibility, PMKS+ aims to provide a user-friendly experience that aids learning and promotes understanding of complex concepts in a simplified manner.
Interactive Linkage Creation & Editing: Easily create and modify planar linkages with a user-friendly interface.
A Matlab Script (SixBarVerification.m) was used to verify the Analysis and the v,p,a obtained from this Mechanism . The values were compared and a test script was created to continue verifying similar Mechanisims.
For development, we recommend using WebStorm, a powerful IDE ideal for JavaScript development. It is free for students and faculty members with a .edu email. You can download it here.
Download & Install WebStorm: Visit the WebStorm site and download the software. Remember to register with your .edu email to get it for free.
Clone the Repository: Using WebStorm, clone the PMKS+ repository to your local machine.
Install Node JS: https://nodejs.org/en/download
Install Dependencies: The necessary dependencies should automatically install when the repository is cloned. If any dependencies are missing, you can run npm install
to add them.
Set Up Run Configurations: Create two run configurations in WebStorm:
http://localhost:4200
. This allows you to run a locally hosted test site on port 4200 and use breakpoints and the debugger to identify errors.Angular DevTools: We recommend using the Angular DevTools extension for your browser (available for both Chrome and Firefox). This tool provides additional functionality for debugging and optimizing your Angular applications.
With these steps, you should have a fully functional development environment for PMKS+. Happy coding!
We encourage high code quality and strive for clean, readable, and maintainable code. Here are some general practices we follow:
Code Purposefully: Code should be written in a simple, obvious style with descriptive variable and function names. Avoid commenting code to explain how it works; instead, code should be written in a way that is inherently understandable. Use comments to explain why—to describe high-level behavior and its importance.
Keep Code Short: Try to keep classes under 200 lines of code if possible and functions short. This prevents the emergence of "god" classes that can make the codebase difficult to maintain.
Good OOP Practices: Follow principles like SOLID, DRY, and prefer composition over inheritance. If complex relationships seem necessary, reach out first so we can discuss the best approach.
Follow Programming Conventions:
currency-converter.pipe.ts1
Service
. For example: HeroService1
app-hero-list
Component
. For example: HeroListComponent
Directive
. For example: HighlightDirective
Module
. For example: AppModule2
PascalCase
and end with Pipe
. For example: CurrencyConverterPipe2
While the codebase may not always perfectly adhere to these conventions, the aim is to continually improve the codebase to meet these standards.
We follow an agile scrum-style workflow, using an issue tracker (Kanban board) in our GitHub organization here.
The process is as follows:
Please note, the main branch has a CI/CD workflow setup that will update the production website, so nothing should be pushed directly to the main branch!
The commits to the main branch will get reflected on app.pmksplus.com
All other branches will get published to https://[BRANCHNAME]--pmks.netlify.app (For example https://staging--pmks.netlify.app)
Landing Page: https://pmksplus.com
This project was generated with Angular CLI version 13.2.5.
Run ng serve
for a dev server. Navigate to http://localhost:4200/
. The app will automatically reload if you change any of the source files.
Run ng generate component component-name
to generate a new component. You can also use ng generate directive|pipe|service|class|guard|interface|enum|module
.
Run ng build
to build the project. The build artifacts will be stored in the dist/
directory.
To get more help on the Angular CLI use ng help
or go check out the Angular CLI Overview and Command Reference page.
PMKS+ features an intuitive interface that allows you to create, edit, and analyze 2D linkages efficiently.
The PMKS+ interface consists of a full-screen grid with a toolbar at the top and an animation bar at the bottom.
Toolbar: The toolbar provides quick access to common tasks. It includes a PMKS+ logo, buttons for creating a new project, loading a project, accessing the Linkage Library, downloading the current project, and generating a shareable URL for the current project.
Animation Bar: The animation bar allows users to control the simulation of the linkage animation. It consists of buttons for controlling the playback speed, time control buttons, and buttons for controlling the grid visibility.
Side Panels: On the left, there are three tabs for editing, analyzing, and synthesizing linkages. On the right, there are buttons that open panels for settings, help, and displaying equations.
Synthesis: Use the synthesis tab to automatically generate a linkage based on a desired position for one of the links.
Edit: When the edit tab is open, you can modify the properties of the selected object (highlighted in amber color).
Analysis: The analysis panel allows you to view kinematics and force analysis graphs for the selected object.
Settings: The settings panel enables you to modify overall mechanism settings, such as units, input speed, enabling gravity, as well as visual settings like mechanism size and grid line visibility.
Animation Control: Use the animation bar to control the playback of the linkage simulation. You can set the playback speed, play or pause the animation, reset the animation to T=0, and seek through the simulation using the scrubber.
File Management: Use the toolbar buttons to create a new project, load a project, access the Linkage Library, download the current project, and generate a shareable URL for the current project.
Remember, only one tab can be open at a time for each group (left and right), and the linkage can only be modified when the animation is paused and reset to T=0.
PMKS+ is licensed under the MIT License, a popular, permissive open-source license. The full license text is included in the LICENSE file in this repository.
For any queries, you can reach out to the development team at gr-pmksplus@wpi.edu.
PMKS+ is based on PMKS, developed by Prof. Matthew I. Campbell, Professor, Mechanical Engineering, Oregon State University.