How to increment time evenly?

Forum for OpenSees users to post questions, comments, etc. on the use of the OpenSees interpreter, OpenSees.exe

Moderators: silvia, selimgunay, Moderators

Post Reply
Rodgers
Posts: 31
Joined: Wed Sep 15, 2004 4:44 pm
Location: University of California, Davis

How to increment time evenly?

Post by Rodgers »

Hi, I want to do a static analyses where time increments uniformly with a given interval. However, I just found out that in OpenSees, time step dLambda is first determined by:

dLambda(i) = dLambda(i-1)*Jd/J(i-1)

where J(i-1) is the number of iterations it took to reach convergence for the previous step, and Jd is a factor given by user when issuing "integrator" command. Then there are some other adjustment applied.

But this would make my time step smaller and smaller even if it is perfectly linear elastic with Newton algorithm, since J(i-1) is always 2 in this case.

Any suggestion ? I can't just use Jd as 2 because J(i-1) will not be constant for my actual problem.
It is not what you can do, it is what you can dream!
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Post by fmk »

it will be constant for load control unless you provide a Jd on the input line.
Rodgers
Posts: 31
Joined: Wed Sep 15, 2004 4:44 pm
Location: University of California, Davis

Post by Rodgers »

Thanks Frank! But that is not true. Looking at the code below where deltaLambda is determined, it doesn't matter whether Jd is specified or not. If it is not specified, it will just be 1.

However, I could just specify dLambdaMin and dLambdaMax to be exactly the same as the time step I want. But this seems a little awkward.

Code: Select all

int 
LoadControl::newStep(void)
{
    AnalysisModel *theModel = this->getAnalysisModel();    
    if (theModel == 0) {
	opserr << "LoadControl::newStep() - no associated AnalysisModel\n";
	return -1;
    }

    // determine delta lambda for this step based on dLambda and #iter of last step
    double factor = specNumIncrStep/numIncrLastStep;
    deltaLambda *=factor;

    if (deltaLambda < dLambdaMin)
      deltaLambda = dLambdaMin;
    else if (deltaLambda > dLambdaMax)
      deltaLambda = dLambdaMax;
    
    double currentLambda = theModel->getCurrentDomainTime();

    currentLambda += deltaLambda;
    theModel->applyLoadDomain(currentLambda);

    numIncrLastStep = 0;
    
    return 0;
}
   
It is not what you can do, it is what you can dream!
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Post by fmk »

yes but if they are not provided on the command line, it is set up so you get consnat stepsize .. in SRC/tcl/commands.cpp :

Code: Select all

else {
	minIncr = dLambda;
	maxIncr = dLambda;
	numIter = 1;
      }
Rodgers
Posts: 31
Joined: Wed Sep 15, 2004 4:44 pm
Location: University of California, Davis

Post by Rodgers »

Got it. Thanks Frank!
It is not what you can do, it is what you can dream!
Post Reply