2D Mesh Issue

4 views
Skip to first unread message

hoover.a...@gmail.com

unread,
Jan 28, 2026, 11:09:47 AM (4 days ago) Jan 28
to IBAMR Users
Hi all,

I'm encountering an error that came from a recent install of IBAMR and seems to only affect 2D meshes:

P=00001:Program abort called in file ``/apps/project/pbs0334/ibamr/0.17-openmpi/tmp/unpack/IBAMR-0.17.0/src/IB/IBFEMethod.cpp'' at line 375
P=00001:ERROR MESSAGE:
P=00001:Failed assertion: mesh->mesh_dimension() == mesh->spatial_dimension()

I've run the code with 3D meshes and it seems to work correctly. Looking over my input file and main.C (which worked correctly in a previous install), I can't find the issue. My CMakeLists.txt is adjusted for 2D simulations:

PROJECT(mysolver)
CMAKE_MINIMUM_REQUIRED(VERSION 3.15.0)

# List your source files here - this example has just one.
SET(SOURCE_FILES main.C)
ADD_EXECUTABLE(main2d ${SOURCE_FILES})

FIND_PACKAGE(IBAMR 0.17.0 REQUIRED)
TARGET_LINK_LIBRARIES(main2d IBAMR::IBAMR3d)
# IBAMR saves the flags it used to compile - you can reuse them if you want to
SET(CMAKE_CXX_FLAGS ${IBAMR_CXX_FLAGS})

Any hints at what could be causing this?

Best,
Alex

Chang Wei

unread,
Jan 28, 2026, 11:47:04 AM (4 days ago) Jan 28
to ibamr...@googlegroups.com

Hi Alex

There is a small issue in your CMakeLists.txt.  The following line TARGET_LINK_LIBRARIES(main2d IBAMR::IBAMR3d) should be changed into  TARGET_LINK_LIBRARIES(main2d IBAMR::IBAMR2d), so that the target links against the correct 2D IBAMR library. 

Best regards,

Chang




发件人: ibamr...@googlegroups.com <ibamr...@googlegroups.com> 代表 hoover.a...@gmail.com <hoover.a...@gmail.com>
发送时间: 星期四, 一月 29, 2026 12:09 上午
收件人: IBAMR Users <ibamr...@googlegroups.com>
主题: [ibamr-users] 2D Mesh Issue
 
--
You received this message because you are subscribed to the Google Groups "IBAMR Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ibamr-users...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/ibamr-users/e324fd35-2a4f-49cc-9bdc-15fcac6ddaacn%40googlegroups.com.

Wells, David

unread,
Jan 28, 2026, 2:34:50 PM (4 days ago) Jan 28
to ibamr...@googlegroups.com
Hi Alex,

That message typically appears when the loaded mesh has nonzero z coordinates: does it have all the z coordinates set to, for example, 1?

Best,
David Wells

From: ibamr...@googlegroups.com <ibamr...@googlegroups.com> on behalf of Chang Wei <weichx...@gmail.com>
Sent: Wednesday, January 28, 2026 11:46 AM
To: ibamr...@googlegroups.com <ibamr...@googlegroups.com>
Subject: Re: [ibamr-users] 2D Mesh Issue
 
You don't often get email from weichx...@gmail.com. Learn why this is important
Reply all
Reply to author
Forward
0 new messages