UniMainzGeo / LaMEM

LaMEM (Lithosphere and Mantle Evolution Model) - a 3D parallel code to simulate geodynamic and geomechanical processes
MIT License
50 stars 16 forks source link

How to set an initial velocity? #21

Closed colorzircon closed 6 days ago

colorzircon commented 2 months ago

Dear developers of LaMEM,

I am a beginner user of LaMEM and have encountered a challenge in setting an initial velocity to trigger subduction. My goal is to apply an X-direction velocity as follows:

  1. 10 cm/year from left to right for the first 5 Myr
  2. 5 cm/year for the next 5 Myr
  3. No velocity after this 10 Myr period

I've noticed three potentially relevant functions in LaMEM:

  1. Internal velocity box:
VelBox_num    = 1
VelBox_cenX   = 100
VelBox_cenY   = 0.0
VelBox_cenZ   = -50
VelBox_widthX = 200
VelBox_widthY = 4
VelBox_widthZ = 100
VelBox_Vx     = 5
VelBox_Vy     = NaN
VelBox_Vz     = NaN
VelBox_Advect = 1
  1. AddPushing:
AddPushing                = 1
<PushingBlockStart>
    PushID               = 0
    num_changes          = 1
    time                 = 0 5
    V_push               = 5.0
    dir                  = 1
    omega                = 0
    coord_advect         = 1
    reset_pushing_coord  = 0
    theta                = 0
    L_block              = 200
    W_block              = 4
    H_block              = 100
    x_center_block       = 100
    y_center_block       = 0
    z_center_block       = -50
<PushingBlockEnd>
  1. Velocity boundary condition:
bvel_face            = Left
bvel_face_out        = 1
bvel_bot             = -100
bvel_top             = 0
velin_num_periods    = 2
velin_time_delims    = 5
bvel_velin           = 5 0
bvel_relax_d         = 10

Could you please advise which of these methods would be most appropriate for driving an initial subduction?

Thank you very much in advance for your help.

boriskaus commented 2 months ago

Option 2 should do the job

colorzircon commented 2 months ago

Option 2 should do the job

Thank you for your prompt reply to my previous inquiry.

I've been attempting to implement Option 2, AddPushing, in my model. However, I've encountered difficulties in getting it to function correctly.

I was hoping you could review my model setup to identify any necessary corrections.

Would you kindly examine these files to see if there are any issues with my implementation of the AddPushing option?

Thank you for your time and assistance.

boriskaus commented 2 months ago

Can you please create this setup with the Julia interface and send me a Julia script that does the same. See LaMEM.jl and example.

The Matlab setup is no longer supported; within the Julia framework we also set many useful defaults.

colorzircon commented 2 months ago

Can you please create this setup with the Julia interface and send me a Julia script that does the same. See LaMEM.jl and example.

The Matlab setup is no longer supported; within the Julia framework we also set many useful defaults.

Hi, professor, here is my setup with LaMEM.jl. Could you please implement AddPushing in it?

BTW, temperature structure in this model has some problems, could you please check it and give me suggestions on how to improve the temperature setting?

boriskaus commented 1 month ago

apologies, I was too fast in my response.

Option 2 was available in a very old version of LaMEM but has been removed since. In fact all currently available options of LaMEM are listed in the lamem_input.dat file. You can use option 1 (velocity block), and you can in fact even have several velocity blocks at once. Yet, they always have a constant velocity, that doesn't change with time. Option 3 is also available but gives inflow at the boundary.

Option 2 was in fact replaced by Bezier blocks:

# Bezier blocks (single entry per block)
<BCBlockStart>
    npath =  2                                 # Number of path points of Bezier curve (path-points only!)
    theta =  0.0 5.0                           # Orientation angles at path points (counter-clockwise positive)
    time  =  1.0 2.0                           # Times at path points
    path  =  0.0 0.0 0.0 10.0                  # Path points x-y coordinates
    npoly =  4                                 # Number of polygon vertices
    poly  =  0.0 0.0 0.1 0.0 0.1 0.1 0.0 0.1   # Polygon x-y coordinates at initial time
    bot   =  0.0                               # Polygon bottom coordinate
    top   =  0.1                               # Polygon top coordinate
<BCBlockEnd>

This is in fact a much more general way to specify pushing blocks, and allows you to specify the path that a pushing polygon should take through time. You can specify an arbitrary shaped polygon (in x-y or map view) and you can even rotate this block (in map view) at a certain point of time. So you can use this to specify the time-dependent motion of a continental block in a 3D setup.

An example of how to use this in 2D is t3_SubductionGMGinput/Subduction_VEP.dat.

Note that it is also implemented in the Julia interface - I haven't tested this yet so let me know if you run into issues.

colorzircon commented 4 weeks ago

apologies, I was too fast in my response.

Option 2 was available in a very old version of LaMEM but has been removed since. In fact all currently available options of LaMEM are listed in the lamem_input.dat file. You can use option 1 (velocity block), and you can in fact even have several velocity blocks at once. Yet, they always have a constant velocity, that doesn't change with time. Option 3 is also available but gives inflow at the boundary.

Option 2 was in fact replaced by Bezier blocks:

# Bezier blocks (single entry per block)
<BCBlockStart>
    npath =  2                                 # Number of path points of Bezier curve (path-points only!)
    theta =  0.0 5.0                           # Orientation angles at path points (counter-clockwise positive)
    time  =  1.0 2.0                           # Times at path points
    path  =  0.0 0.0 0.0 10.0                  # Path points x-y coordinates
    npoly =  4                                 # Number of polygon vertices
    poly  =  0.0 0.0 0.1 0.0 0.1 0.1 0.0 0.1   # Polygon x-y coordinates at initial time
    bot   =  0.0                               # Polygon bottom coordinate
    top   =  0.1                               # Polygon top coordinate
<BCBlockEnd>

This is in fact a much more general way to specify pushing blocks, and allows you to specify the path that a pushing polygon should take through time. You can specify an arbitrary shaped polygon (in x-y or map view) and you can even rotate this block (in map view) at a certain point of time. So you can use this to specify the time-dependent motion of a continental block in a 3D setup.

An example of how to use this in 2D is t3_SubductionGMGinput/Subduction_VEP.dat.

Note that it is also implemented in the Julia interface - I haven't tested this yet so let me know if you run into issues.

Dear Prof. Boris,

I tried adding BCBlock in LaMEM.jl model, it seems not work. While BCBlock runs well in C++ LaMEM.

Thanks for your time in advance. Best regards, Lei