How to run a 2D case?

Dear all,

I am trying to compile a fully 2D model. However, I am receiving the following error:

  1. When I try to undef solved3D in the cppdefs.h, but it doesn’t seem to work, it still appears in the log file.

2.When I try to undef solve3D in the cppdefs_dve.h,there are some mistakes during compilng.

I am new to CROCO, so it is possible I am making some mistakes. An example of a similar case would be helpful.

Thank you in advance for your time,
Roy

1 Like

Hi,
Roy
Its seems that a very beautiful question, you asked. Is it with parent domain?, can you upload your cppdefs.h, cppdefs_dev.h and log.
Thank you.

Hi,
smaishal
Thank you for replying me. Sorry I am a new user who can not upload the attachments. Would you mind giving me the email and I will send them to you later.
Thank you

1 Like

Roy
OK. :: :slight_smile: ::
Email: subhadeepmaishal@kgpian.iitkgp.ac.in

  1. When I try to undef solved3D in the cppdefs.h, but it doesn’t seem to work, it still appears in the log file.

This should not be the case. Make sure you are reading the correct cppdefs.h. In which directory did you changed this file?

I am sure I am modifying the correct cppdefs.h because I have tried changing other options, which has proven to be effective, but the solve3d dimension cannot be turned off.
Is it possible that other options are conflicting with solve3d?

Roy
conflicting , its happen every where, where not!. let me know.
FVCOM also.
MODEL IT SELF MODEL!

Sorry, I haven’t found where the problem is yet.

Hi, I just ran the default Benguela_LR case in a 2D configuration using CROCO-v2.0.0. Works ok.

The only changes I had to do were

  1. In cppdefs.h

#undef SOLVE3d

  1. In croco.in

Set DT to 60 s
Set NDTFAST to 1

The only output variables are ZETA, UBAR, and VBAR.

Please try this in the default BENGUELA_LR case first.

1 Like

You are right. But in my case, if set the ndtfast to 1, my case will blow up. Thank you for your advice.

What is your grid size (dx) and what is your time step?

dx is 2m, and dt is 0.02s.

Hi,
Roy
I hope you are doing well.
Which application are you using CROCO? it seems analytical.
blow up can happen for many reasons (as an example stratified or satisfied), if a person knows how to solve it. they CAN. I believe you can.
But sometimes it depends. i have seen your file :slight_smile: .
i am just thinking about how i use defined USE_CALENDAR. did you have any idea for that with AGRIF_2WAY ? and it’s my pleasure to talk to you. Have a good day!
BEST
subhadeep

Try decreasing your timestep. A quick calculation based on the Benguela case suggest a dt of 0.004 s

30000 → 3600
2 → 0.24

0.24/60 = 0.004

1 Like