Author Topic: Implementation of earthquake loading  (Read 11827 times)

Prof. R.L. Taylor

  • Administrator
  • FEAP Guru
  • *****
  • Posts: 2649
Re: Implementation of earthquake loading
« Reply #15 on: January 28, 2016, 08:02:39 AM »
Yes, but be sure to print the values you are putting in the body(*) array to be sure they are what you expect.

Now you need to add the body force effect to the  residual array in your user element.

ibry

  • Full Member
  • ***
  • Posts: 52
Re: Implementation of earthquake loading
« Reply #16 on: January 29, 2016, 01:45:18 AM »
I should have explicit type for groupl, groufl, gfac, and gprop eventhough I have written --> include 'refnd.h' and pglob1.h'.
Since the program cannot work to process them after compiling and there are messages to put explicit type of them.
However, it can work after I put 'refng.h', is it right Professor?

I tried to run and I checked statement with marking the following codes

if(imat.eq.5) then
      if(groufl) then
          do i=1,ndf
              d(13+i)=gfac(i)
          enddo
      endif
      if(groupl) then
          do i=1,ndf
              d(16+i)=gprop(i)
          enddo
      endif
endif

But, after I continued debugging "if(imat.eq.5) then" to "if(groufl) then", it didn't go forward and stayed in that step.
What's wrong, Prof?
Thank you very much.
« Last Edit: January 29, 2016, 02:07:14 AM by ibry »

Prof. R.L. Taylor

  • Administrator
  • FEAP Guru
  • *****
  • Posts: 2649
Re: Implementation of earthquake loading
« Reply #17 on: January 29, 2016, 11:18:17 AM »
If you are processing with visual studio, you need to tell the compiler where to find the include files.  This is one of the options you set up when compiling feap.

I can see no reason the program should stop unless it is an unassigned value.  I like putting statements in the code that print things when the debugger is not helping.  Putting code like

      write(*,*) 'variable name =', variable value

helps me -- when the code is running it prints each of these to the screen so you can follow the progress without stepping with the debugger.  Debugging can be hard, you need to be a good detective and follow clues!

ibry

  • Full Member
  • ***
  • Posts: 52
Re: Implementation of earthquake loading
« Reply #18 on: January 30, 2016, 04:58:38 AM »
Sure, I have written gfac(*) and gprop(*) in the screen but the results were still zero values.
The command was not processed and directly jumped in the next step.
I guess indeed it can't work with that code in the user element.
Is there other way to put ground acceleration, beside applying GROU command?
Many thanks.

Prof. R.L. Taylor

  • Administrator
  • FEAP Guru
  • *****
  • Posts: 2649
Re: Implementation of earthquake loading
« Reply #19 on: January 30, 2016, 06:47:16 AM »
You need someone to help you understand why the values are zero when you are printing them.  Ask a friend, professor or tutor.

1. When you read in the values print them to the screen to be sure this part of the program is being used.  Make sure you have the include files so they are saved to the common block.  Also in some operating systems it is necessary for the module to include the statement
        SAVE  (look in one of the existing modules in feap on where to place the statement)

If this is processed then you should have the non-zero values.

2. Now if the values are zero when you get to your module where you want to use them, there must be some place where they are begin set to zero after the input.  Check all your other coding to make sure you do not zero them.