How to Take ABSOLUTE CONTROL of ABAQUS inside MATLAB

It is possible to control ABAQUS directly inside the MATLAB command line. In this video, I show you how to do so running such actions as: (1) submit jobs (b) visualize simulation results (c) run python scripts (d) post-process results and (5) run multiple batch actions. #cmvideos #abaqustipsandtrics #abaqustutorial #matlab #abaqus #rve #periodicboundaryconditions
Time stamps
--------------------------------------
00:00 - Intro
01:24 - Case 1: Run ABAQUS model inside MATLAB
03:11 - Case 2: Visualize simulation contour plots/results
04:02 - Case 3: Call an ABAQUS Python script inside MATLAB
05:05 - Case 4: Run Python Script without loading ABAQUS CAE
08:49 - Case 5: Run multiple batch processor activities
11:12 - Outro
--------------------------------------
📥* DOWNLOAD LINK TO SOFTWARE
1. PBCGen2D: A software for applying periodic boundary condition
Download softwaree: cmvideos.ck.page/products/pbc...
2. PBCGenlite: A lite version of software for applying periodic boundary condition
Download software: cmvideos.ck.page/products/pbc...
3. MontCarlGen2D: A software for creating random inclusions in 2D RVEs
Download software here: cmvideos.ck.page/products/mon...
-----------------------------------
🕮 CM VIDEOS E-BOOK SERIES
I am writing a series of E-books to complement the contents on this channel. If you want to join my writing journey and get weekly newsletter about this, please subscribe via this link: cmvig.cmvideos.org/ebook-news...
-----------------------------------
💁‍♂️ TIP JAR: If you want to support the channel, you can leave a tip here. I am saving for new camera and lighting, so all tips will be reinvested into this. Thanks a lot - cmvideos.ck.page/products/tha...
CMVIDEOS WEBSITE
--------------------------------------
*Website under development at: www.cmvideos.org
👨‍👩‍👦 CM Video Insider
--------------------------------------
Become a CM Video Insider (100% free) to access modelling resources, advanced workshops, bonus trainings, behind the scene contents and regular CM Video updates: cmvig.cmvideos.org/
✔️*Link to Michael Okereke's Finite Element Applications textbook
--------------------------------------
Okereke, M. and Keates, S., 2018. Finite element applications. Cham: Springer International Publishing AG. amzn.to/3Bv54Di
---------------------------------------
My KZread Accessories
• Rode NT USB Mini Studio Micro USB - amzn.to/3SXha0y
• LOGITUBO Full HD 1080P Webcam - amzn.to/3MoqHvf
• Microsoft Surface Book 2 - amzn.to/3CwlT2a
• Microsoft Arc Bluetooth Mouse - Black - amzn.to/3EwPbAu
• Microsoft Surface Pen - amzn.to/3CkYsc8
• Iiyama LCD Monitor - amzn.to/3CRfpw7
• External Hard Drive - USB 3.0, Black - amzn.to/3RX5xWf
• Webcam Stand - amzn.to/3SZgwQ0
• Samsung Galaxy S21 Smartphone - amzn.to/3iL4Hgl
• Jabra Evolve 40 MS Stereo Headset - amzn.to/3EC2krP
• Green Screen 5x6.5ft - amzn.to/3RXldZw
• Scripting book: Hardcover Notebook - Black - amzn.to/3TbvDFG
Other Accessories
------------------------------------------
Business Projector - amzn.to/3ThN8o4
Please note the above are affiliate links and I do get commissions when you make purchases from those links.
🔔 Subscribe
--------------------------------------
If this is the kind of content you like, please do subscribe to this channel and click the notification button so when contents like this are made, you will be the first to see it. If you also have ideas of videos you want me to make, do suggest those in the comment section and I will consider them.

Пікірлер: 12

  • @Ein4alle
    @Ein4alle5 ай бұрын

    Thanks for sharing, I'm not so experienced in Abaqus but wonder if there is away to automate Abqus to generate and excute a multiple model and analyses. I intend to build a multi model to calculate the buckling load for steel beam which varies both in length and stiffness of the support i.e boundry conditions ?

  • @MichaelOkereke

    @MichaelOkereke

    5 ай бұрын

    I think this is true. You have to create a Python code that does this and then simply automate it for variables you are interested in. I think you can do this only through a script.

  • @azedinerebouh3651
    @azedinerebouh365111 ай бұрын

    @MichaelOkereke Now I have finished my simulation in Abaqus . Now I want a script MATLAB that allows me to control and change young's modulus of my material , and through this i will extract many graphs of force for comparison

  • @MichaelOkereke

    @MichaelOkereke

    11 ай бұрын

    Hello, it sounds like this is an extra script that you might have to write in MATLAB to do as requested. Good luck with it.

  • @eslingenastugart3581
    @eslingenastugart3581 Жыл бұрын

    That's very useful video for the beginner like me! Would you have a plan to make another useful videos about subroutine and UMAT in ABAQUS, or how to read python scripts to be embedded in ABAQUS?

  • @MichaelOkereke

    @MichaelOkereke

    Жыл бұрын

    Hello @eslingena stugart, thank you for the kind comments. I am happy you found the video useful. With respect to support for UMATs in ABAQUS, that is not something I am doing right now. I intend in future to start working on a series of UMAT-dedicated videos. In the mean time, you may like to consider Dr Ronald Wagner's KZread channel where he has a lot of lovely resources on UMATS here: kzread.info/dash/bejne/d6eB2LudYpm2gtY.html

  • @azedinerebouh3651
    @azedinerebouh365110 ай бұрын

    Hello sir I want to ask you simple question.. I finished my simulation in abaqus of tensile test now i put a script in python to allow me to change value of young's modulus 10 times si i've now 10 inp and odb files so all what I want is how can I call abaqus to read this odb files automatically to exctract the graph of stress strain or if there is a simple way to do this

  • @MichaelOkereke

    @MichaelOkereke

    10 ай бұрын

    It is possible but you will have to develop the python script for doing that especially the post-processing of the ODB files. I do not have any video to this effect on my channel but maybe search around and seeif there is anyone who have such a video to help you. Good luck.

  • @supernova-4420
    @supernova-442011 ай бұрын

    How do we set up the abaqus environment to allow matlab to use it?

  • @MichaelOkereke

    @MichaelOkereke

    11 ай бұрын

    Hello, this is a good question. I will suggest you search out for an answer in ChatGPT. Here is the outcome that I got when I asked it. It looks right, I have not actually tested it out but it does sound right: Integrating Abaqus with MATLAB can be beneficial for performing coupled analyses or leveraging MATLAB's powerful scripting capabilities alongside Abaqus simulations. To set up the Abaqus environment to allow MATLAB to use it, you'll need to follow these general steps: Install Abaqus and MATLAB: Make sure you have both Abaqus and MATLAB installed on your system. It's important that both software packages are correctly installed and working independently before attempting integration. Path Configuration: MATLAB needs to know the path to the Abaqus executable and libraries. This is typically achieved through the MATLAB environment's PATH and LD_LIBRARY_PATH (on Linux) or PATH (on Windows) environment variables. On Windows: Go to "Control Panel" > "System and Security" > "System" > "Advanced system settings" > "Environment Variables". Under "System variables", find "Path" and click "Edit". Add the paths to the Abaqus executable and libraries directories to the list. On Linux: Open a terminal and use the export command to set the LD_LIBRARY_PATH variable to include the Abaqus libraries' path. You can also add this export command to your shell startup files (e.g., .bashrc, .bash_profile, etc.) to make it permanent. Interface Files: Abaqus provides interface files (scripts) that allow MATLAB to communicate with Abaqus and control simulations. These files are located in the Abaqus installation directory. You might find them in a folder named "tools/Scripting". Look for files like abaqus_v6.env, abaqus_v6.bat (Windows), or abaqus_v6.sh (Linux). These files set up the environment for Abaqus scripting. Modify abaqus_v6.env: Edit this file and add lines to specify the Abaqus installation paths and any other required environment variables. Test the Integration: After setting up the environment variables and configuring the interface files, you should test the integration. Launch MATLAB and use its scripting capabilities to interact with Abaqus. For instance, you can use MATLAB to call Abaqus scripts, execute simulations, and retrieve results. MATLAB's system or dos commands can be used to call Abaqus executables and pass simulation commands. You can also use the ! symbol in MATLAB to execute command-line instructions. Here's a basic example of MATLAB code to execute an Abaqus simulation: matlab code abaqusCmd = 'abaqus job=example_input.inp'; system(abaqusCmd); MATLAB Abaqus Toolbox: Another option is to use the MATLAB Abaqus Toolbox, if available. This toolbox provides a graphical interface within MATLAB to set up, run, and post-process Abaqus simulations. It streamlines the process and might eliminate the need for manual scripting. Documentation and Resources: Both Abaqus and MATLAB offer extensive documentation and user guides. Consult these resources for specific information on integrating the two software packages. Additionally, online forums and communities can provide valuable insights and solutions to integration-related issues. Remember that this integration process might vary based on the specific versions of Abaqus and MATLAB you are using, as well as your operating system. Always consult the documentation provided with the software for accurate and up-to-date information.

  • @user-ub3yo4co4w
    @user-ub3yo4co4w7 ай бұрын

    Hi, a quick question. How to ask abaqus to wait for the first job to complete and then start the second job?

  • @MichaelOkereke

    @MichaelOkereke

    7 ай бұрын

    Hello, *What I do* There is no straight forward command in ABAQUS to do this. What you will have to do is to find a way to monitor to job and then ask it to indicate when a job is completed and then a second one starts. In the past, what I have done is to write a Shell Script which multiple submit options and the next job only executes when a 'JOB COMPLETED' output is detected in the work directory. These sort of external methods are actions people take to monitor ABAQUS JOBs and then run jobs concurrently. *What ABAQUS recommends* ABAQUS has this command called waitForCompletion() which you can use to check the job is completed before loading a next activity. Check more about it from the ABAQUS documentation here: 130.149.89.49:2080/v6.8/books/cmd/default.htm?startat=pt02ch06s08.html Essentially, you hold the job until completion is detected before a next activity is called. In the example in the link, you check for completion before a visualization module is detected and a subsequent plot generated. In your case, you check for completion before sending a new job submit command with your next job name. This is probably a straight forward process for but you have to do it from a Python script. *External methods* I know they are external methods that you can use. Thinking further into your problem, I decided to ask the same question to ChatGPT and below is the ChatGPT-response. I like the *sub-process* option but I have not tested it out. -------------------------------------------------------------------- *Using Python Scripting* If you're running Abaqus jobs via Python scripts, you can employ the subprocess module to execute the second job after the completion of the first job. Python code import subprocess # Run first job subprocess.run('abaqus job=input1.inp', shell=True) # Wait for the completion of the first job # Run the second job subprocess.run('abaqus job=input2.inp', shell=True) This Python script will execute the first job, wait for its completion, and then proceed to execute the second job. *Using Bash Scripting (Linux/macOS)* In a Unix-like environment, you can create a Bash script to wait for the first job to complete before initiating the second job. bash code (shell-scripting language) # Run first job in the background abaqus job=input1.inp & # Wait for the first job to complete wait # Run the second job abaqus job=input2.inp *Using Job Scheduler* If you're working in a cluster or HPC environment, job scheduling software (like Slurm, PBS, or LSF) often provides mechanisms to submit jobs in sequence. You can use job dependencies or job chaining to ensure that the second job starts only after the first job has completed. For example, in Slurm, you can use job dependencies: bash code # Submit the first job and get its job ID job1_id=$(sbatch input1.slurm | awk '{print $4}') # Submit the second job depending on the first job sbatch --dependency=afterok:$job1_id input2.slurm